/* ════════════════════════════════════════════════
   SHARED STYLES — fonts, colors, nav, footer
   Used by every page. Edit nav/footer once, here.
   ════════════════════════════════════════════════ */

@font-face { font-family: 'ZTNature'; src: url('fonts/ZTNature-100.ttf') format('truetype'); font-weight: 100; font-style: normal; }
@font-face { font-family: 'ZTNature'; src: url('fonts/ZTNature-100-italic.ttf') format('truetype'); font-weight: 100; font-style: italic; }
@font-face { font-family: 'ZTNature'; src: url('fonts/ZTNature-500.ttf') format('truetype'); font-weight: 500; font-style: normal; }
@font-face { font-family: 'ZTNature'; src: url('fonts/ZTNature-500-italic.ttf') format('truetype'); font-weight: 500; font-style: italic; }
@font-face { font-family: 'ZTNature'; src: url('fonts/ZTNature-900.ttf') format('truetype'); font-weight: 900; font-style: normal; }
@font-face { font-family: 'ZTNature'; src: url('fonts/ZTNature-900-italic.ttf') format('truetype'); font-weight: 900; font-style: italic; }

:root {
  --navy: #002b62;
  --majorelle: #5c5bee;
  --periwinkle: #9c9afe;
  --lemon: #d7e82b;
  --lime: #94c428;
  --forest: #006042;
  --white: #ffffff;
  --carbon: #1e1e1e;
  --sky: #afd9e9;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--majorelle); }
body { font-family: 'ZTNature', sans-serif; overflow-x: hidden; }

/* ── NAVBAR — logo left, animated menu button top right ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 3rem;
  background: var(--navy);
  border-bottom: 2px solid var(--lemon);
  box-shadow: 0 2px 24px rgba(0,0,0,0.25);
}
.nav-logo img { height: 52px; width: 52px; object-fit: cover; border-radius: 8px; display: block; }

/* Menu button — mobile only; static logo that plays its animation when pressed */
.nav-menu-btn {
  display: none;
  background: none; border: none; padding: 0; cursor: pointer;
  position: relative; height: 52px; width: 52px;
  transition: transform 0.15s;
}
.nav-menu-btn:hover { transform: scale(1.06); }
.nav-menu-btn img,
.nav-menu-btn video {
  height: 52px; width: 52px; object-fit: cover;
  border-radius: 8px; display: block;
}
.nav-menu-btn video { position: absolute; inset: 0; display: none; }
.nav-menu-btn.playing video { display: block; }

/* Desktop: links always visible in the navbar (wrapper is layout-transparent) */
.nav-menu-wrap { display: contents; }
.nav-links { display: flex; gap: 2.5rem; list-style: none; align-items: center; }
.nav-links a {
  display: flex; align-items: center;
  font-family: 'ZTNature', sans-serif; font-weight: 500;
  font-size: 0.9rem; color: rgba(255,255,255,0.75); text-decoration: none;
  letter-spacing: 0.06em; text-transform: uppercase; transition: color 0.2s;
  position: relative; padding-bottom: 2px;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0; right: 0;
  height: 2px; background: var(--lemon); border-radius: 2px;
  transform: scaleX(0); transition: transform 0.2s ease;
}
.nav-links a:hover { color: var(--lemon); }
.nav-links a:hover::after { transform: scaleX(1); }
.nav-ico { margin-right: 0.6rem; display: inline-flex; }
.nav-ico svg { width: 17px; height: 17px; display: block; }

/* Mobile: menu covers the whole screen, links drop in one by one */
@keyframes menuItemDrop {
  from { opacity: 0; transform: translateY(-24px); }
  to   { opacity: 1; transform: translateY(0); }
}
/* Mobile: whole menu slides down from the top like a curtain */
@keyframes menuCurtain {
  from { transform: translateY(-100%); }
  to   { transform: translateY(0); }
}
@keyframes menuCurtainUp {
  from { transform: translateY(0); }
  to   { transform: translateY(-100%); }
}
@media (max-width: 768px) {
  /* show the menu button; keep navbar (and animating logo) above the sliding menu */
  .nav-menu-btn { display: block; }
  .nav-logo, .nav-menu-btn { position: relative; z-index: 2; }
  /* clipping window below the navbar — the curtain slides inside it,
     so the navbar and its accent line always stay visible */
  .nav-menu-wrap {
    display: none;
    position: fixed; top: 83px; left: 0; right: 0; bottom: 0;
    overflow: hidden;
  }
  nav.menu-open .nav-menu-wrap, nav.menu-closing .nav-menu-wrap { display: block; }
  .nav-links {
    position: absolute; inset: 0;
    display: flex;
    flex-direction: column;
    background: var(--navy);
    justify-content: center; align-items: center;
    gap: 0.5rem;
  }
  nav.menu-open .nav-links { animation: menuCurtain 0.7s cubic-bezier(0.22, 0.9, 0.36, 1) both; }
  nav.menu-closing .nav-links { animation: menuCurtainUp 0.55s cubic-bezier(0.5, 0, 0.75, 0.4) both; }
  /* close X in the corner — tapping it (or any empty space) closes the menu */
  .nav-links::before {
    content: '✕';
    position: absolute; top: 1.4rem; right: 1.6rem;
    font-size: 1.5rem; color: var(--lemon);
    cursor: pointer;
  }
  .nav-links li { width: min(78vw, 320px); }
  .nav-links li + li { border-top: 1px solid rgba(215,232,43,0.3); }
  .nav-links a { font-size: 1.5rem; padding: 1.6rem 1rem; justify-content: center; color: var(--lemon); }
  .nav-links a::after { display: none; }
  .nav-links a:hover { color: var(--white); }
  .nav-links a.active { color: var(--lemon); background: none; }
  .nav-ico { margin-right: 1rem; }
  .nav-ico svg { width: 30px; height: 30px; }
  nav.menu-open .nav-links li { animation: menuItemDrop 0.5s ease both; }
  nav.menu-open .nav-links li:nth-child(1) { animation-delay: 0.45s; }
  nav.menu-open .nav-links li:nth-child(2) { animation-delay: 0.6s; }
  nav.menu-open .nav-links li:nth-child(3) { animation-delay: 0.75s; }
  nav.menu-open .nav-links li:nth-child(4) { animation-delay: 0.9s; }
}

/* ── FOOTER ── */
footer {
  background: var(--carbon); color: rgba(255,255,255,0.4);
  padding: 2.5rem 4rem;
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem;
}
.footer-logo img { height: 52px; width: 52px; object-fit: cover; border-radius: 6px; }
.footer-links { display: flex; gap: 2rem; list-style: none; }
.footer-links a { color: rgba(255,255,255,0.35); text-decoration: none; font-size: 0.82rem; font-weight: 500; transition: color 0.2s; text-transform: uppercase; letter-spacing: 0.06em; }
.footer-links a:hover { color: var(--lemon); }
.footer-copy { font-size: 0.78rem; font-weight: 500; }

/* ── PAGE TRANSITION ── */
@keyframes pageFadeIn { from { opacity: 0; } to { opacity: 1; } }
body { animation: pageFadeIn 0.4s ease both; }
body.page-exit { opacity: 0; transition: opacity 0.25s ease; animation: none; }

/* ── SHARED RESPONSIVE ── */
@media (max-width: 768px) {
  nav { padding: 0.9rem 1.5rem; }
  footer {
    padding: 2rem 1.5rem;
    flex-direction: column; justify-content: center;
    text-align: center; gap: 1.2rem;
  }
  .footer-links { justify-content: center; flex-wrap: wrap; gap: 1.2rem; }
}
