/* ==========================================================================
   Students Corner shared styles — everything namespaced under sc- so
   nothing bleeds into existing site styles (including y2hero-*).
   Palette: ink navy #14264C · pencil yellow #F5B91E · warm paper #FBFAF6
   ========================================================================== */

:root {
    --sc-ink: #14264C;
    --sc-pencil: #F5B91E;
    --sc-paper: #FBFAF6;
    --sc-mist: #D9DEEA;
    --sc-ink-soft: #3D4E75;
    --sc-line: #E7E3D8;
    --sc-white: #FFFFFF;
    --sc-green: #2E7D4F;
    --sc-red: #B3413A;
    --sc-radius: 14px;
    --sc-shadow: 0 2px 10px rgba(20, 38, 76, 0.08);
    --sc-font-display: 'Fraunces', Georgia, serif;
    --sc-font-body: 'Public Sans', system-ui, sans-serif;
}

/* ---------- page scaffold ---------- */

.sc-main {
    font-family: var(--sc-font-body);
    background: var(--sc-paper);
    color: var(--sc-ink);
    line-height: 1.6;
    padding: 0 20px 64px;
    min-height: 60vh;
}

.sc-wrap {
    max-width: 980px;
    margin: 0 auto;
}

.sc-main h1,
.sc-main h2,
.sc-main h3 {
    font-family: var(--sc-font-display);
    font-weight: 650;
    color: var(--sc-ink);
    line-height: 1.18;
}

.sc-eyebrow {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--sc-ink-soft);
    margin: 0 0 10px;
}

.sc-lead {
    color: var(--sc-ink-soft);
    font-size: 1.05rem;
    max-width: 40em;
}

.sc-footnote {
    font-size: 0.82rem;
    color: var(--sc-ink-soft);
    border-top: 1px solid var(--sc-line);
    padding-top: 14px;
    margin-top: 40px;
}

.sc-visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

/* ---------- buttons ---------- */

.sc-btn {
    display: inline-block;
    background: var(--sc-pencil);
    color: var(--sc-ink);
    font-family: var(--sc-font-body);
    font-weight: 700;
    font-size: 1rem;
    border: none;
    border-radius: 10px;
    padding: 13px 26px;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.sc-btn:hover,
.sc-btn:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(245, 185, 30, 0.45);
}

.sc-btn-ghost {
    display: inline-block;
    background: transparent;
    color: var(--sc-ink);
    font-weight: 600;
    border: 2px solid var(--sc-ink);
    border-radius: 10px;
    padding: 11px 22px;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
}

.sc-btn-ghost:hover,
.sc-btn-ghost:focus-visible {
    background: var(--sc-ink);
    color: var(--sc-paper);
}

/* ---------- shared header strip (breadcrumb + portal button) ---------- */

.sc-strip {
    background: var(--sc-ink);
    color: var(--sc-mist);
    font-family: var(--sc-font-body);
    padding: 10px 20px;
}

.sc-strip-inner {
    max-width: 980px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
}

.sc-crumb {
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.sc-crumb a {
    color: var(--sc-mist);
    text-decoration: none;
}

.sc-crumb a:hover,
.sc-crumb a:focus-visible {
    color: var(--sc-pencil);
    text-decoration: underline;
}

.sc-crumb [aria-current="page"] {
    color: var(--sc-white);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sc-crumb-sep {
    color: var(--sc-pencil);
}

.sc-portal-link {
    background: var(--sc-pencil);
    color: var(--sc-ink);
    font-weight: 700;
    font-size: 0.88rem;
    border-radius: 8px;
    padding: 7px 14px;
    text-decoration: none;
    white-space: nowrap;
}

.sc-portal-link:hover,
.sc-portal-link:focus-visible {
    box-shadow: 0 3px 10px rgba(245, 185, 30, 0.5);
}

/* ---------- cards ---------- */

.sc-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.sc-card {
    background: var(--sc-white);
    border: 1px solid var(--sc-line);
    border-radius: var(--sc-radius);
    box-shadow: var(--sc-shadow);
    padding: 22px;
}

.sc-card h3 {
    margin: 0 0 8px;
    font-size: 1.12rem;
}

.sc-card p {
    margin: 0;
    color: var(--sc-ink-soft);
    font-size: 0.95rem;
}

/* ---------- accordion (portal troubleshooting, Camp HQ weeks) ---------- */

.sc-acc {
    border: 1px solid var(--sc-line);
    border-radius: var(--sc-radius);
    background: var(--sc-white);
    overflow: hidden;
}

.sc-acc + .sc-acc {
    margin-top: 12px;
}

.sc-acc summary {
    font-family: var(--sc-font-body);
    font-weight: 700;
    font-size: 1rem;
    color: var(--sc-ink);
    padding: 16px 20px;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.sc-acc summary::-webkit-details-marker {
    display: none;
}

.sc-acc summary::after {
    content: "+";
    font-size: 1.3rem;
    color: var(--sc-pencil);
    font-weight: 700;
    flex-shrink: 0;
    line-height: 1;
}

.sc-acc[open] summary::after {
    content: "–";
}

.sc-acc summary:focus-visible {
    outline: 3px solid var(--sc-pencil);
    outline-offset: -3px;
}

.sc-acc-body {
    padding: 0 20px 18px;
    color: var(--sc-ink-soft);
    font-size: 0.95rem;
}

.sc-acc-body a {
    color: var(--sc-ink);
    font-weight: 600;
}

/* ---------- password gate overlay ---------- */

.sc-gate {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: var(--sc-paper);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    font-family: var(--sc-font-body);
    visibility: visible;
}

.sc-gate-card {
    max-width: 420px;
    width: 100%;
    text-align: center;
}

.sc-gate-title {
    font-family: var(--sc-font-display);
    font-weight: 650;
    font-size: clamp(1.8rem, 5vw, 2.4rem);
    color: var(--sc-ink);
    margin: 0 0 10px;
}

.sc-gate-sub {
    color: var(--sc-ink-soft);
    margin: 0 0 24px;
}

.sc-gate-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.sc-gate-input {
    flex: 1 1 200px;
    font-family: var(--sc-font-body);
    font-size: 1rem;
    color: var(--sc-ink);
    background: var(--sc-white);
    border: 2px solid var(--sc-mist);
    border-radius: 10px;
    padding: 12px 16px;
}

.sc-gate-input:focus {
    outline: none;
    border-color: var(--sc-pencil);
}

.sc-gate-btn {
    flex: 0 0 auto;
}

.sc-gate-error {
    color: var(--sc-red);
    font-size: 0.92rem;
    margin: 16px 0 0;
}

.sc-gate-shake {
    animation: sc-shake 0.35s ease;
}

@keyframes sc-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-7px); }
    75% { transform: translateX(7px); }
}

/* ---------- responsive ---------- */

@media (max-width: 900px) {
    .sc-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .sc-grid {
        grid-template-columns: 1fr;
    }

    .sc-strip-inner {
        justify-content: center;
        text-align: center;
    }
}
