/* Admissions landing page (inc/admissions.php, theme 1.13). Loaded on top of showcase.css,
   whose tones (tone-coral, …) colour the stops, steps and cards. Not from the approved design. */

/* ── PATHWAYS: THE JOURNEY RAIL ─────────────────── */
.ad-paths {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(520px 420px at 100% 0%, rgba(220, 138, 0, 0.1), transparent 70%),
        radial-gradient(460px 400px at 0% 100%, rgba(14, 148, 136, 0.1), transparent 70%),
        var(--offwhite);
}

.ad-rail {
    position: relative;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 36px;
    padding: 0;
    margin: 0;
}

/* The dashed path that joins the stops, drawn in once the rail scrolls into view */
.ad-rail::before {
    content: '';
    position: absolute;
    top: 30px;
    left: 16%;
    width: 0;
    height: 0;
    border-top: 3px dashed rgba(10, 22, 40, 0.18);
    transition: width 1.4s ease 0.3s;
}

.ad-rail.visible::before {
    width: 68%;
}

.ad-stop {
    position: relative;
    padding-top: 30px;
}

.ad-stop-marker {
    position: absolute;
    top: 0;
    left: 50%;
    z-index: 2;
    width: 60px;
    height: 60px;
    margin-left: -30px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--white);
    background: linear-gradient(140deg, var(--tone), var(--tone-2));
    box-shadow: 0 0 0 8px var(--offwhite), 0 14px 30px -12px var(--tone);
    font-family: 'Playfair Display', serif;
    font-size: 21px;
    font-weight: 700;
    transition: transform 0.4s ease;
}

.ad-stop:hover .ad-stop-marker,
.ad-stop.is-match .ad-stop-marker {
    transform: translateY(-4px) scale(1.06);
}

.ad-card {
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 26px;
    overflow: hidden;
    box-shadow: 0 10px 30px -22px rgba(10, 22, 40, 0.35);
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.ad-stop:hover .ad-card {
    transform: translateY(-6px);
    box-shadow: 0 30px 50px -28px rgba(10, 22, 40, 0.45);
    border-color: transparent;
}

.ad-card-media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(140deg, var(--tone-soft), var(--white));
}

.ad-card-media img,
.ad-card-media-blank {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.9s ease;
}

.ad-card-media-blank {
    background: linear-gradient(140deg, var(--tone), var(--tone-2));
    opacity: 0.85;
}

.ad-stop:hover .ad-card-media img {
    transform: scale(1.06);
}

.ad-card-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(6, 14, 28, 0.08) 0%, transparent 40%, rgba(6, 14, 28, 0.42) 100%);
}

.ad-card-school,
.ad-card-status {
    position: absolute;
    top: 16px;
    z-index: 1;
    padding: 7px 12px;
    border-radius: 999px;
    font-family: 'Montserrat', sans-serif;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
}

.ad-card-school {
    left: 16px;
    color: var(--navy);
    background: rgba(255, 255, 255, 0.92);
}

.ad-card-status {
    right: 16px;
    color: var(--white);
    background: var(--navy-mid);
}

.ad-card-status::before {
    content: '';
    display: inline-block;
    width: 7px;
    height: 7px;
    margin-right: 7px;
    border-radius: 50%;
    background: currentColor;
    vertical-align: 1px;
}

.ad-stop--open .ad-card-status { background: #2E9E55; }
.ad-stop--soon .ad-card-status { background: #DC8A00; }
.ad-stop--closing .ad-card-status { background: #E5533D; }
.ad-stop--closed .ad-card-status { background: rgba(10, 22, 40, 0.78); }

.ad-stop--open .ad-card-status::before {
    animation: adPulse 1.6s ease-in-out infinite;
}

@keyframes adPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.35; }
}

.ad-card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 26px 28px 28px;
    border-top: 4px solid var(--tone);
}

.ad-card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}

.ad-card-age {
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--tone-soft);
    color: var(--tone-ink);
    font-family: 'Montserrat', sans-serif;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.ad-card-level {
    font-family: 'Montserrat', sans-serif;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.6px;
    color: var(--muted);
}

.ad-card-title {
    font-family: 'Playfair Display', serif;
    font-size: 23px;
    font-weight: 700;
    line-height: 1.25;
    color: var(--navy);
    margin-bottom: 10px;
}

.ad-card-title a {
    color: inherit;
    text-decoration: none;
}

/* The whole card opens the pathway */
.ad-card-link::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
}

.ad-card-note {
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 600;
    color: var(--tone-ink);
    margin-bottom: 10px;
}

.ad-card-text {
    font-size: 14.5px;
    line-height: 1.8;
    color: var(--muted);
    margin-bottom: 22px;
}

.ad-card-more {
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'Montserrat', sans-serif;
    font-size: 11.5px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--tone-ink);
}

.ad-card-more svg {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
}

.ad-stop:hover .ad-card-more svg {
    transform: translateX(5px);
}

/* The finder's match: that stop lights up, the others step back */
.ad-rail.has-match .ad-stop:not(.is-match) .ad-card {
    opacity: 0.55;
    filter: saturate(0.6);
}

.ad-stop.is-match .ad-card {
    transform: translateY(-6px);
    border-color: var(--tone);
    box-shadow: 0 0 0 4px var(--tone-soft), 0 30px 50px -28px var(--tone);
}

.ad-rail .ad-card {
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease, opacity 0.4s ease, filter 0.4s ease;
}

/* ── AGE FINDER ─────────────────────────────────── */
.ad-finder {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 48px;
    align-items: center;
    max-width: 1040px;
    margin: 0 auto 64px;
    padding: 34px 40px;
    border-radius: 26px;
    background: var(--white);
    border: 1px solid var(--border);
    box-shadow: 0 24px 50px -36px rgba(10, 22, 40, 0.45);
}

.ad-finder[hidden] {
    display: none;
}

.ad-finder-title {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
}

.ad-finder-text p {
    font-size: 14.5px;
    line-height: 1.75;
    color: var(--muted);
}

.ad-finder-label {
    display: block;
    font-family: 'Montserrat', sans-serif;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--navy);
    margin-bottom: 10px;
}

.ad-finder-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.ad-finder-row input {
    flex: 1 1 180px;
    min-width: 0;
    padding: 13px 16px;
    border: 1px solid var(--border);
    border-radius: 999px;
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    color: var(--text);
    background: var(--offwhite);
}

.ad-finder-row input:focus {
    outline: 2px solid var(--gold);
    outline-offset: 1px;
}

.ad-finder-row .btn-gold {
    cursor: pointer;
    white-space: nowrap;
}

.ad-finder-note {
    margin-top: 10px;
    font-size: 12px;
    color: var(--muted);
}

.ad-finder-result {
    grid-column: 1 / -1;
    display: none;
    padding: 16px 20px;
    border-radius: 16px;
    background: var(--gold-pale);
    border-left: 4px solid var(--gold);
    font-size: 15px;
    line-height: 1.7;
    color: var(--navy);
}

.ad-finder-result.is-shown {
    display: block;
}

.ad-finder-result a {
    color: var(--navy);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.ad-finder-result strong {
    font-weight: 700;
}

/* ── THE PROCESS ────────────────────────────────── */
.ad-steps-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 28px;
    padding: 0;
    margin: 0;
    counter-reset: ad-step;
}

.ad-step {
    position: relative;
    padding: 0 6px;
    text-align: center;
}

/* Dashed connectors between the badges */
.ad-step:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 42px;
    left: calc(50% + 48px);
    width: calc(100% - 96px + 28px);
    border-top: 2px dashed rgba(10, 22, 40, 0.14);
}

.ad-step-badge {
    position: relative;
    width: 84px;
    height: 84px;
    margin: 0 auto 22px;
    border-radius: 28px;
    display: grid;
    place-items: center;
    background: linear-gradient(140deg, var(--tone), var(--tone-2));
    color: var(--white);
    box-shadow: 0 18px 30px -18px var(--tone);
    transform: rotate(-4deg);
    transition: transform 0.4s ease;
}

.ad-step:hover .ad-step-badge {
    transform: rotate(0) translateY(-4px);
}

.ad-step-icon svg {
    width: 34px;
    height: 34px;
    display: block;
}

.ad-step-num {
    position: absolute;
    top: -12px;
    right: -12px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: var(--navy);
    color: var(--gold);
    font-family: 'Playfair Display', serif;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 0 0 4px var(--white);
}

.ad-step-title {
    font-family: 'Playfair Display', serif;
    font-size: 21px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 8px;
}

.ad-step-text {
    font-size: 14px;
    line-height: 1.75;
    color: var(--muted);
}

/* ── GOOD TO KNOW ───────────────────────────────── */
.ad-info {
    background: var(--gold-pale);
}

.ad-info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
}

.ad-info-card {
    padding: 34px 32px;
    border-radius: 24px;
    background: var(--white);
    border: 1px solid rgba(201, 168, 76, 0.25);
    box-shadow: 0 20px 40px -34px rgba(10, 22, 40, 0.4);
}

.ad-info-icon {
    width: 56px;
    height: 56px;
    margin-bottom: 20px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: var(--tone-soft);
    color: var(--tone-ink);
}

.ad-info-icon svg {
    width: 26px;
    height: 26px;
}

.ad-info-title {
    font-family: 'Playfair Display', serif;
    font-size: 21px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 12px;
}

.ad-info-text {
    font-size: 14.5px;
    line-height: 1.8;
    color: var(--muted);
    margin-bottom: 14px;
}

.ad-ticks {
    list-style: none;
    display: grid;
    gap: 10px;
    padding: 0;
    margin: 0;
}

.ad-ticks li {
    display: grid;
    grid-template-columns: 24px 1fr;
    gap: 12px;
    align-items: start;
    font-size: 14.5px;
    line-height: 1.65;
    color: var(--text);
}

.ad-ticks svg {
    width: 24px;
    height: 24px;
    padding: 6px;
    border-radius: 50%;
    background: var(--tone-soft);
    color: var(--tone-ink);
}

/* ── QUESTIONS ──────────────────────────────────── */
.ad-faq-inner {
    max-width: 880px;
}

.ad-faq-list {
    display: grid;
    gap: 12px;
}

.ad-faq-item {
    border: 1px solid var(--border);
    border-radius: 18px;
    background: var(--white);
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.ad-faq-item[open] {
    border-color: rgba(201, 168, 76, 0.6);
    box-shadow: 0 20px 40px -34px rgba(10, 22, 40, 0.4);
}

.ad-faq-item summary {
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 24px;
    cursor: pointer;
}

.ad-faq-item summary::-webkit-details-marker {
    display: none;
}

.ad-faq-q {
    font-family: 'Playfair Display', serif;
    font-size: 18px;
    font-weight: 700;
    color: var(--navy);
    line-height: 1.35;
}

.ad-faq-toggle {
    position: relative;
    flex: 0 0 32px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--gold-pale);
    transition: transform 0.3s ease, background 0.3s ease;
}

.ad-faq-toggle::before,
.ad-faq-toggle::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 2px;
    margin: -1px 0 0 -6px;
    background: var(--navy);
}

.ad-faq-toggle::after {
    transform: rotate(90deg);
}

.ad-faq-item[open] .ad-faq-toggle {
    transform: rotate(45deg);
    background: var(--gold);
}

.ad-faq-a {
    padding: 0 24px 22px;
    font-size: 15px;
    line-height: 1.8;
    color: var(--muted);
}

.ad-faq-a p + p {
    margin-top: 10px;
}

/* ── TALK TO US ─────────────────────────────────── */
.ad-help {
    position: relative;
    overflow: hidden;
    padding: 96px 48px;
    background:
        radial-gradient(560px 380px at 100% 0%, rgba(14, 148, 136, 0.35), transparent 70%),
        radial-gradient(480px 360px at 0% 100%, rgba(229, 83, 61, 0.3), transparent 70%),
        var(--navy);
    color: var(--white);
}

.ad-help-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

.ad-help-text .eyebrow {
    color: var(--gold);
}

.ad-help-hours {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 22px;
    padding: 10px 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.6px;
    color: rgba(255, 255, 255, 0.82);
}

.ad-help-hours svg {
    width: 16px;
    height: 16px;
    color: var(--gold);
}

.ad-help-cards {
    display: grid;
    gap: 18px;
}

.ad-help-card {
    padding: 26px 28px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-left: 5px solid var(--tone-2);
    backdrop-filter: blur(6px);
}

.ad-help-name {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 14px;
}

.ad-help-line {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 0;
    color: rgba(255, 255, 255, 0.84);
    text-decoration: none;
    font-size: 15px;
    transition: color 0.3s ease;
}

.ad-help-line:hover {
    color: var(--gold-light);
}

.ad-help-line svg {
    width: 18px;
    height: 18px;
    color: var(--tone-2);
    flex-shrink: 0;
}

/* ── RESPONSIVE ─────────────────────────────────── */
@media (max-width: 1100px) {
    .ad-steps-list {
        grid-template-columns: repeat(3, 1fr);
        gap: 36px 28px;
    }

    .ad-step:nth-child(3n)::after,
    .ad-step:last-child::after {
        display: none;
    }
}

@media (max-width: 900px) {
    .ad-rail {
        grid-template-columns: 1fr;
        gap: 28px;
        padding-left: 44px;
    }

    /* The path runs down the left of the stacked stops */
    .ad-rail::before {
        top: 30px;
        bottom: 30px;
        left: 29px;
        width: 0;
        height: auto;
        border-top: 0;
        border-left: 3px dashed rgba(10, 22, 40, 0.18);
        transform: scaleY(0);
        transform-origin: top;
        transition: transform 1.4s ease 0.3s;
    }

    .ad-rail.visible::before {
        width: 0;
        transform: scaleY(1);
    }

    .ad-stop {
        padding-top: 0;
    }

    .ad-stop-marker {
        top: 0;
        left: -44px;
        margin-left: 0;
    }

    .ad-finder {
        grid-template-columns: 1fr;
        gap: 18px;
        padding: 28px 24px;
    }

    .ad-info-grid,
    .ad-help-inner {
        grid-template-columns: 1fr;
    }

    .ad-help {
        padding: 72px 24px;
    }

    .ad-help-inner {
        gap: 40px;
    }
}

@media (max-width: 600px) {
    .ad-steps-list {
        grid-template-columns: 1fr 1fr;
    }

    .ad-step::after {
        display: none;
    }

    .ad-step-badge {
        width: 72px;
        height: 72px;
        border-radius: 24px;
    }

    .ad-step-icon svg {
        width: 28px;
        height: 28px;
    }

    .ad-step-title {
        font-size: 18px;
    }

    .ad-card-body {
        padding: 22px 22px 24px;
    }

    .ad-card-title {
        font-size: 21px;
    }

    .ad-finder-row .btn-gold {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 420px) {
    .ad-steps-list {
        grid-template-columns: 1fr;
    }
}
