/* ============================================================
   HOME.CSS - Stili per home page MokaByte
   MokaByte Template 2020
   ============================================================ */

/* Reset e base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #fff;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
}

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

.tagline {
    font-size: 0.85rem;
    color: #666;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: #333;
    margin: 5px 0;
}

.main-nav .menu {
    display: flex;
    list-style: none;
    gap: 1.5rem;
}

.main-nav a {
    font-size: 0.95rem;
    color: #333;
    transition: color 0.2s;
}

.main-nav a:hover {
    color: #2d6a4f;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
    position: relative;
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    overflow: hidden;
}

.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: -2;
}

.hero-overlay {
    display: none;
}

.hero-content {
    position: relative;
    text-align: center;
    max-width: 800px;
    z-index: 1;
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: #333;
}

.hero-title span {
    color: #2d6a4f;
}

.hero-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 2.5rem;
}

/* Search Box */
.hero-search {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.hero-search input {
    flex: 1;
    padding: 1rem 1.25rem;
    border: none;
    border-radius: 4px 0 0 4px;
    font-size: 1rem;
    font-family: inherit;
    outline: none;
}

.hero-search input:focus {
    box-shadow: 0 0 0 2px #5cb85c;
}

.hero-search button {
    padding: 1rem 1.5rem;
    background: #2d6a4f;
    color: #fff;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 1rem;
    font-family: inherit;
    transition: background 0.2s;
}

.hero-search button:hover {
    background: #1b4332;
}

/* ============================================================
   ULTIMO NUMERO
   ============================================================ */
.ultimo-numero {
    padding: 4rem 2rem;
    background: #f9f9f9;
    text-align: center;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.numero-header {
    text-align: center;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 0.5rem;
}

.numero-info {
    font-size: 1rem;
    color: #666;
}

.articoli-lista {
    list-style: none;
    margin-bottom: 2rem;
}

.articoli-lista li {
    border-bottom: 1px solid #e0e0e0;
}

.articoli-lista li:first-child {
    border-top: 1px solid #e0e0e0;
}

.articoli-lista a {
    display: block;
    padding: 1rem 0;
    color: #333;
    transition: color 0.2s;
}

.articoli-lista a:hover {
    color: #2d6a4f;
}

.btn-vedi-tutti {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: #2d6a4f;
    color: #fff;
    border-radius: 4px;
    font-size: 0.95rem;
    transition: background 0.2s;
}

.btn-vedi-tutti:hover {
    background: #1b4332;
}

/* ============================================================
   ARTICLES GRID & CARD
   ============================================================ */
.articles-grid {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2rem;
}

.article-card {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.article-card-image {
    flex-shrink: 0;
    width: 280px;
    height: 180px;
    border-radius: 6px;
    overflow: hidden;
}

.article-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.article-card-meta {
    margin-bottom: 0.75rem;
}

.article-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.article-card-tags .tag {
    color: #2d6a4f;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color 0.2s;
}

.article-card-tags .tag:hover {
    color: #1b4332;
}

.article-card-title {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.article-card-title a {
    color: #222;
    transition: color 0.2s;
}

.article-card-title a:hover {
    color: #2d6a4f;
}

.article-card-subtitle {
    font-size: 1.05rem;
    color: #555;
    margin-bottom: 0.75rem;
    font-weight: 500;
}

.article-card-abstract {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.7;
    flex: 1;
}

.article-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f0f0f0;
}

.article-card-footer .author {
    font-size: 0.9rem;
    color: #888;
}

.article-card-footer .author:hover {
    color: #2d6a4f;
}

.read-more {
    font-size: 0.9rem;
    color: #2d6a4f;
    font-weight: 600;
    transition: color 0.2s;
}

.read-more:hover {
    color: #1b4332;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
    .tagline {
        display: none;
    }

    .menu-toggle {
        display: block;
    }

    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid #e0e0e0;
        padding: 1rem 2rem;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav .menu {
        flex-direction: column;
        gap: 0;
    }

    .main-nav .menu li {
        border-bottom: 1px solid #f0f0f0;
    }

    .main-nav .menu a {
        display: block;
        padding: 0.75rem 0;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-text {
        font-size: 1rem;
    }

    .hero-search {
        flex-direction: column;
    }

    .hero-search input {
        border-radius: 4px;
        margin-bottom: 0.5rem;
    }

    .hero-search button {
        border-radius: 4px;
    }

    .article-card {
        flex-direction: column;
    }

    .article-card-image {
        width: 100%;
        height: 200px;
    }

    .article-card-title {
        font-size: 1.2rem;
    }
}
