/* =============================================================
   UMBC Scholars Program — page-scholars-program.php
   Font: Inter (loaded via theme global font-face in functions.php)
   Scoped entirely under .scholars-page to avoid bleed.
   ============================================================= */

/* ── Tokens ────────────────────────────────────────────────── */
.scholars-page {
    --sc-gold: #fdb515;
    --sc-gold-dark: #c48f00;
    --sc-black: #1a1a1a;
    --sc-charcoal: #2e2e2e;
    --sc-gray-100: #f5f5f3;
    --sc-gray-200: #e8e8e4;
    --sc-gray-400: #9a9a94;
    --sc-teal: #007176;
    --sc-teal-dark: #005a5e;
    --sc-white: #ffffff;
    --sc-max-w: 1180px;
    --sc-section-v: 5rem;
}

/* ── Layout helpers ─────────────────────────────────────────── */
.scholars-page .wrap {
    max-width: 100%;
    margin-inline: auto;
    padding-inline: 1.5rem;
}

.scholars-section {
    padding-block: var(--sc-section-v);
}

.scholars-section--gray {
    background: var(--sc-gray-100);
}

/* ── Shared typography ──────────────────────────────────────── */
.scholars-label {
    font-family: "Inter", sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--sc-gold-dark);
    margin-bottom: 0.5rem;
}

.scholars-label--center {
    text-align: center;
}
.scholars-label--gold {
    color: var(--sc-gold);
}

.scholars-section-title {
    font-family: "Inter", sans-serif;
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    font-weight: 800;
    line-height: 1.1;
    color: var(--sc-black);
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.scholars-section-title--center {
    text-align: center;
}
.scholars-section-title--white {
    color: var(--sc-white);
}

/* ── Buttons ────────────────────────────────────────────────── */
.scholars-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.65rem 1.35rem;
    font-family: "Inter", sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    border-radius: 3px;
    text-decoration: none;
    transition:
        background 0.18s,
        color 0.18s,
        transform 0.12s;
    border: 2px solid transparent;
    white-space: nowrap;
    cursor: pointer;
}

.scholars-btn:hover {
    transform: translateY(-2px);
}

.scholars-btn--gold {
    background: var(--sc-gold);
    color: var(--sc-black);
    border-color: var(--sc-gold);
}
.scholars-btn--gold:hover {
    background: var(--sc-gold-dark);
    border-color: var(--sc-gold-dark);
}

.scholars-btn--outline {
    background: transparent;
    color: var(--sc-white);
    border-color: var(--sc-gold);
}
.scholars-btn--outline:hover {
    background: var(--sc-gold);
    color: var(--sc-black);
}

.scholars-btn--black {
    background: var(--sc-black);
    color: var(--sc-white);
    border-color: var(--sc-black);
}
.scholars-btn--black:hover {
    background: var(--sc-charcoal);
}

/* =============================================================
   HERO
   ============================================================= */
.scholars-hero {
    position: relative;
    min-height: 540px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    background-color: var(--sc-black);
}

.scholars-hero__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    opacity: 0.38;
}

.scholars-hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0) 0%,
        rgba(0, 0, 0, 0.65) 40%,
        rgba(0, 0, 0, 0.65) 100%
    ) !important;
    opacity: 1 !important;
}

/* Corner notch — 46px 45° cut from the bottom-left, matching the site
   header / section nav (replaced the full-width diagonal wedge 2026-06).
   Transparent: shows the section behind, so no fill or dark override. */
.scholars-hero {
    clip-path: polygon(
        0 0,
        100% 0,
        100% 100%,
        46px 100%,
        0 calc(100% - 46px)
    );
}

.scholars-hero__content {
    position: relative;
    z-index: 2;
    padding: 3rem 1.5rem 5rem;
    width: 100%;
}

/* Desktop: hero text lines up with the section nav's left edge — the
   section-layout wrapper below is a centered 1500px box with 2rem side
   padding, so mirror that container here. (.scholars-page .wrap would
   out-specify a bare class, hence the scoped selector.) */
@media (min-width: 768px) {
    .scholars-page .scholars-hero__content {
        max-width: 1500px;
        margin-inline: auto;
        padding-inline: 2rem;
        box-sizing: border-box; /* cap includes padding, like the wrapper */
    }
}

.scholars-hero__eyebrow {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.scholars-hero__eyebrow span,
.scholars-hero__eyebrow-link {
    font-family: "Inter", sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--sc-gold);
    text-decoration: none;
}

.scholars-hero__eyebrow-link:hover {
    color: var(--sc-white);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.scholars-hero__eyebrow::before {
    content: "";
    width: 2.5rem;
    height: 2px;
    background: var(--sc-gold);
    flex-shrink: 0;
}

.scholars-hero__title {
    font-family: "Inter", sans-serif;
    font-size: clamp(2.2rem, 5vw, 3.8rem);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.03em;
    color: var(--sc-white);
    max-width: 100% !important;
    margin-bottom: 1.25rem;
}

.scholars-hero__tagline {
    font-family: "Inter", sans-serif;
    font-size: 1.1rem;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.82);
    margin-bottom: 2rem;
    max-width: 100% !important;
    line-height: 1.65;
}

.scholars-hero__ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* =============================================================
   ABOUT
   ============================================================= */
.scholars-about {
    background: var(--sc-white);
}

.scholars-about__grid {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 4rem;
    align-items: start;
}

.scholars-about__copy {
    font-size: 1.05rem;
    color: var(--sc-charcoal);
    line-height: 1.65;
    max-width: 60ch;
    margin-bottom: 1rem;
}

.scholars-about__copy p {
    margin-bottom: 1rem;
}

.scholars-invitation {
    margin-top: 2rem;
    border-left: 4px solid var(--sc-gold);
    padding: 1.5rem 1.75rem;
    background: var(--sc-gray-100);
    border-radius: 0 6px 6px 0;
}

.scholars-invitation__heading {
    font-family: "Inter", sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--sc-black);
    margin-bottom: 1rem;
}

.scholars-invitation__list ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.scholars-invitation__list li {
    font-size: 0.95rem;
    padding-left: 1.25rem;
    position: relative;
    color: var(--sc-charcoal);
    line-height: 1.5;
}

.scholars-invitation__list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--sc-gold);
}

.scholars-about__image {
    position: relative;
}

.scholars-about__image img {
    width: 100%;
    border-radius: 6px;
    object-fit: cover;
    max-height: 580px;
    display: block;
}

.scholars-about__image::before {
    content: "";
    position: absolute;
    top: -1rem;
    right: -1rem;
    bottom: 1rem;
    left: 1rem;
    background: var(--sc-gold);
    border-radius: 6px;
    z-index: -1;
}

/* =============================================================
   ELIGIBILITY
   ============================================================= */
.scholars-elig__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.scholars-card {
    background: var(--sc-white);
    border-radius: 8px;
    padding: 2rem 2.25rem;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
}

.scholars-card--teal {
    border-top: 4px solid var(--sc-teal);
}

.scholars-card__label {
    font-family: "Inter", sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--sc-gray-400);
    margin-bottom: 0.75rem;
}

.scholars-card__title {
    font-family: "Inter", sans-serif;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--sc-black);
    margin-bottom: 1rem;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.scholars-card__body {
    font-size: 0.97rem;
    color: var(--sc-charcoal);
    line-height: 1.6;
}

.scholars-card__body p {
    margin-bottom: 0.75rem;
}
.scholars-card__body p:last-child {
    margin-bottom: 0;
}

.scholars-card__body strong {
    color: var(--sc-black);
}

/* Scholarship amount display — editors write these as <p><strong>$X,XXX / …</strong></p> */
.scholars-card--teal .scholars-card__body strong:first-of-type,
.scholars-card--teal .scholars-card__body p > strong {
    font-family: "Inter", sans-serif;
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--sc-teal);
    letter-spacing: -0.03em;
    display: block;
    line-height: 1.1;
    margin-bottom: 0.15rem;
}

/* =============================================================
   WHY SECTION (teal full-bleed)
   ============================================================= */
.scholars-why {
    background: var(--sc-teal);
    padding-block: var(--sc-section-v);
    position: relative;
    overflow: hidden;
}

.scholars-why__pattern {
    position: absolute;
    inset: 0;
    background-image: repeating-linear-gradient(
        -45deg,
        transparent,
        transparent 40px,
        rgba(255, 255, 255, 0.04) 40px,
        rgba(255, 255, 255, 0.04) 80px
    );
    pointer-events: none;
}

.scholars-why__content {
    position: relative;
    z-index: 1;
}

.scholars-why .scholars-label {
    color: var(--sc-gold);
}

.scholars-why .scholars-section-title {
    color: var(--sc-white);
    margin-bottom: 1.5rem;
}

.scholars-why__body {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.05rem;
    font-weight: 300;
    line-height: 1.7;
    max-width: 72ch;
}

.scholars-why__body p {
    margin-bottom: 1rem;
}

.scholars-why__body p:last-child {
    margin-bottom: 0;
}

/* =============================================================
   DEADLINES
   ============================================================= */
.scholars-deadlines__block {
    max-width: 700px;
    margin-inline: auto;
    margin-bottom: 2rem;
}

/* Center the subcategory title inside the block */
.scholars-deadlines__block .ugrad-upcoming-dates-subcategory-title {
    margin-left: auto !important;
}

/* The block's grid defaults to 2 columns — override to 1 so the single
   scholars deadline doesn't sit stranded in the left column */
.scholars-deadlines__block .ugrad-upcoming-deadline-with-subcategory-section,
.scholars-deadlines__block .ugrad-upcoming-deadline-no-subcategory-section {
    grid-template-columns: 1fr;
}

/* Center the event card (max-width: 554px from block CSS) within the column */
.scholars-deadlines__block .ugrad-upcoming-deadline-event-list {
    margin-inline: auto;
}

.scholars-deadlines__note {
    text-align: center;
    font-size: 0.9rem;
    color: var(--sc-charcoal);
    max-width: 60ch;
    margin-inline: auto;
    line-height: 1.55;
    margin-bottom: 2rem;
}

.scholars-deadlines__cta {
    text-align: center;
}

/* =============================================================
   TESTIMONIAL
   ============================================================= */
.scholars-testimonial {
    background: var(--sc-gray-100);
}

.scholars-testimonial__inner {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 3rem;
    align-items: center;
    max-width: 860px;
    margin-inline: auto;
}

/* Notched photo card (bottom-left) — same 46px 45-degree cut as the hero /
   section nav. The clip lives on the img; the shadow is a drop-shadow
   filter on the wrapper so it hugs the notched outline (a box-shadow
   would still trace the square corner). */
.scholars-testimonial__img {
    border-radius: 8px;
    overflow: hidden;
    filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.16));
    flex-shrink: 0;
}

.scholars-testimonial__img img {
    width: 100%;
    object-fit: cover;
    aspect-ratio: 3/4;
    display: block;
    clip-path: polygon(
        0 0,
        100% 0,
        100% 100%,
        46px 100%,
        0 calc(100% - 46px)
    );
}

.scholars-testimonial__quote {
    padding-left: 2rem;
    border-left: 4px solid var(--sc-gold);
}

.scholars-testimonial__text {
    font-family: "Inter", sans-serif;
    font-size: 1.2rem;
    font-weight: 300;
    font-style: italic;
    line-height: 1.6;
    color: var(--sc-black);
    margin-bottom: 1.25rem;
}

.scholars-testimonial__attribution {
    font-family: "Inter", sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--sc-teal);
    letter-spacing: 0.03em;
    margin: 0;
}

/* When video is used, drop the single-column gutter so embed sits centered */
.scholars-testimonial--video .scholars-testimonial__inner {
    grid-template-columns: 1fr;
    max-width: 860px;
    gap: 2rem;
}

.scholars-testimonial__video {
    aspect-ratio: 16 / 9;
    width: 100%;
    max-width: 860px;
    margin-inline: auto;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    background: var(--sc-black);
}

.scholars-testimonial__video iframe,
.scholars-testimonial__video video {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

/* =============================================================
   LOGO SOUP — "Our Scholars Make a Difference"
   ============================================================= */
.scholars-logos {
    background: var(--sc-white);
    text-align: center;
}

.scholars-logos__subhead {
    font-family: "Inter", sans-serif;
    font-size: 1rem;
    color: var(--sc-black);
    max-width: 640px;
    margin: 0 auto 2.5rem;
}

.scholars-logos__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 2rem 3rem;
    justify-content: center;
    align-items: center;
}

.scholars-logos__item {
    flex: 0 0 auto;
    max-width: 200px;
}

.scholars-logos__item img {
    max-width: 100%;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.scholars-logos__link {
    display: block;
}

/* =============================================================
   FORM SECTION
   ============================================================= */
.scholars-form-section {
    background-color: var(--sc-black);
    padding-block: var(--sc-section-v);
    position: relative;
    overflow: hidden;
    background-size: cover;
    background-position: center;
}

.scholars-form-section__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
}

.scholars-form-section__content {
    position: relative;
    z-index: 1;
}

.scholars-form-section__form {
    max-width: 600px;
    margin: 2rem auto 0;
    background: var(--sc-white);
    border-radius: 8px;
    padding: 2rem 2.5rem;
}

.scholars-form-section__placeholder {
    max-width: 600px;
    margin: 2rem auto 0;
    background: var(--sc-white);
    border-radius: 8px;
    padding: 2rem 2.5rem;
    text-align: center;
    color: var(--sc-gray-400);
    border: 2px dashed var(--sc-gray-200);
    font-size: 0.95rem;
}

.scholars-form-section__placeholder strong {
    display: block;
    color: var(--sc-black);
    margin-bottom: 0.4rem;
}

/* =============================================================
   DARK MODE  [data-theme="dark"]
   Hero, teal why-section, and form section are already dark —
   only the white/gray light surfaces need overrides.
   ============================================================= */

/* ── Light surfaces → dark ──────────────────────────────────── */
[data-theme="dark"] .scholars-about {
    background: #1e1e1e;
}

[data-theme="dark"] .scholars-section--gray {
    background: #252525;
}

/* Testimonial has its own background property — override it too */
[data-theme="dark"] .scholars-testimonial {
    background: #252525;
}

[data-theme="dark"] .scholars-card {
    background: #2c2c2c;
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
}

[data-theme="dark"] .scholars-invitation {
    background: #2c2c2c;
}

/* ── Text → light ───────────────────────────────────────────── */
[data-theme="dark"] .scholars-section-title {
    color: #f0f0f0;
}

[data-theme="dark"] .scholars-label {
    color: var(--sc-gold);
}

[data-theme="dark"] .scholars-about__copy,
[data-theme="dark"] .scholars-card__body,
[data-theme="dark"] .scholars-deadlines__note,
[data-theme="dark"] .scholars-invitation__list li {
    color: #d8d8d8;
}

[data-theme="dark"] .scholars-card__title,
[data-theme="dark"] .scholars-invitation__heading {
    color: #f0f0f0;
}

[data-theme="dark"] .scholars-card__body strong {
    color: #f0f0f0;
}

[data-theme="dark"] .scholars-testimonial__text {
    color: #e0e0e0;
}

[data-theme="dark"] .scholars-testimonial__attribution {
    color: #c8c8c8;
}

/* ── Gold decoration on invitation border ───────────────────── */
[data-theme="dark"] .scholars-invitation {
    border-left-color: var(--sc-gold);
}

/* ── Keep why-section and hero labels gold ──────────────────── */
[data-theme="dark"] .scholars-why .scholars-label {
    color: var(--sc-gold);
}

/* ── Logo soup section ─────────────────────────────────────── */
[data-theme="dark"] .scholars-logos {
    background: #252525;
}

[data-theme="dark"] .scholars-logos__subhead {
    color: #d8d8d8;
}

/* Most partner logos are dark-on-white — keep their original colors
   on a white card behind each tile so they stay legible in dark mode. */
[data-theme="dark"] .scholars-logos__item {
    background: var(--sc-white);
    padding: 0.75rem 1rem;
    border-radius: 6px;
}

/* ── Btn--black inverts in dark mode ────────────────────────── */
[data-theme="dark"] .scholars-btn--black {
    background: #e8e8e8;
    color: #1a1a1a;
    border-color: #e8e8e8;
}
[data-theme="dark"] .scholars-btn--black:hover {
    background: #ffffff;
    border-color: #ffffff;
}

/* ── Form card goes dark in dark mode ───────────────────────── */
[data-theme="dark"] .scholars-form-section__form {
    background: #2a2a2a;
    color: #f0f0f0;
    color-scheme: dark;
}

[data-theme="dark"] .scholars-form-section__form label,
[data-theme="dark"] .scholars-form-section__form p,
[data-theme="dark"] .scholars-form-section__form legend,
[data-theme="dark"] .scholars-form-section__form h1,
[data-theme="dark"] .scholars-form-section__form h2,
[data-theme="dark"] .scholars-form-section__form h3 {
    color: #f0f0f0;
}

[data-theme="dark"] .scholars-form-section__form input:not([type="submit"]),
[data-theme="dark"] .scholars-form-section__form select,
[data-theme="dark"] .scholars-form-section__form textarea {
    background-color: #3a3a3a;
    color: #f0f0f0;
    border: 1px solid #555;
    color-scheme: dark;
}

[data-theme="dark"]
    .scholars-card--teal
    .scholars-card__body
    strong:first-of-type,
[data-theme="dark"] .scholars-card--teal .scholars-card__body p > strong {
    color: #fdb515;
}

/* ── Section title white variant (on teal/dark bgs) — unchanged */
[data-theme="dark"] .scholars-section-title--white {
    color: var(--sc-white);
}

/* =============================================================
   RESPONSIVE
   ============================================================= */
@media (max-width: 960px) {
    .scholars-about__grid {
        grid-template-columns: 1fr;
    }

    .scholars-about__image {
        order: -1;
        max-width: 480px;
    }

    .scholars-about__image::before {
        display: none;
    }

    .scholars-elig__grid {
        grid-template-columns: 1fr;
    }

    .scholars-testimonial__inner {
        grid-template-columns: 1fr;
    }

    .scholars-testimonial__img {
        max-width: 220px;
    }
}

@media (max-width: 580px) {
    .scholars-page {
        --sc-section-v: 3.5rem;
    }

    .scholars-hero {
        min-height: 420px;
    }

    .scholars-hero__content {
        padding-bottom: 4rem;
    }

    .scholars-form-section__form,
    .scholars-form-section__placeholder {
        padding: 1.5rem;
    }
}
