/* Cristal Frios Web — estilos do site
 * Regras originais preservadas na ordem de cascata.
 */

/* Base, navegação, conteúdo e rodapé */
:root {
    --ink: #252525;
    --accent: #00789d;
    --paper: #fffdf5;
    --line: #d7e6eb;
    --brand-blue: #00a3d2;
    --brand-yellow: #f5cd3e;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 125px;
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font: 16px/1.65 system-ui,sans-serif;
}

a {
    color: var(--accent);
}

header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: white;
    box-shadow: 0 2px 12px #0001;
}

.top {
    background: #006785;
    color: white;
    padding: 4px max(5vw,20px);
    font-size: 12px;
    display: flex;
    justify-content: space-between;
}

.nav {
    max-width: 1300px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 24px;
    gap: 20px;
}

.nav img {
    width: 110px;
    height: 60px;
    object-fit: contain;
}

nav {
    display: flex;
    gap: 16px;
    align-items: center;
    flex-wrap: wrap;
}

nav a {
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
}

.button {
    display: inline-block;
    background: var(--brand-yellow);
    color: var(--ink);
    padding: 11px 19px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 650;
    border: 1px solid #d5ad24;
}

.outline {
    background: transparent;
    color: var(--accent);
    margin-top: 22px;
}

#menu {
    display: none;
}

main {
    max-width: 1200px;
    margin: auto;
    padding: 0 24px;
}

.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 35px;
    padding: 65px 0;
}

.hero img {
    width: 100%;
    height: 380px;
    object-fit: cover;
    border-radius: 20px;
}

.eyebrow {
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--accent);
}

h1,h2,h3 {
    line-height: 1.15;
}

h1 {
    font-size: clamp(36px,5vw,68px);
    letter-spacing: -2px;
}

h2 {
    font-size: clamp(28px,4vw,42px);
    margin: 12px 0 25px;
}

.section {
    padding: 45px 0;
    border-top: 1px solid var(--line);
}

.compact {
    padding-top: 0;
    border: 0;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(230px,1fr));
    gap: 18px;
}

.tile {
    background: white;
    border: 1px solid var(--line);
    border-radius: 14px;
    overflow: hidden;
    text-decoration: none;
    color: var(--ink);
}

.tile img {
    width: 100%;
    height: 175px;
    object-fit: cover;
}

.tile div {
    padding: 18px;
}

.tile h3 {
    margin: 8px 0 14px;
}

.tile span,small {
    color: var(--accent);
}

.prose {
    max-width: 850px;
    overflow-wrap: anywhere;
}

.prose img {
    max-width: 100%;
    height: auto;
    max-height: 520px;
    object-fit: contain;
    margin: 6px;
}

.gallery {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 12px;
}

.gallery img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
    border-radius: 10px;
}

footer {
    background: var(--ink);
    color: white;
    padding: 40px max(5vw,24px);
}

footer a {
    color: white;
    margin-right: 14px;
    font-size: 13px;
}

.notice {
    background: #fff1b5;
    padding: 12px;
}

input,textarea,select,button {
    font: inherit;
}

input,textarea,select {
    max-width: 100%;
    padding: 10px;
    border: 1px solid #aaa;
    border-radius: 6px;
}

textarea {
    width: 100%;
}

button {
    cursor: pointer;
    padding: 8px 14px;
}

@media (max-width:900px) {
    #menu {
        display: block;
    }

    nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        padding: 20px;
    }

    nav.open {
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }

    .hero {
        grid-template-columns: 1fr;
        padding: 35px 0;
    }

    .hero img {
        height: 240px;
    }

    .gallery {
        grid-template-columns: repeat(2,1fr);
    }
}

@media (prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto;
    }
}

header {
    border-bottom: 3px solid var(--brand-blue);
}

.button:hover {
    background: #ffdc62;
    color: var(--ink);
}

.outline:hover {
    background: #e4f7fc;
    color: var(--accent);
}

.tile:hover {
    border-color: var(--brand-blue);
}

footer {
    border-top: 4px solid var(--brand-yellow);
}

a:focus-visible,button:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 3px;
}

body {
    background: #fff;
    color: #252525;
}

.top {
    background: #00789d;
}

.nav img {
    width: 120px;
    height: 76px;
}

.hero {
    background: #f1faff;
    border-radius: 22px;
    margin: 24px 0;
    padding: 36px;
}

.hero h1 {
    color: #005c79;
    margin: 14px 0;
}

.section {
    scroll-margin-top: 15px;
}

.section h2 {
    color: #005c79;
}

.footer-inner {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 32px;
    max-width: 1200px;
    margin: auto;
}

.footer-logo {
    width: 125px;
    background: #fff;
    border-radius: 10px;
    padding: 5px;
}

.copyright {
    border-top: 1px solid #ffffff30;
    margin: 24px auto 0;
    padding-top: 20px;
    max-width: 1200px;
    font-size: 13px;
}

.back-top {
    float: right;
}

.admin main {
    padding: 30px 24px;
    min-height: 70vh;
}

.admin button {
    background: var(--brand-yellow);
    border: 1px solid #d5ad24;
    border-radius: 8px;
}

.unavailable {
    text-align: center;
    padding: 60px 24px;
}

.tile img {
    object-fit: contain;
    background: #f7fafb;
}

.prose table {
    display: block;
    max-width: 100%;
    overflow: auto;
}

.prose iframe {
    max-width: 100%;
}

@media (max-width:1000px) {
    .nav {
        flex-wrap: wrap;
    }
}

@media (max-width:900px) {
    .hero {
        padding: 24px;
    }

    .footer-inner {
        grid-template-columns: 1fr;
    }

    .back-top {
        float: none;
        display: block;
        margin-top: 12px;
    }

    html {
        scroll-padding-top: 130px;
    }
}

/* Formas de pagamento: padronizacao das logos legadas */
#pagamentos .prose {
    max-width: none;
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
}

#pagamentos .prose p,#pagamentos .prose a {
    display: contents;
}

#pagamentos .prose br {
    display: none;
}

#pagamentos .prose img {
    display: block;
    width: 150px;
    height: 85px;
    max-width: 100%;
    margin: 0;
    padding: 12px;
    object-fit: contain;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 10px;
}

@media (max-width:480px) {
    #pagamentos .prose {
        gap: 8px;
    }

    #pagamentos .prose img {
        width: calc((100% - 16px)/3);
        height: 72px;
        padding: 8px;
    }
}

/* Contato institucional */
.contact-intro {
    color: #52636c;
    margin: -12px 0 24px;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 18px;
}

.contact-card {
    border: 1px solid var(--line);
    border-top: 4px solid #00a3d2;
    border-radius: 14px;
    background: #fff;
    padding: 24px;
    min-width: 0;
    box-shadow: 0 4px 18px #005c7909;
}

.contact-card h3 {
    color: #005c79;
    margin: 0 0 16px;
    font-size: 20px;
}

.contact-phone {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}

.contact-phone:last-child,.contact-email:last-child {
    border-bottom: 0;
}

.contact-phone small {
    display: block;
    color: #52636c;
}

.contact-number {
    display: block;
    font-weight: 700;
    color: #252525;
    text-decoration: none;
}

.contact-wa {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #e8f7ee;
    color: #146c39;
    border-radius: 8px;
    padding: 8px 10px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.contact-wa img {
    width: 20px;
    height: 20px;
    object-fit: contain;
    margin: 0;
}

.contact-email {
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    overflow-wrap: anywhere;
}

.contact-email strong,.contact-email a {
    display: block;
}

.contact-email a {
    color: #006887;
    font-size: 14px;
}

.contact-card address {
    font-style: normal;
    margin-bottom: 16px;
}

.contact-card .button {
    display: inline-block;
    margin-top: 8px;
}

@media (max-width:760px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-card {
        padding: 18px;
    }
}

@media (max-width:360px) {
    .contact-phone {
        flex-wrap: wrap;
    }
}

/* Baxinho institucional — v1.1.3 */
.bx-home {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    align-items: center;
}

.bx-home>img {
    width: 100%;
    height: auto;
    border-radius: 16px;
    display: block;
}

.bx-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.bx-secondary {
    background: white;
    color: #005c79;
    border-color: #b9dce7;
}

.bx-article {
    max-width: 1100px;
    margin: auto;
}

.bx-back {
    display: inline-block;
    margin-bottom: 20px;
}

.bx-hero {
    border: 1px solid var(--line);
    border-radius: 20px;
    overflow: hidden;
    background: #f1faff;
}

.bx-hero>img {
    display: block;
    width: 100%;
    height: auto;
}

.bx-hero-text {
    padding: clamp(20px,4vw,42px);
}

.bx-hero h1 {
    font-size: clamp(30px,5vw,52px);
    color: #005c79;
    margin: 10px 0;
    letter-spacing: -1px;
}

.bx-block {
    padding: 35px 0;
}

.bx-gallery {
    display: grid;
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 16px;
}

.bx-gallery figure {
    margin: 0;
    border: 1px solid var(--line);
    border-radius: 12px;
    overflow: hidden;
    background: white;
}

.bx-gallery img {
    display: block;
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
}

.bx-gallery figcaption {
    padding: 10px 14px;
    font-weight: 600;
}

.bx-info {
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    gap: 18px;
}

.bx-panel {
    padding: 24px;
    border: 1px solid var(--line);
    border-top: 4px solid var(--brand-blue);
    border-radius: 14px;
}

.bx-panel h2,.bx-cta h2 {
    font-size: 25px;
    margin: 0 0 16px;
}

.bx-panel h3 {
    font-size: 17px;
    margin: 18px 0 5px;
}

.bx-panel p {
    margin: 5px 0 12px;
}

.bx-panel dt {
    font-weight: 700;
    margin-top: 14px;
}

.bx-panel dd {
    margin: 4px 0 0;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
}

.bx-cta {
    margin-top: 28px;
    padding: 24px;
    background: #eaf8fc;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.bx-cta p {
    margin: 0;
}

.bx-cta a {
    overflow-wrap: anywhere;
    max-width: 100%;
}

@media (max-width:760px) {
    .bx-home,.bx-info {
        grid-template-columns: 1fr;
    }

    .bx-gallery {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }

    .bx-panel {
        padding: 18px;
    }
}

@media (max-width:360px) {
    .bx-gallery {
        grid-template-columns: 1fr;
    }
}

/* WAU — contador de visitantes */
.visitor-tracker {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 12px auto 0;
    opacity: 0.85;
}

.visitor-tracker:hover {
    opacity: 1;
}

/* Menu Digital — destaque permanente, inclusive no celular */
.menu-digital {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    font-size: 14px;
    animation: cf-menu-shake 5s ease-in-out infinite;
}
.menu-digital:hover, .menu-digital:focus-visible {
    animation: none;
    box-shadow: 0 4px 15px #f5cd3e66;
}
@keyframes cf-menu-shake {
    0%, 80%, 100% { transform: translateX(0); }
    82%, 90% { transform: translateX(-3px) rotate(-2deg); }
    86%, 94% { transform: translateX(3px) rotate(2deg); }
    98% { transform: translateX(0); }
}

/* Natal — aplicado somente durante o período sazonal */
.christmas-theme header { border-bottom-color: #d5ad24; }
.christmas-theme .top { background: #075345; gap: 8px; align-items: center; }
.festive-greeting { color: #ffe49a; text-align: center; font-weight: 700; }
.cf-snow { position: fixed; inset: 0; pointer-events: none; z-index: 11; overflow: hidden; }
.cf-snow span {
    position: absolute;
    top: -24px;
    color: #fff;
    text-shadow: 0 0 3px #00789d99;
    animation: cf-snowfall linear infinite;
}
@keyframes cf-snowfall { to { transform: translate(35px, 110vh); } }
.cf-christmas {
    width: min(480px, calc(100% - 32px));
    max-height: 90vh;
    overflow: auto;
    padding: 32px;
    border: 2px solid #d5ad24;
    border-radius: 22px;
    background: linear-gradient(145deg, #064d40, #123b46);
    color: white;
    text-align: center;
    box-shadow: 0 20px 70px #0005;
}
.cf-christmas::backdrop { background: #10252cb3; }
.cf-christmas h2 { color: #ffe49a; margin: 8px 0; }
.cf-close { position: absolute; right: 10px; top: 8px; background: transparent; color: white; border: 0; font-size: 25px; }
.cf-festive-icon { font-size: 40px; color: #ffe49a; }
.cf-festive-brand { font-size: 12px; letter-spacing: 2px; }
.cf-newyear { font-size: 20px; font-weight: 700; }

/* Consentimento de cookies e monitoramento opcional */
.cf-cookie-banner[hidden], #cf-wau[hidden] { display: none !important; }
.cf-cookie-banner {
    position: fixed;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: min(960px, calc(100% - 24px));
    z-index: 30;
    background: white;
    color: var(--ink);
    border: 1px solid var(--line);
    border-top: 4px solid var(--brand-blue);
    border-radius: 14px;
    padding: 20px;
    box-shadow: 0 8px 40px #0003;
    display: flex;
    align-items: center;
    gap: 20px;
    max-height: 85vh;
    overflow: auto;
}
.cf-cookie-banner h2 { font-size: 20px; margin: 0 0 8px; color: #005c79; }
.cf-cookie-banner p { font-size: 14px; margin: 0 0 6px; }
.cf-cookie-actions { display: flex; flex-wrap: wrap; gap: 8px; flex-shrink: 0; max-width: 350px; }
.cf-cookie-actions button { flex: 1; font-size: 14px; padding: 10px 12px; border: 1px solid #d5ad24; border-radius: 8px; }
.cf-cookie-reject { background: white; color: var(--ink); }
.cf-cookie-settings { display: block; margin: 16px auto 0; color: white; background: transparent; border: 1px solid #ffffff60; border-radius: 8px; font-size: 13px; }
@media (max-width: 900px) {
    .nav { gap: 10px; }
    .nav > .menu-digital { margin-left: auto; }
    .christmas-theme .top { flex-wrap: wrap; }
    .festive-greeting { order: 3; width: 100%; }
    .christmas-theme { scroll-margin-top: 20px; }
    html:has(.christmas-theme) { scroll-padding-top: 165px; }
}
@media (max-width: 600px) {
    .cf-cookie-banner { flex-direction: column; align-items: stretch; padding: 15px; gap: 12px; }
    .cf-cookie-actions { max-width: none; }
    .nav > .menu-digital { padding: 8px 10px; }
    .nav img { width: 90px; height: 56px; }
    .nav { padding: 8px 12px; }
}
@media (prefers-reduced-motion: reduce) {
    .menu-digital { animation: none; }
    .cf-snow { display: none; }
}

/* MaisBB — apresentação institucional e artigo */
.bb-home, .bb-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 28px;
    align-items: center;
}
.bb-hero {
    background: #f5faff;
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: clamp(18px, 4vw, 36px);
}
.bb-home img, .bb-hero img {
    width: 100%;
    max-height: 330px;
    object-fit: contain;
    border-radius: 12px;
}
.bb-article h1 { font-size: clamp(30px, 5vw, 48px); color: #005c79; letter-spacing: -1px; }
.bb-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin: 24px 0; }
.bb-card { background: white; border: 1px solid var(--line); border-top: 4px solid var(--brand-blue); border-radius: 14px; padding: 24px; }
.bb-card h2 { font-size: 24px; margin: 0 0 16px; }
.bb-services { list-style: none; padding: 0; margin: 0; }
.bb-services li { padding: 9px 0; border-bottom: 1px solid var(--line); }
.bb-services li:last-child { border: 0; }
.bb-services li::before { content: "✓"; color: #00789d; font-weight: bold; margin-right: 10px; }
.bb-hours { font-weight: 700; color: #005c79; }
.bb-note { color: #52636c; font-size: 14px; }
.bb-cta { background: #eaf8fc; border-radius: 14px; padding: 24px; margin-top: 20px; }
@media (max-width: 760px) {
    .bb-home, .bb-hero, .bb-grid { grid-template-columns: 1fr; }
    .bb-card { padding: 18px; }
}

/* Quem somos — v1.1.7 */
.cf-about-home, .cf-about-hero {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: center;
    gap: 28px;
}
.cf-about-lead {
    font-size: 1.2rem;
    color: #005c79;
    font-weight: 600;
}
.cf-about-photo {
    margin: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #f1faff;
}
.cf-about-photo img {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}
.cf-about-photo figcaption {
    padding: 10px 16px;
    color: #005c79;
    font-size: .9rem;
}
.cf-about-article { max-width: 1100px; margin: auto; }
.cf-about-hero {
    padding: clamp(20px, 4vw, 42px);
    background: #f1faff;
    border: 1px solid var(--line);
    border-radius: 20px;
    border-top: 4px solid var(--brand-blue);
}
.cf-about-hero h1 { color: #005c79; margin: 12px 0; }
.cf-about-hero img { width: 100%; max-width: 300px; justify-self: center; height: auto; }
.cf-about-year { display: inline-block; background: var(--brand-yellow); padding: 6px 12px; border-radius: 8px; font-weight: 700; }
.cf-about-story { margin: 32px auto; max-width: 850px; }
.cf-about-values { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.cf-about-values section { padding: 20px; border: 1px solid var(--line); border-top: 4px solid var(--brand-blue); border-radius: 14px; }
.cf-about-values h3 { color: #005c79; margin: 0 0 12px; }
.cf-about-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
@media (max-width: 760px) {
    .cf-about-home, .cf-about-hero, .cf-about-values { grid-template-columns: 1fr; }
}

/* Atendimento integrado — v1.1.8 */
.contact-grid-expanded {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    align-items: stretch;
}

.contact-grid-expanded .contact-card {
    padding: 20px;
}

.contact-grid-expanded .contact-phone {
    flex-wrap: wrap;
    gap: 8px;
}

.contact-hours {
    background: #f1faff;
    scroll-margin-top: 15px;
}

.contact-hours-content p {
    margin: 0;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
}

.contact-hours-content p:last-child {
    border-bottom: 0;
}

.contact-hours-content strong {
    color: #005c79;
}

.contact-digital {
    border-top-color: var(--brand-yellow);
}

@media (max-width: 1050px) {
    .contact-grid-expanded {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .contact-grid-expanded {
        grid-template-columns: 1fr;
    }
}


/* Rodapé institucional — v1.1.10 */
.footer-inner.cf-footer-columns {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr) minmax(0, 1.5fr) minmax(0, 1fr);
    gap: clamp(18px, 3vw, 36px);
    align-items: start;
}
.cf-footer-group ul {
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
}
.cf-footer-group li { margin: 0 0 10px; }
.cf-footer-group a { display: inline-block; margin: 0; line-height: 1.5; text-decoration: none; overflow-wrap: break-word; }
.cf-footer-group a:hover, .cf-footer-group a:focus-visible { color: var(--brand-yellow); text-decoration: underline; }
.cf-footer-group strong { display: block; font-size: 16px; color: var(--brand-yellow); }
.cf-footer-services a, .cf-footer-credits a { margin-right: 0; }
.cf-footer-services a:hover, .cf-footer-credits a:hover { color: var(--brand-yellow); }
footer .copyright {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.cf-footer-credits { display: grid; gap: 6px; }
footer .copyright .back-top { float: none; margin: 0; }
@media (max-width: 1000px) {
    .footer-inner.cf-footer-columns { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
}
@media (max-width: 560px) {
    .footer-inner.cf-footer-columns { grid-template-columns: 1fr; gap: 24px; }
    footer .copyright { flex-direction: column; align-items: flex-start; }
}
