/* css/index.css - FerreSys (Ferretería / Cerrajería) · Liquid Glass */

:root {
    /* --- PALETA FERRESYS: naranja de seguridad + ámbar sobre grafito --- */
    --brand-primary: #ea580c;
    --brand-primary-dark: #c2410c;
    --brand-secondary: #f59e0b;
    --brand-dark: #1c1917;
    --brand-steel: #475569;
    --brand-gradient: linear-gradient(135deg, #ea580c 0%, #f59e0b 100%);

    /* Alias de compatibilidad (páginas que aún usan los nombres anteriores) */
    --brand-cyan: var(--brand-primary);
    --brand-green: var(--brand-secondary);

    /* Colores Base */
    --bg-body: #f5f1ea;
    --text-main: #1c1917;
    --text-body: #57534e;
    --white: #ffffff;

    /* Vidrio (glassmorphism / liquid glass) */
    --glass-bg: rgba(255, 255, 255, 0.42);
    --glass-bg-strong: rgba(255, 255, 255, 0.62);
    --glass-border: rgba(255, 255, 255, 0.7);
    --glass-blur: blur(22px) saturate(170%);
    --glass-shadow: 0 10px 40px -10px rgba(28, 25, 23, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.9), inset 0 -1px 0 rgba(255, 255, 255, 0.25);
    --shadow-card: var(--glass-shadow);
    --radius-lg: 24px;
    --radius-md: 16px;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Plus Jakarta Sans', sans-serif; }
h1, h2, h3, h4, .btn, .nav-link { font-family: 'Outfit', sans-serif; }

body {
    background-color: var(--bg-body);
    color: var(--text-main);
    overflow-x: hidden;
    display: flex; flex-direction: column; min-height: 100vh;
}

/* --- FONDO ANIMADO (manchas de color detrás del vidrio) --- */
.morph-bg {
    position: fixed; inset: 0; z-index: -1; overflow: hidden;
    background-color: var(--bg-body);
    background-image: radial-gradient(rgba(28, 25, 23, 0.05) 1.2px, transparent 1.2px);
    background-size: 28px 28px;
}
.blob, .morph-bg::before, .morph-bg::after {
    position: absolute; border-radius: 50%; filter: blur(110px);
    animation: float 22s ease-in-out infinite alternate;
}
.blob-1 { top: -12%; left: -8%; width: 55vh; height: 55vh; background: rgba(234, 88, 12, 0.16); }
.blob-2 { bottom: -15%; right: -10%; width: 65vh; height: 65vh; background: rgba(245, 158, 11, 0.18); animation-delay: -6s; }
.morph-bg::before { content: ""; top: 35%; right: 18%; width: 40vh; height: 40vh; background: rgba(71, 85, 105, 0.10); animation-delay: -11s; }
.morph-bg::after { content: ""; bottom: 5%; left: 12%; width: 38vh; height: 38vh; background: rgba(251, 146, 60, 0.12); animation-delay: -16s; }
@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(40px, 30px) scale(1.08); }
    100% { transform: translate(-20px, 60px) scale(0.95); }
}

/* --- BASE DE VIDRIO + BRILLO LÍQUIDO --- */
.navbar, .glass-card, .price-card, .faq-item, .mockup-container, .split-image,
.testimonial-card, .legal-content, .subtitle {
    background: var(--glass-bg);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    box-shadow: var(--glass-shadow);
}
.glass-card, .price-card, .faq-item, .mockup-container, .split-image, .testimonial-card, .legal-content { position: relative; isolation: isolate; }
.glass-card::before, .price-card::before, .mockup-container::before, .split-image::before, .testimonial-card::before, .legal-content::before {
    content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: -1;
    background:
        radial-gradient(120% 60% at 0% 0%, rgba(255, 255, 255, 0.55) 0%, rgba(255, 255, 255, 0) 45%),
        linear-gradient(160deg, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0) 35%, rgba(255, 255, 255, 0) 70%, rgba(255, 255, 255, 0.15) 100%);
}

/* --- NAVBAR FLOTANTE --- */
.navbar {
    position: fixed; top: 14px; left: 50%; transform: translateX(-50%);
    width: calc(100% - 4%); max-width: 1320px; padding: 0.7rem 1.6rem;
    display: flex; justify-content: space-between; align-items: center;
    border-radius: 22px; z-index: 1000;
    background: var(--glass-bg-strong);
}
.logo-img { height: 48px; width: auto; transition: 0.3s; display: block; }
.nav-menu { display: flex; gap: 0.4rem; }
.nav-link { text-decoration: none; color: var(--brand-dark); font-weight: 600; font-size: 0.95rem; padding: 0.5rem 1rem; border-radius: 12px; transition: 0.25s; }
.nav-link:hover { color: var(--brand-primary-dark); background: rgba(255, 255, 255, 0.7); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9); }

/* --- BOTONES --- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px;
    padding: 0.8rem 2rem; border-radius: 50px; font-weight: 700;
    text-decoration: none; transition: all 0.3s ease; cursor: pointer; border: none; font-size: 1rem;
    position: relative; overflow: hidden;
}
.btn-primary {
    background: var(--brand-gradient); color: white;
    box-shadow: 0 8px 22px -6px rgba(234, 88, 12, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
.btn-primary::after {
    content: ""; position: absolute; top: 0; left: 0; right: 0; height: 50%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0)); pointer-events: none;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -6px rgba(234, 88, 12, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.5); }
.btn-outline {
    background: rgba(255, 255, 255, 0.5); color: var(--brand-dark);
    border: 1.5px solid rgba(234, 88, 12, 0.55);
    -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
.btn-outline:hover { background: var(--brand-primary); border-color: var(--brand-primary); color: white; transform: translateY(-2px); }

/* --- HERO --- */
.hero { padding: 160px 5% 100px; display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.hero h1 { font-size: 3.5rem; line-height: 1.1; font-weight: 800; color: var(--brand-dark); margin-bottom: 1.5rem; letter-spacing: -1px; }
.text-gradient { background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { font-size: 1.2rem; color: var(--text-body); margin-bottom: 2.5rem; max-width: 550px; line-height: 1.7; }
.mockup-container {
    padding: 12px; border-radius: 26px;
    transform: perspective(1000px) rotateY(-8deg) rotateX(4deg);
    transition: 0.5s; box-shadow: 0 40px 80px -20px rgba(28, 25, 23, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}
.mockup-container:hover { transform: perspective(1000px) rotateY(0deg) rotateX(0deg); }
.mockup-container img { width: 100%; border-radius: 16px; display: block; }

/* --- SECCIONES DIVIDIDAS --- */
.split-section { display: grid; grid-template-columns: 1fr 1fr; gap: 6rem; align-items: center; padding: 100px 5%; }
.split-content h2 { font-size: 2.8rem; color: var(--brand-dark); margin-bottom: 1.5rem; line-height: 1.1; }
.split-content p { font-size: 1.15rem; color: var(--text-body); margin-bottom: 2rem; line-height: 1.6; }
.split-image { border-radius: var(--radius-lg); overflow: hidden; padding: 12px; }
.split-image img { width: 100%; height: auto; display: block; border-radius: 16px; transition: transform 0.5s; }
.split-image:hover img { transform: scale(1.02); }
.reverse { direction: rtl; } .reverse > * { direction: ltr; }

/* Lista de beneficios */
.benefit-list { list-style: none; margin-top: 1rem; }
.benefit-list li { display: flex; align-items: flex-start; gap: 15px; margin-bottom: 1.2rem; font-size: 1.1rem; color: var(--text-main); }
.benefit-list i {
    color: var(--brand-primary); font-size: 1.1rem; margin-top: 2px; padding: 10px; border-radius: 12px; min-width: 40px; text-align: center;
    background: rgba(255, 255, 255, 0.6); border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 4px 12px -4px rgba(234, 88, 12, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.benefit-list strong { color: var(--brand-dark); font-weight: 700; }

/* --- GRID MÓDULOS --- */
.features { padding: 80px 5%; background: transparent; }
.section-header { text-align: center; max-width: 750px; margin: 0 auto 60px; }
.section-header h2 { font-size: 2.8rem; color: var(--brand-dark); margin-bottom: 1rem; }
.section-header p { color: var(--text-body); }
.subtitle {
    color: var(--brand-primary-dark); font-weight: 700; text-transform: uppercase; letter-spacing: 1px; font-size: 0.8rem;
    display: inline-block; margin-bottom: 14px; padding: 6px 14px; border-radius: 999px;
    background: var(--glass-bg-strong);
}

.bento-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.glass-card {
    border-radius: var(--radius-lg); padding: 2.5rem;
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease; display: flex; flex-direction: column;
}
.glass-card:hover {
    transform: translateY(-8px); border-color: rgba(234, 88, 12, 0.35);
    box-shadow: 0 24px 50px -16px rgba(234, 88, 12, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.95);
}
.icon-box {
    width: 52px; height: 52px; border-radius: 14px; display: flex; align-items: center; justify-content: center;
    font-size: 1.4rem; margin-bottom: 1rem; color: white; background: var(--brand-gradient);
    box-shadow: 0 8px 18px -6px rgba(234, 88, 12, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
.glass-card h3 { font-size: 1.3rem; margin-bottom: 0.5rem; color: var(--brand-dark); }
.glass-card p { font-size: 0.95rem; color: var(--text-body); margin-bottom: 1.5rem; flex-grow: 1; }
.card-img { width: 100%; height: 180px; border-radius: 14px; overflow: hidden; margin-top: auto; border: 1px solid rgba(255, 255, 255, 0.8); box-shadow: 0 6px 20px -8px rgba(28, 25, 23, 0.25); }
.card-img img { width: 100%; height: 100%; object-fit: cover; }
.span-2 { grid-column: span 2; }

/* --- PRECIOS --- */
.pricing { padding: 100px 5%; background: transparent; }
.pricing-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; max-width: 1200px; margin: 0 auto; align-items: center; }
.price-card { padding: 3rem 2rem; border-radius: var(--radius-lg); transition: all 0.4s ease; }
.price-card:hover { transform: translateY(-12px); border-color: rgba(234, 88, 12, 0.4); box-shadow: 0 30px 60px -20px rgba(234, 88, 12, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.95); }
.plan-name { font-size: 1.5rem; font-weight: 800; color: var(--brand-dark); }
.price { font-size: 3.5rem; font-weight: 800; margin: 1rem 0; background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.price span { font-size: 1rem; color: var(--text-body); -webkit-text-fill-color: var(--text-body); font-weight: 500; }
.users-badge { display: inline-block; background: rgba(234, 88, 12, 0.1); color: var(--brand-primary-dark); padding: 5px 15px; border-radius: 20px; font-weight: 700; margin-bottom: 2rem; border: 1px solid rgba(234, 88, 12, 0.18); }
.check-list { list-style: none; }
.check-list li { margin-bottom: 0.8rem; display: flex; gap: 10px; color: var(--text-body); font-size: 0.95rem; }
.check-list li i { color: var(--brand-primary); margin-top: 3px; }
.more-features { color: var(--brand-primary); font-weight: 600; margin-top: 10px; display: block; text-align: center; opacity: 0.85; }

/* Plan destacado: vidrio oscuro (grafito) */
.price-card.featured {
    background: rgba(28, 25, 23, 0.78); border-color: rgba(255, 255, 255, 0.14); color: #fafaf9;
    box-shadow: 0 30px 70px -20px rgba(28, 25, 23, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.18);
    transform: scale(1.03);
}
.price-card.featured::before {
    background:
        radial-gradient(120% 60% at 0% 0%, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 45%),
        radial-gradient(80% 50% at 100% 100%, rgba(234, 88, 12, 0.28) 0%, rgba(234, 88, 12, 0) 60%);
}
.price-card.featured::after {
    content: "Recomendado"; position: absolute; top: 18px; right: 18px; z-index: 3;
    background: var(--brand-gradient); color: white; font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 0.8rem;
    padding: 4px 12px; border-radius: 999px; box-shadow: 0 6px 14px -4px rgba(234, 88, 12, 0.6);
}
.price-card.featured:hover { transform: scale(1.03) translateY(-12px); }
.price-card.featured .plan-name { color: #fafaf9; }
.price-card.featured .price span { color: #d6d3d1; -webkit-text-fill-color: #d6d3d1; }
.price-card.featured .users-badge { background: rgba(245, 158, 11, 0.16); color: #fbbf24; border-color: rgba(245, 158, 11, 0.3); }
.price-card.featured .check-list li { color: #e7e5e4; }
.price-card.featured .check-list li i { color: var(--brand-secondary); }
.price-card.featured .more-features { color: #fbbf24; }

/* --- TESTIMONIOS --- */
.testimonials { padding: 80px 5%; background: transparent; }
.testimonial-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; margin-top: 40px; }
.testimonial-card { padding: 2rem; border-radius: var(--radius-md); }
.stars { color: var(--brand-secondary); margin-bottom: 1rem; }
.quote { font-style: italic; color: var(--text-main); margin-bottom: 1.5rem; font-size: 1.05rem; line-height: 1.6; }
.author { display: flex; align-items: center; gap: 15px; }
.author img { width: 50px; height: 50px; border-radius: 50%; object-fit: cover; }
.author-info h5 { font-weight: 700; color: var(--brand-dark); }
.author-info span { font-size: 0.85rem; color: var(--text-body); }

/* --- FAQ --- */
.faq-section { padding: 80px 5%; max-width: 900px; margin: 0 auto; width: 100%; }
.faq-item { margin-bottom: 1rem; border-radius: 16px; overflow: hidden; transition: 0.3s; }
.faq-question { padding: 1.4rem 1.5rem; font-weight: 700; cursor: pointer; display: flex; justify-content: space-between; align-items: center; color: var(--brand-dark); list-style: none; font-size: 1.1rem; }
.faq-question::-webkit-details-marker { display: none; }
.faq-question::after { content: "+"; font-size: 1.5rem; color: var(--brand-primary); font-weight: 400; }
details[open] .faq-question::after { content: "-"; }
.faq-answer { padding: 1rem 1.5rem 1.5rem; color: var(--text-body); line-height: 1.6; border-top: 1px solid rgba(255, 255, 255, 0.7); }
.faq-item:hover { background: var(--glass-bg-strong); }

/* --- PÁGINAS LEGALES --- */
.legal-content { max-width: 800px; margin: 130px auto 60px; padding: 3rem 5%; flex-grow: 1; border-radius: var(--radius-lg); width: calc(100% - 32px); }
.legal-content h1 { font-size: 2.5rem; color: var(--brand-dark); margin-bottom: 1rem; }
.legal-content h3 { font-size: 1.5rem; color: var(--brand-dark); margin-top: 2rem; margin-bottom: 1rem; }
.legal-content p, .legal-content ul { color: var(--text-body); font-size: 1.1rem; line-height: 1.8; margin-bottom: 1rem; }
.legal-content ul { padding-left: 20px; }

/* --- FOOTER --- */
.footer { background: var(--brand-dark); color: white; padding: 60px 5% 30px; margin-top: auto; position: relative; }
.footer::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: var(--brand-gradient); }
.footer-logo { height: 40px; filter: brightness(0) invert(1); margin-bottom: 1.5rem; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 3rem; }
.footer h4 { margin-bottom: 1.5rem; color: white; }
.footer ul { list-style: none; }
.footer li { margin-bottom: 0.8rem; }
.footer a { color: #a8a29e; text-decoration: none; transition: 0.3s; }
.footer a:hover { color: white; }
.footer-contact a { color: white; }
.footer-contact a:hover { color: var(--brand-secondary); }

/* WHATSAPP FLOAT */
.whatsapp-float {
    position: fixed; bottom: 30px; right: 30px; background: #25D366; color: white;
    width: 65px; height: 65px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 32px; z-index: 999; transition: 0.3s; text-decoration: none;
    box-shadow: 0 12px 28px -6px rgba(37, 211, 102, 0.6), 0 0 0 6px rgba(255, 255, 255, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
.whatsapp-float:hover { transform: scale(1.1); }

/* Navegadores sin backdrop-filter: vidrio más opaco para mantener legibilidad */
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    :root { --glass-bg: rgba(255, 255, 255, 0.88); --glass-bg-strong: rgba(255, 255, 255, 0.95); }
    .price-card.featured { background: rgba(28, 25, 23, 0.96); }
}

@media (prefers-reduced-motion: reduce) {
    .blob, .morph-bg::before, .morph-bg::after { animation: none; }
}

/* RESPONSIVE */
@media (max-width: 992px) {
    .navbar { top: 10px; width: calc(100% - 24px); padding: 0.6rem 1rem; border-radius: 18px; }
    .logo-img { height: 40px; }
    .hero { grid-template-columns: 1fr; text-align: center; padding-top: 130px; }
    .nav-menu { display: none; }
    .split-section { grid-template-columns: 1fr; gap: 3rem; text-align: center; padding: 60px 5%; }
    .split-content { text-align: center; }
    .reverse { direction: ltr; }
    .bento-grid { grid-template-columns: 1fr; }
    .span-2 { grid-column: span 1; }
    .benefit-list li { justify-content: flex-start; text-align: left; }
    .price-card.featured, .price-card.featured:hover { transform: none; }
}
