/* TrumpkinContest.com — public styles.
   Palette: char #14110f, crate #1e1913, cream #f4e9d4, ember #ff7a1a, vine #8fbf5f.
   No web fonts: system stacks keep the site fast and free of third-party requests. */
:root {
  --char: #14110f;
  --crate: #1e1913;
  --crate-2: #241d16;
  --line: #3a3128;
  --cream: #f4e9d4;
  --muted: #bcae98;
  --ember: #ff7a1a;
  --ember-hi: #ff9646;
  --vine: #8fbf5f;
  --alert: #ffb4a2;
  --focus: #ffd08a;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--char); color: var(--cream); font: 1.0625rem/1.6 var(--sans); }
img { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
a { color: var(--ember-hi); text-underline-offset: 3px; }
a:hover { color: #ffb070; }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; line-height: 1.12; letter-spacing: -0.015em; margin: 0 0 .6em; }
h1 { font-size: clamp(2.2rem, 6vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.3rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: .75rem; top: -4rem; background: var(--ember); color: #1a0f05; padding: .6rem 1rem; border-radius: 8px; z-index: 100; font-weight: 700; }
.skip-link:focus { top: .75rem; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.wrap { width: 100%; max-width: 1180px; margin-inline: auto; padding-inline: 1.25rem; }
.narrow { max-width: 760px; }
.measure { max-width: 46rem; }
.muted { color: var(--muted); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(20, 17, 15, .96); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 1rem; }
.logo { display: inline-flex; align-items: center; gap: .55rem; text-decoration: none; color: var(--cream); }
.logo-icon { width: 36px; height: 36px; flex: none; }
.logo-word { font-family: var(--serif); font-weight: 700; font-size: 1.3rem; letter-spacing: -0.02em; line-height: 1; }
.logo-a { color: var(--cream); }
.logo-b { color: var(--ember); margin-left: .18em; font-style: italic; font-weight: 600; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: .25rem; }
.site-nav a { display: block; padding: .55rem .9rem; color: var(--cream); text-decoration: none; border-radius: 999px; }
.site-nav a:hover { background: var(--crate-2); }
.site-nav a[aria-current="page"] { background: var(--ember); color: #1a0f05; font-weight: 700; }
.nav-toggle { display: none; background: none; border: 1.5px solid var(--line); border-radius: 10px; width: 46px; height: 42px; cursor: pointer; position: relative; color: var(--cream); }
.nav-toggle-bar, .nav-toggle-bar::before, .nav-toggle-bar::after { content: ""; position: absolute; left: 12px; right: 12px; height: 2px; background: var(--cream); }
.nav-toggle-bar { top: 20px; } .nav-toggle-bar::before { top: -7px; left: 0; right: 0; } .nav-toggle-bar::after { top: 7px; left: 0; right: 0; }
@media (max-width: 759px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--char); border-bottom: 1px solid var(--line); padding: .5rem 1.25rem 1rem; }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; }
  .site-nav a { padding: .85rem 1rem; }
}

/* Buttons */
.btn { display: inline-block; font: 700 1rem/1 var(--sans); padding: .95rem 1.5rem; border-radius: 999px; border: 2px solid transparent; text-decoration: none; cursor: pointer; transition: background-color .15s, border-color .15s, transform .15s; }
.btn-primary { background: var(--ember); color: #1a0f05; }
.btn-primary:hover { background: var(--ember-hi); color: #1a0f05; }
.btn-ghost { background: transparent; color: var(--cream); border-color: #6b5d4c; }
.btn-ghost:hover { border-color: var(--cream); color: var(--cream); }
.btn-lg { padding: 1.1rem 2rem; font-size: 1.1rem; }
.btn-sm { padding: .5rem .85rem; font-size: .875rem; }
.btn-danger { background: transparent; color: var(--alert); border-color: #8a4a3c; }
.btn-danger:hover { background: #3a1f19; color: #ffd0c4; }
.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.text-link { font-weight: 600; }

/* Hero */
.hero { padding: clamp(2.5rem, 7vw, 5.5rem) 0 clamp(3rem, 7vw, 5rem); background: radial-gradient(60% 70% at 78% 40%, rgba(255, 122, 26, .17), transparent 70%); }
.hero-inner { display: grid; gap: 2.5rem; align-items: center; }
.hero h1 { font-size: clamp(3.2rem, 11vw, 7rem); line-height: .92; letter-spacing: -0.035em; margin-bottom: .35em; }
.hero-lede { font: italic 600 clamp(1.3rem, 3.4vw, 1.9rem)/1.25 var(--serif); margin-bottom: .8em; }
.hero-sub { color: var(--muted); max-width: 46ch; font-size: 1.1rem; }
.hero-stack { position: relative; aspect-ratio: 1 / 1.05; width: 100%; max-width: 520px; margin-inline: auto; }
.print { position: absolute; display: block; background: var(--cream); color: #1a1109; padding: .55rem .55rem .5rem; border-radius: 3px; text-decoration: none; box-shadow: 0 14px 32px rgba(0, 0, 0, .55); transition: transform .2s; }
.print img { width: 100%; height: auto; border-radius: 1px; }
.print-cap { display: block; padding: .5rem .25rem .1rem; font: italic 600 .95rem/1.2 var(--serif); }
.print-1 { width: 53%; left: 0; top: 4%; transform: rotate(-5deg); z-index: 2; }
.print-2 { width: 47%; right: 0; top: 0; transform: rotate(5deg); }
.print-3 { width: 52%; left: 30%; bottom: 0; transform: rotate(-2deg); z-index: 3; }
.print:hover { transform: rotate(0) scale(1.03); z-index: 5; }
.print-empty { padding: 2rem; text-align: center; width: 70%; left: 15%; top: 15%; }
.print-icon { width: 96px; height: 96px; margin: 0 auto .5rem; }
@media (min-width: 900px) { .hero-inner { grid-template-columns: 1.1fr .9fr; } }
@media (prefers-reduced-motion: no-preference) {
  .print { animation: settle .7s cubic-bezier(.2, .8, .3, 1) both; }
  .print-2 { animation-delay: .12s; } .print-3 { animation-delay: .24s; }
  @keyframes settle { from { opacity: 0; translate: 0 -22px; } to { opacity: 1; translate: 0 0; } }
}

/* Sections */
.section { padding: clamp(3rem, 6vw, 4.75rem) 0; }
.section-tint { background: var(--crate); border-block: 1px solid var(--line); }
.page-head { padding-bottom: 1.5rem; }
.lead { font: 1.3rem/1.5 var(--serif); color: var(--cream); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.section-head h2 { margin: 0; }
.empty { color: var(--muted); padding: 2rem 0; }

/* Steps: a genuine sequence, so numbered */
.steps { list-style: none; margin: 2rem 0 0; padding: 0; display: grid; gap: 1.5rem; counter-reset: step; }
.steps li { counter-increment: step; border-top: 2px solid var(--ember); padding-top: 1rem; }
.steps li::before { content: counter(step); display: block; font: 700 2.4rem/1 var(--serif); color: var(--ember); margin-bottom: .4rem; }
.steps p { color: var(--muted); margin: 0; }
@media (min-width: 720px) { .steps { grid-template-columns: repeat(4, 1fr); } }

.cta-band { background: linear-gradient(180deg, var(--crate), #2a1d10); border-top: 1px solid var(--line); padding: clamp(3rem, 6vw, 4.5rem) 0; text-align: center; }
.cta-inner h2 { max-width: 20ch; margin-inline: auto; margin-bottom: 1.25rem; }

/* Gallery */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1.25rem; }
.chips a { padding: .5rem 1rem; border: 1.5px solid var(--line); border-radius: 999px; color: var(--cream); text-decoration: none; font-size: .95rem; }
.chips a:hover { border-color: var(--muted); }
.chips a[aria-current="true"] { background: var(--cream); color: #1a1109; border-color: var(--cream); font-weight: 700; }
.masonry { column-count: 1; column-gap: 1.1rem; }
@media (min-width: 560px) { .masonry { column-count: 2; } }
@media (min-width: 960px) { .masonry { column-count: 3; } }
.card { break-inside: avoid; margin: 0 0 1.1rem; background: var(--crate-2); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.card-media { display: block; position: relative; overflow: hidden; background: #0e0c0a; }
.card-media img { width: 100%; height: auto; transition: transform .35s ease; }
.card-media:hover img { transform: scale(1.035); }
.badge { position: absolute; left: .7rem; top: .7rem; background: var(--ember); color: #1a0f05; font: 700 .8rem/1 var(--sans); padding: .4rem .65rem; border-radius: 6px; }
.card-body { padding: .9rem 1rem 1.05rem; }
.card-title { font-size: 1.2rem; margin: 0 0 .25rem; }
.card-title a { color: var(--cream); text-decoration: none; }
.card-title a:hover { text-decoration: underline; }
.card-resembles { color: var(--ember-hi); font-weight: 600; margin: 0 0 .35rem; }
.card-meta { color: var(--muted); font-size: .875rem; margin: 0; }
.pager { display: flex; justify-content: center; gap: .75rem; margin-top: 2rem; flex-wrap: wrap; }

/* Lightbox */
.lightbox { border: 0; padding: 0; background: transparent; width: 100%; height: 100%; max-width: 100vw; max-height: 100vh; color: var(--cream); }
.lightbox::backdrop { background: rgba(10, 8, 6, .94); }
.lb-inner { height: 100%; display: flex; align-items: center; justify-content: center; gap: .5rem; padding: 1rem; overflow-y: auto; }
.lb-fig { margin: 0; max-width: min(92vw, 860px); text-align: center; }
.lb-fig img { max-width: 100%; max-height: 68vh; width: auto; height: auto; margin: 0 auto; border-radius: 6px; object-fit: contain; }
.lb-fig h2 { font-size: 1.5rem; margin: 1rem 0 .25rem; }
.lb-fig p { margin: 0 0 .4rem; color: var(--muted); }
#lb-meta { color: var(--ember-hi); font-weight: 600; }
.lb-btn { background: rgba(244, 233, 212, .1); color: var(--cream); border: 1.5px solid rgba(244, 233, 212, .35); border-radius: 999px; width: 48px; height: 48px; font-size: 1.8rem; line-height: 1; cursor: pointer; flex: none; }
.lb-btn:hover { background: rgba(244, 233, 212, .22); }
.lb-close { position: fixed; top: 1rem; right: 1rem; z-index: 2; }
@media (max-width: 640px) {
  .lb-inner { flex-wrap: wrap; align-content: center; }
  .lb-fig { order: 1; width: 100%; } .lb-prev { order: 2; } .lb-next { order: 3; }
}

/* Single pumpkin page */
.single-grid { display: grid; gap: 2rem; align-items: start; }
@media (min-width: 900px) { .single-grid { grid-template-columns: 1.35fr 1fr; gap: 3rem; } .single-info { position: sticky; top: 90px; } }
.single-photo { margin: 0; }
.single-photo img { width: 100%; border-radius: 10px; border: 1px solid var(--line); }
.crumbs { color: var(--muted); font-size: .9rem; }
.single-resembles { font: italic 600 1.35rem/1.3 var(--serif); color: var(--ember-hi); }
.single-caption { font-size: 1.1rem; }
.share { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1.25rem 0; }
.fine { color: var(--muted); font-size: .85rem; }

/* Prose pages */
.prose { max-width: 68ch; }
.prose h2 { margin-top: 1.8em; font-size: 1.6rem; }
.prose li { margin-bottom: .6em; }
.rules-list { padding-left: 1.2rem; }

/* Forms */
.form { display: grid; gap: 1.4rem; }
.field label, .consent legend { display: block; font-weight: 700; margin-bottom: .4rem; }
.req, .opt { font-weight: 400; color: var(--muted); font-size: .9rem; }
input[type="text"], input[type="email"], input[type="password"], select, textarea, input[type="file"] {
  width: 100%; background: var(--crate); color: var(--cream); border: 1.5px solid #574a3c; border-radius: 10px; padding: .8rem .95rem; font: inherit; }
input[type="file"] { padding: .7rem; }
input[type="file"]::file-selector-button { background: var(--ember); border: 0; border-radius: 999px; padding: .5rem 1rem; margin-right: .8rem; font-weight: 700; color: #1a0f05; cursor: pointer; }
textarea { resize: vertical; }
[aria-invalid="true"] { border-color: var(--alert); border-width: 2px; }
.help { color: var(--muted); font-size: .9rem; margin: .4rem 0 0; }
.field-error { color: var(--alert); font-weight: 600; margin: .4rem 0 0; }
.field-error::before { content: "Problem: "; }
.field-row { display: grid; gap: 1.4rem; }
@media (min-width: 640px) { .field-row { grid-template-columns: 1fr 1fr; } }
.consent { border: 1px solid var(--line); border-radius: 12px; padding: 1.1rem 1.2rem; margin: 0; background: var(--crate); }
.consent legend { padding: 0 .4rem; }
.check { display: flex; gap: .75rem; align-items: flex-start; margin-top: .9rem; }
.check input { width: 1.35rem; height: 1.35rem; margin-top: .2rem; accent-color: var(--ember); flex: none; }
.check label { font-weight: 400; margin: 0; }
.photo-preview { max-height: 320px; width: auto; margin-top: .9rem; border-radius: 10px; border: 1px solid var(--line); }
.notice { border-radius: 12px; padding: 1.1rem 1.3rem; margin-bottom: 1.5rem; border: 1.5px solid; }
.notice h2 { font-size: 1.3rem; margin-bottom: .4rem; }
.notice ul { margin: 0; padding-left: 1.2rem; }
.notice-ok { background: #1c2616; border-color: #4f7a33; }
.notice-error { background: #2c1712; border-color: #a3503f; }
.notice p:last-child { margin-bottom: 0; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 3rem 0 1.5rem; background: #0f0d0b; }
.footer-grid { display: grid; gap: 2rem; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.4fr 1fr; } }
.disclaimer { color: var(--muted); font-size: .9rem; max-width: 62ch; margin-top: 1rem; }
.footer-nav ul { list-style: none; margin: 0; padding: 0; columns: 2; }
.footer-nav a { display: inline-block; padding: .3rem 0; color: var(--cream); }
.copyright { color: var(--muted); font-size: .85rem; margin: 2rem auto 0; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
