/* assets/css/styles.css */
/* 
 * Premium Editorial Design 
 * Colors: Bone (#EFEFEF), Oxford (#1A1A1A), Brick Red (#8B0000)
 */

:root {
    --bg-color: #EFEFEF;
    --text-main: #1A1A1A;
    --text-muted: #555555;
    --accent: #8B0000;
    --divider: #333333;
    
    --font-heading: 'Georgia', 'Garamond', serif;
    --font-body: 'Arial', 'Inter', sans-serif;
}

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

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: normal;
    color: var(--text-main);
}

a {
    color: var(--text-main);
    text-decoration: none;
}

a:hover {
    color: var(--accent);
}

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

/* Masthead / Header */
header.main-header {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: var(--bg-color);
    border-bottom: 1px solid var(--divider);
    transition: all 0.3s ease;
    padding: 20px 0;
    text-align: center;
}

.logo-placeholder {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: bold;
    letter-spacing: -1px;
    text-transform: uppercase;
    display: inline-block;
    padding: 10px 20px;
    border: 1px solid var(--text-main);
}

.nav-container {
    border-top: 1px solid var(--divider);
    border-bottom: 1px solid var(--divider);
    padding: 10px 0;
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 30px;
}

.nav-container a {
    text-transform: uppercase;
    font-size: 0.85rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.nav-container a:hover {
    color: var(--accent);
}

/* Hamburger Menu (Mobile) */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    position: absolute;
    top: 30px;
    right: 20px;
}

/* Grid System */
.grid-container {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

.grid-item {
    grid-column: span 2;
    border-top: 1px solid var(--divider);
    padding-top: 15px;
}

/* Symmetrical Grid Rules (Anti-Orphans) */
/* When there are exactly 4 items, 4th item centers */
.grid-container.count-4 .grid-item:nth-child(4) {
    grid-column: 3 / span 2;
}

/* When there are exactly 5 items, 4th and 5th items center */
.grid-container.count-5 .grid-item:nth-child(4) {
    grid-column: 2 / span 2;
}
.grid-container.count-5 .grid-item:nth-child(5) {
    grid-column: 4 / span 2;
}

/* Cards & Micro-interactions */
.card-premium {
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.4s ease;
    overflow: hidden;
    background: #fff;
    border: 1px solid #ddd;
    display: block;
    height: 100%;
}

.card-premium:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.card-premium .img-container {
    overflow: hidden;
    aspect-ratio: 16/9;
}

.card-premium img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.card-premium:hover img {
    transform: scale(1.08);
}

.card-content {
    padding: 15px;
}

.card-category {
    color: var(--accent);
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: bold;
    margin-bottom: 8px;
    display: block;
}

.card-title {
    font-size: 1.2rem;
    line-height: 1.3;
    margin-bottom: 10px;
}

.card-excerpt {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Front Page Specific Layout */
.main-news {
    margin-bottom: 40px;
    border-bottom: 2px solid var(--divider);
    padding-bottom: 40px;
}

.main-news img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    margin-bottom: 20px;
}

.main-news h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    text-align: center;
}

.main-news p {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    color: var(--text-muted);
}

/* Responsive Rules */
@media (max-width: 768px) {
    header.main-header { padding: 10px 16px; }
    
    .nav-container {
        display: none; /* Hide default nav */
        flex-direction: column;
        gap: 15px;
        padding: 20px;
    }
    
    .nav-container.active {
        display: flex; /* Show when toggled */
    }

    .mobile-menu-toggle {
        display: block;
    }

    .grid-item {
        grid-column: span 6 !important; /* Stack everything on mobile */
    }

    .main-news h2 {
        font-size: 1.8rem;
    }
}
