/* Home page sections. The design system is in site.css. */

main { padding: 0; }

.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; margin-top: 36px; }

/* ---------- Hero ---------- */
.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: min(84vh, 820px);
    border-bottom: 1px solid var(--rule);
}
.hero-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(56px, 8vw, 112px) var(--gutter);
}
.hero-text h1 { margin-top: 24px; }
.hero-sub {
    max-width: 30em;
    margin: 24px 0 0;
    font-size: 1.125rem;
    color: var(--text-dark);
}
.hero-image { position: relative; margin: 0; background: #000; }
.hero-image img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 40% 50%;
}
.hero-image figcaption {
    position: absolute;
    right: 16px;
    bottom: 12px;
    color: #fff;
}

/* ---------- Sections ---------- */
.home-section {
    padding: clamp(72px, 10vw, 144px) var(--gutter) 0;
}
.home-section:last-of-type { padding-bottom: clamp(72px, 10vw, 144px); }
.section-label { margin-bottom: 32px; }
.section-intro { max-width: 36em; margin: 20px 0 0; }
.section-foot { margin: 36px 0 0; }

.disclosure {
    max-width: 52em;
    margin: 24px 0 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}
.disclosure a { color: var(--text-dark); }

/* ---------- Credentials ---------- */
.credentials {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
}
.credential { padding: 32px clamp(20px, 3vw, 40px) 48px; border-left: 1px solid var(--rule); }
.credential:first-child { padding-left: 0; border-left: none; }
.callout {
    margin: 24px 0 0;
    font-family: var(--font-serif) !important;
    font-size: clamp(1.5rem, 2.3vw, 2.125rem);
    line-height: 1.25;
}

/* ---------- Before and after ---------- */
.case-track {
    display: flex;
    gap: 32px;
    margin-top: 40px;
    padding-bottom: 12px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
}
.case { flex: 0 0 min(560px, 88%); margin: 0; scroll-snap-align: start; }
.compare {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #000;
    touch-action: pan-y;
}
.compare img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.compare-after { clip-path: inset(0 0 0 var(--pos)); }
.compare-label { position: absolute; top: 10px; padding: 2px 8px; background: #000; color: #fff; }
.compare-label-before { left: 10px; }
.compare-label-after { right: 10px; }
.compare input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: ew-resize;
}
.compare-handle {
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--pos);
    width: 2px;
    margin-left: -1px;
    background: #fff;
    pointer-events: none;
}
.compare-handle::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 24px;
    height: 24px;
    margin: -14px 0 0 -14px;
    border: 2px solid #000;
    border-radius: 50%;
    background: #fff;
}
.compare input:focus-visible ~ .compare-handle::after { outline: 3px solid #1a56db; outline-offset: 2px; }
.case figcaption { display: block; padding-top: 16px; border-top: 1px solid var(--rule); margin-top: 16px; }
.case-title { display: block; margin-top: 6px; font-family: var(--font-serif); font-size: 1.5rem; font-weight: 400; line-height: 1.25; }
.case-text { display: block; margin-top: 8px; font-family: var(--font-serif); font-size: 1.0625rem; line-height: 1.5; }

/* ---------- Services ---------- */
.tiers {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(20px, 3vw, 40px);
    margin-top: 40px;
}
.tier { display: block; color: var(--text-dark); text-decoration: none; }
.tier img { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: cover; }
.tier h3 {
    margin: 20px 0 0;
    padding-top: 16px;
    border-top: 1px solid var(--rule);
    font-family: var(--font-serif);
    font-size: 1.625rem;
    font-weight: 400;
}
.tier:hover h3 { text-decoration: underline; text-underline-offset: 4px; }
.tier-price { margin: 4px 0 0; font-family: var(--font-serif) !important; font-size: 1.375rem; }
.tier-price .caption-muted { font-size: 0.75rem; }
.tier-desc { margin: 4px 0 0; font-size: 0.95rem; color: var(--text-muted); }

/* ---------- Process ---------- */
.ledger { margin: 40px 0 0; padding: 0; list-style: none; border-bottom: 1px solid var(--rule); }
.ledger li {
    display: grid;
    grid-template-columns: 64px minmax(160px, 1fr) 2.4fr;
    gap: 8px 24px;
    align-items: baseline;
    padding: 24px 0;
    border-top: 1px solid var(--rule);
}
.ledger h3 { margin: 0; font-family: var(--font-serif); font-size: 1.5rem; font-weight: 400; line-height: 1.25; }
.ledger p { margin: 0; }

/* ---------- Closing ---------- */
.closing { text-align: left; }

/* ---------- Narrow screens ---------- */
@media (max-width: 860px) {
    .hero { grid-template-columns: 1fr; min-height: 0; }
    .hero-text { padding-top: 56px; padding-bottom: 56px; }
    .hero-image { aspect-ratio: 1 / 1; }
    .credentials { grid-template-columns: 1fr; }
    .credential,
    .credential:first-child { padding: 24px 0 32px; border-left: none; border-top: 1px solid var(--rule); }
    .credential:first-child { border-top: none; }
    .tiers { grid-template-columns: 1fr; }
    .ledger li { grid-template-columns: 44px 1fr; }
    .ledger p { grid-column: 2; }
}
