:root {
    --bg: #0b0f14;
    --panel: #141a22;
    --panel2: #1b2430;
    --border: #2d3744;
    --text: #f4f7fb;
    --muted: #8f9baa;
    --blue: #2777f6;
    --green: #219653;
    --red: #d33b3b;
    --yellow: #e0a21b;
}

* {
    box-sizing: border-box;
}

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

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
}

.login-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
}

.login-card,
.panel,
.deposit-card {
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 14px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, .30);
}

.login-card {
    width: min(430px, calc(100vw - 30px));
    padding: 34px;
}

.login-card h1 {
    margin: 0;
    font-size: 34px;
}

.login-card p {
    color: var(--muted);
    margin-top: 8px;
}

.topbar {
    height: 68px;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--panel);
    border-bottom: 1px solid var(--border);
}

.brand {
    font-size: 21px;
    font-weight: 900;
}

.user-area {
    display: flex;
    align-items: center;
    gap: 14px;
}

.layout {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    min-height: calc(100vh - 68px);
}

.sidebar {
    padding: 22px 14px;
    background: #10151c;
    border-right: 1px solid var(--border);
}

.sidebar h3 {
    color: var(--muted);
    margin: 0 10px 14px;
}

.shop-link {
    display: block;
    color: var(--text);
    text-decoration: none;
    padding: 13px 14px;
    border-radius: 8px;
    margin-bottom: 7px;
    transition: background .15s ease;
}

.shop-link:hover,
.shop-link.active {
    background: var(--blue);
}

.content {
    padding: 26px;
    display: grid;
    gap: 20px;
}

.deposit-card {
    padding: 28px;
    text-align: center;
}

.small-title {
    color: var(--muted);
    font-size: 18px;
    font-weight: bold;
}

.deposit-label {
    margin-top: 16px;
    color: var(--muted);
    letter-spacing: .12em;
    font-weight: bold;
}

.deposit-value {
    font-size: clamp(42px, 7vw, 76px);
    font-weight: 900;
    margin: 12px 0;
}

.panel {
    padding: 24px;
}

.panel h2 {
    margin: 0 0 20px;
}

label {
    display: block;
    margin: 18px 0 8px;
    color: var(--muted);
    font-weight: bold;
}

input {
    width: 100%;
    height: 50px;
    padding: 10px 14px;
    background: var(--panel2);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 20px;
    outline: none;
}

input:focus {
    border-color: var(--blue);
}

.btn {
    border: 0;
    border-radius: 8px;
    padding: 13px 18px;
    color: white;
    text-decoration: none;
    font-weight: 900;
    cursor: pointer;
}

.btn.primary {
    background: var(--blue);
}

.btn.warning {
    background: var(--yellow);
    color: #111;
}

.btn.danger {
    background: var(--red);
}

.btn.quick {
    background: var(--panel2);
    border: 1px solid var(--border);
}

.btn.quick:hover {
    border-color: var(--blue);
}

.btn.full {
    width: 100%;
    margin-top: 22px;
}

.quick-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
}

.button-row {
    display: flex;
    gap: 12px;
    margin-top: 18px;
}

.button-row .btn {
    flex: 1;
}

.alert {
    padding: 14px 16px;
    border-radius: 8px;
    font-weight: bold;
}

.alert.success {
    background: rgba(33, 150, 83, .20);
    border: 1px solid var(--green);
}

.alert.danger {
    background: rgba(211, 59, 59, .20);
    border: 1px solid var(--red);
}

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

.table-wrap {
    overflow: auto;
}

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

th,
td {
    text-align: left;
    padding: 13px 14px;
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}

th {
    background: var(--panel2);
    position: sticky;
    top: 0;
    z-index: 1;
}

tr:hover td {
    background: rgba(255, 255, 255, .02);
}

.empty {
    text-align: center;
    color: var(--muted);
}

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

    .sidebar {
        border-right: 0;
        border-bottom: 1px solid var(--border);
    }

    .quick-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .button-row {
        flex-direction: column;
    }

    .topbar {
        height: auto;
        min-height: 68px;
        padding: 14px;
        gap: 14px;
        flex-wrap: wrap;
    }
}

.table-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

input[readonly] {
    opacity: 0.75;
    cursor: not-allowed;
}
