@import url('vars.css');

body {
  background: var(--dark);
  color: var(--text);
  font-family: 'Sora', sans-serif;
  font-weight: 200;
  overflow-x: hidden;
}

body.single-screen {
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

canvas#atmosphere {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
}

.mouse-glow {
  position: fixed;
  width: 600px; height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(212,185,106,0.06) 0%, rgba(139,115,85,0.03) 30%, transparent 70%);
  pointer-events: none;
  z-index: 1;
  will-change: transform;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 999;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px;
}

.page-content {
  position: relative;
  z-index: 2;
}

/* ── NAVBAR ── */

nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 48px;
  background: linear-gradient(to bottom, rgba(10,8,6,0.92) 0%, rgba(10,8,6,0.6) 70%, transparent 100%);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.nav-logo {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-weight: 300;
  font-size: 20px;
  color: var(--text);
  letter-spacing: 1px;
  opacity: 0;
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 36px;
}

.nav-links a {
  font-family: 'Sora', sans-serif;
  font-weight: 300;
  font-size: 11px;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 3px;
  text-transform: uppercase;
  transition: color 0.4s;
  position: relative;
  opacity: 0;
  transform: translateY(-10px);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 1px;
  background: var(--gold);
  transition: width 0.4s ease;
}

.nav-links a:hover { color: var(--text); }
.nav-links a:hover::after { width: 100%; }
.nav-links a.active { color: var(--text); }
.nav-links a.active::after { width: 100%; }

/* ── HAMBURGER (mobile) ── */

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 32px; height: 24px;
  position: relative;
  z-index: 101;
}

.nav-hamburger span {
  display: block;
  width: 100%; height: 1px;
  background: var(--text);
  position: absolute;
  left: 0;
  transition: transform 0.3s, opacity 0.3s;
}

.nav-hamburger span:nth-child(1) { top: 4px; }
.nav-hamburger span:nth-child(2) { top: 11px; }
.nav-hamburger span:nth-child(3) { top: 18px; }

.nav-hamburger.open span:nth-child(1) { top: 11px; transform: rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { top: 11px; transform: rotate(-45deg); }

.nav-mobile-panel {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0;
  background: var(--dark);
  padding: 80px 48px 40px;
  z-index: 99;
  flex-direction: column;
  gap: 24px;
  transform: translateY(-100%);
  transition: transform 0.4s ease;
}

.nav-mobile-panel.open {
  transform: translateY(0);
}

.nav-mobile-panel a {
  font-family: 'Sora', sans-serif;
  font-weight: 300;
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
  letter-spacing: 3px;
  text-transform: uppercase;
}

.nav-mobile-panel a.active { color: var(--text); }

/* ── HERO ── */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.single-screen .hero {
  min-height: 100vh;
  min-height: 100dvh;
  height: 100vh;
  height: 100dvh;
}

.hero-content {
  text-align: center;
  position: relative;
  z-index: 10;
}

.hero-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 30%, rgba(10,8,6,0.7) 100%);
}

/* ── CTA border-reveal ── */

.cta-border-reveal {
  position: relative;
  display: inline-block;
  padding: 16px 48px;
  color: var(--gold);
  font-family: 'Sora', sans-serif;
  font-weight: 300;
  font-size: 11px;
  letter-spacing: 4px;
  text-transform: uppercase;
  text-decoration: none;
  overflow: hidden;
  cursor: pointer;
  background: none;
  border: none;
}

.cta-border-reveal .cta-borders span {
  position: absolute;
  background: var(--gold);
  transition: transform 0.5s cubic-bezier(0.65,0,0.35,1);
}

.cta-border-reveal .cta-borders .top { top:0;left:0;width:100%;height:1px;transform:scaleX(0);transform-origin:left; }
.cta-border-reveal .cta-borders .right { top:0;right:0;width:1px;height:100%;transform:scaleY(0);transform-origin:top; }
.cta-border-reveal .cta-borders .bottom { bottom:0;right:0;width:100%;height:1px;transform:scaleX(0);transform-origin:right; }
.cta-border-reveal .cta-borders .left { bottom:0;left:0;width:1px;height:100%;transform:scaleY(0);transform-origin:bottom; }

.cta-border-reveal:hover .top { transform:scaleX(1);transition-delay:0s; }
.cta-border-reveal:hover .right { transform:scaleY(1);transition-delay:0.12s; }
.cta-border-reveal:hover .bottom { transform:scaleX(1);transition-delay:0.24s; }
.cta-border-reveal:hover .left { transform:scaleY(1);transition-delay:0.36s; }

.cta-border-reveal .cta-text-inner { position:relative;z-index:2; }

.cta-border-reveal .cta-bg {
  position: absolute;
  inset: 0;
  background: rgba(212,185,106,0.08);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s cubic-bezier(0.65,0,0.35,1) 0.15s;
}

.cta-border-reveal:hover .cta-bg { transform: scaleX(1); }

/* ── FOOTER ── */

footer {
  padding: 48px;
  border-top: 1px solid rgba(138,125,109,0.08);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--dark-alt);
}

footer span {
  font-size: 11px;
  color: var(--subtle);
  letter-spacing: 2px;
}

/* ── RESPONSIVE ── */

@media (max-width: 768px) {
  nav { padding: 16px 24px; }
  .nav-links { display: none; }
  .nav-hamburger { display: block; }
  .nav-mobile-panel { display: flex; }
  footer { padding: 32px 24px; }
  .cta-border-reveal { padding: 18px 40px; font-size: 12px; }
}

@media (max-width: 480px) {
  footer { flex-direction: column; gap: 8px; }
}

@media (max-height: 600px) {
  .single-screen .hero-content { transform: scale(0.85); }
}

/* ── REDUCED MOTION ── */

@media (prefers-reduced-motion: reduce) {
  canvas#atmosphere,
  .mouse-glow { display: none !important; }
  .nav-logo { opacity: 0.8 !important; }
  .nav-links a { opacity: 1 !important; transform: none !important; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── TOUCH DEVICE: hide mouse glow ── */

@media (hover: none) {
  .mouse-glow { display: none; }
}

/* ── NAV GALLERY LINK ── */

.nav-gallery-link {
  color: var(--gold) !important;
  opacity: 1 !important;
}

/* ── ANTICAMERA (homepage) ── */

body.anticamera { height: 100vh; height: 100dvh; overflow: hidden; }

body.anticamera nav { background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
body.anticamera .nav-links a { color: rgba(212,196,168,0.2); opacity: 1; transform: none; }
body.anticamera .nav-links a:hover { color: var(--gold); }
body.anticamera .nav-logo { opacity: 1; color: rgba(212,196,168,0.3); }
