/* ==========================================================================
   homeowner-program.html — page-local styles ("90-Day Ring")
   Loads AFTER css/styles.css. Tokens only: white / black / silver.
   ========================================================================== */

/* ---- hero: the founder standing on a vault panel (a black card with a chrome bezel) ---- */
@media (min-width: 1101px) { .hp-hero .hero-grid { grid-template-columns: 1.02fr .98fr; } }
.hero-figure-wrap { display: flex; justify-content: center; perspective: 1400px; }
.hero-figure {
  position: relative;
  width: min(100%, 470px);
  aspect-ratio: 4 / 4.6;
  border-radius: 22px;
  background: var(--card-face);
  overflow: hidden;
  box-shadow: 0 40px 80px -30px rgba(10,10,11,.55);
  transform: rotateX(calc(var(--my, 0) * -5deg)) rotateY(calc(var(--mx, 0) * 5deg));
  transition: transform .15s ease-out;
}
.hero-figure .iu-rim, .hero-figure .iu-brush { position: absolute; }
.hero-figure .iu-brush { opacity: .3; }
.hero-figure .team-spot { top: 30%; }
.hero-figure img { position: absolute; left: -8%; right: -8%; bottom: -3%; margin: 0 auto; width: 116%; max-width: none; height: auto; z-index: 1; }
.hero-figure::after { content: ''; position: absolute; left: 8%; right: 8%; bottom: 0; height: 1px; background: var(--chrome-edge); opacity: .7; z-index: 2; }
.figure-tag {
  position: absolute; top: 22px; left: 24px; z-index: 2;
  font-family: var(--font-display); font-variation-settings: 'wdth' 110, 'wght' 600;
  font-size: .68rem; letter-spacing: .22em; text-transform: uppercase; line-height: 1.5;
  color: #DDDFE3; text-shadow: 0 1px 0 rgba(255,255,255,.2), 0 -1px 0 rgba(0,0,0,.9);
}
.figure-tag span { display: block; font-family: var(--font-mono); font-variation-settings: normal; font-weight: 500; font-size: .62rem; color: #8E9199; text-shadow: none; }
.figure-chip { position: absolute; left: 24px; bottom: 24px; z-index: 3; }
.figure-chip .mono { font-weight: 700; }

/* ---- the 90-day ring (vault) ---- */
.ring-grid { display: grid; grid-template-columns: 1.08fr .92fr; gap: clamp(40px, 6vw, 88px); align-items: center; }
.ring-stage { display: grid; justify-items: center; padding: 24px clamp(28px, 4vw, 56px); }
.ring-box { position: relative; width: min(100%, clamp(300px, 40vw, 520px)); container-type: inline-size; }
.score.days { width: 100%; }
/* 90 ticks — the tick layer is an un-rotated overlay so each tick's angle is absolute (135° + 3°·i) */
.ring-ticks { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.ring-ticks line { stroke: #FFFFFF; stroke-width: 1.5; stroke-linecap: round; opacity: .14; transition: opacity .35s var(--ease-out); transition-delay: var(--d, 0ms); }
.ring-ticks line.major { stroke-width: 2.4; opacity: .28; }
.score.days.in .ring-ticks line, html:not(.js) .ring-ticks line { opacity: 1; }
/* centre: DAY / 90 / denied to approved */
.score.days .score-center { gap: 0; padding-bottom: 8cqw; }
.score.days .score-center .mono-label { font-size: 3.1cqw; letter-spacing: .3em; color: #8E9199; }
.score.days .score-num { font-size: 30cqw; letter-spacing: -.05em; margin-top: .5cqw; }
.score.days .score-word { font-size: 6.2cqw; color: #C9CCD2; margin-top: 1.4cqw; }
/* the guarantee seal sits in the gauge's open bottom wedge and rotates beside the fill */
.score.days .seal { top: auto; right: auto; left: 50%; bottom: 0; width: 27cqw; height: 27cqw; margin-left: -13.5cqw; }
.score.days .seal svg text { fill: #B9BCC3; }
.score.days .seal .seal-mono { fill: #FFFFFF; }
/* phase labels at the four corners of the gauge; each brightens as the fill passes it */
.phases { position: absolute; inset: 0; pointer-events: none; }
.phase {
  position: absolute; z-index: 2;
  font-family: var(--font-mono); font-weight: 500;
  font-size: max(10px, 2.6cqw); letter-spacing: .2em; text-transform: uppercase; line-height: 1.4;
  color: #8E9199; white-space: nowrap;
  opacity: .32;
  transition: opacity .5s var(--ease-out); transition-delay: var(--d, 0ms);
}
.phase strong { display: block; font-family: var(--font-display); font-variation-settings: 'wdth' 112, 'wght' 700; font-size: 1.45em; letter-spacing: -.01em; text-transform: none; color: #FFFFFF; }
.ring-box:has(.score.in) .phase, html:not(.js) .phase { opacity: 1; }
.phase-1 { right: 87%; top: 86%; text-align: right; --d: 60ms; }
.phase-2 { right: 87%; bottom: 87%; text-align: right; --d: 180ms; }
.phase-3 { left: 87%; bottom: 87%; text-align: left; --d: 420ms; }
/* the end marker stamps in as a chrome pill when the fill completes */
.phase-end { left: 86%; top: 86%; opacity: 0; transform: scale(.8); transform-origin: left top; transition: transform .5s var(--ease-spring), opacity .3s; --d: 0ms; }
.ring-box:has(.score.is-done) .phase-end, html:not(.js) .phase-end { opacity: 1; transform: scale(1); }
/* program copy beside the ring */
.ring-copy .sec-head { margin-bottom: 26px; }
.ring-copy .checklist { margin-top: 26px; }
.ring-copy .checklist strong { color: #FFFFFF; }
.ring-copy .checklist li { padding: 13px 0; }
.ring-note { margin-top: 22px; font-size: .8rem; color: #8E9199; }

/* ---- the path: four steps on the rail (system .steps-ledger) ---- */
.path-cta { margin-top: 48px; }

/* ---- the story (mist): two chapters as numbered paper cards ---- */
.story-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.chapter { display: flex; flex-direction: column; min-height: 300px; padding: 34px 36px 36px; }
.chapter .mono-label { color: #26272B; }
.chapter .chapter-n { font-family: var(--font-mono); font-weight: 700; font-size: 2.6rem; line-height: 1; letter-spacing: -.03em; color: #C9CCD2; margin: 28px 0 auto; transition: color .3s; }
.chapter:hover .chapter-n { color: #0A0A0B; }
.chapter h3 { font-size: clamp(1.3rem, 1.9vw, 1.6rem); margin: 40px 0 12px; }
.chapter p { font-size: .95rem; line-height: 1.6; max-width: 42ch; }

/* ---- responsive ---- */
@media (max-width: 1100px) {
  .ring-grid { grid-template-columns: 1fr; gap: 48px; }
  .ring-copy { max-width: 640px; margin: 0 auto; }
  .hero-figure { width: min(100%, 440px); }
}
@media (max-width: 900px) {
  .story-grid { grid-template-columns: 1fr; }
  .chapter { min-height: 0; }
  .chapter h3 { margin-top: 26px; }
}
@media (max-width: 640px) {
  .ring-stage { padding: 0; }
  .ring-box { width: 100%; }
  .phases { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; margin-top: 26px; padding-top: 22px; border-top: 1px solid #26272B; }
  .phase { position: static; text-align: left; white-space: normal; font-size: .62rem; }
  .phase-1, .phase-2, .phase-3 { text-align: left; }
  .phase-end { transform-origin: left center; }
  .hero-figure { width: 100%; aspect-ratio: 4 / 4.4; }
  .hero-figure img { width: 100%; left: 0; right: 0; bottom: -2%; }
  .figure-tag { font-size: .6rem; }
  .figure-tag { top: 16px; left: 18px; }
  .figure-chip { left: 18px; bottom: 18px; }
  .chapter { padding: 26px 22px 28px; }
}
