/* ProMakers Club - Modern, Clean & Professional Stylesheet */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --border-color: #e2e8f0;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --primary: #4f46e5;
    --primary-hover: #4338ca;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    letter-spacing: -0.01em;
}

/* Tarjetas y Contenedores Modernos */
.sketchy-border {
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background-color: #ffffff;
    box-shadow: 0 1px 3px 0 rgba(15, 23, 42, 0.05), 0 1px 2px -1px rgba(15, 23, 42, 0.05);
}

.sketchy-border-alt {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background-color: #ffffff;
}

.sketchy-shadow {
    box-shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.05), 0 2px 4px -2px rgba(15, 23, 42, 0.05);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.sketchy-shadow:hover {
    box-shadow: 0 10px 15px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.05);
    transform: translateY(-2px);
}

.sketchy-shadow-sm {
    box-shadow: 0 1px 2px 0 rgba(15, 23, 42, 0.05);
}

/* Inputs Modernos y Pulidos */
.sketchy-input {
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    background-color: #f8fafc;
    color: #0f172a;
    transition: all 0.2s ease;
}

.sketchy-input:focus {
    outline: none;
    background-color: #ffffff;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

/* Custom Scrollbar Discreto */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { 
    background: #cbd5e1; 
    border-radius: 8px; 
}
::-webkit-scrollbar-thumb:hover { 
    background: #94a3b8; 
}

/* Lógica de Vistas */
.view-section { 
    display: none !important; 
}
.view-section.active { 
    display: block !important; 
    width: 100%;
    animation: fadeIn 0.2s ease-in-out; 
}
#view-map.view-section.active {
    display: flex !important;
    width: 100%;
}

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

/* Ajustes Leaflet Moderno */
.leaflet-container {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    background: #f1f5f9 !important; 
    border: 1px solid #cbd5e1;
    border-radius: 16px;
}

.leaflet-control-layers {
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 6px -1px rgba(15, 23, 42, 0.08) !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    padding: 8px 12px !important;
}

.leaflet-control-layers-expanded {
    background-color: #ffffff !important;
    color: #0f172a !important;
}

.leaflet-control-layers-base label {
    margin-bottom: 4px !important;
    cursor: pointer !important;
}

.marker-pin {
    background-color: #4f46e5;
    border: 3px solid #ffffff;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.4);
    transition: transform 0.2s ease;
}

.marker-pin:hover {
    transform: scale(1.15);
}

.marker-pin span {
    font-weight: 700;
    font-size: 0.95rem;
    color: #ffffff;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

/* Elemento Activo en Navegación */
.nav-active {
    background-color: #eef2ff !important;
    color: #4f46e5 !important;
    font-weight: 600;
    border-radius: 12px !important;
}

/* Botón Google Moderno */
.btn-google-sketchy {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    background-color: #ffffff;
    color: #0f172a;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
    padding: 10px 18px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.btn-google-sketchy:hover {
    background-color: #f8fafc;
    border-color: #94a3b8;
    box-shadow: 0 2px 4px rgba(15, 23, 42, 0.08);
}

/* Modal Backdrop */
.sketchy-modal-backdrop {
    background-color: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
}

/* ==========================================================================
   MODO OSCURO - PROMAKERS CLUB (Ultra-modern, Clean & High-Contrast)
   ========================================================================== */

html.dark {
    color-scheme: dark;
    --bg-main: #0b0f19;
    --bg-card: #111827;
    --border-color: #1f2c42;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --primary: #6366f1;
    --primary-hover: #4f46e5;
}

html.dark body {
    background-color: #0b0f19 !important;
    color: #f1f5f9 !important;
}

html.dark #app-shell {
    background-color: #0b0f19 !important;
}

/* Fondos de contenedores y tarjetas */
html.dark .bg-white {
    background-color: #111827 !important;
}

html.dark .bg-slate-50,
html.dark .bg-slate-50\/70,
html.dark .bg-slate-50\/90 {
    background-color: #151e2e !important;
}

html.dark .bg-slate-100,
html.dark .bg-slate-100\/80 {
    background-color: #1a2538 !important;
}

/* Efectos Hover */
html.dark .hover\:bg-slate-50:hover {
    background-color: #151e2e !important;
}

html.dark .hover\:bg-slate-100:hover,
html.dark .hover\:bg-slate-100\/80:hover {
    background-color: #1e2c44 !important;
}

html.dark .hover\:bg-slate-200:hover {
    background-color: #253654 !important;
}

/* Bordes y Separadores */
html.dark .border-slate-200,
html.dark .border-slate-200\/90,
html.dark .border-slate-200\/80,
html.dark .border-slate-200\/70,
html.dark .border-slate-200\/60,
html.dark .border-slate-200\/50,
html.dark .border-slate-100,
html.dark .border-b.border-slate-200,
html.dark .border-t.border-slate-200,
html.dark .border-r.border-slate-200 {
    border-color: #1f2c42 !important;
}

html.dark .divide-slate-100 > :not([hidden]) ~ :not([hidden]),
html.dark .divide-slate-200 > :not([hidden]) ~ :not([hidden]) {
    border-color: #1f2c42 !important;
}

/* Tipografía en modo oscuro */
html.dark .text-slate-900 {
    color: #f8fafc !important;
}

html.dark .text-slate-800 {
    color: #f1f5f9 !important;
}

html.dark .text-slate-700 {
    color: #cbd5e1 !important;
}

html.dark .text-slate-600 {
    color: #94a3b8 !important;
}

html.dark .text-slate-500 {
    color: #94a3b8 !important;
}

html.dark .text-slate-400 {
    color: #64748b !important;
}

/* Inputs, Textareas y Selects */
html.dark .sketchy-input {
    background-color: #151e2e !important;
    color: #f8fafc !important;
    border-color: #27364e !important;
}

html.dark .sketchy-input:focus {
    background-color: #111827 !important;
    border-color: #6366f1 !important;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25) !important;
}

html.dark select.sketchy-input option {
    background-color: #111827 !important;
    color: #f8fafc !important;
}

html.dark textarea.sketchy-input::placeholder,
html.dark input.sketchy-input::placeholder {
    color: #4b5d78 !important;
}

/* Tarjetas y sombras */
html.dark .sketchy-border {
    background-color: #111827 !important;
    border-color: #1f2c42 !important;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.4);
}

html.dark .sketchy-border-alt {
    background-color: #111827 !important;
    border-color: #1f2c42 !important;
}

html.dark .sketchy-shadow {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
}

html.dark .sketchy-shadow:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.6);
}

/* Navegación y Cabeceras */
html.dark nav.md\:flex {
    background-color: #111827 !important;
    border-color: #1f2c42 !important;
}

html.dark #mobile-header {
    background-color: rgba(17, 24, 39, 0.95) !important;
    border-color: #1f2c42 !important;
}

html.dark #mobile-nav {
    background-color: rgba(17, 24, 39, 0.95) !important;
    border-color: #1f2c42 !important;
}

html.dark .nav-active {
    background-color: #1e1b4b !important;
    color: #818cf8 !important;
}

/* Badges y Etiquetas de Color */
html.dark .bg-indigo-50 {
    background-color: rgba(79, 70, 229, 0.18) !important;
}
html.dark .text-indigo-700,
html.dark .text-indigo-600 {
    color: #a5b4fc !important;
}
html.dark .border-indigo-100,
html.dark .border-indigo-200,
html.dark .border-indigo-200\/80,
html.dark .border-indigo-200\/60 {
    border-color: rgba(99, 102, 241, 0.35) !important;
}
html.dark .border-indigo-600 {
    border-color: #818cf8 !important;
}

html.dark .bg-emerald-50 {
    background-color: rgba(16, 185, 129, 0.18) !important;
}
html.dark .text-emerald-700,
html.dark .text-emerald-600 {
    color: #6ee7b7 !important;
}
html.dark .border-emerald-200 {
    border-color: rgba(16, 185, 129, 0.35) !important;
}

html.dark .bg-amber-50 {
    background-color: rgba(245, 158, 11, 0.18) !important;
}
html.dark .text-amber-700 {
    color: #fcd34d !important;
}
html.dark .border-amber-200,
html.dark .border-amber-200\/80 {
    border-color: rgba(245, 158, 11, 0.35) !important;
}

html.dark .bg-rose-50 {
    background-color: rgba(244, 63, 94, 0.18) !important;
}
html.dark .text-rose-700,
html.dark .text-rose-800 {
    color: #fda4af !important;
}
html.dark .border-rose-200 {
    border-color: rgba(244, 63, 94, 0.35) !important;
}

/* Modales */
html.dark .sketchy-modal-backdrop {
    background-color: rgba(0, 0, 0, 0.75) !important;
}

/* Mapa Leaflet en modo oscuro */
html.dark .leaflet-container {
    background: #0f172a !important;
    border-color: #1f2c42 !important;
}

html.dark .leaflet-popup-content-wrapper,
html.dark .leaflet-popup-tip {
    background-color: #111827 !important;
    color: #f8fafc !important;
    border: 1px solid #1f2c42;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6) !important;
}

html.dark .leaflet-control-layers {
    background-color: #111827 !important;
    color: #f8fafc !important;
    border-color: #1f2c42 !important;
}

html.dark .leaflet-control-layers-expanded {
    background-color: #111827 !important;
    color: #f8fafc !important;
}

html.dark .leaflet-bar a {
    background-color: #111827 !important;
    color: #f8fafc !important;
    border-color: #1f2c42 !important;
}

html.dark .leaflet-bar a:hover {
    background-color: #1a2538 !important;
}

html.dark .marker-pin {
    border-color: #111827;
}

/* Inversión sutil y elegante de las baldosas de mapa en modo oscuro */
html.dark .leaflet-tile-pane {
    filter: brightness(0.68) invert(1) contrast(3) hue-rotate(200deg) saturate(0.35);
}

/* Botón Google en login */
html.dark .btn-google-sketchy {
    background-color: #151e2e;
    color: #f8fafc;
    border-color: #27364e;
}
html.dark .btn-google-sketchy:hover {
    background-color: #1a2538;
    border-color: #334460;
}

/* Scrollbars */
html.dark ::-webkit-scrollbar-thumb {
    background: #2b3952;
}
html.dark ::-webkit-scrollbar-thumb:hover {
    background: #3b4d6e;
}

/* Utilidades de truncado multi-línea */
.line-clamp-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Tarjetas de enlaces en modo oscuro */
html.dark .bg-slate-50\/80 {
    background-color: rgba(26, 37, 56, 0.8) !important;
}
html.dark .bg-slate-50\/70 {
    background-color: rgba(26, 37, 56, 0.7) !important;
}
