/* ============================================================================
 * Certopact brand stylesheet
 * Palette + typography from certopact-logo-pack BRAND-GUIDE.html
 * Applied across Client Portal (manage.certopact.com) + Admin Portal
 * ============================================================================ */

:root {
    --cream: #F3EEE4;
    --paper: #FBF7EE;
    --ink: #0B1220;
    --navy: #0B1F3A;
    --gold: #B08840;
    --gold-lt: #D4B271;
    --mid: #6B6860;
    --line: rgba(11, 18, 32, 0.10);
}

html, body {
    min-height: 100%;
}

body {
    background: var(--cream);
    color: var(--ink);
    font-family: 'Manrope', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3 {
    font-family: 'Fraunces', Georgia, serif;
    font-weight: 300;
    color: var(--ink);
    letter-spacing: -0.01em;
}

h1 {
    font-size: clamp(2.25rem, 4vw, 3.25rem);
    line-height: 1.1;
}

h2 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    line-height: 1.15;
}

h3 {
    font-size: 1.35rem;
}

h1 em,
h2 em,
h3 em {
    font-style: italic;
    color: var(--gold);
}

.lede {
    font-family: 'Instrument Serif', Georgia, serif;
    font-weight: 400;
    font-size: 1.125rem;
    color: var(--mid);
    line-height: 1.5;
}

.kicker {
    font-family: 'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace;
    text-transform: uppercase;
    letter-spacing: 0.24em;
    font-size: 11px;
    color: var(--mid);
}

a {
    color: var(--navy);
    text-decoration: none;
    transition: color 0.15s ease-in-out;
}

a:hover,
a:focus {
    color: var(--gold);
}

/* Bootstrap overrides --------------------------------------------------- */

.btn-primary,
.btn-navy {
    background-color: var(--navy);
    border-color: var(--navy);
    color: #fff;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-navy:hover,
.btn-navy:focus {
    background-color: #061324;
    border-color: #061324;
    color: #fff;
}

.btn-outline-navy {
    color: var(--navy);
    border-color: var(--navy);
    background-color: transparent;
    font-weight: 600;
}

.btn-outline-navy:hover,
.btn-outline-navy:focus {
    background-color: var(--navy);
    color: #fff;
}

.form-control,
.form-select {
    background-color: var(--paper);
    border-color: var(--line);
    color: var(--ink);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 0.2rem rgba(176, 136, 64, 0.25);
}

.form-floating > label {
    color: var(--mid);
}

/* Layout + navigation --------------------------------------------------- */

.cp-topnav {
    background-color: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 0.75rem 1.25rem;
}

.cp-topnav .cp-brand img {
    height: 28px;
    width: auto;
}

.cp-topnav .cp-user {
    color: var(--mid);
    font-size: 0.925rem;
}

/* Subnav ---------------------------------------------------------------- */

.cp-subnav {
    background-color: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 0 1.25rem;
    display: flex;
    align-items: stretch;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.cp-subnav::-webkit-scrollbar {
    display: none;
}

.cp-subnav-link {
    display: inline-flex;
    align-items: center;
    padding: 0.625rem 0.875rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--mid);
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
    transition: color 0.15s ease-in-out, border-color 0.15s ease-in-out;
}

.cp-subnav-link:hover,
.cp-subnav-link:focus {
    color: var(--navy);
    border-bottom-color: var(--gold-lt);
}

.cp-subnav-link.active {
    color: var(--navy);
    border-bottom-color: var(--navy);
    font-weight: 700;
}

.cp-footer {
    background-color: var(--cream);
    color: var(--mid);
    border-top: 1px solid var(--line);
    padding: 1rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 400;
}

.cp-footer a {
    color: var(--mid);
}

.cp-footer a:hover,
.cp-footer a:focus {
    color: var(--gold);
}

/* Cards + tiles --------------------------------------------------------- */

.cp-tile.card {
    background-color: var(--paper);
    border: 1px solid var(--line);
    border-radius: 12px;
}

.cp-tile .cp-tile-label {
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 11px;
    color: var(--mid);
    margin-bottom: 0.5rem;
}

.cp-tile .cp-tile-value {
    font-family: 'Fraunces', Georgia, serif;
    font-weight: 300;
    font-size: 2.25rem;
    color: var(--gold);
    line-height: 1;
}

.cp-tile .cp-tile-foot {
    color: var(--mid);
    font-size: 0.8125rem;
    margin-top: 0.5rem;
}

/* Usage progress thresholds (Round D will flip data in) */
.cp-usage-bar {
    height: 6px;
    background-color: var(--line);
    border-radius: 3px;
    overflow: hidden;
}

.cp-usage-bar-fill {
    height: 100%;
    background-color: var(--navy);
}

.cp-usage-threshold-amber .cp-usage-bar-fill {
    background-color: var(--gold);
}

.cp-usage-threshold-red .cp-usage-bar-fill {
    background-color: #B04040;
}

/* Login split layout ---------------------------------------------------- */

.cp-login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

@media (max-width: 960px) {
    .cp-login-shell {
        grid-template-columns: 1fr;
    }
}

.cp-login-hero {
    position: relative;
    background-image: url('/img/login/login-hero.webp');
    background-size: cover;
    background-position: center;
    min-height: 320px;
}

.cp-login-hero::after {
    content: "";
    position: absolute;
    inset: auto 0 0 0;
    height: 45%;
    background: linear-gradient(to top, rgba(11, 18, 32, 0.55), rgba(11, 18, 32, 0));
    pointer-events: none;
}

.cp-login-hero-caption {
    position: absolute;
    left: 2rem;
    bottom: 1.5rem;
    color: rgba(255, 255, 255, 0.85);
    z-index: 1;
}

.cp-login-form {
    background-color: var(--cream);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 1.5rem;
}

.cp-login-form-inner {
    width: 100%;
    max-width: 420px;
}

.cp-login-logo {
    height: 32px;
    width: auto;
    margin-bottom: 1.75rem;
}

/* Alerts -------------------------------------------------------------- */

.alert-danger {
    background-color: #FBECEC;
    border-color: #E4A2A2;
    color: #7A2323;
}

/* Misc ---------------------------------------------------------------- */

.text-gold {
    color: var(--gold) !important;
}

.bg-paper {
    background-color: var(--paper) !important;
}

/* Focus ring default */
:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}
