/* ==========================================
   CLEAN LAYOUT OVERRIDES
   ========================================== */

/* Better Base Layout */
body {
    background: linear-gradient(135deg, #ffe6ff 0%, #fff0ff 50%, #ffe6ff 100%);
    min-height: 100vh;
}

/* Main Container - Centered and Clean */
.container {
    max-width: 900px;
    margin: 20px auto;
    padding: 0;
    background: transparent;
    box-shadow: none;
}

/* Settings Bar - Fixed Top */
.settings-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #660066, #990099);
    padding: 10px 20px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(102, 0, 102, 0.3);
}

.settings-btn {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    padding: 8px 15px;
    border-radius: 20px;
    color: white;
    cursor: pointer;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.6em;
    transition: all 0.3s ease;
}

.settings-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

/* Add top padding to account for fixed navbar */
.container {
    padding-top: 60px;
}

/* Hide the old banner - we have nav now */
.retro-banner {
    display: none;
}

/* Hide welcome section - redundant */
.welcome-section {
    display: none;
}

/* ==========================================
   CARD SYSTEM
   ========================================== */

.cat-section,
.achievements-section,
.mini-games-section,
.showcase-section,
.battles-section,
.pet-sitting-section,
.challenges-section,
.profile-section,
.community-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(102, 0, 102, 0.1);
    border: 2px solid rgba(255, 102, 255, 0.2);
}

.cat-section h2,
.achievements-section h2,
.mini-games-section h2,
.showcase-section h2,
.battles-section h2,
.pet-sitting-section h2,
.challenges-section h2,
.profile-section h2,
.community-section h2 {
    margin: 0 0 20px 0;
    padding-bottom: 15px;
    border-bottom: 2px solid rgba(255, 102, 255, 0.2);
    color: #660066;
    font-size: 1em;
}

/* ==========================================
   CAT SECTION - Main Focus
   ========================================== */

.cat-section {
    text-align: center;
}

.status-bars {
    max-width: 350px;
    margin: 0 auto 20px auto;
    display: grid;
    gap: 12px;
}

.status-label {
    text-align: left;
    font-size: 0.7em;
    margin-bottom: 4px;
    color: #660066;
}

.status-container {
    height: 16px;
    border-radius: 8px;
    border: none;
    background: rgba(102, 0, 102, 0.1);
    overflow: hidden;
}

.status-bar {
    height: 100%;
    background: linear-gradient(90deg, #ff66ff, #ff99ff);
    border-radius: 8px;
    transition: width 0.5s ease;
}

.cat-container {
    background: linear-gradient(145deg, rgba(255, 230, 255, 0.5), rgba(255, 200, 255, 0.3));
    border: 3px solid rgba(255, 102, 255, 0.3);
    border-radius: 20px;
    width: 280px;
    height: 280px;
    margin: 20px auto;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.pet-controls {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin: 20px 0;
}

.pet-name-section {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 102, 255, 0.2);
}

.pet-name-input {
    padding: 10px 15px;
    border: 2px solid rgba(255, 102, 255, 0.3);
    border-radius: 10px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.7em;
    background: white;
    color: #660066;
    width: 180px;
}

.pet-name-display {
    font-size: 1.2em;
    color: #660066;
    margin-bottom: 10px;
}

.streak-section {
    margin-top: 15px;
    padding: 12px;
    background: linear-gradient(135deg, #fff5e6, #ffe6cc);
    border-radius: 10px;
    display: inline-block;
}

.streak-display {
    font-size: 0.9em;
    color: #cc6600;
}

/* ==========================================
   BUTTONS - Cleaner Style
   ========================================== */

.action-button {
    padding: 12px 20px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(145deg, #ff66ff, #dd44dd);
    color: white;
    cursor: pointer;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.7em;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(255, 102, 255, 0.3);
}

.action-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 102, 255, 0.4);
    background: linear-gradient(145deg, #ff88ff, #ee55ee);
}

.action-button:active {
    transform: translateY(1px);
}

/* ==========================================
   MINI GAMES - Grid Layout
   ========================================== */

.games-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
}

.game-button {
    padding: 20px;
    background: linear-gradient(145deg, #fff, #f5e6ff);
    border: 2px solid rgba(255, 102, 255, 0.3);
    border-radius: 15px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.8em;
    color: #660066;
    cursor: pointer;
    transition: all 0.3s ease;
}

.game-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(255, 102, 255, 0.2);
    border-color: #ff66ff;
}

/* ==========================================
   ACHIEVEMENTS - Compact Grid
   ========================================== */

.achievements-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
}

/* ==========================================
   SHOWCASE - Cleaner Tabs
   ========================================== */

.showcase-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.showcase-tab {
    flex: 1;
    padding: 12px;
    background: rgba(255, 102, 255, 0.1);
    border: 2px solid transparent;
    border-radius: 10px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.7em;
    color: #660066;
    cursor: pointer;
    transition: all 0.3s ease;
}

.showcase-tab.active {
    background: white;
    border-color: #ff66ff;
    box-shadow: 0 4px 12px rgba(255, 102, 255, 0.2);
}

.leaderboard-list {
    max-height: 300px;
    overflow-y: auto;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

/* ==========================================
   BATTLES - Clean Layout
   ========================================== */

.battle-description {
    color: #888;
    font-size: 0.7em;
    margin-bottom: 15px;
}

.battle-stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 102, 255, 0.2);
    font-size: 0.8em;
}

/* ==========================================
   PET SITTING - Grid
   ========================================== */

.available-pets {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

/* ==========================================
   PROFILE SECTION - Stats Grid
   ========================================== */

.profile-content {
    margin-bottom: 20px;
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 15px;
}

.stat-item {
    background: linear-gradient(145deg, #fff, #f5e6ff);
    padding: 15px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid rgba(255, 102, 255, 0.2);
}

.stat-label {
    display: block;
    font-size: 0.6em;
    color: #888;
    margin-bottom: 5px;
}

.stat-value {
    display: block;
    font-size: 1.2em;
    color: #660066;
}

/* Friends Section */
.friends-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px solid rgba(255, 102, 255, 0.2);
}

.friends-section h3 {
    margin-bottom: 15px;
    color: #660066;
    font-size: 0.9em;
}

.add-friend-container {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.friend-input {
    flex: 1;
    padding: 10px 15px;
    border: 2px solid rgba(255, 102, 255, 0.3);
    border-radius: 10px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.7em;
}

/* ==========================================
   COMMUNITY SECTION - Chat Focus
   ========================================== */

.user-info-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 10px 15px;
    background: rgba(255, 102, 255, 0.1);
    border-radius: 10px;
}

.user-info-bar span {
    font-size: 0.7em;
}

.logout-button {
    padding: 8px 15px;
    background: rgba(255, 102, 255, 0.2);
    border: none;
    border-radius: 8px;
    color: #660066;
    cursor: pointer;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.6em;
    transition: all 0.3s ease;
}

.logout-button:hover {
    background: rgba(255, 102, 255, 0.3);
}

.community-header {
    display: none;
}

.chat-section {
    background: white;
    border-radius: 15px;
    padding: 20px;
    border: 1px solid rgba(255, 102, 255, 0.2);
}

.chat-section h3 {
    margin: 0 0 15px 0;
    color: #660066;
    font-size: 0.9em;
}

.chat-messages {
    height: 300px;
    overflow-y: auto;
    background: rgba(255, 250, 255, 0.5);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 15px;
}

.chat-input-container {
    display: flex;
    gap: 10px;
}

.chat-input {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid rgba(255, 102, 255, 0.3);
    border-radius: 10px;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.7em;
}

.chat-send-button {
    padding: 12px 20px;
    background: linear-gradient(145deg, #ff66ff, #dd44dd);
    border: none;
    border-radius: 10px;
    color: white;
    cursor: pointer;
    font-family: 'Press Start 2P', cursive;
    font-size: 0.7em;
}

/* ==========================================
   CUSTOMIZATION PANEL - Collapsible
   ========================================== */

.customization-panel {
    position: fixed;
    left: 20px;
    top: 80px;
    width: 200px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 15px;
    padding: 15px;
    border: 2px solid rgba(255, 102, 255, 0.3);
    box-shadow: 0 4px 20px rgba(102, 0, 102, 0.1);
    font-size: 0.65em;
    z-index: 100;
    transition: all 0.3s ease;
}

.customization-panel.collapsed {
    width: 50px;
    overflow: hidden;
}

.customization-panel h2 {
    font-size: 0.9em;
    margin: 0 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 102, 255, 0.2);
    color: #660066;
}

.customization-panel h3 {
    font-size: 0.8em;
    margin: 12px 0 8px 0;
    color: #888;
}

.customization-section {
    margin-bottom: 12px;
}

.customization-section select {
    width: 100%;
    padding: 8px;
    margin: 4px 0;
    border: 1px solid rgba(255, 102, 255, 0.3);
    border-radius: 8px;
    font-size: 0.9em;
    background: white;
}

.color-picker label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0;
}

.color-picker input[type="color"] {
    width: 35px;
    height: 22px;
    border: 1px solid rgba(255, 102, 255, 0.3);
    border-radius: 4px;
    padding: 0;
    cursor: pointer;
}

.accessory-toggles {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}

.accessory-toggles label {
    font-size: 0.85em;
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 3px 0;
}

#randomize {
    width: 100%;
    padding: 10px;
    margin-top: 10px;
}

/* ==========================================
   MUSIC PLAYER - Compact
   ========================================== */

.music-controls {
    position: fixed;
    right: 20px;
    bottom: 20px;
    min-width: 220px;
    padding: 15px;
    background: linear-gradient(145deg, #660066, #880088);
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(102, 0, 102, 0.3);
    z-index: 1000;
}

.music-info {
    text-align: center;
    margin-bottom: 12px;
    padding: 8px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

#song-title {
    color: white;
    font-size: 0.7em;
    margin-bottom: 4px;
}

#time-info {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.6em;
}

.music-controls-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 12px;
}

.music-button {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.music-button:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
}

.volume-control span {
    color: white;
}

.volume-slider {
    flex: 1;
    height: 4px;
    -webkit-appearance: none;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 14px;
    height: 14px;
    background: white;
    border-radius: 50%;
    cursor: pointer;
}

/* ==========================================
   RESPONSIVE - Mobile First
   ========================================== */

@media (max-width: 1100px) {
    .customization-panel {
        position: static;
        width: 100%;
        max-height: none;
        margin-bottom: 20px;
    }
    
    .container {
        max-width: 100%;
        padding: 60px 15px 15px 15px;
    }
}

@media (max-width: 600px) {
    .settings-bar {
        padding: 8px 10px;
    }
    
    .settings-btn {
        padding: 6px 10px;
        font-size: 0.5em;
    }
    
    .cat-section,
    .achievements-section,
    .mini-games-section,
    .showcase-section,
    .battles-section,
    .pet-sitting-section,
    .challenges-section,
    .profile-section,
    .community-section {
        padding: 15px;
        border-radius: 15px;
    }
    
    .pet-controls {
        flex-direction: column;
    }
    
    .pet-controls .action-button {
        width: 100%;
    }
    
    .music-controls {
        right: 10px;
        bottom: 10px;
        min-width: 180px;
        padding: 12px;
    }
    
    .profile-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .games-container {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   DARK MODE TWEAKS
   ========================================== */

body.dark-mode {
    background: linear-gradient(135deg, #1a0a1a 0%, #2a1a2a 50%, #1a0a1a 100%);
}

body.dark-mode .cat-section,
body.dark-mode .achievements-section,
body.dark-mode .mini-games-section,
body.dark-mode .showcase-section,
body.dark-mode .battles-section,
body.dark-mode .pet-sitting-section,
body.dark-mode .challenges-section,
body.dark-mode .profile-section,
body.dark-mode .community-section {
    background: rgba(40, 20, 40, 0.95);
    border-color: rgba(255, 102, 255, 0.3);
}

body.dark-mode .customization-panel {
    background: rgba(40, 20, 40, 0.98);
    border-color: rgba(255, 102, 255, 0.3);
}

body.dark-mode .chat-section {
    background: rgba(30, 15, 30, 0.9);
}

body.dark-mode .chat-messages {
    background: rgba(20, 10, 20, 0.5);
}
