/* =========================================================
   Almighty Pools — Renovation Design Studio
   Scoped styles for renodesignstudio.html
   (loads AFTER styles.css so it reuses the same tokens)
   ========================================================= */

/* ---------- Intro ---------- */
.studioHero {
  background: linear-gradient(165deg, var(--navy-900) 0%, var(--navy) 55%, var(--aqua-700) 130%);
  color: #fff; padding: clamp(2.4rem, 7vw, 4rem) 0 1.6rem; text-align: center;
}
.studioHero .eyebrow {
  display: inline-block; font-family: var(--font-head); font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; font-size: .78rem; color: #bff0ff;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.25);
  padding: .4rem 1rem; border-radius: 999px; margin-bottom: 1.1rem;
}
.studioHero__title {
  color: #fff; font-weight: 800; font-size: clamp(1.9rem, 6vw, 3.1rem);
  letter-spacing: -.02em; margin-bottom: .7rem;
}
.studioHero__lead {
  color: #eef3ff; max-width: 640px; margin: 0 auto; font-size: clamp(1rem, 2.4vw, 1.12rem);
}

/* ---------- Step progress ---------- */
.steps {
  display: flex; align-items: center; justify-content: center; gap: .4rem;
  margin: 2rem auto 0; max-width: 640px; flex-wrap: nowrap;
}
.steps__item {
  display: flex; align-items: center; gap: .55rem; flex: 0 1 auto;
  color: rgba(255,255,255,.6); font-family: var(--font-head); font-weight: 600;
  font-size: .82rem; white-space: nowrap;
}
.steps__num {
  width: 30px; height: 30px; flex: 0 0 30px; border-radius: 50%;
  display: grid; place-items: center; font-size: .9rem;
  background: rgba(255,255,255,.14); border: 2px solid rgba(255,255,255,.35);
  transition: background .25s, border-color .25s, color .25s;
}
.steps__item.is-current { color: #fff; }
.steps__item.is-current .steps__num { background: var(--aqua); border-color: var(--aqua); color: var(--navy-900); }
.steps__item.is-done { color: #d3f4ff; }
.steps__item.is-done .steps__num { background: rgba(64,192,230,.35); border-color: var(--aqua); color: #fff; }
.steps__item:not(:first-child)::before {
  content: ""; width: clamp(14px, 5vw, 48px); height: 2px; border-radius: 2px;
  background: rgba(255,255,255,.28); margin-right: .4rem;
}
.steps__item.is-done::before,
.steps__item.is-current::before { background: rgba(64,192,230,.7); }
@media (max-width: 480px) {
  .steps__label { display: none; }
  .steps__item:not(:first-child)::before { width: 26px; }
}

/* ---------- Step panels ---------- */
.studioStep { padding: clamp(2rem, 5vw, 3.2rem) 0 0; }
.studioStep[hidden] { display: none; }
.studioStep__head { text-align: center; max-width: 720px; margin: 0 auto 1.6rem; }
.studioStep__title { font-size: clamp(1.5rem, 4vw, 2.1rem); }
.studioStep__title span {
  display: inline-block; font-size: .7em; color: var(--aqua-700);
  background: var(--tint); padding: .1rem .6rem; border-radius: 999px; margin-right: .35rem;
  vertical-align: middle;
}
.studioStep__sub { color: var(--muted); margin: 0; }

/* ---------- Filters ---------- */
.filters { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin-bottom: 1.6rem; }
.filters--tile { flex-direction: column; align-items: center; gap: .9rem; }
.filters__group { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: .5rem; }
.filters__label {
  font-family: var(--font-head); font-weight: 700; font-size: .8rem; color: var(--navy);
  text-transform: uppercase; letter-spacing: .06em; margin-right: .2rem;
}
.chip {
  font-family: var(--font-head); font-weight: 600; font-size: .88rem;
  padding: .5rem 1rem; border-radius: 999px; cursor: pointer;
  background: #fff; color: var(--ink); border: 1.5px solid var(--line);
  transition: background .2s, color .2s, border-color .2s, transform .15s;
}
.chip:hover { border-color: var(--aqua); transform: translateY(-1px); }
.chip.is-active { background: var(--navy); color: #fff; border-color: var(--navy); }
.chip:focus-visible { outline: none; box-shadow: var(--ring); }
/* Size filter is a dropdown (30+ sizes is too many chips) — styled to read as a chip.
   Active state stays light so the custom chevron below is legible in both states. */
.filters__select {
  font-family: var(--font-head); font-weight: 600; font-size: .88rem;
  padding: .5rem 2.3rem .5rem 1rem; border-radius: 999px; cursor: pointer;
  background-color: #fff; color: var(--ink); border: 1.5px solid var(--line);
  transition: background-color .2s, color .2s, border-color .2s;
  -webkit-appearance: none; appearance: none; max-width: 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%2316233f' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right .9rem center; background-size: .7rem;
}
.filters__select:hover { border-color: var(--aqua); }
.filters__select:focus-visible { outline: none; box-shadow: var(--ring); }
.filters__select.is-active { background-color: var(--tint); border-color: var(--aqua); }
.filters__select optgroup { font-style: normal; font-weight: 700; color: var(--muted); }
.filters__select option { font-weight: 500; color: var(--ink); }

/* ---------- Swatch grid ---------- */
.swatchGrid {
  display: grid; gap: 1rem; grid-template-columns: repeat(2, 1fr);
  padding-bottom: .5rem;
}
@media (min-width: 560px) { .swatchGrid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 820px) { .swatchGrid { grid-template-columns: repeat(4, 1fr); gap: 1.2rem; } }
@media (min-width: 1080px){ .swatchGrid { grid-template-columns: repeat(5, 1fr); } }
.swatchGrid__empty { text-align: center; color: var(--muted); padding: 2rem 0; }
.swatchGrid__count { text-align: center; color: var(--muted); font-size: .85rem; margin: 0 0 1rem; }

.swatch {
  position: relative; display: flex; flex-direction: column;
  border: 2px solid var(--line); border-radius: var(--radius-sm);
  overflow: hidden; background: #fff; cursor: pointer; text-align: left;
  transition: border-color .2s, box-shadow .2s, transform .15s; padding: 0;
}
.swatch:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--aqua); }
.swatch:focus-visible { outline: none; box-shadow: var(--ring); }
/* display:flex above would override the [hidden] attribute, so restore it for filtering */
.swatch[hidden] { display: none; }
.swatch__img {
  display: block; aspect-ratio: 1 / 1; width: 100%; position: relative;
  background: linear-gradient(140deg, var(--aqua-700), var(--navy));
}
.swatch__img img { display: block; width: 100%; height: 100%; object-fit: cover; }
/* Tiles: show the whole product photo, never crop/zoom it */
.swatch--tile .swatch__img { background: #eef3f8; }
.swatch--tile .swatch__img img { object-fit: contain; }
.swatch__meta { display: block; padding: .6rem .7rem .7rem; }
.swatch__name { display: block; font-family: var(--font-head); font-weight: 600; font-size: .92rem; color: var(--ink); line-height: 1.25; }
.swatch__tag { display: block; font-size: .74rem; color: var(--body); margin-top: .1rem; }
.swatch__check {
  position: absolute; top: .5rem; right: .5rem; width: 26px; height: 26px; border-radius: 50%;
  background: var(--aqua); color: var(--navy-900); display: grid; place-items: center;
  transform: scale(0); transition: transform .2s var(--ease); z-index: 2;
}
.swatch__check svg { width: 15px; height: 15px; }
.swatch.is-selected { border-color: var(--aqua-600); box-shadow: 0 0 0 3px rgba(64,192,230,.3); }
.swatch.is-selected .swatch__check { transform: scale(1); }

/* ---------- Sticky step footer bar ---------- */
/* Solid (not translucent) + no backdrop-filter: prevents content bleeding
   through and avoids an iOS Safari sticky+backdrop-filter rendering glitch. */
.stepbar {
  position: sticky; bottom: 0; z-index: 30; margin-top: 1.4rem;
  background: #fff; border-top: 1px solid var(--line);
  box-shadow: 0 -6px 18px rgba(15, 34, 82, .08);
}
.stepbar__inner {
  display: flex; align-items: center; justify-content: space-between; gap: .8rem;
  padding-top: .8rem; padding-bottom: .8rem; flex-wrap: wrap;
}
.stepbar__pick { margin: 0; font-size: .9rem; color: var(--body); flex: 1 1 auto; min-width: 0; }
.stepbar__pick strong { color: var(--ink); font-family: var(--font-head); }
.stepbar .btn { flex: 0 0 auto; }

/* Running strip of picks so far — one thumb per chosen finish, tap to revisit that step */
.stepbar__strip { display: flex; align-items: flex-end; gap: .45rem; flex: 0 0 auto; }
.stepbar__strip:empty { display: none; }
.pickThumb {
  display: flex; flex-direction: column; align-items: center; gap: .22rem;
  background: none; border: 0; padding: 0; cursor: pointer; font-family: var(--font-head);
}
.pickThumb__img {
  display: block; width: 42px; height: 42px; border-radius: 9px; overflow: hidden;
  border: 2px solid var(--line); background: var(--tint-2);
  transition: border-color .2s, transform .2s var(--ease);
}
.pickThumb__img img { width: 100%; height: 100%; object-fit: cover; }
.pickThumb__img--spray { background: linear-gradient(140deg, var(--aqua-700), var(--navy)); }
.pickThumb:hover .pickThumb__img { border-color: var(--aqua); transform: translateY(-2px); }
.pickThumb:focus-visible { outline: none; }
.pickThumb:focus-visible .pickThumb__img { border-color: var(--aqua); box-shadow: var(--ring); }
.pickThumb__label {
  font-size: .6rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase;
  color: var(--muted); line-height: 1;
}
@keyframes thumbPop { from { opacity: 0; transform: scale(.55); } to { opacity: 1; transform: scale(1); } }
.pickThumb.is-new { animation: thumbPop .3s var(--ease) both; }
@media (prefers-reduced-motion: reduce) {
  .pickThumb.is-new { animation: none; }
  .pickThumb:hover .pickThumb__img { transform: none; }
}
.btn--aqua:disabled { background: var(--line); color: var(--muted); box-shadow: none; cursor: not-allowed; transform: none; }
.btn--ghost-navy { background: #fff; color: var(--navy); border-color: var(--line); }
.btn--ghost-navy:hover { border-color: var(--navy); background: var(--tint); transform: translateY(-2px); }

/* Mobile: a tidy 2-row action bar — full-width primary "Next" with Back + Skip
   on the row above. The live status text is dropped here (the chosen swatch
   already shows a check + ring, and the pick is echoed on the review step),
   so the bar stays slim instead of swallowing a third of the screen. */
@media (max-width: 560px) {
  .stepbar__inner { justify-content: center; gap: .4rem .9rem; padding-top: .7rem; padding-bottom: .7rem; }
  .stepbar__pick { display: none; }
  .stepbar .btn--ghost-navy { order: 0; flex: 0 1 auto; padding-left: .9rem; padding-right: .9rem; }
  .stepbar__skip { order: 1; padding: .45rem .25rem; white-space: nowrap; }
  .stepbar .btn--aqua { order: 2; flex: 1 1 100%; font-size: .98rem; }
  /* Thumbs stay on mobile even though the "Selected:" text is hidden — they're the only pick feedback left */
  .stepbar__strip { order: 0; gap: .35rem; }
  .pickThumb__img { width: 36px; height: 36px; }
}

/* ---------- Step 3: review ---------- */
.review { max-width: 900px; margin: 0 auto 2.4rem; }

/* Side-by-side choice cards */
.review__cards { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
@media (max-width: 520px) { .review__cards { grid-template-columns: 1fr; } }
.pickCard {
  position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: .7rem;
}
.pickCard__tag {
  font-family: var(--font-head); font-weight: 600; font-size: .74rem; text-transform: uppercase;
  letter-spacing: .06em; color: var(--aqua-700);
}
.pickCard__img { aspect-ratio: 16/10; border-radius: var(--radius-sm); overflow: hidden; background: linear-gradient(140deg, var(--aqua-700), var(--navy)); }
.pickCard__img img { width: 100%; height: 100%; object-fit: cover; }
.pickCard__meta { display: flex; flex-direction: column; }
.pickCard__meta strong { font-family: var(--font-head); font-size: 1.05rem; color: var(--ink); }
.pickCard__sub { font-size: .84rem; color: var(--muted); }
.pickCard__change {
  align-self: flex-start; margin-top: auto; background: none; border: 0; cursor: pointer;
  color: var(--aqua-700); font-family: var(--font-head); font-weight: 600; font-size: .85rem;
  padding: .2rem 0; text-decoration: underline;
}
.pickCard__change:hover { color: var(--navy); }

/* ---------- Step 3: form ---------- */
.studioForm {
  max-width: 760px; margin: 0 auto; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: clamp(1.3rem, 4vw, 2.2rem); box-shadow: var(--shadow);
}
.studioForm__title { font-size: 1.3rem; text-align: center; margin-bottom: 1.3rem; }
.studioForm__grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .studioForm__grid { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: .35rem; }
.field--full { grid-column: 1 / -1; }
.field span { font-family: var(--font-head); font-weight: 600; font-size: .88rem; color: var(--ink); }
.field span i { color: #e0564f; font-style: normal; }
.field input, .field textarea {
  font-family: var(--font-body); font-size: 1rem; color: var(--ink);
  padding: .75rem .9rem; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--tint-2); transition: border-color .2s, box-shadow .2s; width: 100%;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--aqua); box-shadow: var(--ring); background: #fff; }
.field textarea { resize: vertical; }
.field .is-invalid, .field input.is-invalid, .field textarea.is-invalid { border-color: #e0564f; background: #fff5f5; }

.studioForm__foot {
  display: flex; align-items: center; justify-content: space-between; gap: .8rem;
  margin-top: 1.5rem; flex-wrap: wrap;
}
.studioForm__foot .btn { flex: 1 1 auto; }
.studioForm__note { margin: 1rem 0 0; padding: .8rem 1rem; border-radius: var(--radius-sm); font-weight: 600; display: none; }
.studioForm__note.is-ok { display: block; background: #e9f9ef; color: #1c7a44; border: 1px solid #b7e6c8; }
.studioForm__note.is-err { display: block; background: #fdeeee; color: #b23b34; border: 1px solid #f3c9c6; }
.studioForm__fine { margin: 1rem 0 0; text-align: center; font-size: .8rem; color: var(--muted); }

/* ---------- Skip link (in sticky step footer) ---------- */
.stepbar__skip {
  flex: 0 0 auto; background: none; border: 0; cursor: pointer;
  font-family: var(--font-head); font-weight: 600; font-size: .88rem;
  color: var(--muted); text-decoration: underline; padding: .5rem .4rem;
  transition: color .2s;
}
.stepbar__skip:hover { color: var(--navy); }
.stepbar__skip:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }

/* ---------- Step 3: decking type choice ---------- */
.deckChoice { max-width: 880px; margin: 0 auto; }
.deckOptions { display: grid; gap: 1.3rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 680px) { .deckOptions { grid-template-columns: 1fr; } }

.deckOption {
  display: flex; flex-direction: column; text-align: left; cursor: pointer; padding: 0;
  background: #fff; border: 2px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow);
  transition: border-color .2s, box-shadow .2s, transform .15s;
}
.deckOption:hover { transform: translateY(-4px); border-color: var(--aqua); }
.deckOption:focus-visible { outline: none; box-shadow: var(--ring); }
.deckOption__img {
  display: grid; place-items: center; width: 100%; aspect-ratio: 16 / 9;
  background-size: cover; background-position: center; position: relative;
}
.deckOption__img--pavers {
  background-image: url("https://www.tremron.com/images/colors/pavers/full/olde_towne_autumn_blend.jpg");
}
.deckOption__img--spray { background: linear-gradient(135deg, var(--aqua-700), var(--navy)); }
.deckOption__img--spray::after {
  content: "Coming soon"; font-family: var(--font-head); font-weight: 700;
  font-size: .8rem; letter-spacing: .04em; text-transform: uppercase; color: #fff;
  background: rgba(0,0,0,.28); border: 1px solid rgba(255,255,255,.4);
  padding: .4rem 1rem; border-radius: 999px;
}
.deckOption__body { padding: 1.1rem 1.2rem 1.3rem; display: flex; flex-direction: column; gap: .55rem; }
.deckOption__name { font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; color: var(--ink); }
.deckOption__desc { font-size: .9rem; color: var(--muted); line-height: 1.55; }
.deckOption__go { margin-top: .15rem; font-family: var(--font-head); font-weight: 600; font-size: .92rem; color: var(--aqua-700); transition: color .2s; }
.deckOption:hover .deckOption__go { color: var(--navy); }

/* ---------- Step 3: paver / spray sub-panels ---------- */
.deckPanel { margin-top: .3rem; }
.deckBack {
  background: none; border: 0; cursor: pointer; color: var(--aqua-700);
  font-family: var(--font-head); font-weight: 600; font-size: .9rem;
  padding: .3rem .2rem; margin-bottom: 1.1rem; display: inline-flex; transition: color .2s;
}
.deckBack:hover { color: var(--navy); }
.deckBack:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--radius-sm); }

/* Paver swatch photos sit on a neutral tile so any load gap looks intentional */
.swatch--paver .swatch__img { background: #eef3f8; }

.deckPlaceholder {
  max-width: 620px; margin: 1rem auto 0; text-align: center;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(1.5rem, 5vw, 2.6rem); box-shadow: var(--shadow);
}
.deckPlaceholder__title { font-size: 1.5rem; margin-bottom: .7rem; }
.deckPlaceholder__lead { color: var(--muted); margin: 0 auto .9rem; max-width: 48ch; }
.deckPlaceholder .btn { margin-top: .6rem; }

/* ---------- Review: skipped / empty pick cards ---------- */
.pickCard--empty .pickCard__img {
  background: var(--tint); border: 1px dashed var(--line);
}
.pickCard--empty .pickCard__meta strong { color: var(--muted); }
