/* ==========================================================================
   5. NAVIGATION
   ========================================================================== */

/* Navbar Base */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: #0a0a0a;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    padding: 1.5rem 0;
    transition: padding 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
    transform: translateZ(0);
    backface-visibility: hidden;
    will-change: transform;
}

/* Reduce expensive backdrop-filter during rapid scrolling */
.navbar.rapid-scroll {
    backdrop-filter: blur(10px) saturate(120%);
    -webkit-backdrop-filter: blur(10px) saturate(120%);
}

.navbar.scrolled {
    background: #0a0a0a;
    border-bottom-color: var(--border-color-hover);
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Nav Brand */
.nav-brand {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--text-primary);
    letter-spacing: 1.5px;
    text-transform: uppercase;
    transition: color 0.2s var(--ease-out), opacity 0.2s var(--ease-out);
    cursor: pointer;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    min-height: 44px;
    display: flex;
    align-items: center;
}

.nav-brand:hover {
    color: var(--accent-color);
    transition: color 0.1s ease;
}

.nav-brand:active {
    color: var(--text-primary);
    opacity: 0.8;
    transition: color 0s, opacity 0s;
}

.nav-brand:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Nav Menu */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 3rem;
}

.nav-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 400;
    font-size: 0.94rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    transition: color 0.2s var(--ease-out);
    position: relative;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    padding: 0.5rem 0;
    min-height: 44px;
    display: flex;
    align-items: center;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: width 0.3s cubic-bezier(0.25, 0.1, 0.25, 1);
    transform: translateZ(0);
    backface-visibility: hidden;
}

.nav-menu a:hover {
    color: var(--text-primary);
}

.nav-menu a:active {
    color: var(--text-secondary);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.nav-menu a.active {
    color: var(--text-primary);
}

/* Theme Toggle Button */
.theme-toggle {
    background: transparent;
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s var(--ease-out), transform 0.2s var(--ease-out), color 0.2s var(--ease-out);
    padding: 0;
    margin-left: auto;
    margin-right: 1rem;
    color: var(--text-primary);
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
}

.theme-toggle:hover {
    border: 1px solid var(--border-color-hover);
    background: color-mix(in srgb, var(--text-primary) 5%, transparent);
}

[data-theme="light"] .theme-toggle:hover {
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.theme-toggle:active {
    background: color-mix(in srgb, var(--text-primary) 8%, transparent);
    transform: scale(0.95);
}

.theme-toggle:focus,
.theme-toggle:focus-visible {
    outline: none !important;
    box-shadow: none !important;
}

/* Theme Icons */
.theme-icon {
    width: 20px;
    height: 20px;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    stroke: currentColor;
    backface-visibility: hidden;
    transform-origin: center;
    will-change: opacity, transform;
}

/* Dark mode: show sun (light icon), hide moon (dark icon) */
.theme-icon-dark {
    opacity: 0;
    visibility: hidden;
    transform: rotate(90deg) translateZ(0);
    pointer-events: none;
    transition: opacity 0.2s ease-out 0s, 
                transform 0.3s cubic-bezier(0.25, 0.1, 0.25, 1) 0s,
                visibility 0s linear 0.2s,
                stroke 0.2s ease;
}

.theme-icon-light {
    opacity: 1;
    visibility: visible;
    transform: rotate(0deg) translateZ(0);
    pointer-events: auto;
    transition: opacity 0.2s ease-out 0.1s, 
                transform 0.3s cubic-bezier(0.25, 0.1, 0.25, 1) 0.1s,
                visibility 0s linear 0s,
                stroke 0.2s ease;
}

/* Light mode: show moon (dark icon), hide sun (light icon) */
[data-theme="light"] .theme-icon-dark {
    opacity: 1;
    visibility: visible;
    transform: rotate(0deg) translateZ(0);
    pointer-events: auto;
    transition: opacity 0.2s ease-out 0.1s, 
                transform 0.3s cubic-bezier(0.25, 0.1, 0.25, 1) 0.1s,
                visibility 0s linear 0s,
                stroke 0.2s ease;
}

[data-theme="light"] .theme-icon-light {
    opacity: 0;
    visibility: hidden;
    transform: rotate(-90deg) translateZ(0);
    pointer-events: none;
    transition: opacity 0.2s ease-out 0s, 
                transform 0.3s cubic-bezier(0.25, 0.1, 0.25, 1) 0s,
                visibility 0s linear 0.2s,
                stroke 0.2s ease;
}

/* Theme Icon Hover Effects */
.theme-toggle:hover .theme-icon-dark,
.theme-toggle:active .theme-icon-dark {
    stroke: var(--accent-color);
}

.theme-toggle:hover .theme-icon-light,
.theme-toggle:active .theme-icon-light {
    stroke: #ffd700;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
    position: relative;
    width: 25px;
    height: 19px;
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    user-select: none;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
    position: relative;
    display: block;
}

.hamburger.active span:nth-child(1) {
    position: absolute;
    top: 8px;
    left: 0;
    transform: rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.hamburger.active span:nth-child(3) {
    position: absolute;
    top: 8px;
    left: 0;
    transform: rotate(-45deg);
}

/* ==========================================================================
   6. HERO SECTION
   ========================================================================== */
.hero {
    position: relative;
    height: 100vh;
    min-height: 700px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background: #292929;
    will-change: opacity;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.hero-background-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    z-index: 0;
    object-fit: cover;
    opacity: 0.4;
    transition: opacity 0.3s ease;
    /* Temporarily disabled until video is ready */
    display: none;
}

/* Video de fundal hero – strat GPU separat, fără efecte care provoacă stutter */
.hero-bg-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    object-fit: cover;
    opacity: 0.95;
    pointer-events: none;
    transform: translateZ(0);
    will-change: transform;
}

/* Vignetă + respirație ușoară ca hero-ul să pară viu */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, 
        color-mix(in srgb, var(--text-primary) 2%, transparent) 0%, 
        transparent 70%);
    z-index: 1;
    pointer-events: none;
    animation: heroVignetteBreathe 6s ease-in-out infinite;
}

@keyframes heroVignetteBreathe {
    0%, 100% { opacity: 0.45; }
    50% { opacity: 0.58; }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, 
        rgba(15, 15, 20, 0.22) 0%, 
        rgba(15, 15, 20, 0.32) 100%);
    z-index: 1;
}

/* Fără backdrop-filter peste video – cauzează stutter la redare */
.hero:has(.hero-bg-video) .hero-overlay {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    animation: fadeInUp 0.8s var(--ease-out);
    max-width: 900px;
    padding: 0 2rem;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* CTA lansare – Syne 500; încadrat (inline-block + compensare letter-spacing), sweep fără artefacte */
.hero-video-label {
    position: relative;
    display: inline-block;
    margin: 0 0 1.25rem 0;
    margin-right: -0.2em;
    font-family: 'Syne', 'Poppins', sans-serif;
    font-size: clamp(1.2rem, 2.8vw, 1.45rem);
    font-weight: 500;
    letter-spacing: 0.2em;
    line-height: 1.2;
    text-transform: uppercase;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    animation: fadeIn 1s var(--ease-out) 0.15s both;
    isolation: isolate;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: geometricPrecision;
}

.hero-video-label-text {
    font-family: inherit;
    font-weight: inherit;
    color: #ececec;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Glide: aceleași font/size/weight; layer GPU + clip pentru sweep fără buguri */
.hero-video-label-glide {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    display: block;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    line-height: inherit;
    white-space: nowrap;
    color: transparent;
    background: linear-gradient(
        135deg,
        transparent 0%,
        transparent 47%,
        #ffffff 49.5%,
        #ffffff 50.5%,
        transparent 53%,
        transparent 100%
    );
    background-size: 260% 260%;
    background-repeat: no-repeat;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    filter: drop-shadow(0 0 8px rgba(201, 162, 39, 0.35));
    animation: heroLabelGlide 4.45s ease-in-out 0.75s infinite;
    pointer-events: none;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.hero-video-label-highlight {
    font-weight: 500;
    letter-spacing: 0.2em;
}

/* Hero video thumbnail - click deschide YouTube; zoom subtil la hover în frame */
.hero-video-wrap {
    display: block;
    position: relative;
    width: 100%;
    max-width: 1280px;
    border-radius: 8px;
    overflow: hidden;
    animation: fadeIn 1s var(--ease-out) 0.2s both;
    text-decoration: none;
    color: inherit;
    box-shadow: none;
    transition: box-shadow 0.4s ease-out;
}

.hero-video-thumb {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    vertical-align: top;
    transition: transform 0.4s ease-out;
}

.hero-video-wrap:hover .hero-video-thumb {
    transform: scale(1.02);
}

.hero-video-wrap:hover .hero-video-play {
    transform: translate(-50%, -50%) scale(1.05);
}

.hero-video-wrap:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 4px;
}

/* Premium hover: glow soft la preview YouTube – dark și light */
@media (hover: hover) and (pointer: fine) {
    .hero-video-wrap:hover {
        box-shadow: 0 20px 56px -12px var(--hero-preview-glow);
    }
}

.hero-video-play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 68px;
    height: 48px;
    z-index: 2;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.5));
    pointer-events: none;
    will-change: transform;
    transition: transform 0.25s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.hero-video-play svg {
    display: block;
    width: 100%;
    height: 100%;
}

/* Buton roșu YouTube, triunghi alb */
.hero-video-play svg path:first-of-type {
    fill: #ff0000;
}

.hero-video-play svg path:last-of-type {
    fill: #fafafa;
}

.hero-badge {
    display: inline-block;
    padding: 0.4rem 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.12); /* Subtle border, main separation comes from text */
    border-radius: 0;
    margin-bottom: 3rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.95); /* Increased for better text visibility */
    font-weight: 300;
    letter-spacing: 3px;
    text-transform: uppercase;
    animation: fadeIn 0.8s var(--ease-out) 0.2s both;
    background: transparent; /* Rely on hero overlay; avoid extra block of contrast */
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35); /* Slight shadow just for readability */
}

.hero-title {
    font-size: clamp(2.5rem, 7vw, 5.5rem);
    font-weight: 300; /* FIX: Changed from 200 (no font available) to 300 */
    margin: 0 0 3.5rem 0;
    color: #fafafa;
    letter-spacing: 2px;
    line-height: 1.15;
    text-transform: uppercase;
    animation: fadeIn 1s var(--ease-out) 0.3s both;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 0;
}

.hero-logo {
    width: clamp(280px, 55vw, 600px);
    max-width: 90%;
    height: auto;
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 2px 20px rgba(0, 0, 0, 0.4));
    color: #fefefe;
    flex-shrink: 0;
}

.hero-subtitle {
    font-size: clamp(0.94rem, 2vw, 1.06rem);
    color: rgba(255, 255, 255, 0.85);
    margin: 0 0 3rem 0;
    font-weight: 400;
    letter-spacing: 1.5px;
    line-height: 1.5;
    text-transform: uppercase;
    animation: fadeIn 1s var(--ease-out) 0.5s both;
    text-align: center;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    animation: fadeIn 0.8s var(--ease-out) 0.6s both;
    width: 100%;
}

.hero-buttons .btn svg {
    width: 16px;
    height: 16px;
    transition: var(--transition-fast);
    fill: currentColor;
}

.hero-buttons .btn:hover svg {
    transform: translateX(3px);
    fill: #fafafa;
    transition: transform 0.15s var(--ease-out), fill 0.15s var(--ease-out);
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.mouse {
    width: 22.5px;
    height: 37.5px;
    border: 1.5px solid rgba(255, 255, 255, 0.6);
    border-radius: 11.25px;
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 6px;
    animation: mouseFloat 2s ease-in-out infinite;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    background: rgba(0, 0, 0, 0.2);
}

.mouse-wheel {
    width: 3px;
    height: 7.5px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 1.5px;
    animation: scrollWheel 1.5s ease-in-out infinite;
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
}

