@layer sections {
    /* ==========================================================================
   SECTIONS.CSS - Layouts de seção compartilhados entre múltiplas páginas
   Hero, Services Grid, Process (base), Skills, About, FAQ,
   Interactive Wrapper, Seamless Transitions
   ========================================================================== */

    /* 1. LOGOS CONTAINER (Shared: index, servicos-ia, servicos-web) */
    .logos-container {
        display: flex;
        justify-content: center;
        gap: 40px;
        flex-wrap: wrap;
        font-size: 1.8rem;
        color: var(--secondary-text-color);
        opacity: 0.6;
        margin-top: 25px;
    }

    .logos-container i:hover {
        color: var(--highlight-color);
        opacity: 1;
        transform: scale(1.1);
        transition: 0.3s;
    }

    /* 2. HERO SECTION */
    .hero-section {
        min-height: 85vh;
        display: flex;
        justify-content: center;
        align-items: center;
        text-align: center;
        padding: 120px 20px 80px;
        position: relative;
        overflow: hidden;
        background-color: var(--bg-color);
    }

    .hero-background-image {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-image: var(--hero-bg);
        background-size: cover;
        background-position: center;
        z-index: 0;
        transition: background-image var(--transition-speed) ease;
    }

    .hero-glass-overlay {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(244, 247, 249, 0.5);
        -webkit-backdrop-filter: blur(12px);
        backdrop-filter: blur(12px);
        z-index: 1;
        transition: background-color var(--transition-speed) ease;
    }

    html.dark-theme .hero-glass-overlay {
        background-color: rgba(26, 30, 38, 0.6);
    }

    .interactive-mouse-effect {
        isolation: isolate;
    }

    .hero-light-effect {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        z-index: 2;
        background: radial-gradient(600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(0, 123, 255, 0.16), transparent 40%);
        pointer-events: none;
    }

    html.dark-theme .hero-light-effect {
        background: radial-gradient(600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(var(--highlight-color-rgb), 0.10), transparent 40%);
    }

    .hero-content {
        position: relative;
        z-index: 3;
        max-width: 900px;
        margin: 0 auto;
    }

    .hero-content h1 {
        font-size: 1.2rem;
        color: var(--highlight-color);
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 2px;
        margin-bottom: 15px;
    }

    .hero-content h2 {
        font-family: var(--font-titles);
        font-size: 3.5rem;
        line-height: 1.1;
        margin-bottom: 25px;
        font-weight: 800;
        color: var(--text-color);
    }

    .hero-content p {
        font-size: 1.2rem;
        color: var(--secondary-text-color);
        margin-bottom: 40px;
        max-width: 700px;
        margin: 0 auto 40px;
    }

    /* 2. SERVICES SECTION (Grid Layout) */
    .services-section {
        padding: 100px 20px;
        text-align: center;
    }

    .services-wrapper-relative {
        position: relative;
        width: 100%;
        max-width: 1150px;
        margin: 0 auto;
    }

    .services-container {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 30px;
    }

    /* 3. PROCESS SECTION (Base Container) */
    .process-section {
        padding: 100px 20px;
        background-color: var(--bg-color);
    }

    .process-container {
        max-width: 1100px;
        margin: 0 auto;
    }

    /* 4. SKILLS SECTION */
    .skills-section {
        padding: 80px 20px;
        background-color: var(--container-bg-color);
        border-top: 1px solid var(--border-color);
        border-bottom: 1px solid var(--border-color);
    }

    .skills-container {
        max-width: 900px;
        margin: 0 auto;
    }

    .skills-filters {
        display: flex;
        justify-content: center;
        gap: 15px;
        margin-bottom: 50px;
        flex-wrap: wrap;
    }

    .skills-grid-cards {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 20px;
    }

    /* 5. ABOUT SECTION */
    .about-section {
        padding: 80px 20px;
    }

    .about-container {
        max-width: 1000px;
        margin: 0 auto;
        display: flex;
        gap: 80px;
        align-items: stretch;
    }

    .about-text {
        flex: 1;
        display: flex;
        flex-direction: column;
    }

    .about-content-inner {
        flex: 1;
        display: flex;
        flex-direction: column;
        justify-content: center;
        width: 100%;
    }

    .about-text p {
        font-size: 1.15rem;
        line-height: 1.9;
        margin-bottom: 10px;
        color: var(--secondary-text-color);
    }

    .about-buttons-container {
        margin-top: 10px;
        /* Reduzi o margin por padrão agora */
        display: flex;
        gap: 8px;
        flex-wrap: wrap;
        width: 100%;
    }

    .about-buttons-container .cta-button {
        flex: 1;
        justify-content: center;
        text-align: center;
        white-space: nowrap;
    }

    .about-image-wrapper {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
        max-width: 500px;
    }

    .about-image-wrapper .about-content-inner {
        gap: 0;
    }

    .about-image-wrapper>.glowing-border-wrapper {
        width: 100%;
    }

    .about-image-wrapper .about-me-extra-btn {
        margin-top: 10px;
        /* Reduzi o margin por padrão agora */
    }

    .about-me-extra-btn {
        margin-top: auto;
        width: 100%;
        justify-content: center;
    }

    .about-image img,
    .about-image-wrapper img {
        width: 100%;
        height: 100%;
        aspect-ratio: 3 / 4;
        object-fit: cover;
        border-radius: 12px;
        box-shadow: var(--card-shadow);
        border: 1px solid var(--border-color);
        transition: opacity 0.3s ease;
    }

    /* 6. FAQ SECTION */
    .about-actions {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 15px;
        margin-top: 40px;
        padding: 0 20px;
    }

    .about-actions a {
        min-width: 250px;
    }

    .faq-section {
        padding: 64px 20px;
        background-color: var(--container-bg-color);
        border-top: 1px solid var(--border-color);
    }

    .faq-container {
        max-width: 800px;
        margin: 0 auto;
    }

    .faq-wrapper {
        margin-top: 40px;
        display: flex;
        flex-direction: column;
        gap: 15px;
    }

    /* 7. INTERACTIVE BG MODULES */
    .section-bg-placeholder {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 0;
        background-image: url('../imagens/hero-bg-light.webp');
        background-size: cover;
        background-position: center;
        opacity: 0.4;
    }

    html.dark-theme .section-bg-placeholder {
        background-image: url('../imagens/hero-bg-dark.webp');
        opacity: 0.3;
    }

    .interactive-section {
        position: relative;
        overflow: hidden;
    }

    .interactive-section>.fade-in,
    .interactive-section>[class*="container"],
    .interactive-section>.content-wrapper {
        position: relative;
        z-index: 5;
    }

    /* 8. UNIFIED WRAPPER (Seamless Transitions) */
    .interactive-wrapper {
        position: relative;
        overflow: hidden;
        width: 100%;
        background-color: var(--bg-color);
    }

    .interactive-wrapper .hero-glass-overlay {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        pointer-events: none;
    }

    .interactive-wrapper .portfolio-section,
    .interactive-wrapper .faq-section {
        background: transparent !important;
        background-color: transparent !important;
        border: none !important;
        box-shadow: none !important;
        position: relative;
        z-index: 5;
        margin: 0;
    }

    .interactive-wrapper .faq-section {
        margin-top: -2px !important;
        padding-top: 60px;
    }

    .interactive-wrapper .portfolio-section {
        padding-top: 80px;
        padding-bottom: 60px;
    }

    /* Masks for Seamless Transitions */
    .interactive-wrapper::before,
    .interactive-wrapper::after {
        content: '';
        position: absolute;
        left: 0;
        width: 100%;
        height: 150px;
        z-index: 3;
        pointer-events: none;
    }

    .interactive-wrapper::before {
        top: 0;
        background: linear-gradient(to bottom, var(--bg-color) 0%, rgba(26, 30, 38, 0) 100%);
    }

    .interactive-wrapper::after {
        bottom: 0;
        background: linear-gradient(to bottom, rgba(26, 30, 38, 0) 0%, var(--bg-color) 100%);
    }

    html.dark-theme .interactive-wrapper::before {
        background: linear-gradient(to bottom, var(--bg-color) 0%, rgba(244, 247, 249, 0) 100%);
    }

    html.dark-theme .interactive-wrapper::after {
        background: linear-gradient(to bottom, rgba(244, 247, 249, 0) 0%, var(--bg-color) 100%);
    }

    .interactive-wrapper .portfolio-section {
        padding-top: 80px;
    }

    .interactive-wrapper .faq-section {
        padding-bottom: 80px;
    }

    /* 9. SHARED UTILITY CLASSES */

    /* Ícone decorativo grande do hero das páginas de serviço */
    .service-hero-icon {
        font-size: 3rem;
        color: var(--highlight-color);
        margin-bottom: 20px;
    }

    /* Subtítulo centralizado com cor secundária (usado em múltiplas páginas) */
    .section-subtitle {
        text-align: center;
        color: var(--secondary-text-color);
        margin-bottom: 50px;
    }

    /* Título de seção centralizado (movido de servicos-web.css) */
    .section-title-centered {
        text-align: center;
        display: block !important;
        width: 100%;
    }

    .section-title-centered::after {
        margin-left: auto !important;
        margin-right: auto !important;
        margin-top: 15px !important;
    }

    /* Descrição de CTA (max-width, centrado, cor secundária) */
    .cta-description {
        max-width: 600px;
        margin: 20px auto;
        color: var(--secondary-text-color);
    }

    /* 11. SHARED CTA BOX (Shared: servicos-web, servicos-marketing, sobre-mim) */
    .web-cta-box {
        background-color: var(--container-bg-color);
        margin-top: 80px;
        padding: 40px;
        border-radius: 12px;
        border: 1px solid var(--highlight-color);
        max-width: 650px;
        width: 90%;
        margin-left: auto;
        margin-right: auto;
        position: relative;
        box-shadow: 0 0 30px rgba(var(--highlight-rgb), 0.1);
    }

    .web-cta-box h3 {
        margin-bottom: 15px;
    }

    .web-cta-box p {
        margin-bottom: 30px;
    }

    /* 10. PROCESS INTERACTIVE TABS (Shared: index.html, servicos-web.html) */
    .process-split-wrapper {
        display: grid;
        grid-template-columns: 1fr 1.5fr;
        gap: 60px;
        margin-top: 50px;
        align-items: start;
    }

    .process-nav {
        display: flex;
        flex-direction: column;
        position: relative;
        gap: 0;
    }

    .process-line {
        position: absolute;
        left: 24px;
        top: 30px;
        bottom: 30px;
        width: 2px;
        background: var(--border-color);
        z-index: 0;
        transition: background 0.3s ease;
    }

    .process-line-active {
        position: absolute;
        left: 24px;
        top: 30px;
        width: 2px;
        height: 0;
        background: var(--highlight-color);
        z-index: 1;
        transition: height 0.6s cubic-bezier(0.25, 1, 0.5, 1);
        box-shadow: 0 0 10px rgba(var(--highlight-color-rgb), 0.5);
    }

    .process-line-active::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: linear-gradient(to bottom, transparent, #fff 50%, transparent);
        opacity: 0;
        background-size: 100% 200%;
        background-position: 0% -100%;
    }

    .process-line-active.animating-forward::after {
        animation: flow-energy-forward 0.6s ease-out forwards;
    }

    .process-line-active.animating-backward::after {
        animation: flow-energy-backward 0.6s ease-out forwards;
    }

    @keyframes flow-energy-forward {
        0%   { opacity: 1; background-position: 0% -100%; }
        100% { opacity: 0; background-position: 0%  100%; }
    }

    @keyframes flow-energy-backward {
        0%   { opacity: 1; background-position: 0%  100%; }
        100% { opacity: 0; background-position: 0% -100%; }
    }

    .process-step-btn {
        background: transparent;
        border: none;
        display: flex;
        align-items: center;
        gap: 15px;
        padding: 15px 0;
        cursor: pointer;
        text-align: left;
        position: relative;
        transition: all 0.3s ease;
    }

    .step-icon-wrapper {
        position: relative;
        z-index: 2;
        width: 50px;
        height: 50px;
        flex-shrink: 0;
        background-color: var(--bg-color);
        border: 2px solid var(--border-color);
        border-radius: 50%;
        display: flex;
        justify-content: center;
        align-items: center;
        transition: all 0.3s ease;
    }

    .process-step-btn .step-icon,
    .process-step-btn h4 {
        opacity: 0.5;
        transition: opacity 0.3s ease, color 0.3s ease;
    }

    .step-icon {
        font-size: 1rem;
        color: var(--secondary-text-color);
    }

    .process-step-btn:hover .step-icon,
    .process-step-btn:hover h4,
    .process-step-btn.active .step-icon,
    .process-step-btn.active h4,
    .process-step-btn.active-path .step-icon,
    .process-step-btn.active-path h4 {
        opacity: 1;
    }

    .process-step-btn.active .step-icon-wrapper,
    .process-step-btn.active-path .step-icon-wrapper {
        border-color: var(--highlight-color);
        box-shadow: 0 0 15px rgba(0, 0, 0, 0.2);
        transform: scale(1.1);
    }

    .process-step-btn.active .step-icon,
    .process-step-btn.active-path .step-icon {
        color: var(--highlight-color);
    }

    .process-step-btn h4 {
        font-size: 1rem;
        font-weight: 700;
        color: var(--text-color);
        margin: 0;
    }

    .process-step-btn.active h4,
    .process-step-btn.active-path h4 {
        color: var(--highlight-color);
    }

    .process-display-area {
        position: relative;
        min-height: 350px;
        background-color: var(--container-bg-color);
        border: 1px solid var(--border-color);
        border-radius: 20px;
        padding: 50px;
        display: flex;
        align-items: center;
        overflow: hidden;
        box-shadow: var(--card-shadow);
    }

    .process-display-area::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 4px;
        height: 100%;
        background: var(--highlight-color);
        opacity: 0.5;
    }

    .process-content-panel {
        display: none;
        width: 100%;
        animation: fadeInRight 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    }

    .process-content-panel.active {
        display: block;
    }

    @keyframes fadeInRight {
        from { opacity: 0; transform: translateX(20px); }
        to   { opacity: 1; transform: translateX(0); }
    }

    .panel-number {
        font-size: 4rem;
        font-weight: 900;
        color: var(--text-color);
        opacity: 0.1;
        line-height: 1;
        margin-bottom: 20px;
    }

    .process-content-panel h3 {
        font-size: 2rem;
        margin-bottom: 20px;
        color: var(--text-color);
    }

    .process-content-panel p {
        font-size: 1.1rem;
        line-height: 1.8;
        color: var(--secondary-text-color);
    }

    .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;
    }

    /* 10. RESPONSIVE - SECTIONS */
    @media (max-width: 768px) {
        .logos-container {
            gap: 20px;
        }
        .hero-content h2 {
            font-size: 2.2rem;
        }

        .about-container {
            flex-direction: column;
        }

        .about-buttons-container .cta-button {
            font-size: 0.9rem;
            padding: 12px 15px;
        }

        .services-section,
        .portfolio-section,
        .about-section,
        .skills-section,
        .process-section {
            padding: 40px 20px;
        }

        .portfolio-header,
        .section-subtitle,
        .skills-filters {
            margin-bottom: 30px !important;
        }

        .skills-grid-cards {
            grid-template-columns: 1fr;
            gap: 15px;
        }

        .about-image img {
            max-width: 100%;
            aspect-ratio: 1/1;
        }

        .hero-content h1 {
            font-size: 0.9rem;
            margin-bottom: 10px;
        }

        .hero-content h2 {
            font-size: 2rem;
            margin-bottom: 20px;
        }

        .hero-content p {
            font-size: 1rem;
            line-height: 1.5;
            max-width: 100%;
            margin-bottom: 30px;
            padding: 0 10px;
        }

        .hero-section {
            padding-bottom: 60px;
        }

        .about-section {
            padding: 50px 20px;
        }

        .about-text h3 {
            font-size: 1.8rem;
            margin-bottom: 20px;
        }

        .about-text p {
            font-size: 0.95rem;
            line-height: 1.5;
            margin-bottom: 15px;
            color: var(--secondary-text-color);
            text-align: left;
        }

        .about-container {
            display: flex;
            flex-direction: column;
            gap: 15px;
        }

        .about-text,
        .about-image-wrapper {
            display: contents;
        }

        .about-content-inner {
            flex: none;
            justify-content: flex-start;
        }

        .about-text .about-content-inner {
            order: 1;
        }

        .about-image-wrapper .about-content-inner {
            order: 2;
        }

        .about-image-wrapper .about-me-extra-btn {
            order: 3;
            margin-top: 0;
        }

        .about-buttons-container {
            order: 4;
            margin-top: 0;
            gap: 15px;
        }

        .about-buttons-container .cta-button {
            padding: 12px 15px;
            font-size: 0.9rem;
        }

        /* Process responsive (Shared: index + servicos-web) */
        .process-split-wrapper {
            grid-template-columns: 1fr;
            gap: 30px;
        }

        .process-nav {
            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;
        }
    }
}
