/* ===== RESET & BASE ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

img {
    display: block;
    max-width: 100%;
}

/* ===== NAVIGATION ===== */
.nav-fixed {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transition: background-color 0.4s ease, backdrop-filter 0.4s ease;
}

.nav-fixed.scrolled {
    background-color: rgba(7, 31, 42, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: currentColor;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Mobile menu */
.menu-line {
    display: block;
}

#menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}

#menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-toggle.active .menu-line:nth-child(3) {
    width: 1.5rem;
    transform: rotate(-45deg) translate(3px, -3px);
}

#mobile-menu.open {
    transform: translateX(0);
}

.mobile-link {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* ===== HERO ===== */
.hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.hero-img {
    transform: scale(1.05);
    animation: heroZoom 20s ease-out forwards;
}

@keyframes heroZoom {
    from { transform: scale(1.08); }
    to { transform: scale(1); }
}

.hero-overlay {
    background: linear-gradient(
        to bottom,
        rgba(7, 31, 42, 0.55) 0%,
        rgba(7, 31, 42, 0.40) 40%,
        rgba(7, 31, 42, 0.65) 70%,
        rgba(7, 31, 42, 0.95) 100%
    );
}

.writing-mode-vertical {
    writing-mode: vertical-rl;
    text-orientation: mixed;
}

/* ===== SCROLL REVEALS ===== */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
    }

    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }

    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* ===== FORM ===== */
input:focus,
textarea:focus {
    outline: none;
}

input::placeholder,
textarea::placeholder {
    color: rgba(255, 255, 255, 0.2);
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #071F2A;
}

::-webkit-scrollbar-thumb {
    background: rgba(42, 157, 111, 0.3);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(42, 157, 111, 0.5);
}

/* ===== SELECTION ===== */
::selection {
    background: rgba(42, 157, 111, 0.3);
    color: #D8F5E8;
}

/* ===== FOCUS VISIBLE ===== */
:focus-visible {
    outline: 2px solid #4ABF8F;
    outline-offset: 2px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .nav-fixed {
        background-color: rgba(7, 31, 42, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
    }
}
