/* =======================================================
   THE CODE HOUSE — TIKTOK LIVE LANDING PAGE ($500 MXN)
   Dark Mode Tech Studio Theme (High Contrast Edition)
   ======================================================= */

:root {
    --bg-dark: #060c17;
    --bg-card: #0b172a;
    --bg-card-alt: #101f38;
    --bg-input: #091528;
    
    --primary-cyan: #00f2fe;
    --primary-cyan-glow: rgba(0, 242, 254, 0.25);
    --accent-green: #00e676;
    --accent-green-glow: rgba(0, 230, 118, 0.25);
    --warning-gold: #ffc107;
    
    --text-main: #ffffff;
    --text-muted: #cbd5e1;  /* Ultra legible en pantallas oscuras */
    --text-dim: #94a3b8;    /* Alto contraste para etiquetas secundarias */
    --border-color: rgba(255, 255, 255, 0.15);
    --border-glow: rgba(0, 242, 254, 0.4);
    
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --font-mono: 'Space Mono', 'Fira Code', monospace;
    
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 18px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-dark);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    background-image: 
        radial-gradient(circle at 50% 0%, rgba(0, 242, 254, 0.1) 0%, transparent 60%),
        radial-gradient(circle at 100% 50%, rgba(0, 230, 118, 0.05) 0%, transparent 50%);
}

.container {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 1.25rem;
}

/* Header */
.live-header {
    background-color: rgba(6, 12, 23, 0.92);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--border-color);
    padding: 0.85rem 0;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.brand-logo {
    height: 38px;
    width: auto;
    filter: drop-shadow(0 0 8px rgba(0, 242, 254, 0.3));
}

.brand-text-container {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-family: var(--font-sans);
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--text-main);
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.brand-subtitle {
    font-family: var(--font-mono);
    font-size: 0.68rem;
    color: var(--primary-cyan);
    letter-spacing: 0.5px;
    font-weight: 700;
}

/* Language Switcher Pill */
.lang-switch {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-color);
    padding: 0.4rem 0.85rem;
    border-radius: 50px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #ffffff;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.25s ease;
}

.lang-switch:hover {
    background: rgba(0, 242, 254, 0.15);
    border-color: var(--primary-cyan);
    color: var(--primary-cyan);
}

/* Live Badge */
.live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.5);
    padding: 0.4rem 0.85rem;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #fca5a5;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.live-dot {
    width: 8px;
    height: 8px;
    background-color: #ef4444;
    border-radius: 50%;
    box-shadow: 0 0 10px #ef4444;
    animation: livePulse 1.4s infinite;
}

@keyframes livePulse {
    0% { transform: scale(0.95); opacity: 0.5; }
    50% { transform: scale(1.35); opacity: 1; box-shadow: 0 0 14px #ef4444; }
    100% { transform: scale(0.95); opacity: 0.5; }
}

/* Hero Section */
.hero-section {
    padding: 2.5rem 0 2rem 0;
    text-align: center;
}

.delivery-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(0, 242, 254, 0.12);
    border: 1px solid rgba(0, 242, 254, 0.4);
    color: var(--primary-cyan);
    padding: 0.55rem 1.2rem;
    border-radius: 50px;
    font-size: 0.88rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 18px rgba(0, 242, 254, 0.2);
}

.hero-title {
    font-size: 2.25rem;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.03em;
    margin-bottom: 1.2rem;
    color: #ffffff;
}

.hero-title span.price-tag {
    color: var(--accent-green);
    text-shadow: 0 0 20px rgba(0, 230, 118, 0.5);
    display: inline-block;
    font-weight: 800;
}

.hero-sub {
    font-size: 1.08rem;
    color: var(--text-muted);
    max-width: 680px;
    margin: 0 auto 2rem auto;
    font-weight: 400;
}

.hero-features {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.feature-pill {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.18);
    padding: 0.5rem 0.95rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    color: #ffffff;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.feature-pill i {
    color: var(--accent-green);
}

/* SPEI Payment Module */
.spei-card {
    background: linear-gradient(145deg, var(--bg-card) 0%, var(--bg-card-alt) 100%);
    border: 2px solid var(--primary-cyan);
    border-radius: var(--radius-md);
    padding: 1.75rem;
    margin-bottom: 2.5rem;
    box-shadow: 0 10px 30px rgba(0, 242, 254, 0.2), 0 0 20px rgba(0, 0, 0, 0.6);
    position: relative;
    overflow: hidden;
}

.spei-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-cyan), var(--accent-green));
}

.spei-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.spei-header-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.spei-header-title h3 {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-main);
}

.spei-header-title i {
    color: var(--accent-green);
    font-size: 1.4rem;
}

.spei-amount-badge {
    background: rgba(0, 230, 118, 0.2);
    border: 1px solid rgba(0, 230, 118, 0.5);
    color: var(--accent-green);
    padding: 0.45rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 1.15rem;
    font-weight: 800;
    font-family: var(--font-mono);
}

.spei-grid {
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 1.5rem;
    align-items: center;
}

.spei-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.spei-row {
    background: var(--bg-input);
    border: 1px solid rgba(255, 255, 255, 0.15);
    padding: 0.85rem 1.1rem;
    border-radius: var(--radius-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
}

.spei-label {
    font-size: 0.78rem;
    text-transform: uppercase;
    color: var(--text-dim);
    font-weight: 700;
    letter-spacing: 0.5px;
}

.spei-val-group {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.spei-value {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    color: var(--primary-cyan);
    word-break: break-all;
}

.btn-copy {
    background: rgba(0, 242, 254, 0.15);
    border: 1px solid var(--primary-cyan);
    color: #ffffff;
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.btn-copy:hover {
    background: var(--primary-cyan);
    color: #040914;
    border-color: var(--primary-cyan);
    transform: scale(1.04);
}

.spei-qr-box {
    background: #ffffff;
    padding: 0.85rem;
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.spei-qr-box img {
    width: 150px;
    height: 150px;
    object-fit: contain;
}

.spei-qr-box span {
    font-size: 0.75rem;
    color: #0f172a;
    font-weight: 800;
    margin-top: 0.4rem;
}

/* Form Section */
.form-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    margin-bottom: 2.5rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.form-header {
    margin-bottom: 1.75rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.form-header h2 {
    font-size: 1.65rem;
    font-weight: 800;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.form-header h2 i {
    color: var(--primary-cyan);
}

.form-header p {
    font-size: 0.92rem;
    color: var(--text-muted);
    margin-top: 0.3rem;
}

.order-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.form-group.full-width {
    grid-column: span 2;
}

.form-group label {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 700;
    color: #f1f5f9;
    margin-bottom: 0.45rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group label span.req {
    color: var(--primary-cyan);
}

.form-control {
    width: 100%;
    background-color: var(--bg-input);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-sm);
    padding: 0.85rem 1rem;
    color: #ffffff;
    font-family: var(--font-sans);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--primary-cyan);
    box-shadow: 0 0 0 3px var(--primary-cyan-glow);
    background-color: #0d1e38;
}

.form-control::placeholder {
    color: #94a3b8;
}

/* File Upload Zone */
.file-upload-box {
    border: 2px dashed rgba(255, 255, 255, 0.25);
    background-color: var(--bg-input);
    border-radius: var(--radius-sm);
    padding: 1.25rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.file-upload-box:hover {
    border-color: var(--primary-cyan);
    background-color: rgba(0, 242, 254, 0.05);
}

.file-upload-box input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.file-upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
}

.file-upload-icon {
    font-size: 1.9rem;
    color: var(--primary-cyan);
}

.file-upload-text {
    font-size: 0.88rem;
    color: #f1f5f9;
    font-weight: 600;
}

.file-upload-hint {
    font-size: 0.75rem;
    color: var(--text-dim);
}

.file-preview-name {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--accent-green);
    margin-top: 0.4rem;
    font-weight: 700;
    word-break: break-all;
}

/* Submit Button */
.btn-submit-live {
    grid-column: span 2;
    background: linear-gradient(135deg, var(--primary-cyan) 0%, #00b4d8 100%);
    color: #040914;
    border: none;
    padding: 1.15rem 1.5rem;
    border-radius: var(--radius-sm);
    font-size: 1.12rem;
    font-weight: 800;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 0.5rem;
    box-shadow: 0 0 25px rgba(0, 242, 254, 0.35);
}

.btn-submit-live:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 35px rgba(0, 242, 254, 0.55);
    background: linear-gradient(135deg, #38ef7d 0%, var(--accent-green) 100%);
    color: #040914;
}

.btn-submit-live:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Success Message */
.form-success-box {
    display: none;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2.5rem 1.5rem;
    background: rgba(0, 230, 118, 0.06);
    border: 1px solid var(--accent-green);
    border-radius: var(--radius-md);
}

.form-success-box i {
    font-size: 3.5rem;
    color: var(--accent-green);
    margin-bottom: 1rem;
}

.form-success-box h3 {
    font-size: 1.65rem;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}

.form-success-box p {
    color: var(--text-muted);
    max-width: 500px;
    margin-bottom: 1.5rem;
}

.btn-whatsapp-direct {
    background-color: #25d366;
    color: #ffffff;
    padding: 0.85rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.35);
    transition: var(--transition);
}

.btn-whatsapp-direct:hover {
    background-color: #20ba5a;
    transform: translateY(-2px);
}

/* Rules & Terms Section */
.terms-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    margin-bottom: 3rem;
}

.terms-title {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.terms-title i {
    color: var(--warning-gold);
}

.terms-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.term-box {
    background-color: var(--bg-input);
    border: 1px solid var(--border-color);
    padding: 1.25rem;
    border-radius: var(--radius-sm);
}

.term-box h4 {
    font-size: 0.95rem;
    color: var(--primary-cyan);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
}

.term-box p {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Footer */
.live-footer {
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    text-align: center;
    color: var(--text-dim);
    font-size: 0.82rem;
}

/* Toast Notification */
.toast-notice {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--bg-card-alt);
    border: 1px solid var(--primary-cyan);
    color: var(--text-main);
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    font-size: 0.88rem;
    font-weight: 700;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
    transition: all 0.3s ease;
    z-index: 9999;
    opacity: 0;
}

.toast-notice.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* Responsive Rules */
@media (max-width: 768px) {
    .hero-title {
        font-size: 1.75rem;
    }
    
    .spei-grid {
        grid-template-columns: 1fr;
    }
    
    .spei-qr-box {
        max-width: 200px;
        margin: 0 auto;
    }
    
    .order-form {
        grid-template-columns: 1fr;
    }
    
    .form-group.full-width {
        grid-column: span 1;
    }
    
    .btn-submit-live {
        grid-column: span 1;
    }
    
    .terms-grid {
        grid-template-columns: 1fr;
    }
}

/* Payment Tabs Segmented Control */
.payment-tabs-nav {
    display: flex;
    gap: 0.5rem;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    padding: 0.35rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
}

.tab-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.8rem 1rem;
    font-size: 0.95rem;
    font-weight: 700;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.25s ease;
}

.tab-btn i {
    font-size: 1.1rem;
}

.tab-btn:hover {
    color: #ffffff;
}

.tab-btn.active {
    background: linear-gradient(135deg, rgba(99, 91, 255, 0.25) 0%, rgba(0, 242, 254, 0.15) 100%);
    border: 1px solid rgba(99, 91, 255, 0.5);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(99, 91, 255, 0.25);
}

.payment-tab-content {
    animation: fadeInTab 0.3s ease-in-out;
}

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

/* Stripe Pay Box */
.stripe-pay-box {
    text-align: center;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(99, 91, 255, 0.3);
    padding: 1.75rem 1.25rem;
    border-radius: 12px;
}

.btn-stripe-pay {
    background: linear-gradient(135deg, #635bff 0%, #00d4b6 100%);
    color: #ffffff !important;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.25rem 1.75rem;
    font-size: 1.25rem;
    font-weight: 800;
    border-radius: 10px;
    box-shadow: 0 6px 25px rgba(99, 91, 255, 0.45);
    transition: all 0.25s ease;
    margin-bottom: 1.25rem;
}

.btn-stripe-pay:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(99, 91, 255, 0.6);
}

.card-brands {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 0.85rem;
}

.brand-badge {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-color);
    padding: 0.35rem 0.65rem;
    border-radius: 6px;
    font-size: 0.82rem;
    font-weight: 600;
    color: #cbd5e1;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.stripe-guarantee {
    font-size: 0.8rem;
    color: var(--text-dim);
    display: block;
}

.tax-note-box {
    background: rgba(255, 183, 3, 0.1);
    border: 1px solid rgba(255, 183, 3, 0.3);
    padding: 0.85rem 1rem;
    border-radius: 8px;
    font-size: 0.83rem;
    color: #ffb703;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    margin-top: 1rem;
}

@media (max-width: 600px) {
    .payment-tabs-nav {
        flex-direction: column;
    }
    
    .btn-stripe-pay {
        font-size: 1.1rem;
        padding: 1.1rem 1rem;
    }
}

/* Floating WhatsApp Button Widget */
.floating-whatsapp-btn {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 9999;
    background: #25d366;
    color: #ffffff !important;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.1rem;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
    text-decoration: none !important;
    transition: all 0.3s ease;
    animation: waPulse 2s infinite;
}

.floating-whatsapp-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.7);
}

.wa-badge-tooltip {
    position: absolute;
    right: 70px;
    bottom: 12px;
    background: rgba(15, 23, 42, 0.92);
    border: 1px solid rgba(37, 211, 102, 0.5);
    color: #ffffff;
    padding: 0.5rem 0.85rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
    opacity: 0.95;
    pointer-events: none;
}

@keyframes waPulse {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); }
    70% { box-shadow: 0 0 0 16px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

@media (max-width: 600px) {
    .wa-badge-tooltip {
        display: none;
    }
    .floating-whatsapp-btn {
        bottom: 20px;
        right: 20px;
        width: 55px;
        height: 55px;
        font-size: 1.8rem;
    }
}
