/* Product + corporate landing pages: cheesecake, cakes, corporate.
   Uses the tokens from site.css (burgundy, cream, gold). */

.pg { padding: 0; display: block; }
.pg > section, .pg > header { padding-inline: var(--edge); }
.pg h2 { font-size: clamp(1.875rem, 1.2rem + 2.4vw, 3.25rem); line-height: 1.02; }
.pg h3 { font-size: clamp(1.25rem, 1.1rem + .6vw, 1.625rem); line-height: 1.1; }

/* ---------- hero: burgundy ground, text left, framed photo right ---------- */
.pg-hero {
  background: var(--burgundy); color: var(--cream);
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px);
  align-items: center; padding-block: clamp(40px, 6vw, 88px);
}
.pg-hero h1 { font-size: clamp(2.75rem, 1.2rem + 5.2vw, 5.75rem); line-height: .98; max-width: 11ch; }
.pg-hero .lede { margin-top: 22px; color: rgb(var(--cream-rgb) / .9); max-width: 30em; }
.pg-hero .btn-row { margin-top: 30px; }
.pg-hero .btn-primary { background: var(--cream); color: var(--burgundy); }
.pg-hero .btn-primary:hover { background: color-mix(in srgb, var(--cream) 85%, white); }
.pg-hero .btn-outline, .pg-hero .btn-secondary { border-color: var(--gold); color: var(--cream); }
.pg-hero .btn-outline:hover, .pg-hero .btn-secondary:hover { border-color: var(--cream); background: transparent; }
.pg-facts { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--rule-dark); font-size: .9375rem; }
.pg-facts b { font-family: var(--f-display); font-weight: 400; font-size: 1.375rem; color: var(--cream); margin-right: 6px; }
.pg-facts span { color: rgb(var(--cream-rgb) / .8); }

.pg-frame { position: relative; margin: 0; justify-self: center; width: min(100%, 460px); }
.pg-frame img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 260px 260px 4px 4px; background: var(--cut-bg); }
.pg-frame::after { content: ""; position: absolute; inset: -12px; border: 1px solid var(--gold); border-radius: 272px 272px 10px 10px; pointer-events: none; }
.pg-tag {
  position: absolute; z-index: 2; left: -14px; bottom: 36px; padding: 12px 18px;
  background: var(--cream); color: var(--burgundy); border-radius: 2px; box-shadow: 0 10px 24px -10px rgb(var(--shadow-rgb) / .6);
  display: grid; gap: 2px;
}
.pg-tag b { font-family: var(--f-display); font-weight: 400; font-size: 1.5rem; line-height: 1; }
.pg-tag span { font-size: .8125rem; }

/* ---------- generic section rhythm ---------- */
.pg-sec { padding-block: var(--section-y); }
.pg-sec-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px 40px; margin-bottom: clamp(24px, 3.4vw, 44px); }
.pg-sec-head p { max-width: 34em; }

/* ---------- product cards ---------- */
.pg-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: clamp(14px, 2vw, 24px); }
.pg-card { display: grid; gap: 14px; align-content: start; }
.pg-card figure { margin: 0; aspect-ratio: 4 / 5; overflow: hidden; border-radius: var(--radius); background: var(--cut-bg); }
.pg-card img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease-out); }
.pg-card:hover img { transform: scale(1.04); }
.pg-card h3 { padding-bottom: 8px; border-bottom: 1px solid var(--gold); display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.pg-card h3 span { font-family: var(--f-body); font-size: 1rem; font-weight: 500; white-space: nowrap; }
.pg-card p { font-size: .9375rem; }
.pg-card.is-lead { position: relative; }
.pg-card.is-lead figure { outline: 1px solid var(--gold); outline-offset: 6px; }
.pg-card .pg-flag { position: absolute; top: 12px; left: 12px; z-index: 2; background: var(--cream); color: var(--burgundy); font-size: .75rem; font-weight: 600; padding: 5px 10px; border-radius: 2px; }

/* ---------- size & price table ---------- */
.pg-sizes { background: color-mix(in srgb, var(--cream) 88%, var(--burgundy)); }
.sz { width: 100%; border-collapse: collapse; }
.sz th, .sz td { padding: 18px 12px; text-align: right; border-bottom: 1px solid var(--rule); font-variant-numeric: tabular-nums; }
.sz th:first-child, .sz td:first-child { text-align: left; padding-left: 0; }
.sz thead th { font-weight: 600; font-size: .875rem; border-bottom: 1.5px solid var(--burgundy); padding-top: 0; }
.sz tbody th { font-family: var(--f-display); font-weight: 400; font-size: clamp(1.1875rem, 1rem + .7vw, 1.5rem); }
.sz td { font-size: 1.0625rem; }
.sz td:last-child { padding-right: 0; }
.sz tbody tr:hover { background: var(--hover-tint); }
.sz tr.is-lead th::after { content: " · signature"; font-family: var(--f-body); font-size: .8125rem; color: var(--gold-ink); }
.pg-note { margin-top: 18px; font-size: .9375rem; }

/* ---------- split: photo + copy ---------- */
.pg-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 6vw, 88px); align-items: center; }
.pg-split.flip > :first-child { order: 2; }
.pg-split img { display: block; width: 100%; height: auto; border-radius: var(--radius); background: var(--cut-bg); }
.pg-split .copy { display: grid; gap: 18px; justify-items: start; }
.pg-split .copy p { max-width: 32em; }

/* ---------- burgundy band ---------- */
.pg-band { background: var(--burgundy); color: var(--cream); padding-block: var(--section-y); }
.pg-band .btn-primary { background: var(--cream); color: var(--burgundy); }
.pg-band .btn-outline, .pg-band .btn-secondary { border-color: var(--gold); color: var(--cream); }
.pg-band .btn-outline:hover, .pg-band .btn-secondary:hover { border-color: var(--cream); background: transparent; }

/* ---------- gallery: five finished cakes ---------- */
.pg-gallery { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(12px, 2vw, 24px); align-items: end; }
.pg-gallery figure { margin: 0; display: grid; gap: 12px; }
.pg-gallery img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); background: var(--cut-bg); }
.pg-gallery figcaption { font-family: var(--f-display); font-size: 1.125rem; }

/* ---------- steps (order flow is a real sequence) ---------- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: clamp(20px, 3vw, 40px); counter-reset: s; }
.steps li { list-style: none; counter-increment: s; border-top: 1px solid var(--gold); padding-top: 18px; display: grid; gap: 8px; align-content: start; }
.steps li::before { content: counter(s); font-family: var(--f-display); font-size: 2.75rem; line-height: 1; color: var(--gold); }
.steps b { font-family: var(--f-display); font-weight: 400; font-size: 1.375rem; line-height: 1.1; }
.steps span { font-size: .9375rem; }
.pg-band .steps li { border-color: rgb(var(--cream-rgb) / .35); }

/* ---------- corporate: offer tiles ---------- */
.offers { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); border-top: 1px solid var(--burgundy); }
.offer { padding: 28px clamp(16px, 2vw, 28px) 32px 0; display: grid; gap: 10px; align-content: start; border-bottom: 1px solid var(--rule); }
.offer img { height: 64px; width: auto; max-width: 96px; object-fit: contain; object-position: left; margin-bottom: 8px; }
.offer p { font-size: .9375rem; max-width: 26em; }

.pg-photo-row { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: clamp(12px, 2vw, 24px); }
.pg-photo-row img { display: block; width: 100%; height: 100%; min-height: 280px; object-fit: cover; border-radius: var(--radius); background: var(--cut-bg); }

/* ---------- questions ---------- */
.qa { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: clamp(24px, 6vw, 88px); }
.qa dl { display: grid; }
.qa dt { font-family: var(--f-display); font-size: 1.25rem; line-height: 1.15; padding-top: 22px; border-top: 1px solid var(--rule); }
.qa dd { padding: 8px 0 22px; max-width: 38em; }
.qa dl > :first-child { border-top: 0; padding-top: 0; }

/* ---------- final call ---------- */
.pg-cta { display: grid; gap: 22px; justify-items: start; }
.pg-cta h2 { max-width: 14ch; }
.pg-cta p { max-width: 32em; }

@media (max-width: 860px) {
  .pg-hero, .pg-split, .qa { grid-template-columns: minmax(0, 1fr); }
  .pg-hero h1 { max-width: none; }
  .pg-split.flip > :first-child { order: 0; }
  .pg-frame { width: min(100%, 360px); margin-top: 12px; }
  .pg-tag { left: 8px; }
  .pg-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pg-gallery figure:last-child:nth-child(odd) { grid-column: 1 / -1; width: calc(50% - 6px); justify-self: center; }
  .pg-photo-row { grid-template-columns: 1fr 1fr; }
  .pg-photo-row img:first-child { grid-column: 1 / -1; min-height: 220px; }
  .pg-photo-row img { min-height: 180px; }
  .sz thead { display: none; }
  .sz, .sz tbody, .sz tr, .sz th, .sz td { display: block; }
  .sz tr { display: grid; grid-template-columns: repeat(3, 1fr); padding: 18px 0; border-bottom: 1px solid var(--rule); }
  .sz tbody th { grid-column: 1 / -1; padding: 0 0 10px; border: 0; }
  .sz td { padding: 0; border: 0; text-align: left; font-size: 1rem; }
  .sz td::before { content: attr(data-s); display: block; font-size: .75rem; color: var(--gold-ink); margin-bottom: 2px; }
  .sz tr.is-lead th::after { content: " · signature"; }
}
@media (max-width: 520px) {
  .pg-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pg-hero .btn-row .btn, .pg-cta .btn-row .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .pg-card img { transition: none; }
  .pg-card:hover img { transform: none; }
}
