/* ============================================================
   ALVENTOR — Custom Styles
   ============================================================ */

html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; }

/* Scrollbar */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: #f6f3f5; }
::-webkit-scrollbar-thumb { background: #0b1f3a; border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: #C49A3C; }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

.reveal-left {
  opacity: 0;
  transform: translateX(-28px);
  transition: opacity 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.reveal-left.visible { opacity: 1; transform: translateX(0); }

.reveal-right {
  opacity: 0;
  transform: translateX(28px);
  transition: opacity 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              transform 0.65s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.reveal-right.visible { opacity: 1; transform: translateX(0); }

/* Stagger delays */
.stagger > :nth-child(1) { transition-delay: 0ms; }
.stagger > :nth-child(2) { transition-delay: 110ms; }
.stagger > :nth-child(3) { transition-delay: 220ms; }
.stagger > :nth-child(4) { transition-delay: 330ms; }
.stagger > :nth-child(5) { transition-delay: 440ms; }
.stagger > :nth-child(6) { transition-delay: 550ms; }

/* ============================================================
   PAGE TRANSITION CURTAIN
   ============================================================ */
#page-curtain {
  position: fixed;
  inset: 0;
  background: #0b1f3a;
  z-index: 9999;
  pointer-events: none;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s cubic-bezier(0.76, 0, 0.24, 1);
}
#page-curtain.closing {
  transform: scaleX(1);
  transform-origin: left;
  pointer-events: all;
}
#page-curtain.opening {
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.45s cubic-bezier(0.76, 0, 0.24, 1) 0.05s;
}

/* ============================================================
   SCROLL PROGRESS BAR
   ============================================================ */
#scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0;
  background: #C49A3C;
  z-index: 9998;
  transition: width 0.1s linear;
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav-link {
  position: relative;
  padding-bottom: 2px;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: #C49A3C;
  transition: width 0.25s ease;
}
.nav-link:hover::after,
.nav-link.active::after { width: 100%; }
.nav-link.active { color: #0b1f3a !important; }

#main-nav {
  transition: box-shadow 0.3s ease;
}
#main-nav.scrolled {
  box-shadow: 0 1px 24px rgba(11, 31, 58, 0.1);
}

/* Mobile menu */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  height: 100vh;
  width: 300px;
  background: white;
  z-index: 200;
  transform: translateX(100%);
  transition: transform 0.38s cubic-bezier(0.76, 0, 0.24, 1);
  box-shadow: -8px 0 32px rgba(0, 0, 0, 0.12);
  padding: 5rem 2rem 2rem;
  display: flex;
  flex-direction: column;
}
.mobile-menu.open { transform: translateX(0); }

.menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 6, 21, 0.55);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.menu-overlay.visible { opacity: 1; pointer-events: all; }

/* Hamburger animation */
.hamburger-bar {
  display: block;
  width: 22px;
  height: 2px;
  background: #0b1f3a;
  transition: all 0.3s ease;
  transform-origin: center;
}
.hamburger.open .hamburger-bar:nth-child(1) { transform: rotate(45deg) translate(3px, 3px); }
.hamburger.open .hamburger-bar:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open .hamburger-bar:nth-child(3) { transform: rotate(-45deg) translate(3px, -3px); }

/* ============================================================
   HERO ANIMATIONS
   ============================================================ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hero-line { opacity: 0; animation: fadeInUp 0.75s ease forwards; }
.hero-line:nth-child(1) { animation-delay: 0.1s; }
.hero-line:nth-child(2) { animation-delay: 0.28s; }
.hero-line:nth-child(3) { animation-delay: 0.46s; }
.hero-line:nth-child(4) { animation-delay: 0.64s; }
.hero-line:nth-child(5) { animation-delay: 0.82s; }

/* ============================================================
   TECHNICAL GRID BACKGROUND
   ============================================================ */
.technical-grid-bg {
  background-image: radial-gradient(#c4c6ce 0.5px, transparent 0.5px);
  background-size: 24px 24px;
}

/* ============================================================
   CARDS & IMAGES
   ============================================================ */
.card-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card-lift:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 48px rgba(11, 31, 58, 0.13);
}

.grayscale-hover {
  filter: grayscale(1);
  transition: filter 0.65s ease, transform 0.65s ease;
}
.group:hover .grayscale-hover {
  filter: grayscale(0);
  transform: scale(1.05);
}

/* Gold accent elements */
.gold-bar {
  width: 40px;
  height: 2px;
  background: #C49A3C;
  display: block;
}

/* ============================================================
   ADMIN PANEL
   ============================================================ */
.tab-content { display: none; }
.tab-content.active { display: block; }

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}
.modal-overlay.show { opacity: 1; pointer-events: all; }

.modal-box {
  background: white;
  width: 90%;
  max-width: 660px;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2.5rem;
  transform: translateY(16px);
  transition: transform 0.2s ease;
}
.modal-overlay.show .modal-box { transform: translateY(0); }

/* Toast */
#toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: #0b1f3a;
  color: white;
  padding: 14px 24px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  z-index: 999;
  transform: translateY(80px);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  border-left: 4px solid #C49A3C;
}
#toast.show { transform: translateY(0); opacity: 1; }

/* Fade-in for dynamically rendered cards */
@keyframes cardAppear {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
.card-appear { animation: cardAppear 0.45s ease forwards; }
