body {
    background-color: #f8f9fa;
}

.logo {
    max-width: 200px;
}

.btn-primary {
    background-color: #00b050;
    border-color: #00b050;
}

.footer {
    background-color: #00b050 !important;
}

/* Miglioramenti per il banner */
.hero-image {
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.hero-image img {
    max-height: 300px;
    object-fit: cover;
    width: 100%;
}

.hero-overlay {
    position: relative;
}

.hero-overlay::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom, transparent, rgba(0,0,0,0.8));
    pointer-events: none;
}

.hero-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px 20px;
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
    line-height: 1.3;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    z-index: 1;
}

/* Stile per la sezione news in stile Hacker News */
.news-list {
    padding: 15px;
}

.news-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Riquadri affiancati */
.link-boxes {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.link-boxes .card {
    flex: 1;
    text-align: center;
}

.link-boxes img {
    max-width: 100%;
    height: auto;
}

/* Sezione cards */
.card-section {
    flex-direction: column;
    gap: 15px;
    padding: 15px;
}

.card {
    margin-bottom: 15px;
    width: 100%;
}

.card img {
    max-height: 200px;
    object-fit: cover;
}

/* Media queries */
@media (min-width: 768px) {
    .card-section {
        flex-direction: row;
    }

    .card {
        margin-bottom: 0;
    }

    .hero-title {
        font-size: 2.2rem;
        padding: 40px;
    }
}

/* Ottimizzazioni per schermi molto piccoli */
@media (max-width: 320px) {
    .hero-title {
        font-size: 1.2rem;
        padding: 15px;
    }
}

/* Stili per la pagina news */
.news-grid {
    display: grid;
    gap: 20px;
    margin-bottom: 30px;
}

.news-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 0.9rem;
}

.pagination .page-link {
    color: #333;
}

.pagination .active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
}

@media (min-width: 768px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .news-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Stili per la pagina games */
.games-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.game-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background-color: #fff;
    cursor: pointer;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.game-image-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* Aspect ratio 16:9 */
}

.game-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.game-content {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    text-align: center;
}

.game-title {
    margin-bottom: 0.5rem;
    color: #333;
}

.game-description {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 1rem;
}

.play-button {
    width: 100%;
    margin-top: auto;
    background-color: #28a745;
    border-color: #28a745;
}

.play-button:hover {
    background-color: #218838;
    border-color: #1e7e34;
}

.page-title {
    position: relative;
    padding-bottom: 15px;
    margin-bottom: 30px;
}

.page-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 3px;
    background: #0d6efd;
}

@media (max-width: 768px) {
    .games-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .games-grid {
        grid-template-columns: 1fr;
    }
}

.game-card a {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    height: 100%;
}

