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

:root {
    --primary-color: #2563eb;
    --primary-dark: #1e40af;
    --secondary-color: #10b981;
    --accent-color: #f59e0b;
    --text-color: #1f2937;
    --text-light: #6b7280;
    --bg-light: #f9fafb;
    --bg-white: #ffffff;
    --border-color: #e5e7eb;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-white);
}

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

/* Header y Navegación */
header {
    background-color: var(--bg-white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h2 {
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: 700;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
}

.nav-menu a:hover {
    color: var(--primary-color);
}

.nav-menu .btn-cta {
    background-color: var(--primary-color);
    color: white;
    padding: 0.5rem 1.5rem;
    border-radius: 0.5rem;
}

.nav-menu .btn-cta:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    transition: var(--transition);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 6rem 0;
    text-align: center;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 800;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.95;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Botones */
.btn {
    display: inline-block;
    padding: 0.875rem 2rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

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

.btn-primary:hover {
    background-color: #059669;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

.btn-secondary:hover {
    background-color: var(--bg-light);
    transform: translateY(-2px);
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
}

/* Secciones */
.section {
    padding: 5rem 0;
}

.bg-light {
    background-color: var(--bg-light);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.section-intro {
    text-align: center;
    font-size: 1.125rem;
    color: var(--text-light);
    max-width: 800px;
    margin: 0 auto 3rem;
}

/* Grid de Riesgos */
.risk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.risk-card {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.risk-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.risk-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.risk-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.risk-card p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

.risk-card ul {
    list-style: none;
    padding-left: 0;
}

.risk-card ul li {
    padding: 0.5rem 0;
    color: var(--text-color);
    padding-left: 1.5rem;
    position: relative;
}

.risk-card ul li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

/* Coberturas */
.coverage-container {
    display: grid;
    gap: 2rem;
}

.coverage-item {
    background: var(--bg-white);
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.coverage-item:hover {
    box-shadow: var(--shadow-lg);
}

.coverage-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.coverage-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.coverage-badge.essential {
    background-color: #ef4444;
}

.coverage-badge.recommended {
    background-color: var(--secondary-color);
}

.coverage-badge.optional {
    background-color: var(--text-light);
}

.coverage-badge.new {
    background-color: var(--accent-color);
}

.coverage-content {
    padding: 1.5rem;
}

.coverage-content h4 {
    margin: 1rem 0 0.5rem;
    color: var(--primary-color);
}

.coverage-content ul {
    list-style: none;
}

.coverage-content ul li {
    padding: 0.5rem 0;
}

/* Tabla Comparativa */
.comparison-table-wrapper {
    overflow-x: auto;
    margin-bottom: 3rem;
    border-radius: 1rem;
    box-shadow: var(--shadow);
}

.comparison-table {
    width: 100%;
    background: var(--bg-white);
    border-collapse: collapse;
}

.comparison-table thead {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
}

.comparison-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.comparison-table td {
    padding: 1.5rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.comparison-table tr:hover {
    background-color: var(--bg-light);
}

.comparison-table tr.featured {
    background-color: #fef3c7;
}

.comparison-table .rating {
    color: var(--accent-color);
    font-size: 1.25rem;
}

.comparison-table ul {
    list-style: none;
    padding: 0;
    margin: 0.5rem 0 0 0;
}

.comparison-table ul li {
    padding: 0.25rem 0;
    font-size: 0.875rem;
}

.badge-featured {
    background-color: var(--accent-color);
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.75rem;
    margin-left: 0.5rem;
}

/* Cards de Aseguradoras */
.comparison-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.insurer-card {
    background: var(--bg-white);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.insurer-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.insurer-card.featured {
    border: 3px solid var(--accent-color);
}

.insurer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 700;
}

.badge.gold {
    background-color: var(--accent-color);
    color: white;
}

.badge.silver {
    background-color: #94a3b8;
    color: white;
}

.badge.bronze {
    background-color: #fb923c;
    color: white;
}

.rating-large {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.rating-large .stars {
    color: var(--accent-color);
    font-size: 1.5rem;
}

.rating-large .score {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
}

.price {
    text-align: center;
    margin-bottom: 1rem;
    padding: 1rem;
    background-color: var(--bg-light);
    border-radius: 0.5rem;
}

.price .amount {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.price .period {
    font-size: 0.875rem;
    color: var(--text-light);
}

.insurer-card .description {
    margin-bottom: 1.5rem;
    color: var(--text-light);
}

.insurer-card .features {
    list-style: none;
    margin-bottom: 2rem;
    flex-grow: 1;
}

.insurer-card .features li {
    padding: 0.5rem 0;
    color: var(--text-color);
}

.insurer-card .btn {
    width: 100%;
    text-align: center;
}

.insurer-note {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem;
    border-radius: 0.5rem;
    text-align: center;
    font-weight: 600;
    margin-top: auto;
}

/* Nota sobre enlaces externos */
.external-links-note {
    margin-top: 1rem;
    color: var(--text-light);
    font-size: 0.875rem;
    text-align: center;
}

/* Consejos */
.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.tip-card {
    background: var(--bg-white);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow);
    position: relative;
    transition: var(--transition);
}

.tip-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.tip-number {
    position: absolute;
    top: -15px;
    left: 20px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
}

.tip-card h3 {
    margin-top: 1rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.tip-card ul {
    list-style: none;
    padding: 0;
}

.tip-card ul li {
    padding: 0.5rem 0;
}

/* Checklist */
.checklist-box {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow-lg);
}

.checklist-box h3 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
}

.checklist {
    list-style: none;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.checklist li {
    padding: 0.75rem;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    font-size: 1rem;
}

/* FAQ */
.faq-container {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    background: var(--bg-white);
    margin-bottom: 1rem;
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.faq-question {
    padding: 1.5rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.faq-question:hover {
    background-color: var(--bg-light);
}

.faq-question h3 {
    font-size: 1.125rem;
    color: var(--primary-color);
    margin: 0;
}

.faq-icon {
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 300;
    transition: var(--transition);
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 2000px;
}

.faq-answer p,
.faq-answer ul,
.faq-answer ol {
    padding: 0 1.5rem 1.5rem;
}

.faq-answer ul,
.faq-answer ol {
    padding-left: 3rem;
}

.faq-answer li {
    margin: 0.5rem 0;
}

/* Ad Spaces */
.ad-space {
    padding: 2rem 0;
    background-color: var(--bg-light);
}

.ad-space-inline {
    padding: 3rem 0;
}

.ad-placeholder {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 100%);
    border: 2px dashed #cbd5e1;
    border-radius: 0.5rem;
    padding: 2rem;
    text-align: center;
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.ad-placeholder.ad-horizontal {
    min-height: 120px;
}

.ad-label {
    color: var(--text-light);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* CTA Info Box */
.cta-info-box {
    background: var(--bg-white);
    border-radius: 1rem;
    padding: 2.5rem;
    max-width: 900px;
    margin: 0 auto 3rem;
    box-shadow: var(--shadow-lg);
}

.cta-info-box h3 {
    color: var(--primary-color);
    font-size: 1.75rem;
    margin-bottom: 2rem;
    text-align: center;
}

.recommendations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.recommendation-item {
    text-align: center;
    padding: 1.5rem;
    background: var(--bg-light);
    border-radius: 0.75rem;
    transition: var(--transition);
}

.recommendation-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.rec-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 1rem;
}

.recommendation-item h4 {
    color: var(--primary-color);
    font-size: 1rem;
    margin-bottom: 0.5rem;
}

.recommendation-item p {
    color: var(--text-light);
    font-size: 0.875rem;
}

/* CTA Section */
.cta-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5rem 0;
}

.cta-content h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.cta-content > p {
    text-align: center;
    font-size: 1.25rem;
    margin-bottom: 3rem;
    opacity: 0.95;
}

.cta-form {
    background: var(--bg-white);
    border-radius: 1rem;
    padding: 2.5rem;
    max-width: 700px;
    margin: 0 auto 3rem;
    box-shadow: var(--shadow-lg);
}

.cta-form h3 {
    color: var(--primary-color);
    font-size: 1.75rem;
    margin-bottom: 2rem;
    text-align: center;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

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

.form-group label {
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-color);
}

.form-group input,
.form-group select {
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.checkbox-group {
    margin: 1rem 0;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    margin-right: 0.5rem;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.cta-form button {
    width: 100%;
    margin-top: 1rem;
}

.form-note {
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-light);
    margin-top: 1rem;
}

.cta-benefits {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.benefit {
    display: flex;
    gap: 1rem;
    align-items: start;
}

.benefit-icon {
    font-size: 2rem;
    background: rgba(255, 255, 255, 0.2);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.benefit strong {
    display: block;
    font-size: 1.125rem;
    margin-bottom: 0.25rem;
}

.benefit p {
    opacity: 0.9;
    font-size: 0.875rem;
}

/* Footer */
.footer {
    background-color: var(--text-color);
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

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

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
}

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

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    font-size: 1.5rem;
    transition: var(--transition);
}

.social-links a:hover {
    transform: translateY(-3px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 1rem;
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background-color: var(--primary-color);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    z-index: 999;
}

.back-to-top:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
}

.back-to-top.visible {
    display: flex;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--bg-white);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--shadow);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .hamburger {
        display: flex;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

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

    .section-title {
        font-size: 2rem;
    }

    .risk-grid,
    .tips-grid,
    .comparison-cards {
        grid-template-columns: 1fr;
    }

    .comparison-table-wrapper {
        font-size: 0.875rem;
    }

    .cta-form {
        padding: 1.5rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.875rem;
    }
}

/* Animaciones */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Modo de impresión */
@media print {
    .navbar,
    .hero,
    .cta-section,
    .footer,
    .back-to-top {
        display: none;
    }

    .section {
        page-break-inside: avoid;
    }
}