/* Barakah Global — Seed Index Deck catalog (unique aisle-tray layout) */

.page-catalog-index {
  --ix-bg: #eaf2ec;
  --ix-paper: #fbfaf6;
  --ix-ink: #13261f;
  --ix-soft: #4a6357;
  --ix-line: rgba(19, 38, 31, 0.12);
  --ix-moss: #1f6b4f;
  --ix-moss-bright: #2f9a6a;
  --ix-saffron: #e09a1b;
  --ix-saffron-deep: #c47d0a;
  --ix-plate: #0f2a22;
  --ix-shadow: 0 18px 40px rgba(15, 42, 34, 0.12);
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Outfit", system-ui, sans-serif;
  font-family: var(--font-body);
  color: var(--ix-ink);
  background:
    radial-gradient(ellipse 65% 40% at 0% 0%, rgba(31, 107, 79, 0.1), transparent 55%),
    radial-gradient(ellipse 50% 35% at 100% 8%, rgba(224, 154, 27, 0.11), transparent 50%),
    linear-gradient(180deg, var(--ix-bg) 0%, #fff 42%, #e7f0ea 100%);
}

.a32-index {
  padding-bottom: 0;
}

/* ——— Masthead ——— */
.a32-index-mast {
  position: relative;
  overflow: hidden;
  padding: clamp(2.4rem, 5vw, 3.5rem) 0 2.85rem;
  color: #f7fbf8;
  background: linear-gradient(122deg, #0f2a22 0%, #184a38 48%, #12362d 100%);
}
.a32-index-mast-glow {
  position: absolute;
  width: min(50vw, 440px);
  height: min(50vw, 440px);
  right: -12%;
  top: -28%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(224, 154, 27, 0.3), transparent 68%);
  animation: a32-ix-glow 12s ease-in-out infinite;
  pointer-events: none;
}
@keyframes a32-ix-glow {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.85; }
  50% { transform: translate(-7%, 9%) scale(1.08); opacity: 1; }
}
.a32-index-mast-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.25fr auto;
  gap: clamp(1.25rem, 3vw, 2.5rem);
  align-items: end;
}
.a32-index-crumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  margin-bottom: 0.75rem;
  font-size: 0.82rem;
  color: rgba(247, 251, 248, 0.65);
}
.a32-index-crumb a {
  color: rgba(247, 251, 248, 0.9);
  text-decoration: none;
  font-weight: 600;
}
.a32-index-crumb a:hover {
  color: var(--ix-saffron);
}
.a32-index-brand {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  font-weight: 700;
  font-variation-settings: "SOFT" 35, "WONK" 0.45;
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.a32-index-mast h1 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 4vw, 2.7rem);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.a32-index-lede {
  margin: 0;
  max-width: 44ch;
  font-size: 0.98rem;
  line-height: 1.55;
  color: rgba(247, 251, 248, 0.78);
}
.a32-index-meters {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
  min-width: 11rem;
}
.a32-index-meters > div {
  display: grid;
  gap: 0.15rem;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  background: rgba(251, 250, 246, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  text-align: center;
  backdrop-filter: blur(8px);
}
.a32-index-meters strong {
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
  color: var(--ix-saffron);
}
.a32-index-meters span {
  font-size: 0.75rem;
  font-weight: 700;
  color: rgba(247, 251, 248, 0.7);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ——— Shell ——— */
.a32-index-shell {
  position: relative;
  z-index: 2;
  margin-top: -1.25rem;
  padding-bottom: 2rem;
  display: grid;
  gap: 1.25rem;
}

/* ——— Jump rail ——— */
.a32-index-jump {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.35rem 0.1rem 0.65rem;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}
.a32-index-jump-chip {
  flex: 0 0 auto;
  scroll-snap-align: start;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 0.95rem;
  border-radius: 999px;
  text-decoration: none;
  color: var(--ix-ink);
  background: var(--ix-paper);
  border: 1px solid var(--ix-line);
  box-shadow: 0 10px 24px rgba(15, 42, 34, 0.06);
  transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}
.a32-index-jump-chip:hover {
  transform: translateY(-2px);
  border-color: rgba(31, 107, 79, 0.35);
  background: #fff;
}
.a32-index-jump-chip em {
  font-style: normal;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--ix-saffron-deep);
}
.a32-index-jump-chip span {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

/* ——— Deck / trays ——— */
.a32-index-deck {
  display: grid;
  gap: 1.15rem;
}
.a32-index-tray {
  border-radius: 1.35rem;
  background: var(--ix-paper);
  border: 1px solid var(--ix-line);
  box-shadow: var(--ix-shadow);
  overflow: hidden;
  animation: a32-ix-rise 0.55s ease both;
}
.a32-index-deck .a32-index-tray:nth-child(2) { animation-delay: 0.04s; }
.a32-index-deck .a32-index-tray:nth-child(3) { animation-delay: 0.08s; }
.a32-index-deck .a32-index-tray:nth-child(4) { animation-delay: 0.12s; }
.a32-index-deck .a32-index-tray:nth-child(5) { animation-delay: 0.16s; }
.a32-index-deck .a32-index-tray:nth-child(6) { animation-delay: 0.2s; }
.a32-index-deck .a32-index-tray:nth-child(7) { animation-delay: 0.24s; }
@keyframes a32-ix-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
.a32-index-tray:hover {
  border-color: rgba(31, 107, 79, 0.28);
}

.a32-index-tray-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 1.15rem 1.25rem 1rem;
  background:
    linear-gradient(135deg, rgba(15, 42, 34, 0.96), rgba(26, 77, 58, 0.94));
  color: #f7fbf8;
}
.a32-index-tray-num {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ix-saffron);
}
.a32-index-tray-head h2 {
  margin: 0 0 0.3rem;
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 1.6rem);
  font-weight: 650;
  letter-spacing: -0.02em;
}
.a32-index-tray-head h2 a {
  color: inherit;
  text-decoration: none;
}
.a32-index-tray-head h2 a:hover {
  color: var(--ix-saffron);
}
.a32-index-tray-head p {
  margin: 0;
  font-size: 0.88rem;
  color: rgba(247, 251, 248, 0.72);
}
.a32-index-enter {
  display: inline-flex;
  align-items: center;
  padding: 0.6rem 1rem;
  border-radius: 999px;
  background: var(--ix-saffron);
  color: var(--ix-ink);
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.a32-index-enter:hover {
  background: var(--ix-saffron-deep);
  color: #fff;
  transform: translateY(-1px);
}

.a32-index-preview {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.65rem;
  padding: 1rem 1.15rem 0.35rem;
}
.a32-index-thumb {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  border-radius: 0.95rem;
  overflow: hidden;
  background: linear-gradient(160deg, #e8f1eb, #f4f7f2 55%, #efe8d8);
  border: 1px solid var(--ix-line);
  text-decoration: none;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.a32-index-thumb:hover {
  transform: translateY(-4px) scale(1.03);
  box-shadow: 0 12px 24px rgba(15, 42, 34, 0.12);
}
.a32-index-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.55rem;
  transition: transform 0.4s ease;
}
.a32-index-thumb:hover img {
  transform: scale(1.06) rotate(-1deg);
}

.a32-index-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.75rem 1.15rem 1.2rem;
}
.a32-index-chip {
  display: inline-flex;
  max-width: 100%;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--ix-line);
  color: var(--ix-ink);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 650;
  line-height: 1.3;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.a32-index-chip:hover {
  border-color: rgba(31, 107, 79, 0.35);
  background: rgba(31, 107, 79, 0.08);
  color: var(--ix-moss);
}

/* ——— Dock ——— */
.a32-index-dock {
  position: sticky;
  bottom: 0;
  z-index: 5;
  padding: 0.85rem 0;
  background: rgba(15, 42, 34, 0.94);
  color: #f7fbf8;
  border-top: 1px solid rgba(224, 154, 27, 0.35);
  backdrop-filter: blur(10px);
}
.a32-index-dock-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
}
.a32-index-dock-inner strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 650;
  margin-bottom: 0.15rem;
}
.a32-index-dock-inner span {
  font-size: 0.85rem;
  color: rgba(247, 251, 248, 0.72);
}
.a32-index-dock-btn {
  display: inline-flex;
  align-items: center;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  background: var(--ix-saffron);
  color: var(--ix-ink);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.a32-index-dock-btn:hover {
  background: var(--ix-saffron-deep);
  color: #fff;
  transform: translateY(-1px);
}

/* ——— Responsive ——— */
@media (max-width: 900px) {
  .a32-index-preview {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .a32-index-preview .a32-index-thumb:nth-child(5) {
    display: none;
  }
}
@media (max-width: 720px) {
  .a32-index-mast-inner {
    grid-template-columns: 1fr;
  }
  .a32-index-meters {
    justify-self: start;
  }
  .a32-index-preview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .a32-index-preview .a32-index-thumb:nth-child(4),
  .a32-index-preview .a32-index-thumb:nth-child(5) {
    display: none;
  }
  .a32-index-tray-head {
    align-items: stretch;
  }
  .a32-index-enter {
    width: 100%;
    justify-content: center;
  }
}
@media (max-width: 480px) {
  .a32-index-preview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .a32-index-dock-inner {
    flex-direction: column;
    align-items: stretch;
  }
  .a32-index-dock-btn {
    width: 100%;
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .a32-index-mast-glow,
  .a32-index-tray {
    animation: none !important;
  }
  .a32-index-thumb,
  .a32-index-jump-chip,
  .a32-index-enter {
    transition: none !important;
  }
}
