/* ============================================================
   DÉTAIL ELEVÉ — Custom CSS (animations + utilities)
   Complementa Tailwind CDN
   ============================================================ */

:root {
    /* Brand */
    --brand-amber: #f59e0b;
    --brand-dark: #080808;
    --brand-graphite: #121212;

    /* Design tokens (espejo del original app.css) */
    --background: hsl(0 0% 3.9%);
    --foreground: hsl(0 0% 98%);
    --card: hsl(0 0% 5%);
    --card-foreground: hsl(0 0% 98%);
    --border: hsl(0 0% 14.9%);
    --input: hsl(0 0% 14.9%);
    --ring: hsl(0 0% 83.1%);
    --muted: hsl(0 0% 16%);
    --muted-foreground: hsl(0 0% 100%);
    --primary: hsl(0 0% 98%);
    --primary-foreground: hsl(0 0% 9%);
    --accent: hsl(0 0% 14.9%);
    --accent-foreground: hsl(0 0% 98%);
    --radius: 0.5rem;

    /* Escala tipográfica ligeramente mayor (igual que original) */
    font-size: 16px;
}

/* Forzar italic en títulos principales (igual que @layer base original) */
h1, .hero-title {
    font-style: italic !important;
}

/* Normalizar border-color global */
*, ::after, ::before {
    border-color: var(--border);
}

/* ---------- Glass Card ---------- */
.glass-card {
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s ease;
}
.glass-card:hover {
    border-color: rgba(245, 158, 11, 0.3);
    background: rgba(255, 255, 255, 0.04);
}

/* ---------- Animaciones Hero ---------- */
@keyframes slow-zoom {
    from { transform: scale(1.05); }
    to   { transform: scale(1.15); }
}
.animate-slow-zoom {
    animation: slow-zoom 20s ease-in-out infinite alternate;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(40px); }
    to   { opacity: 1; transform: translateY(0); }
}
.animate-fade-in-up {
    animation: fadeInUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes pulse-soft {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.8; }
}
.animate-pulse-soft {
    animation: pulse-soft 3s infinite;
}

/* ---------- Testimonios Marquee ---------- */
@keyframes marquee {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}
.animate-marquee {
    display: flex;
    width: max-content;
    animation: marquee 30s linear infinite;
}
.animate-marquee:hover {
    animation-play-state: paused;
}

/* ---------- FAQ Accordion ---------- */
.faq-answer {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 0.4s ease,
                padding 0.4s ease;
    padding: 0 2rem;
}
.faq-item.active .faq-answer {
    max-height: 500px;
    opacity: 1;
    padding: 1rem 2rem 2rem;
}
.faq-item.active {
    border-color: rgba(245, 158, 11, 0.3) !important;
}
.faq-item.active .faq-chevron {
    transform: rotate(180deg);
    color: var(--brand-amber);
}
.faq-chevron {
    transition: transform 0.3s ease, color 0.3s ease;
}

/* ---------- Scroll Reveal ---------- */
.reveal {
    opacity: 1;
    transform: none;
    transition: all 0.8s ease-out;
}
html.js .reveal {
    opacity: 1;
    transform: none;
}
html.js .reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- No scrollbar ---------- */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* ---------- Before/After Slider ---------- */
.ba-container {
    position: relative;
    overflow: visible;
    cursor: ew-resize;
    user-select: none;
    touch-action: none;
    border-radius: 3rem;
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 25px 80px rgba(0,0,0,0.6);
    aspect-ratio: 4/3;
    background: #050505;
}
@media (min-width: 768px) {
    .ba-container { aspect-ratio: 16/9; }
}
.ba-after,
.ba-before {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: var(--ba-fit, cover);
    object-position: var(--ba-position, center);
    pointer-events: none;
    border-radius: inherit;
}
.ba-after-wrap,
.ba-before-wrap {
    position: absolute;
    inset: 0;
    overflow: hidden;
    border-radius: inherit;
}
.ba-handle {
    position: absolute;
    top: 0; bottom: 0;
    width: 3px;
    background: var(--brand-amber);
    transform: translateX(-50%);
    z-index: 10;
}
.ba-handle::before, .ba-handle::after {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 40px; height: 40px;
    border-radius: 50%;
    background: var(--brand-amber);
    border: 3px solid black;
}
.ba-handle::before { top: 50%; transform: translate(-50%, -50%); }
.ba-handle::after  { display: none; }
.ba-side-label {
    position: absolute;
    top: 50%;
    z-index: 8;
    display: none;
    transform: translateY(-50%);
    padding: 0.45rem 0.7rem;
    border-radius: 9999px;
    background: rgba(0,0,0,0.72);
    backdrop-filter: blur(8px);
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.22em;
    line-height: 1;
    text-transform: uppercase;
    pointer-events: none;
    box-shadow: 0 12px 30px rgba(0,0,0,0.35);
}
.ba-container[data-fit="contain"] .ba-side-label {
    display: block;
}
.ba-side-label-before {
    left: clamp(1rem, 8%, 5rem);
    color: white;
}
.ba-side-label-after {
    right: clamp(1rem, 8%, 5rem);
    color: var(--brand-amber);
}
.ba-label {
    position: absolute;
    bottom: 1rem;
    z-index: 9;
    padding: 0.25rem 0.75rem;
    background: rgba(0,0,0,0.7);
    color: white;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    border-radius: 9999px;
    backdrop-filter: blur(8px);
}
.ba-label-before { left: 1rem; }
.ba-label-after  { right: 1rem; color: var(--brand-amber); }

/* ---------- Mobile Sticky CTA ---------- */
.mobile-sticky-cta {
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.8);
}

/* ---------- Hero ambient glow ---------- */
.hero-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
}

/* ---------- Gradient text utility ---------- */
.text-gradient-amber {
    background: linear-gradient(135deg, #d97706, #f59e0b, #fde68a);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ---------- Card hover glow (service cards) ---------- */
.card-hover-glow {
    transition: box-shadow 0.4s ease, border-color 0.4s ease;
}
.card-hover-glow:hover {
    box-shadow: 0 0 60px rgba(245, 158, 11, 0.12), 0 25px 50px rgba(0,0,0,0.5);
}

/* ---------- Número del paso (proceso) ---------- */
.step-number {
    font-variant-numeric: tabular-nums;
    -webkit-text-stroke: 1px rgba(245, 158, 11, 0.3);
    color: transparent;
    font-size: 5rem;
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.05em;
}

/* ---------- Shine effect sobre botones ---------- */
@keyframes shine {
    from { transform: translateX(-100%) skewX(-15deg); }
    to   { transform: translateX(200%) skewX(-15deg); }
}
.btn-shine {
    position: relative;
    overflow: hidden;
}
.btn-shine::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.25), transparent);
    transform: translateX(-100%) skewX(-15deg);
}
.btn-shine:hover::after {
    animation: shine 0.6s ease forwards;
}

/* ---------- Parallax overlay gradiente hero ---------- */
.hero-overlay-gradient {
    background: linear-gradient(
        to right,
        rgba(8, 8, 8, 0.95) 0%,
        rgba(8, 8, 8, 0.75) 40%,
        rgba(8, 8, 8, 0.2) 100%
    );
}
@media (max-width: 1024px) {
    .hero-overlay-gradient {
        background: linear-gradient(
            to bottom,
            rgba(8, 8, 8, 0.3) 0%,
            rgba(8, 8, 8, 0.85) 60%,
            rgba(8, 8, 8, 0.98) 100%
        );
    }
}

/* ---------- Testimonial card ---------- */
.testimonial-card {
    flex-shrink: 0;
    width: 320px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 1.5rem;
    padding: 1.5rem;
    transition: border-color 0.3s ease;
}
.testimonial-card:hover {
    border-color: rgba(245, 158, 11, 0.2);
}

/* ---------- Marquee fade masks (laterales) ---------- */
.marquee-fade {
    -webkit-mask-image: linear-gradient(
        to right,
        transparent 0%,
        black 8%,
        black 92%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to right,
        transparent 0%,
        black 8%,
        black 92%,
        transparent 100%
    );
}

/* ---------- Ambient glow dot (decorativo) ---------- */
.ambient-dot {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
}

/* ---------- Línea separadora dorada ---------- */
.gold-line {
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, #f59e0b, #fde68a);
    border-radius: 2px;
}

/* ---------- Nav scrolled (más opaco) ---------- */
.nav-scrolled {
    background: rgba(0, 0, 0, 0.98) !important;
    box-shadow: 0 4px 30px rgba(0,0,0,0.5);
}
