/* =========================================================================
   Installment Loans Hub — styles (prefix: ilh-)
   ========================================================================= */

/* ---- Design tokens ---------------------------------------------------- */
.ilh-page {
    --ilh-bg:            #0b1220;
    --ilh-surface:       #ffffff;
    --ilh-surface-2:     #f6f8fc;
    --ilh-border:        #e3e8f0;
    --ilh-text:          #1a2233;
    --ilh-text-soft:     #55617a;
    --ilh-primary:       #1c64f2;
    --ilh-primary-dark:  #1450c7;
    --ilh-teal:          #14b8a6;
    --ilh-amber:         #f59e0b;
    --ilh-green:         #16a34a;
    --ilh-red:           #dc2626;
    --ilh-radius:        16px;
    --ilh-radius-sm:     10px;
    --ilh-shadow:        0 10px 30px -12px rgba(16, 32, 64, .25);
    --ilh-shadow-lg:     0 24px 60px -20px rgba(16, 32, 64, .35);
    --ilh-gap:           clamp(1rem, 2.5vw, 2rem);
    --ilh-section-y:     clamp(2.5rem, 6vw, 5rem);

    color: var(--ilh-text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.ilh-page .container {
    max-width: 1120px;
    margin-inline: auto;
    padding-inline: clamp(1rem, 4vw, 2rem);
}

.ilh-page h1,
.ilh-page h2,
.ilh-page h3 { line-height: 1.2; margin: 0 0 .5em; }

.ilh-page a { color: var(--ilh-primary); }

.ilh-page :focus-visible {
    outline: 3px solid var(--ilh-primary);
    outline-offset: 2px;
    border-radius: 4px;
}

/* ---- Hero headline ---------------------------------------------------- */
.ilh-hero-headline {
    max-width: 780px;
    margin: 0 auto;
    padding: clamp(2rem, 6vw, 4rem) clamp(1rem, 4vw, 2rem) clamp(1.5rem, 4vw, 2.5rem);
    text-align: center;
}
.ilh-hero-headline__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    font-size: .82rem;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    color: var(--ilh-primary-dark);
    background: rgba(28, 100, 242, .08);
    padding: .4rem .85rem;
    border-radius: 999px;
    margin-bottom: 1.1rem;
}
.ilh-hero-headline__dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--ilh-green);
    box-shadow: 0 0 0 0 rgba(22, 163, 74, .5);
    animation: ilh-pulse 2s infinite;
}
.ilh-hero-headline__title {
    font-size: clamp(1.9rem, 5vw, 3rem);
    font-weight: 800;
    letter-spacing: -.02em;
}
.ilh-hero-headline__sub {
    font-size: clamp(1rem, 2vw, 1.18rem);
    color: var(--ilh-text-soft);
    max-width: 620px;
    margin-inline: auto;
}

@keyframes ilh-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(22, 163, 74, .5); }
    70%  { box-shadow: 0 0 0 10px rgba(22, 163, 74, 0); }
    100% { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0); }
}

/* ---- Hero form background --------------------------------------------- */
.ilh-hero-form-bg {
    position: relative;
    overflow: hidden;
    background: linear-gradient(160deg, #0b1220 0%, #14233f 60%, #0b1220 100%);
    padding-block: clamp(2rem, 6vw, 4rem);
}
.ilh-hero-canvas { position: absolute; inset: 0; pointer-events: none; }
.ilh-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: .55;
    animation: ilh-float 14s ease-in-out infinite;
}
.ilh-orb--teal  { width: 320px; height: 320px; background: var(--ilh-teal);   top: -60px; left: -40px; }
.ilh-orb--blue  { width: 380px; height: 380px; background: var(--ilh-primary); bottom: -120px; right: -60px; animation-delay: -4s; }
.ilh-orb--amber { width: 220px; height: 220px; background: var(--ilh-amber);  top: 40%; left: 55%; opacity: .3; animation-delay: -8s; }
.ilh-grid-pattern {
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: radial-gradient(ellipse at center, #000 40%, transparent 80%);
}
.ilh-sweep {
    position: absolute; inset: 0;
    background: linear-gradient(115deg, transparent 40%, rgba(255,255,255,.08) 50%, transparent 60%);
    animation: ilh-sweep 8s linear infinite;
}
@keyframes ilh-float {
    0%,100% { transform: translate(0,0); }
    50%     { transform: translate(20px, -30px); }
}
@keyframes ilh-sweep {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.ilh-hero-form__column { position: relative; z-index: 1; }

/* ---- Form card -------------------------------------------------------- */
.basic-form {
    max-width: 560px;
    margin-inline: auto;
    background: var(--ilh-surface);
    border-radius: var(--ilh-radius);
    box-shadow: var(--ilh-shadow-lg);
    padding: clamp(1.25rem, 4vw, 2rem);
}
.ilh-form-caption {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 1rem;
    text-align: center;
}
.ilh-pre-form { margin-bottom: 1.25rem; }
.ilh-pre-form h2 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--ilh-text-soft);
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-bottom: .75rem;
}
.ilh-pre-form__list { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.ilh-pre-form__list li { display: flex; gap: .75rem; align-items: flex-start; font-size: .92rem; }
.ilh-pre-form__list svg { flex: none; color: var(--ilh-primary); margin-top: 2px; }

.js-form-slot { min-height: 60px; }

.ilh-mini-disclosure {
    font-size: .78rem;
    color: var(--ilh-text-soft);
    margin: 1rem 0 0;
    text-align: center;
}

.ilh-form-fallback {
    background: #fff7ed;
    border: 1px solid var(--ilh-amber);
    border-radius: var(--ilh-radius-sm);
    padding: 1rem;
    font-size: .9rem;
    text-align: center;
}
.ilh-form-fallback p { margin: .25rem 0; }

/* ---- Trust strip ------------------------------------------------------ */
.ilh-hero-intro { margin-top: calc(var(--ilh-section-y) * -0.4); position: relative; z-index: 2; }
.ilh-trust-strip {
    list-style: none; margin: 0; padding: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--ilh-gap);
    background: var(--ilh-surface);
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius);
    box-shadow: var(--ilh-shadow);
    padding: clamp(1rem, 3vw, 1.75rem);
}
.ilh-trust-item { display: flex; gap: .75rem; align-items: center; }
.ilh-trust-icon {
    flex: none;
    display: grid; place-items: center;
    width: 52px; height: 52px;
    border-radius: 12px;
    background: rgba(28,100,242,.08);
    color: var(--ilh-primary);
}
.ilh-trust-item__label { font-weight: 700; font-size: 1rem; }
.ilh-trust-item__sub { font-size: .82rem; color: var(--ilh-text-soft); }

/* ---- Section shell ---------------------------------------------------- */
.ilh-page section { padding-block: var(--ilh-section-y); }
.ilh-section-heading {
    display: flex; align-items: center; gap: .65rem;
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    letter-spacing: -.01em;
}
.ilh-heading-icon {
    display: grid; place-items: center;
    width: 42px; height: 42px; flex: none;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--ilh-primary), var(--ilh-teal));
    color: #fff;
}
.ilh-section-lede {
    color: var(--ilh-text-soft);
    font-size: 1.05rem;
    max-width: 720px;
    margin-bottom: 1.75rem;
}

/* ---- Shared <details> cards ------------------------------------------- */
.ilh-qa-card,
.ilh-faq-item,
.ilh-example-rollover {
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius-sm);
    background: var(--ilh-surface);
    overflow: hidden;
}
.ilh-qa-card summary,
.ilh-faq-item summary,
.ilh-example-rollover summary {
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.15rem;
    font-weight: 600;
}
.ilh-qa-card summary::-webkit-details-marker,
.ilh-faq-item summary::-webkit-details-marker,
.ilh-example-rollover summary::-webkit-details-marker { display: none; }

.ilh-qa-card p,
.ilh-faq-item p { margin: 0; padding: 0 1.15rem 1.15rem; color: var(--ilh-text-soft); }

/* +/- toggle */
.ilh-qa-toggle { position: relative; width: 18px; height: 18px; flex: none; }
.ilh-qa-toggle::before,
.ilh-qa-toggle::after {
    content: ""; position: absolute; background: var(--ilh-primary);
    transition: transform .25s ease;
}
.ilh-qa-toggle::before { top: 8px; left: 0; width: 18px; height: 2px; }
.ilh-qa-toggle::after  { top: 0; left: 8px; width: 2px; height: 18px; }
details[open] .ilh-qa-toggle::after { transform: scaleY(0); }

.ilh-faq-item summary::after,
.ilh-example-rollover summary::after {
    content: "+"; font-size: 1.4rem; line-height: 1; color: var(--ilh-primary);
    transition: transform .25s ease;
}
.ilh-faq-item[open] summary::after,
.ilh-example-rollover[open] summary::after { transform: rotate(45deg); }

.ilh-qa-grid { display: grid; gap: 1rem; }

/* ---- Worked example --------------------------------------------------- */
.ilh-example-card {
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius);
    box-shadow: var(--ilh-shadow);
    overflow: hidden;
}
.ilh-example-scenario {
    display: flex; gap: 1rem; align-items: flex-start;
    padding: 1.25rem;
    background: var(--ilh-surface-2);
    border-bottom: 1px solid var(--ilh-border);
}
.ilh-example-scenario__icon { color: var(--ilh-primary); flex: none; }
.ilh-example-scenario__label {
    font-size: .78rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .05em; color: var(--ilh-text-soft);
}
.ilh-example-scenario__text { font-size: .98rem; }

.ilh-example-breakdown { padding: .5rem 1.25rem; }
.ilh-example-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: .7rem 0;
    border-bottom: 1px dashed var(--ilh-border);
}
.ilh-example-row dt, .ilh-example-row dd { margin: 0; }
.ilh-example-row dd { font-weight: 600; font-variant-numeric: tabular-nums; }
.ilh-example-row:last-child { border-bottom: none; }
.ilh-example-row--apr dd { color: var(--ilh-amber); }
.ilh-example-row--total {
    font-weight: 700;
    border-bottom: none;
}
.ilh-example-row--total dt { font-weight: 700; }
.ilh-example-row--total dd { color: var(--ilh-primary-dark); font-size: 1.05rem; }

.ilh-example-rollover { border: none; border-top: 1px solid var(--ilh-border); border-radius: 0; }
.ilh-example-rollover summary { background: #fff7ed; color: var(--ilh-amber); }
.ilh-example-rollover__content { padding: 1rem 1.25rem 1.25rem; color: var(--ilh-text-soft); }
.ilh-example-rollover__content p { margin: .5rem 0; }

.ilh-callout {
    margin-top: 1.5rem;
    background: var(--ilh-surface-2);
    border-left: 4px solid var(--ilh-primary);
    border-radius: var(--ilh-radius-sm);
    padding: 1.15rem 1.35rem;
}
.ilh-callout ul { margin: .75rem 0 0; padding-left: 1.2rem; display: grid; gap: .4rem; }
.ilh-callout li { color: var(--ilh-text-soft); }

/* ---- Steps ------------------------------------------------------------ */
.ilh-steps-list {
    list-style: none; margin: 0; padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: var(--ilh-gap);
    counter-reset: none;
}
.ilh-step {
    background: var(--ilh-surface);
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius-sm);
    padding: 1.35rem;
    position: relative;
}
.ilh-step__num {
    width: 40px; height: 40px;
    display: grid; place-items: center;
    border-radius: 50%;
    font-weight: 800;
    color: #fff;
    background: linear-gradient(135deg, var(--ilh-primary), var(--ilh-teal));
    margin-bottom: .85rem;
}
.ilh-step__body h3 { font-size: 1.1rem; }
.ilh-step__body p { margin: 0; color: var(--ilh-text-soft); font-size: .92rem; }

/* ---- Eligibility ------------------------------------------------------ */
.ilh-eligibility-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--ilh-gap);
}
.ilh-elig {
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius-sm);
    padding: 1.35rem;
    background: var(--ilh-surface);
}
.ilh-elig--yes { border-top: 4px solid var(--ilh-green); }
.ilh-elig--no  { border-top: 4px solid var(--ilh-text-soft); }
.ilh-elig__header {
    display: flex; align-items: center; gap: .6rem;
    font-weight: 700; font-size: 1.1rem;
    margin-bottom: .85rem;
}
.ilh-elig-icon {
    width: 28px; height: 28px; flex: none;
    display: grid; place-items: center;
    border-radius: 50%; font-weight: 800; color: #fff;
}
.ilh-elig--yes .ilh-elig-icon { background: var(--ilh-green); }
.ilh-elig--no  .ilh-elig-icon { background: var(--ilh-text-soft); }
.ilh-elig ul { margin: 0; padding-left: 1.15rem; display: grid; gap: .5rem; color: var(--ilh-text-soft); }

/* ---- Loan type cards -------------------------------------------------- */
.ilh-types-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: var(--ilh-gap);
}
.ilh-type-card {
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius);
    background: var(--ilh-surface);
    padding: 1.5rem;
    box-shadow: var(--ilh-shadow);
    display: flex;
    flex-direction: column;
    transition: transform .2s ease, box-shadow .2s ease;
}
.ilh-type-card:hover { transform: translateY(-4px); box-shadow: var(--ilh-shadow-lg); }
.ilh-type-card--installment { border-top: 4px solid var(--ilh-primary); }
.ilh-type-card--personal    { border-top: 4px solid var(--ilh-teal); }
.ilh-type-card--cash        { border-top: 4px solid var(--ilh-amber); }
.ilh-type-card__header { display: flex; gap: .85rem; align-items: center; margin-bottom: 1rem; }
.ilh-type-icon {
    width: 54px; height: 54px; flex: none;
    display: grid; place-items: center;
    border-radius: 12px;
    background: var(--ilh-surface-2);
    color: var(--ilh-primary);
}
.ilh-type-card__meta h3 { margin: .2rem 0 0; font-size: 1.2rem; }
.ilh-type-card__tag {
    display: inline-block;
    font-size: .7rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .04em;
    padding: .2rem .55rem;
    border-radius: 999px;
    background: var(--ilh-surface-2);
    color: var(--ilh-text-soft);
}
.ilh-type-card__tag--good    { background: rgba(22,163,74,.12);  color: var(--ilh-green); }
.ilh-type-card__tag--warning { background: rgba(245,158,11,.15); color: #b45309; }
.ilh-type-specs { margin: 0 0 1rem; display: grid; gap: .5rem; }
.ilh-type-specs > div {
    display: flex; justify-content: space-between;
    border-bottom: 1px dashed var(--ilh-border);
    padding-bottom: .5rem;
}
.ilh-type-specs dt { color: var(--ilh-text-soft); margin: 0; }
.ilh-type-specs dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.ilh-type-card__body { margin: 0; color: var(--ilh-text-soft); font-size: .92rem; margin-top: auto; }

/* ---- FAQ -------------------------------------------------------------- */
.ilh-faq-list { display: grid; gap: .75rem; }

/* ---- Final CTA -------------------------------------------------------- */
.ilh-final-cta { }
.ilh-final-cta__inner {
    text-align: center;
    background: linear-gradient(160deg, #0b1220 0%, #14233f 100%);
    color: #fff;
    border-radius: var(--ilh-radius);
    padding: clamp(2rem, 6vw, 3.5rem) clamp(1.25rem, 4vw, 2rem);
    box-shadow: var(--ilh-shadow-lg);
}
.ilh-final-cta__badge {
    width: 64px; height: 64px;
    display: grid; place-items: center;
    margin: 0 auto 1rem;
    border-radius: 50%;
    background: rgba(255,255,255,.1);
    color: #fff;
}
.ilh-final-cta__inner h2 { font-size: clamp(1.5rem, 4vw, 2.2rem); }
.ilh-final-cta__inner p { color: rgba(255,255,255,.8); max-width: 560px; margin-inline: auto; }
.ilh-final-cta__btn {
    display: inline-flex; align-items: center; gap: .5rem;
    margin-top: 1.5rem;
    background: var(--ilh-primary);
    color: #fff !important;
    text-decoration: none;
    font-weight: 700;
    padding: .9rem 1.75rem;
    border-radius: 999px;
    transition: background .2s ease, transform .2s ease;
}
.ilh-final-cta__btn:hover { background: var(--ilh-primary-dark); transform: translateY(-2px); }
.ilh-final-cta__btn span { transition: transform .2s ease; }
.ilh-final-cta__btn:hover span { transform: translateX(4px); }
.ilh-final-cta__disclaimer { font-size: .78rem; margin-top: 1rem; color: rgba(255,255,255,.6); }

/* ---- Disclaimer box --------------------------------------------------- */
.ilh-disclaimer-box {
    background: var(--ilh-surface-2);
    border: 1px solid var(--ilh-border);
    border-radius: var(--ilh-radius-sm);
    padding: clamp(1.25rem, 3vw, 2rem);
    margin-bottom: var(--ilh-section-y);
}
.ilh-disclaimer-box h3 { font-size: 1.1rem; }
.ilh-disclaimer-box p { font-size: .82rem; color: var(--ilh-text-soft); margin: 0 0 .85rem; }
.ilh-disclaimer-box p:last-child { margin-bottom: 0; }

/* ---- Responsive ------------------------------------------------------- */
@media (max-width: 860px) {
    .ilh-trust-strip { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
    .ilh-trust-strip,
    .ilh-eligibility-grid { grid-template-columns: 1fr; }
    .ilh-hero-intro { margin-top: 1rem; }
}

/* ---- Reduced motion --------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    .ilh-orb, .ilh-sweep, .ilh-hero-headline__dot,
    .ilh-type-card, .ilh-final-cta__btn, .ilh-final-cta__btn span {
        animation: none !important;
        transition: none !important;
    }
}