/* Erebos Core — brand palette (identity-board-v1)
   Violet touches only CORE and the glyph — EREBOS stays ink or bone. */
:root {
  --void-black: #121214;
  --ink: #1F1F23;
  --daylight-violet: #6B46E5;
  --night-violet: #9B82FF;
  --bone: #EFEAE1;
  --bone-dim: #B9B4AA;
  --line: rgba(239, 234, 225, 0.1);

  --font-display: "Cinzel", "Cormorant SC", serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--void-black);
  color: var(--bone);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

/* ------------------------------------------------------------------ Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 3rem;
  padding: 1.1rem clamp(1.25rem, 5vw, 3rem);
  background: rgba(18, 18, 20, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
}

.brand-mark { width: 34px; height: 34px; flex-shrink: 0; }

.site-footer .brand-mark { width: 28px; height: 28px; }

.brand-word {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.22em;
  color: var(--bone);
  white-space: nowrap;
}

.brand-word em {
  font-style: normal;
  color: var(--night-violet);
  letter-spacing: 0.3em;
  font-size: 0.85em;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
  gap: clamp(0.9rem, 2.5vw, 2rem);
}

.site-nav a {
  color: var(--bone-dim);
  text-decoration: none;
  font-size: 0.92rem;
  letter-spacing: 0.04em;
  white-space: nowrap;
  transition: color 160ms ease;
}

.site-nav a:hover { color: var(--bone); }

.site-nav .nav-cta {
  color: var(--night-violet);
  border: 1px solid rgba(155, 130, 255, 0.38);
  border-radius: 999px;
  padding: 0.4rem 1.1rem;
  transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.site-nav .nav-cta:hover {
  color: var(--void-black);
  background: var(--night-violet);
  border-color: var(--night-violet);
}

/* --------------------------------------------------------------------- Hero */

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 9rem 1.5rem 8rem;
  padding: clamp(5rem, 13vh, 9rem) 1.5rem clamp(5rem, 12vh, 8rem);
  overflow: hidden;
  isolation: isolate;
}

/* Aurora blobs */
.hero-aurora {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: -2;
}

.aurora-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(72px);
}

.aurora-blob--1 {
  width: 560px; height: 560px;
  background: radial-gradient(circle, rgba(107,70,229,0.28) 0%, transparent 70%);
  top: -180px;
  left: 50%;
  transform: translateX(-50%);
  animation: aurora-drift-1 18s ease-in-out infinite alternate;
}

.aurora-blob--2 {
  width: 380px; height: 380px;
  background: radial-gradient(circle, rgba(155,130,255,0.16) 0%, transparent 70%);
  bottom: -80px; right: 5%;
  animation: aurora-drift-2 22s ease-in-out infinite alternate;
}

.aurora-blob--3 {
  width: 300px; height: 300px;
  background: radial-gradient(circle, rgba(107,70,229,0.12) 0%, transparent 70%);
  bottom: 0; left: -5%;
  animation: aurora-drift-2 28s ease-in-out infinite alternate-reverse;
}

@keyframes aurora-drift-1 {
  from { transform: translateX(-50%) translateY(0px) scale(1); }
  to   { transform: translateX(-50%) translateY(30px) scale(1.08); }
}

@keyframes aurora-drift-2 {
  from { transform: translateY(0px) scale(1); }
  to   { transform: translateY(-24px) scale(1.06); }
}

/* Film grain */
.hero-grain {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.72' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23g)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px 200px;
}

/* Animated glyph */
.hero-mark {
  width: 120px;
  height: 120px;
  margin-bottom: 2.5rem;
  animation: hero-in 0.9s cubic-bezier(0.16,1,0.3,1) both;
}

.glyph-outer,
.glyph-inner,
.glyph-diamond {
  transform-box: view-box;
  transform-origin: 50% 50%;
}

.glyph-outer  { animation: glyph-cw  40s linear infinite; }
.glyph-inner  { animation: glyph-ccw 26s linear infinite; }
.glyph-diamond { animation: diamond-pulse 3.5s ease-in-out infinite; }

@keyframes glyph-cw  { to { transform: rotate( 360deg); } }
@keyframes glyph-ccw { to { transform: rotate(-360deg); } }
@keyframes diamond-pulse {
  0%, 100% { transform: scale(1);    opacity: 1;    }
  50%       { transform: scale(1.18); opacity: 0.75; }
}

/* Hero typography */
.hero-word {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 4.75rem;
  font-size: clamp(2.6rem, 8vw, 4.75rem);
  letter-spacing: 0.28em;
  text-indent: 0.28em;
  color: var(--bone);
  line-height: 1.1;
  animation: hero-in 0.9s 0.12s cubic-bezier(0.16,1,0.3,1) both;
}

.hero-core {
  display: block;
  font-size: 0.3em;
  letter-spacing: 0.9em;
  text-indent: 0.9em;
  color: var(--night-violet);
  margin-top: 0.85rem;
}

.hero-tagline {
  margin-top: 2rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-size: clamp(1.05rem, 2.4vw, 1.35rem);
  letter-spacing: 0.12em;
  color: var(--bone);
  animation: hero-in 0.9s 0.24s cubic-bezier(0.16,1,0.3,1) both;
}

.hero-sub {
  margin-top: 1rem;
  max-width: 36rem;
  color: var(--bone-dim);
  animation: hero-in 0.9s 0.34s cubic-bezier(0.16,1,0.3,1) both;
}

.hero-actions {
  margin-top: 2.5rem;
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  animation: hero-in 0.9s 0.44s cubic-bezier(0.16,1,0.3,1) both;
}

@keyframes hero-in {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: none; }
}

/* ------------------------------------------------------------------ Buttons */

.btn {
  display: inline-block;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  border-radius: 999px;
  padding: 0.8rem 1.9rem;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

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

.btn-primary {
  background: var(--daylight-violet);
  color: var(--bone);
  box-shadow: 0 0 0 0 rgba(107,70,229,0);
}

.btn-primary:hover {
  background: var(--night-violet);
  color: var(--void-black);
  box-shadow: 0 6px 28px rgba(107,70,229,0.38);
}

.btn-ghost {
  color: var(--bone);
  border: 1px solid var(--line);
}

.btn-ghost:hover {
  border-color: rgba(239,234,225,0.35);
  box-shadow: inset 0 0 0 1px rgba(239,234,225,0.12);
}

.btn-lg { padding: 1rem 2.4rem; font-size: 1.05rem; }

/* ----------------------------------------------------------------- Marquee */

.marquee-strip {
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 0.9rem 0;
  background: var(--ink);
}

.marquee-track {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  width: max-content;
  animation: marquee 32s linear infinite;
  font-family: var(--font-display);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  color: var(--bone-dim);
  text-transform: uppercase;
}

.marquee-sep {
  color: var(--night-violet);
  font-size: 1rem;
  line-height: 1;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ---------------------------------------------------------------- Sections */

.section {
  padding: 7rem 3rem;
  padding: clamp(4rem, 10vh, 7rem) clamp(1.25rem, 5vw, 3rem);
}

.section-alt { background: var(--ink); }

.section-inner { max-width: 62rem; margin: 0 auto; }

.kicker {
  font-size: 0.78rem;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--night-violet);
  margin-bottom: 0.9rem;
}

.section h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 2.5rem;
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  letter-spacing: 0.06em;
  color: var(--bone);
  margin-bottom: 2rem;
}

.prose { max-width: 44rem; color: var(--bone-dim); }
.prose p + p { margin-top: 1.1rem; }

/* ------------------------------------------------------------------- Cards */

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1.2rem;
}

.card {
  background: rgba(18,18,20,0.55);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1.75rem 1.5rem;
  transition: border-color 220ms ease, box-shadow 220ms ease, transform 220ms ease;
}

.card:hover {
  border-color: rgba(107,70,229,0.55);
  box-shadow: 0 0 0 1px rgba(107,70,229,0.12), 0 12px 36px rgba(107,70,229,0.1);
  transform: translateY(-3px);
}

.card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
}

.card p { color: var(--bone-dim); font-size: 0.95rem; }

.work-note {
  margin-top: 2.25rem;
  color: var(--bone-dim);
  font-size: 0.92rem;
  border-left: 2px solid var(--daylight-violet);
  padding-left: 1rem;
}

/* ----------------------------------------------------------------- Process */

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
  gap: 0;
  position: relative;
}

.process-step {
  padding: 0 1.5rem 0 0;
}

.process-num-wrap {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
}

.process-num {
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.25em;
  color: var(--night-violet);
  flex-shrink: 0;
}

.process-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, var(--daylight-violet), transparent);
  margin-left: 1rem;
  opacity: 0.4;
}

.process-step:last-child .process-line { display: none; }

.process-step h3 {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 0.5rem;
}

.process-step p { color: var(--bone-dim); font-size: 0.94rem; }

/* --------------------------------------------------------------- Principles */

.principles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 2.25rem;
}

.principle-num {
  font-family: var(--font-display);
  color: var(--night-violet);
  letter-spacing: 0.2em;
  font-size: 0.85rem;
}

.principle h3 {
  margin: 0.6rem 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.principle p { color: var(--bone-dim); font-size: 0.95rem; }

/* ----------------------------------------------------------------- Contact */

.section-contact {
  text-align: center;
  background:
    radial-gradient(ellipse 65% 80% at 50% 110%, rgba(107,70,229,0.2), transparent 70%),
    var(--void-black);
}

.contact-lead {
  max-width: 34rem;
  margin: 0 auto 2.5rem;
  color: var(--bone-dim);
}

/* ------------------------------------------------------------------ Footer */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 3rem;
  padding: 2rem clamp(1.25rem, 5vw, 3rem);
}

.footer-inner {
  max-width: 62rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-note { color: var(--bone-dim); font-size: 0.85rem; }

/* --------------------------------------------------------------- Scroll reveal */

[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16,1,0.3,1), transform 0.7s cubic-bezier(0.16,1,0.3,1);
}

[data-reveal].revealed {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------- Responsive / a11y */

@media (max-width: 640px) {
  .site-nav a:not(.nav-cta) { display: none; }

  .process-steps {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .process-line { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .glyph-outer,
  .glyph-inner,
  .glyph-diamond,
  .aurora-blob--1,
  .aurora-blob--2,
  .aurora-blob--3,
  .marquee-track,
  .hero-mark,
  .hero-word,
  .hero-tagline,
  .hero-sub,
  .hero-actions {
    animation: none !important;
  }
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}
