/* ===== AvnetTours shared styles ===== */

:root {
  --stone-dark: #2b2016;
  --stone-mid: #4a3722;
  --parchment: #f3ead9;
  --parchment-deep: #e9dcc3;
  --ink: #2b2016;
  --ink-soft: #5c4c38;
  --gold: #b8843f;
  --gold-bright: #c99a52;
  --cream: #f7f1e4;
  --danger: #a5482f;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 64px;
  --radius: 16px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  font-size: 15px;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--ink);
  background: var(--parchment);
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.display { font-family: 'Fraunces', serif; font-optical-sizing: auto; }
a { color: inherit; }

main { flex: 1 0 auto; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 6vw; }
.wrap-narrow { max-width: 760px; margin: 0 auto; padding: 0 6vw; }

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* Security: pages that gate their <main> behind a session/authorization
   check (dashboard.html, console.html, prayer-form.html) start it hidden via
   this class, applied directly in the HTML. This rule is parsed and applied
   before the page can paint anything — not a JS toggle racing against first
   paint — so there is no window in which a signed-out visitor or an
   unauthorized member could glimpse the page's heading/shell while the
   check is still in flight. Each page's own script removes this class only
   after its check explicitly passes; every other path (no session, wrong
   role, unpaid, etc.) redirects away and never removes it. */
.auth-gate-hidden { display: none; }

/* ---------- HEADER ---------- */

.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(26, 18, 10, 0.85);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(247, 241, 228, 0.1);
}
.header-inner {
  max-width: 1180px; margin: 0 auto; height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 6vw;
}
.logo { font-size: 1.05rem; font-weight: 500; color: var(--cream); text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 1.6rem; }
.nav-links a {
  color: rgba(247, 241, 228, 0.8); text-decoration: none;
  font-size: 0.86rem; font-weight: 500; transition: color 0.2s var(--ease);
}
.nav-links a:hover { color: var(--gold-bright); }
.nav-links a:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 3px; }
.nav-links .nav-cta {
  background: var(--gold); color: #241a10;
  padding: 0.48rem 1.15rem; border-radius: 999px; font-weight: 600;
}
.nav-links .nav-cta:hover { background: var(--gold-bright); }
.nav-toggle {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 32px; height: 32px; background: none; border: none; cursor: pointer; padding: 0;
}
.nav-toggle span {
  width: 20px; height: 2px; background: var(--cream); border-radius: 2px;
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease); align-self: center;
}
.nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 760px) {
  .nav-toggle { display: flex; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: rgba(20, 14, 8, 0.97); backdrop-filter: blur(10px);
    max-height: 0; overflow: hidden; transition: max-height 0.35s var(--ease);
    border-bottom: 1px solid rgba(247, 241, 228, 0.08);
  }
  .nav-links.open { max-height: 360px; }
  .nav-links a { padding: 0.85rem 6vw; border-top: 1px solid rgba(247, 241, 228, 0.06); width: 100%; }
  .nav-links .nav-cta { margin: 0.8rem 6vw; text-align: center; width: auto; }
}

/* ---------- BUTTONS ---------- */

.cta {
  display: inline-block; padding: 0.82rem 2rem;
  background: var(--gold); color: #241a10;
  font-weight: 600; font-size: 0.9rem; text-decoration: none;
  border: none; border-radius: 999px; cursor: pointer;
  box-shadow: 0 8px 24px rgba(184, 132, 63, 0.25);
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.cta:hover { background: var(--gold-bright); transform: translateY(-2px); box-shadow: 0 12px 30px rgba(184, 132, 63, 0.35); }
.cta:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.cta.block { display: block; width: 100%; text-align: center; }

.btn-ghost {
  display: inline-block; padding: 0.8rem 1.9rem;
  border: 1.5px solid rgba(43, 32, 22, 0.3); color: var(--ink);
  border-radius: 999px; text-decoration: none; background: none; cursor: pointer;
  font-weight: 600; font-size: 0.9rem; transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }

/* ---------- PAGE HEADS ---------- */

.page-head { padding: calc(var(--header-h) + 3.5rem) 0 2.5rem; text-align: center; }
.page-head .eyebrow {
  display: block; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 0.8rem;
}
.page-head h1 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); font-weight: 500; color: var(--ink); line-height: 1.2; }
.page-head p { margin-top: 0.9rem; color: var(--ink-soft); font-size: 0.98rem; }

/* ---------- LEGAL / PROSE ---------- */

.prose { padding-bottom: 4rem; }
.prose h2 {
  font-family: 'Fraunces', serif; font-weight: 500; font-size: 1.25rem;
  color: var(--ink); margin: 2rem 0 0.7rem;
}
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { font-size: 0.95rem; line-height: 1.75; color: var(--ink-soft); margin-bottom: 0.9rem; }
.prose ul { padding-left: 1.3rem; margin-bottom: 0.9rem; }
.prose .updated { font-size: 0.85rem; color: var(--gold); font-style: italic; margin-bottom: 2rem; }

/* ---------- CARDS / FORMS ---------- */

.card {
  background: var(--cream); border: 1px solid rgba(184, 132, 63, 0.18);
  border-radius: var(--radius); box-shadow: 0 12px 28px rgba(43, 32, 22, 0.06);
}

.field { margin-bottom: 1.25rem; }
.field label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--ink); margin-bottom: 0.45rem; }
.field .hint { font-weight: 400; color: var(--ink-soft); }
.field input[type=text], .field input[type=email], .field input[type=password], .field textarea, .field select {
  width: 100%; padding: 0.72rem 0.9rem; font-family: inherit; font-size: 0.92rem;
  color: var(--ink); background: #fffdf8; border: 1.5px solid rgba(92, 76, 56, 0.25);
  border-radius: 10px; transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.field textarea { resize: vertical; min-height: 90px; line-height: 1.6; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(184, 132, 63, 0.15);
}
.field .counter { text-align: right; font-size: 0.75rem; color: var(--ink-soft); margin-top: 0.3rem; }

.divider-or {
  display: flex; align-items: center; gap: 1rem; margin: 1.5rem 0;
  color: var(--ink-soft); font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em;
}
.divider-or::before, .divider-or::after { content: ""; flex: 1; height: 1px; background: rgba(92, 76, 56, 0.2); }

.stripe-note {
  display: flex; align-items: center; gap: 0.5rem; justify-content: center;
  font-size: 0.78rem; color: var(--ink-soft); margin-top: 1.2rem;
}
.stripe-note svg { width: 15px; height: 15px; stroke: var(--ink-soft); }

.demo-banner {
  background: rgba(184, 132, 63, 0.14); border: 1px dashed var(--gold);
  color: #7a5a2c; font-size: 0.8rem; text-align: center;
  padding: 0.6rem 1rem; border-radius: 10px; margin-bottom: 1.5rem;
}

/* ---------- FOOTER ---------- */

.site-footer { background: #221d13; padding: 3rem 6vw 1.6rem; color: rgba(247, 241, 228, 0.75); flex-shrink: 0; }
.footer-inner {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1.3fr repeat(3, 1fr); gap: 2.2rem;
  padding-bottom: 2rem; border-bottom: 1px solid rgba(247, 241, 228, 0.1);
}
.footer-brand .footer-logo { font-size: 1.1rem; color: var(--cream); }
.footer-brand p { margin-top: 0.7rem; font-size: 0.82rem; line-height: 1.6; max-width: 240px; color: rgba(247, 241, 228, 0.55); }
.footer-col h4 { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--gold-bright); margin-bottom: 0.8rem; font-weight: 600; }
.footer-col a { display: block; font-size: 0.84rem; color: rgba(247, 241, 228, 0.72); text-decoration: none; margin-bottom: 0.6rem; transition: color 0.2s var(--ease); }
.footer-col a:hover { color: var(--gold-bright); }
.footer-bottom { max-width: 1100px; margin: 0 auto; padding-top: 1.3rem; font-size: 0.75rem; color: rgba(247, 241, 228, 0.45); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; }

@media (max-width: 720px) { .footer-inner { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-inner { grid-template-columns: 1fr; } }
