:root {
    --main-green: #61FF86;
    --dark-green: #2d8a4a;
    --light-green: #e8fff0;
    --shadow: 0 4px 6px rgba(0,0,0,0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f5f5;
    color: #333;
}

/* Header */
header {
    background: linear-gradient(135deg, #1a4a2a, #61FF86);
    padding: 20px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-container img {
    height: 60px;
    width: auto;
}

.logo-text {
    color: white;
}

.logo-text h1 {
    font-size: 32px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    letter-spacing: 1px;
}

.logo-text .slogan {
    font-size: 14px;
    opacity: 0.9;
    font-style: italic;
}

/* Menú de navegación */
nav {
    background: white;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav ul {
    max-width: 1200px;
    margin: 0 auto;
    list-style: none;
    display: flex;
    gap: 0;
    padding: 0 20px;
}

nav ul li {
    flex: 1;
}

nav ul li a {
    display: block;
    padding: 15px 20px;
    text-decoration: none;
    color: #333;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
}

nav ul li a:hover,
nav ul li a.active {
    background: var(--light-green);
    border-bottom-color: var(--main-green);
    color: var(--dark-green);
}

/* Contenido principal */
.container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 20px;
}

/* Noticia principal */
.main-news {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.main-news:hover {
    transform: translateY(-5px);
}

.main-news img {
    width: 100%;
    height: 400px;
    object-fit: cover;
}

.main-news .news-content {
    padding: 25px;
}

.main-news h2 {
    font-size: 28px;
    color: #1a4a2a;
    margin-bottom: 10px;
}

.main-news .meta {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.main-news .excerpt {
    font-size: 16px;
    line-height: 1.6;
    color: #555;
}

/* Grid de noticias */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 20px;
}

.news-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.news-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-card .card-content {
    padding: 20px;
}

.news-card h3 {
    font-size: 18px;
    color: #1a4a2a;
    margin-bottom: 10px;
    line-height: 1.4;
}

.news-card .meta {
    color: #666;
    font-size: 13px;
    margin-bottom: 10px;
}

.news-card .excerpt {
    font-size: 14px;
    line-height: 1.5;
    color: #555;
}

.news-card .category-badge {
    display: inline-block;
    background: var(--main-green);
    color: #1a4a2a;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-top: 10px;
}

/* Botones */
.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--main-green);
    color: #1a4a2a;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: var(--dark-green);
    color: white;
    transform: translateY(-2px);
}

.btn-admin {
    background: #1a4a2a;
    color: white;
}

.btn-admin:hover {
    background: #2d8a4a;
}

/* Página de detalle de noticia */
.detail-news {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: var(--shadow);
}

.detail-news h1 {
    font-size: 36px;
    color: #1a4a2a;
    margin-bottom: 15px;
    line-height: 1.3;
}

.detail-news .meta {
    color: #666;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--light-green);
}

.detail-news img {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 30px;
}

.detail-news .content {
    font-size: 18px;
    line-height: 1.8;
    color: #444;
}

.detail-news .category-tag {
    display: inline-block;
    background: var(--main-green);
    padding: 5px 20px;
    border-radius: 20px;
    font-weight: 600;
    color: #1a4a2a;
    margin-bottom: 20px;
}

/* Admin */
.admin-container {
    max-width: 800px;
    margin: 50px auto;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.admin-container h2 {
    color: #1a4a2a;
    margin-bottom: 30px;
    text-align: center;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--main-green);
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.login-box {
    max-width: 400px;
    margin: 100px auto;
    padding: 40px;
    background: white;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.login-box h2 {
    color: #1a4a2a;
    text-align: center;
    margin-bottom: 30px;
}

/* Footer */
footer {
    background: #1a4a2a;
    color: white;
    text-align: center;
    padding: 30px 20px;
    margin-top: 60px;
}

footer .footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        text-align: center;
    }
    
    .logo-container {
        flex-direction: column;
    }
    
    .logo-container img {
        height: 50px;
    }
    
    .logo-text h1 {
        font-size: 24px;
    }
    
    nav ul {
        flex-direction: column;
    }
    
    nav ul li a {
        padding: 12px;
    }
    
    .main-news img {
        height: 250px;
    }
    
    .main-news h2 {
        font-size: 22px;
    }
    
    .news-grid {
        grid-template-columns: 1fr;
    }
    
    .detail-news {
        padding: 20px;
    }
    
    .detail-news h1 {
        font-size: 28px;
    }
    
    .admin-container {
        padding: 20px;
        margin: 20px;
    }
}

/* Utilidades */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.success-message {
    background: #d4edda;
    color: #155724;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
    border-left: 4px solid #28a745;
}

.error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
    border-left: 4px solid #dc3545;
}