/* Headings + buttons use "Boring Time". Everything else — nav, body copy,
   product name/price — stays Montserrat. Browsers fall back to the next
   font in a stack for any character a font is missing, so no extra
   handling is needed for glyphs Boring Time lacks (e.g. digits). */
@font-face {
  font-family: "Boring Time";
  src: url("assets/fonts/BoringTime.otf") format("opentype");
  font-display: swap;
}

@import url("https://fonts.googleapis.com/css?family=Montserrat:400,500,700");

:root {
  --bg: #ffffff;
  --text: #1a1b1f;
  --text-gray: #9a9a9a;
  --border: #e5e5e5;
  --button-bg: #000000;
  --button-text: #ffffff;
  --font-heading: "Boring Time", Impact, sans-serif;
  --font-body: "Montserrat", Arial, Helvetica, sans-serif;
}

html {
  margin: 0;
  padding: 0;
}

/* Column layout so the footer sits at the bottom of the viewport on short
   pages instead of needing a scroll to reach. */
body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
}

/* Shared header — logo centered, nav links flanking it. Identical on
   every page. The two .site-nav blocks are equal-width so the logo stays
   optically centered even though one side has more links than the other. */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 28px;
  padding: 16px 24px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  box-sizing: border-box;
}

.site-logo {
  display: block;
  flex: 0 0 auto;
}

.site-logo img {
  display: block;
  height: 54px;
  width: auto;
}

.site-nav {
  flex: 1 1 0;
  display: flex;
  gap: 26px;
}

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

.site-nav.nav-right {
  justify-content: flex-start;
}

.site-nav a {
  font-family: var(--font-heading);
  font-size: 20px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
  white-space: nowrap;
}

.site-nav a:hover,
.site-nav a.active {
  border-bottom-color: var(--text);
}

@media (max-width: 640px) {
  .site-header {
    flex-wrap: wrap;
    gap: 12px;
  }
  .site-logo {
    order: -1;
    flex-basis: 100%;
    display: flex;
    justify-content: center;
  }
  .site-logo img {
    height: 40px;
  }
  .site-nav {
    flex: 0 0 auto;
  }
  .site-nav.nav-left,
  .site-nav.nav-right {
    justify-content: center;
  }
}

/* Generic content-page wrapper (Shop, and anything added later). */
.page {
  flex: 1 0 auto;
  box-sizing: border-box;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 150px 20px 60px;
  text-align: center;
}

.page-title {
  margin: 0 0 32px;
  font-family: var(--font-heading);
  font-size: 34px;
  letter-spacing: 1px;
  font-weight: 400;
}

.page-intro {
  max-width: 560px;
  margin: 0 auto 40px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-gray);
}

/* Small footer links, same on every page. */
.site-footer {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 22px;
  padding: 26px 20px 30px;
  border-top: 1px solid var(--border);
}

.site-footer a {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-gray);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--text);
}

/* Home page — Lotus only. */
.stage {
  position: relative;
  flex: 1 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 130px 20px 40px;
  box-sizing: border-box;
}

.lotus-sprite {
  max-width: min(96vw, 1260px);
  height: auto;
  user-select: none;
  -webkit-user-drag: none;
}

/* Email signup popup */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(26, 27, 31, 0.5);
}

.modal-box {
  position: relative;
  width: 90%;
  max-width: 340px;
  padding: 34px 26px 26px;
  background: var(--bg);
  border: 1px solid var(--text);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  text-align: center;
  box-sizing: border-box;
}

.modal-close {
  position: absolute;
  top: 8px;
  right: 12px;
  background: none;
  border: none;
  font-size: 20px;
  line-height: 1;
  color: var(--text-gray);
  cursor: pointer;
  font-family: inherit;
}

.modal-heading {
  margin: 0 0 18px;
  font-family: var(--font-heading);
  font-size: 22px;
}

.signup {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.signup input[type="email"] {
  padding: 10px 14px;
  border: 1px solid var(--text);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  min-width: 180px;
}

.signup input[type="email"]::placeholder {
  color: var(--text-gray);
}

.signup button {
  padding: 10px 18px;
  border: 1px solid var(--button-bg);
  background: var(--button-bg);
  color: var(--button-text);
  font-family: var(--font-heading);
  font-size: 15px;
  letter-spacing: 0.5px;
  cursor: pointer;
}

.signup button:hover {
  background: #2b2b2b;
}

.signup-message {
  min-height: 18px;
  margin-top: 12px;
  font-size: 13px;
  color: var(--text-gray);
}

@media (max-width: 480px) {
  .signup {
    flex-direction: column;
    align-items: center;
  }
  .signup input[type="email"] {
    width: 100%;
  }
}

/* Shop sort control */
.shop-tools {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin: -12px 0 28px;
}

.shop-tools label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-gray);
}

.shop-tools select {
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 13px;
  cursor: pointer;
}

.shop-tools select:focus {
  outline: none;
  border-color: var(--text);
}

/* Shop */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  column-gap: 26px;
  row-gap: 56px;
}

.product-grid .empty-note {
  grid-column: 1 / -1;
  color: var(--text-gray);
  font-size: 14px;
}

/* position + z-index are what stop a scaled-up item from being painted
   over by the item after it in the grid — without these, growing on hover
   looks like the garment is being clipped by its neighbour. */
.product-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.product-card:hover {
  z-index: 10;
}

/* clears the scaled-up image so it never sits on top of the name */
.product-card .product-name {
  margin-top: 28px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.product-card .product-price {
  margin-top: 4px;
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--text-gray);
}

.product-card .buy-btn {
  margin-top: 12px;
  padding: 10px 26px;
  border: 1px solid var(--button-bg);
  background: var(--button-bg);
  color: var(--button-text);
  font-family: var(--font-heading);
  font-size: 15px;
  letter-spacing: 0.5px;
  text-decoration: none;
  cursor: pointer;
}

.product-card .buy-btn:hover {
  background: #2b2b2b;
}

.product-card .buy-btn.disabled {
  background: var(--bg);
  color: var(--text-gray);
  border-color: var(--border);
  cursor: default;
  pointer-events: none;
}

.product-viewer {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: visible;
  border: none;
  background: none;
}

/* contain, not cover — cut-out garments must never be cropped at the edges */
.product-viewer img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.viewer-prev,
.viewer-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid var(--text);
  background: rgba(255, 255, 255, 0.85);
  color: var(--text);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  font-family: inherit;
}

.viewer-prev {
  left: 8px;
}

.viewer-next {
  right: 8px;
}

.viewer-prev:hover,
.viewer-next:hover {
  background: rgba(255, 255, 255, 1);
}

.viewer-dots {
  position: absolute;
  bottom: 8px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 6px;
}

.viewer-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--text);
}

.viewer-dot.active {
  background: var(--text);
}

/* Shuffle button — icon only, right-aligned, quiet until hovered */
.archive-tools {
  display: flex;
  justify-content: flex-end;
  margin: -22px 0 26px;
}

#shuffle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid var(--text);
  border-radius: 50%;
  background: none;
  color: var(--text);
  cursor: pointer;
  transition: color 180ms ease, background 180ms ease;
}

#shuffle-btn:hover {
  background: var(--text);
  color: var(--bg);
}

.shuffle-icon {
  width: 21px;
  height: 21px;
  stroke-width: 2.4;
}

#shuffle-btn.spinning .shuffle-icon {
  animation: spin 560ms cubic-bezier(0.45, 0, 0.2, 1);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Spotlight — sits over the gallery, always in view, never needs a scroll.
   The backdrop is only lightly tinted so the blurred grid still reads
   behind it. */
.spotlight {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 24px;
  box-sizing: border-box;
  background: rgba(255, 255, 255, 0.4);
  opacity: 0;
  transition: opacity 300ms ease;
  cursor: zoom-out;
}

.spotlight.open {
  opacity: 1;
}

/* The travelling element. transform-origin centre keeps the scale
   symmetrical as it flies between the grid and the middle of the screen. */
.spotlight-frame {
  width: min(500px, 84vw, 68vh);
  height: min(500px, 84vw, 68vh);
  transform-origin: center center;
  transition: transform 440ms cubic-bezier(0.22, 0.9, 0.24, 1),
    opacity 300ms ease;
  will-change: transform;
}

.spotlight-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 24px 30px rgba(0, 0, 0, 0.28));
}

.spotlight-caption {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 260ms ease 160ms, transform 260ms ease 160ms;
}

.spotlight.open .spotlight-caption {
  opacity: 1;
  transform: translateY(0);
}

/* The gallery itself blurs and eases back while a piece is featured. */
main.page {
  transition: filter 340ms ease, transform 340ms ease;
}

main.page.blurred {
  filter: blur(3px);
  transform: scale(0.995);
}

.archive-item .product-viewer {
  cursor: zoom-in;
}

@media (prefers-reduced-motion: reduce) {
  .spotlight-frame,
  main.page {
    transition: opacity 200ms ease;
  }
}

/* Archive — same card rhythm as the shop, minus price and buy button.
   Tight column gap + images that render larger than their cell lets the
   garments spill into the gutters and lightly overlap, while the roomy
   row gap keeps the whole silhouette readable. */
.archive-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  column-gap: 8px;
  row-gap: 40px;
}

.archive-grid .empty-note {
  grid-column: 1 / -1;
  color: var(--text-gray);
  font-size: 14px;
}

.archive-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.archive-item:hover {
  z-index: 10;
}

/* Archive photos are pre-squared, so the frame is 1:1 here (the shop's
   frame stays 3:4). Without this the square images would get cropped on
   the left and right edges.

   The frame is also transparent and borderless because the archive images
   are cut-out WebP with alpha — whatever you put behind them
   (page colour, texture, image) shows through the garment's silhouette. */
.archive-item .product-viewer {
  aspect-ratio: 1 / 1;
  background: none;
  border: none;
  overflow: visible;
}

/* The float. drop-shadow (not box-shadow) traces the garment's alpha
   silhouette rather than the square frame, so the shadow follows the
   actual shape of the clothing. */
/* Rendered ~18% larger than the cell so garments break out of their box
   and overlap slightly. object-fit:contain guarantees the full silhouette
   is always visible — the scale only ever adds size, never crops. */
.archive-item .product-viewer img {
  object-fit: contain;
  filter: drop-shadow(0 14px 16px rgba(0, 0, 0, 0.22));
  animation: bob 6s ease-in-out infinite;
  transition: transform 260ms ease, filter 260ms ease;
  will-change: transform;
}

/* --rest-scale lets the archive and the shop share one animation while
   sitting at different sizes. It resolves per element, so each grid can
   set its own without duplicating the keyframes. */
@keyframes bob {
  0%,
  100% {
    transform: scale(var(--rest-scale, 1)) translateY(0);
  }
  50% {
    transform: scale(var(--rest-scale, 1)) translateY(-9px);
  }
}

.archive-item .product-viewer img {
  --rest-scale: 1.18;
}

.product-card .product-viewer img {
  --rest-scale: 1.1;
}

/* Staggered start times so the grid drifts organically instead of every
   piece bobbing in lockstep. */
.archive-item:nth-child(4n + 2) .product-viewer img { animation-delay: -1.4s; }
.archive-item:nth-child(4n + 3) .product-viewer img { animation-delay: -2.9s; }
.archive-item:nth-child(4n + 4) .product-viewer img { animation-delay: -4.3s; }

.archive-item:hover .product-viewer img {
  animation-play-state: paused;
  transform: scale(1.32) translateY(-6px);
  filter: drop-shadow(0 22px 26px rgba(0, 0, 0, 0.3));
}

/* Shop images float too. Only the image bobs — the name, price and buy
   button stay put, so the button never moves under the cursor. */
.product-card .product-viewer {
  border: none;
  background: none;
  overflow: visible;
}

.product-card .product-viewer img {
  animation: bob 6s ease-in-out infinite;
  transition: transform 260ms ease, filter 260ms ease;
  filter: drop-shadow(0 14px 16px rgba(0, 0, 0, 0.18));
  will-change: transform;
}

.product-card:nth-child(4n + 2) .product-viewer img { animation-delay: -1.4s; }
.product-card:nth-child(4n + 3) .product-viewer img { animation-delay: -2.9s; }
.product-card:nth-child(4n + 4) .product-viewer img { animation-delay: -4.3s; }

.product-card:hover .product-viewer img {
  animation-play-state: paused;
  transform: scale(1.28) translateY(-6px);
  filter: drop-shadow(0 22px 26px rgba(0, 0, 0, 0.26));
}

/* Respect the OS "reduce motion" setting — the float stops, hover still
   works. */
@media (prefers-reduced-motion: reduce) {
  .archive-item .product-viewer img,
  .product-card .product-viewer img {
    animation: none;
  }
}


/* Q&A + shipping blocks */
.info-section {
  max-width: 620px;
  margin: 0 auto 48px;
  text-align: left;
}

.section-heading {
  margin: 0 0 20px;
  font-family: var(--font-heading);
  font-size: 24px;
  letter-spacing: 1px;
  font-weight: 400;
  text-align: center;
}

.qa-item {
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}

.qa-item:first-of-type {
  border-top: 1px solid var(--border);
}

.qa-question {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.qa-answer {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-gray);
}

.qa-answer a {
  color: var(--text);
}

/* Shared form styling — contact + custom airbrush request. */
.site-form {
  max-width: 520px;
  margin: 0 auto;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.site-form label {
  display: block;
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.site-form input,
.site-form select,
.site-form textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--border);
  border-radius: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  box-sizing: border-box;
  resize: vertical;
}

.site-form input:focus,
.site-form select:focus,
.site-form textarea:focus {
  outline: none;
  border-color: var(--text);
}

.site-form .field-hint {
  margin: 6px 0 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-gray);
}

.site-form button {
  align-self: flex-start;
  padding: 12px 30px;
  border: 1px solid var(--button-bg);
  background: var(--button-bg);
  color: var(--button-text);
  font-family: var(--font-heading);
  font-size: 17px;
  letter-spacing: 0.5px;
  cursor: pointer;
}

.site-form button:hover {
  background: #2b2b2b;
}

.form-status {
  min-height: 18px;
  font-size: 13px;
  color: var(--text-gray);
}

.hidden {
  display: none !important;
}
