:root {
  --paper: #f7f2e7;
  --paper-deep: #efe4d0;
  --ink: #211c18;
  --muted: #6b625a;
  --wine: #8f2447;
  --sage: #60756b;
  --blue: #23465a;
  --gold: #c8913f;
  --white: #fffaf2;
  --line: rgba(33, 28, 24, 0.16);
  --shadow: 0 24px 70px rgba(51, 36, 22, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(35, 70, 90, 0.06) 1px, transparent 1px),
    linear-gradient(180deg, rgba(143, 36, 71, 0.05) 1px, transparent 1px),
    var(--paper);
  background-size: 42px 42px, 42px 42px, auto;
  font-family: "Work Sans", "Segoe UI", sans-serif;
  line-height: 1.6;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
  background:
    radial-gradient(circle at 20% 15%, rgba(200, 145, 63, 0.16), transparent 26%),
    radial-gradient(circle at 82% 8%, rgba(96, 117, 107, 0.14), transparent 28%),
    linear-gradient(135deg, rgba(255, 250, 242, 0.72), rgba(255, 250, 242, 0.08));
}

a {
  color: inherit;
}

button,
select,
textarea {
  font: inherit;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 22px 0 10px;
}

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

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  color: var(--white);
  background: var(--ink);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  font-family: "Great Vibes", cursive;
  font-size: 23px;
  line-height: 1;
}

.top-nav {
  display: flex;
  gap: 8px;
  align-items: center;
}

.top-nav a {
  padding: 8px 12px;
  color: var(--muted);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.top-nav a:hover {
  color: var(--ink);
  background: rgba(255, 250, 242, 0.7);
}

.hero {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 54px;
}

.hero-copy {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 0.72fr);
  grid-template-areas:
    "eyebrow intro"
    "title intro";
  align-items: end;
  max-width: none;
  min-height: 0;
  padding: 0 24px 0 24px;
  margin-bottom: 24px;
}

.eyebrow {
  grid-area: eyebrow;
  margin: 0 0 12px;
  color: var(--wine);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  grid-area: title;
  max-width: 660px;
  margin: 0;
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: clamp(48px, 7.2vw, 96px);
  line-height: 0.95;
  letter-spacing: 0;
}

h1::after {
  display: block;
  width: min(300px, 72%);
  height: 24px;
  margin: 14px 0 0;
  content: "";
  background:
    linear-gradient(90deg, transparent 0 5%, var(--wine) 5% 38%, transparent 38% 45%, var(--gold) 45% 82%, transparent 82%),
    linear-gradient(180deg, transparent 44%, rgba(33, 28, 24, 0.18) 44% 52%, transparent 52%);
  border-radius: 999px;
  transform: rotate(-1deg);
}

.hero-intro {
  grid-area: intro;
  max-width: 470px;
  margin: 0 0 26px;
  color: var(--muted);
  font-size: clamp(16px, 1.55vw, 20px);
}

.generator-panel {
  padding: clamp(18px, 3vw, 30px);
  background: rgba(255, 250, 242, 0.84);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.input-row,
.style-select {
  display: grid;
  gap: 8px;
}

label,
.preview-label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

textarea,
select {
  width: 100%;
  color: var(--ink);
  background: var(--white);
  border: 1px solid rgba(33, 28, 24, 0.22);
  border-radius: 8px;
  outline: none;
}

textarea {
  min-height: 138px;
  padding: 16px;
  resize: vertical;
  font-size: 18px;
}

select {
  min-height: 48px;
  padding: 0 42px 0 14px;
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--wine) 50%),
    linear-gradient(135deg, var(--wine) 50%, transparent 50%);
  background-position:
    calc(100% - 20px) 21px,
    calc(100% - 14px) 21px;
  background-size: 6px 6px;
  background-repeat: no-repeat;
  font-weight: 600;
}

textarea:focus,
select:focus {
  border-color: var(--wine);
  box-shadow: 0 0 0 4px rgba(143, 36, 71, 0.12);
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: end;
  margin-top: 18px;
}

.style-select span {
  color: var(--muted);
  font-size: 13px;
}

.generator-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-start;
  margin: 16px 0 14px;
  color: var(--muted);
  font-size: 13px;
}

.generator-meta span:first-child {
  color: var(--wine);
  font-weight: 700;
}

.copy-button {
  display: grid;
  min-width: 128px;
  min-height: 48px;
  padding: 7px 18px;
  color: var(--white);
  cursor: pointer;
  background: var(--ink);
  border: 0;
  border-radius: 8px;
  box-shadow: 0 12px 26px rgba(33, 28, 24, 0.22);
}

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

.copy-status {
  color: rgba(255, 250, 242, 0.72);
  font-size: 12px;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.result-card {
  display: grid;
  gap: 14px;
  min-height: 214px;
  padding: 20px;
  background:
    linear-gradient(rgba(35, 70, 90, 0.11) 1px, transparent 1px),
    var(--white);
  background-size: 100% 32px;
  border: 1px solid rgba(33, 28, 24, 0.14);
  border-radius: 8px;
}

.result-card:hover {
  border-color: rgba(143, 36, 71, 0.45);
  box-shadow: 0 14px 30px rgba(51, 36, 22, 0.12);
  transform: translateY(-1px);
}

.result-sample {
  display: block;
  min-height: 112px;
  color: var(--blue);
  font-size: clamp(38px, 4.5vw, 66px);
  line-height: 1.04;
  overflow-wrap: anywhere;
}

.result-actions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.result-name {
  color: var(--wine);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.result-card .copy-button {
  min-width: 80px;
  min-height: 40px;
  padding: 6px 12px;
  box-shadow: none;
}

.preview-sheet {
  position: relative;
  display: grid;
  gap: 12px;
  min-height: 230px;
  margin-top: 22px;
  padding: clamp(18px, 4vw, 34px);
  overflow: hidden;
  background:
    linear-gradient(rgba(35, 70, 90, 0.12) 1px, transparent 1px),
    var(--white);
  background-size: 100% 34px;
  border: 1px solid rgba(33, 28, 24, 0.14);
  border-radius: 8px;
}

.preview-sheet::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 30px;
  width: 1px;
  content: "";
  background: rgba(143, 36, 71, 0.25);
}

.preview-label {
  position: relative;
  z-index: 1;
  margin: 0;
}

.preview-text {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  min-height: 116px;
  color: var(--blue);
  font-size: clamp(42px, 7vw, 82px);
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.font-great-vibes { font-family: "Great Vibes", cursive; }
.font-dancing-script { font-family: "Dancing Script", cursive; }
.font-allura { font-family: "Allura", cursive; }
.font-parisienne { font-family: "Parisienne", cursive; }
.font-sacramento { font-family: "Sacramento", cursive; }
.font-satisfy { font-family: "Satisfy", cursive; }
.font-homemade-apple { font-family: "Homemade Apple", cursive; }
.font-caveat { font-family: "Caveat", cursive; }

.font-gallery,
.use-cases,
.faq {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 78px 0;
}

.section-heading {
  max-width: 720px;
  margin-bottom: 28px;
}

h2 {
  margin: 0;
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: clamp(32px, 5vw, 58px);
  line-height: 1.05;
  letter-spacing: 0;
}

.section-heading p:last-child {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.font-grid,
.style-cloud,
.use-grid {
  display: grid;
  gap: 14px;
}

.font-grid,
.style-cloud,
.use-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.style-cloud span {
  display: grid;
  min-height: 56px;
  padding: 18px;
  place-items: center;
  color: var(--wine);
  background: rgba(255, 250, 242, 0.78);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.font-card,
.use-grid article,
.faq details {
  background: rgba(255, 250, 242, 0.78);
  border: 1px solid var(--line);
  border-radius: 8px;
}

.font-card {
  display: grid;
  gap: 12px;
  min-height: 154px;
  padding: 20px;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}

.font-card:hover,
.font-card.active {
  border-color: rgba(143, 36, 71, 0.54);
  box-shadow: 0 16px 34px rgba(51, 36, 22, 0.13);
  transform: translateY(-2px);
}

.font-sample {
  display: block;
  min-height: 72px;
  color: var(--blue);
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.font-name {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
}

.content-band {
  padding: 88px 0;
  background: rgba(35, 70, 90, 0.1);
  border-top: 1px solid rgba(35, 70, 90, 0.1);
  border-bottom: 1px solid rgba(35, 70, 90, 0.1);
}

.content-band.alternate {
  background: rgba(96, 117, 107, 0.12);
}

.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr);
  gap: clamp(24px, 7vw, 88px);
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.prose p {
  margin: 0 0 18px;
  color: #47413d;
  font-size: 18px;
}

.prose p:last-child {
  margin-bottom: 0;
}

.use-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.use-grid article {
  padding: 24px;
}

h3 {
  margin: 0 0 10px;
  color: var(--wine);
  font-family: "Libre Baskerville", Georgia, serif;
  font-size: 24px;
  line-height: 1.16;
}

.use-grid p {
  margin: 0;
  color: var(--muted);
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq details {
  padding: 18px 20px;
}

.faq summary {
  cursor: pointer;
  font-weight: 700;
}

.faq details p {
  margin: 12px 0 0;
  color: var(--muted);
}

.site-footer {
  display: flex;
  justify-content: space-between;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 44px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.site-footer p {
  margin: 0;
  font-weight: 700;
}

.site-footer a {
  font-weight: 700;
  text-decoration-color: rgba(143, 36, 71, 0.42);
  text-underline-offset: 4px;
}

@media (max-width: 900px) {
  .top-nav {
    display: none;
  }

  .hero,
  .content-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 24px;
  }

  .hero-copy {
    grid-template-columns: 1fr;
    grid-template-areas:
      "eyebrow"
      "title"
      "intro";
    min-height: auto;
    margin-bottom: 22px;
  }

  .hero-intro {
    max-width: 680px;
    margin: 22px 0 0;
  }

  .generator-panel {
    align-self: auto;
  }

  .result-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .font-grid,
  .style-cloud {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 560px) {
  .site-header {
    width: min(100% - 24px, 1180px);
    padding-top: 14px;
  }

  .hero,
  .font-gallery,
  .use-cases,
  .faq,
  .content-layout,
  .site-footer {
    width: min(100% - 24px, 1180px);
  }

  .brand {
    font-size: 14px;
  }

  .brand-mark {
    width: 36px;
    height: 36px;
    font-size: 20px;
  }

  .hero {
    padding-bottom: 42px;
  }

  h1 {
    font-size: clamp(44px, 15vw, 72px);
  }

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

  .copy-button {
    width: 100%;
  }

  .preview-sheet::before {
    left: 18px;
  }

  .result-grid,
  .font-grid,
  .style-cloud {
    grid-template-columns: 1fr;
  }

  .font-card {
    min-height: 132px;
  }

  .content-band,
  .font-gallery,
  .use-cases,
  .faq {
    padding: 58px 0;
  }

  .site-footer {
    display: grid;
    gap: 10px;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .generator-panel,
  .result-card,
  .font-card,
  .copy-button,
  .use-grid article,
  .faq details {
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background-color 180ms ease;
  }
}
