/* =====================================================
   Prime Axiom — Shared Stylesheet
   Loaded by all pages. Page-specific overrides stay
   in inline <style> blocks in each HTML file.
   ===================================================== */

/* ─── RESET + VARIABLES ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --black: #080808;
  --void: #0d0d0d;
  --surface: #111111;
  --border: #1e1e1e;
  --border-light: #2a2a2a;
  --text: #e8e4dc;
  --text-dim: #6b6560;
  --text-mid: #9e9890;
  --gold: #c9a96e;
  --gold-dim: #7a6240;
  --white: #f5f2ee;
}

html { scroll-behavior: smooth; }

body {
  background: var(--black);
  color: var(--text);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 18px;
  line-height: 1.6;
  overflow-x: hidden;
}

/* Grid background */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(201,169,110,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(201,169,110,0.03) 1px, transparent 1px);
  background-size: 80px 80px;
  pointer-events: none;
  z-index: 0;
}

/* Noise overlay */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  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)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: 0.4;
  pointer-events: none;
  z-index: 0;
}

/* ─── NAV ─── */
/* Base: always-opaque. index.html overrides to transparent via inline <style>. */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 60px;
  border-bottom: 1px solid var(--border);
  background: rgba(8,8,8,0.92);
  backdrop-filter: blur(12px);
}

/* Added by index.html JS on scroll — restores opacity after transparent override */
nav.scrolled {
  border-color: var(--border);
  background: rgba(8,8,8,0.92);
  backdrop-filter: blur(12px);
}

.nav-logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-decoration: none;
}
.nav-logo-prime {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.3em;
  color: var(--gold);
  text-transform: uppercase;
}
.nav-logo-axiom {
  font-family: 'Cormorant Garamond', serif;
  font-size: 22px;
  font-weight: 300;
  letter-spacing: 0.08em;
  color: var(--white);
}

.nav-links {
  display: flex;
  gap: 48px;
  list-style: none;
}
.nav-links a {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-mid);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); }
.nav-links a.active { color: var(--gold); }

.nav-cta {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
  border: 1px solid var(--gold-dim);
  padding: 10px 24px;
  transition: all 0.2s;
}
.nav-cta:hover {
  background: var(--gold);
  color: var(--black);
}

/* Back link used on legal pages instead of nav-links */
.nav-back {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-mid);
  text-decoration: none;
  transition: color 0.2s;
  display: flex;
  align-items: center;
  gap: 10px;
}
.nav-back::before {
  content: '←';
  font-size: 14px;
}
.nav-back:hover { color: var(--gold); }

.nav-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 201;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 1px;
  background: var(--text-mid);
  transition: all 0.25s ease;
  transform-origin: center;
}
.nav-burger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); background: var(--text); }
.nav-burger.open span:nth-child(2) { opacity: 0; }
.nav-burger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); background: var(--text); }

/* ─── DIVIDER ─── */
.section-divider {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 0 60px;
}
.divider-line {
  flex: 1;
  height: 1px;
  background: var(--border);
}
.divider-mark {
  width: 6px;
  height: 6px;
  border: 1px solid var(--gold-dim);
  transform: rotate(45deg);
  flex-shrink: 0;
}

/* ─── FOOTER ─── */
footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--border);
  padding: 48px 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-decoration: none;
}
.footer-logo-prime {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--gold);
  text-transform: uppercase;
}
.footer-logo-axiom {
  font-size: 18px;
  font-weight: 300;
  color: var(--text-mid);
}

.footer-tagline {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--text-dim);
  text-transform: uppercase;
}

.footer-right {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  gap: 32px;
}

.footer-legal {
  display: flex;
  gap: 24px;
  list-style: none;
}
.footer-legal a {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--text-dim);
  text-decoration: none;
  text-transform: uppercase;
  transition: color 0.2s;
}
.footer-legal a:hover { color: var(--gold); }

/* Used by legal pages (ochrana, obchodne) */
.footer-links {
  display: flex;
  gap: 32px;
  list-style: none;
}
.footer-links a {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--text-dim);
  text-transform: uppercase;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover, .footer-links a.active { color: var(--gold); }

/* ─── COOKIE BANNER ─── */
#cookieBanner {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  background: var(--surface);
  border: 1px solid var(--border-light);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 20px;
  max-width: 560px;
  width: calc(100% - 48px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.6);
}
#cookieBanner p {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  line-height: 1.7;
  flex: 1;
}
#cookieBanner a {
  color: var(--gold-dim);
  text-decoration: none;
}
#cookieBanner a:hover { color: var(--gold); }
#cookieBannerAccept {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  font-weight: 300;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--black);
  background: var(--gold-dim);
  border: none;
  padding: 8px 18px;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s;
}
#cookieBannerAccept:hover { background: var(--gold); }

/* ─── ANIMATIONS ─── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ─── MOBILE ─── */
@media (max-width: 768px) {
  nav {
    padding: 20px 24px;
    backdrop-filter: none;
  }
  /* Disable backdrop-filter on mobile to prevent fixed overlay clipping */
  nav.scrolled {
    backdrop-filter: none;
  }

  .nav-links {
    display: none;
    position: fixed;
    inset: 0;
    background: var(--black);
    z-index: 200;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 36px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { font-size: 13px; letter-spacing: 0.3em; }
  .nav-cta { display: none; }
  .nav-burger { display: flex; }

  .section-divider { padding: 0 24px; }

  footer {
    flex-direction: column;
    align-items: center;
    gap: 20px;
    text-align: center;
    padding: 40px 24px;
  }
  .footer-legal { flex-wrap: wrap; justify-content: center; gap: 16px; }
  .footer-links { flex-wrap: wrap; justify-content: center; gap: 16px; }
}
