/* Gym Leaders Page Styles - Based on nuzlocke.app design */

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

:root {
    --primary-color: #FF6B35;
    --secondary-color: #8B5CF6;
    --dark-bg: #0f0f0f;
    --card-bg: rgba(30, 30, 30, 0.95);
}

/* Page Container */
.gym-leaders-page {
    min-height: 100vh;
    padding-top: 80px;
    background: var(--dark-bg);
}

/* Hero Section */
.hero-section {
    padding: 60px 20px;
    text-align: center;
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.1), transparent);
}

.page-title {
    font-size: 3rem;
    font-weight: 900;
    color: var(--primary-color);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.page-title i {
    margin-right: 15px;
}

.page-subtitle {
    font-size: 1.2rem;
    color: #aaa;
}

/* Section Titles */
.section-title {
    font-size: 2rem;
    margin: 50px 0 30px;
    color: var(--primary-color);
    text-align: center;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.section-title i {
    margin-right: 10px;
}

.elite-four-title {
    color: #e74c3c;
}

.champion-title {
    color: #f39c12;
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.gym-leaders-container {
    padding: 20px 0 100px;
}

/* Leader Card */
.leader-card {
    background: var(--card-bg);
    border: 2px solid rgba(255, 107, 53, 0.2);
    border-radius: 15px;
    margin-bottom: 25px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.leader-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 5px 25px rgba(255, 107, 53, 0.3);
}

/* Leader Header - Clickable */
.leader-header {
    display: flex;
    align-items: center;
    padding: 20px 25px;
    cursor: pointer;
    gap: 20px;
    transition: background 0.3s ease;
}

.leader-header:hover {
    background: rgba(255, 107, 53, 0.05);
}

/* Arrow */
.leader-arrow {
    transition: transform 0.3s ease;
    color: var(--primary-color);
}

.leader-card.expanded .leader-arrow {
    transform: rotate(90deg);
}

.leader-arrow i {
    font-size: 1.2rem;
}

/* Leader Sprite */
.leader-sprite {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--primary-color);
    flex-shrink: 0;
}

.leader-sprite img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Leader Info */
.leader-info {
    flex: 1;
}

.leader-header-inner {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 5px;
}

.leader-name {
    font-size: 1.8rem;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

.type-badge {
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.leader-gym {
    color: #888;
    font-size: 1rem;
    margin: 5px 0 0 0;
}

/* Team Preview */
.leader-team-preview {
    display: flex;
    gap: 8px;
}

.team-sprite {
    width: 50px;
    height: 50px;
    background: rgba(20, 20, 20, 0.6);
    border-radius: 8px;
    padding: 5px;
    border: 1px solid rgba(255, 107, 53, 0.3);
    transition: all 0.3s ease;
}

.team-sprite:hover {
    transform: scale(1.1);
    border-color: var(--primary-color);
}

.team-sprite img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    image-rendering: pixelated;
}

/* Level Cap */
.leader-level-cap {
    text-align: center;
    padding: 10px;
    background: rgba(139, 92, 246, 0.2);
    border-radius: 10px;
    border: 2px solid var(--secondary-color);
    min-width: 80px;
}

.level-cap-label {
    font-size: 0.7rem;
    color: #888;
    text-transform: uppercase;
    margin-bottom: 2px;
}

.level-cap-number {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--secondary-color);
}

/* Team Expansion */
.leader-team-expansion {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease;
    background: rgba(20, 20, 20, 0.8);
}

.leader-card.expanded .leader-team-expansion {
    max-height: 10000px;
    border-top: 1px solid rgba(255, 107, 53, 0.2);
}

.team-content {
    padding: 30px 20px;
}

/* Pokemon Grid */
.pokemon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 25px;
}

/* Pokemon Card - Screenshot Style */
.pokemon-card {
    background: linear-gradient(135deg, rgba(40, 40, 40, 0.95), rgba(30, 30, 30, 0.95));
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.pokemon-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: 0 10px 30px rgba(255, 107, 53, 0.3);
}

.pokemon-card-header {
    position: relative;
    padding: 15px;
    background: linear-gradient(180deg, rgba(50, 50, 50, 0.8), rgba(40, 40, 40, 0.8));
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pokemon-type-badges {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
}

.type-badge-small {
    padding: 5px 14px;
    border-radius: 14px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pokemon-sprite-container {
    position: relative;
    width: 140px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.1));
    border-radius: 12px;
}

.pokemon-sprite-container img {
    max-width: 100%;
    max-height: 100%;
    image-rendering: pixelated;
}

.shiny-indicator {
    position: absolute;
    top: -8px;
    right: -8px;
    font-size: 2rem;
    animation: sparkle 1.5s ease-in-out infinite;
    filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.8));
}

@keyframes sparkle {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.2) rotate(180deg); }
}

.pokemon-hp-display {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid #FF5959;
    border-radius: 8px;
    padding: 6px 14px;
    font-size: 1.2rem;
    font-weight: 700;
    color: #fff;
}

.pokemon-title-section {
    padding: 15px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.pokemon-level-badge {
    display: inline-block;
    background: rgba(139, 92, 246, 0.2);
    border: 1px solid var(--secondary-color);
    border-radius: 6px;
    padding: 5px 12px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 8px;
}

.pokemon-name-display {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
    margin: 8px 0;
}

.pokemon-ability-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(241, 196, 15, 0.2);
    border: 1px solid rgba(241, 196, 15, 0.4);
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 0.9rem;
    color: #f1c40f;
}

.pokemon-moves-section {
    padding: 15px 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.move-item {
    background: rgba(20, 20, 20, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: all 0.2s ease;
}

.move-item:hover {
    background: rgba(30, 30, 30, 0.8);
    border-color: var(--primary-color);
}

.move-name-power {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.move-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #fff;
}

.move-power {
    font-size: 0.85rem;
    font-weight: 700;
    color: #aaa;
}

.pokemon-stats-section {
    padding: 15px 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

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

.stat-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #aaa;
    text-transform: lowercase;
}

.stat-value {
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    text-align: right;
}

.stat-bar-bg {
    height: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
}

.stat-bar {
    height: 100%;
    border-radius: 5px;
    transition: width 0.5s ease;
}

/* Type Colors */
.type-normal { background: #A8A878; color: #fff; }
.type-fire { background: #F08030; color: #fff; }
.type-water { background: #6890F0; color: #fff; }
.type-electric { background: #F8D030; color: #333; }
.type-grass { background: #78C850; color: #fff; }
.type-ice { background: #98D8D8; color: #333; }
.type-fighting { background: #C03028; color: #fff; }
.type-poison { background: #A040A0; color: #fff; }
.type-ground { background: #E0C068; color: #333; }
.type-flying { background: #A890F0; color: #fff; }
.type-psychic { background: #F85888; color: #fff; }
.type-bug { background: #A8B820; color: #fff; }
.type-rock { background: #B8A038; color: #fff; }
.type-ghost { background: #705898; color: #fff; }
.type-dragon { background: #7038F8; color: #fff; }
.type-dark { background: #705848; color: #fff; }
.type-steel { background: #B8B8D0; color: #333; }
.type-fairy { background: #EE99AC; color: #333; }
.type-champion { background: linear-gradient(135deg, #f39c12, #e74c3c); color: #fff; }

/* Responsive Design */
@media (max-width: 768px) {
    .page-title {
        font-size: 2rem;
    }

    .leader-header {
        flex-wrap: wrap;
        padding: 15px;
    }

    .leader-sprite {
        width: 60px;
        height: 60px;
    }

    .leader-team-preview {
        order: 4;
        width: 100%;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }

    .pokemon-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .pokemon-moves-section {
        grid-template-columns: 1fr;
    }

    .team-content {
        padding: 20px 10px;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
}
