.nav-hidden { display: none !important; }

.nav-account {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--color-text-light);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

.nav-account:hover { color: var(--color-text-white); }

.nav-account-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    opacity: 0.75;
    transition: opacity 0.2s;
}

.nav-account:hover .nav-account-icon { opacity: 1; }

.nav-logout {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-muted);
    text-decoration: none;
    transition: color 0.2s;
}

.nav-logout:hover { color: #f87171; }

.profile-view {
    display: none;
    width: 100%;
    padding: 36px 20px 60px;
    justify-content: center;
}

.profile-view.active {
    display: flex;
}

.profile-inner {
    width: 100%;
    max-width: 1100px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.profile-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 80px 0;
    color: var(--color-text-muted);
    font-size: 14px;
}

.profile-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--color-border);
    border-top-color: var(--color-accent-blue);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.profile-hero {
    background: linear-gradient(135deg, #0f1a35 0%, #1a2a50 50%, #0f1a35 100%);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    padding: 28px 32px;
    display: flex;
    align-items: center;
    gap: 22px;
    position: relative;
    overflow: hidden;
}

.profile-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 30% 50%, rgba(30,58,138,0.3) 0%, transparent 60%);
    pointer-events: none;
}

.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1e3a8a 0%, #3b5cc8 100%);
    border: 2px solid rgba(80,130,220,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 800;
    color: #fff;
    flex-shrink: 0;
    box-shadow: 0 0 24px rgba(30,58,138,0.5);
    position: relative;
    z-index: 1;
}

.profile-hero-info {
    flex: 1;
    min-width: 0;
    position: relative;
    z-index: 1;
}

.profile-username {
    font-size: 26px;
    font-weight: 800;
    color: var(--color-text-white);
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.profile-hero-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12.5px;
    color: var(--color-text-muted);
}

.profile-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.profile-status-badge--online {
    background: rgba(34,197,94,0.15);
    border: 1px solid rgba(34,197,94,0.3);
    color: #4ade80;
}

.profile-status-badge--offline {
    background: rgba(100,116,139,0.15);
    border: 1px solid rgba(100,116,139,0.3);
    color: #94a3b8;
}

.profile-hero-sep { opacity: 0.3; }

.profile-hero-detail { color: var(--color-text-muted); }
.profile-hero-detail strong { color: var(--color-text-light); }

.profile-logout-btn {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 18px;
    background: rgba(200,50,50,0.1);
    border: 1px solid rgba(200,50,50,0.25);
    border-radius: var(--radius-md);
    color: #f87171;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-main);
    transition: background 0.2s, border-color 0.2s;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.profile-logout-btn:hover {
    background: rgba(200,50,50,0.2);
    border-color: rgba(200,50,50,0.5);
}

.profile-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 0;
    border: 1px solid var(--color-border);
    border-top: none;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    overflow: hidden;
}

.profile-sidebar {
    background: #0a0f1e;
    border-right: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
    gap: 0;
}

.profile-card {
    padding: 20px 22px;
    border-bottom: 1px solid var(--color-border);
}

.profile-card:last-child { border-bottom: none; }

.profile-card-title {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
    margin-bottom: 14px;
}

.profile-card-title svg { opacity: 0.6; }

.profile-info-list { display: flex; flex-direction: column; gap: 10px; }

.profile-info-row {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.profile-info-label {
    font-size: 10.5px;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--color-text-muted);
}

.profile-info-val {
    font-size: 13px;
    color: var(--color-text-light);
    font-weight: 500;
    word-break: break-all;
}

.profile-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.profile-stat-box {
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: 12px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
}

.profile-stat-val {
    font-size: 18px;
    font-weight: 800;
    color: var(--color-text-white);
}

.profile-stat-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--color-text-muted);
}

.profile-main {
    background: var(--color-bg-card);
    display: flex;
    flex-direction: column;
}

.profile-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--color-border);
    background: #0d1120;
    padding: 0 20px;
}

.profile-tab {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 14px 18px;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--color-text-muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-main);
    transition: color 0.2s, border-color 0.2s;
    margin-bottom: -1px;
}

.profile-tab svg { opacity: 0.5; transition: opacity 0.2s; }

.profile-tab:hover { color: var(--color-text-light); }
.profile-tab:hover svg { opacity: 0.8; }

.profile-tab.active {
    color: var(--color-text-white);
    border-bottom-color: #3b6fd4;
}

.profile-tab.active svg { opacity: 1; }

.profile-panel { padding: 24px; }
.profile-panel--hidden { display: none; }

.profile-chars-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.prof-char-card {
    background: rgba(255,255,255,0.025);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.prof-char-card:hover {
    border-color: rgba(59,111,212,0.5);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.prof-char-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    background: linear-gradient(135deg, rgba(30,42,70,0.8), rgba(15,22,45,0.8));
    border-bottom: 1px solid var(--color-border);
}

.prof-char-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: rgba(30,58,138,0.25);
    border: 1px solid rgba(59,111,212,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.prof-char-icon img {
    width: 26px;
    height: 26px;
    object-fit: contain;
    opacity: 0.85;
}

.prof-char-identity { flex: 1; min-width: 0; }

.prof-char-name {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: var(--color-text-white);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.prof-char-class {
    display: block;
    font-size: 12px;
    color: var(--color-text-muted);
    margin-top: 2px;
}

.prof-char-level {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    background: rgba(30,58,138,0.3);
    border: 1px solid rgba(59,111,212,0.4);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    color: #93c5fd;
    flex-shrink: 0;
}

.prof-char-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
}

.prof-char-stat {
    padding: 12px 18px;
    border-right: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.prof-char-stat:nth-child(2n) { border-right: none; }
.prof-char-stat:nth-last-child(-n+2) { border-bottom: none; }

.prof-char-stat-label {
    font-size: 10.5px;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--color-text-muted);
}

.prof-char-stat-val {
    font-size: 13px;
    font-weight: 600;
    color: var(--color-text-light);
}

.prof-char-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 20px;
    color: var(--color-text-muted);
    font-size: 13px;
}

.profile-settings-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.profile-settings-card {
    background: rgba(255,255,255,0.025);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.profile-settings-card-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 700;
    color: var(--color-text-light);
}

.profile-settings-card form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.profile-settings-card .form-input { font-size: 13px; padding: 9px 14px; }

.profile-settings-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 10px 16px;
    margin-top: 4px;
    background: linear-gradient(135deg, #1e3a8a 0%, #2a50b8 100%);
    border: 1px solid rgba(80,130,220,0.35);
    border-radius: var(--radius-md);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
    cursor: pointer;
    font-family: var(--font-main);
    transition: filter 0.2s;
}

.profile-settings-btn:hover { filter: brightness(1.15); }
.profile-settings-btn:disabled { opacity: 0.5; cursor: default; }

.profile-settings-msg {
    display: none;
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    font-size: 12.5px;
    border: 1px solid;
}

.profile-settings-msg.success {
    display: block;
    background: rgba(34,197,94,0.1);
    border-color: rgba(34,197,94,0.3);
    color: #4ade80;
}

.profile-settings-msg.error {
    display: block;
    background: rgba(200,50,50,0.1);
    border-color: rgba(200,50,50,0.3);
    color: #f87171;
}
