/* Custom extra styles */
.select2-container--bootstrap-5 .select2-selection--single {
    height: 44px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgb(0 0 0 / 0.15);
    font-size: 16px;
    padding: 5px 12px;
    background-color: #f8f9fa;
}

.select2-search__field {
    width: 94% !important;
}

.select2-results__option--highlighted {
    background-color: #1b3a1a !important; /* cor do fundo ao passar o mouse */
    color: white !important;             /* cor do texto ao passar o mouse */
}

.select2-selection__placeholder{
    font-weight: 400;
    line-height: 2.0 !important;
    color: #6c757d;
}
.select2-selection__rendered {
    padding: 0;
    font-weight: 400;
    line-height: 2.0 !important;
    color: #212529;
}

.select2-results__option--selected{
    color: #fff;
    background-color: #2c6f24 !important;
}

.select2-selection{
    box-shadow: 0 0 0 .25rem rgba(0, 0, 0, .25) !important;
}

#pesquisaInput {
    box-shadow: 0 0 0 .25rem rgba(0, 0, 0, .25) !important;
}

#pesquisaInput:focus {
    outline: none;          /* remove o contorno do navegador */
    border: none;           /* remove a borda (se tiver) */
}




.cookie-notice {
    position: fixed;
    bottom: 0;
    width: 100%;
    background: #1b3a1a;
    color: white;
    padding: 15px 20px;
    text-align: center;
    font-size: 0.9rem;
    z-index: 9999;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.3);
}

.cookie-notice button {
    background: #ffffff;
    color: #1b3a1a;
    border: none;
    padding: 6px 12px;
    margin-left: 15px;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.3s;
}

.cookie-notice button:hover {
    background: #ddd;
}



#resetPasswordModal input[type="email"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 14px;
    margin-top: 4px;
    margin-bottom: 15px;
    transition: border-color 0.3s;
}

#resetPasswordModal input[type="email"]:focus {
    border-color: #2c6f24;
    outline: none;
    box-shadow: 0 0 5px rgba(44, 111, 36, 0.4);
}



.modal {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    justify-content: center;
    align-items: center;
}



#logoutSuccessAnimation {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #ffffff;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 0 20px rgba(0,0,0,0.3);
    display: none;
    z-index: 99999;
    animation: fadeOut 2s 1s forwards;
}

.checkmark {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: block;
    stroke-width: 3;
    stroke: #4caf50;
    stroke-miterlimit: 10;
    box-shadow: inset 0px 0px 0px #4caf50;
    animation: scale .3s ease-in-out;
    margin: 0 auto;
}

.checkmark__circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 3;
    stroke-miterlimit: 10;
    stroke: #4caf50;
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark__check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.3s forwards;
}

@keyframes stroke {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes scale {
    0%, 100% {
        transform: none;
    }
    50% {
        transform: scale3d(1.1, 1.1, 1);
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        visibility: hidden;
    }
}

.modal {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
    z-index: 2000;

    /* Adicionado para scroll interno */
    overflow-y: auto;
    padding: 20px 10px; /* um pouco de espaçamento para evitar cortar conteúdo */
    box-sizing: border-box;
}

.modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 5px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.3);
}



.btn {
    padding: 8px 16px;
    margin: 0 5px;
    border: none;
    cursor: pointer;
    border-radius: 4px;
}

.btn-secondary {
    background-color: #ccc;
    color: #000;
}

.btn-danger {
    background-color: #e74c3c;
    color: #fff;
}


/* Estilo para o disclaimer */
.disclaimer {
    margin-bottom: 10px;
    font-size: 14px;
    color: #777; /* Cor mais suave */
}




#loginModal input[type="email"],
#loginModal input[type="text"],
#loginModal input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 14px;
    margin-top: 4px;
    margin-bottom: 15px;
    transition: border-color 0.3s;
}

#loginModal input[type="email"]:focus,
#loginModal input[type="text"]:focus,
#loginModal input[type="password"]:focus {
    border-color: #2c6f24;
    outline: none;
    box-shadow: 0 0 5px rgba(44, 111, 36, 0.4);
}


.input-error {
    border: 1px solid red !important;
}


/* Adicionando novo estilo para feedback da senha */
.password-strength {
    height: 6px;
    width: 100%;
    border-radius: 4px;
    margin-top: 10px;
}

.strength-weak {
    background-color: red;
}

.strength-medium {
    background-color: orange;
}

.strength-strong {
    background-color: green;
}

.error-message {
    color: red;
    font-size: 0.9rem;
    margin-top: 5px;
}












.placeholder-pequeno::placeholder {
    font-size: 10px;
    color: #888;
}


#registoModal input[type="email"],
#registoModal input[type="text"],
#registoModal input[type="password"] {
    width: 100%;
    padding: 0.6rem;
    margin-top: 0.3rem;
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    box-sizing: border-box;
}

#registoModal input[type="email"]:focus,
#registoModal input[type="text"]:focus,
#registoModal input[type="password"]:focus {
    border-color: #2c6f24;
    outline: none;
    box-shadow: 0 0 5px rgba(44, 111, 36, 0.4);
}







body.modal-open {
    overflow: hidden; /* bloqueia scroll da página */
    height: 100vh;
}









#imagemMapa {
    max-width: 100%;
    margin-top: 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
}




#ligarBtn {
    background-color: #2c6f24;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    margin-bottom: 15px;
    width: 100%;
    display: none;
}

#ligarBtn.mostrar {
    display: block;
}















/* Animacao cards */
.loja {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.loja.animated {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.loja.loading {
    pointer-events: none;
}



.titulo-estilizado {
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(90deg, #1b3a1a, #2c6f24, #4caf50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
    text-shadow: 2px 2px 10px rgba(0, 114, 255, 0.2);
    animation: glow 3s ease-in-out infinite alternate;
    letter-spacing: 1.5px;
}

@keyframes glow {
    from {
        text-shadow: 2px 2px 10px rgba(0, 114, 255, 0.2);
    }
    to {
        text-shadow: 2px 2px 20px rgba(0, 114, 255, 0.6);
    }
}

@media (max-width: 600px) {
    .titulo-estilizado {
        font-size: 2rem;
    }
}


.menu-lateral hr {
    border: none;
    border-top: 1px solid #ccc;
    margin: 20px 0;
}



body {
    margin: 0;
    font-family: Arial, sans-serif;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: #f2f2f2;
}

main {
    flex: 1;
}

header {
    background: #1b3a1a;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between; /* Mantém o logo à esquerda e os botões à direita */
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 10000;
}

header a img {
    height: 40px;
}

.menu-group {
    display: flex;
    align-items: center;
    gap: 0; /* Remove o espaço entre os botões */
    justify-content: flex-end; /* Alinha os botões à direita */
}

button {
    background: none;
    border: none;
    cursor: pointer;
}

.burger {
    font-size: 24px;
    color: white; /* Torna o "☰" branco */
    background: none;
    border: none;
    cursor: pointer;
}

.user-btn img {
    height: 24px;
    width: 24px;
    object-fit: contain;
    filter: brightness(0) invert(1); /* Torna o ícone branco */
}

.burger:hover {
    background-color: rgba(255, 255, 255, 0.15);
}








.menu-lateral {
    position: fixed;
    top: 60px; /* ajustado para ficar abaixo do header */
    right: -300px;
    width: 250px;
    height: calc(100% - 70px); /* ajustado para preencher o resto da tela */
    background: #8cbe00;
    color: white;
    padding: 20px;
    transition: right 0.3s ease;
    z-index: 500;
    box-shadow: -3px 0 6px rgba(0,0,0,0.2);
}


.menu-lateral.ativo {
    right: 0;
}

.fechar-menu {
    background: none;
    border: none;
    color: white;
    font-size: 32px;
    position: absolute;
    top: 10px;
    right: 15px;
    cursor: pointer;
    line-height: 1;
}

.menu-lateral a {
    color: white;
    text-decoration: none;
    display: block;
    margin: 25px 0 10px 0;
    font-weight: bold;
    font-size: 1.1rem;
    transition: color 0.3s ease;
}

.menu-lateral a:hover {
    color: #1b3a1a;
}

.imagem-fundo {
    background-image: url('https://www.diarioleiria.pt/wp-content/uploads/sites/7/2024/12/Camara-municipal-de-alvaiazere_lfc-e1733142490518.webp');
    background-size: cover;
    background-position: center;
    height: 300px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 15px 15px 15px 15px;
    filter: contrast(1.1) brightness(1.05);
}

.div-branca-opaca {
    background: rgba(255, 255, 255, 0.5);
    padding: 15px;
    border-radius: 10px;
    max-width: 1000px;
    width: 100%;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    align-items: center;
}

.div-branca-opaca input[type="text"],
.div-branca-opaca select {
    flex: 1 1 220px;
    min-width: 220px;
    max-width: 400px;
    padding: 10px 15px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 1rem;
}

.select-estilizado {
    appearance: none;
    cursor: pointer;
    background-image: url('data:image/svg+xml;charset=UTF-8,<svg viewBox="0 0 140 140" xmlns="http://www.w3.org/2000/svg"><polyline points="20,50 70,100 120,50" stroke="%23333" stroke-width="20" fill="none" stroke-linecap="round"/></svg>');
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px;
    color: #999; /* placeholder color */
}

.select-estilizado option:not(:disabled) {
    color: black;
}

/* Mobile - empilha input e select */
@media (max-width: 600px) {
    .div-branca-opaca {
        flex-direction: column;
        align-items: stretch;
    }

    .div-branca-opaca input[type="text"],
    .div-branca-opaca select {
        max-width: 100%;
        min-width: auto;
        flex: none;
    }

    /* Centralizar o "ou" no mobile */
    .div-branca-opaca span {
        display: block;
        width: 100%;
        text-align: center;
        margin: 8px 0;
        font-weight: 600;
        color: #444;
    }

    .select2{
        width: 100% !important;
    }

    .select2-selection__rendered
    {
        text-align: left !important;
        line-height: 1.5 !important;
        margin-top: 0px !important;
    }

    .select2-selection__placeholder
    {
        text-align: left !important;
        line-height: 1.5 !important;
        margin-top: 2px !important;
    }

    .select2-container
    {
        margin-top: -10px !important;
    }
}

.lista-lojas {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    max-width: 1000px;
    margin: 30px auto;
    padding: 0 15px;
}

.loja {
    background: white;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.loja:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0,0,0,0.15);
}

.loja img {
    width: 100%;

    object-fit: cover;
}

.tipo-label {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #8cbe00;
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
    padding: 5px 12px;
    border-radius: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.25);
    text-transform: capitalize;
    z-index: 10;
}

.loja-info {
    padding: 15px;
    flex-grow: 1;
}

.loja-info h3 {
    margin: 0 0 8px 0;
    font-size: 1.2rem;
    color: #2c6f24;
}

.loja-info p {
    margin: 0;
    color: #555;
    font-size: 0.95rem;
}

.detalhes-btn {
    background: #2c6f24;
    color: white;
    border: none;
    padding: 10px;
    margin: 10px 15px 15px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    align-self: flex-start;
    transition: background-color 0.3s ease;
}

.detalhes-btn:hover {
    background: #215316;
}

footer {
    background: #1b3a1a;
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: auto;
    font-size: 0.9rem;
}

.modal {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.modal-conteudo {
    background: white;
    padding: 20px 30px;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    position: relative;
    text-align: left;
    color: #333;
}

.modal-conteudo h2 {
    margin-top: 0;
    color: #2c6f24;
}

.modal-conteudo p {
    margin: 8px 0;
    font-size: 1rem;
}

.modal-conteudo a {
    color: #2c6f24;
    text-decoration: none;
    font-weight: bold;
}

.modal-conteudo a:hover {
    text-decoration: underline;
}

.modal-conteudo button {
    margin-top: 20px;
    background: #1b3a1a;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
}

@media (max-width: 768px) {
    .lista-lojas {
        grid-template-columns: 1fr;
    }
}











#abrirPainel {
    display: block; /* para que tenha o seu espaço e seja visível quando for mostrado */
    width: 85%;
    margin: 10px auto; /* centralizar e dar margem */
    padding: 12px 0;
    background-color: #1b3a1a;
    color: white;
    font-weight: bold;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1.1rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    transition: background-color 0.3s ease;
}

#abrirPainel:hover {
    background-color: #1b3a1a;
}









.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    min-width: 300px;
    padding: 15px 20px;
    border-radius: 4px;
    background-color: #4caf50; /* success verde */
    color: white;
    font-size: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.toast.error {
    background-color: #f44336; /* vermelho erro */
}

.toast.warning {
    background-color: #ffa500; /* laranja */
}

.toast.show {
    display: flex;
    opacity: 1;
    pointer-events: auto;
}

#toastCloseBtn {
    background: none;
    border: none;
    color: white;
    font-size: 22px;
    cursor: pointer;
    line-height: 1;
    padding: 0 8px;
    margin-left: 10px;
}









@media screen and (max-height: 500px) and (orientation: landscape) {
    body::before {
        content: "Por favor rode o dispositivo para modo retrato.";
        position: fixed;
        inset: 0;
        background: #000;
        color: #fff;
        font-size: 1.2rem;
        display: flex;
        justify-content: center;
        align-items: center;
        z-index: 99999;
        text-align: center;
        padding: 20px;
    }

    body > * {
        display: none !important;
    }
}











/* Custom extra styles */
.select2-container--bootstrap-5 .select2-selection--single {
    height: 44px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgb(0 0 0 / 0.15);
    font-size: 16px;
    padding: 5px 12px;
    background-color: #f8f9fa;
}

.select2-search__field {
    width: 94% !important;
}

.select2-results__option--highlighted {
    background-color: #1b3a1a !important; /* cor do fundo ao passar o mouse */
    color: white !important;             /* cor do texto ao passar o mouse */
}

.select2-selection__placeholder{
    font-weight: 400;
    line-height: 2.0 !important;
    color: #6c757d;
}
.select2-selection__rendered {
    padding: 0;
    font-weight: 400;
    line-height: 2.0 !important;
    color: #212529;
}

.select2-results__option--selected{
    color: #fff;
    background-color: #2c6f24 !important;
}

.select2-selection{
    box-shadow: 0 0 0 .25rem rgba(0, 0, 0, .25) !important;
}

#pesquisaInput {
    box-shadow: 0 0 0 .25rem rgba(0, 0, 0, .25) !important;
}

#pesquisaInput:focus {
    outline: none;          /* remove o contorno do navegador */
    border: none;           /* remove a borda (se tiver) */
}




#recoverBtn {
    width: 100%;height: 50px;
}
#backLoginfloat{
    float: left;width: 48%;
}
#fecharReset {
    float:right;width: 48%;
}


/* Generic modal padding */
.modal-padding {
    margin: 0 10px;
}

/* Smaller padding variant */
.modal-padding-small {
    margin: 10px;
}

/* Hide modal by default */
.modal-hidden {
    display: none;
}

/* Password field wrapper (for the eye icon positioning) */
.password-wrapper {
    position: relative;
}

/* Toggle visibility eye button */
.toggle-password-btn {
    position: absolute;
    right: 10px;
    top: -15px;
    background-color: transparent;
    border: none;
    cursor: pointer;
}

/* Align text to the right */
.text-right {
    text-align: right;
}

/* Margin utilities */
.margin-top-small {
    margin-top: 5px;
}

.btn-margin-left {
    margin-left: 10px;
}

/* Small link styling */
.small-link {
    font-size: 0.9em;
}









.hidden {
    display: none;
}

.modal-padding {
    margin-right: 10px;
    margin-left: 10px;
}

.relative {
    position: relative;
}

.toggle-password-btn {
    position: absolute !important;
    right: 10px !important;
    top: 10% !important;
    transform: translateY(-50%);
    background: none !important; /* better than transparent */
    border: none !important;
    cursor: pointer !important;
    z-index: 10;
    font-size: 18px;
    color: #1b3a1a !important;
}


.text-right {
    text-align: right;
}

.btn-margin-left {
    margin-left: 10px;
}



#abrirPainel{
    display:none;
}

#logout{
    display:none;
}
