/**
 * TikAff User Console — sidebar layout (giống Admin Console)
 */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --usr-sidebar-w: 264px;
    --usr-sidebar-bg: #0f172a;
    --usr-sidebar-text: #cbd5e1;
    --usr-sidebar-muted: #64748b;
    --usr-sidebar-hover: rgba(255, 255, 255, 0.06);
    --usr-bg: #f1f5f9;
    --usr-surface: #ffffff;
    --usr-border: #e2e8f0;
    --usr-text: #0f172a;
    --usr-muted: #64748b;
    --usr-primary: #4f46e5;
    --usr-primary-2: #7c3aed;
    --usr-radius: 16px;
    --usr-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 10px 28px rgba(15, 23, 42, 0.06);
    --usr-topbar-h: 58px;
    --usr-font: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --usr-safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ========== Canvas (khi có sidebar shell) ========== */
html.user-app body.usr-shell,
body.usr-shell {
    font-family: var(--usr-font) !important;
    background: var(--usr-bg) !important;
    background-image: none !important;
    color: var(--usr-text);
    margin: 0 !important;
    padding: 0 !important;
    min-height: 100vh !important;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body.usr-drawer-open {
    overflow: hidden;
}

/* ========== Sidebar ========== */
.usr-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1200;
    width: var(--usr-sidebar-w);
    height: 100vh;
    height: 100dvh;
    background: linear-gradient(180deg, #0f172a 0%, #111827 55%, #0b1220 100%);
    color: var(--usr-sidebar-text);
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255, 255, 255, 0.06);
    transition: transform 0.25s ease;
}

.usr-sidebar__brand {
    flex-shrink: 0;
    padding: 1rem 1.1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    min-height: var(--usr-topbar-h);
    display: flex;
    align-items: center;
}

.usr-sidebar__brand-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: inherit;
    min-width: 0;
    width: 100%;
}

.usr-sidebar__brand-mark {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed 55%, #06b6d4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 800;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 8px 18px rgba(79, 70, 229, 0.35);
}

.usr-sidebar__brand-mark img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.usr-sidebar__brand-text {
    min-width: 0;
    line-height: 1.2;
}

.usr-sidebar__brand-text strong {
    display: block;
    color: #f8fafc;
    font-size: 0.95rem;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.usr-sidebar__brand-text span {
    display: block;
    color: var(--usr-sidebar-muted);
    font-size: 0.72rem;
    margin-top: 2px;
}

.usr-sidebar__nav {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0.85rem 0.75rem 1rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(148, 163, 184, 0.35) transparent;
}

.usr-nav-group {
    margin-bottom: 1rem;
}

.usr-nav-group__label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--usr-sidebar-muted);
    padding: 0.35rem 0.7rem 0.5rem;
}

.usr-nav-link {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.65rem 0.75rem;
    margin-bottom: 2px;
    border-radius: 10px;
    color: var(--usr-sidebar-text);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: background 0.15s ease, color 0.15s ease;
}

.usr-nav-link i {
    width: 1.25rem;
    text-align: center;
    font-size: 0.95rem;
    opacity: 0.92;
    flex-shrink: 0;
}

.usr-nav-link:hover {
    background: var(--usr-sidebar-hover);
    color: #fff;
}

.usr-nav-link.is-active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), rgba(139, 92, 246, 0.18));
    color: #fff;
    box-shadow: inset 0 0 0 1px rgba(129, 140, 248, 0.35);
}

.usr-nav-link.is-active i {
    color: #a5b4fc;
}

.usr-nav-link--admin {
    background: rgba(249, 115, 22, 0.12);
    color: #fdba74;
}
.usr-nav-link--admin:hover {
    background: rgba(249, 115, 22, 0.2);
    color: #ffedd5;
}

.usr-sidebar__footer {
    flex-shrink: 0;
    padding: 0.85rem 0.75rem 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.usr-sidebar__user {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.55rem 0.65rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    margin-bottom: 0.55rem;
}

.usr-sidebar__avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, #334155, #1e293b);
    color: #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    flex-shrink: 0;
}

.usr-sidebar__user-meta {
    min-width: 0;
    flex: 1;
}

.usr-sidebar__user-meta strong {
    display: block;
    color: #f1f5f9;
    font-size: 0.82rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.usr-sidebar__user-meta span {
    display: block;
    color: var(--usr-sidebar-muted);
    font-size: 0.72rem;
}

.usr-sidebar__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.4rem;
}

.usr-sidebar__actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.5rem 0.4rem;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.15s ease;
}

.usr-btn-profile {
    background: rgba(255, 255, 255, 0.08);
    color: #e2e8f0;
}
.usr-btn-profile:hover {
    background: rgba(255, 255, 255, 0.14);
}
.usr-btn-logout {
    background: rgba(220, 38, 38, 0.18);
    color: #fecaca;
}
.usr-btn-logout:hover {
    background: rgba(220, 38, 38, 0.28);
}

.usr-sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    z-index: 1190;
    backdrop-filter: blur(2px);
}

/* ========== Mobile top bar ========== */
.usr-mobile-bar {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1100;
    height: var(--usr-topbar-h);
    background: var(--usr-surface);
    border-bottom: 1px solid var(--usr-border);
    padding: 0 0.85rem;
    align-items: center;
    gap: 0.75rem;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.03);
}

.usr-mobile-bar__menu {
    width: 40px;
    height: 40px;
    border: 1px solid var(--usr-border);
    border-radius: 10px;
    background: #fff;
    color: var(--usr-text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
}

.usr-mobile-bar__title {
    flex: 1;
    font-weight: 800;
    font-size: 0.95rem;
    color: var(--usr-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.usr-mobile-bar__avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.8rem;
    text-decoration: none;
    flex-shrink: 0;
}

/* ========== Content shift ========== */
body.usr-shell .container,
body.usr-shell .converter-wrapper {
    max-width: none !important;
    width: auto !important;
    margin: 0 0 0 var(--usr-sidebar-w) !important;
    padding: 1.15rem 1.35rem 1.75rem !important;
    min-height: 100vh;
    box-sizing: border-box !important;
}

body.usr-shell .container > .card,
body.usr-shell .converter-wrapper .converter-card {
    background: var(--usr-surface) !important;
    border-radius: var(--usr-radius) !important;
    box-shadow: var(--usr-shadow) !important;
    border: 1px solid var(--usr-border) !important;
    padding: 1.2rem 1.35rem 1.5rem !important;
    margin-bottom: 0 !important;
    overflow: hidden;
    position: relative;
}

/* top accent line */
body.usr-shell .container > .card::before,
body.usr-shell .converter-wrapper .converter-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #4f46e5, #06b6d4, #a855f7);
    pointer-events: none;
    z-index: 1;
}

/* Page header strip */
body.usr-shell .container > .card > .header,
body.usr-shell .container .card > .header,
body.usr-shell .converter-wrapper .card-header {
    display: flex !important;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0 0 1.15rem 0 !important;
    padding: 0 0 1rem 0 !important;
    border-bottom: 1px solid var(--usr-border) !important;
    background: transparent !important;
    position: relative !important;
    top: auto !important;
    backdrop-filter: none !important;
}

.usr-page-heading {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    min-width: 0;
}

.usr-page-heading__title {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--usr-text);
    line-height: 1.2;
}

.usr-page-heading__crumb {
    font-size: 0.78rem;
    color: var(--usr-muted);
    font-weight: 500;
}

/* Hide legacy horizontal nav (sidebar replaces it) */
body.usr-shell .nav-buttons,
body.usr-shell .app-nav,
body.usr-shell .header-nav,
body.usr-shell .user-brand,
body.usr-shell .ix-brand {
    display: none !important;
}

/* Titles */
body.usr-shell .container > .card > h2,
body.usr-shell .card > h2,
body.usr-shell .stats-welcome h2,
body.usr-shell .page-title {
    text-align: left !important;
    font-size: 1.2rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em;
    color: var(--usr-text) !important;
    margin: 0 0 0.3rem 0 !important;
}

body.usr-shell .container > .card > h2 + p,
body.usr-shell .page-subtitle,
body.usr-shell .stats-welcome p {
    text-align: left !important;
    color: var(--usr-muted) !important;
    margin: 0 0 1.2rem 0 !important;
    font-size: 0.92rem !important;
}

/* Forms / buttons / tables */
body.usr-shell .btn {
    border-radius: 11px !important;
    font-weight: 700 !important;
}
body.usr-shell .btn-primary {
    background: linear-gradient(135deg, #4f46e5, #6366f1) !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.25);
}

body.usr-shell input[type="text"],
body.usr-shell input[type="email"],
body.usr-shell input[type="password"],
body.usr-shell input[type="number"],
body.usr-shell input[type="url"],
body.usr-shell input[type="tel"],
body.usr-shell input[type="search"],
body.usr-shell select,
body.usr-shell textarea {
    border-radius: 11px !important;
    border: 1.5px solid var(--usr-border) !important;
}
body.usr-shell input:focus,
body.usr-shell select:focus,
body.usr-shell textarea:focus {
    outline: none !important;
    border-color: #818cf8 !important;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15) !important;
}

body.usr-shell .form-section,
body.usr-shell .info-section {
    background: #f8fafc !important;
    border: 1px solid var(--usr-border) !important;
    border-radius: 14px !important;
    padding: 1.15rem !important;
}

body.usr-shell .table-container {
    overflow-x: auto;
    border: 1px solid var(--usr-border) !important;
    border-radius: 14px !important;
    background: #fff;
    box-shadow: var(--usr-shadow);
}

body.usr-shell th {
    background: #f8fafc !important;
    color: var(--usr-muted) !important;
    font-size: 0.72rem !important;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-weight: 700 !important;
}

/* Pricing / stats extras */
body.usr-shell .plans-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)) !important;
    gap: 1.1rem !important;
}
body.usr-shell .plan-card {
    border-radius: 16px !important;
    border: 1px solid var(--usr-border) !important;
    box-shadow: var(--usr-shadow) !important;
}
body.usr-shell .plan-card.popular {
    border: 2px solid #4f46e5 !important;
    transform: none !important;
}
body.usr-shell .duration-tabs {
    background: #eef2ff !important;
    border-radius: 999px !important;
    border: 1px solid #e0e7ff !important;
}
body.usr-shell .duration-tab.active {
    background: #fff !important;
    color: #4f46e5 !important;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.12) !important;
}

body.usr-shell .stats-grid {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) !important;
    gap: 0.9rem !important;
}
body.usr-shell .stat-card {
    border-radius: 14px !important;
    border: 1px solid var(--usr-border) !important;
    box-shadow: var(--usr-shadow) !important;
}

body.usr-shell .profile-container {
    display: grid;
    grid-template-columns: 1.15fr 0.9fr;
    gap: 1rem;
}

body.usr-shell .site-footer {
    margin-left: var(--usr-sidebar-w) !important;
    color: var(--usr-muted) !important;
    text-align: center;
    padding: 1rem !important;
    background: transparent !important;
}

body.usr-shell .affreel-promo-modal-overlay {
    display: none !important;
}

/* Index converter specifics under shell */
body.usr-shell.index-app .converter-wrapper,
body.index-app.usr-shell .converter-wrapper {
    margin-left: var(--usr-sidebar-w) !important;
    padding: 1.15rem 1.35rem 1.75rem !important;
    max-width: none !important;
}

/* Không dùng card lồng nhau — form nằm trực tiếp trong converter-card */
body.usr-shell .premium-converter-card {
    border: none !important;
    box-shadow: none !important;
    background: transparent !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
}
body.usr-shell .premium-converter-card::before {
    display: none !important;
    content: none !important;
}

body.usr-shell .bulk-tab-bar {
    background: #eef2ff !important;
    border-radius: 12px !important;
    border: 1px solid #e0e7ff !important;
}

body.usr-shell .btn-convert-premium,
body.usr-shell #submit-btn,
body.usr-shell #bulk-submit-btn {
    border-radius: 12px !important;
    background: linear-gradient(135deg, #4f46e5, #7c3aed 50%, #2563eb) !important;
    box-shadow: 0 10px 24px rgba(79, 70, 229, 0.3) !important;
    font-weight: 800 !important;
}

/* ===== History search: 1 ô duy nhất (không double border) ===== */
body.usr-shell .history-search-container,
.history-search-container {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    flex: 1 1 auto;
    justify-content: flex-end;
    min-width: 0;
}

body.usr-shell .history-status-select,
.history-status-select {
    height: 40px;
    min-width: 140px;
    max-width: 100%;
    padding: 0 0.75rem !important;
    border: 1.5px solid var(--usr-border, #e2e8f0) !important;
    border-radius: 10px !important;
    background: #fff !important;
    font-size: 0.85rem !important;
    font-weight: 600;
    color: #334155;
    box-shadow: none !important;
}

/* Một khung search: icon + input + clear + nút Tìm */
body.usr-shell .history-search-box,
.history-search-box {
    display: flex;
    align-items: center;
    height: 40px;
    width: 100%;
    max-width: 320px;
    background: #fff;
    border: 1.5px solid var(--usr-border, #e2e8f0);
    border-radius: 10px;
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

body.usr-shell .history-search-box:focus-within,
.history-search-box:focus-within {
    border-color: #818cf8;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.14);
}

body.usr-shell .history-search-box__icon,
.history-search-box__icon {
    flex-shrink: 0;
    padding: 0 0 0 0.75rem;
    color: #94a3b8;
    font-size: 0.85rem;
}

/* Input bên trong KHÔNG có border riêng */
body.usr-shell .history-search-box__input,
.history-search-box__input,
body.usr-shell .history-search-box input[type="text"],
.history-search-box input[type="text"] {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    height: 100% !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    padding: 0 0.5rem !important;
    font-size: 0.9rem !important;
    outline: none !important;
}

body.usr-shell .history-search-box__clear,
.history-search-box__clear {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    margin-right: 2px;
    border: none;
    background: transparent;
    color: #94a3b8;
    border-radius: 6px;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 0;
}
body.usr-shell .history-search-box__clear:hover,
.history-search-box__clear:hover {
    color: #64748b;
    background: #f1f5f9;
}

body.usr-shell .history-search-box__btn,
.history-search-box__btn {
    flex-shrink: 0;
    height: 100%;
    border: none;
    border-left: 1px solid var(--usr-border, #e2e8f0);
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    color: #fff;
    font-weight: 700;
    font-size: 0.82rem;
    padding: 0 0.9rem;
    cursor: pointer;
    white-space: nowrap;
}
body.usr-shell .history-search-box__btn:hover,
.history-search-box__btn:hover {
    filter: brightness(1.05);
}

/* Legacy wrappers (nếu còn) — gỡ double border */
body.usr-shell .search-input-group,
body.usr-shell .status-filter-container {
    border: 1.5px solid var(--usr-border, #e2e8f0) !important;
    background: #fff !important;
    box-shadow: none !important;
}
body.usr-shell .search-input-group input,
body.usr-shell .status-filter-container select,
body.usr-shell .search-input-group input[type="text"] {
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    outline: none !important;
}

@media (max-width: 768px) {
    body.usr-shell .history-search-container,
    .history-search-container {
        width: 100%;
        justify-content: stretch;
    }
    body.usr-shell .history-status-select,
    .history-status-select {
        width: 100%;
        min-width: 0;
        max-width: none;
    }
    body.usr-shell .history-search-box,
    .history-search-box {
        max-width: none;
        width: 100%;
    }
}

body.usr-shell .ix-auth-gate {
    border-radius: 16px;
    border: 1px solid var(--usr-border);
    background: #fff;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: var(--usr-shadow);
}

/* ========== Responsive ========== */
@media (max-width: 1024px) {
    .usr-sidebar {
        transform: translateX(-105%);
    }
    body.usr-drawer-open .usr-sidebar {
        transform: translateX(0);
        box-shadow: 16px 0 40px rgba(0, 0, 0, 0.3);
    }
    body.usr-drawer-open .usr-sidebar-backdrop {
        display: block;
    }
    .usr-mobile-bar {
        display: flex;
    }

    body.usr-shell .container,
    body.usr-shell .converter-wrapper,
    body.usr-shell.index-app .converter-wrapper,
    body.index-app.usr-shell .converter-wrapper {
        margin-left: 0 !important;
        padding: calc(var(--usr-topbar-h) + 0.75rem) 0.85rem 1.35rem !important;
    }

    body.usr-shell .site-footer {
        margin-left: 0 !important;
    }
}

@media (max-width: 768px) {
    body.usr-shell .container > .card {
        border-radius: 14px !important;
        padding: 1rem 0.9rem 1.15rem !important;
    }

    /* Index — form tạo link: padding gọn trên điện thoại */
    body.usr-shell .converter-wrapper,
    body.usr-shell.index-app .converter-wrapper,
    body.index-app.usr-shell .converter-wrapper {
        padding: calc(var(--usr-topbar-h) + 0.35rem) 0.4rem 0.65rem !important;
    }

    body.usr-shell .converter-wrapper .converter-card {
        border-radius: 12px !important;
        padding: 0.55rem 0.55rem 0.7rem !important;
    }

    body.usr-shell .converter-wrapper .card-header {
        margin-bottom: 0.55rem !important;
        padding-bottom: 0.55rem !important;
    }

    body.usr-shell .converter-wrapper .card-body {
        padding: 0.35rem 0.15rem 0.45rem !important;
    }

    body.usr-shell .premium-converter-card {
        padding: 0 !important;
        border: none !important;
        box-shadow: none !important;
        background: transparent !important;
        border-radius: 0 !important;
    }

    body.usr-shell .bulk-tab-bar {
        margin-bottom: 0.55rem !important;
        padding: 3px !important;
    }

    body.usr-shell .bulk-tab-btn {
        padding: 0.5rem 0.35rem !important;
        font-size: 0.8rem !important;
    }

    body.usr-shell .premium-converter-card .form-group {
        margin-bottom: 0.55rem !important;
    }

    body.usr-shell .premium-converter-card .form-actions {
        margin-top: 0.75rem !important;
    }

    body.usr-shell .premium-converter-card .fb-debug-warning {
        margin-bottom: 0.65rem !important;
        padding: 8px 10px !important;
    }

    body.usr-shell .btn-convert-premium,
    body.usr-shell #submit-btn,
    body.usr-shell #bulk-submit-btn {
        height: 48px !important;
        font-size: 0.9rem !important;
    }

    body.usr-shell #web_link,
    body.usr-shell .bulk-textarea {
        min-height: 72px !important;
        padding: 0.7rem 0.75rem !important;
    }

    body.usr-shell .converter-wrapper #history.card-body,
    body.usr-shell .converter-wrapper .card-body#history {
        padding: 0.55rem 0.25rem 0.65rem !important;
        margin-top: 0.35rem !important;
    }

    body.usr-shell .profile-container {
        grid-template-columns: 1fr;
    }

    body.usr-shell .plans-grid {
        grid-template-columns: 1fr !important;
    }

    body.usr-shell .stats-grid {
        grid-template-columns: 1fr 1fr !important;
    }

    body.usr-shell input,
    body.usr-shell select,
    body.usr-shell textarea {
        font-size: 16px !important;
    }

    body.usr-shell .converter-wrapper .main-content {
        grid-template-columns: 1fr !important;
        gap: 0.65rem !important;
    }

    body.usr-shell .input-with-prefix {
        flex-wrap: wrap !important;
        gap: 6px !important;
        background: transparent !important;
        border: none !important;
        padding: 0 !important;
    }
    body.usr-shell .input-with-prefix > * {
        flex: 1 1 100% !important;
        max-width: 100% !important;
        border-radius: 10px !important;
        border: 1.5px solid var(--usr-border) !important;
        min-height: 44px !important;
    }
}

@media (max-width: 480px) {
    body.usr-shell .stats-grid {
        grid-template-columns: 1fr !important;
    }

    body.usr-shell .converter-wrapper,
    body.usr-shell.index-app .converter-wrapper,
    body.index-app.usr-shell .converter-wrapper {
        padding: calc(var(--usr-topbar-h) + 0.25rem) 0.3rem 0.5rem !important;
    }

    body.usr-shell .converter-wrapper .converter-card {
        padding: 0.45rem 0.4rem 0.55rem !important;
        border-radius: 10px !important;
    }

    body.usr-shell .premium-converter-card {
        padding: 0 !important;
    }
}

/* ========== Auth pages (không có sidebar) ========== */
body.user-app:not(.usr-shell):not(.adm-app):not(.adm-chat-app),
html.user-app body:not(.usr-shell):not(.adm-app):not(.adm-chat-app) {
    font-family: var(--usr-font) !important;
    background:
        radial-gradient(ellipse 900px 500px at 0% -10%, rgba(99, 102, 241, 0.5), transparent 55%),
        radial-gradient(ellipse 700px 420px at 100% 0%, rgba(6, 182, 212, 0.28), transparent 50%),
        linear-gradient(165deg, #1e1b4b 0%, #312e81 40%, #4c1d95 100%) !important;
    background-attachment: fixed !important;
    min-height: 100vh !important;
    margin: 0 !important;
    padding: 1rem !important;
}

body.user-app:not(.usr-shell) .login-container,
body.user-app:not(.usr-shell) .register-container,
html.user-app body:not(.usr-shell) .login-container {
    background: rgba(255, 255, 255, 0.98) !important;
    border-radius: 20px !important;
    box-shadow: 0 16px 48px rgba(15, 23, 42, 0.18) !important;
}

body.user-app:not(.usr-shell) .site-footer {
    color: rgba(255, 255, 255, 0.9) !important;
}
