
/* DillisData components. Plain CSS, no script. Every value comes from tokens.css.
   Display type runs expanded: font-stretch 112% for headlines, 108% for figures. */

.dd-root, .dd-root * { box-sizing: border-box; }
.dd-root { font-family: var(--font-sans); font-size: 16px; line-height: 26px; color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
.dd-dark { background: var(--graphite); color: var(--on-graphite); }

/* Engineering grid: an 80px hairline grid on graphite bands */
.dd-grid-bg { background-color: var(--graphite); background-image: linear-gradient(var(--grid-line) 1px, transparent 1px), linear-gradient(90deg, var(--grid-line) 1px, transparent 1px); background-size: var(--grid-pitch) var(--grid-pitch); background-position: -1px -1px; }

/* Corner marks: crop ticks on the four corners of a panel */
.dd-marks { position: relative; }
.dd-marks::before, .dd-marks::after { content: ""; position: absolute; width: 12px; height: 12px; pointer-events: none; border-color: var(--rule-strong); border-style: solid; }
.dd-marks::before { top: -6px; left: -6px; border-width: 1px 0 0 1px; }
.dd-marks::after { bottom: -6px; right: -6px; border-width: 0 1px 1px 0; }
.dd-dark .dd-marks::before, .dd-dark .dd-marks::after { border-color: var(--on-graphite-muted); }

/* Wordmark: the name in expanded caps, framed by four corner marks, the bottom-right one lit.
   Everything scales from the wordmark's font-size (default 17px; set --wm-size to resize). */
.dd-wordmark { position: relative; display: inline-flex; align-items: center; padding: 0.53em 0.63em 0.53em 0.68em; font-size: var(--wm-size, 17px); color: var(--ink); text-decoration: none; --wm-stroke: max(1px, 0.0526em); --wm-tick: 0.32em; }
.dd-wordmark::before, .dd-wordmark::after, .dd-wordmark__name::before, .dd-wordmark__name::after { content: ""; position: absolute; width: var(--wm-tick); height: var(--wm-tick); border: 0 solid currentColor; pointer-events: none; }
.dd-wordmark::before { left: 0; top: 0; border-left-width: var(--wm-stroke); border-top-width: var(--wm-stroke); }
.dd-wordmark__name::before { right: 0; top: 0; border-right-width: var(--wm-stroke); border-top-width: var(--wm-stroke); }
.dd-wordmark__name::after { left: 0; bottom: 0; border-left-width: var(--wm-stroke); border-bottom-width: var(--wm-stroke); }
.dd-wordmark::after { right: 0; bottom: 0; border-right-width: var(--wm-stroke); border-bottom-width: var(--wm-stroke); border-color: var(--signal-bright); }
.dd-wordmark__name { font-family: var(--font-display); font-stretch: 118%; font-size: 1em; line-height: 1; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap; }
.dd-wordmark__name span { font-weight: 400; }
.dd-dark .dd-wordmark { color: var(--on-graphite); }

/* Button */
.dd-btn { display: inline-flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 50px; padding: 0 20px; border: 1px solid transparent; border-radius: 0; font-family: var(--font-sans); font-size: 15px; line-height: 20px; font-weight: 500; text-decoration: none; cursor: pointer; transition: background-color .15s ease, border-color .15s ease, color .15s ease; }
.dd-btn svg { width: 16px; height: 16px; flex: none; transition: transform .15s ease; }
.dd-btn:hover svg { transform: translateX(3px); }
.dd-btn--primary { background: var(--graphite); color: var(--on-graphite); }
.dd-btn--primary:hover { background: var(--graphite-raised); }
.dd-btn--light { background: var(--on-graphite); color: var(--graphite); }
.dd-btn--light:hover { background: var(--signal-bright); color: var(--on-signal); }
.dd-btn--secondary { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.dd-btn--secondary:hover { border-color: var(--ink); }
.dd-dark .dd-btn--secondary { color: var(--on-graphite); border-color: var(--on-graphite-muted); }
.dd-dark .dd-btn--secondary:hover { border-color: var(--on-graphite); }
.dd-btn--block { width: 100%; }
.dd-btn:focus-visible, .dd-link:focus-visible, .dd-accordion summary:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.dd-dark .dd-btn:focus-visible, .dd-dark .dd-link:focus-visible { outline-color: var(--on-graphite); }
.dd-btn[disabled] { opacity: .5; cursor: not-allowed; }
.dd-link { color: inherit; text-decoration: underline; text-decoration-color: var(--rule-strong); text-underline-offset: 3px; }
.dd-link:hover { text-decoration-color: currentColor; }

/* Eyebrow: index and name, led by an indicator square */
.dd-eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0; font-family: var(--font-mono); font-size: 12px; line-height: 16px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-muted); }
.dd-eyebrow::before { content: ""; width: 7px; height: 7px; background: var(--signal); flex: none; }
.dd-dark .dd-eyebrow { color: var(--on-graphite-muted); }
.dd-dark .dd-eyebrow::before { background: var(--signal-bright); }

/* Stat */
.dd-stat { position: relative; display: grid; gap: 10px; align-content: start; padding: 22px 24px 0 0; border-top: 1px solid var(--rule); min-width: 0; }
.dd-stat::before { content: ""; position: absolute; top: -1px; left: 0; width: 24px; height: 2px; background: var(--ink); }
.dd-stat__figure { font-family: var(--font-display); font-stretch: 108%; font-size: 56px; line-height: 56px; font-weight: 500; letter-spacing: -.035em; font-variant-numeric: tabular-nums lining-nums; color: var(--ink); }
.dd-stat__label { font-size: 15px; line-height: 23px; color: var(--ink-muted); }
.dd-stat__source { font-size: 13px; line-height: 18px; color: var(--ink-muted); }
.dd-stat__source a { color: inherit; text-underline-offset: 3px; }
.dd-dark .dd-stat { border-top-color: var(--grid-line); }
.dd-dark .dd-stat::before { background: var(--signal-bright); }
.dd-dark .dd-stat__figure { color: var(--on-graphite); }
.dd-dark .dd-stat__label, .dd-dark .dd-stat__source { color: var(--on-graphite-muted); }

/* Field */
.dd-field { display: grid; gap: 8px; min-width: 0; }
.dd-field__label { font-size: 13px; line-height: 18px; font-weight: 500; color: var(--ink); }
.dd-field__label em { font-style: normal; font-weight: 400; color: var(--ink-muted); }
.dd-input, .dd-select { width: 100%; min-height: 48px; padding: 12px 14px; border: 1px solid var(--rule-strong); border-radius: var(--radius-sm); background: var(--paper); color: var(--ink); font-family: var(--font-sans); font-size: 16px; line-height: 22px; }
.dd-select { appearance: none; padding-right: 40px; background-image: linear-gradient(45deg, transparent 50%, var(--ink-muted) 50%), linear-gradient(135deg, var(--ink-muted) 50%, transparent 50%); background-position: calc(100% - 20px) 21px, calc(100% - 15px) 21px; background-size: 5px 5px; background-repeat: no-repeat; }
.dd-input::placeholder { color: var(--ink-muted); }
.dd-input:focus, .dd-select:focus { outline: 2px solid var(--ink); outline-offset: 1px; border-color: var(--ink); }
.dd-field__hint { font-size: 13px; line-height: 20px; color: var(--ink-muted); }
.dd-field__error { display: none; font-size: 13px; line-height: 20px; color: var(--danger); }
.dd-field--error .dd-input, .dd-field--error .dd-select { border-color: var(--danger); }
.dd-field--error .dd-field__error { display: block; }

/* Choice chip (checkbox or radio) */
.dd-choices { display: flex; flex-wrap: wrap; gap: 8px; }
.dd-choice { position: relative; display: inline-flex; }
.dd-choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.dd-choice span { display: inline-flex; align-items: center; gap: 10px; min-height: 42px; padding: 9px 14px; border: 1px solid var(--rule-strong); border-radius: var(--radius-sm); font-size: 14px; line-height: 20px; color: var(--ink); background: var(--paper); cursor: pointer; transition: background-color .15s ease, border-color .15s ease, color .15s ease; user-select: none; }
.dd-choice span::before { content: ""; width: 8px; height: 8px; border: 1px solid currentColor; flex: none; opacity: .6; }
.dd-choice input:checked + span { border-color: var(--graphite); background: var(--graphite); color: var(--on-graphite); }
.dd-choice input:checked + span::before { background: var(--signal-bright); border-color: var(--signal-bright); opacity: 1; }
.dd-choice input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }
.dd-dark .dd-choice span { background: transparent; color: var(--on-graphite); border-color: var(--grid-line); background: var(--graphite-raised); }
.dd-dark .dd-choice span:hover { border-color: var(--on-graphite-muted); }
.dd-dark .dd-choice input:checked + span { background: var(--on-graphite); color: var(--graphite); border-color: var(--on-graphite); }
.dd-dark .dd-choice input:checked + span::before { background: var(--signal); border-color: var(--signal); }
.dd-dark .dd-choice input:focus-visible + span { outline-color: var(--on-graphite); }

/* Step: a numbered stage of a real sequence */
.dd-step { display: grid; gap: 14px; align-content: start; padding: 24px 24px 28px; border-left: 1px solid var(--rule); min-width: 0; }
.dd-step__num { font-family: var(--font-display); font-stretch: 108%; font-size: 44px; line-height: 44px; font-weight: 500; letter-spacing: -.03em; color: var(--rule-strong); font-variant-numeric: tabular-nums; }
.dd-step__title { margin: 0; font-family: var(--font-display); font-size: 20px; line-height: 26px; font-weight: 600; letter-spacing: -.01em; text-wrap: balance; }
.dd-step__body { margin: 0; color: var(--ink-muted); font-size: 15px; line-height: 24px; }
.dd-step__time { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; line-height: 18px; font-weight: 500; color: var(--ink); }
.dd-step__time::before { content: ""; width: 6px; height: 6px; background: var(--signal); }

/* Fact: one public deal, as a ledger row */
.dd-fact { display: grid; grid-template-columns: 110px minmax(0, 250px) minmax(0, 1fr); gap: 8px 32px; align-items: baseline; padding: 26px 0; border-top: 1px solid var(--rule); }
.dd-fact__date { font-size: 14px; line-height: 20px; color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.dd-fact__figure { font-family: var(--font-display); font-stretch: 108%; font-size: 40px; line-height: 44px; font-weight: 500; letter-spacing: -.03em; color: var(--ink); font-variant-numeric: tabular-nums lining-nums; }
.dd-fact__body { display: grid; gap: 8px; min-width: 0; }
.dd-fact__text { margin: 0; font-size: 16px; line-height: 26px; color: var(--ink); }
.dd-fact__source { font-size: 13px; line-height: 18px; color: var(--ink-muted); }
.dd-fact__source a { color: inherit; text-underline-offset: 3px; }
@media (max-width: 760px) { .dd-fact { grid-template-columns: minmax(0, 1fr); gap: 6px; } }

/* Accordion (FAQ) */
.dd-accordion { border-top: 1px solid var(--ink); }
.dd-accordion details { border-bottom: 1px solid var(--rule); }
.dd-accordion summary { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; padding: 22px 0; cursor: pointer; list-style: none; font-family: var(--font-display); font-size: 19px; line-height: 26px; font-weight: 600; letter-spacing: -.01em; }
.dd-accordion summary::-webkit-details-marker { display: none; }
.dd-accordion summary::after { content: "+"; font-family: var(--font-mono); font-size: 20px; font-weight: 400; color: var(--signal); transition: transform .2s ease; flex: none; }
.dd-accordion details[open] summary::after { transform: rotate(45deg); }
.dd-accordion__body { padding: 0 0 24px; max-width: 680px; color: var(--ink-muted); }
.dd-accordion__body p { margin: 0 0 12px; }

/* Header */
.dd-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--paper); border-bottom: 1px solid var(--rule); }
.dd-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; max-width: var(--content-max); margin: 0 auto; padding: 12px 32px; }
.dd-header__nav { display: flex; gap: 32px; }
.dd-header__nav a { font-size: 14px; line-height: 20px; font-weight: 500; color: var(--ink-muted); text-decoration: none; }
.dd-header__nav a:hover { color: var(--ink); }
.dd-header .dd-btn { min-height: 42px; }
@media (max-width: 860px) { .dd-header__nav { display: none; } .dd-header__inner { padding: 10px 16px; } .dd-header .dd-btn { min-height: 40px; padding: 0 14px; font-size: 14px; gap: 10px; } }

/* Estimate: the estimator's result, set as a spec sheet on paper */
.dd-estimate { display: grid; gap: 16px; padding: 28px; background: var(--paper); color: var(--ink); box-shadow: var(--shadow-panel); }
.dd-estimate__label { font-size: 13px; line-height: 18px; font-weight: 500; color: var(--ink-muted); }
.dd-estimate__range { font-family: var(--font-display); font-stretch: 108%; font-size: 48px; line-height: 52px; font-weight: 500; letter-spacing: -.035em; color: var(--ink); font-variant-numeric: tabular-nums lining-nums; }
.dd-estimate__bar { position: relative; height: 10px; background-image: repeating-linear-gradient(90deg, var(--rule) 0 1px, transparent 1px 10%); border-bottom: 1px solid var(--rule-strong); }
.dd-estimate__bar i { position: absolute; top: 2px; bottom: 2px; background: var(--ink); }
.dd-estimate__bar i::after { content: ""; position: absolute; right: -1px; top: -4px; bottom: -4px; width: 2px; background: var(--signal); }
.dd-estimate__scale { display: flex; justify-content: space-between; font-size: 12px; line-height: 16px; color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.dd-estimate__rows { display: grid; gap: 0; margin: 0; }
.dd-estimate__rows div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-top: 1px solid var(--rule); font-size: 14px; line-height: 20px; }
.dd-estimate__rows dt { color: var(--ink-muted); }
.dd-estimate__rows dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.dd-estimate__note { margin: 0; font-size: 13px; line-height: 20px; color: var(--ink-muted); }

/* Assurance list */
.dd-assure { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--ink); }
.dd-assure li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 12px; align-items: start; padding: 16px 0; border-bottom: 1px solid var(--rule); }
.dd-assure li::before { content: ""; width: 10px; height: 6px; margin-top: 8px; border-left: 2px solid var(--signal); border-bottom: 2px solid var(--signal); transform: rotate(-45deg); }
.dd-dark .dd-assure { border-top-color: var(--on-graphite); }
.dd-dark .dd-assure li { border-bottom-color: var(--grid-line); }
.dd-dark .dd-assure li::before { border-color: var(--signal-bright); }

@media (prefers-reduced-motion: reduce) { .dd-btn, .dd-btn svg, .dd-choice span, .dd-accordion summary::after { transition: none; } }
