/* Video Game Club Custom Styles */

.notice {
    background: var(--pico-ins-color);
    color: white;
    padding: 1rem;
    border-radius: var(--pico-border-radius);
    margin: 1rem 0;
}

.error {
    background: var(--pico-del-color);
    color: white;
    padding: 1rem;
    border-radius: var(--pico-border-radius);
    margin: 1rem 0;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.stat-card {
    text-align: center;
    padding: 1.5rem;
    background: var(--pico-card-background-color);
    border-radius: var(--pico-border-radius);
    border: 1px solid var(--pico-muted-border-color);
}

.stat-card h3 {
    font-size: 2.5rem;
    margin: 0;
    color: var(--pico-primary);
}

.stat-card p {
    margin: 0.5rem 0 0;
    color: var(--pico-muted-color);
}

/* Actions */
.actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 2rem 0;
}

/* Game Grid */
.game-grid, .search-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

/* Search Result Cards */
.search-result-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 0;
    overflow: hidden;
}

.search-result-card img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    flex-shrink: 0;
}

.search-result-card .no-image {
    width: 100%;
    height: 120px;
    background: var(--pico-muted-border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pico-muted-color);
    font-size: 0.9rem;
    flex-shrink: 0;
}

.search-result-card .card-content {
    flex: 1;
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    min-height: 80px;
}

.search-result-card .game-title {
    font-size: 0.95rem;
    margin: 0 0 0.5rem 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.search-result-card .game-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    margin-top: auto;
}

.search-result-card footer {
    padding: 0.75rem;
    margin-top: auto;
    border-top: 1px solid var(--pico-muted-border-color);
}

.search-result-card footer form {
    margin: 0;
}

.search-result-card .nominate-btn {
    width: 100%;
    margin: 0;
    padding: 0.5rem;
    font-size: 0.85rem;
}

/* Nominated state */
.search-result-card footer .notice {
    margin: 0;
    padding: 0.5rem;
    font-size: 0.85rem;
    text-align: center;
}

.search-result-card footer .error {
    margin: 0;
    padding: 0.5rem;
    font-size: 0.85rem;
    text-align: center;
}

/* Game Cards (vote page) */
.game-card {
    overflow: hidden;
}

.game-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.game-card header {
    padding: 0.5rem 0;
}

.game-card h3 {
    margin: 0;
    font-size: 1.1rem;
}

/* Badge */
.badge {
    display: inline-block;
    background: var(--pico-secondary-background);
    color: var(--pico-secondary-inverse);
    padding: 0.15rem 0.4rem;
    border-radius: var(--pico-border-radius);
    font-size: 0.75rem;
}

/* Genres */
.genres {
    font-size: 0.9rem;
    color: var(--pico-muted-color);
}

/* Winner Card */
.winner-card {
    text-align: center;
    padding: 2rem;
    background: linear-gradient(135deg, var(--pico-primary-background), var(--pico-secondary-background));
    border-radius: var(--pico-border-radius);
}

.winner-card img {
    max-width: 400px;
    width: 100%;
    border-radius: var(--pico-border-radius);
    margin: 1rem 0;
}

/* Vote Selections */
.vote-selections {
    display: grid;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* History */
.history-month {
    margin-bottom: 2rem;
}

.winner-banner {
    background: var(--pico-card-background-color);
    padding: 1rem;
    border-radius: var(--pico-border-radius);
    margin-bottom: 1rem;
}

.winner-image {
    max-width: 300px;
    width: 100%;
    border-radius: var(--pico-border-radius);
}

/* HTMX Indicator */
.htmx-indicator {
    display: none;
    color: var(--pico-muted-color);
}

.htmx-request .htmx-indicator,
.htmx-request.htmx-indicator {
    display: inline;
}

/* Game Details Cards (Vote Page) */
.game-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.game-details-card {
    border: 1px solid var(--pico-muted-border-color);
    border-radius: var(--pico-border-radius);
    overflow: hidden;
    background: var(--pico-card-background-color);
}

.game-summary {
    cursor: pointer;
    list-style: none;
    padding: 0;
}

.game-summary::-webkit-details-marker {
    display: none;
}

.game-summary-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
}

.game-thumb {
    width: 80px;
    height: 60px;
    object-fit: cover;
    border-radius: var(--pico-border-radius);
    flex-shrink: 0;
}

.game-thumb.no-image {
    background: var(--pico-muted-border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    color: var(--pico-muted-color);
}

.game-summary-info {
    flex: 1;
    min-width: 0;
}

.game-summary-info h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
}

.game-quick-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.game-points {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0 1rem;
    min-width: 60px;
}

.points-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--pico-primary);
    line-height: 1;
}

.points-label {
    font-size: 0.75rem;
    color: var(--pico-muted-color);
    text-transform: uppercase;
}

.game-details-card[open] .game-summary {
    border-bottom: 1px solid var(--pico-muted-border-color);
}

.game-full-details {
    padding: 1rem;
}

.game-hero {
    width: 100%;
    max-height: 300px;
    object-fit: cover;
    border-radius: var(--pico-border-radius);
    margin-bottom: 1rem;
}

.game-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.info-section h4 {
    margin: 0 0 0.25rem 0;
    font-size: 0.85rem;
    color: var(--pico-muted-color);
    font-weight: normal;
}

.info-section p {
    margin: 0;
    font-size: 1rem;
}

.metacritic-score {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--pico-primary);
}

.store-links {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--pico-muted-border-color);
}

.store-links h4 {
    margin: 0 0 0.75rem 0;
    font-size: 0.9rem;
}

.store-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.store-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: #2a2a2a;
    color: #fff;
    text-decoration: none;
    border-radius: var(--pico-border-radius);
    font-size: 0.85rem;
    font-weight: 500;
    transition: background-color 0.2s, transform 0.1s;
    min-width: 120px;
    justify-content: center;
}

.store-btn:hover {
    transform: translateY(-1px);
    color: #fff;
}

/* Store-specific colors */
.store-btn[href*="steampowered"],
.store-btn[href*="steam"] {
    background: #1b2838;
}
.store-btn[href*="steampowered"]:hover,
.store-btn[href*="steam"]:hover {
    background: #2a475e;
}

.store-btn[href*="playstation"] {
    background: #003791;
}
.store-btn[href*="playstation"]:hover {
    background: #0050c7;
}

.store-btn[href*="xbox"],
.store-btn[href*="microsoft"] {
    background: #107c10;
}
.store-btn[href*="xbox"]:hover,
.store-btn[href*="microsoft"]:hover {
    background: #1a9f1a;
}

.store-btn[href*="nintendo"] {
    background: #e60012;
}
.store-btn[href*="nintendo"]:hover {
    background: #ff1a2b;
}

.store-btn[href*="gog"] {
    background: #86328a;
}
.store-btn[href*="gog"]:hover {
    background: #a33fa8;
}

.store-btn[href*="epicgames"] {
    background: #313131;
}
.store-btn[href*="epicgames"]:hover {
    background: #444;
}

.store-btn[href*="itch.io"] {
    background: #fa5c5c;
}
.store-btn[href*="itch.io"]:hover {
    background: #ff7a7a;
}

.badge-score {
    background: var(--pico-primary);
    color: var(--pico-primary-inverse);
}

.muted {
    color: var(--pico-muted-color);
    font-size: 0.9rem;
}

/* Footer */
footer.container {
    text-align: center;
    padding: 2rem 0;
    margin-top: 2rem;
    border-top: 1px solid var(--pico-muted-border-color);
}
