/* Variables y Reset */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --free-color: #27ae60;
    --premium-color: #f39c12;
    --text-color: #333;
    --light-gray: #f8f9fa;
    --border-color: #ddd;
}

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

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

/* Header */
.main-header {
    background: var(--primary-color);
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

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

.logo {
    font-size: 1.8rem;
    font-weight: bold;
}

.logo a {
    color: white;
    text-decoration: none;
}

.main-nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.main-nav a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
}

.main-nav a:hover {
    color: var(--secondary-color);
}

/* Main Content */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 20px;
    min-height: 70vh;
}

/* Hero Section */
.hero {
    text-align: center;
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    color: white;
    border-radius: 10px;
    margin-bottom: 3rem;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

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

.btn-primary {
    background: var(--accent-color);
    color: white;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background 0.3s;
}

.btn-primary:hover {
    background: #c0392b;
}

.btn-secondary {
    background: var(--primary-color);
    color: white;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background 0.3s;
}

.btn-secondary:hover {
    background: #1a252f;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.feature {
    text-align: center;
    padding: 2rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.feature h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

/* CTA Section */
.cta-section {
    text-align: center;
    padding: 3rem;
    background: var(--light-gray);
    border-radius: 8px;
    margin-top: 3rem;
}

.cta-section h2 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.cta-section p {
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

/* Proveedores Grid */
.proveedores-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.proveedor-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1.5rem;
    background: white;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.proveedor-card.premium {
    border-left: 4px solid var(--premium-color);
}

.proveedor-card.free {
    border-left: 4px solid var(--free-color);
}

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

.card-header h2 {
    font-size: 1.3rem;
    color: var(--primary-color);
}

.card-header h3 {
    font-size: 1.3rem;
    color: var(--primary-color);
}

.badge-plan {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
}

.badge-plan.premium {
    background: var(--premium-color);
    color: white;
}

.badge-plan.free {
    background: var(--free-color);
    color: white;
}

.descripcion {
    color: #666;
    margin-bottom: 1rem;
}

.contacto-mini {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: #777;
}

.btn-ver-mas {
    display: inline-block;
    background: var(--secondary-color);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.9rem;
    transition: background 0.3s;
}

.btn-ver-mas:hover {
    background: #2980b9;
}

.card-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

/* Formulario de Registro */
.registro-container {
    max-width: 800px;
    margin: 0 auto;
}

.form-section {
    background: white;
    padding: 2rem;
    margin-bottom: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-section h2 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--secondary-color);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: var(--primary-color);
}

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

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

.contador-caracteres {
    text-align: right;
    font-size: 0.8rem;
    color: #666;
    margin-top: 0.5rem;
}

/* Plan Selection */
.plan-selection {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

.plan-option input[type="radio"] {
    display: none;
}

.plan-option label {
    display: block;
    padding: 1.5rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.plan-option input[type="radio"]:checked + label {
    border-color: var(--secondary-color);
    background: #e8f4fd;
}

.plan-option h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.plan-option .price {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--secondary-color);
    margin-top: 0.5rem;
}

.btn-registro {
    background: var(--accent-color);
    color: white;
    padding: 15px 40px;
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s;
    display: block;
    width: 100%;
    margin-top: 2rem;
}

.btn-registro:hover {
    background: #c0392b;
}

/* Alertas */
.alert {
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

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

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

/* Detalle de Proveedor */
.proveedor-detalle {
    max-width: 800px;
    margin: 0 auto;
}

.proveedor-header {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.proveedor-header.premium {
    border-left: 4px solid var(--premium-color);
}

.proveedor-header.free {
    border-left: 4px solid var(--free-color);
}

.logotipo {
    max-width: 150px;
    height: auto;
    margin-bottom: 1rem;
}

.info-principal h1 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.contacto p {
    margin-bottom: 0.5rem;
}

.servicios-lista {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.servicios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.servicio-item {
    padding: 1rem;
    background: var(--light-gray);
    border-radius: 4px;
}

.servicio-item h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.volver-link {
    margin-top: 2rem;
    text-align: center;
}

.volver-link a {
    color: var(--secondary-color);
    text-decoration: none;
}

.volver-link a:hover {
    text-decoration: underline;
}

/* Footer Mejorado */
.main-footer {
    background: var(--primary-color);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.footer-section p {
    color: #ccc;
    line-height: 1.6;
}

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

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

.footer-section ul li a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section ul li a:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    border-top: 1px solid #34495e;
    padding-top: 1rem;
    text-align: center;
}

.footer-bottom p {
    color: #ccc;
    margin-bottom: 0.5rem;
}

/* Categorías */
.categorias-section {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

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

.categoria-item {
    background: var(--light-gray);
    padding: 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    color: var(--primary-color);
    text-align: center;
    transition: background 0.3s;
    font-weight: bold;
}

.categoria-item:hover {
    background: var(--secondary-color);
    color: white;
}

.categorias-pagina .categorias-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.categoria-card {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-color);
    border: 1px solid var(--border-color);
    transition: transform 0.3s, box-shadow 0.3s;
    text-align: center;
}

.categoria-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    color: var(--text-color);
}

.categoria-card h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.categoria-card span {
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.breadcrumb {
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--secondary-color);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.no-proveedores, .no-categorias, .no-resultados {
    text-align: center;
    padding: 3rem;
    background: var(--light-gray);
    border-radius: 8px;
    grid-column: 1 / -1;
}

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

.btn-link {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: bold;
}

.btn-link:hover {
    text-decoration: underline;
}

/* Registro por categoría */
.registro-categoria {
    text-align: center;
    padding: 2rem;
    background: var(--light-gray);
    border-radius: 8px;
    margin-top: 2rem;
    border-left: 4px solid var(--secondary-color);
}

.registro-categoria p {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.btn-registro-categoria {
    background: var(--secondary-color);
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background 0.3s;
}

.btn-registro-categoria:hover {
    background: #2980b9;
}

.categoria-contexto {
    background: #e8f4fd;
    padding: 1rem;
    border-radius: 5px;
    margin-bottom: 1rem;
    border-left: 4px solid var(--secondary-color);
}

/* Páginas Legales */
.legal-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 20px;
}

.legal-section {
    margin-bottom: 2rem;
}

.legal-section h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
    border-bottom: 2px solid #3498db;
    padding-bottom: 0.5rem;
}

.legal-section ul {
    margin-left: 2rem;
    margin-bottom: 1rem;
}

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

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .main-nav ul {
        gap: 1rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .proveedores-grid {
        grid-template-columns: 1fr;
    }
    
    .plan-selection {
        grid-template-columns: 1fr;
    }
    
    .contacto-mini {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .categorias-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}