@import url("https://grandtelecomus.com/font/typographhy/stylesheet.css");

:root {
    color-scheme: light;
    --brand-blue: #1a68b2;
    --brand-blue-deep: #162644;
    --brand-blue-soft: #e6f0fb;
    --brand-ice: #f4f8fd;
    --panel: rgba(255, 255, 255, 0.96);
    --ink: #10233c;
    --muted: #55616d;
    --line: rgba(26, 104, 178, 0.14);
    --success: #177a55;
    --success-soft: #ddf3ea;
    --warn: #8d6b12;
    --warn-soft: #f8edc8;
    --danger: #a33838;
    --danger-soft: #f8dfdf;
    --shadow: 0 22px 50px rgba(15, 40, 79, 0.12);
}

@media (prefers-color-scheme: dark) {
    :root {
        color-scheme: dark;
        --brand-blue: #5aa8f2;
        --brand-blue-deep: #081a32;
        --brand-blue-soft: rgba(90, 168, 242, 0.18);
        --brand-ice: #040a12;
        --panel: rgba(8, 18, 30, 0.94);
        --ink: #e7f0fa;
        --muted: #9cb0c3;
        --line: rgba(90, 168, 242, 0.18);
        --success: #72d6ab;
        --success-soft: rgba(30, 94, 71, 0.34);
        --warn: #e5c164;
        --warn-soft: rgba(123, 95, 24, 0.3);
        --danger: #e27777;
        --danger-soft: rgba(117, 43, 43, 0.34);
        --shadow: 0 22px 50px rgba(0, 0, 0, 0.28);
    }

    body {
        background:
            radial-gradient(circle at top left, rgba(90, 168, 242, 0.1), transparent 20%),
            radial-gradient(circle at right 20%, rgba(12, 30, 56, 0.28), transparent 28%),
            linear-gradient(180deg, #5f5a55 0%, var(--brand-ice) 52%, #14191f 100%);
    }

    .site-header {
        background:
            linear-gradient(135deg, rgba(6, 16, 31, 0.98) 0%, rgba(13, 47, 87, 0.97) 58%, rgba(21, 93, 150, 0.9) 100%);
        border-bottom-color: rgba(255, 255, 255, 0.08);
        box-shadow: 0 20px 45px rgba(0, 0, 0, 0.34);
    }

    .partner-mark {
        background: rgba(255, 255, 255, 0.08);
        border-color: rgba(255, 255, 255, 0.1);
    }

    .partner-name {
        color: #f5f7fb;
    }

    .stat-card,
    .panel,
    .login-card,
    .banner,
    .toolbar-field,
    input,
    select,
    .button {
        background: rgba(7, 14, 24, 0.98);
        color: var(--ink);
        border-color: var(--line);
    }

    .nav-links a {
        background: rgba(255, 255, 255, 0.06);
        border-color: rgba(255, 255, 255, 0.1);
    }

    .nav-links a:hover {
        background: rgba(255, 255, 255, 0.12);
    }

    input:focus,
    select:focus {
        outline-color: rgba(90, 168, 242, 0.24);
        border-color: var(--brand-blue);
    }

    .button:hover:not(.button-primary):not(.button-danger) {
        border-color: var(--brand-blue);
    }

    .button-primary {
        color: #f7fbff;
        border: none;
        background: linear-gradient(135deg, #12345f, var(--brand-blue));
        background-clip: padding-box;
        overflow: hidden;
        box-shadow: 0 12px 24px rgba(18, 52, 95, 0.32);
    }

    .button-danger {
        color: #fff7f7;
        background: linear-gradient(135deg, #692730, #b34f58);
    }

    .toolbar-field select {
        background: transparent;
        color: var(--ink);
    }

    .history-filters .filter-form input,
    .history-filters .filter-form select {
        background: #666a70;
        border-color: rgba(255, 255, 255, 0.12);
    }

    .history-page .assign-form select {
        background: #666a70;
        border-color: rgba(255, 255, 255, 0.12);
    }

    .history-page .nav-form .button,
    .history-page .history-filters .inline-actions .button:not(.button-primary):not(.button-danger),
    .history-page .panel-header .button:not(.button-primary):not(.button-danger),
    .history-page .toolbar-field {
        background: #666a70;
        border-color: rgba(255, 255, 255, 0.12);
    }

.dashboard-page .form-grid input,
.dashboard-page .form-grid select,
.dashboard-page .nav-form .button,
.dashboard-page .button:not(.button-primary):not(.button-danger) {
    background: #666a70;
    border-color: rgba(255, 255, 255, 0.12);
}

.dashboard-page .layout-two > .panel {
    overflow-x: hidden;
}

.dashboard-page .layout-two .data-table {
    table-layout: fixed;
}

.dashboard-page .layout-two .data-table th,
.dashboard-page .layout-two .data-table td {
    overflow-wrap: anywhere;
}

    .zebra-table tbody tr:nth-child(odd) {
        background: rgba(255, 255, 255, 0.06);
    }

    .zebra-table tbody tr:nth-child(even) {
        background: rgba(90, 168, 242, 0.11);
    }

    .pill-blocked,
    .pill-block {
        background: rgba(148, 45, 16, 0.28);
        color: #ffb59e;
    }

    .pill-not-blocked,
    .pill-reject {
        background: rgba(24, 122, 84, 0.32);
        color: #9ae2c3;
    }

    .pill-unprovisioned {
        background: rgba(141, 107, 18, 0.3);
        color: #f1d07a;
    }

    .pill-rejected {
        background: rgba(70, 85, 143, 0.3);
        color: #bbc7ff;
    }

    .pill-error {
        background: rgba(141, 39, 77, 0.32);
        color: #f0a9c6;
    }
}

* { box-sizing: border-box; }

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Pangram", "IBM Plex Sans", "Segoe UI", sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at top left, rgba(26, 104, 178, 0.18), transparent 26%),
        radial-gradient(circle at right 20%, rgba(22, 38, 68, 0.12), transparent 28%),
        linear-gradient(180deg, #f7fbff 0%, var(--brand-ice) 56%, #eef5fb 100%);
}

a {
    color: var(--brand-blue);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

img {
    max-width: 100%;
    height: auto;
}

.shell {
    width: min(1200px, calc(100vw - 32px));
    margin: 0 auto;
}

.site-header {
    color: #fff;
    background:
        linear-gradient(135deg, rgba(22, 38, 68, 0.98) 0%, rgba(26, 104, 178, 0.96) 62%, rgba(31, 137, 196, 0.92) 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 45px rgba(15, 40, 79, 0.2);
}

.header-shell {
    padding: 22px 0 28px;
}

.brand-bar,
.header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.brand-bar {
    margin-bottom: 24px;
}

.brand-lockup,
.partner-lockup {
    display: grid;
    gap: 10px;
}

.partner-lockup {
    justify-items: center;
    text-align: center;
}

.brand-lockup:hover {
    text-decoration: none;
}

.brand-caption,
.partner-caption {
    color: rgba(255, 255, 255, 0.74);
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.brand-logo {
    width: 188px;
    display: block;
}

.partner-mark {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.partner-logo {
    width: 88px;
    height: auto;
    display: block;
}

.partner-name {
    font-weight: 700;
    color: #000;
    letter-spacing: 0.02em;
    font-size: 1rem;
}

.header-row {
    align-items: end;
}

.eyebrow {
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.76rem;
    color: rgba(255, 255, 255, 0.72);
}

.site-title {
    margin: 0;
    font-size: clamp(2rem, 4vw, 3.2rem);
    line-height: 0.98;
    letter-spacing: -0.03em;
}

.site-subtitle {
    margin: 10px 0 0;
    max-width: 720px;
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.84);
}

.nav-links {
    display: flex;
    gap: 14px;
    align-items: center;
    flex-wrap: wrap;
}

.nav-meta {
    position: relative;
    display: flex;
    align-items: center;
}

.nav-links a {
    color: #fff;
    font-weight: 700;
    padding: 11px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.nav-links a:hover {
    text-decoration: none;
    background: rgba(255, 255, 255, 0.16);
}

.nav-form {
    margin: 0;
}

.version-label {
    position: absolute;
    left: 50%;
    bottom: calc(100% + 4px);
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
    white-space: nowrap;
}

.page-stack {
    padding: 28px 0 42px;
    display: grid;
    gap: 24px;
}

.page-heading {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: end;
}

.banner {
    border-radius: 18px;
    padding: 14px 18px;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.banner-success {
    background: rgba(23, 122, 85, 0.08);
    border-color: rgba(23, 122, 85, 0.16);
}

.banner-error {
    background: var(--danger-soft);
    border-color: rgba(163, 56, 56, 0.16);
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
}

.stat-card,
.panel,
.login-card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 22px;
    box-shadow: var(--shadow);
}

.stat-card {
    padding: 22px;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--brand-blue-deep), var(--brand-blue), #53a5de);
}

.stat-label {
    display: block;
    color: var(--muted);
    font-size: 0.8rem;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.stat-value {
    font-size: 2.1rem;
    line-height: 1;
}

.layout-two {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.panel,
.login-card {
    padding: 22px;
    overflow: auto;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 16px;
    margin-bottom: 16px;
}

.panel-header h2,
.page-heading h2 {
    margin: 0;
}

.section-eyebrow {
    color: var(--muted);
    margin-bottom: 10px;
}

.form-grid {
    display: grid;
    gap: 14px;
}

.form-grid label {
    display: grid;
    gap: 8px;
    font-weight: 700;
}

input,
select {
    width: 100%;
    min-height: 48px;
    border-radius: 14px;
    border: 1px solid rgba(26, 104, 178, 0.18);
    background: #fff;
    padding: 12px 14px;
    font: inherit;
    color: var(--ink);
}

input:focus,
select:focus {
    outline: 2px solid rgba(26, 104, 178, 0.18);
    border-color: var(--brand-blue);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    appearance: none;
    -webkit-appearance: none;
    border-radius: 999px;
    border: 1px solid rgba(26, 104, 178, 0.18);
    background: #fff;
    color: var(--ink);
    padding: 10px 16px;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.button:hover:not(.button-primary):not(.button-danger) {
    text-decoration: none;
    border-color: var(--brand-blue);
    transform: translateY(-1px);
}

.button-primary {
    color: #fff;
    border: none;
    background: linear-gradient(135deg, var(--brand-blue-deep), var(--brand-blue));
    background-clip: padding-box;
    overflow: hidden;
    box-shadow: 0 12px 24px rgba(26, 104, 178, 0.22);
}

.button-danger {
    color: #fff;
    border-color: transparent;
    background: linear-gradient(135deg, #7f2730, var(--danger));
}

.button-small {
    padding: 7px 12px;
    font-size: 0.9rem;
}

.inline-actions,
.actions,
.filter-form {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.toolbar-form {
    margin: 0;
}

.toolbar-field {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    border: 1px solid rgba(26, 104, 178, 0.18);
    background: #fff;
    font-weight: 700;
    white-space: nowrap;
}

.toolbar-field span {
    font-size: 0.85rem;
}

.toolbar-field select {
    min-height: auto;
    height: auto;
    width: auto;
    border: none;
    background: transparent;
    padding: 0 18px 0 0;
    font-weight: 700;
    outline: none;
}

.filter-form {
    align-items: end;
}

.filter-form label {
    display: grid;
    gap: 8px;
    min-width: 160px;
    font-weight: 700;
}

.filter-form input,
.filter-form select {
    height: 48px;
    border-radius: 14px;
    appearance: none;
    -webkit-appearance: none;
}

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

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.data-table th,
.data-table td {
    padding: 9px 10px;
    text-align: left;
    vertical-align: top;
}

.data-table thead th {
    color: var(--muted);
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.zebra-table tbody tr:nth-child(odd) {
    background: rgba(22, 38, 68, 0.03);
}

.zebra-table tbody tr:nth-child(even) {
    background: rgba(26, 104, 178, 0.01);
}

.pill {
    display: inline-flex;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.pill-blocked,
.pill-block {
    background: #f9d9d0;
    color: #922d10;
}

.pill-not-blocked,
.pill-reject {
    background: var(--success-soft);
    color: var(--success);
}

.pill-unprovisioned {
    background: var(--warn-soft);
    color: var(--warn);
    box-shadow: none;
}

.pill-rejected {
    background: #e1e5f6;
    color: #46558f;
}

.pill-error {
    background: #eed6de;
    color: #8d274d;
}

.pill-action {
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    border: none;
    outline: none;
    box-shadow: none;
    font: inherit;
}

.assign-inline {
    display: inline-grid;
    vertical-align: middle;
}

.assign-inline > * {
    grid-area: 1 / 1;
}

.assign-form {
    margin: 0;
}

.assign-form[hidden] {
    display: none;
}

.assign-toggle,
.assign-form select {
    width: 100%;
    height: 100%;
    min-height: 0;
}

.login-wrap {
    min-height: calc(100vh - 260px);
    display: grid;
    place-items: center;
}

.login-card {
    width: min(480px, 100%);
}

.login-form {
    margin-top: 20px;
}

.collapsible-panel {
    display: grid;
    gap: 0;
}

.collapsible-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    cursor: pointer;
    list-style: none;
}

.collapsible-summary::-webkit-details-marker {
    display: none;
}

.collapsible-indicator {
    width: 12px;
    height: 12px;
    border-right: 2px solid var(--brand-blue);
    border-bottom: 2px solid var(--brand-blue);
    transform: rotate(45deg);
    transition: transform 0.2s ease;
    flex: 0 0 auto;
    margin-right: 8px;
}

.collapsible-panel[open] .collapsible-indicator {
    transform: rotate(225deg);
    margin-top: 6px;
}

.collapsible-content {
    display: grid;
    gap: 16px;
    padding-top: 18px;
}

.collapsible-content p {
    margin: 0;
    line-height: 1.6;
}

.getting-started-title {
    font-weight: 700;
}

.getting-started-steps {
    margin: 0;
    padding-left: 20px;
    display: grid;
    gap: 10px;
    line-height: 1.6;
}

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

    .brand-bar,
    .header-row,
    .page-heading {
        align-items: start;
        flex-direction: column;
    }
}
