

/* =========================================================
   QADEER ADMIN PANEL — PREMIUM UI
   Dark Navy / Electric Cyan
   Android + Desktop Responsive
   No animations | Existing functionality preserved
========================================================= */

:root {
    --bg: #080d18;
    --bg-soft: #0c1422;
    --panel: #101a2b;
    --panel-2: #142239;
    --panel-3: #192a42;

    --cyan: #35d9ff;
    --cyan-dark: #087eaa;
    --blue: #2776ed;

    --text: #edf5ff;
    --muted: #91a2ba;
    --muted-2: #71839d;

    --border: rgba(130, 165, 210, .16);
    --border-light: rgba(130, 165, 210, .25);

    --green: #38e5a0;
    --green-bg: rgba(38, 210, 135, .12);

    --red: #ff737d;
    --red-bg: rgba(255, 80, 90, .12);

    --yellow: #ffd166;
    --yellow-bg: rgba(255, 190, 60, .12);

    --radius: 15px;
    --radius-sm: 10px;
}

/* ================= GLOBAL ================= */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    min-height: 100%;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: auto;
}

body {
    font-family: system-ui, -apple-system, 'Segoe UI',
        Roboto, Arial, sans-serif;

    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-tap-highlight-color: transparent;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    -webkit-appearance: none;
    appearance: none;
}

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

img {
    max-width: 100%;
    display: block;
}

/* ================= HEADER / BANNER ================= */

.banner {
    position: relative;
    overflow: hidden;
    padding: 30px 16px 27px;
    text-align: center;

    background:
        radial-gradient(
            ellipse at 85% 0%,
            rgba(53, 217, 255, .17),
            transparent 48%
        ),
        linear-gradient(
            135deg,
            #14243d 0%,
            #0c1729 55%,
            #080d18 100%
        );

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

.banner::after {
    content: "";
    position: absolute;
    width: 190px;
    height: 190px;
    right: -90px;
    bottom: -130px;
    border: 1px solid rgba(53, 217, 255, .17);
    border-radius: 50%;
    pointer-events: none;
}

.banner h1 {
    position: relative;
    z-index: 1;
    color: #eafaff;
    font-size: clamp(21px, 4vw, 32px);
    font-weight: 900;
    letter-spacing: 1.5px;
    line-height: 1.3;
}

.banner p {
    position: relative;
    z-index: 1;
    color: #91a9c5;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1.5px;
    margin-top: 7px;
}

/* ================= NAVIGATION ================= */

.nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 8px;

    padding: 12px 12px;

    background: #0c1422;
    border-bottom: 1px solid var(--border);
}

.nav a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 39px;
    padding: 8px 14px;

    background: #142035;
    border: 1px solid var(--border);
    border-radius: 9px;

    color: #b9c8dc;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.nav a.active {
    background: rgba(53, 217, 255, .13);
    border-color: rgba(53, 217, 255, .55);
    color: var(--cyan);
}

/* ================= MAIN LAYOUT ================= */

.wrap {
    width: 100%;
    max-width: 1150px;
    margin: 0 auto;
    padding: 25px 18px 45px;
}

h2.title {
    display: flex;
    align-items: center;
    gap: 10px;

    color: #e9f6ff;
    font-size: 20px;
    font-weight: 850;
    line-height: 1.4;

    margin: 7px 0 17px;
}

h2.title::after {
    content: "";
    flex: 1;
    height: 1px;
    min-width: 15px;

    background: linear-gradient(
        90deg,
        rgba(53, 217, 255, .35),
        transparent
    );
}

.note {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
    margin-bottom: 17px;
}

.note b {
    color: #dceeff;
}

/* ================= MESSAGES ================= */

.msg {
    display: none;
    padding: 12px 14px;
    margin-bottom: 15px;

    border-radius: 10px;
    font-size: 13px;
    line-height: 1.6;

    overflow-wrap: anywhere;
}

.msg.ok {
    display: block;
    background: var(--green-bg);
    border: 1px solid rgba(56, 229, 160, .3);
    color: #8ff5c9;
}

.msg.err {
    display: block;
    background: var(--red-bg);
    border: 1px solid rgba(255, 115, 125, .3);
    color: #ffadb2;
}

/* ================= GRID ================= */

.grid {
    display: grid;
    grid-template-columns: repeat(
        auto-fit,
        minmax(min(100%, 225px), 1fr)
    );
    gap: 15px;
    width: 100%;
}

/* ================= CARDS ================= */

.card {
    min-width: 0;
    padding: 19px;

    background: linear-gradient(
        145deg,
        var(--panel-2),
        var(--panel)
    );

    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.card h3 {
    color: #dcecff;
    font-size: 14px;
    font-weight: 750;
    margin-bottom: 11px;
    overflow-wrap: anywhere;
}

.card .big {
    color: #f4faff;
    font-size: 32px;
    font-weight: 900;
    line-height: 1.3;
    letter-spacing: -.8px;
}

.card .sub {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.65;
    margin-top: 7px;
    overflow-wrap: anywhere;
}

/* ================= STATUS BADGES ================= */

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 5px 9px;

    border-radius: 30px;
    font-size: 10px;
    font-weight: 850;
    letter-spacing: .4px;
    white-space: nowrap;
    vertical-align: middle;
}

.badge.on {
    background: var(--green-bg);
    color: var(--green);
    border: 1px solid rgba(56, 229, 160, .22);
}

.badge.off {
    background: var(--red-bg);
    color: var(--red);
    border: 1px solid rgba(255, 115, 125, .22);
}

.badge.warn {
    background: var(--yellow-bg);
    color: var(--yellow);
    border: 1px solid rgba(255, 209, 102, .22);
}

/* ================= TABLES ================= */

.tblwrap {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;

    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 13px;

    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: #29445e #101a2b;
}

table {
    width: 100%;
    min-width: 540px;
    border-collapse: collapse;

    color: var(--text);
    font-size: 13px;
}

th,
td {
    padding: 14px 13px;
    text-align: left;
    vertical-align: middle;

    border-bottom: 1px solid rgba(130, 165, 210, .1);
}

th {
    background: #18273d;
    color: #8ce9ff;

    font-size: 11px;
    font-weight: 850;
    letter-spacing: .6px;
    white-space: nowrap;
    text-transform: uppercase;
}

td {
    color: #c9d7e9;
    overflow-wrap: anywhere;
}

td b {
    color: #f0f7ff;
}

tr:last-child td {
    border-bottom: none;
}

/* ================= FORMS ================= */

label {
    display: block;
    color: #c8d8eb;

    font-size: 12px;
    font-weight: 800;

    margin: 15px 0 7px;
}

input,
select,
textarea {
    display: block;
    width: 100%;
    min-height: 46px;

    padding: 11px 13px;

    background: #0a1220;
    border: 1px solid #2a3b53;
    border-radius: 10px;

    color: #eff8ff;
    font-size: 14px;

    outline: none;
    color-scheme: dark;
}

input::placeholder,
textarea::placeholder {
    color: #657991;
    opacity: 1;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--cyan);
    outline: 2px solid rgba(53, 217, 255, .13);
}

select {
    cursor: pointer;
}

select option {
    background: #101a2b;
    color: #fff;
}

textarea {
    min-height: 100px;
    resize: vertical;
}

/* ================= BUTTONS ================= */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    min-height: 43px;
    padding: 11px 18px;
    margin-top: 14px;

    background: linear-gradient(
        135deg,
        #19bfe8,
        #1479bd
    );

    border: 1px solid rgba(53, 217, 255, .3);
    border-radius: 10px;

    color: #03131f;
    font-size: 13px;
    font-weight: 900;

    cursor: pointer;
    text-align: center;
    white-space: normal;
}

.btn:disabled {
    opacity: .55;
    cursor: not-allowed;
}

.btn.secondary {
    background: #18283e;
    color: #a9eaff;
    border: 1px solid #2c4967;
}

.btn.danger {
    background: #a92939;
    color: #fff;
    border: 1px solid #d94c5c;
}

.btn.small {
    min-height: 34px;
    padding: 7px 12px;
    margin-top: 0;
    font-size: 11px;
    border-radius: 8px;
}

.btnrow {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.btnrow .btn {
    margin-top: 0;
}

/* ================= SETUP / SPECIAL PANELS ================= */

.setup {
    padding: 17px;
    margin-bottom: 17px;

    background: linear-gradient(
        145deg,
        #142239,
        #101a2b
    );

    border: 1px solid rgba(53, 217, 255, .3);
    border-radius: var(--radius);
}

.setup h3 {
    color: var(--cyan);
    font-size: 15px;
    margin-bottom: 10px;
}

/* ================= FOOTER ================= */

.foot {
    padding: 23px 12px 28px;
    text-align: center;

    background: #0a111d;
    border-top: 1px solid var(--border);

    color: #71849d;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .5px;
}

/* ================= LOGIN PAGE ================= */

.login-wrap {
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
    padding: 45px 18px 35px;
}

.login-logo {
    text-align: center;
    margin-bottom: 25px;
}

.login-logo h1 {
    color: var(--cyan);
    font-size: 27px;
    font-weight: 950;
    letter-spacing: 2px;
}

.login-logo p {
    color: var(--muted);
    font-size: 11px;
    letter-spacing: 2px;
    margin-top: 7px;
}

.login-card {
    padding: 23px 19px;

    background: linear-gradient(
        145deg,
        #15243a,
        #0e1828
    );

    border: 1px solid rgba(53, 217, 255, .24);
    border-radius: 18px;
}

.login-card .btn {
    width: 100%;
    margin-top: 20px;
    min-height: 48px;
}

.login-footer {
    text-align: center;
    color: var(--muted-2);
    font-size: 12px;
    padding: 23px 10px;
}

.login-footer b {
    color: var(--cyan);
}

/* ================= MOBILE RESPONSIVE ================= */

@media (max-width: 700px) {

    .banner {
        padding: 25px 13px;
    }

    .nav {
        flex-wrap: nowrap;
        justify-content: flex-start;

        overflow-x: auto;
        overflow-y: hidden;

        padding: 11px 10px;
        scrollbar-width: none;

        -webkit-overflow-scrolling: touch;
    }

    .nav::-webkit-scrollbar {
        display: none;
    }

    .nav a {
        flex: 0 0 auto;
    }

    .wrap {
        padding: 21px 13px 35px;
    }

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

    .card {
        padding: 15px;
        border-radius: 13px;
    }

    .card .big {
        font-size: 27px;
    }

    .card h3 {
        font-size: 12px;
    }

    .card .sub {
        font-size: 11px;
    }

    h2.title {
        font-size: 17px;
    }

    th,
    td {
        padding: 12px 10px;
    }

    .btn {
        min-height: 44px;
    }

    .btnrow {
        gap: 8px;
    }

    .btnrow .btn {
        flex: 1 1 auto;
    }
}

/* ================= SMALL ANDROID SCREENS ================= */

@media (max-width: 360px) {

    .banner h1 {
        font-size: 19px;
    }

    .banner p {
        font-size: 10px;
    }

    .wrap {
        padding-left: 10px;
        padding-right: 10px;
    }

    .grid {
        gap: 8px;
    }

    .card {
        padding: 12px 10px;
    }

    .card .big {
        font-size: 23px;
    }

    .card h3 {
        font-size: 11px;
    }

    .btn {
        padding: 10px 12px;
        font-size: 12px;
    }

    .login-card {
        padding: 19px 14px;
    }
}

/* ================= ACCESSIBILITY ================= */

button:focus-visible,
a:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation: none !important;
        transition: none !important;
    }
}
