/* =========================================================
   Labirintos Coloridos — Variante "Labirintos Vivos"
   Paleta mais viva, motivos de labirinto, formas orgânicas.
   ========================================================= */

:root {
    /* Paleta viva */
    --cream-bg: #fcf7ee;
    --cream-soft: #f4ead8;
    --ink: #1a1b2d;
    --ink-soft: #3a3c5a;
    --muted: #7a7c92;
    --border: #ece3cf;

    /* Criança — terracota vivo + accent amarelo-dourado */
    --ind-main: #D4572A;      /* terracota saturada */
    --ind-deep: #7c2f1a;
    --ind-light: #F5C896;
    --ind-pop: #F5B041;       /* amarelo quente */

    /* Palcos — magenta + rosa */
    --palco-main: #B83280;    /* magenta vivo */
    --palco-deep: #5c1645;
    --palco-light: #F1B6D7;
    --palco-pop: #EC7EB1;     /* rosa pop */

    /* Estrutura — azul + verde-azulado */
    --est-main: #2A6FB5;      /* azul vivo */
    --est-deep: #0d2d52;
    --est-light: #A9CCEC;
    --est-pop: #3BA99C;       /* verde-azulado */

    /* Tipografia */
    --font-serif: "Fraunces", Georgia, serif;
    --font-sans: "Inter", system-ui, sans-serif;
    --font-hand: "Caveat", "Kalam", cursive;

    --radius-lg: 28px;
    --radius-md: 16px;
    --radius-sm: 8px;
    --shadow-pop: 0 16px 40px rgba(26, 27, 45, .12);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 17px;
    line-height: 1.65;
    color: var(--ink);
    background: var(--cream-bg);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
    font-family: var(--font-serif);
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin: 0 0 1rem;
}
h1 { font-size: clamp(2.5rem, 5.5vw, 4.5rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.8rem); }
h3 { font-size: clamp(1.3rem, 2.2vw, 1.8rem); }

.hand {
    font-family: var(--font-hand);
    font-weight: 400;
    font-size: 1.4em;
    color: var(--palco-main);   /* magenta — distingue da laranja já usada no resto do hero */
    line-height: 1;
    display: inline-block;
    transform: rotate(-2deg);
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.container-narrow { max-width: 780px; margin: 0 auto; padding: 0 1.5rem; }

.section { padding: 6rem 0; position: relative; }

/* ---------- Preview nav (só preview) ---------- */
.preview-nav {
    background: var(--ink); color: #fff; padding: 0.6rem 0;
    font-size: 0.85rem;
}
.preview-nav a { color: #fff; opacity: .7; margin: 0 .75rem; text-decoration: none; }
.preview-nav a:hover, .preview-nav a.active { opacity: 1; }
.preview-label { font-size: .7rem; text-transform: uppercase; letter-spacing: .15em; opacity: .5; margin-right: .5rem; }

/* ---------- Header ---------- */
.site-header {
    position: sticky; top: 0; z-index: 50;
    background: rgba(252, 247, 238, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}
.site-header-inner {
    display: flex; justify-content: space-between; align-items: center;
    padding: 1rem 0; gap: 2rem;
}
.site-brand {
    display: flex; align-items: center; gap: .75rem;
    font-family: var(--font-serif); font-size: 1.15rem; font-weight: 500;
    text-decoration: none;
}
.site-brand:hover { text-decoration: none; }
.site-brand-mark {
    width: 44px; height: 44px;
    border-radius: 50%;
    background: conic-gradient(from 45deg,
        var(--ind-main) 0deg, var(--ind-pop) 90deg,
        var(--palco-main) 180deg, var(--palco-pop) 270deg,
        var(--est-main) 360deg);
    display: grid; place-items: center;
    color: #fff; font-weight: 700; font-size: 1rem;
    position: relative;
}
.site-brand-mark::after {
    content: ""; position: absolute; inset: 6px;
    background: var(--cream-bg); border-radius: 50%;
    z-index: 0;
}
.site-brand-mark span { position: relative; z-index: 1; color: var(--ink); }

.site-nav ul {
    list-style: none; padding: 0; margin: 0;
    display: flex; gap: 2rem; align-items: center;
}
.site-nav a {
    font-size: .95rem; font-weight: 500; color: var(--ink-soft);
    position: relative; padding: 4px 0;
    text-decoration: none;
}
.site-nav a::after {
    content: ""; position: absolute; inset: auto 0 -2px 0; height: 3px;
    background: linear-gradient(90deg, var(--ind-main), var(--palco-main), var(--est-main));
    transform: scaleX(0); transform-origin: left; transition: transform .25s;
    border-radius: 4px;
}
.site-nav a:hover, .site-nav a.active { color: var(--ink); text-decoration: none; }
.site-nav a:hover::after, .site-nav a.active::after { transform: scaleX(1); }

/* ---------- Botão hamburger (só visível em mobile) ---------- */
.menu-toggle {
    display: none;
    background: transparent;
    border: 0;
    padding: 0;
    width: 44px;
    height: 44px;
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    margin-left: auto;
}
.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--ink);
    border-radius: 2px;
    transition: transform .25s ease, opacity .2s ease;
    transform-origin: center;
}
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Header / Nav responsivos ---------- */
@media (max-width: 860px) {
    .site-header { position: relative; }
    .site-header-inner { gap: 1rem; padding: .85rem 0; }
    .site-brand { font-size: 1rem; }
    .site-brand-mark { width: 38px; height: 38px; }
    .site-brand-mark svg { width: 24px; height: 24px; }
    .site-brand small { display: none; } /* esconde sub-título "uma marca …" em mobile estreito */

    .menu-toggle { display: flex; }

    .site-nav {
        position: absolute;
        top: 100%;
        left: 0; right: 0;
        background: rgba(252, 247, 238, 0.98);
        backdrop-filter: blur(12px);
        border-top: 1px solid var(--border);
        border-bottom: 1px solid var(--border);
        max-height: 0;
        overflow: hidden;
        transition: max-height .3s ease;
        z-index: 49;
    }
    .site-nav[data-open="true"] { max-height: 70vh; overflow-y: auto; }
    .site-nav ul {
        flex-direction: column;
        gap: 0;
        padding: .5rem 0;
        align-items: stretch;
    }
    .site-nav li { width: 100%; }
    .site-nav a {
        display: block;
        padding: .95rem 1.5rem;
        font-size: 1rem;
        border-bottom: 1px solid rgba(26,27,45,.06);
    }
    .site-nav li:last-child a { border-bottom: 0; }
    .site-nav a::after { display: none; }
    .site-nav a:hover, .site-nav a.active { background: rgba(184,50,128,.06); }
}

/* ---------- Hero ---------- */
.hero {
    padding: 5rem 0 4rem;
    position: relative;
    overflow: hidden;
}
.hero::before {
    /* Labirinto SVG pattern no fundo */
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 120 120'><g fill='none' stroke='%23D4572A' stroke-width='2' stroke-opacity='0.08' stroke-linecap='round'><path d='M20 20 L100 20 L100 100 L40 100 L40 40 L80 40 L80 80 L60 80 L60 60'/></g></svg>");
    background-size: 180px 180px;
    opacity: .6;
    pointer-events: none;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 4rem;
    align-items: center;
    position: relative;
}
.hero h1 {
    font-size: clamp(2.8rem, 6vw, 5rem);
    line-height: 1;
}
.hero h1 em {
    font-style: italic;
    color: var(--palco-main);
    position: relative;
    display: inline-block;
}
.hero h1 em::after {
    content: "";
    position: absolute; inset: auto 0 -4px 0; height: 12px;
    background: var(--palco-pop);
    opacity: .45; border-radius: 50% / 80%;
    z-index: -1;
}
.eyebrow-pill {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: 8px 18px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-size: .82rem; font-weight: 600;
    letter-spacing: .05em; text-transform: uppercase;
    margin-bottom: 1.5rem;
}
.eyebrow-pill .dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: conic-gradient(var(--ind-main), var(--palco-main), var(--est-main), var(--ind-main));
}
.hero .lead {
    font-size: 1.25rem;
    color: var(--ink-soft);
    line-height: 1.55;
    max-width: 52ch;
    margin: 1.5rem 0;
}

/* ---------- Hero visual: prisma refinado (legado — quando usado em variantes) ---------- */
.hero-visual {
    position: relative;
    max-width: 580px;
    margin: 0 auto;
}
.hero-visual svg { width: 100%; height: auto; display: block; }

/* ---------- Hero split — layout integrado (sem moldura rígida) ---------- */
.hero-split {
    padding: 2.5rem 0 4rem;
    position: relative;
    overflow: hidden;
    /* Glows pastel que atravessam todo o hero (em vez de ficarem presos à moldura) */
    background:
        radial-gradient(ellipse 42% 55% at 88% 18%,  rgba(245, 200, 150, .40), transparent 65%),
        radial-gradient(ellipse 48% 60% at 95% 55%,  rgba(241, 182, 215, .38), transparent 65%),
        radial-gradient(ellipse 42% 50% at 78% 100%, rgba(169, 204, 236, .42), transparent 65%),
        linear-gradient(180deg, #ffffff 0%, #fdf8f2 100%);
}
.hero-split .container { position: relative; }

/* A grelha já não é uma grelha rígida — é apenas contexto para o texto;
   a foto é posicionada absolutamente para poder invadir e esbater no texto. */
.hero-split-grid { display: block; position: relative; }

.hero-split .hero-text {
    max-width: 620px;
    padding: 0.5rem 0;
    position: relative;
    z-index: 2;
    text-align: left;
}
.hero-split .eyebrow-pill { margin-bottom: 1.5rem; }
.hero-split h1 {
    font-size: clamp(2.2rem, 4.4vw, 3.8rem);
    line-height: 1.06;
    margin: 0;
}
.hero-split .lead {
    max-width: 48ch;
    margin: 1.25rem 0 0;
    font-size: 1.1rem;
}
.hero-split .hero-actions {
    margin-top: 2rem;
    display: flex;
    gap: .75rem;
    flex-wrap: wrap;
    justify-content: flex-start;
}

/* Foto: posicionada absolutamente, bleed para dentro do texto */
.hero-photo {
    position: absolute;
    top: 50%;
    right: -5%;
    transform: translateY(-50%);
    width: 58%;
    max-width: 680px;
    margin: 0;
    z-index: 1;
    pointer-events: none;
}
.hero-photo-faded { margin: 0; }

.hero-photo-inner {
    position: relative;
    aspect-ratio: 4 / 5;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    overflow: hidden;
    /* Máscara elíptica: centro nítido, bordas dissolvidas — recorta o sujeito organicamente */
    -webkit-mask-image: radial-gradient(
        ellipse 58% 68% at 60% 46%,
        #000 32%,
        rgba(0,0,0,.85) 55%,
        rgba(0,0,0,.35) 78%,
        transparent 92%
    );
            mask-image: radial-gradient(
        ellipse 58% 68% at 60% 46%,
        #000 32%,
        rgba(0,0,0,.85) 55%,
        rgba(0,0,0,.35) 78%,
        transparent 92%
    );
}
/* Sem overlay branco — agora a foto dissolve-se directamente no fundo do hero */
.hero-photo-faded .hero-photo-inner::before { display: none; }

.hero-photo-silhouette {
    position: absolute;
    inset: auto 0 0 0;
    width: 100%;
    height: 82%;
    display: block;
    opacity: .55;
}
.hero-photo-inner .hero-photo-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Variante ilustração com fundo transparente — sem máscara, assenta
   directamente sobre o gradiente pastel do hero. */
.hero-photo-illustration {
    width: 60%;
    max-width: 690px;
    right: -6%;
}
.hero-photo-illustration .hero-photo-inner {
    aspect-ratio: 5 / 4;
    overflow: visible;
    /* Sem máscara — o PNG já é transparente e integra-se no fundo do hero */
    -webkit-mask-image: none;
            mask-image: none;
}
.hero-photo-illustration .hero-photo-img {
    object-fit: contain;
    object-position: center;
    /* Sombra muito subtil para dar assentamento à miúda sobre o fundo */
    filter: drop-shadow(0 18px 24px rgba(26, 27, 45, .10));
}
/* Tag placeholder (só aparece enquanto não houver foto real) */
.hero-photo-tag {
    position: absolute;
    bottom: 18%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: 7px 14px;
    background: rgba(255,255,255,.85);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 500;
    color: var(--ink-soft);
    font-family: var(--font-serif);
    font-style: italic;
    border: 1px solid rgba(26,27,45,.08);
    white-space: nowrap;
}

/* Blobs decorativos — ligeiramente mais presentes para reforçar o campo colorido */
.blob {
    position: absolute; border-radius: 50%;
    filter: blur(60px);
    opacity: .45;
    z-index: 0;
    pointer-events: none;
}
.blob-1 { width: 320px; height: 320px; background: var(--ind-pop); top: -80px; right: 8%; }
.blob-2 { width: 260px; height: 260px; background: var(--palco-pop); bottom: -60px; left: -40px; opacity: .3; }
.blob-3 { width: 240px; height: 240px; background: var(--est-pop); top: 35%; right: -60px; opacity: .35; }

@media (max-width: 980px) {
    .hero-split { padding: 4rem 0 3rem; }
    .hero-photo { width: 62%; right: -10%; }
}
@media (max-width: 860px) {
    .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
    .hero-split { padding: 3rem 0 2.5rem; text-align: center; }
    .hero-split .hero-text {
        max-width: none;
        text-align: center;
        padding: 1rem 0;
        margin: 0 auto;
    }
    .hero-split .hero-actions { justify-content: center; }
    .hero-split .lead { margin-left: auto; margin-right: auto; }
    /* Na versão móvel, a foto desce para baixo do texto, sem absoluta */
    .hero-photo {
        position: relative;
        top: auto; right: auto;
        transform: none;
        width: 100%;
        max-width: 520px;
        margin: 2rem auto 0;
    }
    .hero-photo-inner {
        aspect-ratio: 4 / 3;
        -webkit-mask-image: radial-gradient(ellipse 70% 85% at 50% 50%, #000 38%, rgba(0,0,0,.7) 65%, transparent 95%);
                mask-image: radial-gradient(ellipse 70% 85% at 50% 50%, #000 38%, rgba(0,0,0,.7) 65%, transparent 95%);
    }
}

/* ---------- Botões ---------- */
.btn {
    display: inline-flex; align-items: center; gap: .5rem;
    padding: 16px 32px;
    border-radius: 999px;
    font-size: 1rem; font-weight: 600;
    text-decoration: none;
    transition: transform .15s, box-shadow .2s;
    border: 2px solid transparent;
    cursor: pointer;
    line-height: 1;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn-primary { background: var(--ink); color: #fff; box-shadow: 0 4px 0 #000; }
.btn-primary:hover { box-shadow: 0 6px 0 #000; }
.btn-outline { background: #fff; color: var(--ink); border-color: var(--ink); }
.btn-outline:hover { box-shadow: 4px 4px 0 var(--ind-main); }
.btn-arrow::after { content: "→"; font-weight: 400; }

/* ---------- 3 Dimensões ---------- */
.dimensoes {
    padding: 6rem 0;
    background: var(--cream-soft);
    position: relative;
    overflow: hidden;
}
.dimensoes::before, .dimensoes::after {
    content: ""; position: absolute; inset: 0 0 auto 0;
    height: 60px;
    background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 60' preserveAspectRatio='none'><path d='M0 60 C 300 0, 900 0, 1200 60 Z' fill='%23fcf7ee'/></svg>") no-repeat;
    background-size: 100% 60px;
}
.dimensoes::after {
    inset: auto 0 0 0; top: auto;
    transform: scaleY(-1);
}

.dim-intro { text-align: center; max-width: 720px; margin: 0 auto 3.5rem; }
.dim-intro h2 { margin-top: .5rem; }

.dim-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.dim-card {
    position: relative;
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 1.5rem 1.5rem 1.4rem;
    text-decoration: none;
    color: var(--ink);
    overflow: hidden;
    transition: transform .45s cubic-bezier(.34, 1.56, .64, 1), box-shadow .4s ease;
    transform-origin: center center;
    border: 3px solid transparent;
    min-height: 340px;
    display: flex; flex-direction: column;
    will-change: transform;
}

/* Animação idle — cada cartão "respira" / treme com timings dessincronizados */
@keyframes dim-card-idle-a {
    0%, 100% { transform: translateY(0) rotate(0); }
    25%      { transform: translateY(-4px) rotate(-0.6deg); }
    50%      { transform: translateY(-2px) rotate(0.4deg); }
    75%      { transform: translateY(-5px) rotate(-0.3deg); }
}
@keyframes dim-card-idle-b {
    0%, 100% { transform: translateY(0) rotate(0); }
    25%      { transform: translateY(-3px) rotate(0.5deg); }
    50%      { transform: translateY(-5px) rotate(-0.4deg); }
    75%      { transform: translateY(-2px) rotate(0.6deg); }
}
@keyframes dim-card-idle-c {
    0%, 100% { transform: translateY(0) rotate(0); }
    25%      { transform: translateY(-2px) rotate(-0.4deg); }
    50%      { transform: translateY(-5px) rotate(0.3deg); }
    75%      { transform: translateY(-3px) rotate(-0.5deg); }
}
.dim-grid > .dim-card:nth-child(1) { animation: dim-card-idle-a 6.5s ease-in-out infinite; }
.dim-grid > .dim-card:nth-child(2) { animation: dim-card-idle-b 5.8s ease-in-out infinite; animation-delay: -1.2s; }
.dim-grid > .dim-card:nth-child(3) { animation: dim-card-idle-c 7.1s ease-in-out infinite; animation-delay: -2.4s; }

/* Hover intensificado — pausa o idle, salta mais alto, roda mais e aplica scale */
.dim-card:hover,
.dim-grid .dim-card:hover,
.dim-card.lc-pre-reveal:hover {
    animation-play-state: paused;
    transform: translateY(-18px) rotate(-3.5deg) scale(1.025) !important;
    opacity: 1 !important;
    text-decoration: none;
    box-shadow: 0 28px 60px rgba(26, 27, 45, .22);
}
.dim-grid > .dim-card:nth-child(2):hover,
.dim-grid .dim-card:nth-child(2):hover {
    transform: translateY(-18px) rotate(3.5deg) scale(1.025) !important;
}
.dim-grid > .dim-card:nth-child(3):hover,
.dim-grid .dim-card:nth-child(3):hover {
    transform: translateY(-18px) rotate(-2deg) scale(1.025) !important;
}

@media (prefers-reduced-motion: reduce) {
    .dim-grid > .dim-card { animation: none !important; }
}

/* Número circular colorido */
.dim-card .dim-number {
    width: 44px; height: 44px;
    border-radius: 50%;
    display: grid; place-items: center;
    font-family: var(--font-serif);
    font-weight: 500;
    font-size: 1.05rem;
    color: #fff;
    margin-bottom: auto;
}

/* Labirinto SVG no topo */
.dim-card .dim-maze {
    position: absolute;
    top: 1.5rem; right: 1.5rem;
    width: 44px; height: 44px;
    opacity: .9;
    z-index: 2; /* acima do stretched-link */
}

/* Dimensão Criança */
.dim-crianca {
    background: linear-gradient(160deg, #fff 0%, #fef4e6 100%);
    border-color: var(--ind-light);
}
.dim-crianca:hover { border-color: var(--ind-main); }
.dim-crianca .dim-number { background: var(--ind-main); }
.dim-crianca h3 { color: var(--ind-deep); }

/* Dimensão Palcos */
.dim-palcos {
    background: linear-gradient(160deg, #fff 0%, #faeaf3 100%);
    border-color: var(--palco-light);
}
.dim-palcos:hover { border-color: var(--palco-main); }
.dim-palcos .dim-number { background: var(--palco-main); }
.dim-palcos h3 { color: var(--palco-deep); }

/* Dimensão Estrutura */
.dim-estrutura {
    background: linear-gradient(160deg, #fff 0%, #e8f1fa 100%);
    border-color: var(--est-light);
}
.dim-estrutura:hover { border-color: var(--est-main); }
.dim-estrutura .dim-number { background: var(--est-main); }
.dim-estrutura h3 { color: var(--est-deep); }

.dim-card h3 { margin: 1.2rem 0 .5rem; font-size: 1.45rem; }
.dim-card p { color: var(--ink-soft); margin: 0; font-size: .92rem; line-height: 1.5; }

.dim-card .dim-mini {
    display: flex; flex-wrap: wrap; gap: .3rem;
    margin-top: 1rem; padding-top: .9rem;
    border-top: 1px dashed var(--border);
    position: relative; /* z-index acima do stretched link para serem clicáveis */
    z-index: 3;
}
.dim-card .dim-mini .dim-mini-chip {
    font-size: .8rem; font-weight: 500;
    padding: 4px 12px; border-radius: 999px;
    background: rgba(0,0,0,.05);
    color: var(--ink-soft);
    text-decoration: none;
    border: 1px solid transparent;
    transition: background .2s, border-color .2s, transform .15s, box-shadow .2s;
    display: inline-block;
    line-height: 1.45;
}
.dim-card .dim-mini .dim-mini-chip:hover {
    transform: translateY(-1px);
    text-decoration: none;
}

.dim-crianca .dim-mini .dim-mini-chip { background: var(--ind-light); color: var(--ind-deep); }
.dim-palcos    .dim-mini .dim-mini-chip { background: var(--palco-light); color: var(--palco-deep); }
.dim-estrutura .dim-mini .dim-mini-chip { background: var(--est-light); color: var(--est-deep); }

.dim-crianca .dim-mini .dim-mini-chip:hover {
    background: #fff; border-color: var(--ind-main);
    box-shadow: 0 2px 8px rgba(212, 87, 42, .18);
}
.dim-palcos .dim-mini .dim-mini-chip:hover {
    background: #fff; border-color: var(--palco-main);
    box-shadow: 0 2px 8px rgba(184, 50, 128, .18);
}
.dim-estrutura .dim-mini .dim-mini-chip:hover {
    background: #fff; border-color: var(--est-main);
    box-shadow: 0 2px 8px rgba(42, 111, 181, .18);
}

/* "Stretched link" — o card inteiro continua clicável para a página da dimensão,
   mas os chips (com z-index superior) têm prioridade de clique. */
.dim-card .dim-card-link {
    position: absolute;
    inset: 0;
    z-index: 2;
    text-indent: -9999px;
    overflow: hidden;
    white-space: nowrap;
    border-radius: inherit;
}
.dim-card .dim-card-link:focus-visible {
    outline: 3px solid var(--ink);
    outline-offset: -8px;
    border-radius: inherit;
}
/* Elementos de conteúdo acima do stretched link.
   O .dim-maze é absoluto — cuidado em não lhe mudar o position aqui. */
.dim-card > .dim-number,
.dim-card > h3,
.dim-card > p,
.dim-card > .dim-arrow { position: relative; z-index: 2; }

.dim-card .dim-arrow {
    margin-top: .8rem;
    font-size: 1.3rem;
    align-self: flex-end;
    transition: transform .2s;
}
.dim-card:hover .dim-arrow { transform: translateX(6px); }

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

/* ---------- Faixa com citação / manifesto ---------- */
.manifesto {
    padding: 5rem 0;
    text-align: center;
    position: relative;
}
.manifesto .big-quote {
    font-family: var(--font-serif);
    font-size: clamp(1.8rem, 4vw, 3rem);
    line-height: 1.25;
    font-weight: 500;
    max-width: 22ch;
    margin: 0 auto;
    color: var(--ink);
}
.manifesto strong.ind   { color: var(--ind-main); background: var(--ind-light); padding: 0 8px; border-radius: 6px; font-weight: 500; font-style: italic; }
.manifesto strong.palco { color: var(--palco-main); background: var(--palco-light); padding: 0 8px; border-radius: 6px; font-weight: 500; font-style: italic; }
.manifesto strong.est   { color: var(--est-main); background: var(--est-light); padding: 0 8px; border-radius: 6px; font-weight: 500; font-style: italic; }

/* ---------- Blocos coloridos decorativos ---------- */
.color-blocks {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin: 3rem 0;
    max-width: 720px; margin-left: auto; margin-right: auto;
}
.color-blocks > div {
    aspect-ratio: 5/4;
    border-radius: var(--radius-md);
    display: grid; place-items: center;
    color: #fff;
    font-family: var(--font-serif);
    font-size: 1rem;
    text-align: center;
    padding: 1rem;
    position: relative;
    overflow: hidden;
}
.cb-1 { background: var(--ind-main); }
.cb-1::before { content: ""; position: absolute; width: 80%; height: 80%; border-radius: 50%; background: var(--ind-pop); opacity: .4; top: -20%; right: -20%; }
.cb-2 { background: var(--palco-main); }
.cb-2::before { content: ""; position: absolute; width: 120%; height: 60%; border-radius: 50%; background: var(--palco-pop); opacity: .4; bottom: -20%; left: -10%; }
.cb-3 { background: var(--est-main); }
.cb-3::before { content: ""; position: absolute; width: 90%; height: 90%; border-radius: 50%; background: var(--est-pop); opacity: .4; top: 10%; left: -40%; }
.color-blocks > div > span { position: relative; z-index: 1; }

/* ---------- Últimos conteúdos ---------- */
.latest {
    background: #fff;
    padding: 6rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.latest-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.latest-card {
    text-decoration: none;
    color: inherit;
    display: flex; flex-direction: column; gap: 1rem;
}
.latest-card-img {
    aspect-ratio: 4/3;
    border-radius: var(--radius-md);
    overflow: hidden;
    position: relative;
    border: 2px solid transparent;
    transition: transform .2s, box-shadow .2s;
    display: grid;
    place-items: center;
}
.latest-card-img .latest-drawing {
    width: 86%; height: 86%;
    object-fit: contain;
    display: block;
    position: relative; z-index: 1;
    /* sombra muito subtil para dar leve profundidade sobre pastel */
    filter: drop-shadow(0 4px 8px rgba(0,0,0,.10));
}
.latest-card-img .latest-icon {
    position: absolute;
    top: 14px; left: 14px;
    width: 40px; height: 40px;
    color: #fff;
    stroke: #fff;
    opacity: 1;
    z-index: 2;
    /* sombra preta mais marcada dá contorno e profundidade ao ícone branco */
    filter: drop-shadow(0 3px 6px rgba(0,0,0,.55)) drop-shadow(0 1px 1px rgba(0,0,0,.35));
}
/* Frames com gradient diagonal (pastel → cor profunda ~20% transparente)
   + halo luminoso no canto superior esquerdo para destacar o ícone branco.
   Dá profundidade e torna o cartão mais dinâmico / profissional. */
.latest-card.tag-ind   .latest-card-img {
    /* Laranja/pêssego ~25% mais claro que --ind-light. Fade atenuado para
       não cair num terracota tão escuro no canto inferior direito. */
    background:
        radial-gradient(circle at 18% 18%, rgba(255,255,255,.35), transparent 55%),
        linear-gradient(135deg,
            color-mix(in srgb, var(--ind-light) 68%, white) 0%,
            color-mix(in srgb, var(--ind-light) 68%, white) 55%,
            color-mix(in srgb, var(--ind-main) 70%, white) 140%);
    border-color: color-mix(in srgb, var(--ind-light) 68%, white);
}
.latest-card.tag-palco .latest-card-img {
    background:
        radial-gradient(circle at 18% 18%, rgba(255,255,255,.35), transparent 55%),
        linear-gradient(135deg, var(--palco-light) 0%, var(--palco-light) 45%, var(--palco-deep) 140%);
    border-color: var(--palco-light);
}
.latest-card.tag-est   .latest-card-img {
    background:
        radial-gradient(circle at 18% 18%, rgba(255,255,255,.35), transparent 55%),
        linear-gradient(135deg, var(--est-light) 0%, var(--est-light) 45%, var(--est-deep) 140%);
    border-color: var(--est-light);
}

/* Os dois links dentro do card: imagem e título.
   Imagem → leva para a página de Recursos filtrada pela dimensão.
   Título → leva para o recurso individual. */
.latest-card-img-link,
.latest-card-title-link {
    display: block;
    text-decoration: none;
    color: inherit;
}
.latest-card-img-link:hover .latest-card-img {
    transform: translateY(-3px);
    box-shadow: 0 14px 30px rgba(26,27,45,.12);
}
.latest-card-img-link .latest-card-img { transition: transform .2s, box-shadow .2s; }
.latest-card h4 {
    font-family: var(--font-serif);
    font-size: 1.3rem; margin: 0; line-height: 1.25;
    transition: color .15s;
}
.latest-card-title-link:hover h4 { color: var(--palco-main); }
.latest-card.tag-ind   .latest-card-title-link:hover h4 { color: var(--ind-main); }
.latest-card.tag-palco .latest-card-title-link:hover h4 { color: var(--palco-main); }
.latest-card.tag-est   .latest-card-title-link:hover h4 { color: var(--est-main); }
.latest-card p { color: var(--ink-soft); margin: 0; font-size: .95rem; }
.latest-card .cat-tag {
    font-size: .72rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .1em;
    display: inline-block; width: fit-content;
    padding: 4px 12px; border-radius: 999px;
    margin-bottom: .5rem;
}
.latest-card.tag-ind .cat-tag    { background: var(--ind-light); color: var(--ind-deep); }
.latest-card.tag-palco .cat-tag  { background: var(--palco-light); color: var(--palco-deep); }
.latest-card.tag-est .cat-tag    { background: var(--est-light); color: var(--est-deep); }

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

/* ---------- Para quem ---------- */
.para-quem {
    padding: 6rem 0;
    background: var(--cream-soft);
}
.para-quem-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-top: 2rem;
}
.quem-card {
    background: #fff;
    border-radius: var(--radius-md);
    padding: 1.5rem 1.5rem 1.6rem;
    transition: transform .25s, box-shadow .25s, border-color .25s;
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    display: block;
    border: 2px solid transparent;
}
.quem-card:hover {
    transform: translateY(-6px) rotate(-0.5deg);
    box-shadow: var(--shadow-pop);
    text-decoration: none;
    color: inherit;
}
/* Cor da borda no hover por tipo (família verde — públicos) */
a.quem-card:has(.quem-pais):hover         { border-color: #4a8c47; }
a.quem-card:has(.quem-tecnicos):hover     { border-color: #357a4a; }
a.quem-card:has(.quem-escolas):hover      { border-color: #2a6b48; }
a.quem-card:has(.quem-instituicoes):hover { border-color: #1f5538; }
.quem-arrow {
    position: absolute;
    bottom: 1rem; right: 1.2rem;
    font-size: 1.4rem;
    color: var(--ink-soft);
    opacity: .35;
    transition: transform .2s, opacity .2s;
}
.quem-card:hover .quem-arrow {
    opacity: 1;
    transform: translateX(4px);
}
.quem-icon {
    width: 48px; height: 48px;
    border-radius: 14px;
    display: grid; place-items: center;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}
/* Cards dos públicos — família verde, gradação clara → escura */
.quem-pais    { background: #d8ecd2; color: #1d4521; }
.quem-tecnicos { background: #c8dccd; color: #143524; }
.quem-escolas { background: #b8d0c2; color: #0e2c1c; }
.quem-instituicoes { background: #a8c4b4; color: #0a2818; }
.quem-invest  { background: #d8ecd2; color: #1d4521; }
.quem-card h4 { font-size: 1.1rem; margin: 0 0 .5rem; }
.quem-card p { margin: 0; font-size: .9rem; color: var(--ink-soft); }

@media (max-width: 860px) { .para-quem-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- CTA ---------- */
.cta-band {
    background: var(--ink);
    color: #fff;
    padding: 5rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-band::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><g fill='none' stroke='%23fff' stroke-width='2' stroke-opacity='0.06' stroke-linecap='round'><path d='M20 20 L100 20 L100 100 L40 100 L40 40 L80 40 L80 80'/></g></svg>");
    background-size: 160px 160px;
}
.cta-band > * { position: relative; }
.cta-band h2 { color: #fff; max-width: 22ch; margin: 0 auto 1rem; }
.cta-band p { color: rgba(255,255,255,.75); max-width: 50ch; margin: 0 auto 2rem; }
.cta-band .btn {
    background: #fff; color: var(--ink);
    box-shadow: 0 4px 0 var(--ind-main);
}
.cta-band .btn:hover { box-shadow: 0 6px 0 var(--ind-main); }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--ink);
    color: rgba(255,255,255,.72);
    padding: 4rem 0 1.5rem;
    font-size: .92rem;
    position: relative;
}
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr .8fr .8fr .8fr;
    gap: 2rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255,255,255,.1);
}
.footer-brand {
    font-family: var(--font-serif);
    color: #fff; font-size: 1.4rem; margin-bottom: .75rem;
}
.footer-grid h5 {
    color: #fff; font-family: var(--font-sans);
    font-size: .78rem; text-transform: uppercase;
    letter-spacing: .1em; margin: 0 0 1rem;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: .5rem; }
.footer-bottom {
    padding-top: 1.5rem;
    font-size: .8rem;
    color: rgba(255,255,255,.5);
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem;
}
/* Links do bloco de contacto ganham sublinhado leve para ficarem descobertos */
.footer-contact a {
    color: rgba(255,255,255,.9);
    border-bottom: 1px solid rgba(255,255,255,.2);
    text-decoration: none;
    transition: color .18s, border-color .18s;
}
.footer-contact a:hover {
    color: #fff;
    border-bottom-color: rgba(255,255,255,.7);
    text-decoration: none;
}
/* Ícones sociais */
.footer-social {
    list-style: none; padding: 0; margin: 1rem 0 0;
    display: flex; gap: .6rem;
}
.footer-social a {
    display: inline-flex; align-items: center; justify-content: center;
    width: 34px; height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,.08);
    color: rgba(255,255,255,.85);
    transition: background .18s, color .18s, transform .18s;
    text-decoration: none;
}
.footer-social a:hover {
    background: rgba(255,255,255,.18);
    color: #fff;
    transform: translateY(-1px);
    text-decoration: none;
}
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 540px) { .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; } }

/* ---------- Utilities ---------- */
.text-center { text-align: center; }

/* ---------- Wavy divider ---------- */
.wavy-divider {
    display: block;
    width: 100%;
    height: 60px;
    fill: var(--cream-bg);
}

/* ---------- Animação suave ---------- */
@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0); }
    50% { transform: translateY(-12px) rotate(2deg); }
}
.float { animation: float 6s ease-in-out infinite; }
