/*
 * Owlbee "Clear Blue" shell: design tokens, site header, footer, buttons and
 * flash messages. Loaded on every page, including the homepage, which does not
 * load Bootstrap's CSS - so every rule here sets its own font, line-height,
 * margins and colours rather than relying on Bootstrap's reboot.
 */
:root {
    --ob-ink: #122b53;
    --ob-heading: #173762;
    --ob-muted: #617492;
    --ob-blue: #2563ed;
    --ob-blue-dark: #1753d1;
    --ob-navy: #153d81;
    --ob-line: #dfe8f5;
    --ob-soft: #f5f8fe;
    --ob-soft-2: #f1f6ff;
    --ob-soft-border: #e1ebfa;
    --ob-field-border: #d5e2f4;
    --ob-font: Arial, Helvetica, sans-serif;
    --ob-header-h: 86px;
}

html { scroll-behavior: smooth; scroll-padding-top: 96px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body.ob-body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: #fff;
    color: var(--ob-ink);
    font-family: var(--ob-font);
    -webkit-font-smoothing: antialiased;
}
.ob-main { flex: 1 0 auto; }

/* Bootstrap sets this everywhere; the homepage has no Bootstrap CSS. */
.ob-announcement, .site-header, .site-header *, .site-header *::before, .site-header *::after,
.site-footer, .site-footer *, .site-footer *::before, .site-footer *::after { box-sizing: border-box; }

.ob-wrap {
    box-sizing: border-box;
    width: 100%;
    max-width: 1280px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 36px;
    padding-right: 36px;
}

/* ---------- Buttons (the sample's .btn, namespaced) ---------- */
.ob-btn {
    box-sizing: border-box;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 17px 24px;
    border: 1px solid transparent;
    border-radius: 7px;
    font-family: var(--ob-font);
    font-weight: 600;
    font-size: 14px;
    line-height: normal;
    text-decoration: none;
    cursor: pointer;
    transition: transform .2s, background .2s;
    -webkit-tap-highlight-color: transparent;
}
.ob-btn:hover { transform: translateY(-2px); text-decoration: none; }
.ob-btn-primary,
.ob-btn-primary:visited {
    background: var(--ob-blue);
    color: #fff;
    box-shadow: 0 5px 12px #2563ed20;
}
.ob-btn-primary:hover { background: var(--ob-blue-dark); color: #fff; }
.ob-btn-line,
.ob-btn-line:visited {
    border-color: #cbdaf0;
    color: #26456e;
    background: #fff;
}
.ob-btn-line:hover { color: #1753d1; border-color: #9fbde9; }
.ob-btn-white,
.ob-btn-white:visited { background: #fff; color: #1f5bce; }
.ob-btn-white:hover { color: #1753d1; }
.ob-btn-sm { padding: 10px 14px; font-size: 13px; gap: 8px; }
@media (prefers-reduced-motion: reduce) { .ob-btn { transition: none; } }

.ob-btn:focus-visible,
.site-header a:focus-visible,
.site-header button:focus-visible,
.site-footer a:focus-visible {
    outline: 3px solid var(--ob-blue);
    outline-offset: 5px;
}

/* ---------- Announcement bar (homepage) ---------- */
.ob-announcement {
    text-align: center;
    background: var(--ob-navy);
    color: #e7f0ff;
    font-family: var(--ob-font);
    font-size: 11px;
    line-height: normal;
    padding: 10px 15px;
    letter-spacing: .3px;
}
.ob-announcement span { color: #a8c9ff; margin-right: 10px; }
.ob-announcement a { color: inherit; text-decoration: none; }
.ob-announcement a:hover { text-decoration: underline; }

/* ---------- Site header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1020;
    background: #ffffffef;
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid #edf2fa;
    font-family: var(--ob-font);
    line-height: normal;
}
.site-header .site-nav {
    height: var(--ob-header-h);
    display: flex;
    align-items: center;
    gap: 36px;
}
.ob-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--ob-font);
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: normal;
    color: #15345d;
    text-decoration: none;
    white-space: nowrap;
}
.ob-brand:hover { color: #15345d; text-decoration: none; }
.ob-brand img { width: 34px; height: 34px; object-fit: contain; }
.ob-brand small { font-weight: 400; font-size: 18px; color: #8294b0; margin-left: -7px; }

.ob-navlinks {
    display: flex;
    align-items: center;
    gap: 28px;
    margin-left: 50px;
    font-size: 14px;
}
.ob-navlinks a,
.ob-navcta-login {
    color: var(--ob-ink);
    text-decoration: none;
    font-size: 14px;
    line-height: normal;
    white-space: nowrap;
}
.ob-navlinks a:hover,
.ob-navcta-login:hover { color: var(--ob-blue); text-decoration: none; }
.ob-navlinks a.is-active { color: var(--ob-blue); font-weight: 600; }
.ob-navlinks-mobile { display: none; }

.ob-navcta {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 25px;
    font-size: 14px;
}

.ob-menu {
    display: none;
    margin: 0;
    padding: 4px 6px;
    background: transparent;
    border: 0;
    font-size: 24px;
    line-height: 1;
    color: var(--ob-ink);
    cursor: pointer;
}

/* Account dropdown. data-bs-display="static" keeps Popper out of it, so the
   position comes from here on pages with and without Bootstrap's CSS. */
.ob-account { position: relative; }
.ob-account-toggle {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin: 0;
    padding: 6px 10px 6px 6px;
    border: 1px solid var(--ob-line);
    border-radius: 999px;
    background: #fff;
    color: #26456e;
    font-family: var(--ob-font);
    font-size: 13px;
    font-weight: 600;
    line-height: normal;
    cursor: pointer;
}
.ob-account-toggle:hover { border-color: #c4d6f1; }
.ob-account-toggle::after {
    content: '';
    width: 6px;
    height: 6px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    margin-left: 2px;
}
.ob-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #eaf2ff;
    color: var(--ob-blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
}
.ob-account-name { max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-header .ob-account-menu {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    left: auto;
    z-index: 1030;
    min-width: 210px;
    margin: 0;
    padding: 8px;
    list-style: none;
    background: #fff;
    border: 1px solid var(--ob-line);
    border-radius: 12px;
    box-shadow: 0 16px 40px rgba(18, 43, 83, .14);
    font-family: var(--ob-font);
    font-size: 14px;
    line-height: normal;
}
.site-header .ob-account-menu.show { display: block; }
.site-header .ob-account-menu li { margin: 0; padding: 0; }
.site-header .ob-account-menu a {
    display: block;
    padding: 9px 12px;
    border-radius: 8px;
    color: #26456e;
    text-decoration: none;
    white-space: nowrap;
    background: transparent;
}
.site-header .ob-account-menu a:hover,
.site-header .ob-account-menu a:focus { background: var(--ob-soft-2); color: var(--ob-blue); }
.site-header .ob-account-menu hr { border: 0; border-top: 1px solid #edf2fa; margin: 6px 4px; opacity: 1; }
.ob-account-menu .ob-account-head { padding: 8px 12px 10px; font-size: 12px; color: var(--ob-muted); }
.ob-account-menu .ob-account-head b { display: block; color: var(--ob-ink); font-size: 13px; margin-bottom: 2px; }

@media (max-width: 1000px) {
    .ob-navlinks { margin-left: 0; gap: 18px; }
    .ob-navcta { gap: 15px; }
}

/* Logged-in header carries more links, so it folds into the menu earlier. */
@media (max-width: 1140px) {
    .site-header--app .site-nav { gap: 12px; }
    .site-header--app .ob-navlinks {
        display: none;
        position: absolute;
        top: var(--ob-header-h);
        left: 0;
        right: 0;
        margin: 0;
        padding: 18px 25px 22px;
        background: #fff;
        border-bottom: 1px solid var(--ob-line);
        box-shadow: 0 18px 30px rgba(18, 43, 83, .06);
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .site-header--app .ob-navlinks.open { display: flex; }
    .site-header--app .ob-navlinks-mobile {
        display: flex;
        flex-direction: column;
        gap: 16px;
        width: 100%;
        padding-top: 16px;
        border-top: 1px solid #edf2fa;
    }
    .site-header--app .ob-navcta { display: none; }
    .site-header--app .ob-menu { display: block; margin-left: auto; }
}

/* Visitors see Features, Integrations and Use cases too, so their header also
   folds into the menu before the links run into the buttons. */
@media (max-width: 960px) {
    .site-header:not(.site-header--app) .ob-navlinks {
        display: none;
        position: absolute;
        top: var(--ob-header-h);
        left: 0;
        right: 0;
        margin: 0;
        padding: 20px 25px;
        background: #fff;
        border-bottom: 1px solid var(--ob-line);
        box-shadow: 0 18px 30px rgba(18, 43, 83, .06);
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .site-header:not(.site-header--app) .ob-navlinks.open { display: flex; }
    .site-header:not(.site-header--app) .ob-navlinks-mobile {
        display: flex;
        flex-direction: column;
        gap: 16px;
        width: 100%;
        padding-top: 16px;
        border-top: 1px solid #edf2fa;
    }
    .site-header:not(.site-header--app) .ob-navcta-login { display: none; }
    .site-header:not(.site-header--app) .ob-menu { display: block; }
}

@media (max-width: 760px) {
    :root { --ob-header-h: 73px; }
    .ob-wrap { padding-left: 22px; padding-right: 22px; }
    .ob-announcement { font-size: 10px; }
    .site-header .site-nav { gap: 12px; }
    .ob-brand { font-size: 25px; }
    .ob-brand img { width: 29px; height: 29px; }
    .ob-navlinks {
        display: none;
        position: absolute;
        top: var(--ob-header-h);
        left: 0;
        right: 0;
        margin: 0;
        padding: 20px 25px;
        background: #fff;
        border-bottom: 1px solid var(--ob-line);
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .ob-navlinks.open { display: flex; }
    .ob-navlinks-mobile {
        display: flex;
        flex-direction: column;
        gap: 16px;
        width: 100%;
        padding-top: 16px;
        border-top: 1px solid #edf2fa;
    }
    .ob-navcta-login { display: none; }
    .ob-navcta .ob-btn { padding: 11px 14px; font-size: 12px; }
    .ob-menu { display: block; }
}

/* ---------- Flash messages that must render without Bootstrap CSS ---------- */
.ob-flash-stack { margin: 18px 0 0; }
.ob-flash-stack .alert { font-family: var(--ob-font); }
body.page-home .ob-flash-stack .alert {
    position: relative;
    margin: 0 0 12px;
    padding: 14px 44px 14px 16px;
    border: 1px solid #c9dcf8;
    border-radius: 10px;
    background: #eef5ff;
    color: #1d4a8a;
    font-size: 14px;
    line-height: 1.5;
}
body.page-home .ob-flash-stack .alert-success { background: #ecfbf3; border-color: #b9ebcf; color: #17603a; }
body.page-home .ob-flash-stack .alert-danger { background: #fff1f1; border-color: #f6c9c9; color: #8a1f1f; }
body.page-home .ob-flash-stack .alert i { display: none; }
body.page-home .ob-flash-stack .btn-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 26px;
    height: 26px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    color: inherit;
    opacity: .6;
}
body.page-home .ob-flash-stack .btn-close::before { content: '\00d7'; font-size: 20px; line-height: 26px; }
body.page-home .ob-flash-stack .fade:not(.show) { opacity: 0; }

/* ---------- Site footer ---------- */
.site-footer {
    flex-shrink: 0;
    font-family: var(--ob-font);
    line-height: normal;
    border-top: 1px solid #edf2fa;
    background: #fff;
}
body.page-home .site-footer { border-top: 0; }
.site-footer .ob-wrap { padding-top: 44px; padding-bottom: 25px; }
.site-footer .foot-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; }
.site-footer .foot-brand p { margin: 14px 0 0; max-width: 240px; font-size: 13px; line-height: 1.6; color: #6d82a0; }
.site-footer .foot-cols { display: grid; grid-template-columns: repeat(4, minmax(120px, auto)); gap: 28px 48px; }
.site-footer .foot-col h2 {
    margin: 0 0 14px;
    font-family: var(--ob-font);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.3px;
    text-transform: uppercase;
    color: var(--ob-heading);
}
.site-footer .foot-links { display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
.site-footer .foot-links a { color: #6d82a0; text-decoration: none; }
.site-footer .foot-links a:hover { color: var(--ob-blue); }
@media (max-width: 960px) {
    .site-footer .foot-top { flex-direction: column; }
    .site-footer .foot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
}
.site-footer .foot-bottom {
    border-top: 1px solid var(--ob-line);
    margin-top: 30px;
    padding-top: 20px;
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #8b9bb1;
}
@media (max-width: 760px) {
    .site-footer .foot-top { gap: 28px; }
    .site-footer .foot-bottom { gap: 15px; line-height: 1.6; }
}

/* Legal links in the footer's bottom row. */
.site-footer .foot-legal { display: inline-flex; flex-wrap: wrap; gap: 6px 16px; margin-left: 16px; }
.site-footer .foot-legal a { color: #8b9bb1; text-decoration: none; }
.site-footer .foot-legal a:hover { color: var(--ob-blue); text-decoration: underline; }
@media (max-width: 760px) { .site-footer .foot-legal { display: flex; margin: 8px 0 0; } }
