:root {
  color-scheme: dark;
  --bg: #090909;
  --surface: #131313;
  --line: #343434;
  --ink: #f2f0eb;
  --muted: #b1b1aa;
  --accent: #deded4;
  --coral: #e89999;
  --focus: #f2f0eb;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a {
  color: var(--accent);
  text-underline-offset: 4px;
}
a:hover {
  color: #fff;
}
button,
input,
select,
textarea {
  font: inherit;
}
button,
.button {
  display: inline-block;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--ink);
  border-radius: 3px;
  background: var(--ink);
  color: var(--bg);
  cursor: pointer;
  text-decoration: none;
}
button:hover,
.button:hover {
  background: #d8d6d0;
  border-color: #d8d6d0;
  color: var(--bg);
}
button:disabled {
  opacity: 0.5;
  cursor: default;
}
input,
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 10px;
  border: 1px solid #777;
  border-radius: 3px;
  background: #101010;
  color: #fff;
}
input[type="checkbox"] {
  width: 22px;
  min-height: 22px;
}
textarea {
  min-height: 100px;
}
label {
  display: block;
  margin: 12px 0;
  color: #ddd;
}
label input,
label select,
label textarea {
  display: block;
  margin-top: 5px;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 4px;
}
h1 {
  font-size: clamp(1.75rem, 3.5vw, 2.6rem);
  line-height: 1.2;
  font-weight: 500;
  letter-spacing: -0.025em;
}
h2 {
  font-size: 1.3rem;
}
h3 {
  font-size: 1.1rem;
}
p {
  max-width: 75ch;
}
header {
  position: relative;
  border-bottom: 1px solid var(--line);
  padding: 18px max(20px, calc((100% - 1120px) / 2));
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
header .brand {
  font-size: 1.15rem;
  color: var(--ink);
  font-weight: 500;
  letter-spacing: -0.02em;
  text-decoration: none;
}
.brand-name {
  color: inherit;
}
header .brand .muted {
  color: var(--muted);
  font-size: 1rem;
  font-weight: 400;
  margin-left: 8px;
}
header nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
}
header nav a:hover {
  color: var(--ink);
  text-decoration: underline;
}

nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}
main {
  max-width: 1160px;
  padding: 30px 20px 60px;
  margin: auto;
  min-height: 65vh;
}
footer {
  border-top: 1px solid var(--line);
  padding: 28px max(20px, calc((100% - 1120px) / 2));
  color: var(--muted);
}
footer nav {
  margin-bottom: 20px;
}
.notice {
  background: var(--surface);
  border-left: 2px solid #777;
  padding: 10px 14px;
  margin: 12px 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.muted {
  color: var(--muted);
}
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.75rem;
  color: var(--accent);
}
.intro {
  margin: 40px 0 32px;
  max-width: 720px;
}
.intro h1 {
  margin: 0 0 12px;
}
.intro p {
  margin: 8px 0;
}
.intro a {
  font-size: 0.9rem;
}

.toolbar {
  display: flex;
  gap: 12px;
  align-items: end;
  flex-wrap: wrap;
  margin-bottom: 24px;
}
.toolbar label {
  margin: 0;
  flex: 1;
  min-width: 150px;
}
.toolbar button {
  margin-bottom: 0;
}
.toolbar input,
.toolbar select,
.toolbar button {
  height: 48px;
  min-height: 48px;
}
.toolbar button {
  padding-block: 0;
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 36px 24px;
}
.card {
  background: transparent;
  min-width: 0;
  display: flex;
}
.card .card-link {
  display: flex;
  flex-direction: column;
  width: 100%;
  text-decoration: none;
}
.card .info {
  padding: 14px 0 0;
}

.card h2 {
  margin: 4px 0 8px;
  font-size: 1.15rem;
  font-weight: 500;
}
.card a {
  color: inherit;
}
.card-link:hover h2 {
  color: var(--accent);
  text-decoration: underline;
}
.photo {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: contain;
  background: #101010;
  display: block;
}
.placeholder {
  display: grid;
  place-content: center;
  text-align: center;
  padding: 24px;
  color: #aaa;
  border-bottom: 1px solid #333;
}
.badge {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: var(--muted);
  margin: 0 10px 6px 0;
}
.price {
  font-size: 1.25rem;
  font-weight: 600;
}
.stock {
  color: var(--muted);
  font-size: 0.9rem;
}
.sold {
  color: #d9bfa0;
}
.stock-status {
  display: inline-flex;
  align-items: baseline;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.stock-status strong {
  color: #ff6b6b;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
}
.cutting-type {
  padding: 0.65rem 0.85rem;
  border-left: 3px solid var(--ink);
  background: #151515;
  font-size: 1.08rem;
}
.listing-legal-notice {
  border-top: 1px solid var(--line);
  padding-top: 1rem;
  margin-top: 1.5rem;
}
.detail {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: start;
}
.detail .photo {
  aspect-ratio: auto;
  max-height: 680px;
  background: transparent;
}
.panel {
  padding: 24px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 3px;
  margin-bottom: 20px;
}
.split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 16px;
}
.full {
  grid-column: 1/-1;
}
.gallery-thumbs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 12px;
}
.gallery-thumbs img {
  width: 60px;
  height: 70px;
  object-fit: contain;
}
.gallery-thumbs button {
  padding: 4px;
  background: transparent;
  border: 0;
  color: var(--ink);
}
.gallery-thumbs img {
  display: block;
  border: 1px solid #777;
  border-radius: 4px;
  padding: 4px;
}
.gallery-thumbs .photo-trigger span {
  display: block;
  margin-top: 4px;
}
.totals {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}
.totals dd {
  margin: 0;
  text-align: right;
}
.cart-checkout {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
  padding-top: 12px;
}
.option-prices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.6rem;
}
[data-cutting-select] {
  width: 100%;
}
.cutting-editor {
  min-width: 0;
  border: 1px solid var(--line);
  padding: 1rem;
}
.cutting-editor h2 {
  margin-top: 0;
}
.cart-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 90px minmax(150px, auto) auto;
  gap: 24px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.cart-title {
  font-weight: 600;
}
.cart-quantity {
  margin: 0;
  font-size: 0.85rem;
}
.cart-quantity input {
  height: 48px;
  font-size: 1rem;
}
.cart-price {
  white-space: nowrap;
}
.actions.order-access-actions {
  align-items: center;
  gap: 12px;
}
.order-access-actions button,
.order-access-actions .button {
  background: var(--surface);
  color: var(--ink);
  border-color: #777;
}
.order-access-actions button:hover,
.order-access-actions .button:hover {
  background: #252525;
  border-color: var(--ink);
}
.error {
  padding: 16px;
  border: 1px solid var(--coral);
  border-radius: 3px;
  background: #2a1414;
  color: #ffcdcd;
  white-space: pre-wrap;
}
.success {
  color: #a0e2b3;
}
.actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0;
}
.actions.payment-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  max-width: 460px;
  align-items: stretch;
}
.payment-actions .button-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 10px;
  font-size: 0.9rem;
  text-align: center;
  white-space: normal;
}
.admin-nav {
  margin-bottom: 25px;
  padding: 12px 0;
  border-bottom: 1px solid #333;
}
.admin-row {
  display: flex;
  gap: 16px;
  justify-content: space-between;
  flex-wrap: wrap;
  padding: 14px 0;
  border-bottom: 1px solid #333;
}
table {
  width: 100%;
  border-collapse: collapse;
}
th,
td {
  text-align: left;
  padding: 10px;
  border-bottom: 1px solid #333;
  overflow-wrap: anywhere;
}
.scroll {
  overflow-x: auto;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
input,
textarea,
select {
  min-width: 0;
}
h1,
h2,
h3,
p,
dd,
.info {
  overflow-wrap: anywhere;
}
.skip {
  position: absolute;
  left: 20px;
  top: -100px;
}
.skip:focus {
  top: 10px;
  z-index: 10;
  background: #000;
  padding: 15px;
}
.checkbox {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.checkbox input {
  flex-shrink: 0;
}
.small {
  font-size: 0.85rem;
}
.empty {
  text-align: center;
  padding: 65px 20px;
  border: 1px dashed #444;
  border-radius: 10px;
}
.photo-tools {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.photo-admin {
  border: 1px solid #444;
  border-radius: 3px;
  padding: 12px;
  margin: 12px 0;
}
.photo-admin img {
  max-width: 180px;
  max-height: 200px;
}
.hidden,
[hidden] {
  display: none !important;
}
dialog {
  max-width: 95vw;
  max-height: 95vh;
  border: 1px solid #777;
  background: #141414;
  color: white;
}
dialog img {
  max-width: 85vw;
  max-height: 75vh;
  object-fit: contain;
}
dialog::backdrop {
  background: #000c;
}
@media (max-width: 1000px) {
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 760px) {
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 14px;
  }
  .detail,
  .split {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  header {
    gap: 12px;
  }
  main {
    padding-top: 22px;
  }
  .panel {
    padding: 18px;
  }
  .cart-line {
    grid-template-columns: 90px minmax(0, 1fr);
    gap: 14px 20px;
  }
  .cart-title {
    grid-column: 1 / -1;
  }
  .cart-price {
    white-space: normal;
  }
  .cart-line button {
    grid-column: 1 / -1;
    justify-self: start;
  }
  .order-access-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .order-access-actions .button {
    text-align: center;
  }
  .fields {
    grid-template-columns: 1fr;
  }
  .toolbar {
    align-items: end;
  }
}
@media (max-width: 560px) {
  .grid {
    grid-template-columns: 1fr;
  }
  header nav {
    gap: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}
@media print {
  header,
  footer,
  nav,
  .actions {
    display: none;
  }
  body {
    background: white;
    color: black;
  }
  .panel {
    border: 0;
  }
  a {
    color: black;
  }
}

footer nav a {
  color: var(--muted);
  font-size: 0.85rem;
}
.card .small {
  margin: 8px 0;
}
.card .price {
  font-size: 1.05rem;
  font-weight: 500;
}
@media (max-width: 560px) {
  .intro {
    margin: 28px 0;
  }
  header {
    padding-block: 16px;
  }
  main {
    padding-inline: 18px;
  }
}

/* Same per-letter breathing rainbow as the original homepage. */
.brand-name {
  white-space: nowrap;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.025em;
}
.brand-name .rainbow-letter {
  display: inline-block;
  animation: rainbow-breathing 3s ease-in-out infinite;
  text-shadow: 0 0 2px currentColor !important;
}
.brand-name .rainbow-letter:nth-child(1) {
  animation-delay: 0s;
}
.brand-name .rainbow-letter:nth-child(2) {
  animation-delay: -0.214s;
}
.brand-name .rainbow-letter:nth-child(3) {
  animation-delay: -0.429s;
}
.brand-name .rainbow-letter:nth-child(4) {
  animation-delay: -0.643s;
}
.brand-name .rainbow-letter:nth-child(5) {
  animation-delay: -0.857s;
}
.brand-name .rainbow-letter:nth-child(6) {
  animation-delay: -1.071s;
}
.brand-name .rainbow-letter:nth-child(7) {
  animation-delay: -1.286s;
}
.brand-name .rainbow-letter:nth-child(8) {
  animation-delay: -1.5s;
}
.brand-name .rainbow-letter:nth-child(9) {
  animation-delay: -1.714s;
}
.brand-name .rainbow-letter:nth-child(10) {
  animation-delay: -1.929s;
}
.brand-name .rainbow-letter:nth-child(11) {
  animation-delay: -2.143s;
}
.brand-name .rainbow-letter:nth-child(12) {
  animation-delay: -2.357s;
}
.brand-name .rainbow-letter:nth-child(13) {
  animation-delay: -2.571s;
}
@keyframes rainbow-breathing {
  0%,
  100% {
    color: #ff0000;
    transform: scale(1);
    text-shadow: 0 0 5px currentColor;
  }
  14.28% {
    color: #ff4500;
    transform: scale(1.1);
    text-shadow: 0 0 10px currentColor;
  }
  28.57% {
    color: #ff7700;
    transform: scale(1.05);
    text-shadow: 0 0 8px currentColor;
  }
  42.85% {
    color: #feda75;
    transform: scale(1.15);
    text-shadow: 0 0 12px currentColor;
  }
  57.14% {
    color: #1db954;
    transform: scale(1.08);
    text-shadow: 0 0 9px currentColor;
  }
  71.42% {
    color: #4267b2;
    transform: scale(1.12);
    text-shadow: 0 0 11px currentColor;
  }
  85.71% {
    color: #6441a5;
    transform: scale(1.06);
    text-shadow: 0 0 7px currentColor;
  }
}

.payment-instructions {
  max-width: 760px;
}
.payment-details {
  margin: 24px 0;
}
.payment-details > div {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.payment-details dt {
  color: var(--muted);
  font-size: 0.9rem;
}
.payment-details dd {
  margin: 6px 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}
.payment-details strong {
  font-size: 1.15rem;
}
.copy-button {
  background: transparent;
  color: var(--ink);
  border-color: #777;
  font-size: 0.85rem;
  padding: 8px 12px;
}
.payment-steps {
  padding-left: 24px;
}
.payment-steps li {
  margin: 12px 0;
  padding-left: 4px;
}
@media (prefers-reduced-motion: reduce) {
  .brand-name .rainbow-letter {
    animation: none;
    color: #feda75;
    text-shadow: none !important;
  }
}
@media (forced-colors: active) {
  .brand-name .rainbow-letter {
    animation: none;
    color: LinkText;
    text-shadow: none !important;
  }
}

.brand-name .rainbow-letter:nth-child(14) {
  animation-delay: -2.786s;
}

/* Animate the border only; photos and reading surfaces remain still. */
@property --listing-angle {
  syntax: "<angle>";
  initial-value: 0deg;
  inherits: false;
}
.card {
  border: 1px solid transparent;
  border-radius: 6px;
  overflow: hidden;
  background:
    linear-gradient(var(--bg), var(--bg)) padding-box,
    conic-gradient(
        from var(--listing-angle),
        #ff0000,
        #ff4500,
        #ff7700,
        #feda75,
        #1db954,
        #4267b2,
        #6441a5,
        #ff0000
      )
      border-box;
  animation: listing-border-rainbow 10s linear infinite;
}
.card .info {
  padding: 14px 16px 18px;
}
@keyframes listing-border-rainbow {
  to {
    --listing-angle: 360deg;
  }
}
@media (prefers-reduced-motion: reduce) {
  .card {
    animation: none;
  }
}
@media (forced-colors: active) {
  .card {
    animation: none;
    background: Canvas;
    border-color: CanvasText;
  }
}

/* Inset the photograph inside its existing box; do not enlarge the card. */
.card .photo {
  padding: 12px;
  background: var(--bg);
}

#zoom {
  padding: 64px 16px 16px;
}
#zoom img {
  display: block;
  max-height: calc(95vh - 90px);
}
#zoom [data-close-zoom] {
  position: absolute;
  top: 12px;
  right: 12px;
  margin: 0;
}
@media print {
  header,
  footer,
  .no-print,
  .payment-instructions,
  #messages,
  #exchange-link,
  .notice {
    display: none !important;
  }
  body.store {
    background: white;
    color: black;
  }
  .panel {
    background: white;
    color: black;
    border-color: #777;
    break-inside: avoid;
  }
  main {
    max-width: none;
    padding: 0;
  }
}

.plant-details {
  margin: 16px 0 24px;
}
.plant-detail {
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
  gap: 16px;
  align-items: baseline;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.plant-detail dt {
  color: var(--muted);
  font-size: 0.9rem;
}
.plant-detail dd {
  margin: 0;
}
.payment-qr {
  margin-block: 24px;
}
.payment-qr img {
  display: block;
  width: min(100%, 320px);
  height: auto;
  border-radius: 8px;
}

/* One primary action per flow page; checkout moves it to the next step. */
.button-primary,
.button-rainbow {
  display: inline-block;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: 10px;
  min-height: 48px;
  padding: 12px 22px;
  color: var(--ink);
  font-weight: 600;
  text-align: center;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    conic-gradient(
        from var(--listing-angle),
        #ff0000,
        #ff4500,
        #ff7700,
        #feda75,
        #1db954,
        #4267b2,
        #6441a5,
        #ff0000
      )
      border-box;
  animation: listing-border-rainbow 10s linear infinite;
  box-shadow: 0 3px 12px #0005;
  transition:
    box-shadow 160ms ease,
    transform 160ms ease;
}
.button-primary:hover:not(:disabled),
.button-rainbow:hover:not(:disabled) {
  color: var(--ink);
  border-color: transparent;
  background:
    linear-gradient(#202020, #202020) padding-box,
    conic-gradient(
        from var(--listing-angle),
        #ff0000,
        #ff4500,
        #ff7700,
        #feda75,
        #1db954,
        #4267b2,
        #6441a5,
        #ff0000
      )
      border-box;
  box-shadow: 0 5px 16px #0008;
  transform: translateY(-1px);
}
header nav a.button-rainbow {
  color: var(--ink);
}
@media (prefers-reduced-motion: reduce) {
  .button-primary,
  .button-rainbow {
    animation: none;
    transition: none;
  }
  .button-primary:hover,
  .button-rainbow:hover {
    transform: none;
  }
}
@media (forced-colors: active) {
  .button-primary,
  .button-primary:hover:not(:disabled),
  .button-rainbow,
  .button-rainbow:hover:not(:disabled) {
    animation: none;
    background: ButtonFace;
    color: ButtonText;
    border-color: ButtonText;
    box-shadow: none;
  }
}
.packing-slip {
  max-width: 800px;
  margin: 24px auto;
  padding: 36px;
  background: white;
  color: #111;
  border: 1px solid #ccc;
}
.slip-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 2px solid #111;
}
.slip-heading strong {
  font-size: 1.5rem;
}
.packing-slip h1 {
  font-size: 1.7rem;
  margin: 0;
}
.packing-slip h2 {
  font-size: 1rem;
  margin: 24px 0 8px;
}
.packing-slip p {
  margin: 8px 0 24px;
}
.packing-slip table {
  width: 100%;
  border-collapse: collapse;
}
.packing-slip th,
.packing-slip td {
  padding: 12px 8px;
  border-bottom: 1px solid #ccc;
  text-align: left;
}
.packing-slip .small {
  color: #555;
}
.slip-thanks {
  padding-top: 28px;
}
details.panel > summary {
  cursor: pointer;
  font-weight: 600;
  padding: 8px 0;
}
details.panel[open] > summary {
  margin-bottom: 20px;
}
@media (max-width: 560px) {
  .packing-slip {
    padding: 20px;
  }
  .slip-heading {
    flex-wrap: wrap;
  }
}
@media print {
  @page {
    margin: 15mm;
  }
  .packing-slip {
    border: 0;
    padding: 0;
    margin: 0;
    max-width: none;
    font-size: 11pt;
  }
  .packing-slip tr {
    break-inside: avoid;
  }
}
.dashboard-card {
  display: block;
  color: inherit;
  text-decoration: none;
}
.dashboard-card:hover {
  border-color: var(--accent);
}
.dashboard-card:hover h2 {
  text-decoration: underline;
}
.no-email-notice {
  color: #ff7777;
  border-left: 3px solid currentColor;
  padding-left: 16px;
}
