/* Zootom Search - shared styles for the public pages (home, terms, privacy). */

:root {
    --bg: #fbfbf9;
    --bg-2: #f3f2ee;
    --panel: #ffffff;
    --panel-strong: #f1f0ec;
    --line: rgba(20, 20, 30, 0.10);
    --ink: #14131a;
    --muted: #55545f;
    --dim: #8b8a95;
    --accent: #89c438;          /* Zootom logo green */
    --accent-text: #537722;     /* same green, darkened so small text stays readable on white */
    --accent-ink: #14131a;      /* text on green buttons */
    --shadow: 0 1px 2px rgba(20, 20, 40, 0.04), 0 8px 24px rgba(20, 20, 40, 0.06);
    --brand: #23a780;
    /* Zootom logo colours */
    --c-yellow: #f1ce18;
    --c-purple: #a88bbb;
    --c-green: #89c438;
    --c-orange: #f99132;
    --c-blue: #4ba8ed;
    --c-coral: #fe6c55;
    --c-teal: #00899c;
    --radius: 22px;
    --serif: "Instrument Serif", "Times New Roman", serif;
    --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
}

a {
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

.wrap {
    width: min(1180px, 100% - 32px);
    margin-inline: auto;
}

/* ---------- Top bar ---------- */
.topbar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    padding: 20px 28px;
    position: relative;
    z-index: 30;
}

.brand {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    transition: transform .25s ease;
}

.brand:hover {
    transform: translateY(-1px);
}

.brand img {
    height: 26px;
    width: auto;
}

.topbar-tagline {
    margin: 0;
    max-width: 440px;
    text-align: center;
    font-size: 13px;
    line-height: 1.45;
    color: var(--muted);
}

.topbar-actions {
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pill-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 999px;
    background: var(--accent);
    color: var(--accent-ink);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: transform .2s ease, box-shadow .2s ease;
}

.pill-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 28px rgba(137, 196, 56, 0.28);
}

.ghost-link {
    font-size: 14px;
    color: var(--muted);
    text-decoration: none;
    padding: 10px 6px;
}

.ghost-link:hover {
    color: var(--ink);
}

/* ---------- Type ---------- */
.eyebrow {
    display: inline-block;
    margin-bottom: 18px;
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--accent-text);
}

.h2 {
    margin: 0 0 18px;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(40px, 5.4vw, 72px);
    line-height: 1;
    letter-spacing: -0.01em;
}

.h2 em {
    color: var(--accent-text);
}

.lead {
    margin: 0;
    color: var(--muted);
    font-size: 17px;
    max-width: 620px;
}

.center {
    text-align: center;
}

.center .lead {
    margin-inline: auto;
}

.icon {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    background: rgba(137, 196, 56, 0.12);
    color: var(--accent-text);
    margin-bottom: 20px;
}

.icon svg {
    width: 22px;
    height: 22px;
}

/* ---------- Footer ---------- */
.site-footer {
    border-top: 1px solid var(--line);
    padding: 72px 0 36px;
    background: var(--bg-2);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.4fr;
    gap: 40px;
}

.site-footer h4 {
    margin: 0 0 14px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--dim);
}

.site-footer p,
.site-footer li {
    color: var(--muted);
    font-size: 14px;
}

.site-footer p {
    margin: 0;
}

.site-footer ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 8px;
}

.site-footer ul a {
    text-decoration: none;
}

.site-footer ul a:hover {
    color: var(--accent-text);
}

.socials {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

.socials a {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--panel-strong);
    color: var(--ink);
    transition: background .2s ease, color .2s ease;
}

.socials a:hover {
    background: var(--accent);
    color: var(--accent-ink);
}

.socials svg {
    width: 18px;
    height: 18px;
}

.copyright {
    margin-top: 56px !important;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    text-align: center;
    font-size: 13px !important;
    color: var(--dim) !important;
}

/* ---------- Reveal on scroll ---------- */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity .8s ease, transform .8s ease;
}

.reveal.is-in {
    opacity: 1;
    transform: none;
}

/* ---------- Legal pages (terms, privacy) ---------- */
.legal-hero {
    position: relative;
    padding: 70px 0 60px;
    text-align: center;
    isolation: isolate;
}

.legal-hero::before {
    content: "";
    position: absolute;
    inset: -120px 0 0;
    z-index: -1;
    background:
        radial-gradient(45% 60% at 50% 30%, rgba(137, 196, 56, 0.12), transparent 70%),
        radial-gradient(30% 40% at 20% 60%, rgba(169, 139, 217, 0.08), transparent 70%);
}

.legal-hero h1 {
    margin: 0 0 18px;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(52px, 9vw, 120px);
    line-height: .95;
    letter-spacing: -0.01em;
}

.legal-hero h1 em {
    color: var(--accent-text);
}

.legal-meta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 999px;
    background: var(--panel);
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 13px;
}

.legal-meta::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent);
}

.legal-layout {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 56px;
    align-items: start;
    padding-bottom: 110px;
}

.legal-toc {
    position: sticky;
    top: 24px;
    padding: 20px;
    border-radius: 18px;
    background: var(--panel);
    border: 1px solid var(--line);
}

.legal-toc summary {
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--dim);
}

.legal-toc summary::-webkit-details-marker {
    display: none;
}

.legal-toc summary::after {
    content: "+";
    font-size: 18px;
    font-weight: 400;
    color: var(--accent-text);
    transition: transform .25s ease;
}

.legal-toc[open] summary::after {
    transform: rotate(45deg);
}

.legal-toc[open] summary {
    margin-bottom: 10px;
}

.legal-toc ol {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 2px;
}

.legal-toc a {
    display: block;
    padding: 6px 10px;
    border-radius: 10px;
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.35;
    text-decoration: none;
    transition: background .2s ease, color .2s ease;
}

.legal-toc a:hover,
.legal-toc a.is-active {
    background: rgba(137, 196, 56, 0.10);
    color: var(--accent-text);
}

.legal-body {
    max-width: 760px;
}

.legal-intro {
    margin: 0 0 36px;
    font-size: 18px;
    line-height: 1.65;
    color: var(--ink);
}

.legal-intro p {
    margin: 0 0 16px;
}

.legal-section {
    padding: 28px 0;
    border-top: 1px solid var(--line);
    scroll-margin-top: 24px;
}

.legal-section h2 {
    display: flex;
    align-items: baseline;
    gap: 14px;
    margin: 0 0 14px;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.legal-section h2 .num {
    font-family: var(--serif);
    font-weight: 400;
    font-size: 30px;
    color: var(--accent-text);
    min-width: 34px;
}

.legal-section p,
.legal-section li {
    color: var(--muted);
    font-size: 15.5px;
    line-height: 1.75;
}

.legal-section p {
    margin: 0 0 12px;
}

.legal-section ol,
.legal-section ul {
    margin: 0 0 12px;
    padding-left: 22px;
    display: grid;
    gap: 8px;
}

.legal-section strong {
    color: var(--ink);
    font-weight: 600;
}

.legal-section a {
    color: var(--accent-text);
}

.legal-contact {
    margin-top: 8px;
    padding: 22px 24px;
    border-radius: 18px;
    background: var(--panel);
    border: 1px solid var(--line);
    display: grid;
    gap: 4px;
    color: var(--muted);
    font-size: 15px;
}

.legal-contact strong {
    color: var(--ink);
}

.legal-outro {
    margin-top: 12px;
    padding: 28px;
    border-radius: var(--radius);
    background:
        radial-gradient(80% 120% at 0% 0%, rgba(137, 196, 56, 0.12), transparent 60%),
        var(--panel);
    border: 1px solid var(--line);
    color: var(--ink);
    font-size: 16px;
}

.legal-outro p {
    margin: 0;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .legal-layout {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .legal-toc {
        position: static;
    }

    .legal-toc ol {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .topbar {
        grid-template-columns: 1fr auto;
        padding: 16px;
    }

    .topbar-tagline {
        grid-column: 1 / -1;
        grid-row: 2;
        margin-inline: auto;
        font-size: 12px;
    }

    .ghost-link {
        display: none;
    }

    .brand img {
        height: 22px;
    }

    .pill-btn {
        padding: 9px 14px;
        font-size: 13px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .legal-hero {
        padding: 44px 0 40px;
    }

    .legal-toc ol {
        grid-template-columns: 1fr;
    }

    .legal-intro {
        font-size: 16.5px;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
}
