/* =============================================================
   The Palm Reading — Legal / Info pages bridge
   Used by: contact.html, terms.html, privacy.html, refund.html

   These pages were previously on the standalone shared-styles.css
   design system. This file makes them part of the MAIN site design
   system instead: it is loaded AFTER assets/css/style.css and only
   provides the page-specific layout/components the legal pages need
   (hero, prose, cards, forms, buttons, TOC fade-ups).

   It deliberately does NOT define *, html, body, nav or footer —
   those now come from style.css + the canonical .main-nav / <footer>
   markup, so the legal pages match index / pricing / reader exactly.

   Token-alias trick: the legacy shared-styles.css variable names are
   re-pointed at the main style.css palette. This lets every legal
   page keep its existing inline <style> block untouched while
   rendering in the main brand colours.
   ============================================================= */

:root {
  /* Legacy shared-styles names → main style.css palette */
  --gold-light:   var(--gold-soft);     /* #e6c478 */
  --gold-dim:     var(--gold-deep);     /* #a37b34 */
  --purple:       var(--plum);          /* #4a2d8a */
  --purple-light: var(--aurora);        /* #b89cff */
  --bg:           var(--void);          /* #07060f */
  --bg-card:      var(--surface-glass); /* raised glass, matches .hw-card */
  --bg-mid:       var(--abyss);         /* #0c0a1a */
  --text-dim:     var(--text-muted);    /* #9b94b8 */
  /* --gold, --text, --border, --radius intentionally NOT redefined:
     they resolve to the main palette automatically (the unification). */
}

/* =============================================================
   Page hero
   ============================================================= */
.page-hero {
  position: relative;
  z-index: 2;
  padding: 9rem 2rem 4rem;
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
}
.hero-eyebrow {
  display: inline-block;
  font-family: 'Cinzel', serif;
  font-size: 0.78rem;
  letter-spacing: 0.32em;
  color: var(--gold);
  text-transform: uppercase;
  padding: 0.55rem 1.4rem;
  border: 1px solid var(--border);
  border-radius: 2rem;
  margin-bottom: 2rem;
  background: rgba(212, 168, 87, 0.05);
}
.page-hero h1 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 1.15;
  margin-bottom: 1.2rem;
  color: var(--text);
}
.page-hero h1 em {
  color: var(--gold);
  font-style: italic;
  -webkit-text-fill-color: currentColor; /* cancel style.css gradient-clip */
  background: none;
}
.page-hero .lede {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 640px;
  margin: 0 auto 1.5rem;
}
.updated-badge {
  display: inline-block;
  font-family: 'Cinzel', serif;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--text-muted);
  padding: 0.4rem 1rem;
  border: 1px solid var(--border);
  border-radius: 2rem;
  margin-top: 0.5rem;
  text-transform: uppercase;
}

/* =============================================================
   Content wrap
   ============================================================= */
.content-wrap {
  position: relative;
  z-index: 2;
  max-width: 760px;
  margin: 0 auto;
  padding: 2rem 1.5rem 5rem;
}
.content-wrap.wide {
  max-width: 1100px;
}
/* Neutralise style.css's global `section { padding: 7rem 0 }`
   for the in-content section blocks. */
.content-wrap section {
  padding: 0;
  position: relative;
}

/* =============================================================
   Prose typography — scoped so it beats style.css globals only
   inside legal content (nav/footer keep the main styling).
   ============================================================= */
.content-wrap h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.01em;
  margin: 2.5rem 0 1.1rem;
  line-height: 1.25;
}
.content-wrap h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--gold-soft);
  margin: 1.6rem 0 0.7rem;
  letter-spacing: 0.02em;
}
.content-wrap p {
  color: var(--text);
  margin-bottom: 1.1rem;
  font-size: 1rem;
  line-height: 1.75;
}
.content-wrap a {
  color: var(--gold-soft);
  text-decoration: none;
  border-bottom: 1px solid rgba(212, 168, 87, 0.3);
  transition: all 0.2s;
}
.content-wrap a:hover {
  color: var(--gold);
  border-bottom-color: var(--gold);
}
.content-wrap ul,
.content-wrap ol {
  margin: 0.8rem 0 1.4rem 1.4rem;
  color: var(--text);
}
.content-wrap li {
  margin-bottom: 0.55rem;
  line-height: 1.7;
}
.content-wrap ul li::marker {
  color: var(--gold);
}
.content-wrap ol li::marker {
  color: var(--gold);
  font-family: 'Cinzel', serif;
}
.content-wrap strong {
  color: var(--gold-soft);
  font-weight: 600;
}

/* =============================================================
   Card component (scoped — style.css has its own .card)
   ============================================================= */
.content-wrap .card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.2rem;
  margin: 1.5rem 0;
  overflow: hidden;
}
.content-wrap .card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--gold) 50%, transparent 100%);
}

/* Gold divider */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--gold-deep) 50%, transparent 100%);
  margin: 3rem 0;
  border: none;
}

/* =============================================================
   Buttons (scoped — style.css has its own .btn / .btn-primary)
   ============================================================= */
.content-wrap .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.95rem 1.8rem;
  font-family: 'Cinzel', serif;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s;
  font-weight: 500;
}
.content-wrap .btn-gold {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-soft) 100%);
  color: var(--void);
  border: 1px solid var(--gold);
}
.content-wrap .btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(212, 168, 87, 0.25);
  color: var(--void);
  border-bottom-color: var(--gold);
}
.content-wrap .btn-outline {
  background: transparent;
  color: var(--gold);
  border: 1px solid var(--gold);
}
.content-wrap .btn-outline:hover {
  background: rgba(212, 168, 87, 0.08);
  color: var(--gold-soft);
  border-color: var(--gold-soft);
}
.content-wrap .btn svg {
  width: 16px;
  height: 16px;
}

/* =============================================================
   Forms (scoped to legal content)
   ============================================================= */
.content-wrap label {
  display: block;
  font-family: 'Cinzel', serif;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.5rem;
  font-weight: 500;
}
.content-wrap .form-group {
  margin-bottom: 1.4rem;
}
.content-wrap .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.content-wrap input,
.content-wrap textarea,
.content-wrap select {
  width: 100%;
  padding: 0.95rem 1rem;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 400;
  transition: border-color 0.25s, background 0.25s;
}
.content-wrap input:focus,
.content-wrap textarea:focus,
.content-wrap select:focus {
  outline: none;
  border-color: var(--gold);
  background: rgba(0, 0, 0, 0.5);
}
.content-wrap input::placeholder,
.content-wrap textarea::placeholder {
  color: var(--text-muted);
  opacity: 0.6;
}
.content-wrap textarea {
  resize: vertical;
  min-height: 140px;
  font-family: 'Inter', sans-serif;
}
.content-wrap select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23d4a857' stroke-width='2'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px;
  padding-right: 2.5rem;
}
.content-wrap select option {
  background: var(--abyss);
  color: var(--text);
}

/* =============================================================
   Scroll-in animations (self-contained, no JS dependency —
   preserves the legal pages' original behaviour)
   ============================================================= */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.fade-up {
  animation: fadeUp 0.8s ease-out forwards;
}
.delay-1 { animation-delay: 0.12s; opacity: 0; }
.delay-2 { animation-delay: 0.24s; opacity: 0; }
.delay-3 { animation-delay: 0.36s; opacity: 0; }

/* =============================================================
   Responsive
   ============================================================= */
@media (max-width: 768px) {
  .content-wrap .form-row {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  .page-hero {
    padding: 7rem 1.2rem 3rem;
  }
  .content-wrap {
    padding: 1.5rem 1rem 3rem;
  }
  .content-wrap .card {
    padding: 1.5rem;
  }
}
