/* Shared styles for the /transcend/ pages.
   Header, nav, mobile menu, footer and tokens mirror index.html / projects.html. */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:         #0C0B09;
  --surface:    #131210;
  --card:       #1A1916;
  --gold:       #C9A227;
  --gold-dim:   rgba(201, 162, 39, 0.15);
  --gold-mid:   rgba(201, 162, 39, 0.4);
  --cream:      #F2EDE4;
  --cream-dim:  rgba(242, 237, 228, 0.6);
  --muted:      #9E9890;
  --border:     rgba(201, 162, 39, 0.12);
  --ease-out:   cubic-bezier(0.22, 1, 0.36, 1);
}

html { scroll-behavior: smooth; scroll-padding-top: 110px; }

body {
  background: var(--bg);
  color: var(--cream);
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  line-height: 1.6;
  overflow-x: hidden;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  opacity: 0.3;
}

::selection { background: var(--gold); color: var(--bg); }

.display {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  line-height: 0.95;
  letter-spacing: -0.02em;
}

em {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-weight: 300;
}

/* ---- Header ---- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 64px;
  transition: transform 0.5s var(--ease-out);
}

.site-logo-fixed { display: block; flex-shrink: 0; }

.site-logo-fixed img {
  height: 150px;
  width: auto;
  display: block;
  filter: drop-shadow(0 2px 12px rgba(0,0,0,0.4));
  transition: opacity 0.3s var(--ease-out);
}

.site-logo-fixed img:hover { opacity: 0.8; }

nav {
  display: flex;
  align-items: center;
  background: rgba(19, 18, 16, 0.88);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 10px 10px 10px 24px;
  white-space: nowrap;
}

.nav-links { display: flex; gap: 4px; list-style: none; }

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 7px 14px;
  border-radius: 100px;
  transition: color 0.3s var(--ease-out), background 0.3s var(--ease-out);
}

.nav-links a:hover { color: var(--cream); background: rgba(196, 169, 98, 0.1); }

.nav-cta {
  margin-left: 8px;
  background: var(--gold) !important;
  color: #0C0B09 !important;
  font-weight: 500 !important;
  padding: 8px 20px !important;
}

.nav-cta:hover { background: rgba(196,169,98,0.15) !important; color: var(--gold) !important; }

.nav-burger {
  display: none;
  background: none;
  border: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 36px;
  margin-right: 2px;
  cursor: pointer;
}

.nav-burger span { display: block; width: 18px; height: 1.5px; background: var(--cream); }

@media (max-width: 900px) {
  .site-header { padding: 16px 24px; align-items: center; }
  nav { padding: 8px 8px 8px 18px; }
  .nav-links li:not(:last-child) { display: none; }
  .nav-burger { display: flex; }
  .site-logo-fixed img { height: 64px; }
}

/* ---- Mobile menu ---- */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 1500;
  background: rgba(12, 11, 9, 0.97);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s var(--ease-out);
}

.mobile-menu.open { opacity: 1; pointer-events: auto; }

.mobile-menu-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: none;
  border: 1px solid var(--gold-dim);
  color: var(--cream);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.mobile-menu ul {
  list-style: none;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mobile-menu a {
  font-family: 'Cormorant Garamond', serif;
  font-size: 40px;
  font-weight: 300;
  color: var(--cream);
  text-decoration: none;
  line-height: 1.3;
}

.mobile-menu a:hover { color: var(--gold); }

.mm-num {
  font-family: 'DM Sans', sans-serif;
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--gold);
  vertical-align: super;
  margin-right: 10px;
}

.mm-contact {
  margin-top: 36px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  line-height: 1.9;
}

html.menu-open, html.menu-open body { overflow: hidden; }

/* ---- Document layout ---- */
.doc {
  max-width: 780px;
  margin: 0 auto;
  padding: 240px 24px 120px;
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 24px;
}

.eyebrow::before {
  content: '';
  width: 24px;
  height: 1px;
  background: var(--gold);
  flex-shrink: 0;
}

.doc h1 {
  font-size: clamp(48px, 7vw, 88px);
  color: var(--cream);
  margin-bottom: 20px;
}

.updated {
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding-bottom: 32px;
  margin-bottom: 40px;
  border-bottom: 1px solid var(--border);
}

.doc h2 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: 30px;
  line-height: 1.2;
  color: var(--cream);
  margin: 52px 0 16px;
}

.doc h3 {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 28px 0 10px;
}

.doc p,
.doc li {
  font-size: 16px;
  line-height: 1.8;
  color: var(--cream-dim);
}

.doc p { margin-bottom: 16px; }

.doc ul,
.doc ol { padding-left: 22px; margin-bottom: 16px; }

.doc li { margin-bottom: 8px; }
.doc li::marker { color: var(--gold); }

.doc strong { color: var(--cream); font-weight: 500; }

.doc a { color: var(--gold); text-underline-offset: 3px; }
.doc a:hover { color: var(--cream); }

.note {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px 28px;
  margin: 24px 0;
}

.note p:last-child { margin-bottom: 0; }

.doc-links {
  display: grid;
  gap: 14px;
  margin: 32px 0 40px;
  padding: 0;
  list-style: none;
}

.doc-links li { margin: 0; }

.doc-links a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  text-decoration: none;
  color: var(--cream);
  font-family: 'Cormorant Garamond', serif;
  font-size: 24px;
  transition: border-color 0.3s var(--ease-out), background 0.3s var(--ease-out);
}

.doc-links a::after { content: '→'; font-family: 'DM Sans', sans-serif; font-size: 16px; color: var(--gold); }
.doc-links a:hover { border-color: var(--gold-mid); background: var(--card); color: var(--cream); }

.doc-nav {
  margin-top: 64px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 12px 28px;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.doc-nav a { text-decoration: none; }

/* ---- Footer ---- */
footer {
  background: var(--surface);
  padding: 64px 64px 40px;
  border-top: 1px solid var(--border);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 60px;
  margin-bottom: 60px;
}

.footer-logo-img { height: 160px; width: auto; display: block; margin-bottom: 20px; }

.footer-tag { font-size: 14px; color: var(--muted); line-height: 1.75; max-width: 260px; }

.footer-col h4 {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 20px;
}

.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }

.footer-col a { font-size: 14px; color: var(--muted); text-decoration: none; transition: color 0.2s; }
.footer-col a:hover { color: var(--cream); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}

.footer-copy { font-size: 13px; color: var(--muted); }
.footer-legal { display: flex; gap: 24px; }

.footer-legal a { font-size: 12px; color: var(--muted); text-decoration: none; transition: color 0.2s; }
.footer-legal a:hover { color: var(--cream); }

@media (max-width: 768px) {
  .doc { padding: 130px 24px 80px; }
  .doc h2 { font-size: 26px; }
  footer { padding: 60px 24px 40px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
  .footer-grid > *:first-child { grid-column: 1 / -1; }
  .footer-bottom { flex-direction: column; gap: 16px; text-align: center; }
}
