/*
Theme Name: Deportes Hoy
Theme URI: https://deporteshoy.com
Author: Deportes Hoy Team
Author URI: https://deporteshoy.com
Description: Tema de WordPress para portal de noticias deportivas con panel de administración personalizado
Version: 1.0.0
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: deportes-hoy
Domain Path: /languages
*/

/* Reset y Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

/* Header */
.dh-header {
    background: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.dh-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.dh-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.dh-logo-icon {
    background: #dc2626;
    color: white;
    width: 45px;
    height: 45px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dh-logo-text h1 {
    font-size: 1.5rem;
    color: #1a1a1a;
    margin: 0;
}

.dh-logo-text span {
    font-size: 0.75rem;
    color: #666;
}

/* Navegación */
.dh-nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

.dh-nav a {
    text-decoration: none;
    color: #555;
    font-weight: 500;
    transition: color 0.3s;
}

.dh-nav a:hover,
.dh-nav a.active {
    color: #dc2626;
}

/* Botones Header */
.dh-header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.dh-search-form {
    display: flex;
    align-items: center;
}

.dh-search-form input {
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 20px 0 0 20px;
    width: 200px;
    outline: none;
}

.dh-search-form button {
    background: #dc2626;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 0 20px 20px 0;
    cursor: pointer;
}

.dh-btn {
    padding: 10px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.dh-btn-primary {
    background: #dc2626;
    color: white;
}

.dh-btn-primary:hover {
    background: #b91c1c;
}

.dh-btn-outline {
    background: transparent;
    color: #555;
    border: 1px solid #ddd;
}

.dh-btn-outline:hover {
    background: #f5f5f5;
}

/* Contenedor Principal */
.dh-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Filtros de Categoría */
.dh-category-filter {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.dh-category-filter a {
    padding: 8px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s;
    background: white;
    color: #555;
    border: 1px solid #e0e0e0;
}

.dh-category-filter a:hover,
.dh-category-filter a.active {
    background: #dc2626;
    color: white;
    border-color: #dc2626;
}

/* Secciones */
.dh-section {
    margin-bottom: 50px;
}

.dh-section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
}

.dh-section-header h2 {
    font-size: 1.5rem;
    color: #1a1a1a;
}

.dh-section-header svg {
    color: #dc2626;
}

/* Grid de Noticias */
.dh-news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
}

.dh-news-grid-featured {
    grid-template-columns: repeat(2, 1fr);
}

/* Tarjeta de Noticia */
.dh-news-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.dh-news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.dh-news-card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.dh-news-card-featured .dh-news-card-image {
    height: 280px;
}

.dh-news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.dh-news-card:hover .dh-news-card-image img {
    transform: scale(1.05);
}

.dh-news-card-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background: #dc2626;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.dh-news-card-content {
    padding: 20px;
}

.dh-news-card h3 {
    font-size: 1.1rem;
    margin-bottom: 10px;
    line-height: 1.4;
    color: #1a1a1a;
}

.dh-news-card-featured h3 {
    font-size: 1.3rem;
}

.dh-news-card p {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 15px;
}

.dh-news-card-meta {
    display: flex;
    gap: 15px;
    font-size: 0.8rem;
    color: #888;
}

.dh-news-card-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Single Post */
.dh-single-header {
    background: white;
    padding: 40px 0;
    margin-bottom: 30px;
}

.dh-single-category {
    display: inline-block;
    background: #dc2626;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    margin-bottom: 15px;
    text-decoration: none;
}

.dh-single-title {
    font-size: 2.5rem;
    color: #1a1a1a;
    margin-bottom: 20px;
    line-height: 1.2;
}

.dh-single-meta {
    display: flex;
    gap: 20px;
    color: #666;
    font-size: 0.9rem;
}

.dh-single-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 30px;
}

.dh-single-content {
    background: white;
    padding: 40px;
    border-radius: 12px;
    font-size: 1.1rem;
    line-height: 1.8;
}

.dh-single-content p {
    margin-bottom: 20px;
}

/* Footer */
.dh-footer {
    background: #1a1a1a;
    color: white;
    padding: 50px 0 20px;
    margin-top: 50px;
}

.dh-footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
}

.dh-footer h3 {
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.dh-footer p {
    color: #aaa;
    line-height: 1.6;
}

.dh-footer ul {
    list-style: none;
}

.dh-footer ul li {
    margin-bottom: 10px;
}

.dh-footer a {
    color: #aaa;
    text-decoration: none;
    transition: color 0.3s;
}

.dh-footer a:hover {
    color: white;
}

.dh-footer-bottom {
    border-top: 1px solid #333;
    margin-top: 30px;
    padding-top: 20px;
    text-align: center;
    color: #666;
    font-size: 0.9rem;
}

/* Panel Admin Personalizado */
.dh-admin-bar {
    background: #1a1a1a;
    color: white;
    padding: 10px 0;
}

.dh-admin-bar-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dh-admin-bar a {
    color: white;
    text-decoration: none;
    padding: 5px 15px;
    border-radius: 5px;
    transition: background 0.3s;
}

.dh-admin-bar a:hover {
    background: #dc2626;
}

/* Formularios */
.dh-form-group {
    margin-bottom: 20px;
}

.dh-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.dh-form-group input,
.dh-form-group textarea,
.dh-form-group select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.dh-form-group input:focus,
.dh-form-group textarea:focus,
.dh-form-group select:focus {
    outline: none;
    border-color: #dc2626;
}

.dh-form-group textarea {
    min-height: 150px;
    resize: vertical;
}

/* Mensajes */
.dh-alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.dh-alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.dh-alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Tabla Admin */
.dh-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
}

.dh-table th,
.dh-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.dh-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #555;
}

.dh-table tr:hover {
    background: #f8f9fa;
}

.dh-table-actions {
    display: flex;
    gap: 10px;
}

.dh-btn-sm {
    padding: 6px 12px;
    font-size: 0.85rem;
}

.dh-btn-danger {
    background: #dc2626;
    color: white;
}

.dh-btn-danger:hover {
    background: #b91c1c;
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 30px;
}

.pagination a,
.pagination span {
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
}

.pagination a {
    background: white;
    color: #555;
    border: 1px solid #ddd;
}

.pagination a:hover {
    background: #f5f5f5;
    color: #dc2626;
}

.pagination .current {
    background: #dc2626;
    color: white;
}

.pagination .dots {
    background: transparent;
    border: none;
}

/* Widgets */
.dh-widget {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.dh-widget-title {
    font-size: 1.1rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #dc2626;
}

.dh-widget-list {
    list-style: none;
    padding: 0;
}

.dh-widget-list li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.dh-widget-list li:last-child {
    border-bottom: none;
}

.dh-widget-list a {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    transition: color 0.3s;
}

.dh-widget-list a:hover {
    color: #dc2626;
}

/* Responsive */
@media (max-width: 768px) {
    .dh-header-inner {
        flex-wrap: wrap;
        height: auto;
        padding: 15px 20px;
    }
    
    .dh-nav {
        display: none;
    }
    
    .dh-news-grid {
        grid-template-columns: 1fr;
    }
    
    .dh-news-grid-featured {
        grid-template-columns: 1fr;
    }
    
    .dh-footer-inner {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .dh-single-title {
        font-size: 1.8rem;
    }
    
    .dh-single-content {
        padding: 20px;
    }
    
    .dh-social-links {
        justify-content: center;
    }
    
    .dh-category-filter {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 10px;
    }
    
    .dh-category-filter a {
        white-space: nowrap;
    }
}
