/* Ravenwood Corp — design system
   60% white / 30% black / 10% gold-amber accent */

:root {
  --paper: #ffffff;
  --paper-soft: #f6f5f2;
  --ink: #0d0d0d;
  --ink-soft: #3a3a3a;
  --line: #e4e2dd;
  --gold: #b8934a;
  --gold-deep: #8f6f38;
  --max-w: 1240px;
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 2rem;
  --space-4: 4rem;
  --space-5: 7rem;
  --radius: 2px;
  --font: -apple-system, BlinkMacSystemFont, "Inter", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; letter-spacing: -0.02em; font-weight: 600; }
p { margin: 0; }
.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 var(--space-3); }

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--gold);
  color: var(--ink);
  padding: var(--space-1) var(--space-2);
  z-index: 1000;
}
.skip-link:focus {
  left: var(--space-2);
  top: var(--space-2);
}

/* Focus states */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  z-index: 100;
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
  text-decoration: none;
}
.brand img { width: 28px; height: 28px; }
.main-nav ul {
  display: flex;
  gap: var(--space-3);
  list-style: none;
  margin: 0;
  padding: 0;
}
.main-nav a {
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink-soft);
}
.main-nav a[aria-current="page"] { color: var(--ink); }
.main-nav a:hover { color: var(--ink); }
.nav-actions { display: flex; align-items: center; gap: var(--space-2); }
.nav-toggle { display: none; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  padding: 0.65rem 1.3rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-deep); border-color: var(--gold-deep); color: var(--paper); }
.btn-ghost { background: transparent; color: var(--paper); border-color: rgba(255,255,255,0.4); }
.btn-ghost:hover { background: var(--paper); color: var(--ink); }

/* Hero */
.hero {
  background: var(--ink);
  color: var(--paper);
  padding: var(--space-5) 0 var(--space-4);
  overflow: hidden;
  position: relative;
}
.hero .wrap { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: var(--space-4); align-items: center; }
.hero-eyebrow {
  color: var(--gold);
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  font-weight: 700;
  margin-bottom: var(--space-2);
}
.hero h1 { font-size: clamp(2.2rem, 4.5vw, 3.6rem); line-height: 1.05; }
.hero p.lead { margin-top: var(--space-2); font-size: 1.1rem; color: #cfcfcf; max-width: 42ch; }
.hero-actions { margin-top: var(--space-3); display: flex; gap: var(--space-2); flex-wrap: wrap; }
.hero-art { width: 100%; aspect-ratio: 640 / 360; height: auto; overflow: visible; }
.sky-glow { animation: skyGlow 9s ease-in-out infinite; transform-origin: 320px 220px; }
.sky-far { animation: skyDriftFar 24s ease-in-out infinite alternate; transform-origin: center; }
.sky-near { animation: skyDriftNear 17s ease-in-out infinite alternate; transform-origin: center; }
.sky-windows rect { animation: windowFlicker 7s ease-in-out infinite; transform-origin: center; }
.sky-windows rect:nth-child(3n+1) { animation-delay: -2.3s; }
.sky-windows rect:nth-child(3n+2) { animation-delay: -4.6s; }

@keyframes skyGlow { 0%, 100% { opacity: 0.5; } 50% { opacity: 1; } }
@keyframes skyDriftFar { from { transform: translateX(0); } to { transform: translateX(-5px); } }
@keyframes skyDriftNear { from { transform: translateX(0); } to { transform: translateX(5px); } }
@keyframes windowFlicker { 0%, 100% { opacity: 0.5; } 50% { opacity: 1; } }

@media (prefers-reduced-motion: reduce) {
  .sky-glow, .sky-far, .sky-near, .sky-windows rect { animation: none; }
}

/* Sections */
section { padding: var(--space-5) 0; }
.section-soft { background: var(--paper-soft); }
.section-dark { background: var(--ink); color: var(--paper); }
.section-gold { background: var(--gold); color: var(--ink); }
.eyebrow {
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: var(--space-1);
}
.section-head { max-width: 60ch; margin-bottom: var(--space-4); }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
.section-head p { margin-top: var(--space-2); color: var(--ink-soft); font-size: 1.05rem; }
.section-dark .section-head p, .section-dark p { color: #cfcfcf; }

/* Bento grid */
.bento {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.bento-card {
  background: var(--paper);
  padding: var(--space-3);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.bento-card .icon { width: 40px; height: 40px; margin-bottom: var(--space-1); color: var(--gold); }
.bento-card h3 { font-size: 1.15rem; }
.bento-card p { color: var(--ink-soft); font-size: 0.95rem; }

/* Stats */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  text-align: center;
}
.stat-value { font-size: clamp(2.2rem, 5vw, 3.2rem); font-weight: 700; color: var(--gold); }
.stat-label { margin-top: 0.4rem; color: #cfcfcf; font-size: 0.9rem; }

/* Portfolio gallery */
.gallery {
  display: flex;
  gap: var(--space-2);
  overflow-x: auto;
  padding-bottom: var(--space-2);
  scroll-snap-type: x proximity;
}
.gallery-card {
  flex: 0 0 280px;
  scroll-snap-align: start;
  border: 1px solid var(--line);
}
.gallery-card .art { background: var(--paper-soft); aspect-ratio: 4/3; display: flex; align-items: center; justify-content: center; }
.gallery-card .art svg { width: 46%; color: var(--gold); }
.gallery-card .meta { padding: var(--space-2); }
.gallery-card .meta h3 { font-size: 1rem; }
.gallery-card .meta p { color: var(--ink-soft); font-size: 0.85rem; margin-top: 0.2rem; }

/* About / split */
.split {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: var(--space-4);
  align-items: center;
}
.split.reverse { grid-template-columns: 1.15fr 0.85fr; }
.split.reverse .art-col { order: 2; }
.art-col .placeholder-photo {
  background: var(--paper-soft);
  border: 1px solid var(--line);
  aspect-ratio: 4/5;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
}
.art-col .placeholder-photo svg { width: 40%; }

/* Process / trust band */
.process-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-3);
}
.process-item .num {
  color: var(--gold);
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.process-item h3 { font-size: 1.05rem; }
.process-item p { color: #cfcfcf; font-size: 0.9rem; margin-top: 0.4rem; }

/* Team */
.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
.team-card .placeholder-photo {
  background: var(--paper-soft);
  border: 1px solid var(--line);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  margin-bottom: var(--space-2);
}
.team-card .placeholder-photo svg { width: 34%; }
.team-card h3 { font-size: 1.05rem; }
.team-card .role { color: var(--gold); font-size: 0.85rem; font-weight: 600; margin-top: 0.2rem; }
.team-card p.bio { color: var(--ink-soft); font-size: 0.9rem; margin-top: 0.5rem; }

/* CTA band */
.cta-band { text-align: center; }
.cta-band h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); max-width: 32ch; margin: 0 auto; }
.cta-band p { margin-top: var(--space-2); }
.cta-band .btn { margin-top: var(--space-3); }

/* Forms */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2);
}
.form-grid .full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: var(--space-2); }
.field label { font-size: 0.85rem; font-weight: 600; }
.field input, .field textarea {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.7rem 0.8rem;
  font-family: var(--font);
  font-size: 0.95rem;
  background: var(--paper);
  color: var(--ink);
}
.field input:focus, .field textarea:focus { border-color: var(--gold); }
.field-error { color: #b3261e; font-size: 0.8rem; min-height: 1em; }
.honeypot-field { position: absolute; left: -9999px; top: -9999px; opacity: 0; height: 0; }
.form-status { margin-top: var(--space-2); font-size: 0.92rem; min-height: 1.4em; }
.form-status[data-state="success"] { color: #2e6b3e; }
.form-status[data-state="error"] { color: #b3261e; }
.form-note { font-size: 0.8rem; color: var(--ink-soft); margin-top: var(--space-1); }

/* Disclaimer callouts */
.disclaimer {
  border: 1px solid var(--line);
  background: var(--paper-soft);
  padding: var(--space-2) var(--space-3);
  font-size: 0.82rem;
  color: var(--ink-soft);
  line-height: 1.6;
}

/* Footer */
.site-footer { background: var(--ink); color: #cfcfcf; padding-top: var(--space-4); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: var(--space-3);
  padding-bottom: var(--space-4);
  border-bottom: 1px solid #2a2a2a;
}
.footer-col h4 { color: var(--paper); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: var(--space-2); }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.55rem; }
.footer-col a { text-decoration: none; font-size: 0.9rem; color: #b8b8b8; }
.footer-col a:hover { color: var(--gold); }
.footer-legal { padding: var(--space-3) 0; font-size: 0.78rem; color: #8a8a8a; }
.footer-wordmark {
  font-size: clamp(3rem, 12vw, 9rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #1c1c1c;
  text-align: center;
  padding: var(--space-3) 0 var(--space-2);
  user-select: none;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-2) 0;
  border-top: 1px solid #2a2a2a;
  font-size: 0.8rem;
  color: #8a8a8a;
  flex-wrap: wrap;
  gap: var(--space-1);
}
.footer-bottom a { color: #8a8a8a; text-decoration: none; }
.footer-bottom a:hover { color: var(--gold); }

/* 404 */
.error-page { min-height: 60vh; display: flex; align-items: center; justify-content: center; text-align: center; }
.error-page .code { font-size: 6rem; font-weight: 800; color: var(--gold); }

/* Legal pages */
.legal-content { max-width: 72ch; }
.legal-content h2 { margin-top: var(--space-4); font-size: 1.3rem; }
.legal-content p, .legal-content li { color: var(--ink-soft); margin-top: var(--space-2); }

/* Mobile nav */
@media (max-width: 860px) {
  .brand { font-size: 0.85rem; white-space: nowrap; gap: 0.4rem; }
  .nav-actions .btn-gold { display: none; }
  .main-nav { display: none; }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: 1px solid var(--line);
    background: none;
    cursor: pointer;
  }
  .site-header.nav-open .main-nav {
    display: block;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: var(--space-2) var(--space-3);
  }
  .site-header.nav-open .main-nav ul { flex-direction: column; gap: var(--space-2); }
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-art { order: -1; max-width: 260px; margin: 0 auto var(--space-3); }
  .bento { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr; gap: var(--space-3); }
  .split, .split.reverse { grid-template-columns: 1fr; }
  .split.reverse .art-col { order: 0; }
  .process-list { grid-template-columns: 1fr 1fr; }
  .team-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .form-grid { grid-template-columns: 1fr; }
}
