/* Renovation cost guide (from the reuse library: builders/renovation-cost-guide and builders/bathroom-cost-guide).
   Each choice is a tile; the chosen one gets a eucalypt edge. Uses the site's --ink, --gum, --pencil, --line,
   --card, --head and --body tokens, with fallbacks so it can be lifted into another site. */
.est { display: grid; gap: 22px; align-items: start; }
@media (min-width: 980px) { .est { grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 40px; } .est-result { position: sticky; top: calc(var(--head-h, 76px) + 20px); } }
.est-form { display: grid; gap: 14px; min-width: 0; }
.est-form fieldset { margin: 0; padding: 20px 18px 18px; background: var(--card, #fff); border: 1px solid var(--line, #dcdbd2); border-radius: 20px; min-width: 0; }
.est-form fieldset[hidden] { display: none; }
.est-form legend { float: left; width: 100%; display: flex; align-items: center; gap: 10px; margin: 0 0 14px; padding: 0; font: 650 1.15rem/1.2 var(--head, sans-serif); letter-spacing: -.01em; }
.est-form legend + * { clear: both; }
.est-form .step { width: 30px; height: 30px; flex: none; border-radius: 9px; display: grid; place-items: center; background: var(--ink, #15232a); color: #fff; font: 700 .9rem/1 var(--head, sans-serif); }
.est-form .why { margin: -4px 0 12px; clear: both; font-size: .92rem; color: var(--ink-3, #56646a); }
.opts { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
@media (min-width: 600px) { .opts.three { grid-template-columns: repeat(3, 1fr); } .opts.four { grid-template-columns: repeat(4, 1fr); } }
.opts.extras { grid-template-columns: 1fr; }
@media (min-width: 600px) { .opts.extras { grid-template-columns: 1fr 1fr; } }
.opt { position: relative; display: block; cursor: pointer; }
.opt[hidden] { display: none; }
.opt input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.opt > span { display: flex; flex-direction: column; justify-content: center; gap: 3px; min-height: 64px; height: 100%; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line-2, #c7c8bd); background: #fbfbf8; font-weight: 650; line-height: 1.25; transition: border-color .15s, background-color .15s, box-shadow .15s; }
.opt small { font-weight: 400; color: var(--ink-3, #56646a); font-size: .86rem; line-height: 1.3; }
.opt .oi { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.opt .oi svg { width: 30px; height: 30px; flex: none; color: var(--gum, #2c5a4e); }
.opt:hover > span { border-color: var(--gum, #2c5a4e); }
.opt input:checked + span { border-color: var(--gum, #2c5a4e); background: var(--gum-ll, #eef4f0); box-shadow: inset 0 0 0 1.5px var(--gum, #2c5a4e); }
.opt input:checked + span .oi svg { color: var(--pencil-d, #b3511b); }
.opt input:focus-visible + span { outline: 3px solid var(--pencil-d, #b3511b); outline-offset: 2px; }
.opts.extras .opt > span { flex-direction: row; align-items: center; justify-content: flex-start; gap: 12px; min-height: 56px; }
.opts.extras .opt > span::before { content: ""; width: 22px; height: 22px; flex: none; border-radius: 7px; border: 2px solid #a2aba3; background: #fff center / 14px no-repeat; }
.opts.extras .opt input:checked + span::before { border-color: var(--gum, #2c5a4e); background-color: var(--gum, #2c5a4e); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E"); }
.opts.extras .opt em { margin-left: auto; font-style: normal; font-size: .82rem; color: var(--ink-3, #56646a); font-weight: 600; white-space: nowrap; }

/* The result card */
.est-result { background: var(--card, #fff); border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg, 0 30px 60px -30px rgb(0 0 0 / .4)); border: 1px solid var(--line, #dcdbd2); scroll-margin-top: calc(var(--head-h, 64px) + 16px); }
.est-result .thumb { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--paper-2, #ebeae2); }
.est-result .thumb img { width: 100%; height: 100%; object-fit: cover; }
.est-result .thumb .ill-tag { position: absolute; left: 12px; bottom: 12px; background: rgb(255 255 255 / .88); }
@media (prefers-reduced-motion: no-preference) { .est-result .thumb img.swap { animation: est-swap .45s ease; } }
@keyframes est-swap { from { opacity: .25; transform: scale(1.03); } to { opacity: 1; transform: none; } }
.est-result .inner { padding: 22px 22px 24px; }
.demo-flag { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 10px; padding: 5px 10px; border-radius: 999px; background: var(--pencil-l, #fdebdc); color: #6b2f0c; font: 700 .72rem/1.2 var(--head, sans-serif); letter-spacing: .1em; text-transform: uppercase; }
.est-result h2 { font-size: 1.25rem; margin: 0 0 .2em; }
.est-title { margin: 0 0 6px; font-size: .94rem; color: var(--ink-3, #56646a); }
.est-range { margin: 0 0 14px; font: 700 clamp(2rem, 7vw, 2.6rem)/1.05 var(--head, sans-serif); letter-spacing: -.035em; color: var(--ink, #15232a); font-variant-numeric: tabular-nums; }
/* The meter is a tape: marks every fifth of the way, and the job's range as a band of pencil. */
.meter { position: relative; height: 14px; border-radius: 4px; background: repeating-linear-gradient(90deg, rgb(21 35 42 / .5) 0 1px, transparent 1px 10%) 0 0 / 100% 55% no-repeat, linear-gradient(#ffe7a3, #f6cf62); border: 1px solid #d9b345; }
.meter i { position: absolute; top: -4px; bottom: -4px; left: 30%; width: 20%; border-radius: 6px; background: var(--gum, #2c5a4e); box-shadow: 0 2px 8px rgb(18 41 31 / .45); transition: left .35s cubic-bezier(.2, .7, .2, 1), width .35s cubic-bezier(.2, .7, .2, 1); }
.meter-scale { display: flex; justify-content: space-between; margin: 7px 0 16px; font-size: .8rem; color: var(--ink-3, #56646a); }
.est-lines { list-style: none; margin: 0 0 14px; padding: 0; border-top: 1px solid var(--line, #dcdbd2); }
.est-lines li { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px solid var(--line, #dcdbd2); font-size: .95rem; }
.est-lines li span:last-child { font-weight: 650; white-space: nowrap; font-variant-numeric: tabular-nums; }
.est-notes p { margin: 0 0 10px; padding: 11px 13px; border-radius: 12px; font-size: .92rem; line-height: 1.45; }
.est-notes p[hidden] { display: none; }
.est-notes .n-warn { background: #fbece2; color: #6b2c14; }
.est-notes .n-good { background: var(--gum-ll, #eef4f0); color: var(--gum-d, #1d4037); }
.est-result .btn { width: 100%; }
.est-note { margin: 12px 0 0; font-size: .86rem; color: var(--ink-3, #56646a); }

/* Phones: the live price floats above the call bar while people choose. */
.est-live { display: none; }
@media (max-width: 979px) {
  .est-ready .est-live { position: sticky; bottom: 84px; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 4px; padding: 10px 10px 10px 18px; border-radius: 16px; background: var(--ink, #15232a); color: #fff; box-shadow: 0 14px 30px -12px rgb(21 35 42 / .6); transition: opacity .25s, transform .25s; }
  .est-live small { display: block; font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: #a9bdb5; }
  .est-live b { font: 700 1.15rem/1.1 var(--head, sans-serif); font-variant-numeric: tabular-nums; }
  .est-live a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 14px; border-radius: 12px; background: var(--pencil, #f28c3b); color: var(--ink, #15232a); font: 650 .95rem/1 var(--head, sans-serif); text-decoration: none; white-space: nowrap; }
  .est-live.gone { opacity: 0; transform: translateY(12px); pointer-events: none; }
}
@media (min-width: 761px) and (max-width: 979px) { .est-ready .est-live { bottom: 16px; } }

/* The small version on the home page */
.est-mini { display: grid; gap: 24px; align-items: center; }
@media (min-width: 980px) { .est-mini { grid-template-columns: 1.05fr .95fr; gap: 52px; } }
.est-mini .est-form fieldset { background: transparent; border: 0; padding: 0; }
.est-mini .mini-result { position: relative; overflow: hidden; background: var(--ink, #15232a); color: #fff; border-radius: 24px; padding: 26px 24px; display: grid; gap: 10px; }
.est-mini .mini-result::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 12px; background: repeating-linear-gradient(90deg, rgb(21 35 42 / .75) 0 1px, transparent 1px 10px) 0 0 / 100% 45% no-repeat, repeating-linear-gradient(90deg, rgb(21 35 42 / .85) 0 1.5px, transparent 1.5px 50px) 0 0 / 100% 75% no-repeat, linear-gradient(#ffd46b, #f5bd2d 45%, #dca318); }
.est-mini .mini-result .est-range { color: #fff; margin: 0; font-size: clamp(2.1rem, 8vw, 2.9rem); }
.est-mini .mini-result p { margin: 0; color: #c3cfca; font-size: .95rem; }
.est-mini .mini-result .demo-flag { justify-self: start; margin: 8px 0 0; }
.est-mini .mini-result .btn-row { margin-top: 10px; }
/* The size question stays three across, even on a phone. */
.opts.tri { grid-template-columns: repeat(3, 1fr); gap: 8px; }
@media (max-width: 599px) { .opts.tri .opt > span { padding: 10px 10px; font-size: .98rem; } .opts.tri .opt small { font-size: .8rem; } }
