/* Variables globales */
:root {
    --primary-color: #3498db;
    --primary-dark: #2980b9;
    --secondary-color: #e74c3c;
    --text-color: #333;
    --text-light: #777;
    --bg-color: #fff;
    --bg-light: #f5f7fa;
    --bg-dark: #2c3e50;
    --border-color: #ddd;
    --border-radius: 8px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
    --section-padding: 80px 0;
    --container-width: 1200px;
    --header-height: 80px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--bg-color);
}

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

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

a:hover {
    color: var(--primary-dark);
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 15px;
    transition: var(--transition);
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

p {
    margin-bottom: 20px;
}

button, .btn {
    cursor: pointer;
    font-family: inherit;
    font-weight: 600;
    transition: var(--transition);
}

ul {
    list-style-type: none;
}

/* Contenedor */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

/* Header y navegación */
header {
    background-color: var(--bg-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    height: var(--header-height);
    display: flex;
    align-items: center;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

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

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

nav ul {
    display: flex;
}

nav ul li {
    margin-left: 30px;
}

nav ul li a {
    color: var(--text-color);
    font-weight: 600;
    position: relative;
    padding: 10px 0;
}

nav ul li a:hover {
    color: var(--primary-color);
}

nav ul li a.active {
    color: var(--primary-color);
}

nav ul li a.active::after,
nav ul li a:hover::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
}

/* Botones */
.btn {
    display: inline-block;
    background-color: var(--primary-color);
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1rem;
    text-align: center;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.btn:hover {
    background-color: var(--primary-dark);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Hero section */
.hero {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('images/1.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 150px 0;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto 30px;
}

/* Página de cabecera (para blog, contacto, etc.) */
.page-header {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('images/3.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 100px 0;
}

.page-header h1 {
    font-size: 2.8rem;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.page-header p {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Sección de artículos destacados */
.featured-posts {
    padding: var(--section-padding);
    background-color: var(--bg-light);
}

.featured-posts h2 {
    text-align: center;
    margin-bottom: 40px;
}

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.post-card {
    background-color: var(--bg-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.post-image {
    height: 220px;
    overflow: hidden;
}

.post-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.post-content {
    padding: 20px;
}

.post-content h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.post-content h3 a {
    color: var(--text-color);
}

.post-content h3 a:hover {
    color: var(--primary-color);
}

.post-date {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 15px;
    display: block;
}

.read-more {
    display: inline-flex;
    align-items: center;
    font-weight: 600;
    margin-top: 10px;
}

.read-more i {
    margin-left: 5px;
    transition: transform 0.3s ease;
}

.read-more:hover i {
    transform: translateX(3px);
}

.view-all {
    text-align: center;
    margin-top: 40px;
}

/* Suscripción al boletín */
.newsletter {
    padding: 60px 0;
    background-color: var(--bg-dark);
    color: white;
    text-align: center;
}

.newsletter h2 {
    margin-bottom: 15px;
}

.newsletter p {
    max-width: 600px;
    margin: 0 auto 25px;
    opacity: 0.9;
}

.newsletter form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter input {
    flex-grow: 1;
    padding: 12px 15px;
    border: none;
    border-radius: var(--border-radius) 0 0 var(--border-radius);
    font-size: 1rem;
}

.newsletter button {
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

/* Footer */
footer {
    background-color: #1a2530;
    color: white;
    padding: 70px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.footer-info {
    margin-bottom: 20px;
}

.footer-logo {
    height: 60px;
    width: auto;
    margin-bottom: 15px;
}

.footer-info p {
    opacity: 0.8;
    margin-bottom: 20px;
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
}

.social-icons a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.footer-links h3,
.footer-contact h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: white;
}

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

.footer-links ul li a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
}

.footer-links ul li a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-contact p {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    color: rgba(255, 255, 255, 0.8);
}

.footer-contact p i {
    margin-right: 10px;
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 40px;
    margin-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
}

/* Página de blog */
.blog-content {
    padding: var(--section-padding);
}

/* Página de artículo individual */
.post-header {
    padding: 100px 0 50px;
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('images/2.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
}

.post-meta {
    display: flex;
    justify-content: center;
    gap: 20px;
    font-size: 0.95rem;
}

.post-meta span {
    display: flex;
    align-items: center;
}

.post-meta i {
    margin-right: 5px;
    color: var(--primary-color);
}

.post-content {
    padding: 60px 0;
}

.post-featured-image {
    margin-bottom: 40px;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.post-featured-image img {
    width: 100%;
    height: auto;
}

article h2 {
    font-size: 1.8rem;
    margin: 40px 0 20px;
    color: #2c3e50;
}

article h3 {
    font-size: 1.4rem;
    margin: 30px 0 15px;
    color: #34495e;
}

article p {
    margin-bottom: 20px;
    font-size: 1.05rem;
    line-height: 1.7;
}

article ul, article ol {
    margin: 20px 0 20px 20px;
}

article li {
    margin-bottom: 10px;
}

.post-quote {
    margin: 30px 0;
    padding: 30px;
    background-color: var(--bg-light);
    border-left: 5px solid var(--primary-color);
    border-radius: var(--border-radius);
}

.post-quote blockquote {
    font-style: italic;
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 10px;
}

.post-quote cite {
    display: block;
    font-weight: 600;
    text-align: right;
    color: var(--text-light);
}

.post-tags {
    margin: 40px 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.post-tags span {
    font-weight: 600;
}

.post-tags a {
    display: inline-block;
    background-color: var(--bg-light);
    padding: 5px 12px;
    border-radius: 30px;
    font-size: 0.9rem;
    color: var(--text-light);
    transition: var(--transition);
}

.post-tags a:hover {
    background-color: var(--primary-color);
    color: white;
}

.post-navigation {
    display: flex;
    justify-content: space-between;
    margin: 50px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: 20px 0;
}

.nav-previous a, .nav-next a {
    display: flex;
    align-items: center;
    font-weight: 600;
}

.nav-previous i {
    margin-right: 8px;
}

.nav-next i {
    margin-left: 8px;
}

.related-posts {
    margin-top: 60px;
}

.related-posts h3 {
    text-align: center;
    margin-bottom: 30px;
}

.related-posts .posts-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.related-posts .post-card {
    display: flex;
    flex-direction: column;
}

.related-posts .post-image {
    height: 180px;
}

.related-posts h4 {
    font-size: 1.1rem;
    margin-bottom: 10px;
}

/* Página de contacto */
.contact-content {
    padding: var(--section-padding);
}

.contact-flex {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    margin-bottom: 60px;
}

.contact-info h2, .contact-form h2 {
    margin-bottom: 25px;
}

.contact-details {
    margin-top: 30px;
}

.contact-item {
    display: flex;
    margin-bottom: 25px;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-right: 15px;
    width: 30px;
    text-align: center;
}

.contact-item h3 {
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.social-contact {
    margin-top: 40px;
}

.social-contact h3 {
    margin-bottom: 15px;
}

.contact-form form {
    display: flex;
    flex-direction: column;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
}

.form-group.checkbox {
    display: flex;
    align-items: center;
}

.form-group.checkbox input {
    width: auto;
    margin-right: 10px;
}

.map-container {
    margin-top: 60px;
}

.map-container h2 {
    text-align: center;
    margin-bottom: 30px;
}

.map {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

/* Sobre Nosotros */
.about-content {
    padding: var(--section-padding);
}

.about-intro {
    max-width: 800px;
    margin: 0 auto 60px;
}

.about-image {
    margin: 40px 0;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
}

.values-list {
    margin: 30px 0;
}

.values-list li {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.values-list i {
    color: var(--primary-color);
    margin-right: 10px;
    font-size: 1.2rem;
}

.team-section {
    margin-bottom: 60px;
    text-align: center;
}

.team-section > p {
    max-width: 700px;
    margin: 0 auto 40px;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 30px;
}

.team-member {
    background-color: var(--bg-light);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    padding-bottom: 20px;
}

.team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.team-member img {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    object-fit: cover;
}

.team-member h3 {
    margin: 15px 0 5px;
    padding: 0 15px;
}

.team-member p {
    padding: 0 15px;
    margin-bottom: 10px;
}

.member-social {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 15px;
}

.member-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 50%;
    color: var(--text-color);
    transition: var(--transition);
}

.member-social a:hover {
    background-color: var(--primary-color);
    color: white;
}

.achievements-section {
    margin-bottom: 60px;
    text-align: center;
}

.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.achievement-card {
    background-color: var(--bg-light);
    padding: 30px 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
}

.achievement-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
}

.achievement-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.achievement-card h3 {
    font-size: 2rem;
    margin-bottom: 5px;
}

.partner-section {
    margin-bottom: 60px;
    text-align: center;
}

.partner-logos {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 40px;
    margin-top: 30px;
}

.partner-logo {
    width: 150px;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: var(--transition);
}

.partner-logo:hover {
    filter: grayscale(0);
    opacity: 1;
}

.cta-about {
    text-align: center;
    background-color: var(--bg-light);
    padding: 60px 30px;
    border-radius: var(--border-radius);
    margin-top: 60px;
}

.cta-about h2 {
    margin-bottom: 15px;
}

.cta-about p {
    max-width: 600px;
    margin: 0 auto 25px;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-form input {
    flex-grow: 1;
    padding: 12px 15px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius) 0 0 var(--border-radius);
    font-size: 1rem;
}

.newsletter-form button {
    border-radius: 0 var(--border-radius) var(--border-radius) 0;
}

/* Botón de feedback */
.feedback {
    padding: 30px 0;
    text-align: center;
}

.feedback-btn {
    background-color: var(--secondary-color);
}

.feedback-btn:hover {
    background-color: #c0392b;
}

/* Modal de agradecimiento */
.thank-you-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: white;
    padding: 40px;
    border-radius: var(--border-radius);
    max-width: 500px;
    width: 90%;
    text-align: center;
    position: relative;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-light);
}

.modal-content i {
    font-size: 3rem;
    color: #2ecc71;
    margin-bottom: 20px;
}

.modal-btn {
    margin-top: 20px;
}

/* Aviso de cookies */
.cookie-consent {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--bg-dark);
    color: white;
    padding: 20px;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

.cookie-text {
    flex: 2;
}

.cookie-text a {
    color: var(--primary-color);
    text-decoration: underline;
}

.cookie-buttons {
    display: flex;
    gap: 10px;
    flex: 1;
    justify-content: flex-end;
}

.btn-accept {
    background-color: #2ecc71;
}

.btn-accept:hover {
    background-color: #27ae60;
}

.btn-settings {
    background-color: #7f8c8d;
}

.btn-settings:hover {
    background-color: #6c7a7b;
}

.btn-decline {
    background-color: #e74c3c;
}

.btn-decline:hover {
    background-color: #c0392b;
}

/* Efecto hover para títulos */
h1:hover, h2:hover, h3:hover, h4:hover, h5:hover, h6:hover {
    color: var(--primary-color);
    transform: translateX(5px);
}

/* Media queries */
@media (max-width: 1024px) {
    :root {
        --section-padding: 60px 0;
    }
    
    h1 {
        font-size: 2.2rem;
    }
    
    h2 {
        font-size: 1.8rem;
    }
    
    .hero {
        padding: 120px 0;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.6rem;
    }
    
    .hero {
        padding: 100px 0;
    }
    
    .hero h1 {
        font-size: 2.2rem;
    }
    
    .contact-flex {
        grid-template-columns: 1fr;
    }
    
    .newsletter form {
        flex-direction: column;
    }
    
    .newsletter input {
        border-radius: var(--border-radius);
        margin-bottom: 10px;
    }
    
    .newsletter button {
        border-radius: var(--border-radius);
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
    
    .cookie-consent {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-text {
        margin-bottom: 15px;
    }
}

@media (max-width: 576px) {
    :root {
        --header-height: 60px;
    }
    
    header .container {
        flex-direction: column;
        padding: 10px 20px;
    }
    
    nav ul {
        margin-top: 15px;
    }
    
    nav ul li {
        margin-left: 15px;
        margin-right: 15px;
    }
    
    .hero {
        padding: 80px 0;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .post-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .cookie-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .cookie-buttons button {
        width: 100%;
    }
}
