/* ==========================================================
   PowerSense / Synapses - site styles (2026 modern refresh)
   All original class names are kept so existing pages keep working.
   Most dashboard markup uses inline WebForms styles, so some rules
   below deliberately override them with !important.
   ========================================================== */

:root {
    --brand: #017581;
    --brand-600: #016a75;
    --brand-700: #015a63;
    --brand-50: #e8f4f5;
    --brand-100: #cfe9eb;
    --bg: #f3f5f8;
    --surface: #ffffff;
    --surface-2: #f8fafc;
    --text: #0f172a;
    --text-2: #334155;
    --muted: #64748b;
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
    --success: #16a34a;
    --warning: #f59e0b;
    --danger: #dc2626;
    --radius: 10px;
    --radius-lg: 14px;
    --shadow-xs: 0 1px 2px rgba(15, 23, 42, .05);
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, .06), 0 1px 2px rgba(15, 23, 42, .04);
    --shadow-md: 0 8px 24px rgba(15, 23, 42, .08), 0 2px 6px rgba(15, 23, 42, .04);
    --shadow-lg: 0 20px 48px rgba(15, 23, 42, .18);
    --font: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

/* BASE
----------------------------------------------------------*/

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

body {
    background: var(--bg);
    font-size: 13px;
    font-family: var(--font);
    font-feature-settings: "cv11", "ss01";
    -webkit-font-smoothing: antialiased;
    line-height: 1.45;
    margin: 0;
    padding: 0;
    color: var(--text-2);
}

a:link, a:visited { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-700); text-decoration: underline; }
a:active { color: var(--brand-700); }

p { margin: 0 0 8px 0; line-height: 1.5; }

h1, h2, h3, h4, h5, h6 {
    color: var(--text);
    font-weight: 650;
    letter-spacing: -.015em;
    margin: 16px 0 8px 0;
}
h1 { font-size: 1.75em; }
h2 { font-size: 1.4em; }
h3 { font-size: 1.15em; }
h4 { font-size: 1.05em; }
h5, h6 { font-size: 1em; }

.rightColumn > h1, .rightColumn > h2, .leftColumn > h1, .leftColumn > h2 { margin-top: 0; }

/* APP SHELL
----------------------------------------------------------*/

.page {
    width: 100%;
    min-width: 1152px;
    max-width: none;
    margin: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.header {
    position: sticky;
    top: 0;
    z-index: 900;
    margin: 0;
    padding: 0;
    width: 100%;
    background: rgba(255, 255, 255, .92);
    -webkit-backdrop-filter: saturate(180%) blur(10px);
    backdrop-filter: saturate(180%) blur(10px);
    border-bottom: 1px solid var(--border);
}

.header-bar {
    display: flex;
    align-items: center;
    gap: 28px;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 24px;
    height: 64px;
    box-sizing: border-box;
}

.header h1 {
    font-weight: 700;
    margin: 0;
    padding: 0 0 0 20px;
    color: #f9f9f9;
    border: none;
    line-height: 2em;
    font-size: 2em;
}

.main {
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px 24px 32px 24px;
    min-height: 420px;
    box-sizing: border-box;
}

.leftCol { padding: 6px 0; margin: 12px 8px 8px 8px; width: 200px; min-height: 200px; }

.footer {
    color: var(--muted);
    padding: 8px 0 24px 0;
    margin: 0 auto;
    text-align: center;
    line-height: normal;
    font-size: .92em;
}

/* Logo */
.title { display: block; flex: 0 0 auto; text-align: left; width: auto; }
.title p { margin: 0; }
.title img { display: block; height: 40px; width: auto; }

/* User area */
.loginDisplay {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--muted);
    white-space: nowrap;
}

    .loginDisplay .bold {
        color: var(--text);
        font-weight: 600;
    }

    .loginDisplay a:link,
    .loginDisplay a:visited {
        display: inline-block;
        margin-left: 6px;
        padding: 6px 14px;
        border: 1px solid var(--border-strong);
        border-radius: 999px;
        color: var(--text-2);
        background: var(--surface);
        text-decoration: none;
        font-weight: 600;
        transition: background-color .15s, border-color .15s, color .15s;
    }

    .loginDisplay a:hover {
        background: var(--brand-50);
        border-color: var(--brand);
        color: var(--brand-700);
        text-decoration: none;
    }

/* NAVIGATION (asp:Menu, List rendering: ul.level1 > li > a.level1)
----------------------------------------------------------*/

div.hideSkiplink {
    background: transparent;
    width: auto;
    flex: 1 1 auto;
    clear: none;
}

    div.hideSkiplink > a > img { display: none; }

div.menu { padding: 0; }

    div.menu:after { content: ""; display: table; clear: both; }

    div.menu ul { list-style: none; margin: 0; padding: 0; width: auto; }

    div.menu a.level1,
    div.menu a.level1:visited {
        display: block;
        margin: 0 2px;
        padding: 8px 14px;
        border-radius: 8px;
        background: transparent;
        border: 0;
        color: var(--text-2);
        line-height: 1.35em;
        text-decoration: none;
        white-space: nowrap;
        font-weight: 600;
        transition: background-color .15s, color .15s;
    }

        div.menu a.level1:hover,
        div.menu a.level1.highlighted {
            background: var(--brand-50);
            color: var(--brand-700);
            text-decoration: none;
        }

    /* Drop-down panels (shown/positioned by the Menu script) */
    div.menu ul.level2,
    div.menu ul.level3 {
        background: var(--surface);
        border: 1px solid var(--border);
        border-radius: 12px;
        box-shadow: var(--shadow-md);
        padding: 6px;
        min-width: 230px;
        z-index: 1000;
    }

    div.menu ul.level2 { margin-top: 6px !important; }

    div.menu a.level2, div.menu a.level2:visited,
    div.menu a.level3, div.menu a.level3:visited {
        display: block;
        padding: 9px 12px;
        border-radius: 8px;
        background: transparent;
        border: 0;
        color: var(--text-2);
        text-decoration: none;
        white-space: nowrap;
        font-weight: 500;
    }

        div.menu a.level2:hover, div.menu a.level2.highlighted,
        div.menu a.level3:hover, div.menu a.level3.highlighted {
            background: var(--brand-50);
            color: var(--brand-700);
            text-decoration: none;
        }

    /* Chevron on items that open a sub-menu */
    div.menu a.popout {
        background-image: none !important;
        padding-right: 30px !important;
        position: relative;
    }

        div.menu a.popout:after {
            content: "";
            position: absolute;
            right: 13px;
            top: 50%;
            width: 6px;
            height: 6px;
            margin-top: -5px;
            border-right: 2px solid currentColor;
            border-bottom: 2px solid currentColor;
            transform: rotate(45deg);
            opacity: .6;
        }

    div.menu a.popout.level2:after,
    div.menu a.popout.level3:after {
        transform: rotate(-45deg);
        margin-top: -3px;
    }

    div.menu a.disabled,
    div.menu a.aspNetDisabled {
        opacity: .4;
        cursor: default;
    }

/* SECTIONS: fieldset + legend rendered as cards
----------------------------------------------------------*/

fieldset {
    margin: 0 0 20px 0;
    padding: 0 20px 16px 20px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    min-width: 0;
}

    /* Legend becomes a card header inside the box */
    fieldset > legend {
        float: left;
        width: 100%;
        box-sizing: border-box;
        margin: 0 0 14px 0;
        padding: 14px 0 12px 0;
        border-bottom: 1px solid var(--border);
        font-size: 14px;
        font-weight: 650;
        letter-spacing: -.01em;
        color: var(--text);
    }

        fieldset > legend + * { clear: both; }

    fieldset p { margin: 3px 8px 6px 8px; }

    fieldset.login label, fieldset.register label, fieldset.changePassword label {
        display: block;
        text-align: left;
        font-weight: 600;
        margin-bottom: 4px;
        color: var(--text);
    }

    fieldset label.inline { display: inline; font-weight: 400; }

    /* Field captions in the dashboard selection criteria */
    fieldset td > p > span[id^="MainContent_Label"] {
        color: var(--muted);
        font-size: 12px;
        font-weight: 600;
    }

    /* Inner "legend / show on map" boxes (inline: border 1px solid grey) */
    fieldset table[style*="solid grey"],
    fieldset table[style*="solid gray"] {
        border: 1px solid var(--border) !important;
        border-radius: var(--radius);
        background: var(--surface-2);
        border-collapse: separate;
        margin-bottom: 12px;
    }

legend {
    font-size: 14px;
    font-weight: 650;
    color: var(--text);
    padding: 0 6px;
}

/* FORM CONTROLS
----------------------------------------------------------*/

input[type="text"],
input[type="password"],
input[type="email"],
input[type="number"],
input[type="date"],
input[type="search"],
select,
textarea {
    box-sizing: border-box;
    font: inherit;
    color: var(--text);
    background-color: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: 8px;
    padding: 5px 10px;
    min-height: 34px;
    box-shadow: var(--shadow-xs);
    transition: border-color .15s, box-shadow .15s;
}

select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 32px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%2364748b' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 8l4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 9px center;
    background-size: 16px 16px;
    cursor: pointer;
}

    select[multiple], select[size] {
        background-image: none;
        padding-right: 10px;
    }

    input[type="text"]:hover, input[type="password"]:hover, select:hover, textarea:hover {
        border-color: #94a3b8;
    }

    input[type="text"]:focus,
    input[type="password"]:focus,
    input[type="email"]:focus,
    input[type="number"]:focus,
    input[type="date"]:focus,
    input[type="search"]:focus,
    select:focus,
    textarea:focus {
        outline: none;
        border-color: var(--brand);
        box-shadow: 0 0 0 3px rgba(1, 117, 129, .16);
    }

    input[disabled], select[disabled], textarea[disabled],
    input.aspNetDisabled, select.aspNetDisabled, textarea.aspNetDisabled {
        background-color: var(--surface-2);
        color: var(--muted);
        box-shadow: none;
        cursor: not-allowed;
    }

input.textEntry { width: 320px; }
input.passwordEntry { width: 320px; }

input[type="submit"],
input[type="button"],
input[type="reset"],
button {
    box-sizing: border-box;
    font: inherit;
    font-weight: 600;
    color: #fff;
    background-color: var(--brand);
    border: 1px solid var(--brand);
    border-radius: 8px;
    padding: 6px 16px;
    min-height: 34px;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(1, 117, 129, .25);
    transition: background-color .15s, box-shadow .15s, transform .05s;
}

    input[type="submit"]:hover,
    input[type="button"]:hover,
    input[type="reset"]:hover,
    button:hover {
        background-color: var(--brand-700);
        border-color: var(--brand-700);
    }

    input[type="submit"]:active,
    input[type="button"]:active,
    button:active { transform: translateY(1px); }

    input[type="submit"]:focus-visible,
    input[type="button"]:focus-visible,
    button:focus-visible {
        outline: none;
        box-shadow: 0 0 0 3px rgba(1, 117, 129, .3);
    }

    input[type="submit"][disabled],
    input[type="button"][disabled],
    button[disabled],
    input[type="submit"].aspNetDisabled,
    input[type="button"].aspNetDisabled {
        opacity: .45;
        cursor: not-allowed;
        box-shadow: none;
    }

input[type="image"] { border-radius: 6px; }
input[type="image"]:hover { background: var(--brand-50); }

input[type="checkbox"], input[type="radio"] {
    accent-color: var(--brand);
    width: 15px;
    height: 15px;
    vertical-align: middle;
    cursor: pointer;
}

div.accountInfo { width: 42%; }
div.units { width: 100%; }

/* DATA TABLES (GridView: table[rules])
----------------------------------------------------------*/

table[rules] {
    border-collapse: separate !important;
    border-spacing: 0;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--text-2) !important;
    font-variant-numeric: tabular-nums;
}

    table[rules] > tbody > tr > td,
    table[rules] > tbody > tr > th {
        border: 0 !important;
        border-bottom: 1px solid var(--border) !important;
    }

    table[rules] > tbody > tr:last-child > td { border-bottom: 0 !important; }

    /* Neutralise the old beige/white inline row colours */
    table[rules] > tbody > tr {
        background-color: var(--surface) !important;
        color: var(--text-2) !important;
    }

        table[rules] > tbody > tr:nth-child(odd):not(:first-child) {
            background-color: #fbfcfd !important;
        }

        table[rules] > tbody > tr:hover > td {
            background-color: var(--brand-50);
        }

        /* Selected row (SelectedRowStyle #E2DED6) */
        table[rules] > tbody > tr[style*="background-color:#E2DED6"],
        table[rules] > tbody > tr[style*="background-color:#e2ded6"] {
            background-color: var(--brand-100) !important;
            box-shadow: inset 3px 0 0 var(--brand);
        }

        /* Pager row (PagerStyle #284775) */
        table[rules] > tbody > tr[style*="background-color:#284775"] {
            background-color: var(--surface-2) !important;
        }

            table[rules] > tbody > tr[style*="background-color:#284775"] td { padding: 10px; }

            table[rules] > tbody > tr[style*="background-color:#284775"] a,
            table[rules] > tbody > tr[style*="background-color:#284775"] span {
                display: inline-block;
                min-width: 26px;
                padding: 3px 6px;
                margin: 0 1px;
                border-radius: 6px;
                text-align: center;
                color: var(--text-2) !important;
            }

            table[rules] > tbody > tr[style*="background-color:#284775"] span {
                background: var(--brand);
                color: #fff !important;
                font-weight: 600;
            }

        /* Footer row (FooterStyle #017581) */
        table[rules] > tbody > tr[style*="background-color:#017581"]:last-child {
            background-color: var(--surface-2) !important;
            color: var(--text) !important;
        }

th {
    background: var(--surface-2) !important;
    color: var(--muted) !important;
    font-size: 11px;
    font-weight: 650 !important;
    text-transform: uppercase;
    letter-spacing: .03em;
    line-height: 1.3;
    text-align: left;
    vertical-align: bottom;
    position: sticky !important;
    top: 64px; /* below the sticky header */
    z-index: 2;
    box-shadow: inset 0 -1px 0 var(--border);
}

    /* Tables that scroll inside their own box: stick to the top of that box */
    div[style*="overflow"] th { top: 0; }

    th a:link, th a:visited {
        color: var(--muted) !important;
        text-decoration: none;
    }

    th a:hover { color: var(--brand) !important; }

/* Layout tables keep tight spacing; data grids get roomier cells */
th, td { padding: .25rem; }

table[rules] > tbody > tr > td,
table[rules] > tbody > tr > th { padding: .5rem .55rem; }

/* "Open" / "Select" ButtonField links -> small buttons */
td > a[href*="'Select$"] {
    display: inline-block;
    padding: 3px 12px;
    border: 1px solid var(--brand-100);
    border-radius: 999px;
    background: var(--brand-50);
    color: var(--brand-700) !important;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none !important;
    transition: background-color .15s, color .15s, border-color .15s;
}

    td > a[href*="'Select$"]:hover {
        background: var(--brand);
        border-color: var(--brand);
        color: #fff !important;
    }

/* Modern status icons (replace the old clip-art images in place) */
img[src$="green_correct_mark.png"] {
    content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='10' fill='%23dcfce7'/%3E%3Ccircle cx='12' cy='12' r='6.5' fill='%2316a34a'/%3E%3Cpath d='M9.2 12.2l1.9 1.9 3.8-4' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

img[src$="red_incorrect_mark.png"] {
    content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='10' fill='%23fee2e2'/%3E%3Ccircle cx='12' cy='12' r='6.5' fill='%23dc2626'/%3E%3Cpath d='M9.8 9.8l4.4 4.4M14.2 9.8l-4.4 4.4' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
}

img[src$="ci_orange_correct_mark.png"] {
    content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='10' fill='%23fef3c7'/%3E%3Ccircle cx='12' cy='12' r='6.5' fill='%23f59e0b'/%3E%3Cpath d='M9.2 12.2l1.9 1.9 3.8-4' fill='none' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

img[src$="Minus.png"] {
    content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M8 12h8' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
}

/* Search icon button */
input[type="image"][src$="search.png"] {
    content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23017581' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4 4'/%3E%3C/svg%3E");
    padding: 6px;
    width: 32px !important;
    height: 32px !important;
    box-sizing: border-box;
    border: 1px solid var(--border-strong);
    border-radius: 8px;
    background: var(--surface);
}

/* STAT CARDS (AMR dashboards: total / online / offline)
----------------------------------------------------------*/

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    width: calc(97% + 42px); /* same outer width as the 97% fieldset cards (padding + border) */
    margin: 0 0 20px 0;
}

.stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 16px 18px;
}

.stat-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
}

.stat-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--muted);
}

.stat-online .stat-dot { background: var(--success); box-shadow: 0 0 0 3px #dcfce7; }
.stat-offline .stat-dot { background: var(--danger); box-shadow: 0 0 0 3px #fee2e2; }
.stat-online .stat-value { color: #15803d; }
.stat-offline .stat-value { color: #b91c1c; }

.stat-value {
    margin-top: 6px;
    font-size: 28px;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -.02em;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

.stat-sub {
    margin-top: 4px;
    font-size: 12px;
    color: var(--muted);
}

.stat-bar {
    height: 8px;
    margin-top: 12px;
    border-radius: 999px;
    background: #fee2e2;
    overflow: hidden;
}

    .stat-bar.empty { background: var(--border); }

    .stat-bar > span {
        display: block;
        height: 100%;
        border-radius: 999px;
        background: var(--success);
        transition: width .3s ease;
    }

/* AMR POWERFLEX (channel / comms / contactor status blocks)
----------------------------------------------------------*/

.pf-stats { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.pf-stat-nosn .stat-value { color: #b45309; }
.stat-dot.pf-dot-nosn { background: var(--warning); box-shadow: 0 0 0 3px #fef3c7; }

.pf-legend {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 18px;
    margin: 0 0 14px 0;
    padding: 10px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface-2);
    font-size: 12px;
    color: var(--text-2);
}

    .pf-legend > span { display: inline-flex; align-items: center; gap: 6px; }
    .pf-legend-hint { color: var(--muted); }

.pf-table { width: 100%; }
    .pf-table td { vertical-align: middle; }

.pf-mono { font-family: Consolas, "Courier New", monospace; font-size: 12px; }
.pf-num { text-align: right; }
.pf-nowrap { white-space: nowrap; }
.pf-muted { color: var(--muted); }
.pf-stale {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    background: #fee2e2;
    color: #b91c1c;
    font-weight: 600;
    white-space: nowrap;
}
.pf-empty { color: var(--muted); padding: 8px 0; }

.pf-strips { white-space: nowrap; width: 1%; }

.pf-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    line-height: 1;
    margin: 2px 0;
}

.pf-strip-label {
    width: 62px;
    font-size: 11px;
    color: var(--muted);
    font-weight: 600;
}

.pf-blocks { display: inline-flex; gap: 2px; }

.pf-b {
    display: inline-block;
    width: 10px;
    height: 12px;
    border-radius: 2px;
    background: #cbd5e1;
}

    .pf-b.pf-gap { margin-right: 5px; }   /* small gap after every 8 channels */
    .pf-b.pf-on   { background: #16a34a; }
    .pf-b.pf-nosn { background: #f59e0b; }
    .pf-b.pf-off  { background: #dc2626; }
    .pf-b.pf-na   { background: #e2e8f0; }

.pf-legend .pf-b { width: 12px; height: 12px; }

/* MISC
----------------------------------------------------------*/

.clear { clear: both; }
.failureNotification { font-size: 1em; color: var(--danger); text-align: left; }
.bold { font-weight: 600; }
.submitButton { text-align: right; padding-right: 10px; }
.hiddencol { display: none; }
.disabledImageButton { opacity: .25; background-color: #111; }
.ghostChart { opacity: .25; background-color: grey; }
.ghost { opacity: .95; background-color: lightgray; }
.imgLink:hover { cursor: pointer; }

/* Scroll-to-top button */
#myBtn {
    display: none;
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 99;
    width: 44px;
    height: 44px;
    min-height: 0;
    padding: 0;
    font-size: 18px;
    line-height: 44px;
    border: none;
    border-radius: 50%;
    background-color: var(--brand);
    color: #fff;
    cursor: pointer;
    box-shadow: var(--shadow-md);
}

    #myBtn:hover { background-color: var(--brand-700); }

/* MODAL POPUPS (AjaxControlToolkit ModalPopupExtender)
----------------------------------------------------------*/

.modalBackground {
    background-color: rgba(15, 23, 42, .5);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

div[id$="pnlAddDevice"],
div[id$="pnlPopup"],
div[id$="pnlUnitRegistration"] {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

/* LOADING OVERLAY (UpdateProgress)
----------------------------------------------------------*/

.overlay {
    position: fixed;
    z-index: 998;
    inset: 0;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(243, 245, 248, .65);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
}

.overlayContent {
    position: fixed;
    z-index: 999;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    width: auto;
    height: auto;
    padding: 20px 28px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 14px;
}

    .overlayContent h2 { font-size: 14px; font-weight: 600; color: var(--text); margin: 0; }
    .overlayContent img { width: 80px; height: 80px; }

.spinner {
    width: 26px;
    height: 26px;
    border: 3px solid var(--brand-100);
    border-top-color: var(--brand);
    border-radius: 50%;
    animation: ps-spin .8s linear infinite;
}

@keyframes ps-spin { to { transform: rotate(360deg); } }

/* LOGIN / ACCOUNT PAGES
----------------------------------------------------------*/

.auth-card {
    max-width: 420px;
    margin: 56px auto 16px auto;
    padding: 32px 36px;
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    background: var(--surface);
}

    .auth-card h2 { margin-top: 0; font-size: 22px; }
    .auth-card div.accountInfo { width: 100%; }

    .auth-card fieldset {
        border: 0;
        padding: 0;
        margin: 12px 0;
        box-shadow: none;
        background: transparent;
    }

        .auth-card fieldset legend { display: none; }

        .auth-card fieldset p { margin: 0 0 14px 0; position: relative; }

            /* keep the required-field "*" marker from wrapping onto its own line */
            .auth-card fieldset p > span.failureNotification {
                position: absolute;
                right: -14px;
                bottom: 8px;
            }

    .auth-card input.textEntry,
    .auth-card input.passwordEntry { width: 100%; min-height: 40px; }

    .auth-card .submitButton { padding-right: 0; }

        .auth-card .submitButton input[type="submit"] { width: 100%; min-height: 42px; }

    .auth-card .muted { color: var(--muted); }

/* PRINT
----------------------------------------------------------*/

@media print {
    body { background: #fff; }
    .header { position: static; }
    .page { min-width: 0; }
    .hideSkiplink, .loginDisplay, #myBtn, .footer { display: none !important; }
    fieldset { box-shadow: none; }
    th { position: static !important; }
}
