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

:root {
    /* Color Palette */
    --bg-main: #030712;
    --bg-gradient: radial-gradient(circle at top, #0d1e3d 0%, #030712 60%, #030712 100%);
    --bg-login-gradient: radial-gradient(circle at top, #0ea5e9 0%, #020617 55%, #020617 100%);
    --bg-red-gradient: radial-gradient(circle at top, #b91c1c 0%, #020617 60%, #020617 100%);
    
    --card-bg: rgba(17, 24, 39, 0.75);
    --card-border: rgba(255, 255, 255, 0.08);
    --card-border-focus: rgba(56, 189, 248, 0.4);
    
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --text-error: #fecaca;
    --text-success: #bbf7d0;
    
    /* Primary / Accent colors */
    --primary: #38bdf8;
    --primary-hover: #0ea5e9;
    --primary-glow: rgba(56, 189, 248, 0.3);
    
    --success: #10b981;
    --success-border: rgba(16, 185, 129, 0.4);
    
    --error: #ef4444;
    --error-border: rgba(239, 68, 68, 0.4);
    
    /* Social branding colors */
    --twitch: #a78bfa;
    --instagram: #f43f5e;
    --steam: #6b7280;
    --facebook: #3b82f6;
    --snapchat: #eab308;
    --telegram: #0ea5e9;
    --discord: #5865f2;

    /* Shadow & Effects */
    --shadow-premium: 0 25px 60px rgba(0, 0, 0, 0.6);
    --glass-blur: blur(12px);
    --transition-smooth: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Global Reset & Base */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
    overflow-y: auto !important;
}

body.app-view {
    background: var(--bg-main);
    background-image: var(--bg-gradient);
    background-attachment: fixed;
    display: flex;
    flex-direction: column;
    align-items: center;
}

body.login-view {
    background: var(--bg-main);
    background-image: var(--bg-login-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.12);
    border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(56, 189, 248, 0.4);
}

/* Navigation Bar */
.nav {
    position: sticky;
    top: 0;
    z-index: 20;
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 16px 0;
    backdrop-filter: var(--glass-blur);
    background: linear-gradient(to bottom, rgba(3, 7, 18, 0.95), rgba(3, 7, 18, 0.6) 60%, transparent);
}

.nav-inner {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(17, 24, 39, 0.85);
    border: 1px solid var(--card-border);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.nav-link {
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    cursor: pointer;
    user-select: none;
    transition: var(--transition-smooth);
}

.nav-link:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.05);
}

.nav-link-active {
    background: rgba(56, 189, 248, 0.15);
    color: var(--primary) !important;
    border: 1px solid rgba(56, 189, 248, 0.2);
}

.nav-link-active:hover {
    background: rgba(56, 189, 248, 0.25);
}

.nav-link-primary {
    background: rgba(56, 189, 248, 0.15);
    color: #7dd3fc;
}

.nav-link-primary:hover {
    background: rgba(56, 189, 248, 0.28);
}

.nav-link-plus {
    padding-inline: 12px;
    font-weight: 600;
}

/* Premium Card / Container */
.card {
    background: var(--card-bg);
    backdrop-filter: var(--glass-blur);
    border-radius: 18px;
    padding: 36px 32px;
    border: 1px solid var(--card-border);
    box-shadow: var(--shadow-premium);
    width: 100%;
    max-width: 840px;
    display: flex;
    flex-direction: column;
    min-height: 320px;
    margin-top: 32px;
    margin-bottom: 40px;
    transition: border-color var(--transition-smooth);
}

body.login-view .card {
    max-width: 380px;
}

/* Profile page body */
body.profile-view {
    background: var(--bg-main);
    display: flex;
    align-items: center;
    justify-content: center;
}

body.profile-view .card {
    max-width: 440px;
    width: calc(100% - 32px);
    margin-left: auto;
    margin-right: auto;
    padding: 28px 24px;
}

@media (max-width: 480px) {
    body.profile-view .card {
        width: calc(100% - 24px);
        padding: 24px 18px;
        border-radius: 14px;
        margin-top: 16px;
        margin-bottom: 100px;
    }
}

.card:hover {
    border-color: rgba(255, 255, 255, 0.12);
}

.card .footer {
    margin-top: auto;
}

.card h1 {
    margin: 0 0 8px;
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #fff;
}

.card p.subtitle {
    margin: 0 0 24px;
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Form Styling */
label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.88rem;
    font-weight: 500;
    color: #d1d5db;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
textarea,
select {
    width: 100%;
    padding: 11px 14px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(3, 7, 18, 0.5);
    color: var(--text-main);
    font-size: 0.95rem;
    font-family: inherit;
    outline: none;
    transition: var(--transition-smooth);
}

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

input:focus,
textarea:focus,
select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
    background: rgba(3, 7, 18, 0.8);
}

.field {
    margin-bottom: 20px;
}

.field-row {
    display: flex;
    gap: 12px;
}

.field-row .field {
    flex: 1;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 99px;
    padding: 11px 24px;
    font-size: 0.95rem;
    font-weight: 600;
    font-family: inherit;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: linear-gradient(135deg, #0ea5e9 0%, #10b981 100%);
    color: #030712;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.2);
    width: 100%;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

.btn-primary:active {
    transform: translateY(1px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    border: 1px solid var(--card-border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

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

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-main);
}

.btn-row {
    display: flex;
    gap: 12px;
    margin-top: 14px;
}

/* Alert Boxes & Errors */
.error, .db-error {
    background: var(--error-bg);
    border-radius: 10px;
    padding: 12px 16px;
    color: var(--text-error);
    font-size: 0.9rem;
    margin-bottom: 20px;
    border: 1px solid var(--error-border);
    line-height: 1.4;
}

.success, .success-box {
    background: var(--success-bg);
    border-radius: 10px;
    padding: 12px 16px;
    color: var(--text-success);
    font-size: 0.9rem;
    margin-bottom: 20px;
    border: 1px solid var(--success-border);
    line-height: 1.4;
}

.success-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 4px;
    color: #fff;
}

.success-text {
    margin: 0;
    color: var(--text-success);
}

.success-text--white {
    color: var(--text-main);
}

/* Toast System */
.toast {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 50;
    min-width: 250px;
    max-width: 350px;
    padding: 12px 18px;
    border-radius: 12px;
    font-size: 0.9rem;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 10px;
    opacity: 0;
    transform: translateY(-10px);
    transition: var(--transition-smooth);
}

.toast--visible {
    opacity: 1;
    transform: translateY(0);
}

.toast--success {
    background: rgba(16, 185, 129, 0.95);
    color: #ecfdf5;
    border: 1px solid #34d399;
}

.toast--error {
    background: rgba(239, 68, 68, 0.95);
    color: #fef2f2;
    border: 1px solid #f87171;
}

.toast-icon {
    font-size: 1.2rem;
    font-weight: bold;
}

.toast-close {
    margin-left: auto;
    border: none;
    background: transparent;
    color: inherit;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    padding: 0;
}

/* Global Chat UI */
.chat-placeholder {
    width: 100%;
    margin-top: 24px;
}

.chat-box {
    background: rgba(10, 15, 30, 0.6);
    border-radius: 14px;
    border: 1px solid var(--card-border);
    padding: 14px;
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 400px;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding-right: 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.chat-message {
    font-size: 0.88rem;
    line-height: 1.4;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    background: rgba(255, 255, 255, 0.02);
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.02);
    transition: var(--transition-smooth);
}

.chat-message:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.05);
}

.chat-header-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.chat-username {
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-smooth);
}

.chat-username:hover {
    text-decoration: underline;
}

.chat-username--developer { color: var(--primary); text-shadow: 0 0 8px var(--primary-glow); }
.chat-username--admin { color: #f87171; text-shadow: 0 0 8px rgba(248, 113, 113, 0.3); }
.chat-username--premium { color: #34d399; text-shadow: 0 0 8px rgba(52, 211, 153, 0.3); }
.chat-username--user { color: #ffffff; }

.chat-time {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.chat-text {
    color: #e5e7eb;
    word-break: break-word;
}

.chat-actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.chat-delete-btn {
    border: none;
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    font-size: 0.72rem;
    font-weight: bold;
    cursor: pointer;
    padding: 3px 6px;
    border-radius: 4px;
    transition: var(--transition-smooth);
}

.chat-delete-btn:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #fff;
}

.chat-input-row {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}

.chat-input-row input[type="text"] {
    flex: 1;
    border-radius: 99px;
    padding: 10px 18px;
    background: rgba(3, 7, 18, 0.6);
}

.chat-send-btn {
    border: none;
    border-radius: 99px;
    padding: 0 20px;
    font-size: 0.88rem;
    font-weight: 600;
    cursor: pointer;
    background: rgba(56, 189, 248, 0.15);
    color: var(--primary);
    border: 1px solid rgba(56, 189, 248, 0.2);
    transition: var(--transition-smooth);
}

.chat-send-btn:hover {
    background: var(--primary);
    color: #030712;
    box-shadow: 0 0 15px var(--primary-glow);
}

/* Online Presence List */
.online-list {
    margin-top: 14px;
    padding: 12px;
    border-radius: 12px;
    background: rgba(10, 15, 30, 0.4);
    border: 1px solid var(--card-border);
}

.online-list-title {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-weight: 600;
}

.online-list-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* Home Changelog Card */
.changelog-home {
    margin-top: 20px;
    padding: 18px 20px;
    border-radius: 14px;
    border: 1px solid var(--card-border);
    background: rgba(17, 24, 39, 0.4);
    text-align: left;
    width: 100%;
    transition: var(--transition-smooth);
}

.changelog-home:hover {
    border-color: rgba(255, 255, 255, 0.12);
    background: rgba(17, 24, 39, 0.55);
}

.changelog-home__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.changelog-home__label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--primary);
    font-weight: 700;
}

.changelog-home__top-right {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.changelog-home__date {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.changelog-home__badge {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 99px;
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(52, 211, 153, 0.3);
}

.changelog-home__title {
    margin: 0 0 8px;
    font-size: 1.15rem;
    font-weight: 600;
}

.changelog-home__title a {
    color: #fff;
    text-decoration: none;
    transition: var(--transition-smooth);
}

.changelog-home__title a:hover {
    color: var(--primary);
}

.changelog-home__preview {
    margin: 0 0 12px;
    font-size: 0.9rem;
    color: #d1d5db;
    line-height: 1.5;
}

.changelog-home__more {
    font-size: 0.85rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition-smooth);
}

.changelog-home__more:hover {
    text-decoration: underline;
}

/* User Listing Page */
.user-list-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 20px;
}

.user-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 auto;
    font-size: 0.95rem;
}

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

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

.user-link {
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition-smooth);
}

.user-link--developer { color: var(--primary); }
.user-link--premium { color: #34d399; }
.user-link--user { color: #fff; }

.user-link:hover {
    text-decoration: underline;
}

.user-table .user-name-cell {
    text-align: left;
}

.user-table .name-wrap {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.user-table .list-badges,
.username .badges {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.badge-icon {
    width: 24px;
    height: 24px;
    display: inline-block;
    vertical-align: middle;
    filter: brightness(0) invert(1);
    opacity: 0.8;
}

.badge-ice {
    width: 24px;
    height: 24px;
    display: inline-block;
    vertical-align: middle;
}

.badge-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.user-table .user-uid-cell {
    text-align: center;
    width: 80px;
    font-weight: 600;
    color: var(--text-muted);
}

/* Public Profile Page (`/u/slug`) */
.username {
    font-size: 1.8rem;
    font-weight: 700;
    margin: 0 0 6px;
    color: #fff;
}

.title {
    font-size: 1.05rem;
    color: #a5b4fc;
    margin: 0 0 14px;
    font-weight: 500;
    text-align: center;
    width: 100%;
    display: block;
}

.description {
    font-size: 0.95rem;
    color: #d1d5db;
    margin: 0 0 24px;
    white-space: pre-line;
    line-height: 1.6;
    text-align: center;
    width: 100%;
    display: block;
}

.socials {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
}

.social-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}

.social-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    color: #fff;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(17, 24, 39, 0.8);
    transition: var(--transition-smooth);
}

.social-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(56, 189, 248, 0.2);
}

.social-btn svg {
    width: 22px;
    height: 22px;
}

.social-btn--img img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.social-btn--discord {
    width: auto;
    height: auto;
    padding: 10px 22px;
    gap: 8px;
    border-radius: 99px;
    cursor: pointer;
}

.social-btn--discord span {
    font-size: 0.85rem;
    color: #fff;
    font-weight: 600;
}

/* User Settings / Profil Panel Tabs */
.profile-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 6px;
}

.profile-tab {
    padding: 8px 18px;
    border-radius: 99px;
    font-size: 0.92rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: var(--transition-smooth);
}

.profile-tab:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.04);
}

.profile-tab--active {
    color: var(--primary);
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.2);
}

.security-panel h2 {
    margin: 0 0 12px;
    font-size: 1.15rem;
    color: #fff;
    font-weight: 600;
}

.security-panel .field-hint {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: -8px 0 16px;
    line-height: 1.4;
}

.security-block {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.security-block:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

/* Admin / Plusz Panels Table */
.admin-dashboard {
    width: 100%;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 12px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 14px;
    font-size: 0.9rem;
}

th, td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    text-align: left;
}

th {
    font-weight: 600;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.01);
}

.code-cell {
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: 0.88rem;
    color: var(--primary);
}

/* Utility classes */
hr {
    border: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 24px 0;
}

.footer {
    margin-top: 24px;
    font-size: 0.82rem;
    color: var(--text-muted);
    text-align: center;
}

a.link {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition-smooth);
}

a.link:hover {
    text-decoration: underline;
}

/* Changelog specific styles */
.entry {
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
    background: rgba(17, 24, 39, 0.4);
    backdrop-filter: var(--glass-blur);
    transition: var(--transition-smooth);
}
.entry:hover {
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(17, 24, 39, 0.55);
}
.entry-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 10px;
    font-size: 0.78rem;
    color: var(--text-muted);
}
.entry-date {
    flex: 1;
    min-width: 0;
    line-height: 1.35;
}
.entry-author-wrap {
    flex-shrink: 0;
    text-align: right;
    line-height: 1.35;
}
.entry-title {
    margin: 0 0 10px;
    font-size: 1.25rem;
    font-weight: 600;
    color: #fff;
    line-height: 1.35;
}
.entry-body {
    font-size: 0.95rem;
    color: #d1d5db;
    line-height: 1.6;
}
.entry-body .changelog-body-p {
    margin: 0 0 0.8em;
}
.entry-body .changelog-body-p:last-child {
    margin-bottom: 0;
}
.entry-actions {
    margin-top: 14px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.btn-small {
    padding: 6px 12px;
    border-radius: 99px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    font-size: 0.78rem;
    cursor: pointer;
    font-family: inherit;
    font-weight: 500;
    transition: var(--transition-smooth);
}
.btn-small:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}
.btn-small--danger {
    border-color: rgba(239, 68, 68, 0.3);
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
}
.btn-small--danger:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #fff;
}
.entry-author-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}
.entry-author-link:hover {
    text-decoration: underline;
}
.new-form textarea {
    width: 100%;
    min-height: 100px;
    resize: vertical;
}
.new-form input[type="text"] {
    width: 100%;
}
.entry-title-link {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-smooth);
}
.entry-title-link:hover {
    color: var(--primary);
}
.back-link {
    display: inline-block;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition-smooth);
}
.back-link:hover {
    text-decoration: underline;
}
body.changelog-single-post .card {
    margin-top: 32px;
}

body.forbidden-view {
    background: var(--bg-main);
    background-image: var(--bg-red-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}
.code-box {
    margin-top: 16px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(3, 7, 18, 0.6);
    border: 1px solid rgba(56, 189, 248, 0.4);
    font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
    font-size: 1rem;
    color: var(--primary);
    text-align: center;
}
.note {
    margin-top: 14px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.field-checkbox {
    margin-top: 16px;
    margin-bottom: 22px;
}

/* Hide default checkbox */
.field-checkbox input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

/* Base label container */
.checkbox-label {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    user-select: none;
    font-size: 0.88rem;
    color: var(--text-muted);
    font-weight: 500;
    transition: var(--transition-smooth);
}

.checkbox-label:hover {
    color: var(--text-main);
}

/* The custom checkbox container */
.custom-checkbox {
    width: 18px;
    height: 18px;
    background: rgba(3, 7, 18, 0.6);
    border: 1.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 5px;
    position: relative;
    flex-shrink: 0;
    transition: var(--transition-smooth);
}

/* Hover state border glow */
.checkbox-label:hover .custom-checkbox {
    border-color: rgba(56, 189, 248, 0.5);
    box-shadow: 0 0 8px rgba(56, 189, 248, 0.15);
}

/* Checked state */
.field-checkbox input[type="checkbox"]:checked ~ .checkbox-label .custom-checkbox {
    background: linear-gradient(135deg, #0ea5e9 0%, #10b981 100%);
    border-color: transparent;
    box-shadow: 0 0 10px var(--primary-glow);
}

/* The checkmark (hidden by default) */
.custom-checkbox::after {
    content: "";
    position: absolute;
    display: none;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid #030712;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Show checkmark when checked */
.field-checkbox input[type="checkbox"]:checked ~ .checkbox-label .custom-checkbox::after {
    display: block;
}

.checkbox-text {
    line-height: 1;
}

/* Chat Avatars & Layout Adjustments */
.chat-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
}

.chat-content-wrap {
    flex: 1;
    min-width: 0;
    margin-left: 10px;
}

/* Emoji Picker & Drawer Styles */
.emoji-picker-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 1.1rem;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: center;
}

.emoji-picker-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.emoji-drawer {
    position: absolute;
    bottom: 50px;
    left: 0;
    width: 240px;
    max-height: 150px;
    overflow-y: auto;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
    border-radius: 10px;
    padding: 10px;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 6px;
    z-index: 100;
}

.emoji-item {
    font-size: 1.25rem;
    cursor: pointer;
    text-align: center;
    padding: 4px;
    border-radius: 6px;
    transition: background 0.2s;
    user-select: none;
}

.emoji-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* User management styles */
.user-management-table th, 
.user-management-table td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.user-management-table tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

/* Guns.lol avatar hover animations */
.avatar--spin {
    transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.3s;
}
.avatar--spin:hover {
    transform: rotate(360deg) scale(1.1);
}

.avatar--pulse {
    animation: avatarPulse 2.5s infinite ease-in-out;
    transition: transform 0.3s;
}
.avatar--pulse:hover {
    transform: scale(1.1);
}
@keyframes avatarPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.avatar--glow {
    transition: box-shadow 0.4s ease, transform 0.3s;
}
.avatar--glow:hover {
    transform: scale(1.1);
    box-shadow: 0 0 25px var(--glow-color, #d946ef);
}

@keyframes breathe {
    0%, 100% { opacity: 0.6; transform: scale(0.98); }
    50% { opacity: 1; transform: scale(1.02); }
}

.audio-controller button {
    opacity: 0.8;
    transition: opacity 0.2s, transform 0.1s;
}
.audio-controller button:hover {
    opacity: 1;
    transform: scale(1.1);
}
.audio-controller input[type="range"] {
    opacity: 0.7;
    transition: opacity 0.2s;
}
.audio-controller input[type="range"]:hover {
    opacity: 1;
}

/* ==========================================================================
   Full Mobile Responsiveness Styles
   ========================================================================== */
@media (max-width: 1024px) {
    .profile-split {
        grid-template-columns: 1fr !important;
    }
    .profile-page {
        padding: 16px 12px 100px !important;
    }
    #mobile-toggle-view-btn {
        display: flex !important;
    }
    .profile-split:not(.show-mobile-preview) .preview-panel {
        display: none !important;
    }
    .profile-split.show-mobile-preview .profile-form-col {
        display: none !important;
    }
    .profile-split.show-mobile-preview .preview-panel {
        display: flex !important;
        position: relative !important;
        top: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        align-items: center !important;
    }
    .profile-split.show-mobile-preview .preview-viewport {
        width: 100% !important;
    }
}

@media (max-width: 768px) {
    /* Navigation Bar collapsing / wrapping */
    .nav {
        padding: 10px 0;
    }
    .nav-inner {
        flex-wrap: wrap;
        justify-content: center;
        border-radius: 16px;
        padding: 6px;
        gap: 4px;
        max-width: 95%;
    }
    .nav-link {
        padding: 6px 10px;
        font-size: 0.8rem;
    }
    
    /* Container cards */
    .card {
        padding: 20px 16px;
        margin-top: 16px;
        margin-bottom: 24px;
        border-radius: 14px;
        width: 100%;
        max-width: 100%;
    }

    /* Grid layouts */
    .prof-grid-3, .prof-grid-2, [style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 12px !important;
    }

    /* Chat page layout */
    .chat-layout-wrapper {
        flex-direction: column !important;
        gap: 16px !important;
    }
    .admin-mute-panel {
        width: 100% !important;
        height: 350px !important;
    }
    .chat-box {
        min-width: 100% !important;
    }
    
    /* Stats & Leaderboard responsive tables */
    .table-container {
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin-bottom: 16px;
        border: 1px solid var(--card-border);
        border-radius: 8px;
    }
    table {
        min-width: 600px; /* Force scrollbar on small viewports instead of shrinking */
    }

    /* Form improvements */
    .field input, .field select, .field textarea {
        font-size: 14px !important;
        padding: 10px !important;
    }
    
    /* General spacing improvements */
    body {
        font-size: 14px;
    }
    h1 {
        font-size: 1.5rem !important;
    }
}


