@import url('fonts.css');

:root {
    --bg-main: #02040a; /* Deep Night - almost black with a hint of navy */
    --text-main: #e2e8f0;
    --accent-main: #f48e24; /* Bold Copper */
    --accent-glow: rgba(244, 142, 36, 0.2);

    --card-bg: rgba(255, 255, 255, 0.02);
    --card-border: rgba(255, 255, 255, 0.05);
    --card-hover-border: var(--accent-main);

    --text-muted: #94a3b8;
    --nav-bg: rgba(2, 4, 10, 0.85);

    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'Fira Code', monospace;

    --nav-height: 90px;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 10rem;
    --accent-studio: #E98525;
    --studio-shadow: rgba(233, 133, 37, 0.2);
}

body.light-mode {
    --bg-main: #F8FAFC;
    --text-main: #0F172A;
    --accent-main: #f48e24; /* Bold Copper from dark mode */
    --accent-dark: #E98525;

    --card-bg: #FFFFFF;
    --card-border: #E2E8F0;
    --card-hover-border: rgba(244, 142, 36, 0.5);

    --text-muted: #475569;
    --nav-bg: rgba(255, 255, 255, 0.85);
    --nav-border: rgba(0, 0, 0, 0.1);
    --footer-bg: rgba(241, 245, 249, 0.8);

    --gradient-features: linear-gradient(to bottom, transparent, rgba(244, 142, 36, 0.05));
    --card-gradient: linear-gradient(145deg, #FFFFFF 0%, #F8FAFC 100%);

    --shadow-heavy: rgba(15, 23, 42, 0.1);
    --shadow-accent-10: rgba(244, 142, 36, 0.1);
    --shadow-accent-30: rgba(244, 142, 36, 0.3);
    --shadow-accent-40: rgba(244, 142, 36, 0.4);

    --orb-bg-1: rgba(244, 142, 36, 0.15);
    --orb-bg-2: rgba(233, 133, 37, 0.15);
    --accent-studio: #E98525; /* Mantain copper for light mode too, but check readability */
    --studio-shadow: rgba(233, 133, 37, 0.1);

    --feature-title-color: #1E293B;
    --footer-text-color: #64748B;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    max-width: 100vw;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    max-width: 100vw;
    position: relative;
    letter-spacing: -0.01em;
}

/* Texture Grain */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    pointer-events: none;
    opacity: 0.03;
    mix-blend-mode: overlay;
    background-image: url('data:image/svg+xml,<svg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"><filter id="noiseFilter"><feTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch" /></filter><rect width="100%" height="100%" filter="url(%23noiseFilter)" /></svg>');
}

/* Classes utils */
.mono {
    font-family: var(--font-mono);
}

.accent {
    color: var(--accent-main);
    background: linear-gradient(90deg, var(--accent-main), #ffaa55, var(--accent-studio), var(--accent-main));
    background-size: 300% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shine-accent 6s linear infinite;
}

@keyframes shine-accent {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.accent-studio {
    color: var(--accent-studio);
    font-weight: 700;
}

.studio-logo-text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: var(--accent-studio);
    font-weight: 800;
    text-transform: lowercase;
}

.studio-logo-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

/* ==========================================================================
   Botons
   ========================================================================== */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    text-align: center;
}

.btn-outline {
    border: 1px solid var(--accent-main);
    color: var(--accent-main);
    font-size: 0.9rem;
}

.btn-outline:hover {
    background: var(--shadow-accent-10);
    box-shadow: 0 0 15px var(--shadow-accent-30);
}

.btn-primary {
    background: var(--accent-main);
    color: var(--bg-main);
    border: 1px solid var(--accent-main);
    font-size: 1.1rem;
    padding: 1rem 2.5rem;
}

.btn-primary:hover {
    background: transparent;
    color: var(--accent-main);
    box-shadow: 0 0 20px var(--shadow-accent-40);
    transform: translateY(-2px);
}

.btn-icon:hover {
    color: var(--accent-main) !important;
}

/* ==========================================================================
   Navbar
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--nav-height);
    background: var(--nav-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid var(--nav-border);
    transition: background-color 0.4s ease, border-color 0.4s ease;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 var(--spacing-md);
    gap: 1.5rem;
}

.nav-center {
    display: flex;
    align-items: center;
    gap: 1.75rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-muted);
    transition: color 0.25s ease;
    position: relative;
    padding: 0.25rem 0;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-main);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-main);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.navbar-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 0.5rem;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    transition: all 0.25s ease;
    border-radius: 8px;
    flex-shrink: 0;
    z-index: 1002;
}

.mobile-menu-btn:hover {
    color: var(--accent-main);
    background: rgba(244, 142, 36, 0.08);
}

.mobile-menu-btn .icon-close {
    display: none;
}

.mobile-menu-btn.active .icon-hamburger {
    display: none;
}

.mobile-menu-btn.active .icon-close {
    display: block;
}

/* Mobile Drawer */
.mobile-nav-drawer {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    width: 100%;
    height: calc(100dvh - var(--nav-height));
    background: rgba(10, 14, 23, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    z-index: 999;
    padding: 2rem 1.5rem 3rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
    overflow-y: auto;
}

body.light-mode .mobile-nav-drawer {
    background: rgba(255, 255, 255, 0.97);
}

.mobile-nav-drawer.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.mobile-nav-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.mobile-nav-item a {
    display: block;
    padding: 0.85rem 1rem;
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-main);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.mobile-nav-item a:hover,
.mobile-nav-item a.active {
    background: rgba(244, 142, 36, 0.1);
    color: var(--accent-main);
    transform: translateX(4px);
}

.mobile-nav-actions {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

body.light-mode .mobile-nav-actions {
    border-top-color: rgba(0, 0, 0, 0.08);
}

.mobile-nav-actions .btn {
    width: 100%;
    text-align: center;
    padding: 0.9rem;
    font-size: 1rem;
    font-weight: 700;
}

@media (max-width: 768px) {
    .nav-center {
        display: none !important;
    }
    .mobile-menu-btn {
        display: flex !important;
    }
    .navbar .nav-contact-btn {
        display: none !important;
    }
    .navbar-controls {
        gap: 0.5rem;
    }
    .navbar-container {
        padding: 0 1rem;
        gap: 0.5rem;
    }
    .logo {
        font-size: 1.25rem;
        white-space: nowrap;
    }
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--accent-main);
    letter-spacing: -1px;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    min-height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: calc(var(--nav-height) + 2.5rem) var(--spacing-md) 3rem;
    position: relative;
}

.hero-content {
    max-width: 980px;
    width: 100%;
    position: relative;
    z-index: 2;
    text-align: center;
    margin: 0 auto;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(1.85rem, 5vw, 3.8rem);
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 1rem;
    letter-spacing: -1px;
    display: flex;
    flex-direction: column;
    word-break: normal;
    overflow-wrap: break-word;
    hyphens: manual;
}

.hero-label {
    font-size: 0.8rem;
    letter-spacing: 5px;
    margin-bottom: 1rem;
    opacity: 0.7;
    text-align: center;
}

.hero-title .line {
    display: block;
    /* Amagat per defecte per a l'animació de GSAP */
    opacity: 0;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-muted);
    margin: 0 auto 1.5rem;
    max-width: 620px;
    line-height: 1.55;
    text-align: center;
    /* Amagat per defecte per a l'animació */
    opacity: 0;
}

/* Dynamic Interactive SVG Canvas for Hero Stage (4 Columns) */
.hero-canvas-container {
    width: 100%;
    max-width: 520px;
    margin: 0.5rem auto 1rem;
    overflow: visible;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-interactive-svg {
    width: 100%;
    height: auto;
    max-height: 160px;
}

.hero-actions {
    display: flex;
    gap: 1.25rem;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    max-width: 600px;
    margin: 0 auto;
}

.hero-actions .hero-btn {
    flex: 1;
    min-width: 220px;
    padding: 0.9rem 1.75rem;
    font-size: 0.95rem;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    /* Amagat per defecte per a l'animació de GSAP */
    opacity: 0;
}

.hero-actions .hero-primary-cta {
    background: var(--accent-main);
    color: #02040a;
    font-weight: 700;
    box-shadow: 0 4px 20px rgba(244, 142, 36, 0.35);
    border: 1px solid var(--accent-main);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-actions .hero-primary-cta:hover {
    background: #ff9d3b;
    box-shadow: 0 6px 28px rgba(244, 142, 36, 0.5);
    transform: translateY(-2px);
}

.hero-actions .hero-contact-cta {
    border-color: rgba(255, 255, 255, 0.15);
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.03);
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

body.light-mode .hero-actions .hero-contact-cta {
    border-color: rgba(0, 0, 0, 0.15);
    color: var(--text-main);
    background: rgba(0, 0, 0, 0.02);
}

.hero-actions .hero-contact-cta:hover {
    border-color: var(--accent-main);
    color: var(--accent-main);
    background: rgba(244, 142, 36, 0.08);
    transform: translateY(-2px);
}

.hero-demo-btn {
    border-color: rgba(244, 142, 36, 0.4);
    color: var(--accent-main);
    background: rgba(244, 142, 36, 0.06);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-demo-btn:hover {
    background: var(--accent-main);
    color: var(--bg-main);
    border-color: var(--accent-main);
    box-shadow: 0 0 20px var(--shadow-accent-30);
    transform: translateY(-2px);
}

.hero-consultoria-btn {
    flex: 1 1 100%;
    min-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-consultoria-btn:hover {
    background: var(--accent-main);
    color: var(--bg-main);
    border-color: var(--accent-main);
    box-shadow: 0 0 20px var(--shadow-accent-30);
    transform: translateY(-2px);
}

.consultoria-rotator {
    display: grid;
    width: 100%;
    justify-items: center;
}

.consultoria-phrase {
    grid-area: 1 / 1;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    text-align: center;
}

.consultoria-phrase.active {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 600px) {
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }
    .hero-actions .hero-btn {
        width: 100%;
        min-width: 100%;
    }
}

/* Resplendors abstractes per fons tecno */
.glow-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    z-index: 1;
    opacity: 0.4;
    pointer-events: none;
    transition: background-color 0.4s ease;
}

.orb-1 {
    top: 15%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: var(--orb-bg-1);
}

.orb-2 {
    bottom: 5%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: var(--orb-bg-2);
}

/* ==========================================================================
   Features Section
   ========================================================================== */
.features {
    padding: var(--spacing-xl) var(--spacing-md) calc(var(--spacing-xl) * 1.5);
    position: relative;
    z-index: 2;
    background: var(--gradient-features);
    transition: background 0.4s ease;
}

.features-container {
    max-width: 1200px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    /* Mobile-first: 1 columna, Desktop s'aplica flexibilitat amb minmax */
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-md);
}

.feature-card {
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: 0; /* Sharp cinematic corners */
    padding: 3.5rem 2.5rem;
    position: relative;
    transition: all 0.5s cubic-bezier(0.23, 1, 0.32, 1);
    backdrop-filter: blur(15px);
    overflow: hidden;
    opacity: 0;
}

.feature-card:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(244, 142, 36, 0.3);
    transform: scale(1.02);
}

.feature-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    letter-spacing: -0.5px;
    margin-bottom: 1.25rem;
    color: #fff;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--accent-main);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.feature-card:hover {
    transform: translateY(-8px) !important;
    /* Force respect to transform on hover */
    border-color: var(--card-hover-border);
    box-shadow: 0 10px 30px var(--shadow-accent-10),
        inset 0 0 0 1px var(--shadow-accent-10);
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-icon {
    font-size: 1.5rem;
    color: var(--accent-main);
    margin-bottom: 1.5rem;
    opacity: 0.8;
}

.feature-title {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--feature-title-color);
}

.feature-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* ==========================================================================
   VoraStudio Section
   ========================================================================== */
.vorastudio {
    padding: var(--spacing-xl) var(--spacing-md);
    background: linear-gradient(to bottom, var(--bg-main), rgba(189, 0, 255, 0.03));
    position: relative;
    overflow: hidden;
}

.vorastudio-container {
    max-width: 1200px;
    margin: 0 auto;
}

.vorastudio-content {
    max-width: 900px;
}

.studio-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.4rem 1rem;
    background: var(--studio-shadow);
    border: 1px solid var(--accent-studio);
    color: var(--accent-studio);
    border-radius: 50px;
    font-size: 0.85rem;
    margin-bottom: 2rem;
    animation: pulse-studio 3s infinite;
}

@keyframes pulse-studio {
    0% { box-shadow: 0 0 0 0 var(--studio-shadow); }
    70% { box-shadow: 0 0 0 15px rgba(233, 133, 37, 0); }
    100% { box-shadow: 0 0 0 0 rgba(233, 133, 37, 0); }
}

.section-title.left {
    text-align: left;
    margin-bottom: 2.5rem;
}

/* ==========================================================================
   Architecture v2 (Asymmetrical & Staggered)
   ========================================================================== */
.architecture-v2 {
    padding: var(--spacing-xl) var(--spacing-md);
    background: linear-gradient(135deg, var(--bg-main) 0%, rgba(244, 142, 36, 0.02) 100%);
    position: relative;
}

.arch-container {
    max-width: 1200px;
    margin: 0 auto;
}

.arch-staggered-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 2rem;
    margin-top: 4rem;
}

.arch-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 3rem;
    position: relative;
    backdrop-filter: blur(20px);
    transition: all 0.5s ease;
    opacity: 0; /* Animació ScrollTrigger */
}

.arch-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--accent-main);
    transform: translateY(-5px);
}

.arch-more-btn {
    position: absolute;
    top: 2.5rem;
    right: 2.5rem;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: var(--accent-main);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 400;
    line-height: 1;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    z-index: 5;
}

body.light-mode .arch-more-btn {
    background: #F1F5F9;
    border-color: #E2E8F0;
}

.arch-item:hover .arch-more-btn {
    background: var(--accent-main);
    border-color: var(--accent-main);
    color: var(--bg-main);
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 0 15px var(--shadow-accent-30);
}

.arch-num {
    font-family: var(--font-mono);
    color: var(--accent-main);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: block;
    opacity: 0.6;
}

.arch-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.arch-text {
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* Posicionament Asimètric */
.pillar-1 {
    grid-column: 1 / 7;
    grid-row: 1;
}

.pillar-2 {
    grid-column: 8 / 13;
    grid-row: 1;
    margin-top: 5rem; /* Esglaonat */
}

.pillar-3 {
    grid-column: 2 / 8;
    grid-row: 2;
    margin-top: -2rem; /* Solapament */
}

.pillar-4 {
    grid-column: 8 / 13;
    grid-row: 2;
}

.pillar-5 {
    grid-column: 3 / 11;
    grid-row: 3;
    margin-top: 1rem;
    border-left: 4px solid var(--accent-main);
}

.accent-box {
    background: linear-gradient(145deg, rgba(244, 142, 36, 0.05) 0%, rgba(244, 142, 36, 0.01) 100%);
    border-color: rgba(244, 142, 36, 0.2);
}

@media (max-width: 900px) {
    .arch-staggered-grid {
        display: flex;
        flex-direction: column;
        gap: 2rem;
    }
    .arch-item {
        margin: 0 !important;
    }
}


/* ==========================================================================
   Secció Nosaltres (Boutique Tecnològica · Girona)
   ========================================================================== */
.nosaltres {
    padding: var(--spacing-xl) var(--spacing-md);
    position: relative;
    background: linear-gradient(180deg, var(--bg-main) 0%, rgba(244, 142, 36, 0.02) 50%, var(--bg-main) 100%);
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.nosaltres-container {
    max-width: 1200px;
    margin: 0 auto;
}

.nosaltres-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.85rem;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    background: rgba(244, 142, 36, 0.08);
    color: var(--accent-main);
    border: 1px solid rgba(244, 142, 36, 0.25);
    margin-bottom: 1.5rem;
}

.nosaltres-grid {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    gap: 4.5rem;
    align-items: center;
}

@media (max-width: 992px) {
    .nosaltres-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

.nosaltres-desc {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.tandem-wrapper {
    margin-top: 2rem;
    padding: 1.75rem;
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
}

.tandem-intro {
    margin-bottom: 1.5rem;
}

.tandem-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}

.tandem-subtitle {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin: 0;
}

.tandem-subtitle strong {
    color: var(--text-main);
}

.tandem-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-top: 1.25rem;
}

@media (max-width: 640px) {
    .tandem-cards {
        grid-template-columns: 1fr;
    }
}

.tandem-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    padding: 1.35rem;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.tandem-card:hover {
    transform: translateY(-3px);
    border-color: rgba(244, 142, 36, 0.35);
}

.tandem-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-bottom: 0.85rem;
}

.tandem-header a {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.tandem-role {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.tandem-card p {
    font-size: 0.9rem;
    line-height: 1.55;
    color: var(--text-muted);
    margin: 0;
}

.tandem-pillars-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem 1.5rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px dashed rgba(255, 255, 255, 0.08);
}

@media (max-width: 640px) {
    .tandem-pillars-grid {
        grid-template-columns: 1fr;
    }
}

.tandem-pillar-item {
    font-size: 0.88rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tandem-pillar-item .accent {
    color: var(--accent);
    font-weight: bold;
}

.local-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(244, 142, 36, 0.25);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.map-visual-container {
    width: 100%;
    line-height: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.girona-tech-map {
    width: 100%;
    height: auto;
    display: block;
}

.local-card-body {
    padding: 1.75rem;
}

.local-card-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.65rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.local-card-text {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

.local-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pill-badge {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    padding: 0.25rem 0.65rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    color: var(--text-main);
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    max-width: 700px;
}

.services-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.service-item {
    font-size: 1.1rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-main);
}

.service-item .accent {
    color: var(--accent-studio);
}

/* ==========================================================================
   Projects Section
   ========================================================================== */
.projects {
    padding: var(--spacing-xl) var(--spacing-md);
    background: var(--bg-main);
}

.projects-container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-weight: 800;
    text-align: center; /* Centering the title as requested */
    margin-bottom: var(--spacing-xl);
    letter-spacing: -2px;
    color: var(--text-main);
}

.projects-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.projects-header .section-title {
    margin-bottom: 0.75rem;
}

.projects-header .section-subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    max-width: 680px;
    margin: 0 auto;
    line-height: 1.6;
}

.projects-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
}

.project-card {
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 2.25rem 2rem;
    position: relative;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.4s ease,
                box-shadow 0.4s ease,
                background 0.4s ease;
    opacity: 0;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    background: rgba(255, 255, 255, 0.045);
    border-color: rgba(244, 142, 36, 0.4);
    transform: translateY(-6px);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35),
                0 0 20px rgba(244, 142, 36, 0.1);
}

/* Targeta destacada Vora IA */
.project-card.project-card-ai {
    background: linear-gradient(145deg, rgba(244, 142, 36, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%);
    border: 1px solid rgba(244, 142, 36, 0.35);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.project-card.project-card-ai:hover {
    border-color: var(--accent);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.4),
                0 0 28px rgba(244, 142, 36, 0.2);
}

.project-tag {
    font-size: 0.75rem;
    color: var(--accent);
    letter-spacing: 1px;
    font-weight: 700;
    margin-bottom: 0.85rem;
    display: inline-block;
    opacity: 0.9;
}

.project-tag.project-tag-ai {
    color: var(--accent-light, #ffb366);
    background: rgba(244, 142, 36, 0.15);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    border: 1px solid rgba(244, 142, 36, 0.3);
}

/* Accent Line at Bottom */
.project-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-main), transparent);
    transform: scaleX(0);
    transition: transform 0.4s ease;
    border-radius: 0 0 10px 10px;
}

.project-card:hover::after {
    transform: scaleX(1);
}

.project-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.project-title {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    margin-bottom: 0.85rem;
    color: var(--text-main);
    font-weight: 700;
    letter-spacing: -0.5px;
}

.project-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.65;
    flex-grow: 1;
    margin-bottom: 1.25rem;
}

.project-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--accent-main);
    margin-top: auto;
    transition: transform 0.3s ease, color 0.3s ease;
}

.project-link-btn:hover {
    transform: translateX(6px);
    color: var(--accent-light, #ffb366);
}

/* ==========================================================================
   Testimonials Section
   ========================================================================== */
.testimonials {
    padding: var(--spacing-xl) var(--spacing-md);
    background: var(--bg-main);
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.testimonials-container {
    max-width: 1200px;
    margin: 0 auto;
}

.testimonials-slider-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-top: 3rem;
}

.testimonials-track-container {
    flex-grow: 1;
    overflow: hidden;
    padding: 1.5rem 0.5rem;
}

.testimonials-track {
    display: flex;
    gap: 2rem;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
}

.testimonial-card {
    flex: 0 0 calc((100% - 4rem) / 3); /* Default 3 columns for desktop */
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: 6px;
    padding: 3.5rem 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 290px;
    backdrop-filter: blur(15px);
    transition: all 0.5s ease;
    opacity: 0; /* Animated by GSAP */
}

body.light-mode .testimonial-card {
    background: var(--card-bg);
    border-color: var(--card-border);
    box-shadow: 0 10px 30px var(--shadow-heavy);
}

.testimonial-card:hover {
    background: rgba(255, 255, 255, 0.025);
    border-color: rgba(244, 142, 36, 0.25);
    transform: translateY(-8px) !important; /* Overwrite standard transforms on hover */
    box-shadow: 0 15px 35px var(--shadow-accent-10);
}

body.light-mode .testimonial-card:hover {
    border-color: rgba(244, 142, 36, 0.4);
    box-shadow: 0 15px 35px var(--shadow-heavy),
                0 0 25px var(--shadow-accent-10);
}

.stars {
    color: var(--accent-main);
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    letter-spacing: 2px;
}

.testimonial-text {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
    font-style: italic;
    margin-bottom: 2rem;
    flex-grow: 1;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.author-name {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-main);
}

.author-role {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent-main);
}

/* Slider Controls */
.slider-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
    z-index: 10;
    outline: none;
}

body.light-mode .slider-btn {
    background: #FFFFFF;
    border-color: #E2E8F0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.slider-btn:hover {
    background: var(--accent-main);
    border-color: var(--accent-main);
    color: var(--bg-main);
    box-shadow: 0 0 15px var(--shadow-accent-30);
    transform: scale(1.05);
}

.slider-btn:active {
    transform: scale(0.95);
}

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 2rem;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: all 0.3s ease;
}

body.light-mode .dot {
    background: #CBD5E1;
}

.dot.active {
    background: var(--accent-main);
    width: 24px;
    border-radius: 10px;
}

/* Responsive columns */
@media (max-width: 992px) {
    .testimonial-card {
        flex: 0 0 calc((100% - 2rem) / 2); /* 2 columns on tablets */
    }
}

@media (max-width: 668px) {
    .testimonial-card {
        flex: 0 0 100%; /* 1 column on mobile */
    }
    .testimonials-slider-wrapper {
        gap: 0.5rem;
    }
    .slider-btn {
        display: none; /* Hide buttons on mobile, swipe or dots only */
    }
}

/* ==========================================================================
   Contact Section
   ========================================================================== */
.contact {
    padding: var(--spacing-xl) var(--spacing-md);
    background: var(--bg-main);
    position: relative;
    z-index: 2;
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
}

.contact-card {
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    padding: 4.5rem 4rem;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    transition: all 0.5s ease;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    opacity: 0; /* Animated by GSAP */
}

.contact-card:hover {
    border-color: rgba(244, 142, 36, 0.25);
    box-shadow: 0 20px 40px rgba(244, 142, 36, 0.05), 
                0 0 30px var(--shadow-accent-10);
}

body.light-mode .contact-card {
    background: var(--card-bg);
    border-color: var(--card-border);
    box-shadow: 0 20px 40px var(--shadow-heavy);
}

body.light-mode .contact-card:hover {
    border-color: rgba(244, 142, 36, 0.4);
    box-shadow: 0 20px 45px var(--shadow-heavy), 
                0 0 25px var(--shadow-accent-10);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 5rem;
    align-items: center;
}

@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 3.5rem;
    }
    .contact-card {
        padding: 3rem 2rem;
    }
}

.contact-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    letter-spacing: -2px;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--text-main);
}

.contact-desc {
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-detail-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.1rem;
    color: var(--text-main);
}

.contact-detail-item a {
    font-weight: 600;
    transition: color 0.3s ease;
}

.contact-detail-item a:hover {
    color: var(--accent-main);
}

/* Formulari */
.contact-form-container {
    width: 100%;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    position: relative;
    width: 100%;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form textarea {
    width: 100%;
    padding: 1rem 1.25rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: all 0.3s ease;
    outline: none;
}

body.light-mode .contact-form input[type="text"],
body.light-mode .contact-form input[type="email"],
body.light-mode .contact-form input[type="tel"],
body.light-mode .contact-form textarea {
    background: #F1F5F9;
    border-color: #E2E8F0;
}

.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form input[type="tel"]:focus,
.contact-form textarea:focus {
    border-color: var(--accent-main);
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 0 15px var(--shadow-accent-10);
}

body.light-mode .contact-form input[type="text"]:focus,
body.light-mode .contact-form input[type="email"]:focus,
body.light-mode .contact-form input[type="tel"]:focus,
body.light-mode .contact-form textarea:focus {
    background: #FFFFFF;
    border-color: var(--accent-main);
    box-shadow: 0 0 15px var(--shadow-accent-10);
}

.btn-submit {
    align-self: flex-start;
    padding: 1rem 2.5rem;
    font-size: 1rem;
    width: 100%;
}

@media (min-width: 576px) {
    .btn-submit {
        width: auto;
    }
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    border-top: 1px solid var(--nav-border);
    padding: var(--spacing-md);
    background: var(--footer-bg);
    transition: background-color 0.4s ease, border-color 0.4s ease;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    color: var(--footer-text-color);
    font-size: 0.9rem;
    text-align: center;
}

.legal-links {
    display: flex;
    gap: 1.5rem;
}

.legal-links a:hover {
    color: var(--accent-main);
}

/* ==========================================================================
   Media Queries (Desktop Enhancements)
   ========================================================================== */
@media (min-width: 768px) {
    .hero {
        justify-content: center;
    }

    .hero-content {
        text-align: center;
    }

    .hero-subtitle {
        margin-inline: auto;
    }

    .footer-container {
        flex-direction: row;
        justify-content: space-between;
    }
}

/* ==========================================================================
   Vori Digital Assistant Floating Widget
   ========================================================================== */
.vori-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 999; /* Below overlay, above everything else */
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    pointer-events: none; /* Let clicks pass through widget container */
}

.vori-widget * {
    pointer-events: auto; /* Re-enable pointer events for elements inside */
}

/* Floating Action Button (FAB) */
.vori-fab {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--accent-main);
    color: #FFFFFF;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 32px rgba(244, 142, 36, 0.4), 0 0 16px rgba(244, 142, 36, 0.2);
    position: relative;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease, background-color 0.3s ease;
}

body.light-mode .vori-fab {
    box-shadow: 0 8px 24px rgba(244, 142, 36, 0.3), 0 0 12px rgba(244, 142, 36, 0.15);
}

.vori-fab:hover {
    transform: scale(1.1) rotate(5deg);
    background: var(--accent-dark, #E98525);
    box-shadow: 0 12px 40px rgba(244, 142, 36, 0.5), 0 0 24px rgba(244, 142, 36, 0.3);
}

.vori-fab:active {
    transform: scale(0.95);
}

.vori-fab-icon {
    width: 32px;
    height: 32px;
    color: #FFFFFF;
}

/* Online Status Indicator */
.vori-online-status {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 14px;
    height: 14px;
    background: #27c93f;
    border: 2px solid var(--accent-main);
    border-radius: 50%;
    animation: pulse-online 2s infinite;
    transition: background-color 0.4s ease;
}

.vori-online-status.status-busy {
    background: #ffbd2e;
    animation: pulse-busy 2s infinite;
}

.vori-online-status.status-offline {
    background: #ff5f56;
    animation: none;
}

@keyframes pulse-online {
    0% {
        box-shadow: 0 0 0 0 rgba(39, 201, 63, 0.7);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(39, 201, 63, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(39, 201, 63, 0);
    }
}

@keyframes pulse-busy {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 189, 46, 0.7);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(255, 189, 46, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 189, 46, 0);
    }
}

/* Welcome Bubble */
.vori-welcome-bubble {
    position: absolute;
    bottom: 75px;
    right: 5px;
    background: var(--bg-main);
    color: var(--text-main);
    border: 1.5px solid var(--accent-main);
    padding: 0.6rem 1.2rem;
    border-radius: 16px 16px 2px 16px;
    font-size: 0.85rem;
    font-weight: 500;
    box-shadow: var(--shadow-heavy, rgba(0, 0, 0, 0.3)) 0px 4px 20px;
    white-space: nowrap;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.5s ease, transform 0.5s ease;
    animation: float-bubble 4s ease-in-out infinite;
    z-index: 1000;
}

body.light-mode .vori-welcome-bubble {
    background: #FFFFFF;
    border: 1.5px solid rgba(244, 142, 36, 0.4);
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.08);
}

.vori-welcome-bubble.fade-out {
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
}

@keyframes float-bubble {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

/* Chat Window */
.vori-chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 480px;
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    
    /* Glassmorphism Dark Mode Default */
    background: rgba(10, 15, 30, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1.5px solid rgba(244, 142, 36, 0.25);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5), 0 0 20px rgba(244, 142, 36, 0.1);
    
    opacity: 0;
    transform: scale(0.85) translateY(20px);
    transform-origin: bottom right;
    pointer-events: none;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

body.light-mode .vori-chat-window {
    background: rgba(255, 255, 255, 0.95);
    border: 1.5px solid rgba(244, 142, 36, 0.3);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08), 0 0 16px rgba(244, 142, 36, 0.08);
}

.vori-chat-window.active {
    opacity: 1;
    transform: scale(1) translateY(0);
    pointer-events: auto;
}

/* Chat Header */
.vori-chat-header {
    background: rgba(244, 142, 36, 0.08);
    border-bottom: 1.5px solid rgba(244, 142, 36, 0.15);
    padding: 1rem 1.2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

body.light-mode .vori-chat-header {
    background: rgba(244, 142, 36, 0.04);
    border-bottom: 1.5px solid rgba(244, 142, 36, 0.1);
}

.vori-chat-header-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.vori-chat-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(244, 142, 36, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.vori-chat-avatar svg {
    width: 24px;
    height: 24px;
}

.vori-chat-titles h3 {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.2;
}

.vori-chat-titles span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.vori-chat-close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.vori-chat-close-btn:hover {
    color: var(--accent-main);
}

/* Chat Messages */
.vori-chat-messages {
    flex: 1;
    padding: 1.2rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

/* Scrollbar */
.vori-chat-messages::-webkit-scrollbar {
    width: 5px;
}

.vori-chat-messages::-webkit-scrollbar-track {
    background: transparent;
}

.vori-chat-messages::-webkit-scrollbar-thumb {
    background: rgba(244, 142, 36, 0.2);
    border-radius: 10px;
}

.vori-chat-messages::-webkit-scrollbar-thumb:hover {
    background: var(--accent-main);
}

/* Message bubble */
.vori-message {
    display: flex;
    max-width: 85%;
    animation: message-appear 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transform-origin: left bottom;
}

@keyframes message-appear {
    0% {
        opacity: 0;
        transform: scale(0.9) translateY(10px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.vori-message.vori-bot {
    align-self: flex-start;
}

.vori-message.vori-user {
    align-self: flex-end;
    transform-origin: right bottom;
}

.vori-message-content {
    padding: 0.8rem 1rem;
    border-radius: 16px;
    font-size: 0.88rem;
    line-height: 1.45;
    word-break: break-word;
}

.vori-message-content a.vori-chat-link {
    color: var(--accent-main);
    text-decoration: underline;
    text-underline-offset: 3px;
    font-weight: 600;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.vori-message-content a.vori-chat-link:hover {
    color: #FFA640;
    text-decoration: underline;
}

.vori-user .vori-message-content a.vori-chat-link {
    color: #FFFFFF;
    text-decoration: underline;
}

.vori-bot .vori-message-content {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    border-bottom-left-radius: 2px;
}

body.light-mode .vori-bot .vori-message-content {
    background: #F1F5F9;
    border: 1px solid #E2E8F0;
}

.vori-user .vori-message-content {
    background: var(--accent-main);
    color: #FFFFFF;
    border-bottom-right-radius: 2px;
    box-shadow: 0 4px 12px rgba(244, 142, 36, 0.25);
}

/* Suggestions / Chips */
.vori-chat-suggestions {
    padding: 0 1.2rem 0.8rem 1.2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.vori-suggestion-chip {
    background: rgba(244, 142, 36, 0.05);
    border: 1px solid rgba(244, 142, 36, 0.25);
    color: var(--text-main);
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: var(--font-body);
}

body.light-mode .vori-suggestion-chip {
    background: rgba(244, 142, 36, 0.03);
    border: 1px solid rgba(244, 142, 36, 0.2);
}

.vori-suggestion-chip:hover {
    background: var(--accent-main);
    color: #FFFFFF;
    border-color: var(--accent-main);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(244, 142, 36, 0.15);
}

/* Input Form */
.vori-chat-input-area {
    padding: 1rem 1.2rem;
    border-top: 1.5px solid rgba(244, 142, 36, 0.15);
    background: rgba(10, 15, 30, 0.95);
    display: flex;
    align-items: center;
    gap: 10px;
}

body.light-mode .vori-chat-input-area {
    border-top: 1.5px solid rgba(244, 142, 36, 0.1);
    background: #FFFFFF;
}

.vori-chat-input-area input {
    flex: 1;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-main);
    padding: 0.75rem 1rem;
    border-radius: 25px;
    font-size: 0.88rem;
    outline: none;
    transition: border-color 0.3s ease, background-color 0.3s ease;
    font-family: var(--font-body);
}

body.light-mode .vori-chat-input-area input {
    background: #F8FAFC;
    border: 1px solid #E2E8F0;
}

.vori-chat-input-area input:focus {
    border-color: var(--accent-main);
    background: rgba(255, 255, 255, 0.05);
}

body.light-mode .vori-chat-input-area input:focus {
    background: #FFFFFF;
    border-color: var(--accent-main);
}

.vori-chat-send-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--accent-main);
    color: #FFFFFF;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, background-color 0.3s ease;
    flex-shrink: 0;
}

.vori-chat-send-btn:hover {
    background: var(--accent-dark, #E98525);
    transform: scale(1.05);
}

.vori-chat-send-btn:active {
    transform: scale(0.95);
}

/* Simulated Typing Indicator */
.vori-typing-indicator {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0.3rem 0;
}

.vori-typing-indicator span {
    width: 6px;
    height: 6px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: typing-bounce 1s infinite ease-in-out;
}

.vori-typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.vori-typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing-bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-4px);
    }
}

/* AI Act Legal Disclaimer */
.vori-ai-disclaimer {
    padding: 0.4rem 1rem 0.6rem;
    font-size: 0.68rem;
    color: var(--text-muted);
    text-align: center;
    line-height: 1.35;
    background: rgba(10, 15, 30, 0.95);
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

body.light-mode .vori-ai-disclaimer {
    background: #FFFFFF;
    border-top: 1px solid rgba(0, 0, 0, 0.04);
    color: #64748B;
}

/* Adjustments for smaller mobile viewports */
@media (max-width: 480px) {
    .vori-widget {
        bottom: 1rem;
        right: 1rem;
    }
    
    .vori-chat-window {
        width: calc(100vw - 2rem);
        height: 420px;
        right: 0;
        bottom: 70px;
    }

    /* Navbar adjustments */
    .navbar-container {
        padding: 0 0.85rem;
    }
    
    .logo {
        font-size: 1.15rem;
    }
    
    .lang-btn {
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
    }
    
    .navbar-controls {
        gap: 0.35rem !important;
    }

    .mobile-menu-btn {
        width: 38px;
        height: 38px;
        padding: 0.35rem;
    }

    /* Hero adjustments */
    .hero {
        padding: calc(var(--nav-height) + 1.25rem) 1rem 2rem;
    }

    .hero-title {
        font-size: 1.85rem;
        letter-spacing: -0.5px;
        line-height: 1.2;
    }
    
    .hero-label {
        font-size: 0.68rem;
        letter-spacing: 2px;
        margin-bottom: 0.75rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
        line-height: 1.5;
        margin-bottom: 1rem;
    }

    .hero-canvas-container {
        max-width: 100% !important;
        margin: 0.75rem auto !important;
    }

    .hero-interactive-svg {
        max-height: 140px !important;
    }

    .daia-showcase-card {
        padding: 1.75rem 1.25rem;
        gap: 1.75rem;
    }

    .daia-showcase-title {
        font-size: 1.5rem;
    }

    .daia-buttons-group .btn {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .core-services-grid,
    .benefits-grid,
    .projects-grid {
        grid-template-columns: 1fr !important;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
        gap: 0.75rem;
    }

    .hero-actions .hero-btn {
        width: 100%;
        min-width: 0;
        padding: 0.85rem 1.25rem;
    }

    .core-service-card {
        padding: 2rem 1.5rem;
    }

    .benefit-card {
        padding: 1.75rem 1.25rem;
    }

    .project-card {
        padding: 1.75rem 1.25rem;
    }
}

/* Language Selector Styles */
.lang-selector-container {
    position: relative;
    display: inline-block;
}

.lang-btn {
    background: none;
    border: 1px solid var(--card-border);
    color: var(--text-main);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.lang-btn:hover {
    border-color: var(--accent-main);
    color: var(--accent-main);
}

.lang-btn .chevron-icon {
    transition: transform 0.3s ease;
}

.lang-selector-container.active .lang-btn .chevron-icon {
    transform: rotate(180deg);
}

.lang-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: rgba(10, 15, 30, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 0.4rem;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 80px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transform: translateY(10px);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1000;
}

body.light-mode .lang-dropdown {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}

.lang-dropdown.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.lang-option {
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.4rem 0.6rem;
    text-align: center;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.lang-option:hover {
    background: rgba(244, 142, 36, 0.08);
    color: var(--accent-main);
}

.lang-option.active {
    background: var(--accent-main);
    color: #FFFFFF;
    font-weight: 700;
}

/* Ocultar el badge flotant de Google reCAPTCHA */
.grecaptcha-badge {
    visibility: hidden !important;
}

/* ==========================================================================
   Executive Benefits Section ("Què pots aconseguir")
   ========================================================================== */
.benefits-section {
    padding: calc(var(--spacing-xl) * 0.8) var(--spacing-md) calc(var(--spacing-xl) * 1.2);
    position: relative;
    z-index: 2;
    background: linear-gradient(180deg, var(--bg-main) 0%, rgba(20, 24, 33, 0.6) 50%, var(--bg-main) 100%);
}

.benefits-container {
    max-width: 1200px;
    margin: 0 auto;
}

.benefits-header {
    margin-bottom: 2.25rem;
    max-width: 820px;
}

.benefits-header .section-title,
.core-services-header .section-title {
    font-size: clamp(1.8rem, 3.6vw, 2.5rem);
    line-height: 1.2;
    letter-spacing: -1px;
    margin-bottom: 1rem;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.75rem;
}

.benefit-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 2.2rem 2rem;
    position: relative;
    transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
    backdrop-filter: blur(12px);
    display: flex;
    flex-direction: column;
}

.benefit-card:hover {
    transform: translateY(-6px);
    border-color: rgba(244, 142, 36, 0.4);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.35), 0 0 20px rgba(244, 142, 36, 0.1);
}

.benefit-icon {
    font-size: 2rem;
    margin-bottom: 1.25rem;
    display: inline-block;
}

.benefit-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--text-main);
    margin-bottom: 0.85rem;
    font-weight: 700;
    line-height: 1.3;
}

.benefit-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* ==========================================================================
   Core Services (2 Pillars)
   ========================================================================== */
.core-services-section {
    padding: calc(var(--spacing-xl) * 1.2) var(--spacing-md);
    position: relative;
    z-index: 2;
}

.core-services-container {
    max-width: 1200px;
    margin: 0 auto;
}

.core-services-header {
    margin-bottom: 3.5rem;
    max-width: 800px;
}

.core-services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 2rem;
}

.core-service-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    padding: 3rem 2.5rem;
    position: relative;
    display: flex;
    flex-direction: column;
    transition: all 0.4s ease;
}

.core-service-card.highlight-card {
    background: linear-gradient(135deg, rgba(244, 142, 36, 0.05) 0%, rgba(20, 24, 33, 0.9) 100%);
    border-color: rgba(244, 142, 36, 0.3);
}

.core-service-card:hover {
    border-color: var(--accent-main);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    transform: translateY(-4px);
}

.core-service-tag {
    font-size: 0.75rem;
    letter-spacing: 2px;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.core-service-num {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 1rem;
    opacity: 0.8;
}

.core-service-title {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    color: var(--text-main);
    margin-bottom: 1.25rem;
    line-height: 1.25;
}

.core-service-desc {
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.65;
    margin-bottom: 2rem;
}

.core-service-list {
    list-style: none;
    padding: 0;
    margin: 0 0 2.5rem 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.core-service-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.95rem;
    color: var(--text-main);
    line-height: 1.5;
}

.core-service-action {
    margin-top: auto;
}

/* ==========================================================================
   DAIA Live Showcase
   ========================================================================== */
.daia-showcase-section {
    padding: calc(var(--spacing-xl) * 1.2) var(--spacing-md);
    position: relative;
    z-index: 2;
}

.daia-showcase-container {
    max-width: 1200px;
    margin: 0 auto;
}

.daia-showcase-card {
    background: linear-gradient(135deg, rgba(20, 24, 33, 0.95) 0%, rgba(10, 13, 20, 0.98) 100%);
    border: 1px solid rgba(244, 142, 36, 0.35);
    border-radius: 20px;
    padding: 3.5rem;
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 3.5rem;
    align-items: center;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 40px rgba(244, 142, 36, 0.1);
}

.daia-badge {
    display: inline-block;
    padding: 0.35rem 0.85rem;
    border-radius: 20px;
    background: rgba(244, 142, 36, 0.15);
    color: var(--accent-main);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-bottom: 1.25rem;
}

.daia-showcase-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--text-main);
    margin-bottom: 1.25rem;
    line-height: 1.25;
}

.daia-showcase-desc {
    color: var(--text-muted);
    font-size: 1.05rem;
    line-height: 1.65;
    margin-bottom: 2rem;
}

.daia-features-list {
    list-style: none;
    padding: 0;
    margin: 0 0 2.5rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.daia-features-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: var(--text-main);
}

.daia-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.85rem;
}

.daia-buttons-group {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
}

.daia-launch-btn {
    padding: 0.9rem 1.8rem;
    font-size: 0.95rem;
    font-weight: 700;
}

.daia-vori-btn {
    padding: 0.9rem 1.8rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-color: rgba(244, 142, 36, 0.5);
    background: rgba(244, 142, 36, 0.05);
}

.daia-vori-btn:hover {
    background: var(--accent-main);
    color: var(--bg-main);
    border-color: var(--accent-main);
    box-shadow: 0 0 20px var(--shadow-accent-30);
    transform: translateY(-2px);
}

.daia-subnote {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.terminal-mockup {
    background: #0B0E14;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
    overflow: hidden;
}

.terminal-header {
    background: rgba(255, 255, 255, 0.04);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.terminal-header .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.terminal-header .dot-red { background: #ff5f56; }
.terminal-header .dot-yellow { background: #ffbd2e; }
.terminal-header .dot-green { background: #27c93f; }

.terminal-title {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-left: auto;
}

.terminal-body {
    padding: 1.5rem;
    font-size: 0.85rem;
    line-height: 1.7;
    color: #E2E8F0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.terminal-prompt {
    color: var(--accent-main);
    font-weight: 700;
}

.terminal-out-dim {
    color: #64748B;
}

.terminal-out-success {
    color: #27c93f;
    font-weight: 600;
}

.terminal-out-code {
    color: #F48E24;
    background: rgba(244, 142, 36, 0.08);
    padding: 0.4rem 0.6rem;
    border-radius: 6px;
    display: inline-block;
}

@media (max-width: 900px) {
    .daia-showcase-card {
        grid-template-columns: 1fr;
        padding: 2.25rem;
        gap: 2.5rem;
    }
}

/* ==========================================================================
   FAQ Section (Generative Engine Optimization & Accordion)
   ========================================================================== */
.faq-section {
    padding: var(--spacing-xl) var(--spacing-md);
    background: var(--bg-main);
    position: relative;
    z-index: 2;
}

.faq-container {
    max-width: 960px;
    margin: 0 auto;
}

.faq-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.faq-header .hero-label {
    margin-bottom: 0.75rem;
}

.faq-header .section-title {
    font-family: var(--font-heading);
    font-size: clamp(1.85rem, 4vw, 2.6rem);
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
    color: var(--text-main);
}

.faq-header .section-subtitle {
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 720px;
    margin: 0 auto;
    line-height: 1.6;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: border-color 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.faq-item:hover {
    border-color: rgba(244, 142, 36, 0.3);
    background: rgba(255, 255, 255, 0.025);
}

.faq-item[open] {
    border-color: rgba(244, 142, 36, 0.45);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25), 0 0 20px var(--shadow-accent-10);
}

.faq-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.4rem 1.75rem;
    cursor: pointer;
    user-select: none;
    list-style: none;
    gap: 1.25rem;
}

.faq-summary::-webkit-details-marker {
    display: none;
}

.faq-question {
    font-family: var(--font-heading);
    font-size: 1.08rem;
    font-weight: 600;
    color: var(--text-main);
    line-height: 1.45;
    transition: color 0.25s ease;
}

.faq-item:hover .faq-question,
.faq-item[open] .faq-question {
    color: #FFFFFF;
}

.faq-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--accent-main);
    flex-shrink: 0;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), background 0.3s ease, border-color 0.3s ease;
}

.faq-item[open] .faq-icon {
    transform: rotate(180deg);
    background: rgba(244, 142, 36, 0.15);
    border-color: var(--accent-main);
}

.faq-answer {
    padding: 0 1.75rem 1.5rem 1.75rem;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    padding-top: 1.25rem;
    animation: faqFadeSlide 0.35s ease;
}

.faq-answer p {
    color: var(--text-muted);
    font-size: 0.98rem;
    line-height: 1.75;
    margin: 0;
}

@keyframes faqFadeSlide {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Light Mode Support */
body.light-mode .faq-section {
    background: var(--bg-main);
}

body.light-mode .faq-header .section-title {
    color: var(--text-main);
}

body.light-mode .faq-item {
    background: var(--card-bg);
    border-color: var(--card-border);
}

body.light-mode .faq-item:hover {
    border-color: rgba(244, 142, 36, 0.5);
    background: #FFFFFF;
}

body.light-mode .faq-item[open] {
    border-color: var(--accent-main);
    background: #FFFFFF;
    box-shadow: 0 10px 25px var(--shadow-heavy);
}

body.light-mode .faq-question {
    color: #0F172A;
}

body.light-mode .faq-item:hover .faq-question,
body.light-mode .faq-item[open] .faq-question {
    color: #000000;
}

body.light-mode .faq-icon {
    background: rgba(244, 142, 36, 0.08);
    border-color: rgba(244, 142, 36, 0.2);
}

body.light-mode .faq-answer {
    border-top-color: var(--card-border);
}

body.light-mode .faq-answer p {
    color: var(--text-muted);
}

@media (max-width: 768px) {
    .faq-section {
        padding: var(--spacing-lg) var(--spacing-sm);
    }
    .faq-header {
        margin-bottom: 2.5rem;
    }
    .faq-summary {
        padding: 1.15rem 1.25rem;
        gap: 0.85rem;
    }
    .faq-question {
        font-size: 1rem;
    }
    .faq-answer {
        padding: 0 1.25rem 1.25rem 1.25rem;
    }
}
