:root {
  --bg: #0a0909;
  --bg-soft: #131010;
  --paper: #f3e8da;
  --muted: #b9a58f;
  --line: rgba(230, 204, 170, 0.14);
  --gold: #dec095;
  --rust: #b87b5a;
  --glass: rgba(24, 18, 18, 0.72);
  --glass-strong: rgba(20, 15, 15, 0.94);
  --shadow: 0 30px 100px rgba(0, 0, 0, 0.52);
  --max-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--paper);
  font-family: "Plus Jakarta Sans", sans-serif;
  background:
    radial-gradient(circle at 16% 14%, rgba(222, 192, 149, 0.1), transparent 24%),
    radial-gradient(circle at 82% 18%, rgba(184, 123, 90, 0.11), transparent 20%),
    linear-gradient(180deg, #090707 0%, #0d0a0a 38%, #090707 100%);
  overflow-x: hidden;
}

body.modal-open {
  overflow: hidden;
}

a,
button,
input,
textarea,
select {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  border: 0;
  padding: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}

img {
  display: block;
  width: 100%;
}

.veil,
.texture {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.texture {
  opacity: 0.045;
  background-image:
    radial-gradient(circle at 25% 25%, #fff 0 0.8px, transparent 0.9px),
    radial-gradient(circle at 75% 75%, #fff 0 0.8px, transparent 0.9px);
  background-size: 26px 26px;
  mix-blend-mode: soft-light;
}

.veil {
  filter: blur(100px);
  opacity: 0.18;
}

.veil-left {
  inset: -6% auto auto -12%;
  width: 420px;
  height: 420px;
  background: #d4b183;
  animation: drift 18s ease-in-out infinite;
}

.veil-right {
  inset: 4% -10% auto auto;
  width: 420px;
  height: 420px;
  background: #8d5a41;
  animation: drift 22s ease-in-out infinite reverse;
}

.frame {
  width: min(var(--max-width), calc(100vw - 40px));
  margin: 0 auto;
}

.section {
  position: relative;
  z-index: 1;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 12;
  backdrop-filter: blur(18px);
  background: rgba(10, 9, 9, 0.58);
  border-bottom: 1px solid rgba(255, 241, 217, 0.05);
}

.topbar-frame,
.footer-frame {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.topbar-frame {
  padding: 16px 0;
}

.wordmark,
h1,
h2,
h3,
.footer-brand strong {
  font-family: "Bodoni Moda", serif;
}

.wordmark {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.26em;
}

.topbar-meta,
.footer-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.topbar-meta,
.topbar-meta a,
.footer-links,
.footer-links a,
.footer-links button {
  color: var(--muted);
}

.hero {
  padding: 76px 0 88px;
}

.hero-frame {
  display: grid;
  gap: 34px;
}

.hero-intro {
  max-width: 880px;
}

.label {
  margin: 0 0 16px;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.72rem;
  font-weight: 700;
}

h1 {
  margin: 0;
  max-width: 10ch;
  font-size: clamp(4rem, 9vw, 8rem);
  line-height: 0.88;
  font-weight: 700;
  letter-spacing: -0.05em;
}

.lead,
.thesis-grid p,
.chapter p,
.salon-card p,
.salon-panel p,
.legal-meta,
.legal-section-block p {
  color: var(--muted);
  line-height: 1.8;
}

.lead {
  max-width: 58ch;
  margin: 24px 0 0;
  font-size: 1.05rem;
}

.hero-tableau,
.thesis-frame,
.finale-frame {
  border: 1px solid var(--line);
  background: var(--glass);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.hero-tableau {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr 0.8fr;
  gap: 18px;
  align-items: center;
  padding: 24px;
  border-radius: 36px;
}

.tableau-copy,
.tableau-status {
  display: grid;
  gap: 16px;
}

.rule-stamp,
.store-chip,
.status-card,
.chapter,
.salon-card,
.salon-panel,
.legal-dialog {
  border: 1px solid var(--line);
  background: rgba(255, 247, 232, 0.03);
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}

.rule-stamp {
  padding: 18px;
  border-radius: 24px;
  color: #e7cbb0;
}

.store-line {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.store-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: 999px;
}

.store-chip-primary {
  background: linear-gradient(135deg, #efd9b7 0%, #d3af7f 100%);
  color: #1d140d;
  font-weight: 800;
}

.tableau-devices {
  position: relative;
  min-height: 640px;
}

.screen {
  position: absolute;
  margin: 0;
  overflow: hidden;
  border-radius: 34px;
  border: 1px solid rgba(255, 244, 224, 0.12);
  box-shadow: 0 34px 84px rgba(0, 0, 0, 0.55);
}

.screen::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255, 246, 232, 0.16), transparent 28%, transparent 72%, rgba(255, 246, 232, 0.06));
}

.screen-left {
  left: 4%;
  top: 70px;
  width: min(246px, 56vw);
  transform: rotate(-7deg);
  animation: float-left 10s ease-in-out infinite;
}

.screen-right {
  right: 2%;
  top: 0;
  width: min(302px, 64vw);
  animation: float-right 8s ease-in-out infinite;
}

.status-card {
  padding: 18px;
  border-radius: 24px;
}

.status-eyebrow,
.salon-tag {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--gold);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.72rem;
  font-weight: 700;
}

.status-card strong,
.chapter h3,
.salon-card h2,
.salon-panel h3,
.section-heading h2,
.thesis-grid h2,
.finale-frame h2,
.legal-dialog h2 {
  display: block;
  margin: 0;
  font-size: clamp(1.55rem, 2.2vw, 2.5rem);
  line-height: 1.04;
}

.thesis,
.chapters,
.salon,
.finale {
  padding: 0 0 92px;
}

.thesis-frame,
.finale-frame {
  padding: 34px 36px;
  border-radius: 34px;
}

.thesis-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 28px;
  align-items: start;
}

.thesis-grid h2,
.finale-frame h2 {
  margin: 0;
  font-size: clamp(2.5rem, 5vw, 4.6rem);
  line-height: 0.95;
}

.section-heading {
  margin-bottom: 26px;
}

.section-heading h2 {
  font-size: clamp(2.5rem, 4.8vw, 4rem);
}

.chapter-list,
.salon-grid {
  display: grid;
  gap: 16px;
}

.chapter {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 22px;
  align-items: start;
  padding: 22px 24px;
  border-radius: 28px;
}

.chapter-no {
  color: var(--gold);
  font-family: "Bodoni Moda", serif;
  font-size: 2rem;
  line-height: 1;
}

.chapter h3,
.salon-panel h3 {
  margin-bottom: 10px;
}

.salon-frame {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 18px;
  align-items: start;
}

.salon-card,
.salon-panel {
  padding: 26px;
  border-radius: 30px;
}

.salon-card h2 {
  margin-bottom: 10px;
}

.finale-frame {
  text-align: center;
}

.store-line-center {
  justify-content: center;
  margin-top: 28px;
}

.footer {
  padding: 0 0 34px;
}

.footer-frame {
  padding-top: 26px;
  border-top: 1px solid rgba(255, 241, 217, 0.08);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-brand strong {
  font-size: 1.5rem;
  letter-spacing: 0.18em;
}

.footer-brand span {
  color: var(--muted);
}

.legal-modal {
  position: fixed;
  inset: 0;
  z-index: 30;
}

.legal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.76);
  backdrop-filter: blur(10px);
}

.legal-dialog {
  position: relative;
  width: min(860px, calc(100vw - 30px));
  max-height: min(88vh, 900px);
  overflow: auto;
  margin: 6vh auto;
  padding: 28px;
  border-radius: 30px;
  background: var(--glass-strong);
}

.legal-close {
  position: sticky;
  top: 0;
  margin-left: auto;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 247, 232, 0.05);
}

.legal-label {
  margin-top: 8px;
}

.legal-content {
  margin-top: 22px;
}

.legal-section-block + .legal-section-block {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 241, 217, 0.08);
}

.legal-section-block h3 {
  margin: 0 0 10px;
  font-family: "Bodoni Moda", serif;
  font-size: 1.35rem;
}

.legal-section-block p {
  margin: 0;
  white-space: pre-wrap;
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.85s ease, transform 0.85s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 {
  transition-delay: 100ms;
}

.reveal-delay-2 {
  transition-delay: 200ms;
}

.reveal-delay-3 {
  transition-delay: 300ms;
}

@keyframes drift {
  0%,
  100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(16px, -20px, 0); }
}

@keyframes float-left {
  0%,
  100% { transform: rotate(-7deg) translateY(0); }
  50% { transform: rotate(-5deg) translateY(-12px); }
}

@keyframes float-right {
  0%,
  100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

@media (max-width: 980px) {
  .hero-tableau,
  .thesis-grid,
  .salon-frame {
    grid-template-columns: 1fr;
  }

  .topbar-meta {
    display: none;
  }

  .tableau-devices {
    min-height: 420px;
  }
}

@media (max-width: 720px) {
  .frame {
    width: min(var(--max-width), calc(100vw - 26px));
  }

  h1 {
    max-width: none;
  }

  .chapter {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .footer-frame,
  .footer-brand,
  .footer-links {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 520px) {
  .hero {
    padding: 42px 0 60px;
  }

  .lead,
  .thesis-grid p,
  .chapter p,
  .salon-card p,
  .salon-panel p {
    font-size: 0.98rem;
  }

  .store-line {
    flex-direction: column;
  }

  .store-chip,
  .rule-stamp {
    width: 100%;
  }

  .tableau-devices {
    min-height: 340px;
  }

  .screen-left {
    width: 146px;
  }

  .screen-right {
    width: 182px;
  }

  .hero-tableau,
  .thesis-frame,
  .finale-frame,
  .chapter,
  .salon-card,
  .salon-panel,
  .legal-dialog {
    padding: 20px 18px;
  }
}
