/* ============================================
   PIKEMMA Food & Wash — Landing Page Styles
   6 Temas + Animaciones Premium
   ============================================ */

/* ---- Google Fonts ---- */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;600;700;800;900&family=Inter:wght@400;500;600&display=swap');

/* ============================================
   TEMA 1: CLÁSICO (Default)
   ============================================ */
:root,
[data-theme="classic"] {
    --bg-primary: #0d0d0d;
    --bg-secondary: #1a1a1a;
    --accent: #E85D04;
    --accent-light: #FF7B2E;
    --accent-glow: rgba(232, 93, 4, 0.4);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --card-bg: rgba(26, 26, 26, 0.6);
    --border-color: rgba(232, 93, 4, 0.2);
    --particle-color: rgba(232, 93, 4, 0.15);
    --btn-shadow: 0 8px 32px rgba(232, 93, 4, 0.3);
    --btn-hover-shadow: 0 12px 48px rgba(232, 93, 4, 0.5);
    --overlay-gradient: linear-gradient(180deg, transparent 0%, rgba(0,0,0,0.3) 100%);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    --logo-filter: none;
    --bubble-opacity: 0.12;
    --page-bg-effect: none;
}

/* ============================================
   TEMA 2: NEÓN
   ============================================ */
[data-theme="neon"] {
    --bg-primary: #050505;
    --bg-secondary: #0f0f0f;
    --accent: #FF6B00;
    --accent-light: #FF9640;
    --accent-glow: rgba(255, 107, 0, 0.6);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.8);
    --card-bg: rgba(15, 15, 15, 0.8);
    --border-color: rgba(255, 107, 0, 0.4);
    --particle-color: rgba(255, 107, 0, 0.2);
    --btn-shadow: 0 0 30px rgba(255, 107, 0, 0.4), 0 0 60px rgba(255, 107, 0, 0.15);
    --btn-hover-shadow: 0 0 50px rgba(255, 107, 0, 0.6), 0 0 100px rgba(255, 107, 0, 0.25);
    --overlay-gradient: linear-gradient(180deg, transparent 0%, rgba(255, 107, 0, 0.03) 100%);
    --bubble-opacity: 0.2;
}

/* ============================================
   TEMA 3: ELEGANTE
   ============================================ */
[data-theme="elegant"] {
    --bg-primary: #12121a;
    --bg-secondary: #1e1e2e;
    --accent: #C9A84C;
    --accent-light: #E0C068;
    --accent-glow: rgba(201, 168, 76, 0.35);
    --text-primary: #f0ece2;
    --text-secondary: rgba(240, 236, 226, 0.7);
    --card-bg: rgba(30, 30, 46, 0.6);
    --border-color: rgba(201, 168, 76, 0.25);
    --particle-color: rgba(201, 168, 76, 0.1);
    --btn-shadow: 0 8px 32px rgba(201, 168, 76, 0.2);
    --btn-hover-shadow: 0 12px 48px rgba(201, 168, 76, 0.4);
    --overlay-gradient: linear-gradient(180deg, transparent 0%, rgba(201, 168, 76, 0.03) 100%);
    --bubble-opacity: 0.08;
}

/* ============================================
   TEMA 4: TROPICAL
   ============================================ */
[data-theme="tropical"] {
    --bg-primary: #1a0a2e;
    --bg-secondary: #2d1250;
    --accent: #FF8C42;
    --accent-light: #FFB07C;
    --accent-glow: rgba(255, 140, 66, 0.4);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.8);
    --card-bg: rgba(45, 18, 80, 0.5);
    --border-color: rgba(255, 140, 66, 0.3);
    --particle-color: rgba(255, 140, 66, 0.15);
    --btn-shadow: 0 8px 32px rgba(255, 140, 66, 0.3);
    --btn-hover-shadow: 0 12px 48px rgba(255, 140, 66, 0.5);
    --overlay-gradient: linear-gradient(180deg, rgba(255, 94, 98, 0.05) 0%, rgba(255, 140, 66, 0.08) 100%);
    --page-bg-effect: linear-gradient(135deg, #1a0a2e 0%, #2d1250 40%, #3d1a6e 70%, #1a0a2e 100%);
    --bubble-opacity: 0.18;
}

/* ============================================
   TEMA 5: MINIMALISTA
   ============================================ */
[data-theme="minimal"] {
    --bg-primary: #fafafa;
    --bg-secondary: #f0f0f0;
    --accent: #E85D04;
    --accent-light: #FF7B2E;
    --accent-glow: rgba(232, 93, 4, 0.2);
    --text-primary: #1a1a1a;
    --text-secondary: rgba(26, 26, 26, 0.6);
    --card-bg: rgba(255, 255, 255, 0.8);
    --border-color: rgba(232, 93, 4, 0.15);
    --particle-color: rgba(232, 93, 4, 0.06);
    --btn-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    --btn-hover-shadow: 0 8px 32px rgba(232, 93, 4, 0.2);
    --overlay-gradient: none;
    --logo-filter: none;
    --bubble-opacity: 0.06;
}

/* ============================================
   TEMA 6: CYBERPUNK
   ============================================ */
[data-theme="cyberpunk"] {
    --bg-primary: #0a001a;
    --bg-secondary: #16003B;
    --accent: #FF5E00;
    --accent-light: #FF8A3D;
    --accent-glow: rgba(255, 94, 0, 0.5);
    --text-primary: #e0e0ff;
    --text-secondary: rgba(224, 224, 255, 0.7);
    --card-bg: rgba(22, 0, 59, 0.7);
    --border-color: rgba(255, 94, 0, 0.35);
    --particle-color: rgba(255, 94, 0, 0.18);
    --btn-shadow: 0 0 20px rgba(255, 94, 0, 0.3), 0 0 40px rgba(138, 43, 226, 0.15);
    --btn-hover-shadow: 0 0 40px rgba(255, 94, 0, 0.5), 0 0 80px rgba(138, 43, 226, 0.25);
    --overlay-gradient: linear-gradient(180deg, rgba(138, 43, 226, 0.05) 0%, rgba(255, 94, 0, 0.03) 100%);
    --page-bg-effect: linear-gradient(135deg, #0a001a 0%, #16003B 50%, #1a0033 100%);
    --bubble-opacity: 0.15;
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    background-image: var(--page-bg-effect, none);
    color: var(--text-primary);
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   PARTICLES / BUBBLES BACKGROUND
   ============================================ */
#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.bubble {
    position: fixed;
    border-radius: 50%;
    background: var(--accent);
    opacity: var(--bubble-opacity);
    pointer-events: none;
    z-index: 0;
    animation: bubbleFloat linear infinite;
}

@keyframes bubbleFloat {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }
    10% {
        opacity: var(--bubble-opacity);
    }
    90% {
        opacity: var(--bubble-opacity);
    }
    100% {
        transform: translateY(-10vh) scale(1);
        opacity: 0;
    }
}

/* ============================================
   AMBIENT GLOW ORB
   ============================================ */
.ambient-orb {
    position: fixed;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
    animation: orbFloat 8s ease-in-out infinite;
}

.ambient-orb:nth-child(1) {
    top: 10%;
    right: -100px;
    animation-delay: 0s;
}

.ambient-orb:nth-child(2) {
    bottom: 20%;
    left: -100px;
    animation-delay: -4s;
    width: 200px;
    height: 200px;
}

@keyframes orbFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -20px) scale(1.1); }
    50% { transform: translate(-20px, 20px) scale(0.9); }
    75% { transform: translate(10px, -30px) scale(1.05); }
}

/* ============================================
   MAIN CONTAINER
   ============================================ */
.landing-container {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100dvh;
    padding: 40px 20px;
    max-width: 480px;
    margin: 0 auto;
}

/* ============================================
   LOGO
   ============================================ */
.logo-wrapper {
    margin-bottom: 48px;
    text-align: center;
    opacity: 0;
    animation: logoReveal 1s cubic-bezier(0.16, 1, 0.3, 1) 0.2s forwards;
}

.logo-wrapper img {
    width: 260px;
    max-width: 70vw;
    height: auto;
    filter: var(--logo-filter);
    transition: filter 0.5s ease, transform 0.5s ease;
}

.logo-wrapper img:hover {
    transform: scale(1.05);
}

/* Logo glow pulse */
.logo-glow {
    position: relative;
    display: inline-block;
}

.logo-glow::after {
    content: '';
    position: absolute;
    inset: -20px;
    background: radial-gradient(ellipse at center, var(--accent-glow), transparent 70%);
    border-radius: 50%;
    z-index: -1;
    animation: logoPulse 3s ease-in-out infinite;
    filter: blur(20px);
}

@keyframes logoPulse {
    0%, 100% { opacity: 0.4; transform: scale(0.95); }
    50% { opacity: 0.7; transform: scale(1.05); }
}

@keyframes logoReveal {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.9);
        filter: blur(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* ============================================
   LINK BUTTONS
   ============================================ */
.links-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    align-items: center;
}

.link-btn {
    display: block;
    width: 100%;
    max-width: 380px;
    text-decoration: none;
    cursor: pointer;
    position: relative;
    border-radius: 16px;
    overflow: visible;
    /* Animation initial state */
    opacity: 0;
    transform: translateY(40px);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.4s ease,
                filter 0.3s ease;
}

.link-btn.visible {
    opacity: 1;
    transform: translateY(0);
}

.link-btn img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Glow effect behind button */
.link-btn::before {
    content: '';
    position: absolute;
    inset: 5px;
    background: var(--accent);
    border-radius: 16px;
    opacity: 0;
    filter: blur(20px);
    z-index: -1;
    transition: opacity 0.4s ease;
}

/* Hover states */
.link-btn:hover {
    transform: translateY(-4px) scale(1.03);
    box-shadow: var(--btn-hover-shadow);
}

.link-btn:hover::before {
    opacity: 0.3;
}

.link-btn:hover img {
    transform: scale(1.02);
}

/* Active/press state */
.link-btn:active {
    transform: translateY(0) scale(0.98);
    transition-duration: 0.1s;
}

/* Stagger animation delays */
.link-btn:nth-child(1) { animation: btnSlideIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s forwards; }
.link-btn:nth-child(2) { animation: btnSlideIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.7s forwards; }
.link-btn:nth-child(3) { animation: btnSlideIn 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.9s forwards; }

@keyframes btnSlideIn {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
        filter: blur(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

/* Ripple effect on click */
.link-btn .ripple {
    position: absolute;
    border-radius: 50%;
    background: var(--accent-glow);
    transform: scale(0);
    animation: rippleEffect 0.6s linear;
    pointer-events: none;
}

@keyframes rippleEffect {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

/* ============================================
   SHIMMER EFFECT (NEON & CYBERPUNK)
   ============================================ */
[data-theme="neon"] .link-btn::after,
[data-theme="cyberpunk"] .link-btn::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg,
        transparent 30%,
        var(--accent-glow) 50%,
        transparent 70%
    );
    border-radius: 18px;
    z-index: -1;
    animation: shimmer 3s ease-in-out infinite;
    opacity: 0.5;
}

@keyframes shimmer {
    0%, 100% { transform: translateX(-100%); }
    50% { transform: translateX(100%); }
}

/* ============================================
   CYBERPUNK GLITCH EFFECT
   ============================================ */
[data-theme="cyberpunk"] .logo-wrapper img {
    animation: glitchSubtle 5s ease-in-out infinite;
}

@keyframes glitchSubtle {
    0%, 95%, 100% { transform: none; filter: none; }
    96% { transform: translate(-2px, 1px); filter: hue-rotate(30deg); }
    97% { transform: translate(2px, -1px); filter: hue-rotate(-30deg); }
    98% { transform: translate(-1px, -1px); filter: none; }
}

/* Scan line effect for cyberpunk */
[data-theme="cyberpunk"] .landing-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(255, 94, 0, 0.015) 2px,
        rgba(255, 94, 0, 0.015) 4px
    );
    pointer-events: none;
    z-index: 999;
}

/* ============================================
   ELEGANT THEME ADJUSTMENTS
   ============================================ */
[data-theme="elegant"] .logo-wrapper img {
    filter: brightness(0.9) contrast(1.1) sepia(0.3) hue-rotate(-10deg);
}

[data-theme="elegant"] .link-btn {
    border: 1px solid var(--border-color);
}

/* ============================================
   MINIMAL THEME ADJUSTMENTS
   ============================================ */
[data-theme="minimal"] .link-btn {
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.1));
}

[data-theme="minimal"] .ambient-orb {
    opacity: 0.3;
}

[data-theme="minimal"] .logo-glow::after {
    display: none;
}

/* ============================================
   FOOTER
   ============================================ */
.landing-footer {
    margin-top: 48px;
    text-align: center;
    opacity: 0;
    animation: fadeIn 1s ease 1.3s forwards;
}

.landing-footer p {
    font-size: 12px;
    color: var(--text-secondary);
    letter-spacing: 1px;
    text-transform: uppercase;
    font-family: var(--font-body);
}

.landing-footer .credits-footer {
    font-size: 10px;
    margin-top: 6px;
    opacity: 0.8;
}

.landing-footer .credits-footer a,
.landing-footer .credits-footer a:link,
.landing-footer .credits-footer a:visited,
.landing-footer .credits-footer a:active {
    color: var(--accent-light) !important;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.landing-footer .credits-footer a:hover {
    color: var(--accent) !important;
    text-shadow: 0 0 8px var(--accent-glow);
}

.landing-footer .divider {
    width: 40px;
    height: 2px;
    background: var(--accent);
    margin: 0 auto 12px;
    border-radius: 1px;
    opacity: 0.5;
}

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

/* ============================================
   LOADING SCREEN
   ============================================ */
.loading-screen {
    position: fixed;
    inset: 0;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 3px solid var(--border-color);
    border-top-color: var(--accent);
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 480px) {
    .landing-container {
        padding: 32px 16px;
    }

    .logo-wrapper img {
        width: 200px;
    }

    .logo-wrapper {
        margin-bottom: 36px;
    }

    .links-container {
        gap: 16px;
    }
}

@media (max-width: 360px) {
    .logo-wrapper img {
        width: 180px;
    }
}

/* ============================================
   PREFERS REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .bubble, .ambient-orb {
        display: none;
    }

    .logo-wrapper,
    .link-btn,
    .landing-footer {
        opacity: 1;
        transform: none;
    }
}
