/* Jenviv Kiddie storefront (WEB-P1-05) — follows the approved design.
   Colour rule: the full logo palette is decoration only. Text, prices and
   buttons use the "-ink" values, which pass WCAG AA (4.5:1) on white.
   Yellow and teal never carry text. */

:root {
  --navy: #13204A;
  --muted: #4A5374;
  --pink: #F2527F;
  --pink-ink: #D6336A;
  --pink-dark: #C42A5E;
  --pink-wash: #FDE8EF;
  --purple: #8963B7;
  --purple-wash: #EFE8F7;
  --green-ink: #3E7F22;
  --teal-wash: #E1F4F5;
  --yellow-wash: #FFF4D9;
  --paper: #FFFFFF;
  --mist: #F7F5FA;
  --line: #E7E3EF;

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Nunito", "Segoe UI", system-ui, sans-serif;
  --radius: 14px;
  --radius-lg: 20px;
  --wrap: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 1rem; }
body { margin: 0; font-family: var(--font-body); font-size: 1rem; line-height: 1.55; color: var(--navy); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: var(--pink-ink); }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 1rem; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 1.1em; height: 1.1em; flex: none; }

h1, h2 { font-family: var(--font-display); font-weight: 600; line-height: 1.15; margin: 0 0 .5rem; }
h1 { font-size: clamp(1.7rem, 4.5vw, 2.5rem); }
h2 { font-size: clamp(1.35rem, 3vw, 1.85rem); }
h3 { font-size: 1rem; font-weight: 700; margin: 0; }

/* ---------- Top bar ---------- */
.topbar { background: var(--mist); font-size: .85rem; color: var(--muted); }
.topbar .wrap { display: flex; justify-content: space-between; gap: 1rem; padding-top: .45rem; padding-bottom: .45rem; }
.topbar span, .topbar a { display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap; }
.topbar a { color: var(--navy); font-weight: 700; text-decoration: none; }
.topbar .optional { display: none; }
@media (min-width: 760px) { .topbar .optional { display: inline-flex; } }
.topbar .wide-only { display: none; }
@media (min-width: 420px) { .topbar .wide-only { display: inline-flex; } .topbar .narrow-only { display: none; } }

/* ---------- Header ---------- */
.site-header { background: var(--paper); border-bottom: 1px solid var(--line); }
.header-main { display: grid; grid-template-columns: auto 1fr; gap: .75rem 1.5rem; align-items: center; padding-top: .9rem; padding-bottom: .9rem; }
.brand img { height: 56px; width: auto; }
.search { grid-column: 1 / -1; display: flex; border: 1.5px solid var(--line); border-radius: 999px; overflow: hidden; background: var(--paper); }
.search input { flex: 1; min-width: 0; border: 0; padding: .7rem 1.1rem; font: inherit; color: var(--navy); background: transparent; }
.search input:focus { outline: none; }
.search:focus-within { border-color: var(--purple); }
.search button { border: 0; background: var(--pink-ink); color: var(--paper); padding: 0 1.2rem; cursor: pointer; display: grid; place-items: center; }
.search button:hover { background: var(--pink-dark); }
.search button .icon { width: 1.3rem; height: 1.3rem; }
@media (min-width: 760px) { .header-main { grid-template-columns: auto minmax(0, 560px); justify-content: space-between; } .search { grid-column: auto; } }

.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: .25rem 1.5rem; overflow-x: auto; }
.main-nav a { display: block; padding: .7rem 0; color: var(--navy); font-weight: 700; text-decoration: none; white-space: nowrap; border-bottom: 3px solid transparent; }
.main-nav a:hover { color: var(--pink-ink); }
.main-nav a[aria-current="page"] { color: var(--pink-ink); border-bottom-color: var(--pink-ink); }

/* ---------- Breadcrumb ---------- */
.breadcrumb { font-size: .88rem; color: var(--muted); padding: 1rem 0 0; }
.breadcrumb ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .35rem; }
.breadcrumb li + li::before { content: "/"; margin-right: .35rem; color: #9AA0B5; }
.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--pink-ink); text-decoration: underline; }

/* ---------- Section heading ---------- */
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin: 2.5rem 0 1rem; }
.section-head a { font-weight: 700; text-decoration: none; white-space: nowrap; }

/* ---------- Product cards ---------- */
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(2, minmax(0, 1fr)); padding-bottom: 1rem; }
@media (min-width: 760px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; } }
.product-card { display: flex; flex-direction: column; text-decoration: none; color: var(--navy); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: box-shadow .15s ease; }
.product-card:hover { box-shadow: 0 6px 20px rgba(19, 32, 74, .08); }
.product-card .thumb { position: relative; aspect-ratio: 2 / 3; background: var(--mist); overflow: hidden; }
.product-card .thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.badge { position: absolute; top: .6rem; left: .6rem; background: var(--pink-ink); color: var(--paper); font-size: .75rem; font-weight: 800; padding: .15rem .55rem; border-radius: 999px; }
.product-card .body { display: flex; flex-direction: column; gap: .2rem; padding: .8rem .9rem 1rem; flex: 1; }
.product-card .meta { font-size: .85rem; color: var(--muted); }
.price { color: var(--pink-ink); font-weight: 800; }
.product-card .price { font-size: 1.1rem; margin-top: auto; padding-top: .3rem; }
.product-card .card-cta { margin-top: .6rem; text-align: center; border-radius: 999px; padding: .5rem; background: var(--pink-ink); color: var(--paper); font-weight: 800; font-size: .9rem; }
.product-card:hover .card-cta { background: var(--pink-dark); }
.empty { padding: 3rem 0; text-align: center; grid-column: 1 / -1; }

/* ---------- Product detail ---------- */
.detail { display: grid; gap: 1.75rem; padding: 1.25rem 0 1rem; }
@media (min-width: 860px) { .detail { grid-template-columns: 1.05fr 1fr; gap: 3rem; align-items: start; } }
.detail .photo { border-radius: var(--radius-lg); background: var(--mist); overflow: hidden; display: grid; place-items: center; }
.detail .photo img { display: block; width: 100%; height: auto; max-height: 82vh; object-fit: contain; }
.detail .price { display: block; font-size: 1.75rem; margin: .1rem 0 1.25rem; }
.option-group { margin: 0 0 1.1rem; border: 0; padding: 0; }
.option-group legend { font-weight: 800; margin-bottom: .45rem; }
.option-group legend span { font-weight: 600; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip { display: inline-block; text-decoration: none; color: var(--navy); border: 1.5px solid var(--line); border-radius: 10px; padding: .45rem .9rem; font-weight: 700; min-width: 3rem; text-align: center; background: var(--paper); }
.chip:hover { border-color: var(--purple); }
.chip[aria-current="true"] { border-color: var(--navy); background: var(--navy); color: var(--paper); }
.stock { display: flex; align-items: center; gap: .45rem; font-weight: 800; margin: .25rem 0 1.1rem; }
.stock::before { content: ""; width: .6rem; height: .6rem; border-radius: 50%; background: currentColor; }
.stock.in { color: var(--green-ink); }
.stock.out { color: var(--muted); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .55rem; width: 100%; padding: .95rem 1.25rem; border: 0; border-radius: 999px; background: var(--pink-ink); color: var(--paper); font: 800 1.05rem var(--font-body); text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--pink-dark); }
.btn[aria-disabled="true"] { background: #B9BCC8; pointer-events: none; }
.btn-note { font-size: .88rem; color: var(--muted); margin: .55rem 0 0; }
.facts { list-style: none; padding: 1.1rem 1.2rem; margin: 1.5rem 0 0; background: var(--mist); border-radius: var(--radius); display: grid; gap: .7rem; }
.facts li { display: flex; gap: .7rem; align-items: flex-start; font-size: .95rem; }
.facts .icon { color: var(--purple); width: 1.3rem; height: 1.3rem; margin-top: .1rem; }
.facts strong { display: block; }
.description { max-width: 46em; }

/* ---------- Footer ---------- */
.site-footer { background: var(--mist); margin-top: 3rem; padding: 2rem 0 calc(1.5rem + env(safe-area-inset-bottom, 0px)); }
.footer-top { display: grid; gap: 1.25rem; align-items: center; }
@media (min-width: 760px) { .footer-top { grid-template-columns: auto 1fr; } }
.site-footer .brand img { height: 60px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; }
@media (min-width: 760px) { .footer-links { justify-content: flex-end; } }
.footer-links a { color: var(--navy); text-decoration: none; font-size: .92rem; }
.footer-links a:hover { color: var(--pink-ink); text-decoration: underline; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem 1rem; border-top: 1px solid var(--line); margin-top: 1.25rem; padding-top: 1rem; font-size: .88rem; color: var(--muted); }
.footer-bottom strong { color: var(--navy); }
.heart { color: var(--pink); }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Listing pages (WEB-P1-06) ---------- */
.listing-head { margin: 1rem 0 1.25rem; }
.listing-head .intro { color: var(--muted); margin: 0; max-width: 40em; }
.listing-controls { display: grid; gap: .9rem; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: .9rem 0; margin-bottom: 1.25rem; }
.toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .6rem 1rem; }
.count { margin: 0; font-weight: 700; color: var(--muted); }
.control-label { font-weight: 800; margin-right: .25rem; white-space: nowrap; }
.sort { display: flex; flex-wrap: nowrap; align-items: center; gap: .4rem; overflow-x: auto; max-width: 100%; scrollbar-width: thin; }
.sort a { white-space: nowrap; }
.sort a { text-decoration: none; color: var(--navy); font-weight: 600; font-size: .92rem; padding: .3rem .8rem; border-radius: 999px; border: 1.5px solid transparent; }
.sort a:hover { border-color: var(--line); }
.sort a[aria-current="true"] { background: var(--purple-wash); border-color: var(--purple); color: var(--navy); font-weight: 800; }
.size-filter { display: flex; align-items: center; gap: .5rem; min-width: 0; }
.size-filter .chips { flex-wrap: nowrap; overflow-x: auto; padding-bottom: .2rem; scrollbar-width: thin; }
.size-filter .chip { padding: .35rem .75rem; min-width: auto; white-space: nowrap; font-size: .92rem; }
.pagination { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; margin: 1rem 0 0; font-weight: 700; color: var(--muted); }
.pagination a { justify-self: start; text-decoration: none; font-weight: 800; padding: .5rem 1.1rem; border-radius: 999px; border: 1.5px solid var(--pink-ink); }
.pagination a[rel="next"] { justify-self: end; }
.pagination a:hover { background: var(--pink-wash); }
@media (max-width: 420px) {
  .sort { gap: .1rem; }
  .sort a { padding: .3rem .5rem; font-size: .86rem; }
}

/* ---------- Home page (WEB-P1-07) ---------- */
.hero { display: grid; align-items: center; gap: 1.25rem; margin: 1.25rem 0 .5rem; border-radius: var(--radius-lg); overflow: hidden;
        background: linear-gradient(110deg, var(--pink-wash) 0%, #FFFFFF 50%); }
.hero-text { padding: 1.75rem 1.5rem 0; }
.eyebrow { margin: 0 0 .4rem; color: var(--pink-ink); font-weight: 800; letter-spacing: .02em; }
.hero h1 { font-size: clamp(2rem, 6vw, 3.3rem); margin-bottom: .75rem; }
.hero-sub { color: var(--muted); font-size: 1.05rem; max-width: 30em; margin: 0 0 1.4rem; }
.hero-btn { width: auto; padding: .9rem 1.8rem; }
.hero-photo img { width: 100%; height: auto; aspect-ratio: 834 / 711; max-height: 300px; object-fit: cover; object-position: center 40%; }
@media (min-width: 860px) {
  .hero { grid-template-columns: 1.05fr 1fr; gap: 0; }
  .hero-text { padding: 2.5rem 1rem 2.5rem 3rem; }
  .hero-photo img { aspect-ratio: auto; height: 100%; max-height: 470px; }
}

.tiles { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.tile { position: relative; display: grid; grid-template-columns: 96px 1fr; align-items: center; gap: 1rem; padding: .9rem; border-radius: var(--radius-lg);
        text-decoration: none; color: var(--navy); transition: box-shadow .15s ease; }
.tile:hover { box-shadow: 0 6px 20px rgba(19, 32, 74, .1); }
@media (min-width: 640px) { .tile { grid-template-columns: 1fr; padding: 1rem 1rem 1.1rem; } .tile-photo { aspect-ratio: 4 / 3; } }
.tile-baby { background: var(--pink-wash); }
.tile-kids { background: var(--purple-wash); }
.tile-teens { background: #E8F3E3; }
.tile-photo { aspect-ratio: 1 / 1; border-radius: var(--radius); overflow: hidden; background: rgba(255, 255, 255, .55); display: grid; place-items: center; position: relative; }
.tile-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 15%; }
.tile-photo svg { width: 55%; height: 55%; }
.tile-baby .tile-photo svg { fill: var(--pink); }
.tile-kids .tile-photo svg { fill: var(--purple); }
.tile-teens .tile-photo svg { fill: var(--green-ink); }
.tile-text { display: grid; }
.tile-label { font-family: var(--font-display); font-size: 1.45rem; font-weight: 600; }
.tile-ages { color: var(--muted); font-size: .92rem; }
.tile-go { position: absolute; right: 1rem; bottom: 1rem; width: 2.3rem; height: 2.3rem; border-radius: 50%; display: grid; place-items: center; color: var(--paper); }
.tile-baby .tile-go { background: var(--pink-ink); }
.tile-kids .tile-go { background: var(--purple); }
.tile-teens .tile-go { background: var(--green-ink); }

.promises { display: grid; gap: 1rem; grid-template-columns: 1fr; margin-top: 2.5rem; padding: 1.25rem; background: var(--mist); border-radius: var(--radius-lg); }
@media (min-width: 640px) { .promises { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .promises { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.promise { display: flex; gap: .75rem; align-items: flex-start; }
.promise .icon { width: 1.8rem; height: 1.8rem; color: var(--purple); margin-top: .1rem; }
.promise strong { display: block; }
.promise span { color: var(--muted); font-size: .92rem; }

/* ---------- Cart (WEB-P2) ---------- */
.header-main { grid-template-columns: auto auto; justify-content: space-between; }
.cart-link { justify-self: end; position: relative; display: inline-flex; align-items: center; gap: .4rem; text-decoration: none; color: var(--navy); font-weight: 800; padding: .4rem .2rem; }
.cart-link .icon { width: 1.6rem; height: 1.6rem; }
.cart-link span:not(.cart-count) { display: none; }
.cart-count { position: absolute; top: -.1rem; left: 1.1rem; min-width: 1.25rem; height: 1.25rem; padding: 0 .3rem; border-radius: 999px; background: var(--pink-ink); color: var(--paper); font-size: .75rem; display: grid; place-items: center; }
@media (min-width: 760px) {
  .header-main { grid-template-columns: auto minmax(0, 560px) auto; }
  .cart-link span:not(.cart-count) { display: inline; }
  .cart-count { position: static; }
}
@media (max-width: 759px) { .header-main .search { grid-column: 1 / -1; grid-row: 2; } }

.notices { margin-top: 1rem; display: grid; gap: .5rem; }
.notice { margin: 0; padding: .7rem 1rem; border-radius: var(--radius); background: var(--mist); font-weight: 600; }
.notice-success { background: #E8F3E3; color: var(--green-ink); }
.notice-error { background: var(--pink-wash); color: var(--pink-dark); }

.add-form { display: grid; grid-template-columns: auto 5rem 1fr; align-items: center; gap: .6rem; margin-bottom: .75rem; }
.add-form label { font-weight: 800; }
.add-form select, .qty-form select { font: inherit; padding: .55rem .5rem; border: 1.5px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--navy); }
.add-form .btn { width: 100%; }
.btn-secondary { background: var(--paper); color: var(--pink-ink); border: 2px solid var(--pink-ink); }
.btn-secondary:hover { background: var(--pink-wash); }
.in-cart { margin: 0 0 .75rem; font-weight: 700; color: var(--green-ink); }

.cart-layout { display: grid; gap: 1.5rem; }
@media (min-width: 900px) { .cart-layout { grid-template-columns: 1fr 340px; align-items: start; } }
.cart-lines { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.cart-line { display: grid; grid-template-columns: 80px 1fr; gap: .9rem; padding: 1rem 0; border-bottom: 1px solid var(--line); }
@media (min-width: 640px) { .cart-line { grid-template-columns: 96px 1fr auto; } }
.cart-thumb img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; object-position: center top; border-radius: var(--radius); background: var(--mist); }
.cart-info { display: grid; gap: .15rem; align-content: start; }
.cart-name { font-weight: 800; color: var(--navy); text-decoration: none; }
.cart-name:hover { color: var(--pink-ink); }
.cart-actions { grid-column: 2; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem; }
@media (min-width: 640px) { .cart-actions { grid-column: auto; flex-direction: column; align-items: flex-end; } }
.qty-form { display: flex; align-items: center; gap: .4rem; }
.line-total { font-weight: 800; color: var(--pink-ink); }
.link-btn { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: var(--muted); text-decoration: underline; cursor: pointer; }
.link-btn:hover { color: var(--pink-ink); }
.is-sold-out .cart-thumb img { opacity: .45; }
.sold-out { color: var(--pink-dark); font-weight: 700; font-size: .9rem; }
.cart-summary { background: var(--mist); border-radius: var(--radius-lg); padding: 1.25rem; display: grid; gap: .8rem; }
.summary-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 1.15rem; }
.summary-row strong { color: var(--pink-ink); font-size: 1.35rem; }
.cart-summary .meta { margin: 0; }
.continue { text-align: center; font-weight: 700; }

/* ---- WEB-P3-03: checkout, order page, order lookup ---- */
.checkout-form { display: grid; gap: 1rem; align-content: start; }
.form-section { border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem 1.1rem 1.1rem; margin: 0; display: grid; gap: .8rem; }
.form-section legend { font-weight: 800; padding: 0 .35rem; }
.checkout-form label { display: grid; gap: .3rem; font-weight: 700; color: var(--navy); }
.checkout-form input:not([type=radio]):not([type=checkbox]), .checkout-form select, .checkout-form textarea, .code-form input {
  font: inherit; color: var(--navy); border: 1.5px solid var(--line); border-radius: 10px; padding: .65rem .8rem; background: var(--paper); width: 100%; }
.checkout-form input:focus, .checkout-form select:focus, .checkout-form textarea:focus, .code-form input:focus { outline: none; border-color: var(--purple); }
.checkout-form label.radio { display: flex; align-items: flex-start; gap: .55rem; font-weight: 700; }
.checkout-form label.agree { font-weight: 600; font-size: .92rem; }
.field-row { display: grid; gap: .8rem; }
@media (min-width: 560px) { .field-row { grid-template-columns: 1fr 1fr; } }
.lookup-form { max-width: 26rem; }
.btn-secondary { background: var(--paper); color: var(--pink-ink); border: 1.5px solid var(--pink-ink); }
.btn-secondary:hover { background: var(--pink-wash); }
.order-main h2 { margin-top: 0; }
.pay-steps { padding-left: 1.2rem; display: grid; gap: .35rem; }
.code-form { display: grid; gap: .8rem; margin-top: 1rem; max-width: 26rem; }
.code-form label { display: grid; gap: .3rem; font-weight: 700; }
.cart-summary .summary-row.line { font-size: .95rem; gap: .75rem; }
.cart-summary .summary-row .amt { white-space: nowrap; }
.checkout-form label.agree a { display: inline; }
.checkout-form .is-off { opacity: .45; }
.recode { margin-top: 1.5rem; border-top: 1px solid var(--line); padding-top: 1rem; }
.recode summary { cursor: pointer; font-weight: 700; color: var(--pink-ink); }

/* Product photos are portrait (2:3, e.g. 1024 x 1536): cards match that shape so the whole
   outfit shows; the product page shows the full photo at any shape (contain). */

/* Content pages: about, contact, FAQ, terms, privacy (launch readiness) */
.prose { max-width: 46rem; margin: 1.5rem auto 3rem; line-height: 1.65; }
.prose h1 { margin-bottom: 1rem; }
.prose h2 { font-size: 1.35rem; margin: 2rem 0 .6rem; }
.prose ul { padding-left: 1.25rem; }
.prose li + li { margin-top: .35rem; }
.prose a { color: var(--pink-ink); }
.prose .updated { color: var(--muted); margin-top: -.5rem; }
.contact-card { font-style: normal; background: var(--mist); border-radius: var(--radius); padding: 1rem 1.25rem; margin: 1rem 0; }
.inline-list { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; }
.faq details { border-bottom: 1px solid var(--line); padding: .25rem 0; }
.faq summary { cursor: pointer; font-weight: 700; padding: .6rem 0; }
.faq summary:hover { color: var(--pink-ink); }
.faq details p { margin: 0 0 .75rem; }
