/* =====================================================================
   Schools Connect: public site
   Shared by Home, Features, Who it's for, About and Contact.
   Page-specific rules stay in each .aspx's own <style> block; only
   things used by two or more pages live here.

   Palette is taken from the logo: navy and blue for structure,
   orange only as a small accent (rules, markers, one button).
   ===================================================================== */

:root {
    --navy: #0E2A57;
    --blue: #1B4F9C;
    --blue-wash: #E9EFF9;
    --orange: #F28A1B;
    --paper: #F4F6FA;
    --white: #FFFFFF;
    --ink: #16223A;
    --muted: #4F5F7A;
    --rule: #D6DDE9;

    --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    --sans: 'Public Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

    --wrap: 1180px;
    --gutter: 28px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--white);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

h1, h2 {
    font-family: var(--serif);
    font-weight: 600;
    color: var(--navy);
    letter-spacing: -0.01em;
    margin: 0;
}
h3, h4, h5 {
    font-family: var(--sans);
    font-weight: 600;
    color: var(--ink);
    margin: 0;
}
p { margin: 0; }
a { text-decoration: none; color: var(--blue); }
ul { margin: 0; padding: 0; list-style: none; }

.wrap {
    width: 100%;
    max-width: calc(var(--wrap) + var(--gutter) * 2);
    margin: 0 auto;
    padding: 0 var(--gutter);
    position: relative;
}

/* Keyboard focus: always visible */
a:focus-visible, button:focus-visible, input:focus-visible,
textarea:focus-visible, select:focus-visible {
    outline: 3px solid var(--blue);
    outline-offset: 2px;
}
.on-dark a:focus-visible, .on-dark button:focus-visible {
    outline-color: #fff;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 8px;
    background: var(--navy);
    color: #fff;
    padding: 10px 16px;
    border-radius: 6px;
    z-index: 100;
}
.skip-link:focus { left: 12px; color: #fff; }

/* ===== NAV ===== */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--white);
    border-bottom: 1px solid var(--rule);
}
.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 68px;
}
.site-nav .brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--serif);
    font-weight: 700;
    font-size: 21px;
    letter-spacing: -0.01em;
    color: var(--navy);
    flex-shrink: 0;
}
.site-nav .brand img { height: 36px; width: auto; display: block; filter: brightness(1.012); }
.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
}
.nav-links a.nav-link {
    color: var(--ink);
    font-weight: 500;
    font-size: 15px;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
    transition: color .15s ease, border-color .15s ease;
}
.nav-links a.nav-link:hover { color: var(--blue); }
.nav-links a.nav-link.active {
    color: var(--navy);
    font-weight: 600;
    border-bottom-color: var(--orange);
}
.nav-cta {
    background: var(--navy);
    color: #fff;
    padding: 10px 22px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 15px;
    transition: background .15s ease;
    flex-shrink: 0;
}
.nav-cta:hover { background: var(--blue); color: #fff; }
.nav-toggle {
    display: none;
    background: none;
    border: 1px solid var(--rule);
    border-radius: 6px;
    font-size: 18px;
    color: var(--navy);
    cursor: pointer;
    padding: 6px 12px;
}

/* ===== BUTTONS ===== */
.btn-solid, .btn-line, .btn-accent, .btn-line-dark {
    display: inline-block;
    padding: 13px 26px;
    border-radius: 6px;
    font-family: var(--sans);
    font-weight: 600;
    font-size: 15.5px;
    line-height: 1.2;
    border: 1.5px solid transparent;
    transition: background .15s ease, color .15s ease, border-color .15s ease;
    cursor: pointer;
}
.btn-solid { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-solid:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-line { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-line:hover { background: var(--blue-wash); color: var(--navy); }
.btn-accent { background: var(--orange); color: var(--navy); border-color: var(--orange); }
.btn-accent:hover { background: #ffa142; border-color: #ffa142; color: var(--navy); }
.btn-line-dark { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.btn-line-dark:hover { background: rgba(255,255,255,.1); color: #fff; }

.text-link {
    color: var(--blue);
    font-weight: 600;
    border-bottom: 1.5px solid currentColor;
    padding-bottom: 1px;
}
.text-link:hover { color: var(--navy); }

/* ===== PAGE HEADER (inner pages) =====
   A navy rule with a short orange segment: the logo's two colours. */
.page-head,
.hero {
    border-top: 4px solid var(--navy);
    background: var(--paper);
    position: relative;
}
.page-head::before,
.hero::before {
    content: '';
    position: absolute;
    top: -4px;
    left: max(var(--gutter), calc(50% - var(--wrap) / 2));
    width: 84px;
    height: 4px;
    background: var(--orange);
}
.page-head { padding: 72px 0 64px; border-bottom: 1px solid var(--rule); }
.page-head h1 {
    font-size: 46px;
    line-height: 1.12;
    max-width: 30ch;
    margin-bottom: 18px;
}
.page-head p.lead {
    font-size: 18.5px;
    color: var(--muted);
    max-width: 60ch;
    line-height: 1.6;
}

/* ===== SECTIONS ===== */
.section { padding: 84px 0; }
.section-paper { background: var(--paper); }
.split + .split { margin-top: 72px; }

.split {
    display: grid;
    grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
    gap: 64px;
    align-items: start;
}
.split-head h2 { font-size: 32px; line-height: 1.2; margin-bottom: 14px; }
.split-head p { color: var(--muted); max-width: 38ch; }
.split-head .text-link { display: inline-block; margin-top: 22px; }
.split-head { position: sticky; top: 100px; }

/* ===== RULED ITEMS (replaces the card grids) ===== */
.rule-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 44px;
}
.rule-grid.one { grid-template-columns: minmax(0, 1fr); }
.rule-item {
    border-top: 1px solid var(--rule);
    padding: 24px 0 30px;
    display: grid;
    grid-template-columns: 30px minmax(0, 1fr);
    column-gap: 12px;
}
.rule-item > i {
    color: var(--blue);
    font-size: 17px;
    line-height: 1.5;
    margin-top: 2px;
}
.rule-item h3 { font-size: 17px; line-height: 1.35; margin-bottom: 6px; }
.rule-item p { font-size: 15px; color: var(--muted); line-height: 1.6; max-width: 56ch; }

/* ===== DARK BAND ===== */
.band {
    background: var(--navy);
    color: #fff;
    padding: 84px 0;
}
.band h2 { color: #fff; font-size: 32px; line-height: 1.2; margin-bottom: 14px; }
.band .split-head p { color: rgba(255,255,255,.78); }
.band .rule-item { border-top-color: rgba(255,255,255,.2); }
.band .rule-item > i { color: var(--orange); }
.band .rule-item h3 { color: #fff; }
.band .rule-item p { color: rgba(255,255,255,.76); }
.band .text-link { color: #fff; }
.band .text-link:hover { color: var(--orange); }

/* ===== CLOSING CALL TO ACTION ===== */
.cta {
    background: var(--paper);
    border-top: 1px solid var(--rule);
    padding: 64px 0;
}
.cta .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    flex-wrap: wrap;
}
.cta h2 { font-size: 30px; line-height: 1.2; margin-bottom: 8px; }
.cta p { color: var(--muted); max-width: 52ch; }

/* ===== FOOTER ===== */
.site-footer {
    background: var(--white);
    border-top: 1px solid var(--rule);
    padding: 56px 0 28px;
    font-size: 14.5px;
    color: var(--muted);
}
.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr));
    gap: 48px;
    padding-bottom: 40px;
}
.footer-brand img {
    height: 112px;
    width: auto;
    display: block;
    mix-blend-mode: multiply; /* the logo file has a white background */
    filter: brightness(1.012); /* lifts the file's 254 white to pure white */
    margin: -8px 0 10px -6px;
}
.footer-brand p { max-width: 34ch; }
.site-footer h4 {
    font-size: 14.5px;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 14px;
}
.footer-col a {
    display: block;
    color: var(--muted);
    padding: 4px 0;
}
.footer-col a:hover { color: var(--blue); }
.footer-base {
    border-top: 1px solid var(--rule);
    padding-top: 22px;
    display: flex;
    justify-content: space-between;
    gap: 12px 32px;
    flex-wrap: wrap;
    font-size: 13.5px;
}
.footer-base .brand-word { font-weight: 700; color: var(--navy); }

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
    :root { --gutter: 22px; }
    .page-head { padding: 52px 0 46px; }
    .page-head h1 { font-size: 36px; }
    .section { padding: 60px 0; }
    .split + .split { margin-top: 52px; }
    .split { grid-template-columns: minmax(0, 1fr); gap: 28px; }
    .split-head { position: static; }
    .band { padding: 60px 0; }

    .nav-links { display: none; }
    .nav-toggle { display: block; }
    .site-nav.nav-open .nav-links {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        padding: 14px var(--gutter) 22px;
        gap: 4px;
        border-bottom: 1px solid var(--rule);
        box-shadow: 0 14px 24px rgba(14,42,87,.08);
    }
    .site-nav.nav-open .nav-links a.nav-link {
        padding: 12px 0;
        border-bottom: 1px solid var(--rule);
    }
    .site-nav.nav-open .nav-cta { text-align: center; margin-top: 12px; }

    .footer-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
    .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 700px) {
    .rule-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 520px) {
    .page-head h1 { font-size: 30px; }
    .split-head h2, .band h2, .cta h2 { font-size: 26px; }
    .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 30px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; animation: none !important; }
}
