/* ---------- VARIABLES ---------- */
:root {
    --bg-dark: #0A0A0C;
    --card-dark: #1A1A20;
    --gold: #D4AF37;
    --gold-light: #FFD966;
    --error: #ff4444;
    --text-muted: #aaa;
    --border-glow: 0 0 8px rgba(212,175,55,0.5);
    --shadow-card: 0 12px 25px rgba(0,0,0,0.3);
    --transition: all 0.2s ease;
}

/* RESET Y BASE */
* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-dark);
    color: #EAEAEA;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
    position: fixed;
}
.bg-texture {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-dark);
    z-index: -1;
}
.bg-texture::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(circle at 20% 40%, rgba(212,175,55,0.08) 1px, transparent 1px);
    background-size: 40px 40px;
    pointer-events: none;
}

/* SCROLL HORIZONTAL - MÁS CONTROLADO */
.scroll-x {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    z-index: 10;
    -webkit-overflow-scrolling: touch;
    scroll-snap-stop: always;
}
.scroll-x::-webkit-scrollbar { display: none; }
.panels { display: flex; width: 500%; height: 100%; }
.panel {
    width: 100vw;
    height: 100vh;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    padding: 5rem 1rem 1.5rem;
    overflow-y: auto;
    background: rgba(5, 5, 7, 0.45);
    backdrop-filter: blur(4px);
}
@media (min-width: 700px) { .panel { padding: 5.5rem 1.5rem 2rem; } }

/* HEADER FIJO */
.fixed-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 0.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 200;
    background: rgba(5, 5, 5, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(212,175,55,0.3);
    flex-wrap: wrap;
    gap: 0.5rem;
}
.logo { display: flex; align-items: center; gap: 0.5rem; font-family: 'Playfair Display', serif; font-size: 0.9rem; font-weight: 600; color: var(--gold); }
.logo-img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; border: 1px solid var(--gold); }
.nav-buttons-header { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.btn-outline {
    background: transparent;
    border: 1.5px solid var(--gold);
    padding: 0.3rem 0.6rem;
    border-radius: 40px;
    color: var(--gold);
    cursor: pointer;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    transition: var(--transition);
    white-space: nowrap;
}
.btn-outline:hover { background: rgba(212,175,55,0.15); transform: translateY(-2px); }
@media (min-width: 700px) {
    .fixed-header { padding: 0.8rem 1.5rem; }
    .btn-outline { padding: 0.3rem 0.8rem; font-size: 0.75rem; }
    .logo { font-size: 1.1rem; }
}

/* HERO */
.hero {
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 80vh;
    padding-top: 1rem;
}
@media (max-width: 700px) {
    .hero { padding-top: 2rem; }
}
.hero h1 {
    font-size: 1.8rem;
    font-family: 'Permanent Marker', cursive;
    background: linear-gradient(135deg, #fff, var(--gold));
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}
@media (min-width: 700px) { .hero h1 { font-size: 3rem; } }
.btn-principal {
    background: var(--gold);
    color: #050505;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 50px;
    font-weight: bold;
    font-size: 0.9rem;
    cursor: pointer;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 15px rgba(212,175,55,0.5);
    transition: var(--transition);
}
.btn-principal:hover { background: var(--gold-light); transform: scale(0.98); }

/* BENEFICIOS */
.beneficios {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    margin: 1.5rem 0 3rem 0;
}
.beneficio {
    background: rgba(0, 0, 0, 0.6);
    border-radius: 1.2rem;
    padding: 0.8rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid rgba(212,175,55,0.4);
    transition: var(--transition);
}
.beneficio:hover { transform: translateY(-3px); border-color: var(--gold); }
.beneficio-icon { width: 45px; height: 45px; flex-shrink: 0; }
.beneficio-icon svg { width: 100%; height: 100%; stroke: var(--gold); stroke-width: 1.8; fill: none; }
.beneficio h3 { font-size: 1rem; color: var(--gold); }
.beneficio p { font-size: 0.7rem; color: #ccc; }
@media (min-width: 700px) {
    .beneficios { flex-direction: row; justify-content: center; gap: 1.2rem; }
    .beneficio { width: 220px; flex-direction: column; text-align: center; padding: 1rem; }
    .beneficio-icon { margin: 0 auto; width: 60px; height: 60px; }
}

/* VITRINA Y SERVICIOS */
.vitrina-title, .servicios-title, .mural-title, .perfil-title {
    font-size: 1.5rem;
    text-align: center;
    margin-bottom: 1.2rem;
    color: var(--gold);
    font-family: 'Permanent Marker', cursive;
    letter-spacing: 1px;
}

/* GRID DE CAFÉS */
.grid-cafes {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.8rem;
    align-items: stretch;
    padding: 0.5rem;
}

/* GRID DE SERVICIOS - MISMO ESTILO QUE CAFÉS */
.grid-servicios {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.8rem;
    align-items: stretch;
    padding: 0.5rem;
}

/* TARJETA DE CAFÉ */
.cafe-card {
    background: rgba(20, 20, 28, 0.95);
    border-radius: 24px;
    padding: 1.2rem;
    border: 1px solid rgba(212, 175, 55, 0.4);
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 480px;
    position: relative;
}

.cafe-card:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: var(--shadow-card);
}

/* TARJETA DE SERVICIO - MISMA ALTURA QUE CAFÉ */
.servicio-card {
    background: rgba(20, 20, 28, 0.95);
    border-radius: 24px;
    padding: 1.2rem;
    border: 1px solid rgba(212, 175, 55, 0.4);
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 480px;
    position: relative;
}

.servicio-card:hover {
    transform: translateY(-5px);
    border-color: var(--gold);
    box-shadow: var(--shadow-card);
}

/* IMAGEN - COMPLETA SIN RECORTAR, ANCHO COMPLETO */
.cafe-img, .servicio-img {
    width: 100%;
    height: auto;
    min-height: 180px;
    max-height: 280px;
    object-fit: contain;
    object-position: center;
    border-radius: 18px;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #2A2A30, #1A1A20);
}

/* Para móviles */
@media (max-width: 700px) {
    .cafe-img, .servicio-img {
        min-height: 150px;
        max-height: 220px;
    }
}

/* Fallback para imágenes rotas */
.cafe-img[src=""], .cafe-img:not([src]), 
.cafe-img[src*="placeholder"], 
.cafe-img[src*="placehold.co"],
.servicio-img[src=""], .servicio-img:not([src]),
.servicio-img[src*="placeholder"], 
.servicio-img[src*="placehold.co"] {
    background: linear-gradient(135deg, #D4AF37, #8B6914);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 3rem;
    min-height: 180px;
}

/* BADGES */
.categoria-badge, .servicio-badge {
    position: absolute;
    top: -12px;
    left: 12px;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: #2A2A30;
    color: var(--gold);
    font-weight: bold;
    font-size: 0.65rem;
    padding: 0.3rem 0.7rem;
    border-radius: 40px;
    border: 1px solid var(--gold);
    z-index: 10;
    backdrop-filter: blur(4px);
}
.categoria-badge.recomendado-badge {
    background: var(--gold);
    color: #000;
    border: none;
    box-shadow: 0 0 12px rgba(212,175,55,0.7);
}

/* NOMBRE */
.cafe-nombre, .servicio-nombre {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--gold);
    margin: 0.3rem 0;
    font-family: 'Permanent Marker', cursive;
    line-height: 1.3;
    min-height: 3rem;
}

/* ORIGEN */
.cafe-origen {
    font-size: 0.7rem;
    color: #aaa;
    margin: 0.2rem 0 0.5rem 0;
    line-height: 1.4;
    min-height: 2.5rem;
}

/* DESCRIPCIÓN SERVICIO */
.servicio-desc {
    font-size: 0.75rem;
    color: #bbb;
    margin: 0.5rem 0;
    line-height: 1.4;
    min-height: 3rem;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.servicio-duracion {
    font-size: 0.7rem;
    color: #D4AF37;
    margin: 0.2rem 0;
}

/* NOTAS DE CATA */
.cafe-notas {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 0.6rem 0;
    min-height: 2.8rem;
}

.nota {
    background: rgba(212, 175, 55, 0.15);
    padding: 0.25rem 0.65rem;
    border-radius: 20px;
    font-size: 0.7rem;
    color: #FFD966;
    line-height: 1.3;
    white-space: normal;
    word-break: keep-all;
}

/* PRECIO */
.cafe-precio, .servicio-precio { 
    font-size: 1.1rem; 
    font-weight: bold; 
    margin: 0.5rem 0 0.3rem 0; 
    color: var(--gold);
    margin-top: auto;
}

/* BOTONES */
.btn-elegir, .btn-reservar {
    width: 100%;
    background: var(--gold);
    color: #050505;
    border: none;
    padding: 0.7rem 0.5rem;
    border-radius: 40px;
    font-weight: bold;
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 0.8rem;
}
.btn-elegir:hover, .btn-reservar:hover { 
    background: var(--gold-light); 
    transform: scale(0.98); 
}

/* RESPONSIVE */
@media (max-width: 700px) {
    .grid-cafes, .grid-servicios {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }
    
    .cafe-card, .servicio-card {
        min-height: 440px;
        padding: 1rem;
    }
    
    .cafe-img, .servicio-img {
        height: 150px;
    }
    
    .cafe-nombre, .servicio-nombre {
        font-size: 1rem;
        min-height: 2.5rem;
    }
    
    .cafe-origen {
        min-height: 2rem;
        font-size: 0.65rem;
    }
    
    .cafe-notas {
        min-height: 2.2rem;
        gap: 0.3rem;
    }
    
    .nota {
        font-size: 0.6rem;
        padding: 0.15rem 0.5rem;
    }
}

@media (min-width: 701px) and (max-width: 1000px) {
    .grid-cafes, .grid-servicios {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1001px) {
    .grid-cafes, .grid-servicios {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* PERFIL (mantiene igual) */
.dashboard-container { max-width: 1200px; margin: 0 auto; width: 100%; }
.profile-header-card {
    background: linear-gradient(135deg, #1E1E24, #141418);
    border-radius: 32px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    border: 1px solid rgba(212,175,55,0.3);
}
.profile-avatar { display: flex; align-items: center; gap: 0.8rem; }
.avatar-circle {
    width: 50px;
    height: 50px;
    background: var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    color: #0A0A0C;
    font-family: 'Permanent Marker', cursive;
}
.profile-info h2 { font-size: 1.2rem; margin-bottom: 0.2rem; color: var(--gold); }
.logout-btn {
    background: rgba(255,68,68,0.2);
    border: 1px solid #ff4444;
    color: #ff8888;
    padding: 0.3rem 0.8rem;
    border-radius: 40px;
    cursor: pointer;
    font-size: 0.7rem;
}
.dashboard-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #2A2A30;
    padding-bottom: 0.5rem;
    flex-wrap: wrap;
}
.tab-dash {
    background: transparent;
    border: none;
    padding: 0.4rem 1rem;
    border-radius: 40px;
    color: #aaa;
    font-weight: bold;
    cursor: pointer;
    font-size: 0.8rem;
}
.tab-dash.active { background: var(--gold); color: #000; box-shadow: 0 0 12px rgba(212,175,55,0.5); }
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}
@media (min-width: 700px) { .dashboard-grid { grid-template-columns: 1fr 1fr; } }
.info-card {
    background: var(--card-dark);
    border-radius: 24px;
    padding: 1rem;
    border: 1px solid rgba(212,175,55,0.2);
}
.info-card h3 { font-size: 1rem; margin-bottom: 0.8rem; color: var(--gold); display: flex; align-items: center; gap: 0.5rem; }
.badge-descuento { background: var(--gold); color: #000; padding: 0.2rem 0.6rem; border-radius: 30px; font-size: 0.7rem; font-weight: bold; }
.pedidos-lista { display: flex; flex-direction: column; gap: 1rem; max-height: 400px; overflow-y: auto; padding-right: 0.5rem; }
.pedido-card {
    background: #141418;
    border-radius: 20px;
    padding: 0.8rem;
    border-left: 4px solid var(--gold);
}
.pedido-card:hover { background: #1E1E24; transform: translateX(4px); }
.badge-estado { display: inline-block; padding: 0.1rem 0.5rem; border-radius: 20px; font-size: 0.65rem; font-weight: bold; margin-top: 0.3rem; }
.estado-pendiente { background: #ff9800; color: #000; }
.estado-en-camino { background: #2196f3; color: #fff; }
.estado-entregado { background: #4caf50; color: #fff; }

/* ESTILO URBANO PARA COFFEECOINS */
.coffeecoins-badge {
    background: linear-gradient(135deg, #FFD966, #FFA500);
    color: #0A0A0C !important;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.25rem 0.8rem;
    border-radius: 40px;
    font-size: 0.75rem;
    font-weight: 800;
    margin-left: 0.5rem;
    box-shadow: 0 0 8px rgba(255, 200, 0, 0.6);
    text-shadow: 0 0 2px rgba(0,0,0,0.2);
    letter-spacing: 0.5px;
    border: 1px solid rgba(255,215,0,0.5);
    backdrop-filter: blur(2px);
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Permanent Marker', cursive;
}
.coffeecoins-badge:hover {
    transform: scale(1.05);
    box-shadow: 0 0 12px rgba(255, 200, 0, 0.9);
    background: linear-gradient(135deg, #FFE680, #FFB347);
}

/* MURAL */
.mural-wall {
    background: #2a2418;
    background-image: repeating-linear-gradient(45deg, rgba(0,0,0,0.1) 0px, rgba(0,0,0,0.1) 2px, transparent 2px, transparent 8px);
    border-radius: 28px;
    padding: 1rem;
    min-height: 40vh;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}
.postit {
    background: #FFE57F;
    width: 160px;
    padding: 0.6rem;
    box-shadow: 5px 5px 12px rgba(0,0,0,0.3);
    transform: rotate(var(--rot, 0deg));
    transition: transform 0.2s, box-shadow 0.2s;
    border-radius: 2px;
    font-family: 'Architects Daughter', cursive;
    color: #2c241a;
    position: relative;
    cursor: pointer;
}
.postit:hover { transform: rotate(0deg) scale(1.03); z-index: 10; }
.postit::before { content: "📌"; position: absolute; top: -12px; left: 50%; transform: translateX(-50%); font-size: 1.3rem; }
.postit .autor { font-weight: bold; font-size: 0.7rem; border-bottom: 1px dashed #b87c4f; display: inline-block; }
.postit .texto { font-size: 0.75rem; margin: 0.3rem 0; }
.postit .fecha { font-size: 0.55rem; text-align: right; margin-top: 0.3rem; color: #5a3a2a; }
.form-postit {
    background: rgba(0,0,0,0.7);
    border-radius: 20px;
    padding: 0.8rem;
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.form-postit input, .form-postit textarea {
    width: 100%;
    padding: 0.5rem;
    border-radius: 20px;
    border: 1px solid var(--gold);
    background: #1E1E24;
    color: white;
    font-family: 'Architects Daughter', cursive;
    font-size: 0.8rem;
}
.form-postit button {
    background: var(--gold);
    padding: 0.5rem;
    border-radius: 30px;
    font-weight: bold;
    width: 100%;
}
@media (min-width: 700px) {
    .postit { width: 200px; padding: 0.8rem; }
    .postit .autor { font-size: 0.8rem; }
    .postit .texto { font-size: 0.85rem; }
}

/* MODALES */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.95);
    z-index: 300;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.modal-content {
    background: #0A0A0C;
    border: 2px solid var(--gold);
    border-radius: 1.5rem;
    padding: 1rem;
    width: 100%;
    max-width: 400px;
    max-height: 85vh;
    overflow-y: auto;
}
.modal-content h3 { color: var(--gold); margin-bottom: 0.8rem; font-size: 1.2rem; font-family: 'Permanent Marker', cursive; text-align: center; }
.modal-content label { display: block; margin-top: 0.5rem; font-size: 0.7rem; color: var(--gold); }
.modal-content input, .modal-content select, .modal-content textarea {
    width: 100%;
    padding: 0.5rem;
    margin-top: 0.2rem;
    background: #1E1E24;
    border: 1px solid var(--gold);
    border-radius: 1rem;
    color: white;
    font-size: 0.8rem;
}
.modal-content button {
    background: var(--gold);
    color: #000;
    border: none;
    padding: 0.5rem;
    border-radius: 2rem;
    font-weight: bold;
    cursor: pointer;
    width: 100%;
    margin-top: 0.8rem;
}
.close-modal { float: right; font-size: 1.3rem; cursor: pointer; color: #aaa; }
.default-option { border: 2px solid var(--gold); background: rgba(212,175,55,0.1); border-radius: 0.8rem; margin-top: 0.5rem; position: relative; }
.default-badge { position: absolute; top: -10px; right: 10px; background: var(--gold); color: #0A0A0C; font-size: 0.6rem; padding: 0.2rem 0.5rem; border-radius: 20px; }
.precio-final { margin: 0.5rem 0; font-size: 1rem; font-weight: bold; color: #FFD966; text-align: center; }

/* SKATER */
.skater {
    position: fixed;
    bottom: 20px;
    left: 20px;
    width: 70px;
    height: 70px;
    z-index: 150;
    cursor: pointer;
    opacity: 0.95;
    transition: all 0.2s ease;
}
.skater:hover {
    transform: scale(1.05);
    opacity: 1;
}
@media (min-width: 700px) {
    .skater {
        width: 85px;
        height: 85px;
        bottom: 25px;
        left: 25px;
    }
}
.skater img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    animation: skateBounce 0.8s infinite ease;
    filter: drop-shadow(0 0 8px var(--gold));
}
@keyframes skateBounce {
    0%,100% { transform: translateY(0px); }
    50% { transform: translateY(-6px); }
}

/* BOTONES DE NAVEGACIÓN */
.nav-buttons {
    position: fixed;
    bottom: 15px;
    right: 70px;
    display: flex;
    gap: 0.5rem;
    z-index: 250;
}
@media (max-width: 700px) {
    .nav-buttons { right: 60px; bottom: 12px; }
}
.nav-btn {
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(8px);
    border: 1px solid var(--gold);
    color: var(--gold);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.nav-btn:hover { background: var(--gold); color: #000; }

.controls-hint {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: rgba(0,0,0,0.6);
    padding: 0.2rem 0.5rem;
    border-radius: 30px;
    font-size: 0.55rem;
    z-index: 200;
    pointer-events: none;
}

/* FRASES FLOTANTES Y TOAST */
.phrase-popup {
    position: fixed;
    background: rgba(245,240,230,0.95);
    border-radius: 60px;
    padding: 4px 12px;
    color: #4A2A1A;
    font-weight: 600;
    font-size: 11px;
    white-space: nowrap;
    z-index: 500;
    pointer-events: none;
    animation: fadeOut 4s ease forwards;
}
@keyframes fadeOut { 0%{opacity:1} 70%{opacity:1} 100%{opacity:0;display:none} }
.toast-notification {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: #1E1E24;
    border-left: 5px solid var(--gold);
    border-radius: 12px;
    padding: 6px 12px;
    color: #EAEAEA;
    font-size: 12px;
    z-index: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(8px);
    animation: slideUp 0.3s ease-out, fadeOutToast 3s ease forwards;
    pointer-events: none;
}
@keyframes slideUp { from { opacity:0; transform:translateX(-50%) translateY(20px); } to { opacity:1; transform:translateX(-50%) translateY(0); } }
@keyframes fadeOutToast { 0%{opacity:1} 70%{opacity:1} 100%{opacity:0;visibility:hidden} }
.review-form select, .review-form textarea { width: 100%; padding: 0.5rem; margin-bottom: 0.5rem; background: #2A2A30; border: 1px solid var(--gold); border-radius: 0.8rem; color: white; font-size: 0.8rem; }
.review-form button { width: 100%; background: var(--gold); color: #000; border: none; padding: 0.5rem; border-radius: 40px; font-weight: bold; margin-top: 0.5rem; }