:root {
  --cream: #f5f0df;
  --paper: #fffaf0;
  --ink: #243329;
  --muted: #697568;
  --forest: #173d2a;
  --moss: #486241;
  --gold: #b58b3b;
  --line: #d9d0b7;
  --sage: #dfe7d6;
  --white: #fffdf7;
  --shadow: 0 18px 45px rgba(36, 51, 41, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: "Segoe UI", system-ui, sans-serif;
  line-height: 1.6;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px clamp(18px, 4vw, 56px);
  background: rgba(245, 240, 223, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--forest);
  border-radius: 50%;
  color: var(--paper);
  background: var(--forest);
  font-family: Georgia, serif;
  font-weight: 700;
}

.brand strong,
h1,
h2,
h3 {
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.1;
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
}

nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px 18px;
  color: var(--forest);
  font-size: 0.94rem;
}

nav a {
  border-bottom: 1px solid transparent;
}

nav a:hover {
  border-color: var(--gold);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.7fr);
  gap: clamp(28px, 6vw, 72px);
  min-height: 76vh;
  align-items: center;
  padding: clamp(42px, 7vw, 86px) clamp(18px, 4vw, 56px);
  background:
    linear-gradient(90deg, rgba(245, 240, 223, 0.96), rgba(245, 240, 223, 0.86)),
    url("data:image/svg+xml,%3Csvg width='900' height='600' viewBox='0 0 900 600' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%23486241' stroke-width='2' opacity='.18'%3E%3Cpath d='M182 510c95-96 119-218 80-365'/%3E%3Cpath d='M263 170c-72 24-114 65-126 122 76-2 127-32 153-91'/%3E%3Cpath d='M258 254c50 7 92 33 127 78-63 21-114 10-153-32'/%3E%3Cpath d='M587 534c-72-124-70-257 4-398'/%3E%3Cpath d='M592 179c-55 39-82 85-80 139 67-16 110-53 130-110'/%3E%3Cpath d='M577 324c52-5 99 10 140 44-54 34-106 36-156 5'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover;
  border-bottom: 1px solid var(--line);
}

.page-hero {
  padding: clamp(48px, 8vw, 100px) clamp(18px, 4vw, 56px);
  background:
    linear-gradient(90deg, rgba(245, 240, 223, 0.98), rgba(245, 240, 223, 0.9)),
    url("data:image/svg+xml,%3Csvg width='900' height='420' viewBox='0 0 900 420' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%23486241' stroke-width='2' opacity='.16'%3E%3Cpath d='M132 388c84-82 102-183 54-303'/%3E%3Cpath d='M185 108c-52 18-86 48-101 90 58 0 99-21 122-64'/%3E%3Cpath d='M598 390c-70-94-72-203-6-326'/%3E%3Cpath d='M600 92c-52 36-78 76-76 119 61-13 99-43 116-91'/%3E%3C/g%3E%3C/svg%3E");
  background-size: cover;
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  max-width: 960px;
  margin: 0;
  color: var(--forest);
  font-size: clamp(2.2rem, 6vw, 4.8rem);
}

.page-hero p {
  max-width: 760px;
  font-size: 1.1rem;
}

.hero h1 {
  max-width: 860px;
  margin: 0;
  color: var(--forest);
  font-size: clamp(2.5rem, 7vw, 5.7rem);
  letter-spacing: 0;
}

.hero p {
  max-width: 680px;
  font-size: clamp(1.05rem, 2vw, 1.28rem);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.actions,
.template-panel .button {
  margin-top: 24px;
}

.button,
button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border: 1px solid var(--forest);
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
}

.primary,
button {
  color: var(--paper);
  background: var(--forest);
}

.secondary {
  color: var(--forest);
  background: transparent;
}

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

.field-card,
article,
.template-panel,
.signup,
.about {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 250, 240, 0.88);
}

.field-card {
  padding: 26px;
  box-shadow: var(--shadow);
}

.specimen {
  display: flex;
  height: 190px;
  align-items: end;
  justify-content: center;
  gap: 16px;
  margin-bottom: 22px;
  border: 1px solid var(--line);
  background: var(--sage);
}

.specimen span {
  width: 34px;
  border-radius: 999px 999px 0 0;
  background: var(--moss);
}

.specimen span:nth-child(1) {
  height: 54%;
}

.specimen span:nth-child(2) {
  height: 82%;
  background: var(--forest);
}

.specimen span:nth-child(3) {
  height: 66%;
}

.card-code {
  color: var(--gold);
  font-weight: 800;
}

.field-card h2 {
  margin: 0 0 18px;
  color: var(--forest);
  font-size: 2rem;
}

dl {
  display: grid;
  gap: 12px;
  margin: 0;
}

dt {
  color: var(--forest);
  font-weight: 800;
}

dd {
  margin: 0;
  color: var(--muted);
}

.section,
.process,
.signup,
footer {
  padding: clamp(42px, 7vw, 78px) clamp(18px, 4vw, 56px);
}

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

.section-heading h2,
.process h2,
.signup h2,
.about h2 {
  margin: 0;
  color: var(--forest);
  font-size: clamp(1.8rem, 4vw, 3rem);
}

.split {
  display: flex;
  max-width: none;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.help-grid,
.card-grid,
.layer-grid,
.category-grid,
.template-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

article {
  padding: 20px;
}

article h3 {
  margin: 0 0 10px;
  color: var(--forest);
  font-size: 1.35rem;
}

article p {
  color: var(--muted);
}

.process {
  background: var(--forest);
  color: var(--paper);
}

.process .eyebrow {
  color: #d0ad61;
}

.process-row {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid rgba(255, 250, 240, 0.25);
  border-radius: 8px;
}

.process-row span {
  position: relative;
  min-height: 86px;
  display: grid;
  place-items: center;
  background: rgba(255, 250, 240, 0.08);
  font-family: Georgia, serif;
  font-size: 1.25rem;
}

.resource-card,
.guide-card {
  min-height: 230px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.status,
.series {
  display: inline-flex;
  width: fit-content;
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--forest);
  background: var(--white);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
}

.library-band {
  background: #ede5cf;
  border-block: 1px solid var(--line);
}

.layer-grid article span {
  color: var(--gold);
  font-weight: 800;
}

.library-groups {
  display: grid;
  gap: 20px;
}

.library-group {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
}

.library-group h3 {
  margin: 0 0 14px;
  color: var(--forest);
  font-size: 1.5rem;
}

.guide-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.guide-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--white);
}

.guide-row span:first-child {
  color: var(--forest);
  font-weight: 800;
}

.guide-row span:last-child {
  color: var(--muted);
  text-align: right;
}

.shop {
  background: #f8f4e8;
}

.tag-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag-grid span {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--forest);
  background: var(--paper);
  font-weight: 700;
}

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

.template-panel ul {
  padding-left: 20px;
  color: var(--muted);
}

.about {
  display: grid;
  grid-template-columns: 0.8fr 1fr;
  gap: 36px;
  margin: clamp(18px, 4vw, 56px);
}

.about p {
  margin: 0;
  color: var(--muted);
  font-size: 1.08rem;
}

.signup {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 34px;
  align-items: center;
  margin: clamp(18px, 4vw, 56px);
  background: var(--forest);
  color: var(--paper);
}

.compact-signup {
  margin-top: 0;
}

.signup h2,
.signup .eyebrow {
  color: var(--paper);
}

.signup p {
  color: #e8dfc7;
}

form label {
  display: block;
  margin-bottom: 8px;
  font-weight: 800;
}

form div {
  display: flex;
  gap: 8px;
}

input {
  width: 100%;
  min-height: 46px;
  padding: 12px 14px;
  border: 1px solid #b9c2ae;
  border-radius: 6px;
  background: var(--paper);
  font: inherit;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  color: var(--paper);
  background: #102b1d;
}

.text-link {
  color: var(--forest);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 4px;
}

@media (max-width: 860px) {
  .site-header,
  .split,
  footer {
    align-items: flex-start;
    flex-direction: column;
  }

  nav {
    justify-content: flex-start;
  }

  .hero,
  .help-grid,
  .card-grid,
  .layer-grid,
  .category-grid,
  .template-grid,
  .about,
  .signup {
    grid-template-columns: 1fr;
  }

  .process-row,
  .guide-list {
    grid-template-columns: 1fr;
  }

  .process-row span {
    min-height: 60px;
  }

  form div {
    flex-direction: column;
  }
}

@media (max-width: 520px) {
  .hero {
    min-height: auto;
  }

  .actions .button,
  button {
    width: 100%;
  }

  .guide-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .guide-row span:last-child {
    text-align: left;
  }
}
