/* ==========================================================================
   Homepage refinements
   Loaded only by index.html, after styles.css. Other pages are unaffected.
   ========================================================================== */

:root {
    --home-ink: #16213a;
    --home-line: #e3e8f0;
}

.story-intro h2 {
    font-size: clamp(2rem, 3.6vw, 2.6rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.025em;
    color: var(--home-ink);
}

/* --------------------------------------------------------------------------
   How It Works: one story told in two chapters
   -------------------------------------------------------------------------- */
.story {
    padding: 5rem 0 4rem;
    background: #ffffff;
}

.story-intro {
    text-align: center;
    max-width: 760px;
    margin: 0 auto;
}

.story-intro p {
    margin-top: 1.6rem; /* clears the orange underline */
    font-size: clamp(1.15rem, 2vw, 1.4rem);
    line-height: 1.45;
    color: var(--color-text-muted);
}

.story-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    align-items: center;
    max-width: 1120px;
    margin: 4.5rem auto 0;
}

@media (min-width: 900px) {
    .story-row {
        grid-template-columns: 5fr 6fr;
        gap: 4.5rem;
        margin-top: 7rem;
    }

    .story-row-reverse {
        grid-template-columns: 6fr 5fr;
    }

    .story-row-reverse .story-text {
        order: 2;
    }
}

.story-text h3 {
    font-size: clamp(1.8rem, 3.4vw, 2.5rem);
    line-height: 1.1;
    letter-spacing: -0.03em;
    color: var(--home-ink);
    margin-bottom: 1.75rem;
}

/* Bold lead-in, quieter continuation */
.story-steps {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
}

.story-steps li {
    font-size: 1.15rem;
    line-height: 1.5;
    color: var(--color-text-muted);
}

.story-steps strong {
    color: var(--home-ink);
    font-weight: 700;
}

ol.story-steps {
    counter-reset: story;
}

ol.story-steps li {
    counter-increment: story;
    position: relative;
    padding-left: 2.5rem;
}

ol.story-steps li::before {
    content: counter(story);
    position: absolute;
    left: 0;
    top: 0.05rem;
    font-family: var(--font-heading);
    font-size: 1.5rem;
    line-height: 1.2;
    color: var(--color-accent);
}

.story-shot {
    display: block;
    width: 100%;
    border: 1px solid var(--home-line);
    border-radius: 14px;
    box-shadow: 0 2px 4px rgba(22, 33, 58, 0.04), 0 20px 40px -24px rgba(22, 33, 58, 0.3);
}

/* The Quick Fill capture is very tall; show its top: header and first row */
.story-shot-crop {
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center top;
}

/* Closing button for the How It Works story */
.story-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 4.5rem;
}

.story-more {
    text-align: center;
    margin-top: 1.75rem;
    color: var(--color-text-muted);
}

.story-more a {
    color: var(--color-primary);
    font-weight: 600;
}

.story-more a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* --------------------------------------------------------------------------
   Phones
   -------------------------------------------------------------------------- */
@media (max-width: 639px) {
    .story {
        padding-top: 3.5rem;
        padding-bottom: 3.5rem;
    }

    .story-row {
        margin-top: 3rem;
    }

    .story-cta {
        margin-top: 3rem;
    }
}

/* Below 768px the testimonials arrow would sit above the heading; hide it */
@media (max-width: 767px) {
    .testimonials-arrow {
        display: none;
    }
}
