/* ============================================
   MARA.COM - ESTILOS PRINCIPALES
   assets/css/style.css
   ============================================ */

/* ============================================
   1. RESET Y BASE
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: #0a0a0a;
    color: #fff;
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

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

/* ============================================
   2. NAVBAR
   ============================================ */
.navbar {
    background: rgba(10, 10, 10, 0.95);
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-img {
    height: 36px;
    border-radius: 8px;
}

.nav-links {
    display: flex;
    gap: 16px;
    align-items: center;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    font-weight: 500;
    transition: color 0.3s;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 8px;
}

.nav-links a:hover,
.nav-links a.active {
    color: #00d4ff;
    background: rgba(0, 212, 255, 0.05);
}

/* ============================================
   3. HERO
   ============================================ */
.hero {
    position: relative;
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-size: cover;
    background-position: center;
    padding: 40px 16px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    padding: 0 10px;
}

.hero-content h1 {
    font-size: 36px;
    font-weight: 800;
    margin-bottom: 16px;
    line-height: 1.2;
}

.hero-content h1 .highlight {
    background: linear-gradient(135deg, #00d4ff, #0099cc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-content p {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 24px;
}

.hero-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-primary {
    background: linear-gradient(135deg, #00d4ff, #0099cc);
    color: #fff;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

.hero-stats {
    display: flex;
    gap: 30px;
    justify-content: center;
    margin-top: 24px;
    flex-wrap: wrap;
}

.hero-stat .number {
    font-size: 22px;
    font-weight: 700;
    color: #00d4ff;
    display: block;
}

.hero-stat .label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ============================================
   4. CATÁLOGO
   ============================================ */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 16px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 30px;
}

.section-header h2 {
    font-size: 24px;
    font-weight: 700;
}

.section-header h2 i {
    color: #00d4ff;
    margin-right: 10px;
}

.search-box {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 0 14px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.search-box i {
    color: rgba(255, 255, 255, 0.3);
    margin-right: 10px;
}

.search-box input {
    background: none;
    border: none;
    padding: 10px 0;
    color: #fff;
    font-size: 14px;
    width: 160px;
    outline: none;
}

.search-box input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

/* ============================================
   GRUPO DE SERVICIO
   ============================================ */
.servicio-grupo {
    margin-bottom: 40px;
}

.servicio-titulo {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
    color: #fff;
}

.servicio-titulo i {
    color: #00d4ff;
    margin-right: 10px;
}

/* ============================================
   GRID DE PRODUCTOS
   ============================================ */
.planes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

/* ============================================
   TARJETA DE PRODUCTO
   ============================================ */
.plan-card {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 14px;
    padding: 20px 16px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s;
    cursor: pointer;
    position: relative;
}

.plan-card:hover {
    transform: translateY(-4px);
    border-color: rgba(0, 212, 255, 0.3);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.badge {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 9px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    text-transform: uppercase;
}

.badge.premium {
    background: rgba(255, 215, 0, 0.15);
    color: #FFD700;
}

.badge.familiar {
    background: rgba(0, 212, 255, 0.15);
    color: #00d4ff;
}

.plan-icon {
    font-size: 30px;
    color: #00d4ff;
    margin-bottom: 10px;
}

.plan-nombre {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
}

.plan-tipo {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

.plan-precio {
    font-size: 24px;
    font-weight: 700;
    color: #00d4ff;
    margin-bottom: 4px;
}

.plan-precio span {
    font-size: 12px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.4);
}

.plan-detalles {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 14px;
}

.plan-detalles i {
    color: #00d4ff;
    margin-right: 4px;
}

.btn-comprar {
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.btn-comprar:hover {
    transform: scale(1.02);
    box-shadow: 0 5px 20px rgba(37, 211, 102, 0.3);
}

/* ============================================
   MENSAJE VACÍO
   ============================================ */
.empty-message {
    text-align: center;
    padding: 60px 20px;
    color: rgba(255, 255, 255, 0.4);
    grid-column: 1 / -1;
}

.empty-message i {
    font-size: 48px;
    display: block;
    margin-bottom: 16px;
}

/* ============================================
   5. FOOTER
   ============================================ */
footer {
    background: rgba(255, 255, 255, 0.02);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 30px 16px 16px;
    margin-top: 30px;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 24px;
}

.footer-section h4 {
    color: #fff;
    font-size: 14px;
    margin-bottom: 10px;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
    margin-bottom: 4px;
}

.footer-section p i {
    margin-right: 6px;
    color: #00d4ff;
}

.footer-bottom {
    max-width: 1400px;
    margin: 16px auto 0;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    color: rgba(255, 255, 255, 0.3);
    font-size: 12px;
}

/* ============================================
   CHAT WIDGET
   ============================================ */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    font-family: 'Inter', sans-serif;
}

.chat-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #25D366, #128C7E);
    border: none;
    color: #fff;
    font-size: 28px;
    cursor: pointer;
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.4);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-button:hover {
    transform: scale(1.08);
    box-shadow: 0 10px 40px rgba(37, 211, 102, 0.5);
}

.chat-window {
    position: absolute;
    bottom: 76px;
    right: 0;
    width: 360px;
    max-height: 520px;
    background: #1a1a2e;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
    display: none;
    flex-direction: column;
    overflow: hidden;
}

.chat-window.active {
    display: flex;
}

.chat-header {
    padding: 14px 18px;
    background: rgba(0, 212, 255, 0.08);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 10px;
}

.chat-header i {
    color: #00d4ff;
    font-size: 18px;
}

.chat-header span {
    flex: 1;
    font-weight: 600;
    font-size: 14px;
    color: #fff;
}

.chat-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    font-size: 18px;
    cursor: pointer;
    padding: 4px 8px;
}

.chat-close:hover {
    color: #ff6b6b;
}

.chat-messages {
    flex: 1;
    padding: 14px 16px;
    overflow-y: auto;
    min-height: 180px;
    max-height: 300px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.message {
    max-width: 85%;
    animation: fadeIn 0.3s ease;
}

.message .content {
    padding: 8px 14px;
    border-radius: 14px;
    font-size: 13px;
    line-height: 1.6;
    word-wrap: break-word;
}

.message.bot .content {
    background: rgba(255, 255, 255, 0.06);
    color: #e0e0e0;
    border-bottom-left-radius: 4px;
}

.message.user .content {
    background: linear-gradient(135deg, #00d4ff, #0099cc);
    color: #fff;
    border-bottom-right-radius: 4px;
    margin-left: auto;
}

.message.bot.typing .content {
    background: rgba(255, 255, 255, 0.06);
    padding: 12px 16px;
    display: flex;
    gap: 4px;
    align-items: center;
}

.message.bot.typing .dot {
    width: 8px;
    height: 8px;
    background: #00d4ff;
    border-radius: 50%;
    display: inline-block;
    animation: typing 1.4s infinite;
}

.message.bot.typing .dot:nth-child(2) {
    animation-delay: 0.2s;
}

.message.bot.typing .dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.4; }
    30% { transform: translateY(-6px); opacity: 1; }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.chat-quick-replies {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 6px 14px 10px 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.quick-reply {
    background: rgba(0, 212, 255, 0.12);
    color: #00d4ff;
    border: 1px solid rgba(0, 212, 255, 0.15);
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.quick-reply:hover {
    background: rgba(0, 212, 255, 0.25);
    transform: scale(1.03);
}

.chat-input {
    display: flex;
    padding: 8px 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    gap: 6px;
    align-items: center;
    background: rgba(0, 0, 0, 0.2);
}

.chat-input input {
    flex: 1;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    padding: 8px 12px;
    color: #fff;
    font-size: 13px;
    outline: none;
    font-family: 'Inter', sans-serif;
}

.chat-input input:focus {
    border-color: rgba(0, 212, 255, 0.3);
}

.chat-input input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.chat-input button {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s;
    padding: 6px 8px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-input button:hover {
    color: #00d4ff;
    background: rgba(0, 212, 255, 0.08);
}

.chat-input .btn-send {
    color: #00d4ff;
}

.chat-input .btn-send:hover {
    color: #fff;
    background: rgba(0, 212, 255, 0.15);
}

.chat-input .btn-attach {
    color: rgba(255, 255, 255, 0.4);
}

.chat-input .btn-attach:hover {
    color: #4CAF50;
    background: rgba(76, 175, 80, 0.1);
}

.chat-receipt-preview {
    display: none;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.03);
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    align-items: center;
    gap: 10px;
}

.chat-receipt-preview img {
    max-width: 50px;
    max-height: 50px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.chat-receipt-preview .receipt-info {
    flex: 1;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
}

.chat-receipt-preview .receipt-remove {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    font-size: 14px;
    padding: 4px 6px;
}

.chat-receipt-preview .receipt-remove:hover {
    color: #ff6b6b;
}

/* ============================================
   RESPONSIVE - MÓVILES
   ============================================ */

/* Tablets y móviles grandes */
@media (max-width: 992px) {
    .hero-content h1 {
        font-size: 30px;
    }
    
    .planes-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }
}

/* Móviles y tablets pequeñas */
@media (max-width: 768px) {
    /* Navbar */
    .navbar {
        padding: 10px 0;
    }
    
    .logo-img {
        height: 30px;
    }
    
    .nav-links {
        gap: 8px;
    }
    
    .nav-links a {
        font-size: 12px;
        padding: 4px 8px;
    }
    
    .nav-links a span {
        display: none;
    }
    
    /* Hero */
    .hero {
        min-height: 40vh;
        padding: 30px 16px;
    }
    
    .hero-content h1 {
        font-size: 26px;
    }
    
    .hero-content p {
        font-size: 14px;
    }
    
    .hero-stats {
        gap: 20px;
    }
    
    .hero-stat .number {
        font-size: 18px;
    }
    
    .hero-stat .label {
        font-size: 10px;
    }
    
    .btn-primary,
    .btn-secondary {
        padding: 10px 18px;
        font-size: 13px;
    }
    
    /* Catálogo */
    .container {
        padding: 30px 12px;
    }
    
    .section-header h2 {
        font-size: 20px;
    }
    
    .search-box input {
        width: 120px;
        font-size: 13px;
    }
    
    .planes-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 12px;
    }
    
    .plan-card {
        padding: 14px 12px;
    }
    
    .plan-nombre {
        font-size: 13px;
    }
    
    .plan-precio {
        font-size: 20px;
    }
    
    /* Chat */
    .chat-window {
        width: 320px;
        max-height: 480px;
        right: -10px;
        bottom: 72px;
    }
    
    .chat-button {
        width: 54px;
        height: 54px;
        font-size: 24px;
    }
}

/* Móviles pequeños */
@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 22px;
    }
    
    .hero-content p {
        font-size: 13px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
        width: 100%;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        justify-content: center;
    }
    
    .planes-grid {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }
    
    .plan-card {
        padding: 12px 10px;
        border-radius: 12px;
    }
    
    .plan-nombre {
        font-size: 12px;
    }
    
    .plan-precio {
        font-size: 18px;
    }
    
    .plan-precio span {
        font-size: 10px;
    }
    
    .plan-detalles {
        font-size: 11px;
    }
    
    .btn-comprar {
        font-size: 11px;
        padding: 6px 12px;
    }
    
    .chat-window {
        width: 290px;
        max-height: 420px;
        right: -20px;
        bottom: 68px;
        border-radius: 14px;
    }
    
    .chat-button {
        width: 50px;
        height: 50px;
        font-size: 22px;
    }
    
    .chat-messages {
        max-height: 220px;
        padding: 12px;
    }
    
    .message .content {
        font-size: 12px;
        padding: 8px 12px;
    }
    
    .quick-reply {
        font-size: 10px;
        padding: 4px 12px;
    }
    
    .servicio-titulo {
        font-size: 17px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .search-box input {
        width: 100%;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 16px;
    }
}

/* Móviles muy pequeños (menos de 360px) */
@media (max-width: 360px) {
    .planes-grid {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }
    
    .plan-card {
        padding: 10px 8px;
    }
    
    .plan-nombre {
        font-size: 11px;
    }
    
    .plan-precio {
        font-size: 16px;
    }
    
    .chat-window {
        width: 260px;
        right: -30px;
        max-height: 380px;
        bottom: 64px;
    }
    
    .chat-button {
        width: 46px;
        height: 46px;
        font-size: 20px;
    }
    
    .chat-messages {
        max-height: 180px;
        padding: 10px;
    }
}

/* Pantallas grandes (PC) */
@media (min-width: 1200px) {
    .hero-content h1 {
        font-size: 54px;
    }
    
    .hero-content p {
        font-size: 20px;
    }
    
    .planes-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 24px;
    }
    
    .plan-card {
        padding: 28px 24px;
    }
    
    .plan-nombre {
        font-size: 18px;
    }
    
    .plan-precio {
        font-size: 30px;
    }
    
    .chat-window {
        width: 420px;
        max-height: 600px;
    }
    
    .chat-messages {
        max-height: 360px;
    }
}