/*
 * Service page component library.
 * Shared visual language for the marketing-style service pages
 * (Teen Driver Education, Adult Driving, DPS Road Test, Parent-Taught Driving).
 * Extracted from the original Teen Driver Education page so every service
 * page renders from the same set of components instead of separate copies.
 */

.sp-page {
    font-family: 'Hanken Grotesk', sans-serif;
    color: #16242e;
    background: #ffffff;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
.sp-page * { box-sizing: border-box; }

.sp-wrap { max-width: 1240px; margin: 0 auto; }
.sp-wrap--narrow { max-width: 880px; }
.sp-section { padding: 96px 24px; }
.sp-section--tight { padding: 88px 24px; }
.sp-center { text-align: center; margin: 0 auto 56px; max-width: 760px; }
.sp-center--wide { max-width: 860px; }

/* ---------- Dark-context theming ----------
 * Add .sp-dark to any section/card with a dark background. Every typography,
 * icon, and index element inside automatically switches to its light-on-dark
 * color. This is the single place that governs light/dark text so no page
 * can forget to override an inherited color again. */
.sp-dark { color: #fff; }
.sp-dark .sp-kicker { color: #4bd6ac; }
.sp-dark .sp-h2, .sp-dark .sp-h3 { color: #fff; }
.sp-dark .sp-p { color: #a9bac0; }
.sp-dark .sp-p--muted { color: #8fa2a9; }
.sp-dark .sp-index { color: #4c5d66; }
.sp-dark .sp-icon-circle { background: rgba(40, 196, 151, .14); color: #4bd6ac; }
.sp-dark .sp-check-item { color: #cdd8dc; }

/* Hero side-card is a light card that lives inside the dark hero: it must
 * escape the .sp-dark cascade above. Selector specificity here is
 * deliberately higher (3 classes) so it always wins regardless of source order. */
.sp-hero .sp-hero-card .sp-h3,
.sp-hero .sp-hero-card .sp-p,
.sp-hero .sp-hero-card .sp-kicker,
.sp-hero .sp-hero-card .sp-index { color: initial; }
.sp-hero-card { color: #16242e; }
.sp-hero-card .sp-kicker { color: #1c9e79; }
.sp-hero-card .sp-h3 { color: #16242e; }
.sp-hero-card .sp-icon-circle { background: #e6f5ef; color: #1c9e79; }

/* ---------- Typography ---------- */
.sp-kicker {
    font-family: 'Sora', sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .13em;
    text-transform: uppercase;
    color: #1c9e79;
    display: inline-block;
}
.sp-h1, .sp-h2, .sp-h3 {
    font-family: 'Sora', sans-serif;
    font-weight: 800;
    letter-spacing: -.02em;
    margin: 0;
}
.sp-h1 { font-size: 58px; line-height: 1.04; color: #fff; margin-top: 22px; }
.sp-h2 { font-size: 42px; line-height: 1.1; color: #16242e; margin: 12px 0 16px; }
.sp-h2--tight { margin: 12px 0 0; }
.sp-h3 { font-weight: 700; font-size: 22px; line-height: 1.25; color: #16242e; margin: 0 0 12px; }
.sp-p { font-size: 17px; line-height: 1.65; color: #56666e; margin: 0 0 16px; }
.sp-p:last-child { margin-bottom: 0; }
.sp-p--lg { font-size: 18px; line-height: 1.65; }
.sp-p--sm { font-size: 14.5px; line-height: 1.6; }

/* ---------- Grids & layout ---------- */
.sp-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }
.sp-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.sp-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.sp-split { display: grid; grid-template-columns: .95fr 1.05fr; gap: 56px; align-items: center; }
.sp-checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.sp-checklist--2col { grid-template-columns: 1fr 1fr; }
.sp-check-item { display: flex; gap: 9px; font-size: 14px; line-height: 1.5; color: #40515a; }
.sp-check-item svg { flex: none; margin-top: 2px; }

/* ---------- Icon circle ----------
 * Icons use stroke/fill="currentColor" so the same markup adapts to light
 * and dark contexts automatically via the `color` set on the circle. */
.sp-icon-circle {
    flex: none;
    width: 44px; height: 44px;
    border-radius: 50%;
    background: #e6f5ef;
    color: #1c9e79;
    display: flex; align-items: center; justify-content: center;
}
.sp-icon-circle--md { width: 50px; height: 50px; border-radius: 14px; }
.sp-icon-circle--lg { width: 54px; height: 54px; border-radius: 14px; }
.sp-icon-circle--solid { background: #28c497; color: #fff; border-radius: 50%; }

/* ---------- Buttons ---------- */
.sp-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    font-family: 'Sora', sans-serif; font-weight: 700; font-size: 16px;
    padding: 16px 26px; border-radius: 9px; text-decoration: none; border: none;
    cursor: pointer;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease, transform .15s ease;
}
.sp-btn--sm { padding: 13px 22px; font-size: 15px; border-radius: 8px; }
.sp-btn--block { width: 100%; }
.sp-btn--primary, .sp-btn--primary:visited { background: #28c497; color: #0c1a24; }
.sp-btn--primary:hover { background: #22b085; color: #0c1a24; transform: translateY(-1px); }
.sp-btn--dark, .sp-btn--dark:visited { background: #16242e; color: #fff; }
.sp-btn--dark:hover { background: #0c1a24; color: #fff; }
.sp-btn--outline, .sp-btn--outline:visited { background: transparent; color: #fff; border: 1.5px solid rgba(255, 255, 255, .28); }
.sp-btn--outline:hover { border-color: #28c497; color: #4bd6ac; }
.sp-btn--outline-dark, .sp-btn--outline-dark:visited { background: #fff; color: #16242e; border: 1.5px solid #16242e; }
.sp-btn--outline-dark:hover { background: #16242e; color: #fff; }

/* ---------- Cards ---------- */
.sp-card { border-radius: 18px; padding: 34px; }
.sp-card--white { background: #fff; border: 1px solid #e6eae9; }
.sp-card--soft { background: #f4f6f5; }
.sp-card--dark { background: #0c1a24; }
.sp-card--darker { background: #12242f; border: 1px solid rgba(255, 255, 255, .08); }
.sp-card--stack { display: flex; flex-direction: column; }

/* Grid feature cards with a top-row index + icon badge, matching Teen's
 * "Program Options" / "What's Included" card header pattern. */
.sp-card-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 20px; }
.sp-index { font-family: 'Sora', sans-serif; font-weight: 700; font-size: 15px; color: #9aa8ad; }

/* Ghost-numeral step card, matching Teen's "How it Works" steps. */
.sp-step { position: relative; overflow: hidden; }
.sp-step-ghost {
    position: absolute; top: 14px; right: 22px;
    font-family: 'Sora', sans-serif; font-weight: 800; font-size: 58px; line-height: 1;
    color: #e6ebe9;
}
.sp-dark .sp-step-ghost { color: rgba(255, 255, 255, .06); }
.sp-step-chip {
    position: relative;
    display: inline-flex; align-items: center; justify-content: center;
    width: 46px; height: 46px; border-radius: 12px;
    background: #28c497; color: #0c1a24;
    font-family: 'Sora', sans-serif; font-weight: 800; font-size: 17px;
}

/* ---------- Hero ---------- */
.sp-hero {
    position: relative;
    background: radial-gradient(120% 100% at 80% 0%, #143140 0%, #0c1a24 55%, #081218 100%);
    overflow: hidden;
    isolation: isolate;
}
.sp-hero::before {
    content: "";
    position: absolute; inset: 0;
    background-image: var(--sp-hero-bg);
    background-size: cover; background-position: center;
    opacity: .10; mix-blend-mode: luminosity;
}
.sp-hero-glow {
    position: absolute; top: -120px; right: -80px;
    width: 420px; height: 420px; border-radius: 50%;
    background: radial-gradient(circle, rgba(40, 196, 151, .22), transparent 70%);
    animation: spGlow 10s ease-in-out infinite;
}
.sp-hero-glow--sm { width: 320px; height: 320px; top: -80px; right: -50px; left: auto; }
.sp-hero-glow--left { left: -60px; right: auto; top: -100px; width: 360px; height: 360px; background: radial-gradient(circle, rgba(40, 196, 151, .16), transparent 70%); }
@keyframes spGlow { 0%, 100% { transform: scale(1); opacity: .7; } 50% { transform: scale(1.15); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .sp-hero-glow { animation: none !important; } }

.sp-hero-grid { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 56px; align-items: center; padding: 84px 24px 96px; }
.sp-hero-badge {
    display: inline-flex; align-items: center; gap: 9px;
    border: 1px solid rgba(40, 196, 151, .4); background: rgba(40, 196, 151, .12);
    color: #4bd6ac; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 12px;
    letter-spacing: .13em; text-transform: uppercase; padding: 8px 14px; border-radius: 6px;
}
.sp-hero-lede { font-size: 18px; line-height: 1.65; color: #b8c6cc; max-width: 560px; margin: 22px 0 0; }
.sp-hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
.sp-hero-serving { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 34px; }
.sp-hero-serving-label { font-family: 'Sora', sans-serif; font-size: 12px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase; color: #7f9199; }
.sp-chip {
    font-family: 'Sora', sans-serif; font-size: 13px; font-weight: 600; color: #e5edf0;
    background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1);
    padding: 7px 14px; border-radius: 6px;
}

.sp-hero-card { background: #ffffff; border-radius: 16px; box-shadow: 0 30px 70px -30px rgba(0, 0, 0, .6); overflow: hidden; }
.sp-hero-card-top { height: 6px; background: #28c497; }
.sp-hero-card-body { padding: 28px 28px 8px; }
.sp-hero-card-item {
    display: flex; align-items: center; gap: 16px; text-decoration: none;
    padding: 16px 0; border-top: 1px solid #eef1f0;
}
.sp-hero-card-item-title { display: block; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 16px; color: #16242e; }
.sp-hero-card-item-sub { display: block; font-size: 13.5px; color: #62727a; margin-top: 2px; }
.sp-hero-card-foot {
    background: #f4f6f5; padding: 16px 28px;
    display: flex; align-items: center; justify-content: space-between;
}
.sp-hero-card-foot-label { font-size: 13.5px; color: #62727a; }
.sp-hero-card-foot-phone {
    font-family: 'Sora', sans-serif; font-weight: 700; font-size: 15px; color: #16242e;
    text-decoration: none; display: inline-flex; align-items: center; gap: 7px;
}

/* ---------- Trust bar ---------- */
.sp-trust { background: #f4f6f5; padding: 26px 24px; }
.sp-trust-item { display: flex; align-items: center; gap: 14px; }
.sp-trust-item strong, .sp-trust-item span.sp-trust-label { font-family: 'Sora', sans-serif; font-weight: 700; font-size: 15px; color: #16242e; }

/* ---------- Pricing cards ---------- */
.sp-price-card { border-radius: 18px; padding: 34px; display: flex; flex-direction: column; position: relative; }
.sp-price-card--featured { box-shadow: 0 30px 60px -28px rgba(12, 26, 36, .5); }
.sp-price-ribbon {
    position: absolute; top: 22px; right: 22px;
    background: #28c497; color: #0c1a24;
    font-family: 'Sora', sans-serif; font-weight: 700; font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
    padding: 6px 11px; border-radius: 20px;
}
.sp-price-value { font-family: 'Sora', sans-serif; font-weight: 800; font-size: 40px; color: #16242e; }
.sp-price-value--sm { font-size: 30px; }
.sp-dark .sp-price-value { color: #fff; }

/* ---------- FAQ accordion ---------- */
.sp-faq-list { border-top: 1px solid #e6eae9; }
.sp-faq-item { border-bottom: 1px solid #e6eae9; }
.sp-faq-btn {
    cursor: pointer; width: 100%; display: flex; align-items: center; gap: 18px;
    background: none; border: none; padding: 24px 4px; text-align: left; font: inherit;
}
.sp-faq-num { font-family: 'Sora', sans-serif; font-weight: 700; font-size: 14px; color: #b1c0b9; flex: none; }
.sp-faq-question { flex: 1; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 18px; color: #16242e; }
.sp-faq-sign {
    flex: none; width: 32px; height: 32px; border-radius: 50%; background: #e6f5ef;
    display: flex; align-items: center; justify-content: center;
    font-family: 'Sora', sans-serif; font-weight: 700; font-size: 20px; color: #1c9e79; line-height: 1;
}
.sp-faq-panel { overflow: hidden; max-height: 0; transition: max-height .3s ease; }
.sp-faq-answer { font-size: 15.5px; line-height: 1.7; color: #56666e; margin: 0; padding: 0 54px 26px; }

/* ---------- CTA ---------- */
.sp-cta-wrap { background: #f4f6f5; padding: 88px 24px; }
.sp-cta {
    max-width: 1000px; margin: 0 auto;
    background: radial-gradient(120% 130% at 85% 0%, #143140 0%, #0c1a24 60%);
    border-radius: 24px; padding: 60px 56px; position: relative; overflow: hidden;
}
.sp-cta-grid { position: relative; display: grid; grid-template-columns: 1.3fr .7fr; gap: 40px; align-items: center; }
.sp-cta-actions { display: flex; flex-direction: column; gap: 12px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .sp-hero-grid, .sp-grid-2, .sp-grid-3, .sp-cta-grid, .sp-split, .sp-checklist--2col { grid-template-columns: 1fr !important; }
    .sp-grid-4 { grid-template-columns: repeat(2, 1fr) !important; }
    .sp-h1 { font-size: 38px !important; }
    .sp-h2 { font-size: 30px !important; }
    .sp-section { padding: 76px 18px; }
    .sp-section--tight { padding: 62px 18px; }
    .sp-cta { padding: 42px 26px; }
}
@media (max-width: 640px) {
    .sp-grid-4 { grid-template-columns: 1fr !important; }
}
