:root {
    --bg-dark: #0a0f1a;
    --bg-darker: #06080e;
    --bg-card: #121820;
    --bg-panel: #1a2332;
    
    --border: #2a3a52;
    --border-light: #3a4a62;
    
    --text: #e8eef7;
    --text-secondary: #a0afc0;
    --text-muted: #6a7a8a;
    
    --gold: #d4a574;
    --gold-dark: #8b6f47;
    --gold-light: #e8c89d;
    
    --blue: #5ba3d0;
    --blue-light: #7abff0;
    
    --success: #6bb968;
    --danger: #d97a5f;
    --warning: #daa520;
    
    --shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
}

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

html, body {
    width: 100%;
    height: 100%;
    font-family: "Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-dark) 50%, var(--bg-darker) 100%);
    overflow-x: hidden;
}

a {
    color: var(--gold-light);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: #fff;
}

button, input, select, textarea {
    font: inherit;
    color: inherit;
}

button {
    cursor: pointer;
    user-select: none;
    border: none;
    background: none;
}

.hidden {
    display: none !important;
}

/* ===== LANDING PAGE ===== */

.landing-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    background: linear-gradient(135deg, var(--bg-darker) 0%, #0a1628 50%, var(--bg-darker) 100%);
}

.landing-shell {
    width: 100%;
    max-width: 1400px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Navigation */
.landing-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border);
}

.landing-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-family: "Cinzel", serif;
    font-weight: 700;
    color: var(--gold-light);
}

.landing-nav-actions {
    display: flex;
    gap: 12px;
}

/* Hero Section */
.landing-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    padding: 60px;
    background: linear-gradient(135deg, rgba(18, 24, 32, 0.8) 0%, rgba(10, 15, 26, 0.9) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    margin-bottom: 40px;
}

.landing-text h1 {
    font-family: "Cinzel", serif;
    font-size: 3.2rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
    color: #fff;
}

.landing-text p {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 30px;
    max-width: 500px;
}

.landing-actions {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.landing-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(91, 163, 208, 0.1) 0%, rgba(212, 165, 116, 0.1) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 40px;
    min-height: 300px;
}

.landing-visual-card {
    display: grid;
    grid-template-rows: auto auto auto;
    gap: 30px;
    text-align: center;
}

.visual-stat strong {
    display: block;
    font-family: "Cinzel", serif;
    font-size: 2.5rem;
    color: var(--gold-light);
    margin-bottom: 8px;
}

.visual-stat span {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
}

/* Features Grid */
.auth-highlights {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

.highlight-card {
    padding: 28px;
    background: linear-gradient(135deg, rgba(18, 24, 32, 0.6) 0%, rgba(10, 15, 26, 0.8) 100%);
    border: 1px solid var(--border);
    border-radius: 8px;
    transition: all 0.3s ease;
}

.highlight-card:hover {
    border-color: var(--border-light);
    background: linear-gradient(135deg, rgba(18, 24, 32, 0.8) 0%, rgba(10, 15, 26, 1) 100%);
    transform: translateY(-4px);
    box-shadow: var(--shadow-sm);
}

.highlight-card strong {
    display: block;
    font-family: "Cinzel", serif;
    font-size: 1.1rem;
    color: var(--gold-light);
    margin-bottom: 12px;
}

.highlight-card span {
    display: block;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-secondary);
}

/* Footer */
.landing-footer {
    text-align: center;
    padding: 40px 20px;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ===== BUTTONS ===== */

.button {
    padding: 12px 28px;
    border-radius: 6px;
    font-family: "Cinzel", serif;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 1px solid transparent;
}

.button-primary {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-light) 100%);
    color: #000;
    border: 1px solid var(--gold-light);
    box-shadow: 0 4px 12px rgba(212, 165, 116, 0.2);
}

.button-primary:hover {
    background: linear-gradient(135deg, var(--gold-light) 0%, #fff 100%);
    box-shadow: 0 6px 20px rgba(212, 165, 116, 0.35);
    transform: translateY(-2px);
}

.button-secondary {
    background: linear-gradient(135deg, var(--bg-panel) 0%, var(--bg-card) 100%);
    color: var(--text);
    border: 1px solid var(--border-light);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.button-secondary:hover {
    background: linear-gradient(135deg, rgba(26, 35, 50, 0.8) 0%, rgba(18, 24, 32, 0.9) 100%);
    border-color: var(--gold);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.button-ghost {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}

.button-ghost:hover {
    border-color: var(--gold);
    background: rgba(212, 165, 116, 0.05);
}

.button-discord {
    background: linear-gradient(135deg, #5865f2 0%, #4752c4 100%);
    color: #fff;
    border: 1px solid rgba(88, 101, 242, 0.5);
    box-shadow: 0 4px 12px rgba(88, 101, 242, 0.2);
}

.button-discord:hover:not(:disabled) {
    background: linear-gradient(135deg, #6d77ff 0%, #5865f2 100%);
    box-shadow: 0 6px 20px rgba(88, 101, 242, 0.35);
    transform: translateY(-2px);
}

.button-discord:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ===== AUTH PAGES ===== */

.auth-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    background: linear-gradient(135deg, var(--bg-darker) 0%, #0a1628 50%, var(--bg-darker) 100%);
}

.auth-shell {
    width: 100%;
    max-width: 1200px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: stretch;
}

.auth-shell-register {
    grid-template-columns: 1fr 1fr;
}

.auth-story {
    padding: 40px;
    background: linear-gradient(135deg, rgba(18, 24, 32, 0.8) 0%, rgba(10, 15, 26, 0.9) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 24px;
}

.auth-story h1 {
    font-family: "Cinzel", serif;
    font-size: 2.4rem;
    font-weight: 700;
    line-height: 1.2;
    color: #fff;
}

.auth-story p {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

.eyebrow {
    display: inline-block;
    font-family: "Cinzel", serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 12px;
}

.auth-panel {
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-card {
    width: 100%;
    max-width: 480px;
    padding: 40px;
    background: linear-gradient(135deg, rgba(18, 24, 32, 0.95) 0%, rgba(10, 15, 26, 1) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.auth-card h2 {
    font-family: "Cinzel", serif;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: #fff;
}

.panel-kicker {
    display: inline-block;
    font-family: "Cinzel", serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 8px;
}

.panel-copy {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 24px;
}

/* ===== FORMS ===== */

.auth-form {
    display: grid;
    gap: 16px;
    margin-bottom: 20px;
}

.field {
    display: grid;
    gap: 8px;
}

.field span {
    font-family: "Cinzel", serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--gold);
    text-transform: uppercase;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 12px 14px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--gold);
    background: rgba(10, 15, 26, 0.9);
    box-shadow: 0 0 12px rgba(212, 165, 116, 0.15);
}

.field input::placeholder,
.field textarea::placeholder {
    color: var(--text-muted);
}

.checkbox-field {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.checkbox-field:hover {
    border-color: var(--border-light);
    background: rgba(10, 15, 26, 0.8);
}

.checkbox-field input {
    width: auto;
    cursor: pointer;
}

.checkbox-field span {
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-family: inherit;
    font-weight: normal;
    text-transform: none;
    letter-spacing: normal;
}

.auth-class-fieldset {
    display: grid;
    gap: 12px;
    padding: 16px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    border-style: none;
}

.auth-class-fieldset legend,
.auth-class-fieldset > span {
    font-family: "Cinzel", serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--gold);
}

.auth-class-fieldset label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.auth-class-fieldset input {
    width: auto;
    cursor: pointer;
    accent-color: var(--gold);
}

.form-message {
    padding: 12px 14px;
    border-radius: 6px;
    margin-bottom: 16px;
    display: none;
}

.form-message.show {
    display: block;
}

.form-message.is-success {
    background: rgba(107, 185, 104, 0.1);
    border: 1px solid var(--success);
    color: #a8e6a1;
}

.form-message.is-error {
    background: rgba(217, 122, 95, 0.1);
    border: 1px solid var(--danger);
    color: #f0a99a;
}

.switch-copy {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.switch-copy a {
    color: var(--gold-light);
    font-weight: 600;
    transition: color 0.2s ease;
}

.switch-copy a:hover {
    color: #fff;
}

/* ===== GAME INTERFACE ===== */

.game-interface {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: 100vh;
    background: linear-gradient(135deg, #0a0f1a 0%, #06080e 50%, #0a0f1a 100%);
    color: var(--text);
}

/* TOP BAR */
.game-topbar {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 30px;
    align-items: center;
    padding: 12px 20px;
    background: linear-gradient(180deg, rgba(18, 24, 32, 0.95) 0%, rgba(10, 15, 26, 0.9) 100%);
    border-bottom: 2px solid var(--border-light);
    backdrop-filter: blur(10px);
}

.game-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: "Cinzel", serif;
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--gold-light);
}

.logo-icon {
    font-size: 1.6rem;
}

.topbar-resources {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
}

.resource-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    text-align: center;
}

.resource-item i {
    color: var(--gold);
    font-size: 1.2rem;
}

.resource-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

.resource-item strong {
    color: var(--gold-light);
    font-size: 1rem;
    font-family: "Cinzel", serif;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-icon-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.topbar-icon-btn:hover {
    border-color: var(--gold);
    background: rgba(10, 15, 26, 0.9);
}

.topbar-icon-btn i {
    font-size: 1.1rem;
}

.badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--danger);
    color: #fff;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
}

.player-status {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.status-online {
    font-size: 0.8rem;
    color: var(--success);
    font-weight: 600;
}

.player-status strong {
    color: var(--text);
    font-size: 0.95rem;
}

/* MAIN LAYOUT */
.game-layout {
    display: grid;
    grid-template-columns: 240px 1fr 280px;
    gap: 12px;
    padding: 12px;
    flex: 1;
    overflow: hidden;
}

/* LEFT SIDEBAR - NAVIGATION */
.game-sidebar {
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, rgba(18, 24, 32, 0.9) 0%, rgba(10, 15, 26, 0.95) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    overflow-y: auto;
}

.sidebar-nav {
    flex: 1;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-section {
    margin-bottom: 16px;
}

.nav-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    padding: 8px 12px;
    font-weight: 700;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    background: rgba(10, 15, 26, 0.5);
    border: 1px solid transparent;
    border-radius: 6px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    text-align: left;
}

.nav-item i {
    min-width: 20px;
    text-align: center;
    font-size: 1.1rem;
}

.nav-item span {
    font-size: 0.9rem;
    font-weight: 600;
}

.nav-item:hover {
    border-color: var(--border-light);
    background: rgba(10, 15, 26, 0.8);
    color: var(--gold);
}

.nav-item.active {
    background: linear-gradient(135deg, rgba(212, 165, 116, 0.15) 0%, rgba(91, 163, 208, 0.1) 100%);
    border-color: var(--gold);
    color: var(--gold-light);
}

.nav-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    margin: 16px;
    background: rgba(217, 122, 95, 0.15);
    border: 1px solid var(--danger);
    border-radius: 6px;
    color: #f0a99a;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
}

.nav-logout:hover {
    background: rgba(217, 122, 95, 0.25);
}

/* CENTER - MAIN GAMEPLAY AREA */
.game-main {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: linear-gradient(180deg, rgba(18, 24, 32, 0.9) 0%, rgba(10, 15, 26, 0.95) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    overflow: hidden;
}

.game-world {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(91, 163, 208, 0.05) 0%, rgba(212, 165, 116, 0.05) 100%);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 20px;
    overflow: auto;
}

.world-background {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 600"><defs><linearGradient id="skyGrad" x1="0%" y1="0%" x2="0%" y2="100%"><stop offset="0%" style="stop-color:%23234470;stop-opacity:1" /><stop offset="100%" style="stop-color:%230a0f1a;stop-opacity:1" /></linearGradient></defs><rect width="800" height="600" fill="url(%23skyGrad)"/><polygon points="700,400 750,300 800,400" fill="%238b6f47" opacity="0.3"/><polygon points="100,450 150,350 200,450" fill="%238b6f47" opacity="0.25"/><circle cx="400" cy="100" r="50" fill="%23d4a574" opacity="0.2"/></svg>') center/cover;
}

.city-view {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 60px;
    font-size: 4rem;
    text-align: center;
}

.world-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 22px;
    min-width: 140px;
    background: rgba(10, 15, 26, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 18px;
    color: var(--gold-light);
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.castle, .market, .training-area {
    font-family: "Cinzel", serif;
    color: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
}

.world-node:hover,
.castle:hover,
.market:hover,
.training-area:hover {
    transform: scale(1.08);
    background: rgba(212, 165, 116, 0.12);
    color: #fff;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
}

.game-content {
    flex: 0 0 auto;
    padding: 16px;
    max-height: 280px;
    overflow-y: auto;
}

.content-view {
    display: none;
}

.content-view.active {
    display: block;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.dashboard-card {
    padding: 14px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
}

.dashboard-card h3 {
    font-size: 0.95rem;
    margin-bottom: 10px;
    color: var(--gold-light);
}

.gain-item, .stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.gain-item strong, .stat-row strong {
    color: var(--gold);
    font-family: "Cinzel", serif;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(10, 15, 26, 0.9);
    border-radius: 4px;
    overflow: hidden;
    margin: 8px 0;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--blue), var(--gold));
    border-radius: 4px;
    transition: width 0.3s ease;
}

.buffs-list, .stats-summary {
    display: grid;
    gap: 6px;
}

.buff {
    font-size: 0.85rem;
    color: var(--success);
    padding: 4px 0;
}

.production-list {
    display: grid;
    gap: 8px;
    margin-top: 12px;
}

.task-item {
    padding: 14px;
    background: rgba(10, 15, 26, 0.85);
    border: 1px solid var(--border);
    border-radius: 8px;
    display: grid;
    gap: 8px;
}

.task-item strong {
    color: var(--gold-light);
    font-family: "Cinzel", serif;
}

.panel-card {
    padding: 18px;
    background: rgba(10, 15, 26, 0.8);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.panel-card h3 {
    margin-bottom: 14px;
    color: var(--gold-light);
    font-size: 1rem;
    font-family: "Cinzel", serif;
}

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

.item-slot {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 12px;
    align-items: center;
    padding: 14px;
    background: rgba(10, 15, 26, 0.75);
    border: 1px solid var(--border);
    border-radius: 8px;
}

.item-icon {
    width: 52px;
    height: 52px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: rgba(212, 165, 116, 0.1);
    color: var(--gold);
    font-size: 1.5rem;
}

.item-details {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.item-details strong {
    font-size: 0.95rem;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.item-details span {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

.item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.combat-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.combat-box {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px;
    background: rgba(10, 15, 26, 0.8);
    border: 1px solid var(--border);
    border-radius: 8px;
}

.combat-card,
.market-card,
.pvp-card,
.achievement-card,
.leaderboard-row,
.skill-card {
    padding: 14px;
    background: rgba(10, 15, 26, 0.75);
    border: 1px solid var(--border);
    border-radius: 8px;
    display: grid;
    gap: 10px;
}

.combat-card strong,
.market-card .market-info strong,
.pvp-card strong,
.achievement-head strong,
.skill-header strong {
    color: var(--gold-light);
    font-family: "Cinzel", serif;
}

.market-card {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 14px;
}

.market-info {
    display: grid;
    gap: 6px;
    min-width: 0;
}

.leaderboard-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 10px;
    align-items: center;
}

.leaderboard-rank,
.leaderboard-name,
.leaderboard-score {
    font-size: 0.9rem;
}

.leaderboard-name {
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.pvp-card {
    display: grid;
    gap: 8px;
}

.pvp-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.achievement-card.locked {
    opacity: 0.8;
}

.achievement-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.achievement-body p,
.achievement-body small {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.5;
}

.skill-card {
    display: grid;
    gap: 8px;
}

.skill-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.skill-meta {
    font-size: 0.85rem;
}

.empty-state {
    padding: 20px;
    border: 1px dashed var(--border);
    border-radius: 8px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    background: rgba(10, 15, 26, 0.55);
}

.section-title {
    font-size: 0.9rem;
    color: var(--gold-light);
    margin: 12px 0 6px;
    font-family: "Cinzel", serif;
}

.game-bottom {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

/* RIGHT SIDEBAR - CHARACTER */
.game-sidebar-right {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: linear-gradient(180deg, rgba(18, 24, 32, 0.9) 0%, rgba(10, 15, 26, 0.95) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 16px;
    overflow-y: auto;
}

.character-panel {
    display: grid;
    gap: 12px;
    padding: 14px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
}

.character-avatar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.avatar-display {
    font-size: 3rem;
    padding: 10px;
    background: linear-gradient(135deg, rgba(212, 165, 116, 0.2) 0%, rgba(91, 163, 208, 0.1) 100%);
    border: 2px solid var(--border-light);
    border-radius: 8px;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.character-avatar strong {
    color: var(--gold-light);
    font-family: "Cinzel", serif;
    font-size: 1rem;
}

.character-avatar small {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.stats-block {
    display: grid;
    gap: 8px;
}

.stats-block h4 {
    font-size: 0.9rem;
    color: var(--gold);
    font-family: "Cinzel", serif;
    margin-bottom: 4px;
}

.stat {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    padding: 4px 0;
}

.stat span {
    color: var(--text-secondary);
}

.stat strong {
    color: var(--gold);
    font-family: "Cinzel", serif;
}

.equipment-panel {
    padding: 14px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
}

.equipment-panel h4 {
    font-size: 0.9rem;
    color: var(--gold);
    margin-bottom: 12px;
    font-family: "Cinzel", serif;
}

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

.equip-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 10px;
    background: rgba(10, 15, 26, 0.8);
    border: 1px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.equip-slot:hover {
    border-color: var(--gold);
    background: rgba(10, 15, 26, 0.95);
}

.slot-icon {
    font-size: 1.5rem;
}

.equip-slot span {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    text-align: center;
}

.info-panel {
    padding: 14px;
    background: rgba(10, 15, 26, 0.6);
    border: 1px solid var(--border);
    border-radius: 6px;
    display: grid;
    gap: 8px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

.info-item span {
    color: var(--text-muted);
}

.info-item strong {
    color: var(--gold);
    font-family: "Cinzel", serif;
}

/* BOTTOM - CHAT & ACTIVITY */
.game-bottom {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
    padding: 12px;
    max-height: 240px;
}

.chat-panel,
.activity-panel,
.area-panel {
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, rgba(18, 24, 32, 0.9) 0%, rgba(10, 15, 26, 0.95) 100%);
    border: 1px solid var(--border-light);
    border-radius: 8px;
    overflow: hidden;
}

.chat-header,
.activity-header,
.area-header {
    padding: 10px 12px;
    background: rgba(10, 15, 26, 0.8);
    border-bottom: 1px solid var(--border);
}

.chat-header h4,
.activity-header h4,
.area-header h4 {
    font-size: 0.9rem;
    color: var(--gold);
    margin: 0;
    font-family: "Cinzel", serif;
}

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

.chat-msg {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.chat-msg strong {
    color: var(--gold-light);
}

.chat-input {
    padding: 8px 10px;
    background: rgba(10, 15, 26, 0.8);
    border: 1px solid var(--border);
    border-radius: 0;
    color: var(--text);
    font-size: 0.85rem;
}

.chat-input::placeholder {
    color: var(--text-muted);
}

.activity-list {
    flex: 1;
    padding: 10px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.activity-item {
    display: grid;
    grid-template-columns: 45px 1fr;
    gap: 8px;
    font-size: 0.85rem;
    padding: 4px 0;
    border-bottom: 1px solid var(--border);
}

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

.activity-item .text {
    color: var(--text-secondary);
}

.area-content {
    padding: 10px;
    flex: 1;
    overflow-y: auto;
}

.area-content strong {
    display: block;
    color: var(--gold-light);
    margin-bottom: 6px;
    font-family: "Cinzel", serif;
}

.area-content p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 8px;
    line-height: 1.5;
}

.mobs-here {
    display: grid;
    gap: 4px;
}

.mobs-here div {
    font-size: 0.8rem;
    color: var(--warning);
    padding: 4px;
    background: rgba(218, 165, 32, 0.1);
    border-left: 2px solid var(--warning);
    padding-left: 8px;
}

/* RESPONSIVE */
@media (max-width: 1400px) {
    .game-layout {
        grid-template-columns: 200px 1fr 240px;
    }
    
    .topbar-resources {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 1100px) {
    .game-layout {
        grid-template-columns: 1fr;
    }
    
    .game-bottom {
        grid-template-columns: 1fr 1fr;
    }
    
    .game-sidebar-right {
        display: none;
    }
}

@media (max-width: 768px) {
    .game-layout {
        grid-template-columns: 1fr;
    }
    
    .game-topbar {
        grid-template-columns: auto 1fr;
        gap: 16px;
    }
    
    .topbar-resources {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .resource-item {
        padding: 6px 8px;
        font-size: 0.8rem;
    }
    
    .game-bottom {
        grid-template-columns: 1fr;
        max-height: 200px;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: rgba(10, 15, 26, 0.6);
}

::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold);
}

/* ===== RESPONSIVE ===== */

@media (max-width: 1200px) {
    .app-shell {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .landing-hero {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .auth-shell,
    .auth-shell-register {
        grid-template-columns: 1fr;
    }
    
    .auth-highlights {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .landing-hero {
        padding: 40px 20px;
    }
    
    .landing-text h1 {
        font-size: 2rem;
    }
    
    .landing-actions {
        flex-direction: column;
    }
    
    .button {
        width: 100%;
    }
    
    .auth-shell,
    .auth-shell-register {
        grid-template-columns: 1fr;
    }
    
    .auth-story,
    .auth-card {
        padding: 30px;
    }
    
    .auth-highlights {
        grid-template-columns: 1fr;
    }
    
    .landing-nav {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
}

@media (max-width: 600px) {
    .landing-logo {
        font-size: 1.2rem;
    }
    
    .landing-text h1 {
        font-size: 1.6rem;
    }
    
    .landing-text p {
        font-size: 0.95rem;
    }
    
    .button {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}
