/* ============================================
   designsbyalice — design tokens
   ============================================ */
:root {
  --linen: #F7F2E9;
  --card: #FFFDF8;
  --ink: #3A342C;
  --ink-soft: #6b6154;
  --rose: #C17B84;
  --rose-deep: #a9636d;
  --sage: #8B9A7A;
  --thread: #B8933B;
  --border-hairline: rgba(58, 52, 44, 0.14);

  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Karla", -apple-system, sans-serif;
  --font-mono: "Space Mono", monospace;

  --radius: 6px;
  --max-width: 1100px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--linen);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

img { max-width: 100%; display: block; }

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   Signature element: running stitch divider
   ============================================ */
.stitch {
  border: none;
  height: 10px;
  margin: 0;
  background-image: repeating-linear-gradient(
    to right,
    var(--thread) 0px,
    var(--thread) 10px,
    transparent 10px,
    transparent 20px
  );
  background-position: center;
  background-repeat: repeat-x;
  background-size: 20px 2px;
  opacity: 0.55;
}

.stitch-border {
  position: relative;
  border: 2px dashed var(--thread);
  border-radius: var(--radius);
}

/* ============================================
   Header / Nav
   ============================================ */
.site-header {
  padding: 28px 0 0;
  text-align: center;
  position: relative;
}

.wordmark {
  font-family: var(--font-display);
  font-style: italic;
  font-optical-sizing: auto;
  font-weight: 500;
  font-size: 2.6rem;
  letter-spacing: -0.01em;
  color: var(--ink);
  display: inline-block;
}

.wordmark span {
  color: var(--rose);
}

.tagline {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 6px 0 22px;
}

.main-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 36px;
  padding: 14px 0;
  border-top: none;
}

.main-nav a {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.86rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink);
  padding-bottom: 4px;
  border-bottom: 2px solid transparent;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.main-nav a:hover,
.main-nav a.active {
  border-bottom-color: var(--rose);
  color: var(--rose-deep);
}

.cart-icon-link {
  position: absolute;
  right: 24px;
  top: 30px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.cart-icon-link svg {
  width: 24px;
  height: 24px;
  stroke: var(--ink);
  transition: stroke 0.2s ease;
}

.cart-icon-link:hover svg { stroke: var(--rose-deep); }

.cart-count {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  background: var(--rose);
  color: var(--card);
  min-width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  position: relative;
  top: -8px;
  left: -10px;
}

/* ============================================
   Hero
   ============================================ */
.hero {
  text-align: center;
  padding: 64px 24px 48px;
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.05;
  margin: 0 0 18px;
  max-width: 14ch;
  margin-inline: auto;
}

.hero p {
  font-size: 1.05rem;
  color: var(--ink-soft);
  max-width: 46ch;
  margin: 0 auto;
}

/* ============================================
   Product grid
   ============================================ */
.section-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--thread);
  text-align: center;
  margin: 48px 0 6px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 32px;
  padding: 32px 0 72px;
}

.product-card {
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(58, 52, 44, 0.10);
}

.product-swatch {
  aspect-ratio: 4 / 5;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.85);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.product-info {
  padding: 16px 18px 20px;
  border-top: 2px dashed var(--border-hairline);
}

.product-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin: 0 0 4px;
}

.product-desc {
  font-size: 0.85rem;
  color: var(--ink-soft);
  margin: 0 0 12px;
}

.product-price {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--rose-deep);
  margin: 0 0 14px;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 12px 20px;
  border-radius: var(--radius);
  border: 2px solid var(--ink);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  text-align: center;
  transition: background 0.2s ease, color 0.2s ease;
  width: 100%;
}

.btn:hover { background: var(--ink); color: var(--linen); }

.btn-primary {
  background: var(--rose);
  border-color: var(--rose);
  color: var(--card);
}

.btn-primary:hover {
  background: var(--rose-deep);
  border-color: var(--rose-deep);
  color: var(--card);
}

/* ============================================
   Footer
   ============================================ */
.site-footer {
  text-align: center;
  padding: 36px 24px 48px;
}

.site-footer .handle {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 16px;
  display: inline-block;
}

/* ============================================
   Generic content pages (About / Contact)
   ============================================ */
.content-page {
  padding: 48px 0 80px;
  max-width: 680px;
  margin: 0 auto;
}

.content-page h1 {
  font-family: var(--font-display);
  font-size: 2.4rem;
  margin-bottom: 8px;
}

.content-page .eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--thread);
}

.content-page p { color: var(--ink-soft); font-size: 1rem; }

.about-portrait {
  display: block;
  width: 100%;
  max-width: 340px;
  margin: 28px auto;
  border-radius: var(--radius);
  border: 2px solid var(--border-hairline);
}

.about-photo {
  aspect-ratio: 16/10;
  border-radius: var(--radius);
  margin: 28px 0;
  background: linear-gradient(135deg, var(--sage), var(--rose));
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.85);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* Contact form */
.form-field { margin-bottom: 18px; text-align: left; }

.form-field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 6px;
}

.form-field input,
.form-field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius);
  border: 2px dashed var(--border-hairline);
  background: var(--card);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
}

.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--rose);
}

.form-note {
  font-size: 0.8rem;
  color: var(--ink-soft);
  margin-top: 8px;
}

/* Cart page */
.cart-table { width: 100%; border-collapse: collapse; margin: 24px 0; }

.cart-row {
  display: grid;
  grid-template-columns: 64px 1fr auto auto auto;
  align-items: center;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 2px dashed var(--border-hairline);
}

.cart-swatch {
  width: 64px;
  height: 64px;
  border-radius: var(--radius);
}

.cart-item-name { font-family: var(--font-display); font-size: 1.05rem; }
.cart-item-meta { font-family: var(--font-mono); font-size: 0.8rem; color: var(--ink-soft); }

.qty-input {
  width: 48px;
  text-align: center;
  padding: 6px;
  border-radius: var(--radius);
  border: 2px dashed var(--border-hairline);
  font-family: var(--font-mono);
  background: var(--card);
}

.remove-link {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--rose-deep);
  cursor: pointer;
  background: none;
  border: none;
  text-decoration: underline;
}

.cart-summary {
  max-width: 320px;
  margin-left: auto;
  padding-top: 20px;
}

.cart-summary-row {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.empty-cart {
  text-align: center;
  padding: 60px 0;
  color: var(--ink-soft);
}

@media (max-width: 640px) {
  .main-nav { gap: 20px; flex-wrap: wrap; }
  .cart-icon-link { position: static; margin-top: 12px; justify-content: center; }
  .site-header { padding-bottom: 8px; }
  .cart-row { grid-template-columns: 48px 1fr; grid-template-areas: "img name" "img meta" "img actions"; }
}

/* ============================================
   Cinematic scroll hero — canvas-driven frame
   scrubber, tied to scroll position. Sits between
   the header and the product grid on index.html.
   ============================================ */
:root {
  --hero-black: #0B0A08;
}

.scroll-hero {
  position: relative;
  height: 320vh;
  background: var(--hero-black);
}

.scroll-hero__sticky {
  position: sticky;
  top: 0;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  background: var(--hero-black);
}

.scroll-hero__canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.scroll-hero__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0 clamp(20px, 6vw, 80px) clamp(56px, 9vh, 120px);
  pointer-events: none;
  background: linear-gradient(
    to top,
    rgba(11,10,8,0.85) 0%,
    rgba(11,10,8,0.30) 45%,
    transparent 75%
  );
}

.scroll-hero__label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 16px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.scroll-hero__title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  line-height: 1.05;
  color: #FFFDF8;
  max-width: 16ch;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease 0.08s, transform 0.7s ease 0.08s;
}

.scroll-hero__title em {
  font-style: italic;
  color: var(--thread);
}

.scroll-hero__sub {
  font-family: var(--font-body);
  font-size: 1rem;
  color: #E5DED0;
  max-width: 46ch;
  margin-top: 18px;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease 0.16s, transform 0.7s ease 0.16s;
}

.scroll-hero__cta {
  margin-top: 28px;
  display: inline-flex;
  width: fit-content;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--card);
  background: var(--rose);
  border: 2px solid var(--rose);
  border-radius: var(--radius);
  padding: 0.85rem 1.8rem;
  pointer-events: auto;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease 0.24s, transform 0.7s ease 0.24s,
              background 0.2s ease, border-color 0.2s ease;
}

.scroll-hero__cta:hover {
  background: var(--rose-deep);
  border-color: var(--rose-deep);
}

.scroll-hero__scrollcue {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  writing-mode: vertical-rl;
  opacity: 0;
  transition: opacity 0.6s ease 0.5s;
}

.scroll-hero.is-visible .scroll-hero__label,
.scroll-hero.is-visible .scroll-hero__title,
.scroll-hero.is-visible .scroll-hero__sub,
.scroll-hero.is-visible .scroll-hero__cta,
.scroll-hero.is-visible .scroll-hero__scrollcue {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 640px) {
  .scroll-hero { height: 280vh; }
}

/* ============================================
   Order / design-your-tank form
   (replaces the fixed-SKU product grid — this
   is made-to-order, no prices, no cart, no
   payment. Submits via Netlify Forms straight
   to Alice's inbox.)
   ============================================ */
.order-section {
  padding: 24px 0 80px;
}

.order-intro {
  max-width: 56ch;
  margin: 0 auto 36px;
  text-align: center;
  color: var(--ink-soft);
}

.hidden-field {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.order-form {
  max-width: 560px;
  margin: 0 auto;
  background: var(--card);
  border-radius: var(--radius);
  padding: 32px clamp(20px, 5vw, 44px) 40px;
  border: 2px dashed var(--border-hairline);
}

.order-field-group {
  margin-bottom: 28px;
}

.order-field-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--thread);
  margin-bottom: 14px;
}

.color-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.swatch-option {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.swatch-option input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.swatch {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid transparent;
  box-shadow: inset 0 0 0 1px rgba(58,52,44,0.15);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.swatch--white { background: #FFFFFF; }
.swatch--gray  { background: #9A968D; }
.swatch--coral { background: #E8654A; }
.swatch--other {
  background: var(--linen);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--ink-soft);
  box-shadow: inset 0 0 0 2px dashed var(--border-hairline), inset 0 0 0 1px rgba(58,52,44,0.15);
  border: 2px dashed var(--border-hairline);
}

.swatch-option input:checked + .swatch {
  box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--rose-deep);
  transform: scale(1.06);
}

.swatch-option input:focus-visible + .swatch {
  outline: 2px solid var(--rose-deep);
  outline-offset: 2px;
}

.swatch-name {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.design-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.design-option {
  cursor: pointer;
}

.design-option input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.design-option span {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  padding: 10px 16px;
  border-radius: 999px;
  border: 2px solid var(--border-hairline);
  color: var(--ink);
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.design-option input:checked + span {
  border-color: var(--rose);
  background: var(--rose);
  color: var(--card);
}

.design-option input:focus-visible + span {
  outline: 2px solid var(--rose-deep);
  outline-offset: 2px;
}

.order-submit {
  width: auto;
  padding: 0.95rem 2.4rem;
  margin-top: 8px;
}

.form-status {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  margin-top: 12px;
  min-height: 1.2em;
}

.form-status--success { color: var(--sage); }
.form-status--error { color: var(--rose-deep); }

.form-status--success a { color: inherit; text-decoration: underline; }

.color-reference {
  margin-bottom: 20px;
}

.color-reference img {
  display: block;
  width: 100%;
  max-width: 420px;
  border-radius: var(--radius);
  border: 2px solid var(--border-hairline);
}

.color-reference-caption {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 8px;
}

.design-options--photo {
  align-items: flex-start;
}

.design-option--photo {
  cursor: pointer;
}

.design-option--photo input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}

.design-option--photo figure {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: 104px;
}

.design-option--photo img {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 12px;
  border: 2px solid var(--border-hairline);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.design-option--photo figcaption {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.74rem;
  text-align: center;
  color: var(--ink);
}

.design-option--photo input:checked + figure img {
  border-color: var(--rose-deep);
  box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--rose-deep);
  transform: scale(1.03);
}

.design-option--photo input:focus-visible + figure img {
  outline: 2px solid var(--rose-deep);
  outline-offset: 2px;
}

.process-gallery {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  margin: 28px 0 8px;
}

.process-gallery figure {
  flex: 1 1 260px;
  margin: 0;
}

.process-gallery img {
  width: 100%;
  display: block;
  border-radius: var(--radius);
  border: 2px solid var(--border-hairline);
}

.process-gallery figcaption {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 10px;
  text-align: center;
}

@media (max-width: 640px) {
  .order-form { padding: 24px 18px 32px; }
}
