/*
 * My Account portal stylesheet.
 *
 * Deliberately not shared with the public site's assets/style.css. That one is
 * a search results page — big type, lots of air, tuned for reading prose. This
 * is a console: dense tables, status chips, forms, and a left rail that stays
 * put. Sharing a stylesheet between the two would mean every change to a table
 * cell risks moving a search result.
 *
 * Light and dark both come from the custom properties below, so a rule almost
 * never needs to name a colour twice.
 */

:root {
    --bg: #ffffff;
    --bg-sunken: #f8fafc;
    --bg-raised: #ffffff;
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
    --text: #1e293b;
    --text-muted: #475569;
    --text-faint: #64748b;
    --accent: #0065bd;
    --accent-hover: #00529b;
    --accent-soft: #eaf4fb;
    --accent-border: #b8d9ed;
    --good: #166534;
    --good-soft: #f0fdf4;
    --warn: #a16207;
    --warn-soft: #fffbeb;
    --bad: #b3261e;
    --bad-soft: #fef2f2;
    --saltire-blue: #0065bd;
    --brand-gradient: linear-gradient(135deg, #1683d1 0%, #0065bd 55%, #004b87 100%);
    --shadow: 0 2px 8px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
    --shadow-lg: 0 18px 45px rgba(15, 23, 42, .12);
    --radius: 14px;
    --sidebar-w: 232px;
    --masthead-h: 64px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg: #0f172a;
        --bg-sunken: #0b1220;
        --bg-raised: #1a2438;
        --border: #24304a;
        --border-strong: #33415c;
        --text: #e2e8f0;
        --text-muted: #a9b6c9;
        --text-faint: #8b9ab0;
        --accent: #7cc4f0;
        --accent-hover: #a9dcf7;
        --accent-soft: #102f49;
        --accent-border: #1e5f8d;
        --good: #86efac;
        --good-soft: #06251a;
        --warn: #fcd34d;
        --warn-soft: #30270d;
        --bad: #fca5a5;
        --bad-soft: #2a1416;
        --shadow: 0 2px 8px rgba(0, 0, 0, .35);
        --shadow-lg: 0 18px 45px rgba(0, 0, 0, .5);
    }
}

* { box-sizing: border-box; }

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

body {
    margin: 0;
    background: var(--bg-sunken);
    color: var(--text);
    font: 14px/1.55 Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

h1 { font-size: 22px; font-weight: 400; margin: 0 0 4px; }
h2 { font-size: 16px; font-weight: 500; margin: 0 0 12px; }
h3 { font-size: 14px; font-weight: 500; margin: 0 0 8px; }

p { margin: 0 0 12px; }

code, .mono {
    font-family: "Roboto Mono", "SF Mono", Menlo, Consolas, monospace;
    font-size: 13px;
}

/* ------------------------------------------------------------- masthead ---- */

.masthead {
    position: sticky;
    top: 0;
    z-index: 20;
    height: var(--masthead-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 16px;
    background: var(--bg-raised);
    border-bottom: 1px solid var(--border);
}

.masthead-brand, .card-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
    font-size: 15px;
}
.masthead-brand:hover, .card-brand:hover { text-decoration: none; }

.brand-mark {
    display: grid;
    place-items: center;
    width: auto;
    height: auto;
    border-radius: 0;
    background: transparent;
    color: inherit;
}
.brand-mark img {
    display: block;
    width: 24px;
    height: 24px;
}

@media (prefers-color-scheme: dark) {
    .brand-mark { color: #0f172a; }
}

.brand-text b { font-weight: 500; color: var(--text-muted); }

.masthead-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 13px;
}
.masthead-link { color: var(--text-muted); }
.masthead-signout { margin: 0; }

.link-button {
    background: none;
    border: 0;
    padding: 0;
    font: inherit;
    color: var(--accent);
    cursor: pointer;
}
.link-button:hover { text-decoration: underline; }

/* --------------------------------------------------------------- shell ---- */

.shell {
    display: grid;
    grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
    align-items: start;
}

.sidebar {
    position: sticky;
    top: var(--masthead-h);
    height: calc(100vh - var(--masthead-h));
    overflow-y: auto;
    padding: 12px 8px;
    background: var(--bg-raised);
    border-right: 1px solid var(--border);
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    margin-bottom: 2px;
    border-radius: 0 999px 999px 0;
    color: var(--text-muted);
    font-size: 13px;
}
.nav-item:hover { background: var(--bg-sunken); text-decoration: none; }
.nav-item.is-active { background: var(--accent-soft); color: var(--accent); font-weight: 500; }

.nav-icon { width: 16px; text-align: center; opacity: .8; }
.nav-sub { padding-left: 20px; }

.nav-group { margin-top: 16px; }
.nav-group-title {
    padding: 4px 12px 6px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-faint);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.content {
    padding: 24px 32px 64px;
    max-width: 1080px;
    width: 100%;
}
.content.is-wide { max-width: none; }

/* Narrow screens: the rail becomes a strip across the top. A console is a
   desktop tool, but a site owner checking a coverage error on a phone should
   not meet a horizontally scrolling page. */
@media (max-width: 820px) {
    .shell { grid-template-columns: 1fr; }
    .sidebar {
        position: static;
        height: auto;
        display: flex;
        gap: 4px;
        overflow-x: auto;
        border-right: 0;
        border-bottom: 1px solid var(--border);
    }
    .nav-group { display: contents; }
    .nav-group-title { display: none; }
    .nav-item { border-radius: 999px; white-space: nowrap; }
    .nav-sub { padding-left: 12px; }
    .content { padding: 16px; }
}

/* -------------------------------------------------------- signed-out card -- */

.centred { display: grid; place-items: center; min-height: 100vh; padding: 24px; }

.card-wrap { width: 100%; max-width: 420px; }
.card-brand { justify-content: center; margin-bottom: 24px; }

.card {
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}
.card h1 { text-align: center; }
.card-lede { text-align: center; color: var(--text-muted); margin-bottom: 24px; }

.card-footer {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    font-size: 12px;
    color: var(--text-faint);
}
.card-footer a { color: var(--text-muted); }

.card-alt {
    margin-top: 16px;
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
}

/* --------------------------------------------------------------- panels ---- */

.panel {
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 16px;
}
.panel-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}
.panel-head h2 { margin: 0; }
.panel-body { padding: 20px; }
.panel-body > :last-child { margin-bottom: 0; }

.page-head { margin-bottom: 20px; }
.page-head .subtitle { color: var(--text-muted); margin: 0; }

/* --------------------------------------------------------------- forms ----- */

.field { margin-bottom: 16px; }
.profile-picture {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin: 0 0 24px;
}
.profile-picture-image,
.profile-picture-placeholder {
  width: 112px;
  height: 112px;
  border-radius: 50%;
  flex: 0 0 112px;
  object-fit: cover;
  background: var(--bg-sunken);
  border: 1px solid var(--border);
}
.profile-picture-placeholder {
  display: grid;
  place-items: center;
  color: var(--accent);
  font-size: 42px;
  font-weight: 700;
}
.profile-picture .link-button { margin-top: 10px; }
.field label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 500;
}
.field .hint {
    margin: 6px 0 0;
    font-size: 12px;
    color: var(--text-muted);
}

input[type=text], input[type=email], input[type=password], input[type=url], input[type=search], select, textarea {
    width: 100%;
    padding: 10px 12px;
    background: var(--bg);
    color: var(--text);
    border: 1px solid var(--border-strong);
    border-radius: 4px;
    font: inherit;
}
input:focus-visible, select:focus-visible, textarea:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: -1px;
    border-color: var(--accent);
}
input[aria-invalid=true] { border-color: var(--bad); }

.field-error {
    margin: 6px 0 0;
    font-size: 12px;
    color: var(--bad);
}

.checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
}
.checkbox input { width: auto; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 24px;
    border: 1px solid transparent;
    border-radius: 4px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 500;
    cursor: pointer;
}
@media (prefers-color-scheme: dark) {
    .btn { color: #0f172a; }
}
.btn:hover { background: var(--accent-hover); text-decoration: none; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-block { width: 100%; }

.btn-secondary {
    background: transparent;
    border-color: var(--border-strong);
    color: var(--accent);
}
.btn-secondary:hover { background: var(--accent-soft); }

.btn-danger { background: var(--bad); color: #fff; }
.btn-danger:hover { background: var(--bad); filter: brightness(.92); }

.btn-small { padding: 6px 14px; font-size: 13px; }

.form-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
}

/* -------------------------------------------------------------- banners ---- */

.banner {
    padding: 12px 16px;
    border-radius: var(--radius);
    margin-bottom: 16px;
    font-size: 13px;
    border: 1px solid transparent;
}
.banner-info { background: var(--accent-soft); color: var(--accent); border-color: var(--accent); }
.banner-success { background: var(--good-soft); color: var(--good); border-color: var(--good); }
.banner-error { background: var(--bad-soft); color: var(--bad); border-color: var(--bad); }

/* ---------------------------------------------------------------- chips ---- */

.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
}
.chip-good { background: var(--good-soft); color: var(--good); }
.chip-warn { background: var(--warn-soft); color: var(--warn); }
.chip-bad { background: var(--bad-soft); color: var(--bad); }
.chip-neutral { background: var(--bg-sunken); color: var(--text-muted); }

/* --------------------------------------------------------------- tables ---- */

/* Tables scroll inside their own box rather than widening the page — a URL
   column has no natural maximum width. */
.table-wrap { overflow-x: auto; }

table.data {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
table.data th, table.data td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}
table.data th {
    font-weight: 500;
    color: var(--text-muted);
    white-space: nowrap;
    background: var(--bg-raised);
    position: sticky;
    top: 0;
}
table.data tbody tr:hover { background: var(--bg-sunken); }
table.data tbody tr:last-child td { border-bottom: 0; }
table.data td.num, table.data th.num { text-align: right; font-variant-numeric: tabular-nums; }
table.data .url-cell { max-width: 420px; word-break: break-word; }

/* ------------------------------------------------------------ empty state -- */

.empty {
    padding: 48px 24px;
    text-align: center;
    color: var(--text-muted);
}
.empty h2 { color: var(--text); }
.empty p { max-width: 46ch; margin-left: auto; margin-right: auto; }

/* ----------------------------------------------------------- stat tiles ---- */

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}
.stat {
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 16px 20px;
}
.stat .stat-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 6px;
}
.stat .stat-value {
    font-size: 26px;
    font-weight: 400;
    font-variant-numeric: tabular-nums;
}
.stat.is-selectable { cursor: pointer; }
.stat.is-active { border-color: var(--accent); box-shadow: inset 0 -3px 0 var(--accent); }

/* --------------------------------------------------------------- misc ------ */

.muted { color: var(--text-muted); }
.faint { color: var(--text-faint); }
.small { font-size: 12px; }
.nowrap { white-space: nowrap; }
.stack > * + * { margin-top: var(--stack-gap, 16px); }

.snippet {
    display: block;
    padding: 12px 14px;
    background: var(--bg-sunken);
    border: 1px solid var(--border);
    border-radius: 4px;
    overflow-x: auto;
    white-space: pre;
    margin: 0 0 8px;
}

.divider { height: 1px; background: var(--border); border: 0; margin: 24px 0; }

.pager {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 20px;
    border-top: 1px solid var(--border);
    font-size: 13px;
    color: var(--text-muted);
}

.tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 16px;
    overflow-x: auto;
}
.tab {
    padding: 10px 16px;
    color: var(--text-muted);
    border-bottom: 3px solid transparent;
    white-space: nowrap;
}
.tab:hover { text-decoration: none; color: var(--text); }
.tab.is-active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 500; }

/* Respect a reduced-motion preference; there is little motion here, but the
   focus ring and hover transitions are enough to matter to some people. */
@media (prefers-reduced-motion: reduce) {
    * { transition: none !important; animation: none !important; }
}

/* -------------------------------------------------------- landing page ---- */

.landing {
    display: block;
    min-height: 100vh;
    background: var(--bg);
}

.landing-masthead {
    position: sticky;
    top: 0;
    z-index: 20;
    background: var(--bg-raised);
    border-bottom: 1px solid var(--border);
}

.landing-masthead-inner {
    max-width: 1120px;
    margin: 0 auto;
    height: var(--masthead-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 24px;
}

.landing-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 14px;
}

.landing-nav a { color: var(--text-muted); }
.landing-nav a:hover { color: var(--text); text-decoration: none; }

.landing-masthead-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.landing-main { min-height: calc(100vh - var(--masthead-h)); }

.hero {
    padding: 72px 24px 80px;
    background: var(--accent-soft);
    border-bottom: 1px solid var(--border);
}

.hero-inner {
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
}

.hero h1 {
    font-size: 36px;
    font-weight: 400;
    line-height: 1.25;
    margin-bottom: 16px;
}

.hero-lede {
    font-size: 18px;
    color: var(--text-muted);
    margin-bottom: 28px;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.hero-note {
    font-size: 13px;
    color: var(--text-faint);
    margin: 0;
}

.btn-lg {
    padding: 12px 28px;
    font-size: 16px;
}

.features,
.how-it-works {
    max-width: 1120px;
    margin: 0 auto;
    padding: 56px 24px;
}

.features {
    border-bottom: 1px solid var(--border);
}

.features-head,
.how-it-works-head {
    text-align: center;
    margin-bottom: 40px;
}

.features-head h2,
.how-it-works-head h2 {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 8px;
}

.features-head p {
    color: var(--text-muted);
    margin: 0;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.feature-card {
    background: var(--bg-raised);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}

.feature-card h3 {
    font-size: 16px;
    font-weight: 500;
    margin: 0 0 8px;
}

.feature-card p {
    color: var(--text-muted);
    margin: 0;
}

.feature-icon {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--accent-soft);
    color: var(--accent);
    font-size: 18px;
    margin-bottom: 16px;
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.step {
    position: relative;
    padding-left: 52px;
}

.step-number {
    position: absolute;
    left: 0;
    top: 0;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-weight: 500;
}
@media (prefers-color-scheme: dark) {
    .step-number { color: #0f172a; }
}

.step h3 {
    font-size: 16px;
    font-weight: 500;
    margin: 0 0 6px;
}

.step p {
    color: var(--text-muted);
    margin: 0;
}

.cta-panel {
    padding: 56px 24px;
    background: var(--bg-sunken);
    border-top: 1px solid var(--border);
}

.cta-panel-inner {
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
}

.cta-panel h2 {
    font-size: 24px;
    font-weight: 400;
    margin-bottom: 8px;
}

.cta-panel p {
    color: var(--text-muted);
    margin-bottom: 24px;
}

.landing-footer {
    padding: 24px;
    border-top: 1px solid var(--border);
    background: var(--bg-raised);
}

.landing-footer-inner {
    max-width: 1120px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.landing-footer-brand { color: var(--text); }
.landing-footer-brand:hover { text-decoration: none; }

.landing-footer-links {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 13px;
}

.landing-footer-links a { color: var(--text-muted); }

@media (max-width: 720px) {
    .landing-masthead-inner {
        height: auto;
        flex-wrap: wrap;
        padding: 12px 16px;
        gap: 12px;
    }
    .landing-nav,
    .landing-masthead-actions {
        width: 100%;
        justify-content: center;
    }
    .hero { padding: 48px 16px; }
    .hero h1 { font-size: 28px; }
    .hero-lede { font-size: 16px; }
    .features,
    .how-it-works,
    .cta-panel { padding: 40px 16px; }
    .landing-footer-inner { justify-content: center; }
}

/* Multi-factor authentication */
.section-heading-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}

.section-heading-row h2 { margin-bottom: 4px; }

.mfa-recovery-panel {
    margin: 20px 0;
    padding: 20px;
    border: 1px solid #f1cf78;
    border-radius: 10px;
    background: #fff9e8;
}

.mfa-code-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 14px;
    margin: 16px 0;
}

.mfa-code-grid code {
    padding: 9px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--bg-raised);
    text-align: center;
    letter-spacing: .08em;
}

.mfa-setup-grid {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) minmax(240px, 1fr);
    gap: 28px;
    margin-top: 20px;
}

.mfa-qr {
    display: inline-flex;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
}

.mfa-qr img { display: block; max-width: 100%; height: auto; }

.mfa-secret {
    display: block;
    margin: 12px 0;
    padding: 10px;
    overflow-wrap: anywhere;
    border: 1px dashed var(--border);
    border-radius: 6px;
    letter-spacing: .08em;
}

.mfa-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 18px 0;
}

.mfa-summary div {
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.mfa-summary dt { color: var(--text-muted); font-size: 12px; }
.mfa-summary dd { margin: 5px 0 0; font-weight: 600; }

.mfa-management {
    margin-top: 12px;
    padding: 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.mfa-management summary { cursor: pointer; font-weight: 600; }
.mfa-danger { border-color: color-mix(in srgb, var(--bad) 35%, var(--border)); }
.mfa-audit-list { margin: 14px 0 0; padding: 0; list-style: none; }
.mfa-audit-list li {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border);
}
.mfa-audit-list li:last-child { border-bottom: 0; }

@media (max-width: 720px) {
    .mfa-setup-grid,
    .mfa-summary,
    .mfa-code-grid { grid-template-columns: 1fr; }
}

/* ------------------------------------------------ account dashboard 2026 -- */

.app {
    min-height: 100vh;
    background:
        radial-gradient(circle at 82% 8%, rgba(0, 101, 189, .055), transparent 28rem),
        radial-gradient(circle at 26% 92%, rgba(0, 101, 189, .04), transparent 30rem),
        var(--bg-sunken);
}

.masthead {
    padding-inline: 24px;
    box-shadow: 0 1px 0 rgba(15, 23, 42, .02);
}

.masthead-brand {
    gap: 12px;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -.015em;
}

.masthead-brand .brand-text {
    color: var(--saltire-blue);
}

.masthead-brand .brand-mark img {
    width: 30px;
    height: 30px;
}

.brand-text b {
    margin-left: 4px;
    font-weight: 500;
}

.masthead-actions {
    gap: 10px;
}

.masthead-link,
.masthead-signout .link-button {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    padding: 0 14px;
    border-radius: 999px;
    color: var(--text-muted);
    font-weight: 600;
}

.masthead-link:hover,
.masthead-signout .link-button:hover {
    background: var(--bg-sunken);
    color: var(--text);
    text-decoration: none;
}

.masthead-signout .link-button {
    border: 1px solid var(--border);
    background: var(--bg-raised);
}

.sidebar {
    padding: 20px 12px;
}

.nav-item {
    min-height: 44px;
    margin-bottom: 4px;
    padding: 10px 14px;
    border-radius: 10px;
    font-weight: 600;
    transition: background-color .15s ease, color .15s ease, transform .15s ease;
}

.nav-item:hover {
    background: var(--bg-sunken);
    transform: translateX(2px);
}

.nav-item.is-active {
    position: relative;
    background: var(--accent-soft);
    color: var(--accent);
}

.nav-item.is-active::before {
    position: absolute;
    inset: 9px auto 9px -12px;
    width: 3px;
    border-radius: 0 999px 999px 0;
    background: var(--brand-gradient);
    content: "";
}

.nav-icon {
    display: grid;
    width: 20px;
    place-items: center;
}

.nav-icon svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.nav-group {
    margin-top: 24px;
}

.nav-group-title {
    padding-inline: 14px;
    color: var(--text-faint);
    font-weight: 700;
    letter-spacing: .1em;
}

.content {
    max-width: 1220px;
    padding: 36px clamp(20px, 4vw, 52px) 72px;
}

.account-dashboard {
    width: 100%;
}

.dashboard-hero {
    position: relative;
    isolation: isolate;
    display: flex;
    min-height: 190px;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px;
    overflow: hidden;
    margin-bottom: 24px;
    padding: clamp(26px, 4vw, 42px);
    border: 1px solid var(--accent-border);
    border-radius: 20px;
    background:
        linear-gradient(110deg, rgba(0, 101, 189, .085), rgba(255, 255, 255, 0) 62%),
        var(--bg-raised);
    box-shadow: var(--shadow);
    color: var(--text);
}

.dashboard-hero::before,
.dashboard-hero::after {
    position: absolute;
    z-index: -1;
    border: 1px solid rgba(0, 101, 189, .12);
    border-radius: 50%;
    content: "";
}

.dashboard-hero::before {
    top: -155px;
    right: -70px;
    width: 330px;
    height: 330px;
    box-shadow: 0 0 0 42px rgba(0, 101, 189, .025);
}

.dashboard-hero::after {
    right: 225px;
    bottom: -165px;
    width: 250px;
    height: 250px;
}

.dashboard-hero-copy {
    max-width: 620px;
}

.dashboard-eyebrow {
    display: block;
    margin-bottom: 8px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .16em;
    color: var(--accent);
    text-transform: uppercase;
}

.dashboard-hero h1 {
    margin: 0 0 8px;
    color: var(--text);
    font-size: clamp(27px, 3.2vw, 38px);
    font-weight: 700;
    letter-spacing: -.035em;
    line-height: 1.15;
}

.dashboard-hero p {
    max-width: 55ch;
    margin: 0;
    color: var(--text-muted);
    font-size: 15px;
}

.dashboard-hero-status {
    display: flex;
    max-width: 310px;
    align-items: flex-end;
    flex-direction: column;
    gap: 8px;
}

.hero-status-item {
    display: inline-flex;
    max-width: 100%;
    min-height: 34px;
    align-items: center;
    gap: 8px;
    overflow: hidden;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--bg-raised);
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.hero-status-dot {
    width: 8px;
    height: 8px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 0 3px rgba(74, 222, 128, .18);
}

.dashboard-grid {
    display: grid;
    gap: 20px;
}

.dashboard-grid-top {
    grid-template-columns: minmax(0, 1.15fr) minmax(300px, .85fr);
}

.section-sessions-full {
    width: 100%;
    margin-top: 20px;
}

.section {
    min-width: 0;
    margin: 0 0 20px;
    padding: clamp(20px, 3vw, 28px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-raised);
    box-shadow: var(--shadow);
}

.dashboard-grid .section {
    margin-bottom: 0;
}

.mfa-section {
    margin-top: 20px;
}

.mfa-page-section {
    margin-top: 0;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-bottom: 24px;
}

.section-title h2 {
    margin: 0;
    color: var(--text);
    font-size: 17px;
    font-weight: 750;
    letter-spacing: -.015em;
}

.section-title p {
    margin: 2px 0 0;
    color: var(--text-muted);
    font-size: 12px;
}

.section-icon {
    display: grid;
    width: 40px;
    height: 40px;
    flex: 0 0 40px;
    place-items: center;
    border-radius: 11px;
}

.section-icon svg {
    width: 21px;
    height: 21px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.section-icon-profile,
.section-icon-password,
.section-icon-mfa,
.section-icon-services,
.section-icon-sessions {
    border: 1px solid var(--accent-border);
    background: var(--accent-soft);
    color: var(--accent);
}

.section-heading-row {
    align-items: center;
    margin-bottom: 22px;
}

.section-heading-row .section-title {
    margin-bottom: 0;
}

.section-heading-row > .chip {
    flex: 0 0 auto;
}

.profile-picture {
    align-items: center;
    margin-bottom: 26px;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg-sunken);
}

.profile-picture-image,
.profile-picture-placeholder {
    width: 96px;
    height: 96px;
    flex-basis: 96px;
    border: 3px solid var(--bg-raised);
    box-shadow: 0 0 0 1px var(--border), var(--shadow);
}

.profile-picture-placeholder {
    background: var(--accent-soft);
    font-size: 34px;
}

.profile-picture > div {
    min-width: 0;
    flex: 1;
}

.profile-picture input[type=file] {
    width: 100%;
    color: var(--text-muted);
    font-size: 12px;
}

.field {
    margin-bottom: 18px;
}

.field label {
    margin-bottom: 7px;
    color: var(--text);
    font-weight: 650;
}

input[type=text],
input[type=email],
input[type=password],
input[type=url],
input[type=search],
select,
textarea {
    min-height: 44px;
    padding: 11px 13px;
    border-color: var(--border);
    border-radius: 9px;
    background: var(--bg);
    box-shadow: inset 0 1px 1px rgba(15, 23, 42, .025);
    transition: border-color .15s ease, box-shadow .15s ease;
}

input:hover:not(:disabled),
select:hover,
textarea:hover {
    border-color: var(--border-strong);
}

input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 101, 189, .14);
}

input:disabled {
    color: var(--text-muted);
    background: var(--bg-sunken);
}

.btn {
    min-height: 42px;
    padding: 9px 18px;
    border-radius: 9px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .12);
    font-weight: 700;
    transition: background-color .15s ease, box-shadow .15s ease, transform .15s ease;
}

.btn:hover {
    box-shadow: 0 4px 10px rgba(0, 101, 189, .18);
    transform: translateY(-1px);
}

.btn-secondary {
    box-shadow: none;
}

.btn-small {
    min-height: 36px;
    padding: 7px 13px;
}

.banner {
    margin-bottom: 20px;
    padding: 13px 16px;
    border-radius: 11px;
    box-shadow: var(--shadow);
    font-weight: 600;
}

.chip {
    padding: 5px 10px;
    font-weight: 700;
    text-transform: capitalize;
}

.chip-good {
    border: 1px solid #bbf7d0;
}

.chip-neutral {
    border: 1px solid var(--border);
}

.service-list {
    display: grid;
    gap: 10px;
    margin: 0 0 20px;
    padding: 0;
    list-style: none;
}

.service-list li {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 4px 12px;
    padding: 13px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--bg-sunken);
}

.service-name {
    overflow: hidden;
    font-weight: 700;
    text-overflow: ellipsis;
    text-transform: capitalize;
    white-space: nowrap;
}

.service-list .meta {
    grid-column: 1 / -1;
    color: var(--text-faint);
    font-size: 11px;
}

.service-links {
    display: flex;
    gap: 9px;
    flex-wrap: wrap;
    margin: 0;
}

.table-scroll {
    overflow-x: auto;
    margin: 0 -6px -6px;
    border: 1px solid var(--border);
    border-radius: 11px;
}

.table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.table th,
.table td {
    padding: 13px 14px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: middle;
}

.table th {
    background: var(--bg-sunken);
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 750;
    letter-spacing: .035em;
    text-transform: uppercase;
    white-space: nowrap;
}

.table tbody tr:last-child td {
    border-bottom: 0;
}

.table tbody tr:hover {
    background: var(--bg-sunken);
}

.table .actions {
    text-align: right;
}

.table .actions form {
    margin: 0;
}

.session-device {
    display: flex;
    min-width: 210px;
    align-items: center;
    gap: 10px;
}

.session-device-icon {
    display: grid;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    place-items: center;
    border: 1px solid var(--accent-border);
    border-radius: 10px;
    background: var(--accent-soft);
    color: var(--accent);
}

.session-device-icon svg,
.session-location svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.session-device-copy {
    display: flex;
    min-width: 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
}

.session-device-copy strong {
    color: var(--text);
    font-size: 12px;
    font-weight: 700;
}

.session-current {
    display: inline-flex;
    padding: 2px 7px;
    border-radius: 999px;
    background: var(--good-soft);
    color: var(--good);
    font-size: 10px;
    font-weight: 750;
}

.session-location {
    display: inline-flex;
    min-width: 150px;
    align-items: center;
    gap: 7px;
    color: var(--text-muted);
}

.session-location svg {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    color: var(--accent);
}

.session-location.is-unavailable {
    color: var(--text-faint);
}

.session-location.is-unavailable svg {
    color: var(--text-faint);
}

.empty-inline {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 16px;
    border: 1px dashed var(--border-strong);
    border-radius: 11px;
    background: var(--bg-sunken);
    color: var(--text-muted);
}

.mfa-summary div,
.mfa-management {
    border-radius: 11px;
    background: var(--bg-sunken);
}

.mfa-management summary {
    color: var(--text);
}

.mfa-management[open] summary {
    margin-bottom: 12px;
}

@media (prefers-color-scheme: dark) {
    .chip-good { border-color: #14532d; }

    .masthead-brand .brand-text {
        color: var(--accent);
    }

    .dashboard-hero {
        background:
            linear-gradient(110deg, rgba(0, 101, 189, .16), transparent 62%),
            var(--bg-raised);
    }
}

@media (max-width: 1040px) {
    .dashboard-grid-top {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 820px) {
    .masthead {
        padding-inline: 16px;
    }

    .sidebar {
        padding: 8px 12px;
    }

    .nav-item {
        min-height: 38px;
        padding-block: 7px;
    }

    .nav-item:hover {
        transform: none;
    }

    .nav-item.is-active::before {
        display: none;
    }

    .content {
        padding: 22px 16px 56px;
    }
}

@media (max-width: 620px) {
    .masthead-brand .brand-text b {
        display: none;
    }

    .masthead-link {
        display: none;
    }

    .dashboard-hero {
        min-height: 0;
        align-items: flex-start;
        flex-direction: column;
        padding: 26px 22px;
    }

    .dashboard-hero-status {
        width: 100%;
        max-width: none;
        align-items: flex-start;
    }

    .hero-status-item {
        max-width: 100%;
    }

    .section {
        padding: 20px 17px;
    }

    .section-heading-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .profile-picture {
        align-items: flex-start;
        flex-direction: column;
    }

    .profile-picture-image,
    .profile-picture-placeholder {
        width: 82px;
        height: 82px;
        flex-basis: 82px;
    }

    .profile-picture > div {
        width: 100%;
    }

    .service-links .btn {
        width: 100%;
    }
}

/* ------------------------------------------------------- location profile -- */

.page-heading {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 26px;
}

.page-heading-icon {
    display: grid;
    width: 62px;
    height: 62px;
    flex: 0 0 62px;
    place-items: center;
    border: 1px solid var(--accent-border);
    border-radius: 18px;
    background: var(--accent-soft);
    color: var(--accent);
    box-shadow: var(--shadow);
}

.page-heading-icon svg {
    width: 29px;
    height: 29px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.page-heading .dashboard-eyebrow {
    margin-bottom: 4px;
}

.page-heading h1 {
    margin: 0 0 4px;
    color: var(--text);
    font-size: clamp(26px, 3vw, 34px);
    font-weight: 750;
    letter-spacing: -.035em;
    line-height: 1.15;
}

.page-heading p {
    margin: 0;
    color: var(--text-muted);
    font-size: 14px;
}

.location-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 290px;
    align-items: start;
    gap: 20px;
}

.location-layout .section {
    margin: 0;
}

.location-field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 18px;
}

.location-timezone-field {
    grid-column: 1 / -1;
}

.location-form-footer {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 6px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.location-form-footer .meta {
    color: var(--text-faint);
    font-size: 12px;
}

.location-privacy-card {
    position: sticky;
    top: calc(var(--masthead-h) + 24px);
    background:
        linear-gradient(145deg, rgba(0, 101, 189, .06), transparent 70%),
        var(--bg-raised);
}

.privacy-icon {
    display: grid;
    width: 44px;
    height: 44px;
    margin-bottom: 18px;
    place-items: center;
    border-radius: 13px;
    background: var(--accent-soft);
    color: var(--accent);
}

.privacy-icon svg {
    width: 23px;
    height: 23px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.location-privacy-card h2 {
    margin-bottom: 10px;
    font-size: 17px;
    font-weight: 750;
}

.location-privacy-card p {
    color: var(--text-muted);
    font-size: 13px;
}

.location-privacy-card p:last-child {
    margin-bottom: 0;
}

@media (max-width: 980px) {
    .location-layout {
        grid-template-columns: 1fr;
    }

    .location-privacy-card {
        position: static;
    }
}

@media (max-width: 620px) {
    .page-heading {
        align-items: flex-start;
    }

    .page-heading-icon {
        width: 52px;
        height: 52px;
        flex-basis: 52px;
        border-radius: 15px;
    }

    .location-field-grid {
        grid-template-columns: 1fr;
    }

    .location-timezone-field {
        grid-column: auto;
    }

    .location-form-footer {
        align-items: stretch;
        flex-direction: column;
    }
}
