/* ThornedMarble — green marble + thorn identity
   Palette pulled from the persona: marbled lime/forest body, coral sash accent. */
:root {
  --rind:    #1f3114;  /* page ground */
  --bark:    #28401a;  /* raised panels */
  --forest:  #2c481c;  /* borders, deep fills */
  --moss:    #3c5421;  /* marble blotch green */
  --leaf:    #6f9a2f;  /* mid green */
  --lime:    #a9cb3f;  /* signature marble green (skin) */
  --pith:    #d7e8a0;  /* pale lime — veins / highlights */
  --marble:  #eef3e2;  /* near-white, green-tinted text */
  --coral:   #f58a48;  /* sash accent */
  --coral-d: #cc5e30;  /* deep coral */
  --muted:   #b6c39c;  /* dim green-grey text */

  --maxw: 1000px;
  --display: "Fredoka", system-ui, sans-serif;
  --body: "Inter", system-ui, sans-serif;
  --mono: "Space Grotesk", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--rind);
  color: var(--marble);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
/* let the page content grow so the footer always sits at the bottom */
#app { flex: 1 0 auto; }

/* soft marble pools in the background */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -2;
  background:
    radial-gradient(55% 45% at 14% 4%, rgba(111,154,47,0.28), transparent 60%),
    radial-gradient(50% 45% at 92% 20%, rgba(60,84,33,0.42), transparent 65%),
    radial-gradient(60% 55% at 80% 98%, rgba(111,154,47,0.20), transparent 60%),
    var(--rind);
}

a { color: var(--lime); text-decoration: none; }
a:hover { color: var(--pith); }
img { display: block; max-width: 100%; }
:focus-visible { outline: 3px solid var(--coral); outline-offset: 3px; border-radius: 6px; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }

/* ---------- tabs header ---------- */
.tabs {
  position: sticky; top: 0; z-index: 50;
  background: rgba(24,38,15,0.78); backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(111,154,47,0.2);
}
.tabs .wrap { display: flex; align-items: center; gap: 16px; height: 62px; }
.tab-brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 600; font-size: 1.15rem; color: var(--marble); }
.tab-brand img { width: 32px; height: 32px; }
.tab-brand b { color: var(--lime); }
.tabs-nav { margin-left: auto; display: flex; gap: 6px; position: relative; }
.tabs-nav a {
  position: relative; z-index: 1;
  font-family: var(--mono); font-weight: 500; font-size: 0.86rem;
  color: var(--muted); padding: 8px 16px; border-radius: 999px;
  transition: color .25s;
}
.tabs-nav a:hover { color: var(--marble); }
.tabs-nav a[aria-current="page"] { color: var(--rind); font-weight: 700; }
/* the lime highlight that slides between tabs — transition exists ONLY while
   the .animate class is set (added just for navigation), so it never animates
   into place on first paint. */
.tab-indicator {
  position: absolute; z-index: 0; left: 0; top: 0; width: 0; height: 0;
  background: var(--lime); border-radius: 999px; opacity: 0;
}
.tab-indicator.animate {
  transition: left .45s cubic-bezier(.34,1.6,.5,1),
              width .45s cubic-bezier(.34,1.6,.5,1),
              top .3s ease, height .3s ease, transform .22s ease;
}
.tab-indicator.move { transform: scaleX(1.16); }
@media (prefers-reduced-motion: reduce) {
  .tab-indicator.animate { transition: opacity .2s; }
  .tab-indicator.move { transform: none; }
}

/* ---------- type helpers ---------- */
h2.title {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(1.8rem, 5vw, 2.7rem); margin: 0; color: var(--marble);
}

/* ---------- hero ---------- */
.hero { padding: clamp(48px, 8vw, 90px) 0 clamp(30px, 5vw, 56px); }
.hero .wrap {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 32px; align-items: center;
  padding-left: clamp(22px, 6vw, 96px);   /* nudge the whole hero right */
}

.wordmark {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(2.3rem, 7vw, 4rem); line-height: 0.95; margin: 0 0 14px;
}
.wordmark .thorned { color: var(--marble); }
.wordmark .marble { color: var(--lime); }
.roles { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 26px; }
.roles span { font-family: var(--mono); font-weight: 500; font-size: 0.82rem; color: var(--marble); background: rgba(111,154,47,0.14); border: 1px solid rgba(111,154,47,0.28); padding: 6px 13px; border-radius: 999px; }
.bio { margin: 22px 0 0; max-width: 470px; color: var(--marble); line-height: 1.6; font-size: 0.98rem; }
.bio:empty { display: none; }

/* persona portrait */
.portrait { justify-self: center; }
.portrait .char {
  width: clamp(150px, 21vw, 215px);
  filter: drop-shadow(0 14px 24px rgba(0,0,0,0.45));
}

/* ---------- link chips (glassy) ---------- */
.links { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.link {
  position: relative; overflow: hidden;
  display: flex; align-items: center; gap: 11px;
  padding: 14px 16px; border-radius: 16px;
  background: rgba(111,154,47,0.10);
  border: 1px solid rgba(111,154,47,0.24);
  color: var(--marble); transition: transform .15s, border-color .15s, background .15s;
}
.link:hover { transform: translateY(-2px); border-color: var(--coral); background: rgba(74,104,40,0.6); color: var(--marble); }
.link .ic { width: 24px; height: 24px; flex: none; color: var(--lime); }
.link:hover .ic { color: var(--coral); }
.link b { display: block; font-size: 0.95rem; font-weight: 600; }

/* lime glow that follows the cursor and blends into the surface */
.link::before, .queue-btn::before {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  border-radius: inherit; opacity: 0; transition: opacity .3s ease;
  mix-blend-mode: screen;
  background: radial-gradient(170px circle at var(--mx, 50%) var(--my, 50%),
              rgba(169,203,63,0.22), rgba(169,203,63,0) 60%);
}
.link:hover::before, .queue-btn:hover::before { opacity: 1; }

/* ---------- sections ---------- */
.section { padding: clamp(44px, 7vw, 76px) 0; }
.section-head { margin-bottom: 30px; }

/* thorn divider */
.thorn-rule { display: flex; align-items: center; gap: 12px; margin: 56px 0 0; }
.thorn-rule::before, .thorn-rule::after { content: ""; height: 1px; flex: 1; background: linear-gradient(90deg, transparent, rgba(111,154,47,0.5), transparent); }
.thorn-rule svg { width: 22px; height: 22px; color: var(--coral); flex: none; }

/* status pill */
.title .status { margin-left: 16px; }
.status { display: inline-flex; align-items: center; vertical-align: middle; gap: 9px; font-family: var(--mono); font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.78rem; padding: 8px 16px; border-radius: 999px; position: relative; top: -0.05em; }
.status.closed { color: #ffd9c7; background: rgba(185,83,42,0.18); border: 1px solid var(--coral-d); }
.status.open { color: #e7f4bb; background: rgba(111,154,47,0.20); border: 1px solid var(--leaf); }
.status .dot { width: 9px; height: 9px; border-radius: 50%; }
/* a ring radiates outward from the solid dot — the dot itself stays fully lit */
.status.open .dot { background: var(--lime); animation: pulse-open 1.8s ease-out infinite; }
.status.closed .dot { background: var(--coral); animation: pulse-closed 1.8s ease-out infinite; }
@keyframes pulse-open {
  0%   { box-shadow: 0 0 0 0 rgba(169,203,63,0.6); }
  70%  { box-shadow: 0 0 0 7px rgba(169,203,63,0); }
  100% { box-shadow: 0 0 0 0 rgba(169,203,63,0); }
}
@keyframes pulse-closed {
  0%   { box-shadow: 0 0 0 0 rgba(245,138,72,0.6); }
  70%  { box-shadow: 0 0 0 7px rgba(245,138,72,0); }
  100% { box-shadow: 0 0 0 0 rgba(245,138,72,0); }
}
@media (prefers-reduced-motion: reduce) { .status .dot { animation: none; } }

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.queue-btn { position: relative; overflow: hidden; cursor: pointer; display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-weight: 500; font-size: 0.95rem; color: var(--marble); background: rgba(111,154,47,0.14); border: 1px solid rgba(111,154,47,0.3); padding: 13px 22px; border-radius: 999px; transition: background .3s ease, border-color .15s ease, color .15s ease; }
.queue-btn:hover { border-color: var(--coral); color: var(--marble); background: rgba(74,104,40,0.6); }
.queue-btn svg { width: 19px; height: 19px; color: var(--lime); }
.queue-btn[aria-expanded="true"] { border-color: var(--coral); background: rgba(74,104,40,0.6); }

.muted-line { color: var(--muted); margin: 16px 0 18px; }

/* inline contact form — animated open/close via grid-rows 0fr -> 1fr.
   The <form> is a bare clipper (no padding/border) so it collapses fully to 0;
   the card visuals live on .cf-inner. */
.contact-form {
  display: grid; grid-template-rows: 0fr; max-width: 620px; margin-top: 0; opacity: 0;
  transition: grid-template-rows .35s ease, opacity .25s ease, margin-top .35s ease;
}
.contact-form[hidden] { display: none; }
.contact-form.open { grid-template-rows: 1fr; opacity: 1; margin-top: 18px; }
.contact-form > form { overflow: hidden; min-height: 0; }
.cf-inner {
  background: rgba(36,58,22,0.5); border: 1px solid rgba(111,154,47,0.24);
  border-radius: 20px; padding: clamp(18px,3vw,26px);
}
@media (prefers-reduced-motion: reduce) { .contact-form { transition: opacity .2s ease; } }
.cf-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.cf-field { display: flex; flex-direction: column; gap: 6px; font-family: var(--mono); font-size: 0.82rem; font-weight: 500; color: var(--muted); }
.cf-cap { display: block; }
.cf-field .cf-opt { color: var(--leaf); font-weight: 400; }
.contact-form label.cf-field { margin-bottom: 0; }
.contact-form input, .contact-form select, .contact-form textarea {
  font-family: var(--body); font-size: 0.96rem; line-height: 1.4; color: var(--marble);
  background: rgba(24,38,15,0.6); border: 1px solid rgba(111,154,47,0.3);
  border-radius: 12px; padding: 10px 12px; width: 100%; height: 44px;
}
/* match the select to the text inputs and give it a custom chevron */
.contact-form select {
  appearance: none; -webkit-appearance: none;
  padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23b6c39c' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center;
}
.contact-form textarea { resize: vertical; min-height: 110px; height: auto; }
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
  outline: none; border-color: var(--coral);
}
.contact-form label.cf-field:has(textarea) { margin-bottom: 14px; }
.cf-turnstile { margin: 4px 0 14px; line-height: 0; }
.cf-turnstile:empty { display: none; }
.cf-actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.cf-submit { cursor: pointer; }
.cf-submit[disabled] { opacity: 0.6; cursor: default; }
.cf-status { font-family: var(--mono); font-size: 0.82rem; color: var(--muted); }
.cf-status.ok { color: var(--lime); }
.cf-status.err { color: #ffb59a; }
@media (max-width: 520px) { .cf-grid { grid-template-columns: 1fr; } }

/* TOS */
.tos { background: rgba(36,58,22,0.5); border: 1px solid rgba(111,154,47,0.24); border-radius: 22px; padding: clamp(22px,3vw,34px); margin-top: 26px; }
.tos ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.tos li { position: relative; padding-left: 30px; color: var(--marble); font-size: 0.97rem; }
.tos li svg { position: absolute; left: 0; top: 2px; width: 17px; height: 17px; color: var(--coral); }
.tos strong { color: var(--lime); font-weight: 700; }

/* offerings */
.offer { margin-top: 40px; }
.offer-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 16px; margin-bottom: 4px; }
.offer-head h2, .offer-head h3 { font-family: var(--display); font-weight: 600; font-size: clamp(1.25rem, 3vw, 1.7rem); margin: 0; color: var(--marble); }
.price { font-family: var(--mono); font-weight: 700; color: var(--lime); font-size: 1rem; }
.addons { list-style: none; padding: 0; margin: 6px 0 18px; display: flex; flex-wrap: wrap; gap: 7px; }
.addons li { display: inline-flex; align-items: center; gap: 5px; font-family: var(--mono); font-weight: 500; font-size: 0.78rem; color: var(--marble); background: rgba(111,154,47,0.12); border: 1px solid rgba(111,154,47,0.22); padding: 4px 11px; border-radius: 999px; }
.addons li .plus { color: var(--coral); font-size: 1.4em; font-weight: 700; line-height: 1; }

.group-title { font-family: var(--display); font-weight: 600; font-size: clamp(1.5rem,4vw,2.1rem); color: var(--marble); margin: 16px 0 4px; }
.group-title + .offer { margin-top: 16px; }

/* galleries */
.grid { display: grid; gap: 11px; }
.grid.cols7 { grid-template-columns: repeat(7, minmax(0,1fr)); }
.grid.cols5 { grid-template-columns: repeat(5, minmax(0,1fr)); }
.grid.cols4 { grid-template-columns: repeat(4, minmax(0,1fr)); }
.grid.cols3 { grid-template-columns: repeat(3, minmax(0,1fr)); }

.tile {
  display: grid; place-items: center;
  border: 1px solid transparent; padding: 6px; background: transparent;
  cursor: zoom-in; border-radius: 16px; overflow: hidden; aspect-ratio: 1;
  transition: transform .18s ease, border-color .18s ease;
}
.tile img { max-width: 100%; max-height: 100%; object-fit: contain; }
.tile:hover { transform: translateY(-3px) rotate(var(--rot, -2deg)); border-color: var(--coral); }

/* illustrations: equal-width flex columns. The widest image fills its column;
   narrower ones keep their aspect and centre, so they get horizontal padding
   inside the column. Border + rounded corners sit on the image, not the column. */
.illus-grid { display: flex; gap: 12px; align-items: center; }
.illus-grid .tile.illus {
  flex: 1 1 0; min-width: 0;
  display: flex; align-items: center; justify-content: center;
  aspect-ratio: auto; height: auto; padding: 0; border: 0; background: transparent; overflow: visible;
}
.illus-grid .tile.illus img {
  width: auto; height: auto; max-width: 100%; max-height: clamp(160px, 20vw, 220px);
  border: 1px solid transparent; border-radius: 16px; display: block;
  transition: transform .18s ease, border-color .18s ease;
}
.illus-grid .tile.illus:hover { transform: none; }
.illus-grid .tile.illus:hover img { transform: translateY(-3px) rotate(var(--rot, -2deg)); border-color: var(--coral); }

/* ---------- comic page ---------- */
.comic-hero { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(20px, 4vw, 40px); align-items: center; }
.comic-cover {
  width: 100%; border-radius: 24px;
  border: 1px solid rgba(111,154,47,0.3);
  box-shadow: 0 24px 60px -28px rgba(0,0,0,0.8);
}
.comic-intro .title { margin-bottom: 16px; }
.lead { font-size: 1.12rem; color: var(--marble); margin: 0 0 18px; max-width: 52ch; }
.warn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--mono); font-weight: 500; font-size: 0.86rem; color: #ffd9c7;
  background: rgba(185,83,42,0.18); border: 1px solid var(--coral-d);
  padding: 9px 15px; border-radius: 14px; margin: 0 0 22px;
}
.warn svg { width: 18px; height: 18px; color: var(--coral); flex: none; }
.warn-wrap { text-align: center; margin-top: 32px; }

.people { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
.person {
  background: rgba(36,58,22,0.5); border: 1px solid rgba(111,154,47,0.24);
  border-radius: 24px; padding: 26px; text-align: center;
}
.person img { width: 150px; height: 150px; object-fit: contain; margin: 0 auto 12px; }
.person h3 { font-family: var(--display); font-weight: 600; font-size: 1.4rem; margin: 0 0 14px; color: var(--marble); }
.person-note { margin: 0; font-size: 0.92rem; color: var(--muted); }
.person-links { display: flex; justify-content: center; flex-wrap: wrap; gap: 9px; }
.person-links a {
  display: grid; place-items: center; width: 42px; height: 42px;
  border-radius: 12px; color: var(--lime);
  background: rgba(111,154,47,0.12); border: 1px solid rgba(111,154,47,0.24);
  transition: transform .15s, border-color .15s, color .15s, background .15s;
}
.person-links a:hover { transform: translateY(-2px); color: var(--coral); border-color: var(--coral); background: rgba(111,154,47,0.2); }
.person-links svg { width: 21px; height: 21px; }

@media (max-width: 720px) {
  .comic-hero { grid-template-columns: 1fr; }
  .comic-cover { max-width: 360px; margin: 0 auto; }
}

/* footer */
.site-footer { text-align: center; padding: 30px 22px; color: var(--muted); font-family: var(--display); font-weight: 500; font-size: 0.92rem; letter-spacing: 0.01em; }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 100; background: rgba(8,12,5,0.93); display: none; place-items: center; padding: 22px; overflow: hidden; }
.lb.show { display: grid; }
/* dvh tracks the *visible* viewport, so the image never grows behind the iOS
   address bar and the close button (z-index above) stays clear of it */
.lb img { max-width: 92vw; max-height: 88vh; max-height: 88dvh; border-radius: 12px; box-shadow: 0 30px 80px -20px #000;
  cursor: var(--cur-help), zoom-in; transition: transform .2s ease; user-select: none; -webkit-user-drag: none; }
.lb.zoomed.pannable img { cursor: var(--cur-move), move; }
.lb.panning img { transition: none; }
.lb button { position: absolute; z-index: 2; width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(111,154,47,0.4); background: rgba(20,32,13,0.85); color: var(--marble); font-size: 1.5rem; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.lb button:hover { background: var(--coral); color: var(--rind); }
.lb button svg { width: 20px; height: 20px; display: block; }
.lb-nav svg { width: 26px; height: 26px; }
#lbClose { top: max(16px, env(safe-area-inset-top, 0px)); right: 18px; }
.lb-nav { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 2rem; }
#lbPrev { left: 18px; }
#lbNext { right: 18px; }
@media (max-width: 560px) { .lb-nav { width: 44px; height: 44px; font-size: 1.6rem; } #lbPrev { left: 8px; } #lbNext { right: 8px; } }

/* responsive */
@media (max-width: 560px) {
  .tab-brand { display: none; }
  .tabs-nav { margin: 0 auto; gap: 6px; }
  .tabs-nav a { padding: 8px 14px; font-size: 0.82rem; }
}

/* mobile illustrations: sketch/lineart 2 columns, full 1 column */
@media (max-width: 600px) {
  .illus-grid { flex-wrap: wrap; }
  .illus-grid .tile.illus { flex: 1 1 calc(50% - 6px); }
  .illus-grid.full-grid .tile.illus { flex: 1 1 100%; justify-content: flex-start; }
}

/* narrow screens: tidy up wrapping of the status pill and offer prices */
@media (max-width: 560px) {
  /* keep the open/closed pill flush-left with no extra gap when it wraps */
  .section-head .title { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; line-height: 1.15; }
  .title .status { margin-left: 0; top: 0; }
  /* price wraps under the title cleanly, with a touch of space after */
  .offer-head { gap: 4px 14px; margin-bottom: 12px; }
  .offer-head h2, .offer-head h3 { line-height: 1.15; }
}

@media (max-width: 760px) {
  .hero .wrap { grid-template-columns: 1fr; padding-left: 22px; row-gap: 60px; justify-items: center; }
  .hero-copy { max-width: 340px; margin-inline: auto; }
  .hero-copy-inner { text-align: center; }
  .roles { justify-content: center; }
  .grid.cols7 { grid-template-columns: repeat(4, minmax(0,1fr)); }
  .grid.cols5 { grid-template-columns: repeat(3, minmax(0,1fr)); }
  .grid.cols4 { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .grid.cols3 { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

/* ---- custom "Gooby" character cursors (gift from Pumpkeo) ----
   The --cur-* variables are defined in the CMS-writable assets/cursors.css (so
   the cursors can be replaced via /admin); the rules below just apply them. */
html, body { cursor: var(--cur-normal), auto; }
a, button, [role="button"], summary, label, select,
.queue-btn, .cf-submit, .lb button, .tab-brand, .tabs-nav a, .link, .switch .slider, .adm-btn, .mini {
  cursor: var(--cur-link), pointer;
}
/* I-beam over selectable text; the interactive rule above re-asserts itself on
   any links/buttons nested inside these (cursor is set per element under it) */
p, h1, h2, h3, h4, li, blockquote, figcaption,
input[type="text"], input[type="email"], input[type="search"], input[type="url"],
input[type="password"], textarea {
  cursor: var(--cur-text), text;
}
.tile { cursor: var(--cur-hand), zoom-in; }
button[disabled], .cf-submit[disabled], a[aria-disabled="true"] {
  cursor: var(--cur-no), not-allowed;
}
