/* Global Styles */
:root {
    --dota-black: #121212;
    --dota-dark-grey: #1e1e1e;
    --dota-red: #a30000;
    --dota-red-bright: #ff4500;
    --dota-text: #cccccc;
    --dota-border: #333;
    --dota-glow: 0 0 10px rgba(163, 0, 0, 0.5);
}

* {
    box-sizing: border-box;
}

body {
    background-color: var(--dota-black);
    color: var(--dota-text);
    font-family: "Microsoft YaHei", "Segoe UI", sans-serif;
    margin: 0;
    padding: 0;
    background-image: url('https://cdn.steamstatic.com/apps/dota2/images/dota_react//home/radiant_dire5.jpg');
    background-size: cover;
    background-attachment: fixed;
    background-position: center;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: -1;
}

a {
    color: var(--dota-text);
    text-decoration: none;
    transition: color 0.3s;
}

a:hover {
    color: var(--dota-red-bright);
}

/* Header */
header {
    background: rgba(0, 0, 0, 0.95);
    border-bottom: 2px solid var(--dota-red);
    padding: 10px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

.container {
    width: 1200px;
    margin: 0 auto;
    max-width: 95%;
    position: relative;
}

/* Navigation */
.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-img {
    height: 40px;
    width: auto;
}

.logo-text {
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.mobile-menu-btn {
    display: none;
    font-size: 24px;
    cursor: pointer;
    color: #fff;
    background: none;
    border: none;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    gap: 30px;
}

nav ul li a {
    font-size: 16px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 8px; /* For Icon */
}

nav ul li a.active, nav ul li a:hover {
    color: var(--dota-red-bright);
    text-shadow: var(--dota-glow);
}

/* Filters (Hero List) */
.filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px 0 30px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 20px;
    background: #25282c;
    border: 1px solid #444;
    color: #aaa;
    border-radius: 4px;
    transition: all 0.3s;
    font-weight: bold;
}
.filter-btn:hover, .filter-btn.active {
    background: var(--dota-red);
    color: #fff;
    border-color: var(--dota-red-bright);
    box-shadow: 0 0 10px rgba(163,0,0,0.5);
}

/* Banner */
.banner {
    position: relative;
    height: 400px; /* Reduced height for mobile */
    background-image: url('https://cdn.steamstatic.com/apps/dota2/images/dota_react//home/radiant_dire5.jpg'); /* Use same as bg or specific banner */
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border-bottom: 2px solid var(--dota-red);
    margin-bottom: 40px;
}

.banner::before {
    content: "";
    position: absolute;
    top:0; left:0; width:100%; height:100%;
    background: rgba(0,0,0,0.5);
}

.banner-content {
    position: relative;
    z-index: 1;
    padding: 20px;
}

.banner h1 {
    font-size: 3em; /* Responsive font size */
    color: #fff;
    text-shadow: 0 0 20px #ff4500;
    margin: 0 0 10px 0;
    border: none;
}

.banner h2 {
    font-size: 1.5em;
    color: #ddd;
    font-weight: normal;
    text-transform: none;
    margin: 0;
    border: none;
}

/* Intro Section */
.intro-section {
    background: rgba(20, 20, 20, 0.9);
    padding: 30px;
    border: 1px solid #444;
    margin-bottom: 40px;
    text-align: center;
    line-height: 1.8;
    color: #ccc;
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
}

/* Main Content */
main {
    padding-bottom: 40px;
    min-height: 60vh;
}

h1, h2, h3 {
    color: #fff;
    text-transform: uppercase;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--dota-red);
    display: inline-block;
    padding-bottom: 5px;
}
h2 i, h3 i { margin-right: 10px; color: var(--dota-red-bright); }

/* Grid */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); /* Adaptive */
    gap: 15px;
}

.card {
    background: rgba(30, 30, 30, 0.8);
    border: 1px solid var(--dota-border);
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
    position: relative;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--dota-glow);
    border-color: var(--dota-red);
}

.card img {
    width: 100%;
    height: auto;
    display: block;
}

.card-info {
    padding: 10px;
    text-align: center;
}

.card-name {
    font-weight: bold;
    color: #fff;
    font-size: 14px;
    margin-bottom: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-price {
    color: #ffd700;
    font-size: 13px;
}

/* Detail Page */
.detail-container {
    background: rgba(30, 30, 30, 0.9);
    padding: 30px;
    border: 1px solid var(--dota-border);
    display: flex;
    flex-direction: row; /* Default row */
    gap: 30px;
}

.detail-left {
    flex: 0 0 300px;
    max-width: 100%;
    text-align: center;
}

.detail-img {
    width: 100%;
    border: 2px solid #000;
    box-shadow: 0 0 20px rgba(0,0,0,0.8);
}

.detail-right {
    flex: 1;
}

/* Stats & Skills */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
    background: rgba(0,0,0,0.3);
    padding: 15px;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.skill-card {
    text-align: center;
    background: rgba(0,0,0,0.5);
    padding: 10px;
    border: 1px solid #333;
}

.skill-card img {
    width: 100%;
    max-width: 80px;
    border-radius: 4px;
    margin-bottom: 5px;
}

/* Sidebar Btns */
.sidebar-btns {
    position: fixed;
    right: 20px;
    bottom: 40px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 999;
}

.sidebar-btn {
    background: var(--dota-red);
    color: #fff;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0,0,0,0.5);
    transition: all 0.3s;
    opacity: 0.7;
}

.sidebar-btn:hover {
    transform: scale(1.1);
    opacity: 1;
}

/* Footer */
footer {
    background: #000;
    color: #666;
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
    border-top: 2px solid var(--dota-red);
}

/* Responsive Media Queries */
@media (max-width: 768px) {
    .nav-wrapper {
        flex-wrap: wrap;
    }
    
    .mobile-menu-btn {
        display: block;
    }
    
    nav {
        width: 100%;
        display: none; /* Hidden by default on mobile */
        margin-top: 15px;
        background: rgba(0,0,0,0.95);
        position: absolute;
        top: 60px;
        left: 0;
        padding: 20px;
        border-bottom: 2px solid var(--dota-red);
    }
    
    nav.active {
        display: block;
    }
    
    nav ul {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
    
    .banner {
        height: 250px;
    }
    
    .banner h1 {
        font-size: 2em;
    }
    
    .detail-container {
        flex-direction: column;
        padding: 15px;
    }
    
    .detail-left {
        flex: 1;
        width: 100%;
        margin: 0 auto;
    }
    
    .grid {
        grid-template-columns: repeat(3, 1fr); /* Mobile: 3 cols */
    }
    @media (max-width: 480px) {
        .grid {
            grid-template-columns: repeat(2, 1fr); /* Small Mobile: 2 cols */
        }
    }
}
