/* Appily Nineteen — Orchard Yield Dossier product page (unique oy- layout) */

.page-orchard-yield {
  --oy-moss: #145233;
  --oy-fern: #1f7a52;
  --oy-honey: #e8a317;
  --oy-coral: #d45a3a;
  --oy-ink: #15202b;
  --oy-paper: #f4f1ea;
  --oy-line: #d4cdc0;
  --oy-accent: var(--oy-fern);
  --oy-accent-soft: rgba(31, 122, 82, 0.12);
  --oy-glow: rgba(31, 122, 82, 0.35);
  --oy-mono: 'IBM Plex Mono', 'Consolas', monospace;
  --oy-serif: 'Fraunces', Georgia, serif;
  --oy-sans: 'Sora', system-ui, sans-serif;
  background:
    radial-gradient(ellipse at 12% 0%, rgba(232, 163, 23, 0.08) 0%, transparent 42%),
    linear-gradient(180deg, #eef5f0 0%, #fff 300px);
}

.page-orchard-yield.tone-citrus {
  --oy-accent: #e8a317;
  --oy-accent-soft: rgba(232, 163, 23, 0.14);
  --oy-glow: rgba(232, 163, 23, 0.4);
}
.page-orchard-yield.tone-berry {
  --oy-accent: #c23d5a;
  --oy-accent-soft: rgba(194, 61, 90, 0.12);
  --oy-glow: rgba(194, 61, 90, 0.35);
}
.page-orchard-yield.tone-tropical {
  --oy-accent: #2d9b68;
  --oy-accent-soft: rgba(45, 155, 104, 0.12);
  --oy-glow: rgba(45, 155, 104, 0.35);
}
.page-orchard-yield.tone-stone {
  --oy-accent: #d4874a;
  --oy-accent-soft: rgba(212, 135, 74, 0.14);
  --oy-glow: rgba(212, 135, 74, 0.35);
}
.page-orchard-yield.tone-melon {
  --oy-accent: #7bc96f;
  --oy-accent-soft: rgba(123, 201, 111, 0.14);
  --oy-glow: rgba(123, 201, 111, 0.35);
}
.page-orchard-yield.tone-pome {
  --oy-accent: #8b4c2a;
  --oy-accent-soft: rgba(139, 76, 42, 0.12);
  --oy-glow: rgba(139, 76, 42, 0.3);
}
.page-orchard-yield.tone-rare {
  --oy-accent: #6b4c9a;
  --oy-accent-soft: rgba(107, 76, 154, 0.12);
  --oy-glow: rgba(107, 76, 154, 0.35);
}
.page-orchard-yield.tone-fresh {
  --oy-accent: var(--oy-fern);
  --oy-accent-soft: rgba(31, 122, 82, 0.12);
  --oy-glow: rgba(31, 122, 82, 0.35);
}

/* Shared */
.oy-kicker {
  margin: 0 0 8px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--oy-fern);
}

.oy-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border: 0;
  border-radius: 4px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}

.oy-btn-primary {
  background: var(--oy-moss);
  color: #fff;
}

.oy-btn-primary:hover {
  background: var(--oy-fern);
  transform: translateY(-1px);
}

.oy-btn-disabled {
  display: inline-flex;
  padding: 14px 24px;
  background: #d1d5db;
  color: #6b7280;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.82rem;
  cursor: not-allowed;
}

/* Vine trail breadcrumb */
.oy-vine-trail {
  padding: 14px 0;
  background: #fff;
  border-bottom: 1px solid var(--oy-line);
}

.oy-trail-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.oy-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: #6b7280;
}

.oy-crumb a {
  color: var(--oy-fern);
}

.oy-crumb a:hover {
  color: var(--oy-moss);
}

.oy-crumb-current {
  color: var(--oy-ink);
  font-weight: 600;
  max-width: 280px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oy-vault-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--oy-line);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--oy-ink);
  text-decoration: none;
  background: var(--oy-paper);
  transition: border-color 0.15s, transform 0.15s;
}

.oy-vault-chip::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--oy-accent);
}

.oy-vault-chip:hover {
  border-color: var(--oy-accent);
  transform: translateY(-1px);
}

/* Yield stage */
.oy-yield-stage {
  padding: clamp(28px, 4vw, 48px) 0 clamp(32px, 5vw, 52px);
}

.oy-stage-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: clamp(24px, 4vw, 48px);
  align-items: start;
}

/* Lens spotlight */
.oy-lens-stage {
  position: relative;
}

.oy-lens-halo {
  position: absolute;
  top: 10%;
  left: 50%;
  transform: translateX(-50%);
  width: 70%;
  height: 60%;
  border-radius: 50%;
  background: radial-gradient(ellipse, var(--oy-glow), transparent 70%);
  pointer-events: none;
  filter: blur(20px);
}

.oy-lens-frame {
  position: relative;
  padding: 24px;
  background: #fff;
  border: 2px solid var(--oy-line);
  border-radius: 50% 50% 12px 12px / 30% 30% 12px 12px;
  box-shadow:
    0 0 0 8px var(--oy-accent-soft),
    0 16px 40px rgba(21, 32, 43, 0.1);
  overflow: hidden;
}

.oy-lens-ring {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 72px;
  height: 72px;
  z-index: 2;
}

.oy-lens-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.oy-ring-track {
  fill: none;
  stroke: var(--oy-line);
  stroke-width: 6;
}

.oy-ring-fill {
  fill: none;
  stroke: var(--oy-accent);
  stroke-width: 6;
  stroke-linecap: round;
  stroke-dasharray: 327;
  stroke-dashoffset: calc(327 - (327 * var(--oy-score, 88) / 100));
}

.oy-ring-label {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--oy-mono);
  font-size: 0.58rem;
  font-weight: 700;
  text-align: center;
  color: var(--oy-moss);
  line-height: 1.2;
}

.oy-hero-img {
  margin: 0;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
  background: var(--oy-paper);
}

.oy-hero-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.oy-lens-frame:hover .oy-hero-img img {
  transform: scale(1.03);
}

.oy-flag {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 3;
  padding: 6px 12px;
  background: var(--oy-coral);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: 2px;
  transform: rotate(-3deg);
}

.oy-flag-sold {
  background: #6b7280;
}

.oy-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.oy-badges li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  background: #fff;
  border: 1px solid var(--oy-line);
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--oy-ink);
}

/* Dossier panel */
.oy-dossier {
  background: #fff;
  border: 1px solid var(--oy-line);
  border-radius: 6px;
  box-shadow: 0 8px 28px rgba(21, 32, 43, 0.08);
  overflow: hidden;
}

.oy-dossier-tab {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  background: var(--oy-moss);
  color: #fff;
  font-family: var(--oy-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.oy-dossier-code {
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 2px;
}

.oy-dossier-body {
  padding: clamp(20px, 3vw, 28px);
}

.oy-dossier-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}

.oy-dossier h1 {
  margin: 0 0 6px;
  font-family: var(--oy-serif);
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.15;
  color: var(--oy-ink);
}

.oy-variant {
  margin: 0;
  font-size: 0.88rem;
  color: #6b7280;
}

.oy-rating {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
}

.oy-star {
  font-size: 1rem;
  color: #d1d5db;
}

.oy-star.is-on {
  color: var(--oy-honey);
}

.oy-reviews {
  margin-left: 6px;
  font-size: 0.78rem;
  color: #9ca3af;
}

/* Ripeness spectrum */
.oy-spectrum {
  display: grid;
  gap: 10px;
  margin-bottom: 20px;
  padding: 14px 16px;
  background: var(--oy-paper);
  border: 1px dashed var(--oy-line);
  border-radius: 4px;
}

.oy-spectrum-row {
  display: grid;
  grid-template-columns: 72px 1fr 40px;
  gap: 10px;
  align-items: center;
}

.oy-spectrum-label {
  font-family: var(--oy-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6b7280;
}

.oy-spectrum-bar {
  height: 8px;
  background: #fff;
  border: 1px solid var(--oy-line);
  border-radius: 4px;
  overflow: hidden;
}

.oy-spectrum-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--oy-accent), var(--oy-honey));
  border-radius: 3px;
  transition: width 0.4s ease;
}

.oy-spectrum-val {
  font-family: var(--oy-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--oy-moss);
  text-align: right;
}

/* Price */
.oy-price-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 12px;
  margin-bottom: 18px;
  padding: 14px 16px;
  background: var(--oy-accent-soft);
  border-left: 4px solid var(--oy-accent);
  border-radius: 2px;
}

.oy-price-was {
  font-family: var(--oy-mono);
  font-size: 0.9rem;
  color: #9ca3af;
  text-decoration: line-through;
}

.oy-price {
  font-family: var(--oy-serif);
  font-size: clamp(1.6rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--oy-moss);
}

.oy-price.is-sale {
  color: var(--oy-coral);
}

.oy-price-unit {
  font-size: 0.82rem;
  color: #6b7280;
}

/* Meta grid */
.oy-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.oy-meta-tile {
  padding: 12px 14px;
  background: var(--oy-paper);
  border: 1px solid var(--oy-line);
  border-radius: 4px;
}

.oy-meta-key {
  display: block;
  margin-bottom: 4px;
  font-family: var(--oy-mono);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #9ca3af;
}

.oy-meta-tile strong {
  font-size: 0.88rem;
  color: var(--oy-ink);
  word-break: break-word;
}

.oy-desc {
  margin: 0 0 16px;
  font-size: 0.92rem;
  line-height: 1.7;
  color: #5c6670;
}

.oy-divider {
  height: 1px;
  margin: 18px 0;
  background: repeating-linear-gradient(
    90deg,
    var(--oy-line) 0,
    var(--oy-line) 6px,
    transparent 6px,
    transparent 12px
  );
}

/* Buy form */
.oy-buy-form {
  display: grid;
  gap: 14px;
}

.oy-qty-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.oy-qty-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--oy-ink);
}

.oy-stepper {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--oy-line);
  border-radius: 4px;
  overflow: hidden;
}

.oy-stepper-btn {
  width: 40px;
  border: 0;
  background: var(--oy-paper);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--oy-moss);
  cursor: pointer;
  transition: background 0.15s;
}

.oy-stepper-btn:hover {
  background: var(--oy-accent-soft);
}

.oy-stepper input {
  width: 48px;
  border: 0;
  border-left: 1px solid var(--oy-line);
  border-right: 1px solid var(--oy-line);
  text-align: center;
  font-family: var(--oy-mono);
  font-size: 0.92rem;
  font-weight: 700;
  background: #fff;
}

.oy-footnote {
  margin: 12px 0 0;
  font-size: 0.76rem;
  line-height: 1.55;
  color: #9ca3af;
}

/* Aisle notes */
.oy-notes {
  padding: 0 0 clamp(40px, 5vw, 56px);
}

.oy-notes-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.oy-note {
  background: #fff;
  border: 1px solid var(--oy-line);
  border-radius: 4px;
  overflow: hidden;
}

.oy-note summary {
  padding: 14px 16px;
  font-family: var(--oy-serif);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--oy-ink);
  cursor: pointer;
  list-style: none;
  background: var(--oy-paper);
  border-bottom: 1px solid transparent;
}

.oy-note[open] summary {
  border-bottom-color: var(--oy-line);
  color: var(--oy-moss);
}

.oy-note summary::-webkit-details-marker {
  display: none;
}

.oy-note p {
  margin: 0;
  padding: 14px 16px;
  font-size: 0.86rem;
  line-height: 1.65;
  color: #6b7280;
}

/* Related filmstrip */
.oy-vault-row {
  padding: clamp(32px, 5vw, 48px) 0 clamp(48px, 6vw, 72px);
  background: var(--oy-paper);
  border-top: 1px solid var(--oy-line);
}

.oy-vault-head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 20px;
}

.oy-vault-head h2 {
  margin: 0;
  font-family: var(--oy-serif);
  font-size: clamp(1.2rem, 2.5vw, 1.5rem);
  color: var(--oy-ink);
}

.oy-vault-all {
  font-family: var(--oy-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--oy-fern);
  text-decoration: none;
}

.oy-vault-all:hover {
  color: var(--oy-moss);
}

.oy-filmstrip {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}

.oy-film-card {
  flex: 0 0 160px;
  scroll-snap-align: start;
  display: grid;
  gap: 8px;
  padding: 12px;
  background: #fff;
  border: 1px solid var(--oy-line);
  border-top: 3px solid var(--oy-accent, var(--oy-fern));
  border-radius: 4px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s, box-shadow 0.2s;
}

.oy-film-card.tone-citrus { --oy-accent: #e8a317; }
.oy-film-card.tone-berry { --oy-accent: #c23d5a; }
.oy-film-card.tone-tropical { --oy-accent: #2d9b68; }
.oy-film-card.tone-stone { --oy-accent: #d4874a; }
.oy-film-card.tone-melon { --oy-accent: #7bc96f; }
.oy-film-card.tone-pome { --oy-accent: #8b4c2a; }
.oy-film-card.tone-rare { --oy-accent: #6b4c9a; }

.oy-film-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(21, 32, 43, 0.1);
}

.oy-film-thumb {
  display: block;
  aspect-ratio: 1;
  border-radius: 4px;
  overflow: hidden;
  background: var(--oy-paper);
}

.oy-film-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.oy-film-name {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--oy-ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.oy-film-price {
  font-family: var(--oy-mono);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--oy-moss);
}

/* 404 miss */
.page-oy-miss {
  background: var(--oy-paper);
}

.oy-miss {
  padding: clamp(56px, 8vw, 96px) 0;
  text-align: center;
}

.oy-miss-crate {
  width: 100px;
  height: 80px;
  margin: 0 auto 20px;
  display: grid;
  place-items: center;
  background: #fff;
  border: 2px dashed var(--oy-line);
  border-radius: 4px;
}

.oy-miss-icon {
  font-size: 2.2rem;
  opacity: 0.5;
}

.oy-miss h1 {
  margin: 0 0 12px;
  font-family: var(--oy-serif);
  font-size: 1.5rem;
  color: var(--oy-ink);
}

.oy-miss p {
  max-width: 420px;
  margin: 0 auto 24px;
  color: #6b7280;
  line-height: 1.65;
}

/* ── Responsive ── */
@media (max-width: 960px) {
  .oy-stage-grid {
    grid-template-columns: 1fr;
  }

  .oy-notes-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .oy-trail-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .oy-dossier-head {
    flex-direction: column;
  }

  .oy-meta-grid {
    grid-template-columns: 1fr;
  }

  .oy-spectrum-row {
    grid-template-columns: 64px 1fr 36px;
  }

  .oy-buy-form .oy-btn-primary,
  .oy-buy-form .oy-btn-disabled {
    width: 100%;
  }
}
