/* ============================================================
   main.css — JC Laboratories
   Shared styles across all pages
   ============================================================ */

/* ── Variables ─────────────────────────────────────────────── */
:root {
  --gold:          #B8A058;
  --gold-light:    #D4BC76;
  --gold-dark:     #8B7535;
  --gold-muted:    #6B5A28;
  --bg:            #0A0A0A;
  --surface:       #141414;
  --surface-high:  #1E1E1E;
  --border:        #242424;
  --text:          #E8E0D0;
  --text-muted:    #6A6258;
  --text-secondary:#9A9088;
  --red:           #7A1515;
  --red-light:     #C0392B;
  --green:         #4CAF50;
  --green-dark:    #2A5A2A;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'EB Garamond', Georgia, serif;
  font-size: 17px;
  line-height: 1.7;
  overflow-x: hidden;
}

/* ── Noise overlay ─────────────────────────────────────────── */
body::before {
  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.03'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.4;
}

/* ── Navigation ────────────────────────────────────────────── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 64px;
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.nav-logo-img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--gold-muted);
  flex-shrink: 0;
}

.nav-name {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  list-style: none;
}

.nav-links a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  text-decoration: none;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--gold); }

.nav-cta {
  color: var(--gold) !important;
  border: 1px solid var(--gold-muted);
  padding: 8px 20px;
  border-radius: 2px;
  transition: all 0.2s !important;
}

.nav-cta:hover {
  background: var(--gold-muted) !important;
  color: var(--bg) !important;
}

.nav-back {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
  text-decoration: none;
  letter-spacing: 1px;
  transition: color 0.2s;
}

.nav-back:hover { color: var(--gold); }

/* ── Mobile nav toggle ─────────────────────────────────────── */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
}

.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--gold);
  border-radius: 1px;
  transition: all 0.3s;
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn-primary {
  font-family: 'Cinzel', serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--bg);
  background: var(--gold);
  border: none;
  padding: 16px 40px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  display: inline-block;
}

.btn-primary:hover {
  background: var(--gold-light);
  transform: translateY(-1px);
}

.btn-secondary {
  font-family: 'Cinzel', serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--gold);
  background: transparent;
  border: 1px solid var(--gold-muted);
  padding: 16px 40px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  display: inline-block;
}

.btn-secondary:hover {
  border-color: var(--gold);
  background: rgba(184,160,88,0.06);
}

/* ── Info/Warning boxes ────────────────────────────────────── */
.highlight {
  background: var(--surface);
  border-left: 3px solid var(--gold);
  padding: 16px 20px;
  margin: 24px 0;
  border-radius: 0 6px 6px 0;
  font-style: italic;
  color: var(--text-muted);
}

.warning-box,
.warning {
  background: var(--surface);
  border-left: 3px solid var(--red);
  padding: 16px 20px;
  margin: 24px 0;
  border-radius: 0 6px 6px 0;
  color: var(--text-muted);
}

/* ── Tier table (shared) ───────────────────────────────────── */
.tier-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  font-size: 14px;
}

.tier-table th {
  background: var(--surface);
  color: var(--gold);
  font-family: 'Cinzel', serif;
  font-size: 11px;
  letter-spacing: 1px;
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.tier-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: top;
}

.tier-table tr:last-child td { border-bottom: none; }

/* ── Footer ────────────────────────────────────────────────── */
footer {
  padding: 48px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 48px;
  border-top: 1px solid var(--border);
}

.footer-brand .logo-img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--gold-muted);
  display: block;
  margin-bottom: 12px;
}

.footer-brand .name {
  font-family: 'Cinzel', serif;
  font-size: 13px;
  color: var(--text);
  letter-spacing: 2px;
  display: block;
  margin-bottom: 12px;
}

.footer-brand p {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer-links h4 {
  font-family: 'Cinzel', serif;
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 2px;
  margin-bottom: 16px;
}

.footer-links ul { list-style: none; }

.footer-links li { margin-bottom: 10px; }

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

.footer-links a:hover { color: var(--gold); }

.footer-bottom {
  grid-column: 1 / -1;
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--text-muted);
}

/* Doc pages footer (privacy/terms) */
footer.doc-footer {
  display: block;
  text-align: center;
  padding: 32px;
  font-size: 13px;
  grid-template-columns: unset;
}

footer.doc-footer a {
  color: var(--gold);
  text-decoration: none;
}

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

/* ── Links ─────────────────────────────────────────────────── */
a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 768px) {
  nav { padding: 0 24px; }

  .nav-links { display: none; }
  .nav-links.open { display: flex; flex-direction: column; position: fixed; top: 64px; left: 0; right: 0; background: var(--bg); border-bottom: 1px solid var(--border); padding: 24px; gap: 20px; z-index: 99; }
  .nav-hamburger { display: flex; }

  footer {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 32px 24px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }
}
