/* Dormer REPS hours guide: "quiet blueprint" (owner-approved V2, 2026-10-31).
   Approved comp: AgentScratch/altai/2026-11-01/reps-guide-design/v2/index.html.
   Reading text sits on flat light surfaces only; the drafting grid appears only inside
   the house plate, which holds no text. One drawing (the house), one 2px blueprint line.
   Type: Fraunces (display, 28px and up) and Inter. Colours: Dormer 2.0 brand system.
   Loads after subpages.css. The .sp-guide-link block at the end serves /products/dormer/. */

body.rg-page {
  --bp: #1e3fa6;
  --bp-ink: #1e3fa6;
  --tx: #121b33;
  --tx2: #4a5068;
  --tx3: #5f6983;
  --line: #d5dbea;
  --wash: #e3e9fa;
  --cv: #eef2fa;
  --pos: #137a42;
  --neg: #c1303a;
  --ground: #fbfbfd;
  background: var(--ground);
  color: var(--tx);
}
html:has(body.rg-page) { background: var(--ground, #fbfbfd); }
.rg-page main { background: transparent; }
.rg-page .sp-grain { display: none; }
.rg-page ::selection { background: var(--wash); color: var(--tx); }
.rg-page main a { color: var(--bp); text-underline-offset: 3px; text-decoration-thickness: 1px; }
.rg-page main a:focus-visible,
.rg-page summary:focus-visible { outline: 2px solid var(--bp); outline-offset: 3px; border-radius: 4px; }
.rg-tnum { font-variant-numeric: tabular-nums lining-nums; }

.rg-w { width: min(1120px, calc(100vw - 40px)); margin-inline: auto; }

/* ---------- drawing (one style: 2px blueprint line, brand fills, no text) ---------- */
.rg-art .ln { fill: none; stroke: #1e3fa6; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.rg-art .dash { fill: none; stroke: #1e3fa6; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-dasharray: 5 6; stroke-linejoin: round; stroke-linecap: round; }
.rg-art .ln *, .rg-art .dash * { vector-effect: non-scaling-stroke; }
.rg-plate {
  display: grid;
  place-items: center;
  border-radius: 16px;
  background-color: var(--cv);
  background-image:
    linear-gradient(rgba(30, 63, 166, 0.075) 1px, transparent 1px),
    linear-gradient(90deg, rgba(30, 63, 166, 0.075) 1px, transparent 1px);
  background-size: 20px 20px;
  background-position: -1px -1px;
}
.rg-plate svg { display: block; width: 100%; height: auto; }
.rg-house-clip,
.rg-house-level {
  transform-box: view-box;
  transition: transform 520ms var(--sp-ease-out, cubic-bezier(0.16, 1, 0.3, 1));
}
.rg-house-clip { transform-origin: 0 250px; }

/* ---------- hero: headline, calculator, result ---------- */
.rg-hero { padding: 140px 0 112px; }
.rg-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  grid-template-areas: "head fig" "form fig" "fine fig";
  grid-template-rows: auto auto 1fr;
  column-gap: 72px;
  align-items: start;
}
.rg-head { grid-area: head; }
.rg-form { grid-area: form; }
.rg-figure { grid-area: fig; }
.rg-hero .rg-fine { grid-area: fine; }

.sp-page .rg-crumb { margin: 0; font: 500 15px/1.4 "Inter", sans-serif; color: var(--tx2); }
.sp-page .rg-crumb a { color: var(--bp); text-decoration: none; font-weight: 600; }
.sp-page .rg-h1 {
  margin: 18px 0 0;
  max-width: 12ch;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 400;
  font-size: clamp(40px, 6vw, 80px);
  line-height: 0.98;
  letter-spacing: -0.008em;
  color: var(--tx);
}
.sp-page .rg-lead { margin: 22px 0 0; max-width: 30ch; font: 400 21px/1.5 "Inter", sans-serif; color: var(--tx2); }

.rg-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px 16px;
  max-width: 480px;
  margin-top: 44px;
}
.rg-field { margin: 0; padding: 0; border: 0; min-width: 0; }
.rg-field[hidden] { display: none; }
.rg-field--wide, .rg-form .rg-hint, .rg-form .rg-error { grid-column: 1 / -1; }
.rg-lab { display: block; padding: 0; margin: 0 0 8px; font: 500 14px/1.3 "Inter", sans-serif; color: var(--tx2); }
.rg-form input[type="number"],
.rg-form input[type="date"] {
  display: block;
  box-sizing: border-box;
  width: 100%;
  height: 52px;
  padding: 0 16px;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font: 500 18px/1 "Inter", sans-serif;
  color: var(--tx);
  -webkit-appearance: none;
  appearance: none;
}
.rg-form input[type="number"]::-webkit-inner-spin-button,
.rg-form input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.rg-form input[type="number"] { -moz-appearance: textfield; }
.rg-form input::-webkit-calendar-picker-indicator { opacity: 0.55; cursor: pointer; }
.rg-form input:focus-visible { outline: 2px solid var(--bp); outline-offset: 1px; border-color: var(--bp); }
.rg-form input[aria-invalid="true"] { border-color: var(--neg); }

.rg-seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 4px; border-radius: 999px; background: var(--cv); }
.rg-seg label { position: relative; cursor: pointer; }
.rg-seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.rg-seg span {
  display: block;
  padding: 10px 0;
  border-radius: 999px;
  text-align: center;
  font: 600 17px/1 "Inter", sans-serif;
  color: var(--bp);
  transition: background-color 160ms ease-out, color 160ms ease-out;
}
.rg-seg input:checked + span { background: var(--bp); color: #fff; }
.rg-seg input:focus-visible + span { outline: 2px solid var(--bp); outline-offset: 2px; }
.sp-page .rg-hint { margin: 0; font: 400 15px/1.5 "Inter", sans-serif; color: var(--tx2); }
.sp-page .rg-error { margin: 0; font: 500 15px/1.5 "Inter", sans-serif; color: var(--neg); }
.rg-error[hidden] { display: none; }

.rg-figure .rg-plate { aspect-ratio: 16 / 11; padding: 32px 40px 24px; }
.sp-page .rg-num { display: flex; align-items: baseline; gap: 16px; margin: 32px 0 0; }
.rg-num b {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 400;
  font-size: 112px;
  line-height: 0.85;
  letter-spacing: -0.015em;
  color: var(--bp);
}
.rg-num span { font: 500 20px/1.3 "Inter", sans-serif; color: var(--tx); }
.sp-page .rg-status { margin: 18px 0 22px; max-width: 44ch; font: 400 19px/1.55 "Inter", sans-serif; color: var(--tx); }
.rg-bar { height: 10px; border-radius: 99px; background: var(--wash); overflow: hidden; }
.rg-bar-fill { display: block; height: 100%; width: 0; border-radius: 99px; background: var(--bp); transition: width 520ms var(--sp-ease-out, ease-out); }
.rg-cap { display: flex; justify-content: space-between; gap: 12px; margin-top: 12px; font: 400 15px/1 "Inter", sans-serif; color: var(--tx2); }
.rg-cap b { color: var(--tx); font-weight: 600; }
.rg-facts { display: flex; gap: 40px; margin: 28px 0 0; padding: 0; }
.rg-facts dt { font: 500 15px/1.3 "Inter", sans-serif; color: var(--tx2); }
.rg-facts dd { margin: 4px 0 0; font: 600 26px/1 "Inter", sans-serif; letter-spacing: -0.01em; color: var(--tx); }
.rg-half[hidden] { display: none; }
.sp-page .rg-half p { margin: 24px 0 0; padding-left: 16px; box-shadow: inset 3px 0 0 var(--pos); font: 400 16px/1.5 "Inter", sans-serif; color: var(--tx); }
.rg-half[data-half="no"] p,
.rg-half[data-half="unset"] p { box-shadow: inset 3px 0 0 var(--tx3); }
.rg-result[data-state="empty"] .rg-num b { color: var(--tx3); }
.rg-hcta { display: flex; align-items: center; gap: 18px; margin-top: 32px; }
.rg-hcta span { font: 400 15px/1.4 "Inter", sans-serif; color: var(--tx2); }
.rg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--bp);
  color: #fff;
  font: 600 16px/1 "Inter", sans-serif;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 160ms ease-out, background-color 160ms ease-out;
}
.rg-page main a.rg-btn { color: #fff; text-decoration: none; }
.rg-btn:hover { background: #18348a; }
.rg-btn:active { transform: scale(0.98); }
.sp-page .rg-fine {
  margin: 40px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  max-width: 480px;
  font: 400 14px/1.55 "Inter", sans-serif;
  color: var(--tx2);
}

/* ---------- the rules, in short ---------- */
.rg-rules { padding: 112px 0; background: #fff; }
.sp-page .rg-rules h2,
.sp-page .rg-faq h2 {
  margin: 0;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 400;
  font-size: clamp(36px, 4.4vw, 56px);
  line-height: 1;
  letter-spacing: -0.005em;
  color: var(--tx);
}
.rg-rule-list { display: grid; grid-template-columns: 1fr 1fr; gap: 64px 72px; margin: 56px 0 0; }
.sp-page .rg-rule .rg-key {
  margin: 0;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 400;
  font-size: 64px;
  line-height: 0.9;
  letter-spacing: -0.01em;
  color: var(--bp);
}
.sp-page .rg-rule h3 { margin: 18px 0 0; font: 600 22px/1.3 "Inter", sans-serif; letter-spacing: -0.01em; color: var(--tx); }
.sp-page .rg-rule p:not(.rg-key) { margin: 8px 0 0; max-width: 36ch; font: 400 19px/1.55 "Inter", sans-serif; color: var(--tx2); }

/* ---------- questions and full rules ---------- */
.rg-faq { padding: 120px 0; }
.rg-faq-grid { display: grid; grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr); gap: 72px; align-items: start; }
.sp-page .rg-faq-side p { margin: 18px 0 0; max-width: 26ch; font: 400 18px/1.55 "Inter", sans-serif; color: var(--tx2); }
.rg-accs { border-top: 1px solid var(--line); }
.rg-acc { border-bottom: 1px solid var(--line); }
.rg-acc summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 24px 2px;
  list-style: none;
  cursor: pointer;
  font: 500 20px/1.35 "Inter", sans-serif;
  color: var(--tx);
}
.rg-acc summary::-webkit-details-marker { display: none; }
.rg-chev { width: 20px; height: 20px; flex: none; color: var(--bp); transition: transform 200ms ease-out; }
.rg-acc[open] .rg-chev { transform: rotate(180deg); }
.sp-page .rg-faq h2.rg-sub-h { margin: 64px 0 8px; font: 600 15px/1.3 "Inter", sans-serif; letter-spacing: 0; color: var(--tx2); }
.rg-accs--rules .rg-acc summary { padding: 18px 2px; font-size: 18px; }

.rg-acc-body {
  padding: 2px 2px 22px;
}

.rg-acc-body p,
.rg-acc-body li {
  color: var(--tx2);
  font-size: 1rem;
  line-height: 1.65;
}

.rg-acc-body p {
  margin: 0 0 14px;
}

.rg-acc-body ul {
  margin: 0 0 14px;
  padding-left: 1.2em;
  display: grid;
  gap: 7px;
}

.rg-acc-body li::marker {
  color: var(--bp-ink);
}

.rg-acc-body strong {
  color: var(--tx);
}

.rg-acc-body h3 {
  margin: 22px 0 6px;
  font-family: "Inter", ui-sans-serif, system-ui, sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--tx);
}

.rg-acc-body a {
  position: relative;
  color: var(--bp);
  text-decoration: underline;
  text-decoration-color: rgba(30, 63, 166, 0.4);
  text-underline-offset: 3px;
}

.rg-acc-body a:hover {
  text-decoration-color: var(--bp);
}

.rg-acc-body a:focus-visible {
  outline: 2px solid var(--bp);
  outline-offset: 2px;
  border-radius: 2px;
}

.rg-acc-body a::after {
  content: "";
  position: absolute;
  inset: -13px -4px;
}

.rg-acc-body a.rg-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  color: #fff;
  background: var(--bp);
  text-decoration: none;
}

.rg-acc-body a.rg-cta::after {
  display: none;
}

.rg-table-wrap {
  margin: 18px 0 0;
  overflow-x: auto;
}

.rg-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.rg-table caption {
  caption-side: bottom;
  padding-top: 10px;
  text-align: left;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--tx2);
}

.rg-table th,
.rg-table td {
  padding: 10px 12px 10px 0;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
  line-height: 1.4;
  color: var(--tx2);
}

.rg-table thead th {
  font-size: 0.8rem;
  color: var(--tx);
  border-bottom-color: var(--bp);
}

.rg-table tbody th {
  color: var(--tx);
}

.rg-acc-body ul.rg-cases {
  list-style: none;
  padding: 0;
  gap: 0;
}

.rg-cases li {
  display: grid;
  gap: 4px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.rg-case-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
}

.rg-tag {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 700;
}

.rg-tag--lost { background: #fce4e5; color: #8c1f28; }
.rg-tag--won { background: #e4f7eb; color: #0f6236; }
.rg-tag--doubted { background: #fcf0dc; color: #7c4609; }

.rg-case-text {
  color: var(--tx2);
  font-size: 0.98rem;
  line-height: 1.55;
}

.rg-sources {
  font-size: 0.95rem;
}

.rg-acc-body ul.rg-sources li {
  overflow-wrap: anywhere;
}


/* answer text: comp sizes, full ink */
.rg-acc-body { padding: 0 2px 30px; }
.rg-acc-body > :last-child { margin-bottom: 0; }
.rg-acc-body p, .rg-acc-body li { font-size: 18px; color: var(--tx); max-width: 62ch; }
.rg-acc-body .rg-case-text, .rg-table caption { color: var(--tx2); }

/* ---------- closing band ---------- */
.rg-band { padding: 88px 0; background: var(--bp); color: #fff; }
.rg-band-in { display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.sp-page .rg-band p {
  margin: 0;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 400;
  font-size: clamp(32px, 3.6vw, 46px);
  line-height: 1.05;
  letter-spacing: -0.015em;
  color: #fff;
}
.sp-page .rg-band p span { display: block; margin-top: 12px; font: 400 19px/1.5 "Inter", sans-serif; letter-spacing: 0; color: #e3e9fa; }
.rg-page main a.rg-btn--light { height: 54px; padding: 0 28px; background: #fff; color: var(--bp); font-size: 17px; }
.rg-btn--light:hover { background: #e3e9fa; }

@media (max-width: 860px) {
  .rg-hero { padding: 112px 0 72px; }
  .rg-hero-grid { display: flex; flex-direction: column; }
  .rg-head { order: 1; }
  .rg-form { order: 2; margin-top: 36px; max-width: none; gap: 18px 12px; }
  .rg-figure { order: 3; margin-top: 32px; }
  .rg-hero .rg-fine { order: 4; margin-top: 32px; padding-top: 0; border-top: 0; }
  .sp-page .rg-lead { font-size: 18px; }
  .rg-form input[type="number"], .rg-form input[type="date"] { height: 50px; padding: 0 12px; font-size: 16px; }
  .rg-figure .rg-plate { aspect-ratio: 16 / 10; padding: 22px 18px 14px; }
  .rg-num b { font-size: 88px; }
  .rg-num span { font-size: 18px; }
  .sp-page .rg-status { font-size: 17px; }
  .rg-facts { gap: 28px; }
  .rg-hcta { flex-direction: column; align-items: stretch; gap: 10px; }
  .rg-hcta .rg-btn { width: 100%; }
  .rg-hcta span { text-align: center; }
  .rg-rules { padding: 80px 0; }
  .rg-rule-list { grid-template-columns: 1fr; gap: 44px; margin-top: 36px; }
  .sp-page .rg-rule .rg-key { font-size: 52px; }
  .sp-page .rg-rule p:not(.rg-key) { font-size: 17px; }
  .rg-faq { padding: 80px 0; }
  .rg-faq-grid { grid-template-columns: 1fr; gap: 24px; }
  .rg-acc summary, .rg-accs--rules .rg-acc summary { padding: 20px 2px; font-size: 18px; }
  .rg-acc-body p, .rg-acc-body li { font-size: 17px; }
  .rg-band { padding: 64px 0; }
  .rg-band-in { flex-direction: column; align-items: stretch; }
  .rg-band .rg-btn { width: 100%; }
}

/* Link from the main Dormer page */
.sp-guide-link {
  margin-top: 14px;
}

.sp-guide-link a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--sp-ink);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(201, 162, 87, 0.75);
  text-underline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
  .rg-house-clip, .rg-house-level, .rg-bar-fill, .rg-chev, .rg-seg span, .rg-btn { transition: none; }
}
