/*
 * Tretuz classic shell
 *
 * Visual-only layer for the public authentication and lobby screens.
 * All forms, IDs, onclick handlers and runtime-created room cards remain
 * owned by the PHP/JavaScript application.
 */

:root {
    --tc-purple-950: #100523;
    --tc-purple-900: #1b0a3a;
    --tc-purple-850: #24104c;
    --tc-purple-800: #311567;
    --tc-purple-700: #4a218b;
    --tc-panel: rgba(13, 13, 17, 0.94);
    --tc-panel-soft: rgba(24, 14, 48, 0.88);
    --tc-panel-raised: rgba(42, 20, 81, 0.84);
    --tc-line: rgba(255, 255, 255, 0.09);
    --tc-line-gold: rgba(250, 200, 0, 0.2);
    --tc-text: #f8f7fb;
    --tc-muted: rgba(238, 234, 246, 0.58);
    --tc-gold: #fac800;
    --tc-orange: #ed6519;
    --tc-green: #20a950;
    --tc-cyan: #19b9c5;
    --tc-red: #d92f3e;
    --tc-shadow: 0 20px 70px rgba(2, 0, 8, 0.48);
}

html {
    min-height: 100%;
    color-scheme: dark;
    background: #08040f;
}

body.classic-auth,
body.classic-lobby {
    color: var(--tc-text);
    background:
        radial-gradient(circle at 50% -18%, rgba(119, 54, 197, 0.5), transparent 44%),
        radial-gradient(circle at 15% 78%, rgba(61, 20, 115, 0.35), transparent 38%),
        linear-gradient(155deg, #16072f 0%, #0d031d 58%, #07040d 100%);
}

body.classic-auth::before,
body.classic-lobby::before {
    position: fixed;
    inset: 0;
    z-index: 0;
    content: "";
    pointer-events: none;
    opacity: 0.38;
    background-image:
        repeating-linear-gradient(0deg, transparent 0 3px, rgba(255, 255, 255, 0.018) 3px 4px),
        repeating-linear-gradient(90deg, transparent 0 4px, rgba(0, 0, 0, 0.04) 4px 5px);
}

/* Authentication --------------------------------------------------------- */

body.classic-auth {
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: max(18px, env(safe-area-inset-top)) 14px max(18px, env(safe-area-inset-bottom));
    overflow-x: hidden;
}

body.classic-auth .page {
    z-index: 1;
    width: min(100%, 430px);
    min-height: 0;
    padding: 0;
    overflow: hidden;
    display: block;
    background: var(--tc-panel);
    border: 1px solid rgba(250, 200, 0, 0.14);
    border-radius: 30px;
    box-shadow: var(--tc-shadow), 0 0 55px rgba(107, 47, 174, 0.14);
}

body.classic-auth .page::before {
    display: block;
    width: 100%;
    height: 4px;
    content: "";
    background: linear-gradient(90deg, #fac800, #ef7b19 54%, #fac800);
}

body.classic-auth .form-area {
    display: block;
    padding: 24px 22px 26px;
}

.classic-brand {
    margin: 1px 0 25px;
    text-align: center;
}

.classic-brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    color: #f0edf5;
    font-size: 24px;
    font-weight: 900;
    letter-spacing: 0.27em;
    line-height: 1;
    text-shadow: 0 0 15px rgba(250, 200, 0, 0.35);
}

.classic-brand-mark span {
    color: var(--tc-gold);
    font-size: 21px;
    letter-spacing: 0;
    transform: translateY(-1px);
}

.classic-brand p {
    margin-top: 10px;
    color: var(--tc-muted);
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.035em;
}

.classic-auth-tabs {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    margin-bottom: 22px;
    padding: 4px;
    border: 1px solid rgba(250, 200, 0, 0.1);
    border-radius: 15px;
    background: rgba(0, 0, 0, 0.35);
}

.classic-auth-tabs a {
    min-height: 36px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    color: rgba(255, 255, 255, 0.47);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.075em;
    text-decoration: none;
    transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}

.classic-auth-tabs a.active {
    color: #17100a;
    background: linear-gradient(105deg, #f4ce19, #ef741b);
    box-shadow: 0 7px 20px rgba(222, 112, 20, 0.2);
}

.classic-auth-tabs a:active {
    transform: scale(0.98);
}

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

body.classic-auth form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

body.classic-auth .field {
    margin: 0;
}

body.classic-auth .field label {
    margin: 0 0 7px 2px;
    color: rgba(239, 236, 245, 0.68);
    font-size: 12px;
    font-weight: 600;
}

body.classic-auth .input-wrap {
    position: relative;
}

body.classic-auth .input-wrap::before {
    position: absolute;
    top: 50%;
    left: 15px;
    z-index: 1;
    width: 16px;
    height: 16px;
    content: "";
    opacity: 0.63;
    transform: translateY(-50%);
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

body.classic-auth .field:has(input[type="email"]) .input-wrap::before {
    border: 1.5px solid currentColor;
    border-radius: 3px;
    background:
        linear-gradient(145deg, transparent 47%, currentColor 48% 52%, transparent 53%) 0 0 / 50% 70% no-repeat,
        linear-gradient(215deg, transparent 47%, currentColor 48% 52%, transparent 53%) 100% 0 / 50% 70% no-repeat;
}

body.classic-auth .field:has(input[name="username"]) .input-wrap::before {
    border: 1.5px solid currentColor;
    border-radius: 50% 50% 42% 42%;
    clip-path: polygon(20% 0, 80% 0, 80% 42%, 100% 60%, 100% 100%, 0 100%, 0 60%, 20% 42%);
}

body.classic-auth .field:has(input[type="password"]) .input-wrap::before {
    width: 14px;
    height: 13px;
    border: 1.5px solid currentColor;
    border-radius: 3px;
    box-shadow: inset 0 4px transparent;
}

body.classic-auth .field input {
    width: 100%;
    height: 52px;
    padding: 0 46px 0 42px;
    color: #fff;
    font-size: 14px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(250, 200, 0, 0.1);
    border-radius: 15px;
    outline: none;
    box-shadow: inset 0 1px rgba(255, 255, 255, 0.02);
}

body.classic-auth .field input::placeholder {
    color: rgba(231, 225, 239, 0.29);
}

body.classic-auth .field input:focus {
    color: #fff;
    background: rgba(0, 0, 0, 0.5);
    border-color: rgba(250, 200, 0, 0.55);
    box-shadow: 0 0 0 4px rgba(250, 200, 0, 0.08);
}

body.classic-auth .eye-btn {
    right: 10px;
    width: 32px;
    height: 32px;
    padding: 0;
    display: grid;
    place-items: center;
    color: rgba(255, 255, 255, 0.48);
    font-size: 16px;
}

body.classic-auth .btn-login,
body.classic-auth .btn-register {
    width: 100%;
    height: 48px;
    margin: 2px 0 0;
    color: #17100a;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.065em;
    background: linear-gradient(105deg, #f4cf1c, #f28c1b 52%, #e85c18);
    border: 0;
    border-radius: 12px;
    box-shadow: 0 9px 26px rgba(230, 103, 21, 0.2);
}

body.classic-auth .btn-login:hover,
body.classic-auth .btn-register:hover {
    background: linear-gradient(105deg, #ffe03b, #fb9b25 52%, #f06a1c);
}

body.classic-auth .btn-login:active,
body.classic-auth .btn-register:active {
    transform: translateY(1px);
}

body.classic-auth .links {
    margin-top: 17px;
}

body.classic-auth .links p,
body.classic-auth .links .forgot {
    color: rgba(238, 234, 246, 0.48);
    font-size: 12px;
}

body.classic-auth .links p {
    margin-bottom: 9px;
}

body.classic-auth .links a,
body.classic-auth .links .forgot:hover {
    color: var(--tc-gold);
}

body.classic-auth .alert {
    margin: 0 0 16px;
    padding: 10px 12px;
    color: #ffb8bd;
    font-size: 12px;
    line-height: 1.4;
    background: rgba(163, 26, 45, 0.22);
    border: 1px solid rgba(241, 75, 89, 0.28);
    border-radius: 10px;
}

body.classic-auth .alert-success {
    color: #a7efbd;
    background: rgba(27, 136, 72, 0.2);
    border-color: rgba(68, 203, 111, 0.3);
}

body.classic-auth .support-btn {
    z-index: 3;
    right: max(13px, env(safe-area-inset-right));
    bottom: max(13px, env(safe-area-inset-bottom));
    padding: 8px 13px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 10px;
    letter-spacing: 0.04em;
    background: rgba(19, 9, 39, 0.86);
    border: 1px solid rgba(250, 200, 0, 0.22);
    border-radius: 9px;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.35);
}

/* Lobby ------------------------------------------------------------------ */

body.classic-lobby {
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    overflow: hidden;
}

body.classic-lobby .app-container {
    --bg: var(--tc-purple-950);
    --surface: #170b30;
    --surface2: rgba(44, 21, 84, 0.92);
    --surface3: rgba(56, 28, 104, 0.92);
    --border: rgba(255, 255, 255, 0.08);
    --text: var(--tc-text);
    --muted: var(--tc-muted);
    --green: var(--tc-green);
    --green2: #4adb75;
    --orange: var(--tc-orange);
    --amber: var(--tc-gold);
    --blue: #2469bd;
    --red: var(--tc-red);

    z-index: 1;
    width: 100%;
    max-width: 384px;
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
    color: var(--tc-text);
    background:
        radial-gradient(circle at 50% -15%, rgba(118, 56, 187, 0.26), transparent 42%),
        linear-gradient(180deg, #1b0b3b 0%, #130729 100%);
    border-inline: 1px solid rgba(255, 255, 255, 0.035);
    box-shadow: 0 0 80px rgba(2, 0, 7, 0.58);
}

body.classic-lobby .app-container > header {
    min-height: 58px;
    padding: 10px 12px;
    background: rgba(18, 7, 39, 0.94);
    border-bottom: 1px solid rgba(250, 200, 0, 0.08);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.14);
}

body.classic-lobby .header-logo {
    gap: 8px;
}

body.classic-lobby .header-logo .logo-icon {
    width: 34px;
    height: 34px;
    color: #19100a;
    font-size: 19px;
    border-radius: 9px;
    background: linear-gradient(145deg, #f7d524, #e96a19);
    box-shadow: 0 6px 18px rgba(226, 102, 21, 0.22);
}

body.classic-lobby .header-logo .logo-text {
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.095em;
}

body.classic-lobby .header-logo .logo-text span {
    margin-top: 4px;
    color: rgba(235, 230, 243, 0.47);
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

body.classic-lobby .header-right {
    gap: 7px;
}

body.classic-lobby .balance-pill {
    min-height: 34px;
    padding: 5px 9px;
    gap: 5px;
    color: #ffe343;
    font-size: 13px;
    border: 1px solid rgba(250, 200, 0, 0.15);
    border-radius: 10px;
    background: rgba(4, 2, 10, 0.34);
}

body.classic-lobby .balance-pill .b-icon {
    font-size: 13px;
}

body.classic-lobby .balance-pill .b-chevron {
    font-size: 9px;
}

body.classic-lobby .btn-add-balance {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(145deg, #44c65a, #228d38);
    box-shadow: 0 5px 15px rgba(25, 137, 52, 0.28);
}

body.classic-lobby .content-area {
    padding: 0 0 calc(63px + env(safe-area-inset-bottom));
    background:
        linear-gradient(rgba(28, 11, 59, 0.36), rgba(14, 6, 29, 0.5)),
        repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.012) 0 2px, transparent 2px 7px);
}

body.classic-lobby .tables-topbar {
    min-height: 54px;
    padding: 11px 11px 8px;
}

body.classic-lobby .tables-title,
body.classic-lobby .shop-header,
body.classic-lobby .tab-header,
body.classic-lobby .section-header h2 {
    color: #fff;
    font-size: 18px;
    font-weight: 900;
    letter-spacing: -0.02em;
}

body.classic-lobby .tables-topbar-btns {
    gap: 5px;
}

body.classic-lobby .btn-destek,
body.classic-lobby .btn-emek,
body.classic-lobby .btn-yeni-otaq {
    min-height: 29px;
    padding: 5px 8px;
    color: #fff;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.025em;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}

body.classic-lobby .btn-destek {
    background: #2b2350;
    border-color: rgba(255, 255, 255, 0.1);
}

body.classic-lobby .btn-emek {
    background: linear-gradient(#ee6b19, #cd4e0f);
}

body.classic-lobby .btn-yeni-otaq {
    background: linear-gradient(#2fb458, #208b3f);
}

body.classic-lobby .search-wrap {
    padding: 0 11px 9px;
}

body.classic-lobby .search-wrap input {
    height: 38px;
    padding: 0 13px;
    color: #fff;
    font-size: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    background: rgba(6, 2, 14, 0.4);
}

body.classic-lobby .search-wrap input:focus {
    border-color: rgba(250, 200, 0, 0.38);
    box-shadow: 0 0 0 3px rgba(250, 200, 0, 0.06);
}

body.classic-lobby .bot-banner {
    min-height: 57px;
    margin: 0 11px 10px;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    background:
        linear-gradient(100deg, rgba(99, 38, 171, 0.95), rgba(61, 27, 125, 0.96)),
        #3b1b75;
    box-shadow: 0 9px 24px rgba(5, 0, 16, 0.25);
}

body.classic-lobby .bot-banner-text {
    font-size: 12px;
    font-weight: 800;
}

body.classic-lobby .bot-banner-sub {
    color: rgba(255, 255, 255, 0.58);
    font-size: 9px;
}

body.classic-lobby .bot-banner-btn {
    padding: 6px 11px;
    color: #1b1006;
    font-size: 10px;
    background: linear-gradient(100deg, #f6d520, #ec781a);
}

body.classic-lobby .tables-list {
    gap: 8px;
    padding: 0 11px 14px;
}

body.classic-lobby .table-item {
    min-height: 69px;
    margin: 0;
    padding: 11px 10px;
    grid-template-columns: 1.35fr 0.78fr 0.78fr 0.78fr;
    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 10px;
    background:
        linear-gradient(105deg, rgba(65, 27, 128, 0.96), rgba(34, 13, 74, 0.98)),
        #2e135d;
    box-shadow: 0 6px 17px rgba(2, 0, 9, 0.25);
}

body.classic-lobby .table-item:hover {
    background: linear-gradient(105deg, rgba(76, 33, 145, 0.98), rgba(41, 16, 87, 0.99));
    border-color: rgba(250, 200, 0, 0.18);
}

body.classic-lobby .table-item::before {
    left: 40%;
    color: rgba(255, 255, 255, 0.025);
    font-size: 46px;
}

body.classic-lobby .table-item .t-name {
    max-width: 120px;
    overflow: hidden;
    font-size: 11px;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.classic-lobby .table-item .t-id {
    color: rgba(255, 255, 255, 0.42);
    font-size: 9px;
}

body.classic-lobby .table-item .t-lbl {
    min-height: 20px;
    color: rgba(255, 255, 255, 0.43);
    font-size: 7px;
    line-height: 1.25;
    letter-spacing: 0.025em;
}

body.classic-lobby .table-item .t-val {
    font-size: 11px;
}

body.classic-lobby .table-item .t-val.orange {
    color: #ffb01d;
}

body.classic-lobby .empty-state {
    padding: 55px 18px;
}

body.classic-lobby .shop-header,
body.classic-lobby .tab-header,
body.classic-lobby .section-header {
    padding: 14px 12px 10px;
}

body.classic-lobby .shop-grid {
    gap: 8px;
    padding: 0 11px 14px;
}

body.classic-lobby .shop-item,
body.classic-lobby .chat-room-item,
body.classic-lobby .stat-card,
body.classic-lobby .profile-top {
    border-color: rgba(255, 255, 255, 0.075);
    background: linear-gradient(145deg, rgba(48, 23, 91, 0.88), rgba(28, 12, 56, 0.92));
    box-shadow: 0 6px 18px rgba(2, 0, 9, 0.18);
}

body.classic-lobby .shop-item {
    padding: 13px 9px;
    border-radius: 10px;
}

body.classic-lobby .shop-item .icon {
    font-size: 26px;
}

body.classic-lobby .shop-item .title {
    font-size: 11px;
}

body.classic-lobby .shop-item .price {
    color: #fbd836;
    font-size: 13px;
}

body.classic-lobby .btn-buy,
body.classic-lobby .btn-submit-wallet {
    background: linear-gradient(105deg, #f4cf1c, #ed7419);
    color: #1b1008;
    font-weight: 900;
}

body.classic-lobby .messages-list {
    padding: 0 11px 14px;
}

body.classic-lobby .chat-room-item {
    border-radius: 9px;
}

body.classic-lobby .profile-top {
    margin: 11px;
    padding: 17px 14px;
}

body.classic-lobby .profile-avatar {
    background: linear-gradient(145deg, #6e34bd, #3c1b79);
    border: 2px solid rgba(250, 200, 0, 0.22);
}

body.classic-lobby .profile-balance-big {
    color: #fbd83d;
}

body.classic-lobby .wallet-actions,
body.classic-lobby .stats-row {
    gap: 8px;
    margin: 11px;
}

body.classic-lobby .form-control,
body.classic-lobby .chat-input {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.09);
    background: rgba(5, 2, 12, 0.44);
}

body.classic-lobby .form-control:focus,
body.classic-lobby .chat-input:focus {
    border-color: rgba(250, 200, 0, 0.42);
}

body.classic-lobby .bottom-nav {
    height: calc(61px + env(safe-area-inset-bottom));
    padding-bottom: env(safe-area-inset-bottom);
    background: rgba(18, 7, 39, 0.97);
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    box-shadow: 0 -8px 25px rgba(3, 0, 10, 0.25);
}

body.classic-lobby .nav-item {
    position: relative;
}

body.classic-lobby .nav-item::before {
    position: absolute;
    top: 0;
    left: 50%;
    width: 27px;
    height: 2px;
    content: "";
    opacity: 0;
    transform: translateX(-50%);
    background: linear-gradient(90deg, #fac800, #f07918);
    border-radius: 0 0 3px 3px;
}

body.classic-lobby .nav-item .nav-icon {
    font-size: 18px;
    opacity: 0.55;
    filter: grayscale(0.55);
}

body.classic-lobby .nav-item .nav-label {
    color: rgba(255, 255, 255, 0.42);
    font-size: 7px;
    letter-spacing: 0.045em;
}

body.classic-lobby .nav-item.active::before {
    opacity: 1;
}

body.classic-lobby .nav-item.active .nav-icon {
    opacity: 1;
    filter: none;
}

body.classic-lobby .nav-item.active .nav-label {
    color: #fbd634;
}

body.classic-lobby .modal,
body.classic-lobby .modal-overlay {
    background: rgba(3, 0, 9, 0.82);
    backdrop-filter: blur(5px);
}

body.classic-lobby .modal-content {
    max-width: 384px;
    color: #fff;
    background: linear-gradient(180deg, #241047, #130827);
    border: 1px solid rgba(250, 200, 0, 0.12);
    box-shadow: 0 -14px 45px rgba(1, 0, 5, 0.45);
}

body.classic-lobby .modal-header {
    border-bottom-color: rgba(255, 255, 255, 0.075);
}

body.classic-lobby .close-modal,
body.classic-lobby .modal-close {
    color: rgba(255, 255, 255, 0.68);
    background: rgba(255, 255, 255, 0.065);
}

@media (min-width: 620px) {
    body.classic-lobby {
        padding: 16px;
    }

    body.classic-lobby .app-container {
        height: min(696px, calc(100dvh - 32px));
        border: 1px solid rgba(255, 255, 255, 0.075);
        border-radius: 21px;
    }

    body.classic-lobby .bottom-nav {
        border-radius: 0 0 20px 20px;
    }

    body.classic-lobby .modal-content {
        border-radius: 20px;
    }
}

@media (max-width: 380px) {
    body.classic-auth .form-area {
        padding-inline: 18px;
    }

    body.classic-lobby .btn-destek,
    body.classic-lobby .btn-emek,
    body.classic-lobby .btn-yeni-otaq {
        padding-inline: 6px;
        font-size: 8px;
    }

    body.classic-lobby .header-logo .logo-text {
        font-size: 12px;
    }
}

@media (max-height: 700px) {
    body.classic-auth {
        place-items: start center;
        overflow-y: auto;
    }

    body.classic-auth .page {
        margin-block: 4px;
    }

    body.classic-auth .form-area {
        padding-top: 19px;
        padding-bottom: 20px;
    }

    body.classic-auth .classic-brand {
        margin-bottom: 18px;
    }

    body.classic-auth .classic-auth-tabs {
        margin-bottom: 17px;
    }

    body.classic-auth form {
        gap: 11px;
    }

    body.classic-auth .field input {
        height: 47px;
    }

    body.classic-auth .support-btn {
        position: absolute;
    }
}

@media (prefers-reduced-motion: reduce) {
    body.classic-auth *,
    body.classic-lobby * {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

/*
 * Exact legacy-style public authentication screens. This block is kept last
 * so it can override the original inline styles without touching auth logic.
 */
body.classic-auth {
    min-height: 100dvh;
    display: flex;
    align-items: stretch;
    justify-content: center;
    padding: 0;
    overflow: hidden;
    background:
        radial-gradient(circle at 48% -12%, rgba(58, 15, 96, 0.46), transparent 48%),
        linear-gradient(180deg, var(--tc-public-surface, #1a0430) 0%, var(--tc-public-bg, #140025) 48%, #120021 100%);
}

body.classic-auth::before {
    opacity: 0.16;
}

body.classic-auth .page {
    width: 100%;
    max-width: 384px;
    min-height: 100dvh;
    display: flex;
    padding: 0 29px;
    margin: 0;
    overflow: visible;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

body.classic-auth .page::before {
    display: none;
}

body.classic-auth .form-area {
    width: 100%;
    padding: 0;
}

body.classic-auth-login .form-area {
    display: flex;
    justify-content: center;
    padding-top: 18px;
    padding-bottom: 0;
}

body.classic-auth-register {
    overflow-y: auto;
}

body.classic-auth-register .form-area {
    display: block;
    padding-top: 120px;
    padding-bottom: 70px;
}

body.classic-auth h1 {
    position: static;
    width: auto;
    height: auto;
    padding: 0;
    margin: 0 0 41px;
    overflow: visible;
    clip: auto;
    color: #fff;
    font-size: 26px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.35px;
    white-space: normal;
}

body.classic-auth-register h1 {
    margin-bottom: 39px;
}

body.classic-auth form {
    display: block;
}

body.classic-auth .field {
    margin: 0 0 23px;
}

body.classic-auth-register .field {
    margin-bottom: 17px;
}

body.classic-auth .field label {
    margin: 0 0 9px 4px;
    color: rgba(255, 255, 255, 0.93);
    font-size: 15px;
    font-weight: 600;
}

body.classic-auth .input-wrap::before {
    display: none;
}

body.classic-auth .field input {
    width: 100%;
    height: 38px;
    padding: 0 42px 0 7px;
    color: #fff;
    font-size: 15px;
    background: rgba(8, 0, 20, 0.22);
    border: 0;
    border-radius: 0;
    box-shadow: inset 0 -1px rgba(255, 255, 255, 0.015);
}

body.classic-auth .field input::placeholder {
    color: rgba(255, 255, 255, 0.48);
}

body.classic-auth .field input:focus {
    background: rgba(8, 0, 20, 0.34);
    border: 0;
    box-shadow: inset 0 -1px rgba(34, 139, 230, 0.85);
}

body.classic-auth .eye-btn {
    right: 9px;
    width: 28px;
    height: 28px;
    color: #fff;
    font-size: 17px;
}

body.classic-auth .btn-login,
body.classic-auth .btn-register {
    width: 100%;
    height: 33px;
    margin-top: 8px;
    border: 0;
    border-radius: 0;
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0;
    box-shadow: none;
}

body.classic-auth .btn-login {
    background: var(--tc-public-primary, #1877e6);
}

body.classic-auth .btn-register {
    margin-top: 0;
    background: var(--tc-public-success, #35a63c);
    text-transform: none;
}

body.classic-auth .links {
    margin-top: 20px;
    text-align: center;
}

body.classic-auth .links p,
body.classic-auth .links .forgot {
    color: rgba(255, 255, 255, 0.69);
    font-size: 14px;
}

body.classic-auth .links p {
    margin-bottom: 21px;
}

body.classic-auth .links a {
    color: #168ed0;
    font-weight: 700;
}

body.classic-auth .support-btn {
    position: fixed;
    right: max(15px, calc((100vw - 384px) / 2 + 15px));
    bottom: max(15px, env(safe-area-inset-bottom));
    min-width: 88px;
    height: 25px;
    padding: 0 12px;
    color: #fff;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    background: var(--tc-public-success, #20a84b);
    border: 0;
    border-radius: 2px;
    box-shadow: none;
}

body.classic-auth .alert {
    margin: -21px 0 16px;
    padding: 9px 11px;
    border-radius: 2px;
}

@media (max-height: 620px) {
    body.classic-auth-register .form-area {
        padding-top: 54px;
    }

    body.classic-auth-login .form-area {
        padding-top: 48px;
        padding-bottom: 72px;
    }
}

/* Exact compact legacy lobby proportions from the 384 × 696 reference. */
body.classic-lobby {
    background: #08040f;
}

body.classic-lobby::before {
    display: none;
}

body.classic-lobby .app-container {
    --bg: var(--tc-public-bg, #160029);
    --surface: var(--tc-public-surface, #3b126d);
    --surface2: #381068;
    --surface3: #42147a;
    --amber: #ee8b19;
    width: 100%;
    max-width: 384px;
    height: 100dvh;
    color: #fff;
    background:
        radial-gradient(circle at 45% -20%, rgba(89, 34, 137, .36), transparent 47%),
        linear-gradient(180deg, var(--tc-public-bg, #1d0738) 0%, #160028 100%);
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

body.classic-lobby .app-container > header {
    min-height: 47px;
    height: 47px;
    padding: 6px 15px;
    background: rgba(42, 12, 71, .42);
    border: 0;
    box-shadow: none;
}

body.classic-lobby .header-logo {
    gap: 5px;
}

body.classic-lobby .header-logo .logo-icon {
    width: 17px;
    height: 17px;
    color: #fff;
    font-size: 13px;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
}

body.classic-lobby .header-logo .logo-text {
    font-size: 9px;
    line-height: .85;
    letter-spacing: .04em;
}

body.classic-lobby .header-logo .logo-text span {
    display: block;
    margin-top: 3px;
    color: rgba(255,255,255,.82);
    font-size: 7px;
    letter-spacing: .03em;
}

body.classic-lobby .balance-pill {
    min-height: 28px;
    padding: 4px 8px;
    color: #ffd43b;
    font-size: 13px;
    background: transparent;
    border: 0;
    border-radius: 0;
}

body.classic-lobby .btn-add-balance {
    width: 33px;
    height: 33px;
    color: #fff;
    font-size: 23px;
    border-radius: 8px;
    background: #35ac4e;
    box-shadow: 0 2px 4px rgba(0,0,0,.22);
}

body.classic-lobby .content-area {
    padding-bottom: calc(55px + env(safe-area-inset-bottom));
    background: transparent;
}

body.classic-lobby .tables-topbar {
    min-height: 74px;
    display: flex;
    flex-direction: column-reverse;
    align-items: stretch;
    gap: 24px;
    padding: 8px 14px 0;
}

body.classic-lobby .tables-title {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0;
}

body.classic-lobby .tables-topbar-btns {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

body.classic-lobby .btn-yeni-versiya,
body.classic-lobby .btn-destek,
body.classic-lobby .btn-emek,
body.classic-lobby .btn-yeni-otaq {
    min-width: 0;
    min-height: 26px;
    height: 26px;
    padding: 0 4px;
    color: #fff;
    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0;
    white-space: nowrap;
    border: 0;
    border-radius: 2px;
    box-shadow: none;
}

body.classic-lobby .btn-yeni-versiya,
body.classic-lobby .btn-destek {
    background: #292144;
}

body.classic-lobby .btn-emek {
    background: #df6e23;
}

body.classic-lobby .btn-yeni-otaq {
    background: #2cab4e;
}

body.classic-lobby .search-wrap {
    padding: 5px 14px 18px;
}

body.classic-lobby .search-wrap input {
    height: 28px;
    padding: 0 14px;
    color: #fff;
    font-size: 12px;
    background: rgba(29, 9, 51, .66);
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

body.classic-lobby .bot-banner {
    display: none !important;
}

body.classic-lobby .tables-list {
    gap: 7px;
    padding: 0 14px 12px;
}

body.classic-lobby .table-item {
    min-height: 59px;
    padding: 8px 28px;
    grid-template-columns: 1.18fr .95fr .95fr .95fr;
    column-gap: 4px;
    color: #fff;
    background:
        linear-gradient(100deg, rgba(65, 17, 125, .96), rgba(52, 12, 104, .97)),
        #3e1174;
    border: 0;
    border-radius: 0;
    box-shadow: 0 3px 4px rgba(0,0,0,.22);
}

body.classic-lobby .table-item:hover {
    background: linear-gradient(100deg, #48158a, #3a0d73);
    border: 0;
}

body.classic-lobby .table-item::before {
    left: 48%;
    color: rgba(255,255,255,.035);
    font-size: 45px;
}

body.classic-lobby .table-item .t-name,
body.classic-lobby .table-item .t-val {
    color: #fff;
    font-size: 10px;
}

body.classic-lobby .table-item .t-id,
body.classic-lobby .table-item .t-lbl {
    color: rgba(255,255,255,.88);
    font-size: 7px;
    letter-spacing: 0;
    white-space: nowrap;
}

body.classic-lobby .table-item .t-val.orange {
    color: #ef9420;
}

body.classic-lobby .bottom-nav {
    height: calc(55px + env(safe-area-inset-bottom));
    background: rgba(40, 15, 65, .97);
    border-top: 1px solid rgba(255,255,255,.035);
    box-shadow: none;
}

body.classic-lobby .nav-item::before {
    display: none;
}

body.classic-lobby .nav-item .nav-icon {
    font-size: 16px;
    opacity: .66;
    filter: grayscale(.8);
}

body.classic-lobby .nav-item .nav-label {
    color: rgba(255,255,255,.63);
    font-size: 10px;
    letter-spacing: 0;
    text-transform: none;
}

body.classic-lobby .nav-item.active .nav-icon {
    opacity: 1;
    filter: none;
}

body.classic-lobby .nav-item.active .nav-label {
    color: #fff;
}

@media (min-width: 620px) {
    body.classic-lobby .app-container,
    body.classic-lobby .bottom-nav {
        border-radius: 0;
    }
}

/*
 * Compact legacy buy-in sheet. The reference shell stays 384 px wide and
 * uses squared controls; do not let desktop media queries turn this into a
 * floating, rounded modern card.
 */
body.classic-lobby #buyInModal {
    align-items: flex-end;
    background: rgba(3, 0, 9, .84);
    backdrop-filter: none;
}

body.classic-lobby #buyInModal .modal-content {
    width: 100%;
    max-width: 384px !important;
    padding: 0 0 12px;
    border: 1px solid rgba(255, 255, 255, .09);
    border-bottom: 0;
    border-radius: 2px 2px 0 0 !important;
    background: linear-gradient(180deg, #2a1050, #17072d);
    box-shadow: 0 -10px 30px rgba(0, 0, 0, .48);
}

body.classic-lobby #buyInModal .modal-header {
    min-height: 42px;
    padding: 8px 14px;
}

body.classic-lobby #buyInModal .modal-header h3 {
    font-size: 13px;
    font-weight: 800;
}

body.classic-lobby #buyInModal .close-modal {
    width: 24px;
    height: 24px;
    border-radius: 2px;
    font-size: 16px;
}

body.classic-lobby #buyInModal form {
    padding: 12px 14px !important;
}

body.classic-lobby #buyInModal form > div:first-of-type {
    margin-bottom: 12px !important;
}

body.classic-lobby #buyInModal .form-group {
    margin-bottom: 9px;
}

body.classic-lobby #buyInModal .form-group label {
    margin-bottom: 4px;
    font-size: 10px;
}

body.classic-lobby #buyInModal .form-control {
    height: 34px;
    padding: 0 10px;
    border-radius: 0;
    font-size: 12px;
}

body.classic-lobby #buyInModal .btn-buy {
    height: 28px;
    padding: 0;
    border-radius: 2px;
    font-size: 10px;
}

body.classic-lobby #buyInModal .btn-submit-wallet {
    height: 40px;
    margin-bottom: 6px;
    border-radius: 2px;
    font-size: 12px;
}

/* Legacy styling for wallet, store, applications and profile screens. */
body.classic-lobby .tab-view:not(#view-tables) {
    min-height: 100%;
    background: transparent;
}

body.classic-lobby .tab-view:not(#view-tables) .section-header,
body.classic-lobby .tab-view:not(#view-tables) .tab-header {
    min-height: 45px;
    padding: 16px 14px 9px;
    border: 0;
}

body.classic-lobby .tab-view:not(#view-tables) .section-header h2,
body.classic-lobby .tab-view:not(#view-tables) .tab-header {
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0;
}

body.classic-lobby #view-shop .shop-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
    padding: 0 14px 14px;
}

body.classic-lobby #view-shop .shop-item {
    min-height: 148px;
    padding: 12px 8px;
    gap: 6px;
    border: 0;
    border-radius: 0;
    background: linear-gradient(105deg, #42147a, #321064);
    box-shadow: 0 3px 4px rgba(0, 0, 0, .22);
}

body.classic-lobby #view-shop .shop-item img {
    width: 56px !important;
    height: 56px !important;
    border-radius: 0 !important;
}

body.classic-lobby #view-shop .shop-item .icon {
    border-radius: 0;
}

body.classic-lobby #view-shop .shop-item .title {
    font-size: 10px;
}

body.classic-lobby #view-shop .shop-item .price {
    color: #ef9420;
    font-size: 11px;
}

body.classic-lobby #view-shop .btn-buy {
    min-height: 29px;
    padding: 0 8px;
    border-radius: 2px;
    font-size: 10px;
}

body.classic-lobby #view-rating #rating-list {
    gap: 4px !important;
}

body.classic-lobby #view-rating .rating-row {
    min-height: 44px;
    display: grid;
    grid-template-columns: 28px 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    padding: 5px 9px;
    color: #fff;
    background: linear-gradient(105deg, #42147a, #321064);
    box-shadow: 0 2px 3px rgba(0, 0, 0, .2);
}

body.classic-lobby #view-rating .rating-rank {
    color: #ef9420;
    font-size: 13px;
    font-weight: 900;
    text-align: center;
}

body.classic-lobby #view-rating .rating-avatar {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    object-fit: cover;
    border-radius: 0;
    background: #24103f;
}

body.classic-lobby #view-rating .rating-user {
    min-width: 0;
    overflow: hidden;
    font-size: 11px;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.classic-lobby #view-rating .rating-score {
    color: #d7cbe8;
    font-size: 9px;
    font-weight: 700;
}

body.classic-lobby #view-rating .rating-empty {
    padding: 36px 10px;
    color: #b6a7ca;
    font-size: 11px;
    text-align: center;
}

body.classic-lobby #view-messages > .section-header + div {
    margin: 0 14px 12px !important;
    padding: 14px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: linear-gradient(105deg, #42147a, #321064) !important;
    box-shadow: 0 3px 4px rgba(0, 0, 0, .22) !important;
}

body.classic-lobby #view-messages > .section-header + div button {
    height: 34px !important;
    border-radius: 2px !important;
    box-shadow: none !important;
    font-size: 10px !important;
}

body.classic-lobby #view-messages .messages-list,
body.classic-lobby #view-dostlar .messages-list {
    padding: 0 14px 14px;
}

body.classic-lobby #view-dostlar > .form-group {
    margin: 0 14px 8px;
}

body.classic-lobby #view-dostlar > .form-group .form-control {
    height: 35px;
    border-radius: 0;
    font-size: 11px;
}

body.classic-lobby #view-messages .chat-room-item,
body.classic-lobby #view-dostlar .chat-room-item {
    border: 0;
    border-radius: 0;
    background: #3e1174;
    box-shadow: none;
}

body.classic-lobby #view-profile .profile-page-header {
    display: block;
}

body.classic-lobby #view-profile .wallet-page-header {
    display: none;
    min-height: 45px;
    padding: 8px 14px;
    align-items: center;
    gap: 10px;
}

body.classic-lobby #view-profile .wallet-page-header button {
    width: 28px;
    height: 28px;
    padding: 0;
    color: #fff;
    font: 300 32px/24px Arial, sans-serif;
    border: 0;
    border-radius: 0;
    background: transparent;
}

body.classic-lobby #view-profile .wallet-page-header h2 {
    font-size: 13px;
    font-weight: 800;
}

body.classic-lobby #view-profile .profile-header {
    margin: 0 14px 10px;
    padding: 13px 12px !important;
    gap: 7px !important;
    border: 0;
    border-radius: 0;
    background: linear-gradient(105deg, #42147a, #321064);
    box-shadow: 0 3px 4px rgba(0, 0, 0, .22);
}

body.classic-lobby #view-profile .profile-avatar {
    width: 54px !important;
    height: 54px !important;
    border-radius: 0 !important;
}

body.classic-lobby #view-profile #username-input {
    height: 32px !important;
    padding: 0 9px !important;
    border-radius: 0 !important;
    font-size: 11px !important;
}

body.classic-lobby #view-profile .profile-header .btn-buy {
    height: 32px;
    padding: 0 9px !important;
    border-radius: 2px !important;
    font-size: 9px !important;
}

body.classic-lobby #view-profile .wallet-actions {
    margin: 0 14px 8px;
    gap: 6px;
}

body.classic-lobby #view-profile .btn-wallet {
    height: 34px;
    border-radius: 2px;
    font-size: 10px;
    box-shadow: none;
    filter: saturate(.55) brightness(.76);
}

body.classic-lobby #view-profile .btn-wallet.wallet-tab-active {
    filter: none;
    outline: 1px solid rgba(255, 255, 255, .38);
    outline-offset: -1px;
}

body.classic-lobby #view-profile .wallet-form {
    margin: 0 14px 10px;
    padding: 13px;
    border: 0;
    border-radius: 0;
    background: linear-gradient(105deg, #42147a, #321064);
    box-shadow: 0 3px 4px rgba(0, 0, 0, .22);
}

body.classic-lobby #view-profile .wallet-form h3 {
    margin-bottom: 10px;
    font-size: 12px;
}

body.classic-lobby #view-profile .wallet-form .form-group {
    margin-bottom: 9px;
}

body.classic-lobby #view-profile .wallet-form label {
    margin-bottom: 4px;
    font-size: 9px;
}

body.classic-lobby #view-profile .wallet-form .form-control {
    height: 35px;
    padding: 0 9px;
    border-radius: 0;
    font-size: 11px;
}

body.classic-lobby #view-profile #deposit-method-instructions,
body.classic-lobby #view-profile #withdraw-method-instructions {
    margin-bottom: 10px !important;
    padding: 9px !important;
    border-radius: 0 !important;
    font-size: 10px !important;
    line-height: 1.45 !important;
}

body.classic-lobby #view-profile .wallet-form .btn-submit-wallet {
    height: 38px;
    margin: 4px 0 0;
    border-radius: 2px;
    font-size: 10px;
}

body.classic-lobby #view-profile .stats-row {
    margin: 8px 14px;
    gap: 7px;
}

body.classic-lobby #view-profile .stat-card {
    padding: 11px;
    border: 0;
    border-radius: 0;
    background: #3e1174;
    box-shadow: none;
}

body.classic-lobby #view-profile .stats-row .btn-buy {
    min-height: 28px;
    padding: 0 9px !important;
    border-radius: 2px !important;
    font-size: 9px !important;
}

body.classic-lobby #view-profile .stats-row img {
    border-radius: 0 !important;
}

body.classic-lobby #view-profile.wallet-focus .profile-page-header,
body.classic-lobby #view-profile.wallet-focus .profile-header,
body.classic-lobby #view-profile.wallet-focus .stats-row,
body.classic-lobby #view-profile.wallet-focus .logout-form {
    display: none !important;
}

body.classic-lobby #view-profile.wallet-focus .wallet-page-header {
    display: flex;
}

body.classic-lobby #view-profile.wallet-focus .wallet-actions {
    margin-top: 0;
}
