/*
 * P4 Card Studio — main.css
 * Design system: dark navy + gold editorial palette
 * Fraunces serif headlines / Inter sans body
 * Inherits palette from p4one.com/capability
 */

/* Skip-to-content (visually hidden until focused) */
.skip-link{position:absolute;left:-9999px;top:auto;width:1px;height:1px;overflow:hidden}
.skip-link:focus{position:fixed;left:1rem;top:1rem;width:auto;height:auto;padding:.75rem 1rem;background:#c79350;color:#000;z-index:9999;border-radius:6px;text-decoration:none;font-weight:600}

/* ============================================================
   CSS CUSTOM PROPERTIES
   ============================================================ */
:root {
  /* Brand palette */
  --bg:        #0a1320;
  --bg1:       #0f1c2e;
  --bg2:       #132030;
  --gold:      #c79350;
  --gold-lt:   #deb278;
  --gold-dk:   #9e6f34;
  --cream:     #f5efe4;
  --ink:       rgba(245, 239, 228, 0.92);
  --muted:     rgba(245, 239, 228, 0.70);
  --muted2:    rgba(245, 239, 228, 0.48);
  --stroke:    rgba(199, 147, 80, 0.18);
  --stroke-lt: rgba(245, 239, 228, 0.10);

  /* Type */
  --font-serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-sans:  'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* Layout */
  --max:        1140px;
  --max-legal:  820px;
  --max-narrow: 680px;
  --r:          12px;
  --r-lg:       20px;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg);
  color: var(--ink);
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video, svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--gold-lt);
  text-decoration: none;
}

a:hover {
  color: var(--cream);
}

/* Visible focus outlines — never suppress without a visible replacement */
:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 3px;
}

/* Screen-reader-only utility */
.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;
}

/* ============================================================
   LAYOUT PRIMITIVES
   ============================================================ */
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

.wrap-narrow {
  max-width: var(--max-narrow);
  margin: 0 auto;
  padding: 0 24px;
}

.wrap-legal {
  max-width: var(--max-legal);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 80px 0;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

/* ============================================================
   SITE HEADER
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 19, 32, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--stroke);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
}

.brand:hover {
  color: var(--cream);
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--gold-dk), var(--gold));
  color: var(--bg);
  font-family: var(--font-serif);
  font-weight: 900;
  font-size: 14px;
  border-radius: 8px;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.brand-name {
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-lt);
}

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

.nav-list a {
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 999px;
  transition: color 0.15s, background 0.15s;
}

.nav-list a:hover {
  color: var(--ink);
  background: rgba(245, 239, 228, 0.06);
}

.ecosystem-link {
  font-size: 12px;
  color: var(--muted2);
  padding: 6px 12px;
  border: 1px solid var(--stroke-lt);
  border-radius: 999px;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
}

.ecosystem-link:hover {
  color: var(--gold-lt);
  border-color: var(--stroke);
}

.back-link {
  font-size: 13px;
  color: var(--muted);
  padding: 6px 14px;
  border: 1px solid var(--stroke-lt);
  border-radius: 999px;
}

.back-link:hover {
  color: var(--ink);
  border-color: var(--stroke);
}

@media (max-width: 640px) {
  .nav-list,
  .ecosystem-link {
    display: none;
  }
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  padding: 96px 0 64px;
  position: relative;
}

.hero-center {
  text-align: center;
}

.hero-center .hero-cta-row {
  justify-content: center;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--stroke);
  background: rgba(199, 147, 80, 0.08);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 20px;
}

h1 {
  font-family: var(--font-serif);
  font-size: clamp(38px, 6vw, 72px);
  font-weight: 900;
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--cream);
  margin-bottom: 20px;
}

h1 em {
  font-style: italic;
  color: var(--gold-lt);
}

.hero-sub {
  font-size: clamp(16px, 2vw, 19px);
  color: var(--muted);
  max-width: 620px;
  margin-bottom: 36px;
  line-height: 1.65;
}

.hero-center .hero-sub {
  margin-left: auto;
  margin-right: auto;
}

.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

/* Hero image placeholder — remove once real image is added */
.hero-img-slot {
  margin-top: 56px;
  border: 2px dashed var(--stroke);
  border-radius: var(--r-lg);
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(199, 147, 80, 0.04);
}

.img-placeholder-label {
  font-family: var(--font-sans);
  font-size: 13px;
  color: var(--muted2);
  letter-spacing: 0.06em;
}

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 14px;
  padding: 12px 24px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s;
  letter-spacing: 0.02em;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--gold);
  color: var(--bg);
}

.btn-primary:hover {
  background: var(--gold-lt);
  color: var(--bg);
}

.btn-ghost {
  background: transparent;
  color: var(--gold-lt);
  border: 1px solid var(--stroke);
}

.btn-ghost:hover {
  background: rgba(199, 147, 80, 0.10);
  color: var(--cream);
  border-color: var(--gold);
}

.btn-sm {
  font-size: 13px;
  padding: 9px 18px;
}

/* ============================================================
   PRODUCT CARDS
   ============================================================ */
.section-products {
  background: var(--bg1);
  border-top: 1px solid var(--stroke-lt);
  border-bottom: 1px solid var(--stroke-lt);
}

.section-products h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  color: var(--cream);
  margin-bottom: 48px;
  letter-spacing: -0.015em;
}

.card {
  background: var(--bg2);
  border: 1px solid var(--stroke);
  border-radius: var(--r-lg);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.card-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(199, 147, 80, 0.10);
  border: 1px solid var(--stroke);
  padding: 4px 10px;
  border-radius: 999px;
  width: fit-content;
}

.card h3 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  color: var(--cream);
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.card p {
  font-size: 15px;
  color: var(--muted);
  line-height: 1.65;
  flex-grow: 1;
}

.price-display {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  color: var(--gold-lt);
  letter-spacing: 0.02em;
}

/* ============================================================
   CONTACT / FORM
   ============================================================ */
.section-contact h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  color: var(--cream);
  margin-bottom: 12px;
  letter-spacing: -0.015em;
}

.section-contact > .wrap-narrow > p {
  font-size: 16px;
  color: var(--muted);
  margin-bottom: 36px;
}

.intake-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.field-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field-row label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.field-row input,
.field-row select,
.field-row textarea {
  font-family: var(--font-sans);
  font-size: 15px;
  color: var(--ink);
  background: var(--bg1);
  border: 1px solid var(--stroke);
  border-radius: var(--r);
  padding: 12px 16px;
  width: 100%;
  transition: border-color 0.15s;
  appearance: none;
  -webkit-appearance: none;
}

.field-row input::placeholder,
.field-row textarea::placeholder {
  color: var(--muted2);
}

.field-row input:focus,
.field-row select:focus,
.field-row textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(199, 147, 80, 0.15);
}

.field-row select option {
  background: var(--bg1);
  color: var(--ink);
}

/* ============================================================
   LOCALE LIST
   ============================================================ */
.section-locales {
  padding: 32px 0;
  border-top: 1px solid var(--stroke-lt);
}

.locale-label {
  font-size: 12px;
  color: var(--muted2);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  display: inline-block;
  margin-right: 12px;
}

.locale-list {
  display: inline-flex;
  list-style: none;
  gap: 12px;
  flex-wrap: wrap;
}

.locale-list a {
  font-size: 13px;
  color: var(--gold-lt);
  padding: 4px 10px;
  border: 1px solid var(--stroke);
  border-radius: 999px;
}

.locale-list a:hover,
.locale-list a[aria-current="page"] {
  background: rgba(199, 147, 80, 0.10);
  color: var(--cream);
}

/* ============================================================
   LEGAL PAGES
   ============================================================ */
.legal-body {
  padding: 32px 0 72px;
}

.callout {
  background: linear-gradient(180deg, rgba(199, 147, 80, 0.09), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--stroke);
  border-radius: var(--r);
  padding: 18px 22px;
  margin: 0 0 28px;
  font-size: 14.5px;
  color: var(--ink);
}

.callout strong {
  color: var(--gold-lt);
}

.legal-body h2 {
  font-family: var(--font-sans);
  font-size: 18px;
  font-weight: 800;
  color: var(--gold-lt);
  margin: 36px 0 10px;
  letter-spacing: -0.01em;
}

.legal-body h2:first-of-type {
  margin-top: 8px;
}

.legal-body h3 {
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  margin: 22px 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.legal-body p {
  font-size: 15.5px;
  color: var(--muted);
  margin-bottom: 14px;
  line-height: 1.7;
}

.legal-body p strong {
  color: var(--ink);
}

.legal-body ul {
  margin: 0 0 18px 22px;
  padding: 0;
}

.legal-body li {
  font-size: 15px;
  color: var(--muted);
  margin-bottom: 7px;
  line-height: 1.65;
}

.legal-body li strong {
  color: var(--ink);
}

.legal-body a {
  color: var(--gold-lt);
}

.legal-body a:hover {
  color: var(--cream);
}

.lastmod {
  font-size: 13px;
  color: var(--muted2);
  letter-spacing: 0.05em;
  margin-top: 8px;
}

.tm-line {
  margin-top: 28px;
  font-size: 11.5px;
  color: var(--muted2);
  letter-spacing: 0.04em;
  line-height: 1.8;
}

/* ============================================================
   SITE FOOTER
   ============================================================ */
.site-footer {
  border-top: 1px solid var(--stroke-lt);
  padding: 40px 0 32px;
  text-align: center;
}

.footer-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 20px;
}

.footer-nav a {
  font-size: 13px;
  color: var(--muted);
}

.footer-nav a:hover,
.footer-nav a[aria-current="page"] {
  color: var(--gold-lt);
}

.footer-contact {
  font-size: 13px;
  color: var(--muted2);
}

.footer-contact a {
  color: var(--gold-lt);
}

.footer-creds {
  font-size: 11.5px;
  color: var(--muted2);
  letter-spacing: 0.04em;
  line-height: 1.9;
}

.footer-copy {
  font-size: 12px;
  color: var(--muted2);
}

/* ============================================================
   RESPONSIVE ADJUSTMENTS
   ============================================================ */
@media (max-width: 768px) {
  .hero {
    padding: 64px 0 48px;
  }

  .section {
    padding: 56px 0;
  }

  .grid-3 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .hero-cta-row {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    text-align: center;
  }
}
