:root {
  color-scheme: light;
  --canvas: #f6f1e7;
  --canvas-deep: #ece1cf;
  --paper: #fffaf1;
  --ink: #231f1b;
  --muted: #645c52;
  --terracotta: #b84d31;
  --terracotta-dark: #843723;
  --coral: #d6724f;
  --amber: #d19a47;
  --olive: #57664d;
  --sage: #b8c2a4;
  --line: rgba(64, 53, 43, 0.16);
  --shadow: 0 24px 80px rgba(58, 43, 31, 0.12);
  --serif: Iowan Old Style, Baskerville, Times New Roman, serif;
  --sans: ui-rounded, SF Pro Rounded, -apple-system, BlinkMacSystemFont, Segoe UI, sans-serif;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--ink);
  background:
    radial-gradient(circle at 92% 5%, rgba(214, 114, 79, 0.14) 0 10rem, transparent 10.1rem),
    radial-gradient(circle at 3% 72%, rgba(184, 194, 164, 0.24) 0 12rem, transparent 12.1rem),
    linear-gradient(135deg, var(--canvas), var(--canvas-deep));
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--terracotta-dark);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--terracotta);
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 3px solid var(--amber);
  outline-offset: 4px;
  border-radius: 0.35rem;
}

.skip-link {
  position: fixed;
  z-index: 20;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  color: #fff;
  background: var(--ink);
  border-radius: 999px;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-shell {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.25rem 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.28rem;
  font-weight: 700;
  text-decoration: none;
}

.brand-name > span {
  color: var(--terracotta-dark);
}

.brand-mark {
  position: relative;
  display: inline-block;
  width: 2.8rem;
  height: 2.3rem;
}

.brand-mark::before,
.brand-mark::after,
.brand-mark span {
  position: absolute;
  inset: 0.15rem 0.1rem;
  content: "";
  border: 1px solid rgba(35, 31, 27, 0.12);
  border-radius: 0.58rem;
}

.brand-mark::before {
  background: var(--amber);
  transform: rotate(-9deg) translate(-0.18rem, 0.08rem);
}

.brand-mark::after {
  background: var(--sage);
  transform: rotate(7deg) translate(0.18rem, 0.03rem);
}

.brand-mark span {
  z-index: 1;
  background: linear-gradient(140deg, var(--coral), var(--terracotta));
}

.brand-mark span::after {
  position: absolute;
  inset: 0.58rem 0.72rem;
  content: "";
  border: 2px solid rgba(255, 255, 255, 0.92);
  border-radius: 0.25rem;
}

.site-nav ul,
.footer-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-block;
  padding: 0.55rem 0.8rem;
  color: var(--muted);
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
  background: rgba(255, 250, 241, 0.74);
}

main {
  min-height: 65vh;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(19rem, 0.85fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 6rem);
  padding: clamp(4.2rem, 9vw, 8rem) 0 clamp(5rem, 10vw, 9rem);
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--terracotta-dark);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin-top: 0;
  font-family: var(--serif);
  line-height: 1.06;
  text-wrap: balance;
}

h1 {
  max-width: 12ch;
  margin-bottom: 1.5rem;
  font-size: clamp(3rem, 7vw, 6.5rem);
  font-weight: 600;
  letter-spacing: -0.045em;
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(2rem, 4vw, 3.4rem);
  font-weight: 600;
  letter-spacing: -0.03em;
}

h3 {
  margin-bottom: 0.65rem;
  font-size: 1.4rem;
}

.lede {
  max-width: 42rem;
  margin: 0;
  color: var(--muted);
  font-size: clamp(1.08rem, 2vw, 1.3rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.secondary-actions {
  margin-top: 1rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 3.1rem;
  padding: 0.78rem 1.2rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  color: var(--ink);
  background: rgba(255, 250, 241, 0.86);
  box-shadow: 0 8px 28px rgba(58, 43, 31, 0.07);
  font-weight: 800;
  text-decoration: none;
}

.button-primary {
  color: #fff;
  background: var(--terracotta-dark);
  border-color: transparent;
}

.button-primary:hover {
  color: #fff;
  background: var(--terracotta);
}

.button:disabled {
  cursor: wait;
  color: rgba(255, 255, 255, 0.72);
  background: #8f8177;
  box-shadow: none;
}

.generator-shell {
  max-width: 44rem;
  margin-top: 2rem;
}

.generator-card,
.job-panel {
  padding: clamp(1.25rem, 3vw, 1.7rem);
  border: 1px solid rgba(64, 53, 43, 0.2);
  border-radius: 1.75rem;
  background: rgba(255, 250, 241, 0.94);
  box-shadow: 0 18px 60px rgba(58, 43, 31, 0.1);
}

.field-group label {
  display: block;
  margin-bottom: 0.55rem;
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 700;
}

.field-group input[type="url"] {
  width: 100%;
  min-height: 3.6rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(64, 53, 43, 0.24);
  border-radius: 1rem;
  color: var(--ink);
  background: #fffdfa;
  font: inherit;
  font-size: 1rem;
  box-shadow: inset 0 1px 2px rgba(58, 43, 31, 0.04);
}

.field-group input[type="url"]::placeholder {
  color: #8a8177;
}

.field-group input[type="url"][aria-invalid="true"] {
  border-color: var(--terracotta);
}

.field-help,
.generator-note,
.job-message {
  color: var(--muted);
}

.field-help {
  margin: 0.55rem 0 0;
  font-size: 0.84rem;
}

.people-option {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.8rem;
  align-items: start;
  margin: 1.15rem 0;
  padding: 0.95rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  cursor: pointer;
  background: rgba(236, 225, 207, 0.36);
}

.people-option input {
  width: 1.2rem;
  height: 1.2rem;
  margin: 0.18rem 0 0;
  accent-color: var(--terracotta-dark);
}

.people-option strong,
.people-option small {
  display: block;
}

.people-consent {
  margin: -0.45rem 0 1.15rem;
  padding: 0.8rem 0.9rem;
  border-left: 0.25rem solid var(--olive);
  border-radius: 0.35rem 0.8rem 0.8rem 0.35rem;
  color: var(--muted);
  background: rgba(184, 194, 164, 0.18);
  font-size: 0.8rem;
  line-height: 1.45;
}

.people-option small {
  margin-top: 0.18rem;
  color: var(--muted);
  line-height: 1.45;
}

.generator-submit {
  width: 100%;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.generator-error {
  margin: 0.9rem 0 0;
  color: var(--terracotta-dark);
  font-weight: 750;
}

.generator-note {
  margin: 0.85rem 0 0;
  font-size: 0.78rem;
  line-height: 1.45;
}

.job-panel {
  border-color: rgba(87, 102, 77, 0.34);
}

.job-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.job-heading .eyebrow {
  margin-bottom: 0.5rem;
}

.job-heading h2 {
  margin-bottom: 0;
  font-size: clamp(1.8rem, 4vw, 2.55rem);
}

.status-pill {
  flex: 0 0 auto;
  padding: 0.45rem 0.75rem;
  border: 1px solid rgba(87, 102, 77, 0.25);
  border-radius: 999px;
  color: var(--olive);
  background: rgba(184, 194, 164, 0.2);
  font-size: 0.78rem;
  font-weight: 800;
}

.status-pill-ready {
  color: #fff;
  background: var(--olive);
}

.status-pill-error {
  color: var(--terracotta-dark);
  border-color: rgba(184, 77, 49, 0.25);
  background: rgba(214, 114, 79, 0.12);
}

.job-message {
  margin: 1rem 0;
}

.progress-track {
  height: 0.65rem;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(64, 53, 43, 0.11);
}

.progress-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--terracotta-dark), var(--coral), var(--amber));
  transition: width 300ms ease;
}

.gallery-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.2rem;
}

.gallery-actions button,
.text-button {
  font: inherit;
}

.text-button {
  margin-top: 1rem;
  padding: 0;
  border: 0;
  color: var(--terracotta-dark);
  background: transparent;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 800;
  text-decoration: underline;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

.gallery-motif {
  position: relative;
  min-height: 26rem;
}

.photo-card {
  position: absolute;
  width: min(18rem, 80%);
  aspect-ratio: 4 / 5;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 2rem;
  background: var(--paper);
  box-shadow: var(--shadow);
}

.photo-card::before {
  display: block;
  width: 100%;
  height: 74%;
  content: "";
  border-radius: 1.35rem;
  background:
    radial-gradient(circle at 67% 31%, rgba(255, 247, 215, 0.9) 0 11%, transparent 11.5%),
    linear-gradient(153deg, transparent 0 43%, var(--olive) 43.5% 69%, transparent 69.5%),
    linear-gradient(27deg, var(--sage) 0 39%, var(--coral) 39.5% 66%, var(--amber) 66.5% 100%);
}

.photo-card::after {
  position: absolute;
  right: 1.3rem;
  bottom: 1.45rem;
  left: 1.3rem;
  height: 0.58rem;
  content: "";
  border-radius: 999px;
  background: linear-gradient(90deg, var(--ink) 0 42%, transparent 42.5% 49%, var(--line) 49.5% 100%);
}

.photo-card:nth-child(1) {
  top: 0.5rem;
  left: 1rem;
  transform: rotate(-10deg);
}

.photo-card:nth-child(2) {
  top: 2.6rem;
  right: 0;
  transform: rotate(8deg);
}

.photo-card:nth-child(3) {
  top: 5rem;
  left: 12%;
  transform: rotate(-1.5deg);
}

.section {
  padding: clamp(4rem, 8vw, 7rem) 0;
  scroll-margin-top: 1.5rem;
}

.section-intro {
  max-width: 44rem;
  margin-bottom: 2.5rem;
}

.section-intro p,
.card p,
.prose p,
.prose li {
  color: var(--muted);
}

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

.card {
  padding: clamp(1.4rem, 3vw, 2rem);
  border: 1px solid var(--line);
  border-radius: 1.6rem;
  background: rgba(255, 250, 241, 0.9);
  box-shadow: 0 16px 50px rgba(58, 43, 31, 0.07);
}

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

.step-number {
  display: grid;
  width: 2.2rem;
  height: 2.2rem;
  margin-bottom: 1.3rem;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: var(--terracotta-dark);
  font-size: 0.8rem;
  font-weight: 800;
}

.trust-band {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(2rem, 5vw, 5rem);
  padding: clamp(2rem, 5vw, 4.5rem);
  border: 1px solid rgba(35, 31, 27, 0.12);
  border-radius: 2rem;
  color: #fff;
  background: var(--ink);
  box-shadow: var(--shadow);
}

.trust-band .eyebrow {
  color: #f0b38f;
}

.trust-band p,
.trust-band li {
  color: rgba(255, 255, 255, 0.76);
}

.trust-band ul {
  display: grid;
  gap: 0.75rem;
  margin: 0;
  padding-left: 1.2rem;
}

.page-hero {
  max-width: 54rem;
  padding: clamp(4rem, 9vw, 7.5rem) 0 3rem;
}

.page-hero h1 {
  max-width: 14ch;
  font-size: clamp(3rem, 7vw, 5.8rem);
}

.page-meta {
  margin-top: 1.35rem;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
}

.prose-layout {
  display: grid;
  grid-template-columns: minmax(12rem, 0.3fr) minmax(0, 0.7fr);
  gap: clamp(2rem, 7vw, 7rem);
  padding-bottom: clamp(5rem, 10vw, 9rem);
}

.contents {
  align-self: start;
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: 1.3rem;
  background: rgba(255, 250, 241, 0.72);
}

.contents strong {
  display: block;
  margin-bottom: 0.65rem;
  font-family: var(--serif);
  font-size: 1.15rem;
}

.contents ul {
  display: grid;
  gap: 0.45rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.contents a {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
}

.prose {
  min-width: 0;
}

.prose section {
  padding: 0 0 2.4rem;
  scroll-margin-top: 2rem;
}

.prose section + section {
  padding-top: 2.4rem;
  border-top: 1px solid var(--line);
}

.prose h2 {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
}

.prose h3 {
  margin-top: 1.8rem;
}

.prose ul,
.prose ol {
  display: grid;
  gap: 0.7rem;
  padding-left: 1.4rem;
}

.notice {
  padding: 1.2rem 1.35rem;
  border-left: 0.32rem solid var(--terracotta);
  border-radius: 0.3rem 1rem 1rem 0.3rem;
  background: rgba(255, 250, 241, 0.82);
}

.notice strong {
  color: var(--ink);
}

.support-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin: 2rem 0 4rem;
}

.site-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 2rem;
  padding: 2.2rem 0 2.8rem;
  border-top: 1px solid var(--line);
}

.site-footer p {
  margin: 0.3rem 0 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.footer-links {
  flex-wrap: wrap;
  justify-content: flex-end;
  font-size: 0.88rem;
  font-weight: 700;
}

.footer-links li + li::before {
  margin: 0 0.45rem 0 0.15rem;
  color: var(--line);
  content: "/";
}

@media (max-width: 800px) {
  .site-nav a {
    padding: 0.45rem 0.5rem;
    font-size: 0.82rem;
  }

  .hero,
  .trust-band,
  .prose-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 3rem;
  }

  .gallery-motif {
    min-height: 25rem;
    overflow: hidden;
  }

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

  .contents {
    display: none;
  }
}

@media (max-width: 560px) {
  .site-shell {
    width: min(100% - 1.25rem, 1180px);
  }

  .brand {
    font-size: 1.08rem;
  }

  .brand-mark {
    width: 2.3rem;
    height: 1.95rem;
  }

  .site-header {
    align-items: flex-start;
    gap: 0.75rem;
  }

  .site-nav ul {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .photo-card {
    width: 72%;
  }

  .generator-card,
  .job-panel {
    border-radius: 1.35rem;
  }

  .job-heading {
    display: grid;
  }

  .status-pill {
    justify-self: start;
  }

  .gallery-actions .button {
    width: 100%;
  }

  .support-grid,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .footer-links {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media print {
  body {
    background: #fff;
  }

  .site-nav,
  .skip-link,
  .contents,
  .hero-actions {
    display: none;
  }

  .site-shell {
    width: 100%;
  }

  .site-footer,
  .prose section + section {
    border-color: #bbb;
  }
}
