﻿@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@500;700;800&family=Rajdhani:wght@400;500;600;700&display=swap');

:root {
    --bg-900: #07040d;
    --bg-800: #11071f;
    --bg-700: #1a0a2d;
    --panel: rgba(17, 8, 30, 0.78);
    --panel-strong: rgba(24, 10, 41, 0.9);
    --line: rgba(235, 213, 255, 0.2);
    --line-strong: rgba(211, 150, 255, 0.42);
    --text: #f5edff;
    --muted: #bda8d2;
    --violet: #a60cff;
    --magenta: #e600ff;
    --rose: #ff3dd9;
    --ring: #efe8ff;
}

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

body {
    font-family: 'Rajdhani', sans-serif;
    color: var(--text);
    min-height: 100vh;
}

.auth-bg,
.panel-bg {
    background:
        radial-gradient(circle at 14% 18%, rgba(255, 61, 217, 0.24), transparent 40%),
        radial-gradient(circle at 88% 12%, rgba(166, 12, 255, 0.24), transparent 36%),
        radial-gradient(circle at 50% 100%, rgba(72, 24, 109, 0.35), transparent 42%),
        linear-gradient(140deg, var(--bg-900), var(--bg-800) 55%, var(--bg-700));
}

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

.lang-floating {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 20;
}

.lang-dropdown {
    position: relative;
    z-index: 11000;
}

.lang-dropdown summary {
    list-style: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 132px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(211, 150, 255, 0.4);
    background: rgba(10, 5, 18, 0.88);
    color: #fff;
    cursor: pointer;
    user-select: none;
    font-weight: 700;
}

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

.lang-dropdown summary::after {
    content: '▾';
    margin-left: auto;
    color: var(--muted);
}

.lang-dropdown[open] summary::after {
    content: '▴';
}

.lang-dropdown-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 170px;
    background: rgba(10, 5, 18, 0.96);
    border: 1px solid rgba(211, 150, 255, 0.34);
    border-radius: 10px;
    padding: 6px;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.45);
    transform-origin: top right;
    animation: menu-pop 0.18s ease;
    z-index: 12000;
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--text);
    border-radius: 8px;
    padding: 8px 10px;
    font-weight: 600;
}

.lang-option:hover {
    background: rgba(166, 12, 255, 0.14);
}

.lang-option.active {
    background: rgba(166, 12, 255, 0.25);
    border: 1px solid rgba(211, 150, 255, 0.48);
}

.lang-flag {
    width: 20px;
    height: 15px;
    border-radius: 3px;
    object-fit: cover;
    display: block;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.16);
}

.auth-card {
    width: min(480px, 100%);
    background: linear-gradient(170deg, var(--panel), rgba(18, 8, 31, 0.72));
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 36px;
    text-align: center;
    box-shadow:
        0 26px 54px rgba(0, 0, 0, 0.5),
        inset 0 0 0 1px rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    animation: rise-in 0.5s ease;
}

.brand-logo {
    width: 100px;
    height: 100px;
    border-radius: 22px;
    object-fit: cover;
    margin-bottom: 16px;
    box-shadow: 0 0 0 2px rgba(239, 232, 255, 0.22), 0 0 34px rgba(230, 0, 255, 0.25);
}

.auth-card h1 {
    font-family: 'Orbitron', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 2rem;
    margin-bottom: 10px;
}

.auth-card p {
    color: var(--muted);
    font-size: 1.1rem;
    line-height: 1.4;
    margin-bottom: 24px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 22px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 1rem;
}

.btn-discord {
    color: #fff;
    background: linear-gradient(135deg, var(--violet), var(--magenta));
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 12px 28px rgba(166, 12, 255, 0.35);
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.btn-discord:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 34px rgba(230, 0, 255, 0.35);
    filter: brightness(1.08);
}

.btn-muted {
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.auth-switch {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 12px;
}

.auth-form {
    text-align: left;
}

.auth-form .btn {
    margin-top: 4px;
}


.topbar {
    width: min(1120px, calc(100% - 24px));
    margin: 14px auto 0;
    background: linear-gradient(180deg, rgba(22, 10, 38, 0.9), rgba(15, 8, 28, 0.86));
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    animation: topbar-drop 0.45s ease;
    position: relative;
    z-index: 10000;
    overflow: visible;
}

.topbar-logo {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    object-fit: cover;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.topbar nav {
    display: flex;
    gap: 8px;
}

.topbar-lang {
    margin-left: auto;
    position: relative;
    z-index: 11000;
}

.topbar a {
    text-decoration: none;
    color: var(--muted);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    padding: 9px 12px;
    border-radius: 10px;
    border: 1px solid transparent;
    transition: 0.2s ease;
    position: relative;
    overflow: hidden;
}

.topbar a::after {
    content: '';
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 6px;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(230, 0, 255, 0), rgba(230, 0, 255, 0.8), rgba(230, 0, 255, 0));
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.22s ease;
}

.topbar a:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.12);
    background: rgba(166, 12, 255, 0.14);
}

.topbar a:hover::after {
    transform: scaleX(1);
}

.topbar a.active {
    color: #fff;
    background: linear-gradient(135deg, rgba(166, 12, 255, 0.28), rgba(230, 0, 255, 0.22));
    border-color: var(--line-strong);
}

.panel-grid {
    width: min(1120px, calc(100% - 24px));
    margin: 18px auto 26px;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 14px;
}

.card {
    background: linear-gradient(165deg, var(--panel), var(--panel-strong));
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 20px;
    box-shadow:
        0 20px 38px rgba(0, 0, 0, 0.36),
        inset 0 0 0 1px rgba(255, 255, 255, 0.03);
    animation: rise-in 0.48s ease;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.panel-grid > .card:nth-child(2) {
    animation-delay: 0.04s;
}

.panel-grid > .card:nth-child(3) {
    animation-delay: 0.08s;
}

.panel-grid > .card:nth-child(4) {
    animation-delay: 0.12s;
}

.panel-grid > .card:nth-child(5) {
    animation-delay: 0.16s;
}

.panel-grid > .card:hover {
    transform: translateY(-2px);
    border-color: rgba(211, 150, 255, 0.4);
    box-shadow:
        0 24px 44px rgba(0, 0, 0, 0.42),
        inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.highlight {
    grid-column: span 12;
    border-color: var(--line-strong);
    position: relative;
    overflow: hidden;
}

.highlight::before {
    content: '';
    position: absolute;
    inset: -40% auto auto -20%;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(230, 0, 255, 0.3), transparent 70%);
    pointer-events: none;
}

.panel-grid .card:nth-child(2),
.panel-grid .card:nth-child(3) {
    grid-column: span 6;
}

.owner-page .topbar {
    width: calc(100% - 24px);
    max-width: none;
}

.owner-page .panel-grid {
    width: calc(100% - 24px);
    max-width: none;
    gap: 16px;
}

.payment-page .topbar {
    width: calc(100% - 24px);
    max-width: none;
}

.payment-page .panel-grid {
    width: calc(100% - 24px);
    max-width: none;
    gap: 16px;
}

.payment-page .panel-grid .reseller-payment-card {
    grid-column: span 12;
}

.owner-page .panel-grid .owner-account-card {
    grid-column: span 4;
}

.owner-page .panel-grid .owner-generate-card {
    grid-column: span 8;
}

.owner-page .panel-grid .owner-pricing-card,
.owner-page .panel-grid .owner-balance-card {
    grid-column: span 6;
}

.table-card {
    grid-column: span 12;
}

.card h1,
.card h2 {
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.card h1 {
    font-size: 1.68rem;
    margin-bottom: 6px;
}

.card h2 {
    font-size: 1.04rem;
    margin-bottom: 12px;
}

.card p,
.card span {
    color: var(--muted);
    font-size: 1.06rem;
}

.user-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.user-row img {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.user-row strong {
    display: block;
    font-size: 1.1rem;
}

.account-card {
    border-color: rgba(211, 150, 255, 0.36);
}

.profile-shell {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px;
    border-radius: 14px;
    border: 1px solid rgba(215, 166, 255, 0.3);
    background: linear-gradient(150deg, rgba(18, 9, 31, 0.9), rgba(14, 7, 25, 0.78));
}

.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 16px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.16);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.35);
}

.profile-main {
    flex: 1;
    min-width: 0;
}

.profile-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.profile-head strong {
    font-size: 1.18rem;
    color: #fff;
    line-height: 1.1;
}

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

.meta-item {
    display: grid;
    gap: 3px;
    border-radius: 10px;
    border: 1px solid rgba(211, 150, 255, 0.22);
    background: rgba(255, 255, 255, 0.03);
    padding: 10px 12px;
}

.meta-label {
    color: #ddc7f1;
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.meta-value {
    color: #fff;
    font-size: 0.98rem;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.loader-card {
    border-color: rgba(211, 150, 255, 0.36);
    grid-column: span 12;
}

.loader-state {
    border-radius: 12px;
    padding: 16px 18px;
    border: 1px solid;
    margin-bottom: 12px;
}

.loader-state-ok {
    border-color: rgba(82, 232, 165, 0.42);
    background: linear-gradient(145deg, rgba(30, 118, 86, 0.16), rgba(15, 61, 44, 0.25));
}

.loader-state-locked {
    border-color: rgba(255, 125, 172, 0.42);
    background: linear-gradient(145deg, rgba(120, 33, 66, 0.16), rgba(77, 21, 42, 0.24));
}

.loader-title {
    color: #fff;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700;
}

.loader-subtitle {
    margin-top: 4px;
    color: #ddd0ee;
    font-size: 1.05rem;
    line-height: 1.45;
}

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

.clean-list {
    list-style: none;
    display: grid;
    gap: 8px;
}

.clean-list li {
    background: rgba(166, 12, 255, 0.14);
    border: 1px solid rgba(217, 128, 255, 0.3);
    border-radius: 10px;
    padding: 10px 12px;
}

.redeem-form {
    display: grid;
    gap: 10px;
}

.redeem-form label {
    color: var(--muted);
    font-size: 0.95rem;
}

.redeem-form input {
    width: 100%;
    border: 1px solid rgba(211, 150, 255, 0.45);
    border-radius: 10px;
    background: rgba(8, 4, 14, 0.7);
    color: var(--text);
    padding: 11px 12px;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.redeem-form select {
    width: 100%;
    border: 1px solid rgba(211, 150, 255, 0.45);
    border-radius: 10px;
    background: rgba(8, 4, 14, 0.85);
    color: var(--text);
    padding: 11px 12px;
    font-size: 1rem;
    outline: none;
}

.redeem-form input:focus {
    border-color: var(--magenta);
    box-shadow: 0 0 0 2px rgba(230, 0, 255, 0.18);
}

.notice {
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 12px;
    font-weight: 600;
}

.notice-ok {
    background: rgba(45, 188, 126, 0.16);
    border: 1px solid rgba(82, 232, 165, 0.45);
    color: #c6ffe4;
}

.notice-error {
    background: rgba(255, 76, 136, 0.16);
    border: 1px solid rgba(255, 125, 172, 0.45);
    color: #ffd8e6;
}

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

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

.keys-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 560px;
}

.keys-table th,
.keys-table td {
    text-align: left;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.keys-table th {
    color: #fff;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.keys-table td {
    color: var(--muted);
}

.inline-form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.inline-form select {
    border: 1px solid rgba(211, 150, 255, 0.45);
    border-radius: 10px;
    background: rgba(8, 4, 14, 0.85);
    color: var(--text);
    padding: 8px 10px;
}

.inline-form .btn {
    padding: 8px 12px;
    font-size: 0.9rem;
}

.pin-remove-form {
    margin-top: 10px;
}

.role-badge {
    display: inline-block;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    padding: 2px 9px;
    font-size: 0.8rem;
    color: #fff;
    background: rgba(166, 12, 255, 0.28);
}

.docs-grid {
    align-items: start;
    grid-template-columns: minmax(230px, 280px) minmax(0, 1fr);
}

.docs-sidebar {
    grid-column: auto;
    position: sticky;
    top: 92px;
    display: grid;
    gap: 8px;
    max-height: calc(100vh - 106px);
    overflow: auto;
}

.docs-content-wrap {
    grid-column: auto;
    display: grid;
    gap: 16px;
    min-width: 0;
}

.docs-hero {
    border-color: rgba(211, 150, 255, 0.45);
    background:
        radial-gradient(circle at 88% 6%, rgba(230, 0, 255, 0.18), transparent 48%),
        linear-gradient(165deg, rgba(24, 10, 43, 0.9), rgba(17, 8, 30, 0.9));
}

.docs-hero p {
    max-width: 64ch;
    line-height: 1.5;
    color: #ddd0ee;
    font-size: 1.12rem;
}

.docs-section {
    border-color: rgba(211, 150, 255, 0.25);
    background: linear-gradient(165deg, rgba(18, 9, 31, 0.9), rgba(15, 8, 27, 0.92));
}

.docs-section h2 {
    margin-bottom: 14px;
    color: #fff;
}

.docs-section p,
.docs-section li,
.docs-section td {
    color: #ded2ef;
    font-size: 1.08rem;
}

.docs-section .notice {
    margin-top: 12px;
}

.docs-sidebar h2 {
    margin-bottom: 4px;
}

.docs-link {
    display: block;
    text-decoration: none;
    color: #d7c7ea;
    border: 1px solid transparent;
    border-radius: 10px;
    padding: 10px 12px;
    font-weight: 700;
    transition: 0.2s ease;
}

.docs-link:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.12);
    background: rgba(166, 12, 255, 0.14);
}

.docs-link.active {
    color: #fff;
    border-color: var(--line-strong);
    background: linear-gradient(135deg, rgba(166, 12, 255, 0.28), rgba(230, 0, 255, 0.22));
}

.docs-support-link {
    margin-top: 10px;
}

.docs-list li {
    line-height: 1.45;
    border-left: 3px solid rgba(230, 0, 255, 0.45);
    background: rgba(174, 92, 240, 0.15);
}

.docs-code {
    margin-top: 10px;
    border-radius: 10px;
    border: 1px solid rgba(160, 255, 199, 0.35);
    background: #08080b;
    color: #d8ffd2;
    font-family: Consolas, "Courier New", monospace;
    font-size: 0.96rem;
    line-height: 1.55;
    padding: 12px;
    overflow-x: auto;
    white-space: pre;
    scrollbar-width: thin;
}

.docs-table th,
.docs-table td {
    white-space: normal;
    vertical-align: middle;
}

.docs-table th {
    color: #f7f1ff;
}

.docs-table td {
    color: #ded2ef;
}

.docs-table tbody tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.04);
}

.docs-table tbody tr:hover {
    background: rgba(166, 12, 255, 0.12);
}

.docs-steps {
    margin-left: 20px;
    color: #ded2ef;
    display: grid;
    gap: 8px;
    line-height: 1.5;
}

.docs-status {
    text-transform: uppercase;
}

.docs-status-active {
    background: rgba(45, 188, 126, 0.18);
    border-color: rgba(82, 232, 165, 0.45);
}

.docs-status-coming {
    background: rgba(166, 12, 255, 0.25);
    border-color: rgba(211, 150, 255, 0.48);
}

@keyframes rise-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes topbar-drop {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes menu-pop {
    from {
        opacity: 0;
        transform: translateY(-4px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (max-width: 740px) {
    .auth-card {
        padding: 28px 20px;
    }

    .auth-card h1 {
        font-size: 1.6rem;
    }

    .panel-grid .card:nth-child(2),
    .panel-grid .card:nth-child(3) {
        grid-column: span 12;
    }

    .owner-page .panel-grid .owner-account-card,
    .owner-page .panel-grid .owner-generate-card,
    .owner-page .panel-grid .owner-pricing-card,
    .owner-page .panel-grid .owner-balance-card {
        grid-column: span 12;
    }

    .docs-sidebar,
    .docs-content-wrap {
        grid-column: auto;
    }

    .docs-sidebar {
        position: static;
        max-height: none;
        overflow: visible;
    }

    .docs-grid {
        grid-template-columns: 1fr;
    }

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

    .profile-avatar {
        width: 64px;
        height: 64px;
    }

    .profile-head {
        flex-wrap: wrap;
    }

    .loader-card {
        grid-column: span 12;
    }

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

    .topbar nav {
        width: 100%;
    }

    .topbar a {
        flex: 1;
        text-align: center;
    }

    .topbar-lang {
        margin-left: 0;
        width: 100%;
    }

    .topbar-lang summary {
        width: 100%;
    }

    .topbar-lang .lang-dropdown-menu {
        left: 0;
        right: auto;
        width: 100%;
    }

    .lang-floating {
        top: 10px;
        right: 10px;
    }
}

@media (max-width: 1200px) {
    .owner-page .panel-grid .owner-account-card,
    .owner-page .panel-grid .owner-generate-card,
    .owner-page .panel-grid .owner-pricing-card,
    .owner-page .panel-grid .owner-balance-card {
        grid-column: span 12;
    }
}

.table-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
}

.table-tools .table-search,
.table-tools .table-status-filter {
    border: 1px solid rgba(211, 150, 255, 0.45);
    border-radius: 10px;
    background: rgba(8, 4, 14, 0.85);
    color: var(--text);
    padding: 10px 12px;
    font-size: 0.96rem;
    min-height: 42px;
}

.table-tools .table-search {
    flex: 1 1 240px;
}

.table-tools .table-status-filter {
    flex: 0 1 190px;
}

.table-tools .table-export-btn {
    min-height: 42px;
}

.copy-key-btn {
    min-height: 36px;
    font-size: 0.85rem;
}

.nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    margin-left: 8px;
    border-radius: 999px;
    background: linear-gradient(135deg, #ff8a00, #ff3d00);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0 6px;
}

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

.tier-option {
    border: 1px solid rgba(211, 150, 255, 0.35);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.03);
    padding: 8px 12px;
    cursor: pointer;
    display: grid;
    gap: 2px;
}

.tier-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.tier-option .tier-name {
    color: #fff;
    font-weight: 700;
    font-size: 0.9rem;
}

.tier-option .tier-price {
    color: #ddc7f1;
    font-size: 0.82rem;
}

.tier-option.is-active {
    border-color: rgba(211, 150, 255, 0.48);
    background: rgba(166, 12, 255, 0.12);
}

.reseller-cart-table th,
.reseller-cart-table td {
    vertical-align: middle;
}

.reseller-cart-card {
    position: relative;
    overflow: hidden;
    border-color: rgba(211, 150, 255, 0.26);
}

.reseller-cart-card::before {
    content: '';
    position: absolute;
    inset: -45% auto auto -18%;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(166, 12, 255, 0.14), transparent 72%);
    pointer-events: none;
}

.reseller-cart-form {
    position: relative;
    z-index: 1;
    padding: 14px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
}

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

.cart-preview-grid p {
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    padding: 8px 10px;
    color: #efe6ff;
    font-weight: 600;
}

.cart-section-title {
    margin-top: 18px;
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.95rem;
}

.cart-empty-state {
    border: 1px dashed rgba(255, 255, 255, 0.22);
    border-radius: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.03);
}

.reseller-cart-table-wrap {
    margin-top: 8px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
}

.reseller-cart-table thead th {
    background: rgba(255, 255, 255, 0.04);
    color: #ece3f7;
}

.reseller-cart-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.035);
}

.cart-inline-form {
    flex-wrap: wrap;
    gap: 6px;
}

.cart-summary-grid {
    margin-top: 12px;
}

.cart-summary-grid .meta-item {
    border-color: rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.025);
}

.cart-checkout-form {
    margin-top: 12px;
}

.cart-checkout-btn {
    width: 100%;
    min-height: 46px;
    font-size: 1rem;
    background: linear-gradient(135deg, #7f3dff, #5d2bd9);
    box-shadow: 0 10px 24px rgba(127, 61, 255, 0.28);
}

.reseller-payment-card {
    border-color: rgba(211, 150, 255, 0.26);
    background:
        radial-gradient(circle at 90% 0%, rgba(166, 12, 255, 0.12), transparent 36%),
        linear-gradient(165deg, var(--panel), var(--panel-strong));
}

.checkout-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 360px);
    gap: 14px;
    align-items: start;
}

.checkout-items {
    display: grid;
    gap: 10px;
}

.checkout-item {
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
    padding: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.checkout-item-main h3 {
    margin: 0 0 10px;
    color: #fff;
    font-size: 1.06rem;
}

.checkout-item-meta {
    display: grid;
    gap: 8px;
}

.checkout-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 10px;
    padding: 8px 10px;
    background: rgba(8, 4, 14, 0.42);
}

.checkout-meta-row span {
    color: #dcc8ef;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.checkout-meta-row strong {
    color: #fff;
    font-size: 0.94rem;
    text-align: right;
}

.checkout-item-total {
    min-width: 135px;
    padding-left: 12px;
    border-left: 1px solid rgba(255, 255, 255, 0.12);
    text-align: right;
    display: grid;
    gap: 2px;
}

.checkout-item-total span {
    color: #ddc7f1;
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.checkout-item-total strong {
    color: #fff;
    font-size: 1.1rem;
}

.checkout-summary-card {
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
    padding: 14px;
    position: sticky;
    top: 88px;
}

.checkout-summary-card h3 {
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.checkout-summary-lines {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
}

.checkout-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 8px 10px;
    background: rgba(255, 255, 255, 0.03);
}

.checkout-summary-row span {
    color: #ddc7f1;
    font-size: 0.78rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.checkout-summary-row strong {
    color: #fff;
    font-size: 0.98rem;
}

.cart-cancel-form {
    margin-top: 8px;
}

.cart-cancel-btn {
    width: 100%;
    min-height: 42px;
}

.generated-groups-card {
    border-color: rgba(211, 150, 255, 0.24);
}

.generated-group-title {
    margin-bottom: 8px;
    margin-top: 12px;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    letter-spacing: 0.04em;
    color: #fff;
}

.generated-group-title:first-of-type {
    margin-top: 4px;
}

.generated-keys-list li {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.16);
}

.owner-pricing-table input[type="number"],
.reseller-cart-table input[type="number"] {
    width: 110px;
    border: 1px solid rgba(211, 150, 255, 0.45);
    border-radius: 10px;
    background: rgba(8, 4, 14, 0.85);
    color: var(--text);
    padding: 8px 10px;
}

.owner-price-form {
    display: inline;
}

@media (max-width: 740px) {
    .topbar nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .table-tools {
        display: grid;
        grid-template-columns: 1fr;
    }

    .table-tools .table-search,
    .table-tools .table-status-filter,
    .table-tools .table-export-btn {
        width: 100%;
    }

    .responsive-table {
        min-width: 0;
    }

    .responsive-table thead {
        display: none;
    }

    .responsive-table tbody,
    .responsive-table tr,
    .responsive-table td {
        display: block;
        width: 100%;
    }

    .responsive-table tr {
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 12px;
        margin-bottom: 10px;
        padding: 6px;
        background: rgba(255, 255, 255, 0.02);
    }

    .responsive-table td {
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        padding: 10px;
    }

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

    .responsive-table td::before {
        content: attr(data-label);
        display: block;
        color: #ddc7f1;
        font-size: 0.72rem;
        font-weight: 700;
        letter-spacing: 0.06em;
        text-transform: uppercase;
        margin-bottom: 4px;
    }

    .cart-preview-grid {
        grid-template-columns: 1fr;
    }

    .tier-selector {
        grid-template-columns: 1fr;
    }

    .checkout-layout {
        grid-template-columns: 1fr;
    }

    .checkout-summary-card {
        position: static;
    }

    .checkout-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .checkout-item-main {
        width: 100%;
    }

    .checkout-item-total {
        border-left: 0;
        padding-left: 0;
        border-top: 1px solid rgba(255, 255, 255, 0.12);
        padding-top: 8px;
    }

    .checkout-item-total {
        min-width: 0;
        width: 100%;
        text-align: left;
    }
}
