/* ==========================================================================
   22-press.css — Press & media kit (/press/, /press/images/, /press/{doc}/)

   Public marketing surface aimed at journalists, so it is deliberately quieter
   than the app: generous measure, high contrast, nothing that competes with the
   screenshots. Imported by tool-tracker.css — bump its ?v= when editing.
   ========================================================================== */

.osat-press {
    background: #f7f9fb;
    padding-bottom: 72px;
}

.osat-press-wrap {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 20px;
}

/* --- Hero ---------------------------------------------------------------- */

.osat-press-hero {
    background: linear-gradient(160deg, #0d3c55 0%, #12506f 100%);
    color: #fff;
    padding: 56px 0 48px;
    margin-bottom: 32px;
}

.osat-press-eyebrow {
    text-transform: uppercase;
    letter-spacing: .12em;
    font-size: .78rem;
    font-weight: 700;
    color: #7fd3f5;
    margin: 0 0 10px;
}

.osat-press-hero h1 {
    color: #fff;
    font-size: clamp(1.9rem, 4vw, 2.7rem);
    line-height: 1.15;
    margin: 0 0 18px;
    max-width: 24ch;
}

.osat-press-lede {
    font-size: 1.06rem;
    line-height: 1.65;
    max-width: 68ch;
    margin: 0 0 14px;
}

.osat-press-hero .osat-press-lede { color: rgba(255, 255, 255, .92); }

.osat-press-cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 26px 0 0;
}

/* --- Buttons ------------------------------------------------------------- */

.osat-press-btn {
    display: inline-block;
    padding: 11px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: .95rem;
    text-decoration: none;
    border: 1.5px solid rgba(255, 255, 255, .55);
    color: #fff;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
}

.osat-press-btn:hover { background: rgba(255, 255, 255, .12); color: #fff; }

.osat-press-btn--primary {
    background: #d5202f;
    border-color: #d5202f;
    color: #fff;
}

.osat-press-btn--primary:hover { background: #b81b28; border-color: #b81b28; }

/* --- Section nav --------------------------------------------------------- */

/* A real menu, not a tab strip.
   History, because this took three goes: v1 was a horizontally scrolling tab row —
   the last items sat off-screen behind a scrollbar that is easy to miss entirely.
   v2 wrapped instead of scrolling, which showed everything but made a wide, untidy
   two-row block. v3 (this) groups the three lift-and-use copy documents under one
   "Available Copy" parent, so there are only 7 top-level items and the row fits on
   one line at any sane width — nothing scrolls, nothing hides. */
.osat-press-nav {
    margin: 0 auto 34px;
    padding-bottom: 14px;
    border-bottom: 1px solid #dde5ec;
    max-width: 980px;
}

.osat-press-nav > ul {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.osat-press-nav li { position: relative; }

.osat-press-nav a,
.osat-press-nav__parent {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 9px 14px;
    font-size: .93rem;
    font-weight: 600;
    font-family: inherit;
    color: #40525f;
    text-decoration: none;
    background: none;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    white-space: nowrap;
    transition: background .15s ease, color .15s ease;
}

.osat-press-nav a:hover,
.osat-press-nav__parent:hover { background: #eaf1f6; color: #0d3c55; }

.osat-press-nav > ul > li > a.is-active,
.osat-press-nav__parent.is-active {
    color: #fff;
    background: #12506f;
}

/* Chevron on the parent item. */
.osat-press-nav__chev {
    width: 0; height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid currentColor;
    opacity: .75;
}

/* --- Dropdown ------------------------------------------------------------ */

/* [CRITICAL] Toggle with `display`, NOT visibility/opacity. A `visibility: hidden`
   element is still IN the layout and still contributes scrollable overflow to its
   ancestors — with body set to `overflow: hidden auto` sitewide, the hidden panel
   inflated the scroll extent and produced scrollbars around a menu that had nothing
   to scroll.

   [CRITICAL] Opening is CLICK-driven (assets/js/press-nav.js sets .is-open), and the
   panel is CLOSED BY DEFAULT AT EVERY WIDTH. An earlier attempt forced it permanently
   open below 720px, because :hover does not exist on touch — which left every child
   item expanded on page load and running off the side of the screen. Hover is layered
   on top only for devices that genuinely have a pointer. */
.osat-press-nav__has-sub { position: relative; }

.osat-press-nav__sub {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    z-index: 60;
    min-width: 232px;
    max-width: calc(100vw - 40px);
    margin: 0;
    padding: 6px;
    list-style: none;
    background: #fff;
    border: 1px solid #dde5ec;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(13, 60, 85, .14);
    box-sizing: border-box;
}

/* Click-opened — every device. */
.osat-press-nav__has-sub.is-open > .osat-press-nav__sub { display: block; }

/* [CRITICAL] There is deliberately NO :hover or :focus-within open rule.
   The panel opens on CLICK and nothing else, identically on every device.
   Hover-opening was tried and removed: it made the menu look "expanded by default"
   whenever the pointer happened to rest over it, which is indistinguishable from a
   bug, and it contradicted the agreed behaviour (closed by default, opens on click).
   Keyboard users get there via the button, which is a real <button>. */

/* Never introduce scrollbars. */
.osat-press-nav,
.osat-press-nav > ul,
.osat-press-nav__sub { overflow: visible; }

/* Each child on its own line — the submenu is a VERTICAL list, never a row.
   [CRITICAL] `flex-direction: column` is a deliberate belt-and-braces guard, not
   redundancy. The panel is a block, so it should never be a flex row — but an earlier
   revision of this file styled the nav with a DESCENDANT selector
   (`.osat-press-nav ul`, no `>`), which also matched this submenu and turned it into a
   `flex-wrap: wrap` row: the items rendered side by side and ran off the side of the
   screen on a phone. Setting the direction here means that even if some other rule
   makes this a flex container, it still lays out vertically. */
.osat-press-nav__sub {
    flex-direction: column;
    align-items: stretch;
}

.osat-press-nav__sub li {
    position: static;
    display: block;
    width: 100%;
    float: none;
    flex: 0 0 auto;
}

.osat-press-nav__sub a {
    display: block;
    width: 100%;
    padding: 9px 12px;
    font-weight: 500;
    white-space: normal;
    box-sizing: border-box;
}

.osat-press-nav__sub a.is-active { color: #0d3c55; background: #eaf1f6; }

.osat-press-nav__chev { transition: transform .15s ease; }
.osat-press-nav__has-sub.is-open .osat-press-nav__chev { transform: rotate(180deg); }

/* Narrow screens: full-width stacked items, and the submenu renders inline (static)
   rather than floating — but ONLY once .is-open is set. Closed on load, like
   everywhere else. */
@media (max-width: 720px) {
    .osat-press-nav > ul { gap: 0; }
    .osat-press-nav > ul > li,
    .osat-press-nav__has-sub { width: 100%; }
    .osat-press-nav__parent { width: 100%; justify-content: space-between; }
    .osat-press-nav > ul > li > a { width: 100%; }

    .osat-press-nav__has-sub.is-open > .osat-press-nav__sub {
        display: block;
        position: static;
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-shadow: none;
        border: 0;
        border-left: 2px solid #dde5ec;
        border-radius: 0;
        margin: 2px 0 6px 14px;
        padding: 0 0 0 6px;
    }
}

/* --- Sections & cards ---------------------------------------------------- */

.osat-press-section { margin: 0 0 48px; }

.osat-press-section > h2 {
    font-size: 1.45rem;
    color: #0d3c55;
    margin: 0 0 8px;
}

.osat-press-section-note {
    color: #566875;
    max-width: 72ch;
    margin: 0 0 20px;
    line-height: 1.6;
}

.osat-press-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 16px;
}

.osat-press-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: #fff;
    border: 1px solid #dde5ec;
    border-radius: 12px;
    padding: 20px;
    text-decoration: none;
    transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.osat-press-card:hover {
    border-color: #12506f;
    box-shadow: 0 6px 20px rgba(13, 60, 85, .10);
    transform: translateY(-2px);
}

.osat-press-card--wide { max-width: 640px; }

.osat-press-card__title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #0d3c55;
}

.osat-press-card__blurb {
    font-size: .93rem;
    line-height: 1.55;
    color: #566875;
    flex: 1;
}

.osat-press-card__go {
    font-size: .88rem;
    font-weight: 700;
    color: #d5202f;
}

/* --- Contact block ------------------------------------------------------- */

.osat-press-contact {
    background: #fff;
    border: 1px solid #dde5ec;
    border-left: 4px solid #d5202f;
    border-radius: 12px;
    padding: 22px 24px;
    max-width: 760px;
}

.osat-press-contact p { margin: 0 0 10px; line-height: 1.6; color: #3d4d59; }
.osat-press-contact p:last-child { margin-bottom: 0; }
.osat-press-contact__links { font-size: .92rem; }

/* --- Doc pages ----------------------------------------------------------- */

.osat-press-breadcrumb {
    padding: 22px 0 4px;
    font-size: .88rem;
    color: #6a7a86;
}

.osat-press-breadcrumb a { color: #12506f; text-decoration: none; }
.osat-press-breadcrumb a:hover { text-decoration: underline; }
.osat-press-breadcrumb span { margin: 0 6px; }

.osat-press-page-head { margin: 0 0 34px; }
.osat-press-page-head h1,
.osat-press-doc > h1 {
    font-size: clamp(1.7rem, 3.2vw, 2.3rem);
    color: #0d3c55;
    margin: 0 0 10px;
}

.osat-press-doc {
    background: #fff;
    border: 1px solid #dde5ec;
    border-radius: 14px;
    padding: 34px 38px;
}

.osat-press-doc__blurb {
    color: #566875;
    font-size: 1.02rem;
    line-height: 1.6;
    margin: 0 0 26px;
    padding-bottom: 20px;
    border-bottom: 1px solid #edf1f5;
    max-width: 72ch;
}

/* Rendered Markdown body. Measure is capped for readability — press docs are
   read, not skimmed like app UI. */
.osat-press-doc__body { max-width: 78ch; color: #2f3d47; }

.osat-press-doc__body h2 {
    font-size: 1.32rem;
    color: #0d3c55;
    margin: 34px 0 12px;
    padding-top: 8px;
}

.osat-press-doc__body h3 {
    font-size: 1.08rem;
    color: #12506f;
    margin: 26px 0 10px;
}

.osat-press-doc__body h4 { font-size: .98rem; color: #12506f; margin: 20px 0 8px; }

.osat-press-doc__body p,
.osat-press-doc__body li { line-height: 1.7; }

.osat-press-doc__body p { margin: 0 0 15px; }

.osat-press-doc__body ul,
.osat-press-doc__body ol { margin: 0 0 18px; padding-left: 22px; }

.osat-press-doc__body li { margin-bottom: 7px; }

.osat-press-doc__body a { color: #12506f; }

.osat-press-doc__body code {
    background: #f0f4f7;
    border-radius: 4px;
    padding: 1px 5px;
    font-size: .9em;
}

.osat-press-doc__body hr {
    border: 0;
    border-top: 1px solid #e4eaef;
    margin: 30px 0;
}

.osat-press-doc__body blockquote {
    margin: 0 0 18px;
    padding: 2px 0 2px 18px;
    border-left: 3px solid #d5202f;
    color: #4a5c6a;
    font-style: italic;
}

/* Tables (Pricing, Product Specifications) must scroll rather than blow out the
   page on a phone. */
.osat-press-doc__body table,
.osat-press-table-wrap table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 20px;
    font-size: .93rem;
}

.osat-press-doc__body table { display: block; overflow-x: auto; }

.osat-press-doc__body th,
.osat-press-doc__body td {
    border: 1px solid #e0e7ed;
    padding: 9px 12px;
    text-align: left;
    vertical-align: top;
}

.osat-press-doc__body th { background: #f2f6f9; color: #0d3c55; font-weight: 700; }

.osat-press-usage {
    background: #eef6fb;
    border: 1px solid #cfe3ef;
    border-radius: 12px;
    padding: 16px 20px;
    margin: 24px 0 0;
    max-width: 78ch;
}

.osat-press-usage p { margin: 0; font-size: .93rem; line-height: 1.6; color: #33505f; }

/* --- Prev / next --------------------------------------------------------- */

.osat-press-pager {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    margin: 30px 0 0;
}

.osat-press-pager__link {
    display: flex;
    flex-direction: column;
    gap: 3px;
    background: #fff;
    border: 1px solid #dde5ec;
    border-radius: 10px;
    padding: 13px 18px;
    text-decoration: none;
    max-width: 46%;
}

.osat-press-pager__link:hover { border-color: #12506f; }
.osat-press-pager__link--next { text-align: right; margin-left: auto; }
.osat-press-pager__dir { font-size: .8rem; color: #7b8b96; font-weight: 600; }
.osat-press-pager__title { font-weight: 700; color: #0d3c55; font-size: .96rem; }

/* --- Image grid ---------------------------------------------------------- */

.osat-press-imggrid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.osat-press-img {
    margin: 0;
    background: #fff;
    border: 1px solid #dde5ec;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

/* Fixed-height frame so a 3200x1800 shot and a 3200x3500 one still tile evenly;
   object-fit keeps the top of the screenshot (where the useful UI is) in view. */
.osat-press-img__frame {
    display: block;
    background: #eef2f5;
    border-bottom: 1px solid #e4eaef;
    height: 240px;
    overflow: hidden;
}

.osat-press-img__frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
    transition: transform .25s ease;
}

.osat-press-img__frame:hover img { transform: scale(1.03); }

/* Logos are artwork, not UI — show them whole on a neutral field. */
.osat-press-img--contain .osat-press-img__frame img { object-fit: contain; padding: 18px; }

.osat-press-img figcaption {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 16px 18px 18px;
}

.osat-press-img__caption {
    font-weight: 600;
    color: #0d3c55;
    font-size: .95rem;
    line-height: 1.45;
}

.osat-press-btn--dl {
    background: #12506f;
    border-color: #12506f;
    color: #fff;
    padding: 8px 18px;
    font-size: .9rem;
}

.osat-press-btn--dl:hover { background: #0d3c55; border-color: #0d3c55; }

.osat-press-img__meta {
    font-size: .82rem;
    color: #6a7a86;
    font-variant-numeric: tabular-nums;
}

/* --- Licence ------------------------------------------------------------- */

.osat-press-licence {
    background: #fff;
    border: 1px solid #dde5ec;
    border-radius: 14px;
    padding: 30px 34px;
    margin: 12px 0 0;
}

.osat-press-licence h2 { font-size: 1.35rem; color: #0d3c55; margin: 0 0 10px; }

.osat-press-licence__intro {
    color: #566875;
    line-height: 1.65;
    max-width: 74ch;
    margin: 0 0 22px;
}

.osat-press-licence__block { margin: 0 0 20px; max-width: 78ch; }

.osat-press-licence__block h3 {
    font-size: 1rem;
    color: #12506f;
    margin: 0 0 8px;
}

.osat-press-licence__block p,
.osat-press-licence__block li { line-height: 1.65; color: #3d4d59; font-size: .95rem; }

.osat-press-licence__block ul { margin: 0; padding-left: 20px; }
.osat-press-licence__block li { margin-bottom: 6px; }

.osat-press-licence__foot {
    border-top: 1px solid #edf1f5;
    padding-top: 16px;
    margin: 24px 0 0;
    font-size: .93rem;
    color: #566875;
}

/* --- Mobile -------------------------------------------------------------- */

@media (max-width: 720px) {
    .osat-press-hero { padding: 38px 0 34px; }
    .osat-press-doc { padding: 24px 20px; }
    .osat-press-licence { padding: 22px 20px; }
    .osat-press-imggrid { grid-template-columns: 1fr; }
    .osat-press-img__frame { height: 200px; }
    .osat-press-pager { flex-direction: column; }
    .osat-press-pager__link,
    .osat-press-pager__link--next { max-width: 100%; text-align: left; margin-left: 0; }
    .osat-press-cta-row .osat-press-btn { width: 100%; text-align: center; }
}


/* --- Centred measure ------------------------------------------------------
   Goal: equal white space either side, copy still left-aligned.

   The trick is to centre the CONTAINER at the measure and let its children fill it,
   rather than centring each paragraph individually — do the latter and headings,
   tables and body text each end up on a different axis (the first attempt at this
   did exactly that, and the doc title sat visibly left of its own body copy).

   Two widths, and a page never mixes them:
     - document pages  → 820px, which IS the reading measure, so every child aligns
     - index / images  → 980px, wide enough for the card and image grids
   ------------------------------------------------------------------------- */

.osat-press-hero > .osat-press-wrap,
.osat-press-nav,
.osat-press-breadcrumb,
.osat-press-page-head,
.osat-press-section,
.osat-press-licence {
    max-width: 980px;
    margin-left: auto;
    margin-right: auto;
}

/* Paragraphs stay left-aligned inside the centred container; a narrower measure is
   fine, it just must not be independently centred. */
.osat-press-lede,
.osat-press-section-note,
.osat-press-licence__intro,
.osat-press-licence__block,
.osat-press-licence__foot { margin-left: 0; margin-right: 0; }

.osat-press-card--wide { max-width: 100%; }

/* Document pages: one width for everything, so the title, blurb, body, tables and
   pager all share a left edge. */
.osat-press--doc .osat-press-nav,
.osat-press--doc .osat-press-breadcrumb,
.osat-press--doc .osat-press-doc,
.osat-press--doc .osat-press-usage,
.osat-press--doc .osat-press-pager {
    max-width: 820px;
    margin-left: auto;
    margin-right: auto;
}

/* Children fill the card — the card itself is now the measure. */
.osat-press--doc .osat-press-doc > h1,
.osat-press--doc .osat-press-doc__blurb,
.osat-press--doc .osat-press-doc__body { max-width: 100%; }

@media (max-width: 900px) {
    .osat-press--doc .osat-press-nav,
    .osat-press--doc .osat-press-breadcrumb,
    .osat-press--doc .osat-press-doc,
    .osat-press--doc .osat-press-usage,
    .osat-press--doc .osat-press-pager { max-width: 100%; }
}
