@layer pages {
    /* ==========================================================================
   INDEX.CSS - Estilos EXCLUSIVOS da Landing Page (index.html)
   Social Proof, Portfolio Bento Grid, Process Interactive Tabs
   ========================================================================== */

    /* 1. HERO (Index-only) */
    .hero-section {
        min-height: 100vh;
    }

    /* Transição suave/degradê do fundo do Hero para o fundo sólido do restante da página */
    #main-content {
        position: relative;
    }

    #main-content::after {
        content: '';
        position: absolute;
        bottom: -2px; /* Resolve subpixel rendering issues */
        left: 0;
        width: 100%;
        height: 200px; /* Um gradient generoso e orgânico */
        z-index: 5;
        /* Default: cor do light theme com alpha 0 */
        background: linear-gradient(to bottom, rgba(244, 247, 249, 0) 0%, var(--bg-color) 100%);
        pointer-events: none;
    }

    html.dark-theme #main-content::after {
        /* Dark theme com alpha 0 */
        background: linear-gradient(to bottom, rgba(26, 30, 38, 0) 0%, var(--bg-color) 100%);
    }

    /* 2. PORTFOLIO SECTION */
    .portfolio-section {
        padding: 80px 20px;
    }

    .portfolio-header {
        text-align: center;
        max-width: 800px;
        margin: 0 auto 60px;
    }

    .portfolio-header .section-subtitle {
        color: var(--secondary-text-color);
        margin-top: 12px;
    }

    /* --- Split container (2 painéis) --- */
    .portfolio-split {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
        max-width: 1050px;
        margin: 0 auto;
        min-height: 450px;
    }

    /* ─── Services Split & Terminal (Index) ────────────────────────── */
    .idx-devdiff-container {
        max-width: 1100px;
        margin: 4rem auto 0;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 5rem;
        align-items: center;
    }

    .idx-devdiff-text {
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
        align-items: center;
        text-align: center;
    }

    .idx-devdiff-text .cta-secondary-pill {
        width: fit-content;
    }
    
    .idx-devdiff-text h4 {
        font-family: 'Inter', sans-serif;
        font-size: clamp(1.8rem, 3.5vw, 2.8rem);
        font-weight: 800;
        line-height: 1.15;
        letter-spacing: -0.02em;
        margin: 0;
    }

    .idx-devdiff-text p {
        font-family: 'Roboto Mono', monospace;
        font-size: 1.1rem;
        line-height: 1.85;
        opacity: 0.85;
        margin: 0;
    }

    /* Estilos do Terminal copiados de formatacao.css */
    .fmt-terminal {
        border-radius: 12px;
        overflow: hidden;
        border: 1px solid rgba(255,255,255,0.1);
        box-shadow: 0 20px 60px rgba(0,0,0,0.4);
        font-family: 'Roboto Mono', monospace;
        font-size: 0.82rem;
        width: 100%;
        max-width: 520px;
    }
    .fmt-terminal__bar {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.6rem 1rem;
        background: rgba(255,255,255,0.06);
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    .fmt-terminal__bar span {
        width: 12px;
        height: 12px;
        border-radius: 50%;
        background: rgba(255,255,255,0.15);
    }
    .fmt-terminal__bar span:nth-child(1) { background: #ff5f57; cursor: pointer; transition: filter 0.2s; }
    .fmt-terminal__bar span:nth-child(1):hover { filter: brightness(0.8); }
    .fmt-terminal__bar span:nth-child(2) { background: #ffbd2e; }
    .fmt-terminal__bar span:nth-child(3) { background: #28c840; }
    .fmt-terminal__bar p {
        margin: 0 0 0 auto;
        font-size: 0.72rem;
        opacity: 0.4;
        letter-spacing: 0.05em;
    }
    .fmt-terminal__body {
        background: rgba(10,10,15,0.85);
        padding: 1.25rem 1.5rem;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        line-height: 1.7;
    }
    .fmt-terminal__body p { margin: 0; text-align: left; }
    .t-prompt { color: var(--color-primary, #3b82f6); font-weight: 700; margin-right: 0.5rem; }
    .t-cmd    { color: #e2e8f0; }
    .t-output { color: rgba(148,163,184,0.8); padding-left: 1.25rem; font-size: 0.8rem; }
    .t-ok     { color: #4ade80; }
    .t-cursor {
        display: inline-block;
        color: var(--color-primary, #3b82f6);
        animation: blink 1s step-end infinite;
    }
    @keyframes blink {
        0%, 100% { opacity: 1; }
        50%       { opacity: 0; }
    }

    /* Animação para o botão de fechar */
    @keyframes pulse-close {
        0%   { transform: scale(1); box-shadow: 0 0 0 0 rgba(255, 95, 87, 0.7); }
        70%  { transform: scale(1.15); box-shadow: 0 0 0 10px rgba(255, 95, 87, 0); }
        100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(255, 95, 87, 0); }
    }

    .app-close-btn.pulse-active {
        animation: pulse-close 1.5s infinite ease-in-out;
        z-index: 10;
    }

    .t-tip {
        font-size: 0.75rem;
        margin-top: 1rem;
        color: var(--highlight-color);
        font-weight: 700;
        opacity: 0.8;
        border-top: 1px solid rgba(255, 95, 87, 0.2);
        padding-top: 0.8rem;
        animation: tipFadeIn 0.5s ease-out forwards;
    }

    @keyframes tipFadeIn {
        from { opacity: 0; transform: translateY(5px); }
        to { opacity: 0.8; transform: translateY(0); }
    }

    /* Terminal hidden state for animation and general utility */
    .is-hidden {
        display: none !important;
    }

    .u-cursor-default {
        cursor: default !important;
    }

    @media (max-width: 900px) {
        .idx-devdiff-container {
            grid-template-columns: 1fr;
            gap: 2.5rem;
        }
    }

    /* ─── Desktop Environment Simulation ─────────────────────── */
    .desktop-environment {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        min-height: 280px;
        width: 100%;
        max-width: 520px;
    }

    /* Windows */
    .app-window {
        width: 100%;
        border-radius: 12px;
        overflow: hidden;
        border: 1px solid rgba(255,255,255,0.1);
        box-shadow: 0 20px 60px rgba(0,0,0,0.4);
        background: rgba(10,10,15,0.85); /* Terminal / window background */
        font-family: 'Roboto Mono', monospace;
        min-height: 310px;
        display: flex;
        flex-direction: column;
    }

    .app-close-btn { 
        cursor: pointer; 
        transition: filter 0.2s; 
    }
    .app-close-btn:hover { 
        filter: brightness(0.8) drop-shadow(0 0 2px red); 
    }

    /* Desktop Icons */
    .desktop-icons-grid {
        display: flex;
        gap: 20px;
        justify-content: center;
        align-items: center;
        width: 100%;
    }

    .desktop-app-icon {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
        cursor: pointer;
        padding: 12px;
        border-radius: 12px;
        transition: transform 0.3s ease, background 0.3s ease;
        text-align: center;
        background: transparent;
        border: none;
    }

    .desktop-app-icon:hover {
        background: rgba(255, 255, 255, 0.05);
        transform: translateY(-5px);
    }
    
    html.dark-theme .desktop-app-icon:hover {
        background: rgba(255, 255, 255, 0.1);
    }

    .desktop-app-icon img {
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    }

    .icon-placeholder {
        width: 50px;
        height: 50px;
        border-radius: 12px;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.5rem;
        color: #fff;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    }
    .mail-icon { background: linear-gradient(135deg, #3b82f6, #2563eb); }
    .mail-icon--gradient { background: linear-gradient(135deg, #8b5cf6, #6d28d9) !important; }
    .folder-icon { background: linear-gradient(135deg, #f59e0b, #d97706); }
    .terminal-icon { background: linear-gradient(135deg, #1e293b, #0f172a); }

    .icon-placeholder svg {
        width: 24px;
        height: 24px;
        color: #fff;
    }

    .desktop-app-icon span {
        font-family: 'Inter', sans-serif;
        font-size: 0.85rem;
        font-weight: 600;
        color: var(--text-color);
        text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    }

    /* Mail Form Inside Window */
    .app-window__body {
        padding: 1.5rem;
        color: rgba(255,255,255,0.85);
        font-size: 0.85rem;
        text-align: left;
    }

    .mail-form {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }

    .mail-form-group label {
        display: block;
        margin-bottom: 6px;
        color: var(--color-primary, #3b82f6);
        font-weight: 700;
    }

    .sys-input, .active-input {
        width: 100%;
        background: rgba(0,0,0,0.4);
        border: 1px solid rgba(255,255,255,0.1);
        padding: 8px 12px;
        border-radius: 6px;
        color: #fff;
        font-family: 'Roboto Mono', monospace;
        font-size: 0.85rem;
    }

    .active-input:focus {
        outline: none;
        border-color: var(--highlight-color);
        box-shadow: 0 0 0 2px rgba(255, 95, 87, 0.2);
    }

    .sys-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        background: #28c840;
        color: #000;
        border: none;
        padding: 10px 16px;
        font-weight: 700;
        border-radius: 6px;
        cursor: pointer;
        font-family: 'Roboto Mono', monospace;
        transition: filter 0.2s;
        margin-top: 8px;
    }
    .sys-btn:hover { filter: brightness(1.1); }

    /* Design Token Window */
    .design-body {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }

    .design-token {
        background: rgba(255,255,255,0.05);
        border: 1px solid rgba(255,255,255,0.1);
        border-radius: 8px;
        padding: 12px;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px;
        text-decoration: none;
        transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s;
    }

    a.design-token:hover {
        background: rgba(255,255,255,0.1);
        transform: translateY(-3px);
        border-color: var(--highlight-color);
    }

    .design-token .d-dot, .design-token .d-txt {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        box-shadow: inset 0 2px 4px rgba(0,0,0,0.5);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1rem;
        color: #fff;
        background: #333;
    }

    .design-token code {
        font-size: 0.70rem;
        color: #a1a1aa;
    }

    /* Token icon gradients */
    .token-icon--whatsapp { background: linear-gradient(135deg, #25D366, #128C7E) !important; }
    .token-icon--linkedin { background: linear-gradient(135deg, #0077b5, #005582) !important; }
    .token-icon--instagram { background: linear-gradient(135deg, #f09433, #bc1888) !important; }
    .token-icon--email { background: linear-gradient(135deg, #d44638, #b23121) !important; }

    .token-label {
        color: #fff !important;
        text-transform: uppercase !important;
    }

    /* Design system preview tokens */
    .d-dot--highlight { background: var(--highlight-color) !important; }
    .d-dot--bg { background: var(--bg-color) !important; }
    .d-txt--inter { font-family: 'Inter', sans-serif !important; }
    .d-txt--mono { font-family: 'Roboto Mono', monospace !important; }

    /* CTA Final section helpers */
    .cta-final-header {
        text-align: center;
        margin-bottom: 2rem;
    }

    .cta-final-app {
        max-width: 520px;
        margin: 0 auto;
    }

    /* Terminal hidden state for animation */
    .fmt-terminal__body p.term-line-hidden {
        display: none;
    }

    /* ─── White Theme for Terminals (App Windows) ────────────────────────── */
    html:not(.dark-theme) .fmt-terminal,
    html:not(.dark-theme) .app-window {
        border-color: rgba(0, 0, 0, 0.08);
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
        background: #ffffff;
    }

    html:not(.dark-theme) .fmt-terminal__bar {
        background: #f8fafc;
        border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    }

    html:not(.dark-theme) .fmt-terminal__bar p {
        color: #64748b;
        opacity: 0.9;
        font-weight: 500;
    }

    html:not(.dark-theme) .fmt-terminal__body,
    html:not(.dark-theme) .app-window__body {
        background: #ffffff;
        color: #334155;
    }

    /* Terminal Window Text Colors */
    html:not(.dark-theme) .t-cmd {
        color: #0f172a;
        font-weight: 500;
    }

    html:not(.dark-theme) .t-output {
        color: #475569;
    }

    html:not(.dark-theme) .t-ok {
        color: #059669;
        font-weight: 600;
    }

    html:not(.dark-theme) .t-tip {
        border-top-color: rgba(0, 0, 0, 0.08);
        color: var(--color-primary, #0284c7);
    }

    /* Connection Window (Redes) */
    html:not(.dark-theme) .sys-input,
    html:not(.dark-theme) .active-input {
        background: #f1f5f9;
        border: 1px solid rgba(0, 0, 0, 0.08);
        color: #0f172a;
    }

    html:not(.dark-theme) .sys-input::placeholder,
    html:not(.dark-theme) .active-input::placeholder {
        color: #94a3b8;
    }

    html:not(.dark-theme) .active-input:focus {
        border-color: #3b82f6;
        box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
    }


    
    html:not(.dark-theme) .mail-form-group label {
        color: var(--color-primary, #3b82f6);
    }

    /* Design Token Window */
    html:not(.dark-theme) .design-token {
        background: #f1f5f9;
        border-color: rgba(0, 0, 0, 0.05);
    }

    html:not(.dark-theme) a.design-token:hover {
        background: #e2e8f0;
        border-color: rgba(0, 0, 0, 0.15);
    }

    html:not(.dark-theme) .design-token code {
        color: #64748b;
    }

    html:not(.dark-theme) .token-label {
        color: #0f172a !important;
        font-weight: 600;
    }
    
    html:not(.dark-theme) .design-token .d-dot, 
    html:not(.dark-theme) .design-token .d-txt {
        box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    }

    /* ─── Web Packages Section ────────────────────────── */
    .web-packages-section {
        padding: 4rem 20px 6rem;
    }
    .web-packages-container {
        max-width: 1100px;
        margin: 0 auto;
    }
    .wp-eyebrow {
        font-family: 'Roboto Mono', monospace;
        font-size: 12px;
        font-weight: 500;
        letter-spacing: 1.5px;
        color: var(--highlight-color);
        text-align: center;
        margin-bottom: 14px;
    }
    .wp-title {
        font-family: 'Inter', sans-serif;
        font-size: 28px;
        font-weight: 500;
        color: #fff;
        text-align: center;
        margin-bottom: 12px;
    }
    .wp-subtitle {
        font-family: 'Inter', sans-serif;
        font-size: 14px;
        font-weight: 400;
        color: rgba(255, 255, 255, 0.6);
        text-align: center;
        max-width: 520px;
        margin: 0 auto 2.5rem;
    }
    .packages-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 14px;
        margin: 0 0 2rem;
    }
    .package-card {
        background: var(--container-bg-color);
        border: 1px solid var(--border-color);
        border-radius: 12px;
        padding: 1.5rem 1.25rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
        position: relative;
    }
    .package-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
        border-color: var(--highlight-color);
    }
    .package-card.highlight-pkg {
        background: rgba(var(--highlight-color-rgb), 0.06);
        border-color: rgba(var(--highlight-color-rgb), 0.45);
        box-shadow: 0 8px 24px rgba(var(--highlight-color-rgb), 0.15);
        transform: translateY(0);
        position: relative;
    }
    .package-card.highlight-pkg:hover {
        transform: translateY(-5px);
        box-shadow: 0 16px 32px rgba(var(--highlight-color-rgb), 0.2);
    }
    .pkg-badge {
        position: absolute;
        top: -10px;
        left: 50%;
        transform: translateX(-50%);
        background: var(--highlight-color);
        color: #08111C;
        font-family: 'Roboto Mono', monospace;
        font-size: 10px;
        font-weight: 500;
        letter-spacing: 1px;
        padding: 4px 12px;
        border-radius: 4px;
        white-space: nowrap;
        text-transform: uppercase;
        z-index: 2;
    }
    .pkg-header {
        margin-bottom: 0;
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .pkg-header h4 {
        font-family: 'Roboto Mono', monospace;
        font-size: 11px;
        font-weight: 500;
        color: rgba(255, 255, 255, 0.5);
        letter-spacing: 1.5px;
        text-transform: uppercase;
        margin: 0 0 12px;
        text-align: center;
    }
    .package-card.highlight-pkg .pkg-header h4 {
        color: var(--highlight-color);
    }
    .pkg-price-prefix {
        font-family: 'Roboto Mono', monospace;
        font-size: 11px;
        font-weight: 400;
        color: rgba(255, 255, 255, 0.4);
        margin: 0 0 4px;
        text-align: center;
    }
    .pkg-price {
        font-family: 'Inter', sans-serif;
        font-size: 26px;
        font-weight: 500;
        color: #fff;
        margin: 0 0 10px;
        line-height: 1;
        text-align: center;
    }
    .pkg-desc {
        font-family: 'Inter', sans-serif;
        font-size: 12px;
        font-weight: 400;
        color: rgba(255, 255, 255, 0.65);
        line-height: 1.5;
        margin: 10px 0 0;
        text-align: center;
    }
    .wp-cta-wrapper {
        text-align: center;
        margin-top: 2rem;
    }
    .wp-cta-pill {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        background: var(--highlight-color);
        color: #08111C;
        font-family: 'Inter', sans-serif;
        font-size: 13px;
        font-weight: 500;
        text-decoration: none;
        padding: 12px 24px;
        border-radius: 30px;
        transition: background 0.2s ease;
    }
    .wp-cta-pill:hover {
        filter: brightness(1.1);
    }
    .wp-signature-note {
        font-family: 'Roboto Mono', monospace;
        font-size: 12px;
        font-weight: 400;
        color: rgba(255, 255, 255, 0.45);
        margin: 14px 0 0;
        text-align: center;
    }
    .wp-signature-highlight {
        color: var(--highlight-color);
    }

    @media (max-width: 1024px) {
        .packages-grid {
            grid-template-columns: repeat(3, 1fr);
        }
        .package-card.highlight-pkg {
            transform: translateY(0);
        }
        .package-card.highlight-pkg:hover {
            transform: translateY(-5px);
        }
    }
    
    @media (max-width: 640px) {
        .packages-grid {
            grid-template-columns: 1fr;
        }
        .web-packages-section {
            padding: 2rem 1rem;
        }
        .wp-title {
            font-size: 22px;
        }
    }

    /* ─── White Theme overrides — Web Packages Section ─── */
    html:not(.dark-theme) .wp-title {
        color: var(--text-color);
    }
    html:not(.dark-theme) .wp-subtitle {
        color: var(--secondary-text-color);
    }
    html:not(.dark-theme) .pkg-header h4 {
        color: var(--secondary-text-color);
    }
    html:not(.dark-theme) .pkg-price-prefix {
        color: var(--secondary-text-color);
    }
    html:not(.dark-theme) .pkg-price {
        color: var(--text-color);
    }
    html:not(.dark-theme) .pkg-desc {
        color: var(--secondary-text-color);
    }
    html:not(.dark-theme) .wp-signature-note {
        color: var(--secondary-text-color);
    }
    html:not(.dark-theme) .package-card.highlight-pkg .pkg-header h4 {
        color: var(--highlight-color);
    }

    /* ─── Escopos de Consultoria Preview (responde ao chat filter) ─────── */
    .mkt-scopes-preview {
        padding: 0 20px 5rem;
    }

    .mkt-scopes-preview__inner {
        max-width: 1100px;
        margin: 0 auto;
        border-top: 1px dashed var(--border-color);
        padding-top: 2rem;
    }

    .mkt-scopes-preview__header {
        margin-bottom: 2rem;
    }

    .mkt-scopes-preview__eyebrow {
        font-family: 'Roboto Mono', monospace;
        font-size: 12px;
        font-weight: 500;
        color: var(--highlight-color);
        letter-spacing: 1.5px;
        margin: 0 0 12px;
    }

    .mkt-scopes-preview__title {
        font-family: 'Inter', sans-serif;
        font-size: clamp(1.4rem, 3vw, 2rem);
        font-weight: 700;
        color: var(--text-color);
        margin: 0;
        line-height: 1.25;
        letter-spacing: -0.02em;
    }

    .mkt-scopes-preview__grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
        margin-bottom: 1.75rem;
    }

    .mkt-scope-mini {
        position: relative;
        background: var(--container-bg-color);
        border: 1px solid var(--border-color);
        border-radius: 12px;
        padding: 20px 22px;
        display: flex;
        flex-direction: column;
        gap: 6px;
        transition: border-color 0.3s ease, box-shadow 0.3s ease;
    }

    /* Estado ativo: destacado pelo filtro do chat */
    .mkt-scope-mini--active {
        border-color: var(--highlight-color);
        box-shadow: 0 0 0 1px var(--highlight-color), 0 4px 24px rgba(var(--highlight-color-rgb), 0.12);
    }

    /* Destaque visual permanente do card featured (Visibilidade) */
    .mkt-scope-mini--featured {
        border-color: color-mix(in srgb, var(--highlight-color) 40%, transparent);
    }

    .mkt-scope-mini--featured.mkt-scope-mini--active {
        border-color: var(--highlight-color);
        box-shadow: 0 0 0 1px var(--highlight-color), 0 6px 32px rgba(var(--highlight-color-rgb), 0.18);
    }

    .mkt-scope-mini__badge {
        position: absolute;
        top: -11px;
        left: 50%;
        transform: translateX(-50%);
        background: var(--highlight-color);
        color: #fff;
        font-family: 'Roboto Mono', monospace;
        font-size: 10px;
        font-weight: 700;
        letter-spacing: 1.5px;
        padding: 3px 10px;
        border-radius: 999px;
        white-space: nowrap;
    }

    .mkt-scope-mini__num {
        font-family: 'Roboto Mono', monospace;
        font-size: 10px;
        font-weight: 400;
        letter-spacing: 1.5px;
        color: var(--secondary-text-color);
        text-transform: uppercase;
    }

    /* Destaque da cor do número no featured e quando ativo */
    .mkt-scope-mini--featured .mkt-scope-mini__num,
    .mkt-scope-mini--active .mkt-scope-mini__num {
        color: var(--highlight-color);
    }

    .mkt-scope-mini__name {
        font-family: 'Inter', sans-serif;
        font-size: 1.1rem;
        font-weight: 700;
        color: var(--text-color);
        margin: 0;
        line-height: 1.2;
    }

    .mkt-scope-mini__tag {
        font-family: 'Inter', sans-serif;
        font-size: 0.82rem;
        color: var(--secondary-text-color);
        margin: 0;
    }

    .mkt-scopes-preview__footer {
        display: flex;
        justify-content: flex-end;
    }

    @media (max-width: 640px) {
        .mkt-scopes-preview__grid {
            grid-template-columns: 1fr;
        }
    }

    /* ─── Visibility & Direcionamento Section ────────────────────────── */
    .visibility-section {
        padding: 4rem 20px 2rem;
    }

    .visibility-wrapper-relative {
        max-width: 1100px;
        margin: 0 auto;
    }
    .visibility-split {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 5rem;
        align-items: start;
    }

    .visibility-left {
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
    }

    .visibility-filters {
        display: flex;
        gap: 8px;
        flex-wrap: wrap;
    }

    .vfilter-btn {
        background: transparent;
        border: 1px solid var(--border-color);
        color: var(--secondary-text-color);
        padding: 8px 16px;
        border-radius: 999px;
        cursor: pointer;
        font-family: 'Inter', sans-serif;
        font-weight: 600;
        font-size: 0.85rem;
        transition: all 0.3s ease;
        white-space: nowrap;
        flex: 1 1 auto;
        text-align: center;
    }

    .vfilter-btn:hover,
    .vfilter-btn.active {
        background: var(--highlight-color);
        color: #fff;
        border-color: var(--highlight-color);
    }

    .visibility-chat-container {
        background: var(--container-bg-color);
        border: 1px solid var(--border-color);
        border-radius: 16px;
        padding: 24px;
        min-height: 280px;
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        box-shadow: var(--card-shadow);
        overflow: hidden;
    }

    .vchat-messages {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }

    .vchat-bubble {
        max-width: 85%;
        padding: 14px 18px;
        border-radius: 18px;
        font-size: 0.95rem;
        line-height: 1.45;
        font-family: 'Inter', sans-serif;
        animation: message-in 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
        opacity: 0;
        transform: translateY(10px);
    }

    .vchat-bubble.left {
        align-self: flex-start;
        background: rgba(128, 128, 128, 0.1);
        color: var(--text-color);
        border-bottom-left-radius: 4px;
    }

    /* O tema light e dark cuida do var(--highlight-color) -> azul / vermelho */
    .vchat-bubble.right {
        align-self: flex-end;
        background: var(--highlight-color);
        color: #fff;
        border-bottom-right-radius: 4px;
    }

    @keyframes message-in {
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    .visibility-right {
        display: flex;
        flex-direction: column;
        gap: 1.5rem;
    }

    .visibility-right > .cta-secondary-pill {
        width: fit-content;
        align-self: center;
    }

    .visibility-title {
        font-family: 'Inter', sans-serif;
        font-size: clamp(2rem, 3.5vw, 2.8rem);
        font-weight: 800;
        line-height: 1.15;
        letter-spacing: -0.02em;
        margin: 0;
    }

    .visibility-copy {
        font-family: 'Roboto Mono', monospace;
        font-size: 1.1rem;
        line-height: 1.85;
        opacity: 0.85;
        margin: 0;
        color: var(--secondary-text-color);
    }

    @media (max-width: 900px) {
        .visibility-split {
            grid-template-columns: 1fr;
            gap: 2rem;
        }
        
        .visibility-right {
            order: -1; /* Mover o texto para cima no mobile */
        }

        .visibility-right > .cta-secondary-pill {
            width: fit-content;
        }

        .visibility-chat-container {
            min-height: 320px;
        }
        
        .visibility-section {
            padding: 2rem 20px 4rem;
        }
    }

    /* ═══ PAINEL ESQUERDO — Bento Grid de Projetos ═══ */
    .projects-panel {
        display: grid;
        grid-template-columns: 1fr 1fr 1fr;
        grid-template-rows: 1fr 1fr;
        gap: 12px;
    }

    .pcard--1 {
        grid-column: 1;
        grid-row: 1 / 3;
    }

    .pcard--2 {
        grid-column: 2;
        grid-row: 1;
    }

    .pcard--3 {
        grid-column: 3;
        grid-row: 1;
    }

    .pcard--4 {
        grid-column: 2 / 4;
        grid-row: 2;
    }

    .pcard {
        position: relative;
        border-radius: 20px;
        overflow: hidden;
        border: 1px solid var(--border-color);
        background: var(--container-bg-color);
        display: block;
        text-decoration: none;
        transition: transform 0.35s cubic-bezier(.16, 1, .3, 1), box-shadow 0.35s ease;
        box-shadow: inset 0 0 0 1px var(--border-color);
    }

    .pcard:hover {
        transform: translateY(-5px);
        box-shadow: inset 0 0 0 1px var(--border-color), 0 20px 50px rgba(0, 0, 0, 0.18);
    }

    .pcard img {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.45s cubic-bezier(.16, 1, .3, 1);
    }

    .pcard:hover img {
        transform: scale(1.04);
    }

    /* Troca de thumbnail por tema */
    html.dark-theme .pcard--1 img {
        content: url('../../imagens/fotos/variants/yancode_notion-dark.webp');
    }

    html.dark-theme .pcard--3 img {
        content: url('../../imagens/thumbnails/conexaorosario-dark.webp');
    }

    html.dark-theme .pcard--4 img {
        content: url('../../imagens/thumbnails/clinicasantoestevao-dark.webp');
    }

    html.dark-theme #pcard-academia img {
        object-position: center 60%;
    }

    #pcard-academia img {
        object-position: center 60%;
    }

    /* GymBrasil — usa o hero do projeto como background layer nos dois temas */
    html:not(.dark-theme) #pcard-gymbrasil {
        background: #f4f7f9;
    }

    #pcard-gymbrasil .pcard-bg-layer {
        background-image:
            linear-gradient(rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.5)),
            url('/GymBrasil/assets/images/hero/hero.png');
        opacity: 1;
        inset: -4px;
        filter: blur(1px);
    }

    html.dark-theme #pcard-gymbrasil .pcard-bg-layer {
        background-image:
            linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
            url('/GymBrasil/assets/images/hero/hero.png');
        opacity: 1;
        inset: -4px;
        filter: blur(1px);
    }

    #pcard-gymbrasil:hover .pcard-bg-layer {
        transform: scale(1.08);
    }

    #pcard-gymbrasil .pcard__overlay {
        padding: 22px 14px 12px;
        background: linear-gradient(to top,
            rgba(0, 0, 0, 0.60) 0%,
            rgba(0, 0, 0, 0.25) 45%,
            transparent 75%);
        color: #fff;
    }

    #pcard-gymbrasil .pcard__title {
        color: inherit;
    }

    #pcard-gymbrasil .pcard-icon-layer {
        align-items: center;
        justify-content: center;
    }

    #pcard-gymbrasil .pcard-icon-layer .pcard-gymbrasil-icon {
        width: 82px !important;
        height: auto !important;
        max-width: 56% !important;
        max-height: 56% !important;
        object-fit: contain !important;
        transform: none !important;
        mix-blend-mode: multiply;
    }

    #pcard-gymbrasil:hover .pcard-gymbrasil-icon {
        transform: scale(1.06) !important;
    }

    /* Hover layer — highlight-color sobe na base, cobrindo só a área do título */
    .pcard::before {
        content: '';
        position: absolute;
        inset: 0;
        z-index: 1;
        background: linear-gradient(to top,
                var(--highlight-color) 0%,
                rgba(0, 0, 0, 0) 38%);
        opacity: 0;
        transition: opacity 0.45s ease;
    }

    .pcard:hover::before {
        opacity: 1;
    }

    /* Garantir que o card Academia siga o padrão de cores global */
    #pcard-academia {
        background: var(--container-bg-color) !important;
    }

    #pcard-academia::before {
        background: linear-gradient(to top,
                var(--highlight-color) 0%,
                rgba(0, 0, 0, 0) 38%) !important;
    }

    /* Overlay permanente — degradê suave apenas na base, próximo ao título */
    .pcard__overlay {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 2;
        padding: 36px 16px 14px;
        /* Sem backdrop-filter: cria borda retangular visível ("corte sólido") */
        background: linear-gradient(to top,
                rgba(0, 0, 0, 0.78) 0%,
                rgba(0, 0, 0, 0.45) 35%,
                rgba(0, 0, 0, 0.12) 60%,
                transparent 80%);
        color: #fff;
    }

    .pcard__title {
        font-size: 0.9rem;
        font-weight: 700;
        margin: 0;
        color: #fff;
    }

    .portfolio-action {
        text-align: center;
        margin-top: 50px;
        display: flex;
        justify-content: center;
    }

    /* ═══ PAINEL DIREITO — Bento Grid de Vídeo ═══ */
    .video-panel {
        display: grid;
        grid-template-columns: 2fr 3fr;
        grid-template-rows: 1fr 1fr;
        gap: 12px;
    }

    .mcard--top {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .mcard--bl {
        grid-column: 1;
        grid-row: 2;
    }

    .mcard--br {
        grid-column: 2;
        grid-row: 2;
    }

    .mcard {
        position: relative;
        border-radius: 20px;
        overflow: hidden;
        border: 1px solid var(--border-color);
        background: var(--container-bg-color); /* Padronizado com .pcard */
        transition: transform 0.35s cubic-bezier(.16, 1, .3, 1), box-shadow 0.35s ease;
        box-shadow: inset 0 0 0 1px var(--border-color);
    }

    .mcard:hover {
        transform: translateY(-5px);
        box-shadow: inset 0 0 0 1px var(--border-color), 0 20px 50px rgba(0, 0, 0, 0.25);
    }

    .mcard__video {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

    /* Posições split — cada card exibe uma região diferente do frame */
    .mcard--top .mcard__video {
        object-position: center 20%;
    }

    .mcard--bl .mcard__video {
        object-position: left 70%;
    }

    .mcard--br .mcard__video {
        object-position: right 75%;
    }

    /* Slideshow card (bottom-left) */
    .slides-container {
        position: relative;
        overflow: hidden;
    }

    .slides-track {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
    }

    .slide-img {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        opacity: 0;
        animation: mcardFade 12s infinite;
    }

    .slide-img:nth-child(1) {
        animation-delay: -1s;
    }

    .slide-img:nth-child(2) {
        animation-delay: 3s;
    }

    .slide-img:nth-child(3) {
        animation-delay: 7s;
    }

    @keyframes mcardFade {
        0% {
            opacity: 0;
        }

        8.33%,
        33.33% {
            opacity: 1;
        }

        41.66%,
        100% {
            opacity: 0;
        }
    }

    /* Conteúdo (label + CTA) do card bottom-right */
    .mcard__content {
        position: absolute;
        inset: 0;
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        padding: 20px;
        background: linear-gradient(to top, rgba(0, 0, 0, 0.72) 0%, transparent 60%);
        color: #fff;
    }

    .mcard__icon {
        font-size: 1rem;
        opacity: 0.7;
        margin-bottom: 6px;
    }

    .mcard__label {
        font-size: 0.8rem;
        font-weight: 700;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        opacity: 0.85;
        margin-bottom: 12px;
    }

    .mcard__cta {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        font-size: 0.8rem;
        font-weight: 700;
        color: #fff;
        text-decoration: none;
        background: rgba(255, 255, 255, 0.15);
        -webkit-backdrop-filter: blur(6px);
        backdrop-filter: blur(6px);
        border: 1px solid rgba(255, 255, 255, 0.3);
        padding: 7px 14px;
        border-radius: 999px;
        width: fit-content;
        transition: background 0.3s ease, border-color 0.3s ease;
    }

    .mcard__cta:hover {
        background: rgba(255, 255, 255, 0.25);
        border-color: rgba(255, 255, 255, 0.5);
    }

    /* 2.1 CUSTOM HERO CARD ANIMADO (bottom-right) */
    .mcard.custom-hero-card {
        background: transparent;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
    }

    .custom-hero-card .hero-bg-layer {
        position: absolute;
        inset: 0;
        background-image: url('../../imagens/backgrounds/hero-bg-light.webp');
        background-size: cover;
        background-position: center;
        opacity: 0.6;
        transition: transform 0.6s ease, opacity 0.6s ease;
        z-index: 0;
    }

    html.dark-theme .custom-hero-card .hero-bg-layer {
        background-image: url('../../imagens/backgrounds/hero-bg-dark.webp');
        opacity: 0.4;
    }

    .custom-hero-card:hover .hero-bg-layer,
    .custom-hero-card:focus .hero-bg-layer {
        transform: scale(1.05);
        opacity: 0.1;
    }

    html.dark-theme .custom-hero-card:hover .hero-bg-layer,
    html.dark-theme .custom-hero-card:focus .hero-bg-layer {
        opacity: 0.15;
    }

    .custom-hero-card .logo-box {
        position: absolute;
        z-index: 2;
        transition: transform 0.5s cubic-bezier(0.25, 1, 0.5, 1);
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .custom-hero-card .logo-img {
        width: 60px;
        height: 60px;
        content: url('../../imagens/icons/xicon-dark.png');
        filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
    }

    html.dark-theme .custom-hero-card .logo-img {
        content: url('../../imagens/icons/xicon.webp');
        filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.3));
    }

    .custom-hero-card .text-box {
        position: absolute;
        z-index: 1;
        opacity: 0;
        transform: translateX(20px);
        transition: all 0.5s cubic-bezier(0.25, 1, 0.5, 1);
        pointer-events: none;
        max-width: 240px;
        padding-left: 60px;
    }

    .custom-hero-card .text-box p {
        margin: 0;
        font-size: 0.95rem;
        font-weight: 600;
        line-height: 1.5;
        color: var(--text-color);
        /* text-wrap: balance removed for better compatibility */
    }

    .custom-hero-card:hover .logo-box,
    .custom-hero-card:focus .logo-box,
    .custom-hero-card:active .logo-box {
        transform: translateX(-90px);
    }

    .custom-hero-card:hover .text-box,
    .custom-hero-card:focus .text-box,
    .custom-hero-card:active .text-box {
        opacity: 1;
        transform: translateX(30px);
    }

    /* 3b. INLINE STYLE REPLACEMENTS */
    .process-description {
        color: var(--text-color);
        margin-bottom: 50px;
        max-width: 800px;
        font-size: 1.1rem;
        line-height: 1.8;
    }

    .services-section .section-subtitle {
        margin-bottom: 60px;
    }

    /* 4. RESPONSIVE - INDEX ONLY */
    @media (max-width: 900px) {

        /* Portfolio responsive */
        .portfolio-split {
            grid-template-columns: 1fr;
        }

        .projects-panel {
            order: 1;
            grid-template-columns: 1fr 1fr;
            grid-template-rows: 155px 155px 190px;
        }

        .pcard--1 {
            grid-column: 1;
            grid-row: 1 / 3;
        }

        .pcard--2 {
            grid-column: 2;
            grid-row: 1;
        }

        .pcard--2 img {
            object-position: center 20%;
        }

        .pcard--3 {
            grid-column: 2;
            grid-row: 2;
        }

        .pcard--3 img {
            object-position: center 20%;
        }

        .pcard--4 {
            grid-column: 1 / 3;
            grid-row: 3;
        }

        .pcard--4 img {
            object-position: center top;
        }

        .video-panel {
            order: 2;
            min-height: 340px;
        }

        /* Ajustes Mobile do Card Hero Customizado */
        .custom-hero-card .logo-img {
            width: 35px;
            height: 35px;
        }

        .custom-hero-card .text-box {
            padding-left: 45px;
            max-width: 170px;
        }

        .custom-hero-card .text-box p {
            font-size: 0.70rem;
        }

        .custom-hero-card:hover .logo-box,
        .custom-hero-card:focus .logo-box,
        .custom-hero-card:active .logo-box {
            transform: translateX(-70px);
        }

        .custom-hero-card:hover .text-box,
        .custom-hero-card:focus .text-box,
        .custom-hero-card:active .text-box {
            transform: translateX(20px);
        }

        /* Process responsive */
        .process-split-wrapper {
            grid-template-columns: 1fr;
            gap: 30px;
        }

        .process-nav {
            flex-direction: row;
            overflow-x: auto;
            padding-bottom: 10px;
            justify-content: flex-start;
            gap: 8px;
            -ms-overflow-style: none; /* IE e Edge */
        }

        @supports (scrollbar-width: none) {
            .process-nav {
                scrollbar-width: none;
            }
        }

        /* Fallback para Safari e versões do Chrome < 121 */
        .process-nav::-webkit-scrollbar {
            display: none;
        }

        .process-line,
        .process-line-active {
            display: none;
        }

        .process-step-btn {
            flex-direction: column;
            text-align: center;
            padding: 8px 5px;
            gap: 8px;
            min-width: 70px;
        }

        .process-step-btn h4 {
            font-size: 0.8rem;
            display: none;
        }

        .process-step-btn.active h4,
        .process-step-btn.active-path h4 {
            display: block;
            font-size: 0.75rem;
        }

        .step-icon-wrapper {
            width: 45px;
            height: 45px;
        }

        .process-display-area {
            min-height: 200px;
            padding: 30px;
        }

        .process-content-panel h3 {
            font-size: 1.5rem;
        }
    }

    /* =========================================
       SCROLL SEQUENCE INTRO
       ========================================= */
    .scroll-sequence-section {
        height: 300vh; /* 3 screens of scrolling to complete animation */
        position: relative;
        background: transparent;
    }

    .scroll-sequence-sticky {
        position: sticky;
        top: 0;
        height: 100vh;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        overflow: hidden;
        width: 100%;
    }

    .scroll-sequence-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        width: 90%;
        max-width: 1000px;
    }

    .word-group {
        display: flex;
        flex-direction: column;
        gap: 0.1rem;
        margin-bottom: 2rem;
    }

    .word-group span {
        font-family: 'Inter', sans-serif;
        font-weight: 800; /* Bold/ExtraBold */
        font-size: 6rem; /* High-end large typography */
        line-height: 1.05;
        letter-spacing: -0.04em;
        opacity: 0;
        transform: translateY(50px) scale(0.95);
        color: var(--text-color);
        will-change: opacity, transform;
    }

    .phrase-group {
        min-height: 3rem;
        max-width: 600px;
        position: relative;
    }

    .typewriter-phrase {
        font-family: 'Roboto Mono', monospace;
        font-size: 1.25rem;
        font-weight: 400;
        line-height: 1.5;
        color: var(--secondary-text-color, #a1a1aa);
        background: linear-gradient(90deg, var(--text-color), var(--secondary-text-color));
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        opacity: 0;
        transform: translateY(20px);
        will-change: opacity, transform;
    }

    /* Reduz o gap entre o Scroll-Sequence e a seção Servicos, 
       cobrindo o espaço vazio deixado pela height de 100vh do sticky */
    .services-section {
        margin-top: -35vh;
        padding-top: 60px;
        padding-bottom: 60px;
        position: relative;
        z-index: 10;
        background-color: var(--bg-color);
        box-shadow: 0 -30px 40px var(--bg-color); /* suaviza a transição de cor */
    }

    @media (max-width: 900px) {
        .services-section {
            margin-top: -35vh; /* Ampliado para cobrir corretamente o subtitle da sequência animada */
        }

        .scroll-sequence-section {
            height: 250vh; /* Reduces scrolling padding on tablet */
        }
        .word-group span {
            font-size: 4rem;
        }
        .typewriter-phrase {
            font-size: 1.1rem;
        }
    }

    @media (max-width: 480px) {
        .services-section {
            margin-top: -32vh; /* Cobertura ampliada para sumir com o subtitle no mobile */
        }
        .scroll-sequence-section {
            height: 180vh; /* Significante reduction for mobile devices, making it much faster to scroll */
        }
        .word-group span {
            font-size: 3rem;
        }
        .typewriter-phrase {
            font-size: 0.95rem;
        }
    }

    /* ─── CTA Final Section ─────────────────────── */
    .cta-final-section {
        padding: 4rem 20px 8rem;
        position: relative;
        z-index: 10;
    }
    
    .cta-final-container {
        max-width: 1200px;
        margin: 0 auto;
    }

    @media (max-width: 768px) {
        .cta-final-section {
            padding: 2rem 20px 6rem;
        }
    }
}
