/* ==========================================================================
   CreatrCollective — ocean-light theme
   Hand-rolled vanilla CSS. Palette adapted from the Wharfinger UI guide
   (docs/ui_styles.md) from its dark-mode-first definitions to a light scheme.
   "CSS variables everywhere": components reference custom properties, not hex.
   ========================================================================== */

/* ----- Design tokens ----------------------------------------------------- */
:root {
    /* Brand — ocean gradient */
    --brand-teal: #006466;
    --brand-teal-hover: #065a60;
    --brand-teal-active: #0b525b;
    --brand-navy: #1b3a4b;
    --brand-navy-deep: #144552;
    --brand-sky: #86bbd8;
    --brand-amber: #f6ae2d;
    --brand-orange: #f26419;

    /* Surfaces & text (light mode) */
    --bg: #ffffff;
    --bg-alt: #f4f8f9;          /* sky-tinted section background */
    --bg-navy: #122230;         /* dark band (footer / dark CTA) */
    --surface: #ffffff;
    --surface-hover: #eef4f6;
    --text: #1b2a36;
    --text-secondary: #46606f;
    --text-muted: #6b8290;
    --text-on-dark: #e2e8f0;
    --text-on-dark-muted: #9fb3c0;
    --border: #e2eaee;

    /* Effects */
    --radius: 12px;
    --radius-sm: 8px;
    --shadow-sm: 0 1px 2px rgba(18, 34, 48, 0.06);
    --shadow-md: 0 6px 20px rgba(18, 34, 48, 0.08);
    --shadow-lg: 0 18px 40px rgba(18, 34, 48, 0.12);

    /* Layout */
    --container: 1120px;
    --nav-h: 70px;

    /* Type */
    --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial,
        "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 17px;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
    margin: 0 0 0.5em;
    line-height: 1.2;
    color: var(--brand-navy);
    font-weight: 700;
    letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 4.5vw, 3.3rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1rem; }

a {
    color: var(--brand-teal);
    text-decoration: none;
    transition: color 0.15s ease;
}
a:hover { color: var(--brand-teal-hover); text-decoration: underline; }

img { max-width: 100%; display: block; }

ul { margin: 0 0 1rem; padding-left: 1.2rem; }
li { margin-bottom: 0.35rem; }

/* Small inline "see more" style link with a nudging arrow. */
.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 600;
    font-size: 0.95rem;
}
.link-arrow:hover { text-decoration: none; }
.link-arrow span { transition: transform 0.15s ease; }
.link-arrow:hover span { transform: translateX(3px); }

/* ----- Layout helpers ---------------------------------------------------- */
.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: 24px;
}

.section {
    padding-block: clamp(48px, 8vw, 88px);
}
.section--alt { background: var(--bg-alt); }
.section--navy {
    background: var(--bg-navy);
    color: var(--text-on-dark);
}
.section--navy h2 { color: #fff; }

.section__head {
    max-width: 680px;
    margin-bottom: 2.5rem;
}
.section__head--center {
    margin-inline: auto;
    text-align: center;
}

.eyebrow {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--brand-teal);
    margin-bottom: 0.75rem;
}
.section--navy .eyebrow { color: var(--brand-sky); }

.lead {
    font-size: 1.15rem;
    color: var(--text-secondary);
}

.founder-byline {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 1.5rem;
}
.founder-byline__name {
    margin: 0;
    line-height: 1.1;
}
.founder-byline__role {
    margin: 0.3rem 0 0;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-secondary);
}
.founder-byline__img {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

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

/* ----- Buttons ----------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    line-height: 1;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease,
        transform 0.05s ease;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }

.btn-primary {
    background: var(--brand-teal);
    color: #fff;
}
.btn-primary:hover { background: var(--brand-teal-hover); color: #fff; }

.btn-ghost {
    background: transparent;
    color: var(--brand-teal);
    border-color: var(--border);
}
.btn-ghost:hover { background: var(--surface-hover); color: var(--brand-teal-hover); }

.btn-amber {
    background: var(--brand-amber);
    color: #3a2a00;
}
.btn-amber:hover { background: #ffbe4a; color: #3a2a00; }

/* On dark bands */
.section--navy .btn-ghost,
.cta-band .btn-ghost {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
}
.section--navy .btn-ghost:hover,
.cta-band .btn-ghost:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* ----- Navbar ------------------------------------------------------------ */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: saturate(180%) blur(8px);
    border-bottom: 1px solid var(--border);
}
.navbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--nav-h);
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--brand-navy);
    letter-spacing: -0.02em;
}
.brand:hover { text-decoration: none; color: var(--brand-navy); }
.brand__mark {
    width: 30px;
    height: 30px;
    border-radius: 8px;
    display: inline-grid;
    place-items: center;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--brand-teal), var(--brand-navy));
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav-links a {
    display: inline-block;
    padding: 0.5rem 0.9rem;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.97rem;
}
.nav-links a:hover {
    color: var(--brand-teal);
    background: var(--surface-hover);
    text-decoration: none;
}
.nav-links a.is-active {
    color: var(--brand-teal);
}
.nav-links a.is-active::after {
    content: "";
    display: block;
    height: 2px;
    border-radius: 2px;
    margin-top: 3px;
    background: var(--brand-sky);
}
.nav-links .btn { padding: 0.6rem 1.1rem; }
/* Keep the CTA button's own colors — `.nav-links a` above is more specific than
   `.btn-primary`, so without these the white text gets overridden to slate. */
.nav-links a.btn-primary {
    color: #fff;
    background: var(--brand-teal);
}
.nav-links a.btn-primary:hover {
    color: #fff;
    background: var(--brand-teal-hover);
}

.nav-toggle {
    display: none;
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    width: 42px;
    height: 42px;
    cursor: pointer;
    color: var(--brand-navy);
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
    content: "";
    display: block;
    width: 20px;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    margin-inline: auto;
    position: relative;
    transition: transform 0.2s ease;
}
.nav-toggle span::before { position: absolute; top: -6px; }
.nav-toggle span::after { position: absolute; top: 6px; }

/* ----- Hero -------------------------------------------------------------- */
.hero {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(900px 400px at 85% -10%, rgba(134, 187, 216, 0.28), transparent 60%),
        radial-gradient(700px 360px at 0% 110%, rgba(0, 100, 102, 0.10), transparent 60%),
        var(--bg-alt);
    border-bottom: 1px solid var(--border);
}
.hero__inner {
    padding-block: clamp(56px, 9vw, 100px);
    max-width: 740px;
}
.hero h1 { margin-bottom: 1rem; }
.hero .lead { margin-bottom: 1.75rem; max-width: 620px; }
.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
}

/* ----- Cards ------------------------------------------------------------- */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
    height: 100%;
}
.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: #cfe0e7;
}
.card h3 { margin-bottom: 0.4rem; }
.card p { margin-bottom: 0; color: var(--text-secondary); }

.card__icon {
    width: 46px;
    height: 46px;
    border-radius: 11px;
    display: grid;
    place-items: center;
    margin-bottom: 1rem;
    background: rgba(0, 100, 102, 0.10);
    color: var(--brand-teal);
}
.card__icon svg {
    width: 26px;
    height: 26px;
    display: block;
}

/* ----- Case studies ------------------------------------------------------ */
.case {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    margin-bottom: 28px;
}
.case__header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem 1rem;
    padding: 1.25rem 1.75rem;
    border-bottom: 1px solid var(--border);
    background: var(--bg-alt);
}
.case__number {
    flex: none;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    font-weight: 800;
    color: #fff;
    background: linear-gradient(135deg, var(--brand-teal), var(--brand-navy));
}
.case__title { margin: 0; font-size: 1.3rem; }
.case__tag {
    margin-left: auto;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--brand-teal);
    background: rgba(0, 100, 102, 0.10);
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
}
.case__body { padding: 1.5rem 1.75rem; }
.case__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem 2rem;
}
.case__block h4 {
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.35rem;
}
.case__block p { margin-bottom: 0; color: var(--text-secondary); }

.case__metrics {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1.25rem 1.75rem;
    border-top: 1px solid var(--border);
    background: var(--bg-alt);
}
.metric {
    flex: 1 1 160px;
}
.metric__value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--brand-teal);
    line-height: 1.1;
}
.metric__label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* ----- About list -------------------------------------------------------- */
.checklist {
    list-style: none;
    padding: 0;
    margin: 0;
}
.checklist li {
    position: relative;
    padding-left: 1.9rem;
    margin-bottom: 0.85rem;
    color: var(--text-secondary);
}
.checklist li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: 0;
    width: 1.35rem;
    height: 1.35rem;
    display: grid;
    place-items: center;
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--brand-teal);
    background: rgba(0, 100, 102, 0.10);
    border-radius: 50%;
}

/* ----- CTA band ---------------------------------------------------------- */
.cta-band {
    background: linear-gradient(135deg, var(--brand-teal), var(--brand-navy));
    color: #fff;
    border-radius: var(--radius);
    padding: clamp(2rem, 5vw, 3.25rem);
    text-align: center;
}
.cta-band h2 { color: #fff; margin-bottom: 0.75rem; }
.cta-band p { color: rgba(255, 255, 255, 0.85); max-width: 560px; margin-inline: auto; }
.cta-band .hero__actions { justify-content: center; margin-top: 1.5rem; }

/* ----- Contact ----------------------------------------------------------- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    align-items: start;
}
.info-item {
    display: flex;
    gap: 0.9rem;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}
.info-item__icon {
    flex: none;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    background: rgba(0, 100, 102, 0.10);
    color: var(--brand-teal);
}
.info-item__icon svg {
    width: 22px;
    height: 22px;
    display: block;
}
.info-item__label {
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.15rem;
}
.info-item strong { color: var(--brand-navy); }

.form-frame {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 0.5rem;
    min-height: 800px;
}
.form-frame iframe {
    width: 100%;
    height: 690px;
    border: 0;
    border-radius: var(--radius-sm);
}
.form-placeholder {
    min-height: 500px;
    border: 2px dashed var(--border);
    border-radius: var(--radius-sm);
    display: grid;
    place-items: center;
    text-align: center;
    color: var(--text-muted);
    padding: 2rem;
}
.form-placeholder code {
    background: var(--surface-hover);
    padding: 0.15rem 0.45rem;
    border-radius: 5px;
    font-size: 0.85rem;
    color: var(--brand-navy);
}

/* ----- Footer ------------------------------------------------------------ */
.footer {
    background: var(--bg-navy);
    color: var(--text-on-dark-muted);
    padding-block: 48px 28px;
}
.footer__top {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.footer .brand { color: #fff; margin-bottom: 0.75rem; }
.footer__tagline { max-width: 320px; color: var(--text-on-dark-muted); }
.footer__col h4 {
    color: #fff;
    font-size: 0.85rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 0.9rem;
}
.footer__col a,
.footer__col p { color: var(--text-on-dark-muted); margin-bottom: 0.5rem; }
.footer__col a:hover { color: #fff; }
.footer__bottom {
    padding-top: 22px;
    font-size: 0.875rem;
    color: var(--text-on-dark-muted);
}

/* ----- Responsive -------------------------------------------------------- */
@media (max-width: 900px) {
    .grid--3 { grid-template-columns: repeat(2, 1fr); }
    .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
    .nav-toggle { display: inline-grid; place-items: center; }
    .nav-links {
        position: absolute;
        top: var(--nav-h);
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0.25rem;
        background: #fff;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-md);
        padding: 0.75rem 1rem 1.1rem;
        display: none;
    }
    .nav-links.is-open { display: flex; }
    .nav-links a { padding: 0.7rem 0.9rem; }
    .nav-links a.is-active::after { display: none; }
    .nav-links .btn { margin-top: 0.35rem; }
}

@media (max-width: 620px) {
    .grid--3,
    .grid--2,
    .case__grid { grid-template-columns: 1fr; }
    .case__tag { margin-left: 0; }
}
