/* Transformation map, navigator entry, ROI calculator, quickpick, finale.
   Home-page-specific layout that shouldn't weigh down core.css. */

/* ---------- Navigator entry ---------- */
.nav-entry {
  display: grid; grid-template-columns: 1.35fr .65fr;
  gap: clamp(28px, 4vw, 60px);
  padding: clamp(28px, 3.6vw, 52px);
  align-items: center;
  background:
    radial-gradient(90% 130% at 100% 0%, rgba(227,184,92,.10), transparent 62%),
    linear-gradient(160deg, rgba(255,255,255,.05), rgba(255,255,255,.012));
}
@media (max-width: 900px) { .nav-entry { grid-template-columns: 1fr; } }
.nav-entry__go {
  border-left: 1px solid var(--line);
  padding-left: clamp(24px, 3vw, 40px);
}
@media (max-width: 900px) { .nav-entry__go { border-left: 0; border-top: 1px solid var(--line); padding: 30px 0 0; } }

.quickpick { display: flex; flex-wrap: wrap; gap: 8px; }
.quickpick button {
  padding: 9px 14px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255,255,255,.03);
  font-size: 12px; color: var(--mute); cursor: pointer;
  transition: border-color .28s, color .28s, background .28s, transform .28s var(--ease);
}
.quickpick button:hover { border-color: rgba(59,224,206,.5); color: var(--teal); transform: translateY(-1px); }
.quickpick button[aria-pressed="true"] {
  border-color: var(--gold); color: var(--gold);
  background: rgba(227,184,92,.12);
}

/* ---------- Transformation map ---------- */
.tmap { margin: 0; position: relative; }
.tmap__svg { width: 100%; height: auto; display: block; overflow: visible; }

.tm-edges .ed {
  stroke: url(#edgeG); stroke-width: 1.2;
  stroke-dasharray: var(--len, 900); stroke-dashoffset: var(--len, 900);
  opacity: .35;
  transition: stroke-dashoffset 1.05s var(--ease), opacity .7s;
}
.tmap.lit-1 .ed[data-tier="1"], .tmap.lit-2 .ed[data-tier="2"],
.tmap.lit-3 .ed[data-tier="3"], .tmap.lit-4 .ed[data-tier="4"] {
  stroke-dashoffset: 0; opacity: 1;
}

.nd rect {
  fill: rgba(255,255,255,.028);
  stroke: rgba(255,255,255,.13);
  stroke-width: 1;
  transition: fill .7s var(--ease), stroke .7s var(--ease);
}
.nd text {
  fill: var(--mute); font-family: var(--sans); font-size: 14px; font-weight: 600;
  letter-spacing: .16em; text-anchor: middle; transition: fill .7s var(--ease);
}
.nd .t-lg { font-size: 17px; letter-spacing: .2em; }
.nd .t-sm { font-size: 11.5px; letter-spacing: .17em; }
.nd { opacity: .34; transform: translateY(9px); transition: opacity .8s var(--ease), transform .8s var(--ease); }

.tmap.lit-0 .nd[data-tier="0"], .tmap.lit-1 .nd[data-tier="1"],
.tmap.lit-2 .nd[data-tier="2"], .tmap.lit-3 .nd[data-tier="3"],
.tmap.lit-4 .nd[data-tier="4"] { opacity: 1; transform: none; }

.tmap.lit-0 .nd[data-tier="0"] rect,
.tmap.lit-1 .nd[data-tier="1"] rect,
.tmap.lit-2 .nd[data-tier="2"] rect { fill: rgba(59,224,206,.09); stroke: rgba(59,224,206,.45); }
.tmap.lit-0 .nd[data-tier="0"] text,
.tmap.lit-1 .nd[data-tier="1"] text,
.tmap.lit-2 .nd[data-tier="2"] text { fill: var(--white); }

.tmap.lit-4 .nd--out rect { fill: rgba(59,224,206,.09); stroke: rgba(59,224,206,.45); }
.tmap.lit-4 .nd--out text { fill: var(--white); }

.nd--ai rect { fill: rgba(227,184,92,.06); stroke: rgba(227,184,92,.3); }
.tmap.lit-3 .nd--ai rect {
  fill: rgba(227,184,92,.16); stroke: url(#aiG); stroke-width: 1.5;
  filter: url(#soft);
}
.tmap.lit-3 .nd--ai .t-ai { fill: var(--gold-soft); }

.tm-signals circle { fill: var(--teal); opacity: 0; }
.tmap.lit-4 .tm-signals circle { opacity: .9; }

/* ---------- ROI calculator ---------- */
/* minmax(0,1fr), not 1fr: a bare 1fr track cannot shrink below its min-content,
   and the min-content here is the un-wrappable dollar figure plus its padding —
   which pushed the panel wider than the viewport on a phone. */
.roi { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr); gap: 0; overflow: hidden; }
@media (max-width: 880px) { .roi { grid-template-columns: minmax(0,1fr); } }
.roi__inputs { padding: clamp(26px, 3.2vw, 44px); }
.roi__out {
  padding: clamp(26px, 3.2vw, 44px); text-align: center;
  border-left: 1px solid var(--line);
  background:
    radial-gradient(80% 100% at 50% 0%, rgba(227,184,92,.13), transparent 62%),
    rgba(255,255,255,.02);
  display: flex; flex-direction: column; justify-content: center;
}
@media (max-width: 880px) { .roi__out { border-left: 0; border-top: 1px solid var(--line); } }

.roi__row { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; align-items: center; margin-bottom: 30px; }
.roi__row > span { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--mute-2); grid-column: 1 / -1; }
.roi__row output {
  font-family: var(--display); font-size: 26px; color: var(--gold);
  min-width: 76px; text-align: right; line-height: 1;
}
.roi__row input[type=range] {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 3px; border-radius: 3px; background: rgba(255,255,255,.14);
  outline: none; cursor: pointer;
}
.roi__row input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 20px; height: 20px; border-radius: 50%;
  background: linear-gradient(140deg, var(--gold-soft), var(--gold-deep));
  border: 2px solid var(--ink); cursor: grab;
  box-shadow: 0 3px 12px -3px rgba(227,184,92,.85);
}
.roi__row input[type=range]::-moz-range-thumb {
  width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--ink);
  background: linear-gradient(140deg, var(--gold-soft), var(--gold-deep));
  box-shadow: 0 3px 12px -3px rgba(227,184,92,.85); cursor: grab;
}
.roi__row input[type=range]:focus-visible { outline: 2px solid var(--teal); outline-offset: 5px; }

.roi__big {
  font-family: var(--display);
  /* the lower bound has to fit a seven-figure result inside a 375px screen */
  font-size: clamp(34px, 7vw, 84px); line-height: 1;
  background: linear-gradient(120deg, var(--gold-soft), var(--gold) 42%, var(--gold-deep));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.roi__sub { display: flex; gap: 34px; justify-content: center; margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--line-2); }
.roi__sv { display: block; font-family: var(--display); font-size: 28px; color: var(--white); line-height: 1; }
.roi__sl { display: block; font-size: 10px; letter-spacing: .17em; text-transform: uppercase; color: var(--mute-2); margin-top: 8px; }

/* ---------- Finale ---------- */
.finale {
  background:
    radial-gradient(70% 110% at 50% 110%, rgba(227,184,92,.13), transparent 60%),
    radial-gradient(60% 90% at 50% 0%, rgba(59,224,206,.07), transparent 60%);
}
