:root {
  --gold: #e8b923;
  --gold-light: #f7d774;
  --gold-dark: #9c7414;
  --black: #0b0906;
  --brown: #2a1a0e;
  --text: #f1e6cf;
  --muted: #b9a888;
  --serif: "Cinzel", "Trajan Pro", "Palatino Linotype", Georgia, serif;
  --african: "Ojuju", var(--serif);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: radial-gradient(ellipse at top, var(--brown), var(--black) 70%) fixed;
  color: var(--text);
  font: 1rem/1.6 system-ui, sans-serif;
}

main { flex: 1; }

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

h1, h2 {
  font-family: var(--serif);
  color: var(--gold);
  letter-spacing: 0.04em;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgb(11 9 6 / 0.92);
  border-bottom: 1px solid var(--gold-dark);
}

.nav {
  max-width: 72rem;
  margin: 0 auto;
  padding: 0.75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.nav-brand {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--gold);
}

.nav-links, .footer-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.9rem;
}

.hero {
  text-align: center;
  padding: 2rem 1.25rem 3rem;
}

.hero-logo {
  display: block;
  margin: 0 auto 1.5rem;
  width: min(28rem, 90vw);
  height: auto;
  filter: drop-shadow(0 0 2rem rgb(232 185 35 / 0.25));
}

.button {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  border-radius: 0.25rem;
  background: linear-gradient(var(--gold-light), var(--gold) 50%, var(--gold-dark));
  color: var(--black);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  text-decoration: none;
}

.button:hover { color: var(--black); filter: brightness(1.1); }

.section {
  max-width: 72rem;
  margin: 0 auto;
  padding: 2rem 1.25rem;
}

.legal { max-width: 48rem; }

.muted { color: var(--muted); }

.draft {
  padding: 0.75rem 1rem;
  border-left: 4px solid var(--gold);
  background: rgb(232 185 35 / 0.08);
}

.site-footer {
  border-top: 1px solid var(--gold-dark);
  padding: 1.5rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  max-width: 72rem;
  width: 100%;
  margin: 0 auto;
  color: var(--muted);
}

.site-footer p { margin: 0; }

@media (max-width: 40rem) {
  .nav { flex-direction: column; }
  .site-footer { flex-direction: column; align-items: center; }
}

.nav-brand sup { font-size: 0.55em; }

.form-page { max-width: 26rem; }

.form { display: flex; flex-direction: column; gap: 1rem; }

.form label { display: flex; flex-direction: column; gap: 0.25rem; }

.form input {
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
  background: var(--black);
  color: var(--text);
  font: inherit;
}

.form input:focus { outline: 2px solid var(--gold); }

.error {
  padding: 0.75rem 1rem;
  border-left: 4px solid #d9534f;
  background: rgb(217 83 79 / 0.12);
}

.button-small { padding: 0.4rem 0.9rem; border: 0; cursor: pointer; font-size: 0.8rem; }

.nav form { display: flex; align-items: center; gap: 0.75rem; }

.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }

.table th, .table td { padding: 0.5rem; border-bottom: 1px solid var(--brown); text-align: left; }

.table th { color: var(--gold); }

.section-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }

.thumb { width: 4rem; height: auto; border-radius: 0.25rem; }

.actions { display: flex; gap: 1rem; align-items: center; }

.link-button {
  padding: 0;
  border: 0;
  background: none;
  color: var(--gold);
  font: inherit;
  text-decoration: underline;
  cursor: pointer;
}

.form textarea {
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
  background: var(--black);
  color: var(--text);
  font: inherit;
}

.carousel { display: flex; align-items: center; gap: 0.5rem; }

.carousel-track {
  flex: 1;
  display: flex;
  gap: 1.5rem;
  margin: 0;
  padding: 0.5rem 0 1rem;
  list-style: none;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-dark) transparent;
}

.carousel-item {
  flex: 0 0 auto;
  width: min-content;  /* as wide as its tile; the name and bio wrap to it */
  scroll-snap-align: center;
  text-align: center;
}

.carousel-nav {
  flex: none;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid var(--gold-dark);
  border-radius: 50%;
  background: var(--black);
  color: var(--gold);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

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

/* A tile keeps one height and takes the shape of what it shows: the image's on the front, the video's when flipped.
   characters.js sets --front-ratio and --back-ratio (width / height) once each file's size is known. */
.tile {
  --tile-height: min(24rem, 60vh);
  --ratio: var(--front-ratio, 0.75);
  display: block;
  height: var(--tile-height);
  width: min(calc(var(--tile-height) * var(--ratio)), 90vw);
  transition: width 0.6s;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  perspective: 60rem;
}

.tile-inner {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  transition: transform 0.6s;
  transform-style: preserve-3d;
}

.tile[aria-pressed="true"] { --ratio: var(--back-ratio, 1.7778); }

.tile[aria-pressed="true"] .tile-inner { transform: rotateY(180deg); }

.tile-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border: 2px solid var(--gold-dark);
  border-radius: 0.5rem;
  background: var(--black);
  backface-visibility: hidden;
}

.tile:hover .tile-face, .tile:focus-visible .tile-face { border-color: var(--gold); }

.tile-back { transform: rotateY(180deg); }

.tile-face img, .tile-face video { width: 100%; height: 100%; object-fit: contain; }

.tile-name { margin: 0.75rem 0 0.25rem; font-size: 1.2rem; }

.tile-bio { margin: 0; color: var(--muted); font-size: 0.95rem; }

@media (prefers-reduced-motion: reduce) {
  .tile, .tile-inner { transition: none; }
}

.coming-soon { display: flex; flex-direction: column; align-items: center; justify-content: center; }

.inline-form { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; margin: 1rem 0; }

.inline-form label { display: flex; align-items: center; gap: 0.5rem; }

.inline-form input[type="number"] {
  width: 7rem;
  padding: 0.4rem 0.5rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
  background: var(--black);
  color: var(--text);
  font: inherit;
}

.table .inline-form { margin: 0; }

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.product-card {
  padding: 1rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.5rem;
  background: rgb(11 9 6 / 0.6);
  text-align: center;
}

.product-card img { width: 100%; height: auto; border-radius: 0.25rem; background: var(--text); }

.product-card h2 { margin: 0.75rem 0 0.25rem; font-size: 1.1rem; }

.price { margin: 0; color: var(--gold-light); font-weight: 700; }

.product-card a { color: inherit; text-decoration: none; }

.product-card a:hover h2 { color: var(--gold-light); }

.product {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}

.product-main-image { width: 100%; height: auto; border-radius: 0.5rem; background: var(--text); }

.product-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.75rem 0 0;
  padding: 0;
  list-style: none;
}

.product-thumbs button {
  padding: 0;
  border: 2px solid var(--gold-dark);
  border-radius: 0.25rem;
  background: var(--text);
  cursor: pointer;
}

.product-thumbs button:hover, .product-thumbs button:focus-visible { border-color: var(--gold); }

.product-thumbs img { display: block; width: 4rem; height: 4rem; object-fit: contain; }

.product-info h1 { margin-top: 0; }

.product-price { font-size: 1.4rem; }

.variant-picker fieldset { margin: 1rem 0; padding: 0; border: 0; }

.variant-picker legend { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; color: var(--gold); }

.swatch { width: 1rem; height: 1rem; border: 1px solid var(--muted); border-radius: 50%; }

.sizes { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.size-option input { position: absolute; opacity: 0; }

.size-option span {
  display: inline-block;
  min-width: 3rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
  text-align: center;
  cursor: pointer;
}

.size-option input:checked + span { border-color: var(--gold); background: var(--gold); color: var(--black); }

.size-option input:focus-visible + span { outline: 2px solid var(--gold-light); }

.product-description { white-space: pre-line; color: var(--text); }

.size-guide { margin-top: 1.5rem; }

.size-guide summary { color: var(--gold); cursor: pointer; }

.size-guide-image { max-width: 12rem; height: auto; background: var(--text); border-radius: 0.25rem; }

.table-scroll { overflow-x: auto; }

@media (max-width: 48rem) {
  .product { grid-template-columns: 1fr; }
}

.error-text { color: #e8837f; }

.add-to-cart { display: flex; align-items: center; gap: 1rem; margin-top: 1rem; }

.add-to-cart input {
  width: 4.5rem;
  padding: 0.5rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
  background: var(--black);
  color: var(--text);
  font: inherit;
}

.cart .inline-form { margin: 0 0 0.25rem; }

.cart-subtotal { margin: 1.5rem 0 1rem; }

.form select {
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
  background: var(--black);
  color: var(--text);
  font: inherit;
}

.rate-option {
  display: flex !important;
  flex-direction: row !important;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--gold-dark);
  border-radius: 0.25rem;
}

.rate-option span { flex: 1; }

#checkout { max-width: 40rem; margin: 0 auto; }

.cart-actions { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }

.shipping-group { margin: 0; padding: 1rem; border: 1px solid var(--gold-dark); border-radius: 0.25rem; }

.shipping-group legend { padding: 0 0.5rem; color: var(--gold); }

.store-card { margin: 0 0 1.5rem; padding: 1rem 1.25rem; border: 1px solid var(--gold-dark); border-radius: 0.5rem; }

.store-card-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; }

.store-card-head h2 { margin: 0; }

.product-description-html { white-space: normal; }

.product-description-html table { width: 100%; margin: 1rem 0; border-collapse: collapse; font-size: 0.9rem; }

.product-description-html td, .product-description-html th { padding: 0.4rem; border-bottom: 1px solid var(--brown); text-align: left; }

.colour-choice {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.2rem 0.6rem;
  border: 1px solid transparent;
  border-radius: 0.25rem;
  background: none;
  color: var(--gold);
  font: inherit;
  cursor: pointer;
}

.colour-choice:hover, .colour-choice[aria-pressed="true"] { border-color: var(--gold); }

.upload-form { display: flex; flex-direction: column; align-items: flex-start; gap: 0.75rem; margin: 1rem 0; }

.drop-zone {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 9rem;
  padding: 1.5rem;
  border: 2px dashed var(--gold-dark);
  border-radius: 0.5rem;
  text-align: center;
  cursor: pointer;
}

.drop-zone:hover, .drop-zone-active { border-color: var(--gold); background: rgb(232 185 35 / 0.08); }

.drop-zone input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

.bulk-actions { display: flex; gap: 0.75rem; margin: 0.75rem 0; }

.flash { margin: 1rem auto 0; max-width: 72rem; padding: 0.75rem 1rem; border-left: 4px solid var(--gold); background: rgb(232 185 35 / 0.1); }

.flash-error { border-left-color: #d9534f; background: rgb(217 83 79 / 0.12); }

.confirm-note { margin-left: 0.5rem; }

.field-error { display: block; font-size: 0.85rem; }

/* While a tile is flipped, room at both ends lets even the first and last tile slide to the centre. */
.carousel-track.has-flipped { padding-inline: 50%; }
.refund-policy { margin-top: 1rem; }
.refund-policy summary { cursor: pointer; }
.order-item + .order-item { margin-top: 0.5rem; }

/* Ojuju (SIL Open Font License, static/fonts/OFL.txt): African display face for the Orishas page. Self-hosted. */
@font-face {
  font-family: "Ojuju";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/static/fonts/ojuju-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Ojuju";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/static/fonts/ojuju-vietnamese.woff2") format("woff2");
  unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB;
}
@font-face {
  font-family: "Ojuju";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/static/fonts/ojuju-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

.orishas h1, .orisha-name { font-family: var(--african); font-weight: 700; letter-spacing: 0.02em; }
.orishas-intro { max-width: 48rem; color: var(--muted); }
.orisha-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 20rem), 1fr)); gap: 1.25rem; margin-top: 1.5rem; }
.orisha { padding: 1.25rem; border: 1px solid var(--gold-dark); border-radius: 8px; background: rgb(11 9 6 / 0.55); }
.orisha:first-child { grid-column: 1 / -1; border-color: var(--gold); }
.orisha-name { margin: 0; color: var(--gold); font-size: 1.6rem; }
.orisha-yoruba { margin: 0.1rem 0 0; font-family: var(--african); color: var(--gold-light); }
.orisha-domain { margin: 0.4rem 0 0.6rem; font-style: italic; color: var(--muted); }
.orisha-text { margin: 0; }
.orisha-image { display: block; width: 100%; max-width: 20rem; height: auto; margin: 0 auto 1rem; }

/* Under the Meet The Squad carousel, in the same African face as the Orishas page. */
.tile-hint { margin: 1.5rem 0 0; text-align: center; font-family: var(--african); font-weight: 700; font-size: 1.5rem; letter-spacing: 0.02em; color: var(--gold-light); }

/* The pages open to everyone before launch, linked from the coming-soon page. */
.coming-soon-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 1rem; margin: 1.5rem 0; }

/* Live search above the merch grid. */
.merch-search { display: flex; gap: 0.5rem; max-width: 32rem; margin: 0 auto 1.5rem; }
.merch-search input { flex: 1; }
.product-card[hidden], .merch-no-match[hidden] { display: none; }
.merch-no-match { text-align: center; }

/* Admin return detail: the customer's photo keeps its shape. */
.return-photo { max-width: 20rem; height: auto; }
.return-actions { display: grid; gap: 1rem; max-width: 32rem; margin-top: 1.5rem; }

/* Hit Us Up: set in the African face like the Orishas page. */
.contact-page label, .contact-page .button { font-family: var(--african); letter-spacing: 0.02em; }
.contact-intro { font-family: var(--african); font-size: 1.4rem; letter-spacing: 0.02em; color: var(--gold-light); }
.contact-page .captcha, .form .captcha { display: block; max-width: 100%; height: auto; border-radius: 4px; }
.contact-sent { padding: 0.75rem 1rem; border-left: 4px solid var(--gold); background: rgb(232 185 35 / 0.1); }
.message-body { white-space: pre-line; }
blockquote.message-body { margin: 1rem 0; padding: 0.75rem 1rem; border-left: 4px solid var(--gold-dark); }
.message-reply { margin: 1rem 0; padding-left: 1rem; border-left: 4px solid var(--gold); }
tr.unread td { font-weight: 600; }
.about-page { font-family: var(--african); letter-spacing: 0.02em; }
.about-page h2 { color: var(--gold-light); }
.about-body { white-space: pre-line; font-size: 1.35rem; line-height: 1.6; }

/* An Orisha card with a video: the image flips to play it, keeping the media's own shape. */
.orisha-tile { display: block; width: 100%; max-width: 20rem; margin: 0 auto 1rem; padding: 0; border: 0;
  background: none; cursor: pointer; perspective: 1000px; }
.orisha-tile-inner { display: grid; transition: transform 0.6s; transform-style: preserve-3d; }
.orisha-tile-inner > * { grid-area: 1 / 1; backface-visibility: hidden; }
.orisha-tile .orisha-image { margin: 0; }
.orisha-tile[aria-pressed="true"] .orisha-tile-inner { transform: rotateY(180deg); }
.orisha-tile-back { transform: rotateY(180deg); width: 100%; height: 100%; object-fit: contain; }
@media (prefers-reduced-motion: reduce) { .orisha-tile-inner { transition: none; } }
