/* Open Consulting - site styles */

:root {
    --brand: #03a9fc;
    --brand-dark: #0276b3;
    --brand-darker: #025a89;
    --brand-tint: #e6f6ff;
    --navy: #0b2236;
    --navy-2: #12304a;
    --ink: #142233;
    --muted: #51606f;
    --line: #e2e7ec;
    --bg: #ffffff;
    --bg-alt: #f5f5f5;

    --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-serif: Charter, "Bitstream Charter", "Sitka Text", Cambria, Georgia, serif;

    --radius: 12px;
    --shadow: 0 1px 2px rgba(11, 34, 54, .06), 0 8px 24px rgba(11, 34, 54, .08);
    --container: 1120px;
    --header-h: 72px;
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; height: auto; }

h1, h2, h3 {
    font-family: var(--font-serif);
    line-height: 1.2;
    color: var(--navy);
    margin: 0 0 .5em;
    text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 4.5vw + .5rem, 3.5rem); }
h2 { font-size: clamp(1.7rem, 2.5vw + .5rem, 2.4rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

a { color: var(--brand-dark); text-underline-offset: 3px; }
a:hover { color: var(--brand-darker); }

:focus-visible {
    outline: 3px solid var(--brand);
    outline-offset: 3px;
    border-radius: 4px;
}

.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
}

.skip-link {
    position: absolute;
    left: 12px;
    top: -60px;
    z-index: 100;
    padding: 10px 16px;
    background: var(--navy);
    color: #fff;
    border-radius: 8px;
}
.skip-link:focus { top: 12px; color: #fff; }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5em;
    padding: .8em 1.4em;
    border-radius: 999px;
    border: 2px solid transparent;
    font: 600 1rem/1.2 var(--font-sans);
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s, color .2s, border-color .2s, transform .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand-dark); color: #fff; }
.btn-primary:hover { background: var(--brand-darker); color: #fff; }
.btn-ghost { border-color: rgba(255, 255, 255, .6); color: #fff; }
.btn-ghost:hover { background: #fff; color: var(--navy); }
.btn-outline { border-color: var(--brand-dark); color: var(--brand-dark); }
.btn-outline:hover { background: var(--brand-dark); color: #fff; }

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, .92);
    backdrop-filter: saturate(180%) blur(10px);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    border-bottom: 1px solid var(--line);
}
.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: var(--header-h);
    gap: 16px;
}
.brand img { width: 190px; }

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--navy);
    cursor: pointer;
}
.nav-toggle svg { width: 26px; height: 26px; margin: auto; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

.site-nav ul {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.site-nav a:not(.btn) {
    display: block;
    padding: 8px 14px;
    border-radius: 8px;
    color: var(--ink);
    font-weight: 500;
    text-decoration: none;
}
.site-nav a:not(.btn):hover { color: var(--brand-dark); background: var(--brand-tint); }
.site-nav a[aria-current="page"] { color: var(--brand-dark); }
.site-nav .btn { margin-left: 10px; padding: .65em 1.2em; }

@media (max-width: 820px) {
    .js .nav-toggle { display: block; }
    .js .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow);
    }
    .js .site-nav.is-open { display: block; }
    .js .site-nav ul {
        flex-direction: column;
        align-items: stretch;
        padding: 12px 20px 20px;
    }
    .js .site-nav a:not(.btn) { padding: 12px; font-size: 1.1rem; }
    .js .site-nav .btn { margin: 8px 0 0; width: 100%; }

    /* Without JS the nav wraps under the logo */
    html:not(.js) .site-header .container { flex-wrap: wrap; padding-bottom: 10px; }
    html:not(.js) .site-nav ul { flex-wrap: wrap; }
}

/* Hero */
.hero {
    position: relative;
    isolation: isolate;
    color: #fff;
    background: var(--navy);
    overflow: hidden;
}
.hero-bg, .hero-bg img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2;
}
.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(100deg, rgba(11, 34, 54, .94) 0%, rgba(11, 34, 54, .82) 45%, rgba(11, 34, 54, .45) 100%);
}
.hero .container { padding-top: clamp(72px, 12vw, 140px); padding-bottom: clamp(72px, 12vw, 140px); }
.hero h1 { color: #fff; max-width: 20ch; }
.hero .lead { max-width: 56ch; font-size: 1.2rem; color: rgba(255, 255, 255, .88); }

.eyebrow {
    display: inline-block;
    margin-bottom: 16px;
    font-size: .85rem;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--brand-dark);
}
.hero .eyebrow, .band-dark .eyebrow { color: var(--brand); }

.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* Page header (inner pages) */
.page-header {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-2) 100%);
    color: #fff;
    padding: clamp(56px, 8vw, 96px) 0 clamp(48px, 6vw, 72px);
}
.page-header h1 { color: #fff; margin-bottom: .3em; }
.page-header p { max-width: 60ch; color: rgba(255, 255, 255, .85); font-size: 1.15rem; margin: 0; }

/* Sections */
.section { padding: clamp(64px, 9vw, 104px) 0; }
.section-alt { background: var(--bg-alt); }
.section-head { max-width: 680px; margin-bottom: 44px; }
.section-head p { color: var(--muted); font-size: 1.1rem; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }

.band-dark { background: var(--navy); color: rgba(255, 255, 255, .88); }
.band-dark h2 { color: #fff; }

/* Grids and cards */
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 28px;
    transition: box-shadow .2s, transform .2s, border-color .2s;
}
.card p { color: var(--muted); margin: 0; }
.card h3 { margin-bottom: .4em; }
a.card { display: block; color: inherit; text-decoration: none; }
a.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }

.icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    margin-bottom: 18px;
    border-radius: 12px;
    background: var(--brand-tint);
    color: var(--brand-dark);
}
.icon svg { width: 24px; height: 24px; }

.value { display: flex; gap: 16px; align-items: flex-start; }
.value .icon { flex: none; margin: 0; }
.value h3 { margin-bottom: .25em; }
.value p { color: var(--muted); margin: 0; }

/* Split layout */
.split {
    display: grid;
    gap: clamp(32px, 6vw, 72px);
    align-items: center;
    grid-template-columns: 1fr;
}
@media (min-width: 900px) {
    .split { grid-template-columns: 1.1fr .9fr; }
}

.checklist { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.checklist li { position: relative; padding-left: 32px; }
.checklist li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .3em;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--brand-dark) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / 12px no-repeat;
}

/* Rates */
.rate-list {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}
.rate {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 28px;
    border-top: 1px solid var(--line);
}
.rate:first-child { border-top: 0; }
.rate-name { font-weight: 600; }
.rate-name small { display: block; font-weight: 400; color: var(--muted); font-size: .95rem; }
.rate-price {
    font-family: var(--font-serif);
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--navy);
    white-space: nowrap;
}
.rate-price span { font-family: var(--font-sans); font-size: .95rem; font-weight: 400; color: var(--muted); }
.rate-featured { background: var(--brand-tint); }
.rate-featured .rate-price { color: var(--brand-dark); }
.note { color: var(--muted); font-size: .95rem; margin-top: 20px; }

.stat-card {
    background: var(--navy);
    color: #fff;
    border-radius: var(--radius);
    padding: 36px;
}
.stat-card .big {
    font-family: var(--font-serif);
    font-size: clamp(2.6rem, 6vw, 3.6rem);
    font-weight: 700;
    line-height: 1;
    color: var(--brand);
}
.stat-card .big small { font-size: .4em; color: rgba(255, 255, 255, .7); }
.stat-card p { color: rgba(255, 255, 255, .85); }

/* How it works */
.steps {
    list-style: none;
    counter-reset: step;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.steps li { counter-increment: step; }
.steps li::before {
    content: counter(step);
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    margin-bottom: 16px;
    border-radius: 50%;
    background: var(--brand-dark);
    color: #fff;
    font-weight: 700;
}
.steps p { color: var(--muted); margin: 0; }

/* Projects */
.project .metric {
    font-family: var(--font-serif);
    font-size: 2.4rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--brand-dark);
    margin-bottom: 16px;
}
.project .metric span {
    display: block;
    font-family: var(--font-sans);
    font-size: .85rem;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--muted);
}

/* FAQ */
.narrow { max-width: 800px; }
.faq details {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    margin-bottom: 12px;
}
.faq summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    font-weight: 600;
    color: var(--navy);
    cursor: pointer;
    list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
    content: "+";
    flex: none;
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 1;
    color: var(--brand-dark);
}
.faq details[open] summary::after { content: "\2212"; }
.faq details p { padding: 0 24px 20px; margin: 0; color: var(--muted); }

/* Highlight the service linked from the home page */
.card:target { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-tint), var(--shadow); }

/* Contact */
.contact-card .label { display: block; color: var(--muted); font-size: .9rem; }
.contact-card .value-text { font-size: 1.15rem; font-weight: 600; color: var(--navy); overflow-wrap: anywhere; }

/* CTA */
.cta { text-align: center; }
.cta p { max-width: 56ch; margin: 0 auto; font-size: 1.1rem; }
.cta .actions { justify-content: center; }

/* Footer */
.site-footer {
    background: #081a2a;
    color: rgba(255, 255, 255, .72);
    padding: 56px 0 28px;
    font-size: .95rem;
}
.site-footer a { color: rgba(255, 255, 255, .85); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-grid {
    display: grid;
    gap: 32px;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.footer-grid img { width: 180px; margin-bottom: 14px; }
.footer-grid h2 {
    font-family: var(--font-sans);
    font-size: .8rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 14px;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.footer-bottom {
    margin-top: 40px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, .12);
    font-size: .875rem;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition: none !important; }
}
