/* ==================================================
   Sofia Isochrone Pulse Finder - Stylesheet
   Sofia 2027 - Premium Dark Theme with Dark Map Layer
   ================================================== */

:root {
    --font-header: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    /* Theme Colors */
    --bg-main: #050b16;
    --bg-card: rgba(13, 22, 40, 0.55);
    --border-card: rgba(255, 255, 255, 0.08);
    --border-focus: rgba(0, 242, 254, 0.4);
    
    /* Neon Accent Colors */
    --color-primary: #00f2fe;    /* Cyan */
    --color-secondary: #8b5cf6;  /* Purple */
    --color-accent: #10b981;     /* Green */
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    
    /* Zone Colors */
    --zone-ultra: #00f2fe;       /* Cyan */
    --zone-high: #8b5cf6;        /* Purple */
    --zone-outer: #64748b;       /* Slate */
    
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-main);
    color: var(--text-main);
    font-family: var(--font-body);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 2rem 1rem;
    overflow-x: hidden;
    position: relative;
}

/* Ambient glow blobs */
.glow-bg {
    position: fixed;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    z-index: -1;
    background: 
        radial-gradient(circle at 10% 25%, rgba(0, 242, 254, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 80% 20%, rgba(139, 92, 246, 0.1) 0%, transparent 45%),
        radial-gradient(circle at 50% 80%, rgba(16, 185, 129, 0.06) 0%, transparent 50%);
    filter: blur(80px);
    pointer-events: none;
}

/* Container */
.app-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Header */
.app-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: 1px solid var(--border-card);
    padding-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.badge {
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: #050b16;
    font-family: var(--font-header);
    font-weight: 700;
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    letter-spacing: 0.05em;
    display: inline-block;
    margin-bottom: 0.5rem;
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.35);
}

h1 {
    font-family: var(--font-header);
    font-size: 2.25rem;
    font-weight: 800;
    background: linear-gradient(to right, #ffffff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

.subtitle {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* Language selector */
.lang-selector {
    display: flex;
    background: rgba(10, 15, 30, 0.6);
    border: 1px solid var(--border-card);
    border-radius: 8px;
    padding: 0.2rem;
}

.lang-btn {
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.35rem 0.75rem;
    cursor: pointer;
    border-radius: 5px;
    transition: var(--transition-smooth);
}

.lang-btn.active {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

/* Layout Split */
.main-grid {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 2rem;
    align-items: stretch;
}

@media (max-width: 900px) {
    .main-grid {
        grid-template-columns: 1fr;
    }
}

/* Sidebar panel */
.sidebar-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Glassmorphism Cards */
.card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-card);
    border-radius: 16px;
    padding: 1.5rem;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    transition: var(--transition-smooth);
}

.card:hover {
    border-color: rgba(0, 242, 254, 0.12);
}

.glass {
    position: relative;
    overflow: hidden;
}

.glass::before {
    content: '';
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.01) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(25deg);
    pointer-events: none;
}

.card-title {
    font-family: var(--font-header);
    font-size: 1.15rem;
    font-weight: 600;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.icon {
    font-size: 1.25rem;
}

/* Tabs for active venue selection */
.venue-tabs {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.venue-tab {
    background: rgba(10, 15, 30, 0.6);
    border: 1px solid var(--border-card);
    border-radius: 10px;
    padding: 0.75rem 1rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    transition: var(--transition-smooth);
    outline: none;
    text-align: left;
}

.venue-tab:hover {
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.15);
}

.venue-tab.active {
    background: rgba(0, 242, 254, 0.06);
    border-color: var(--color-primary);
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.15);
}

.tab-title {
    font-family: var(--font-header);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-main);
}

.venue-tab.active .tab-title {
    color: var(--color-primary);
}

.tab-subtitle {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Search input elements */
.search-box {
    display: flex;
    gap: 0.5rem;
}

.search-input {
    flex: 1;
    background: rgba(10, 15, 30, 0.8);
    border: 1px solid var(--border-card);
    border-radius: 8px;
    padding: 0.65rem 0.85rem;
    color: #ffffff;
    font-family: var(--font-body);
    font-size: 0.85rem;
    outline: none;
    transition: var(--transition-smooth);
}

.search-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 8px rgba(0, 242, 254, 0.15);
}

.search-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Button systems */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: var(--font-header);
    font-weight: 700;
    font-size: 0.85rem;
    border: none;
    outline: none;
    padding: 0.65rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), #00b8fe);
    color: #050b16;
    box-shadow: 0 4px 15px rgba(0, 242, 254, 0.3);
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 242, 254, 0.45);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-card);
    color: var(--text-main);
    width: 100%;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

/* Pulse Zone Badge Indicator */
.pulse-badge-container {
    display: flex;
    justify-content: center;
    margin: 0.5rem 0;
}

.pulse-badge {
    padding: 0.6rem 2rem;
    border-radius: 9999px;
    font-family: var(--font-header);
    font-weight: 800;
    font-size: 0.95rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    transition: var(--transition-smooth);
}

/* Badge variants */
.pulse-badge.ultra {
    background: linear-gradient(135deg, #00f2fe, #00b8fe);
    color: #050b16;
    box-shadow: 0 0 25px rgba(0, 242, 254, 0.45);
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

.pulse-badge.high {
    background: linear-gradient(135deg, #a78bfa, #8b5cf6);
    color: #ffffff;
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.45);
}

.pulse-badge.outer {
    background: linear-gradient(135deg, #475569, #334155);
    color: #cbd5e1;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: none;
}

/* Metrics Table */
.analytics-metrics {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.metric-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
}

.metric-label {
    color: var(--text-muted);
}

.metric-value {
    color: #ffffff;
    font-weight: 600;
    font-family: var(--font-header);
}

.highlight-row {
    background: rgba(255, 255, 255, 0.02);
    border-left: 3px solid var(--color-primary);
    padding: 0.5rem;
    border-radius: 4px;
}

.highlight-row.ultra-highlight {
    border-left-color: var(--zone-ultra);
    background: rgba(0, 242, 254, 0.03);
}
.highlight-row.high-highlight {
    border-left-color: var(--zone-high);
    background: rgba(139, 92, 246, 0.03);
}

.highlight-row .metric-label {
    color: #ffffff;
    font-weight: 600;
}

.highlight-row .metric-value {
    font-size: 1rem;
    font-weight: 700;
}

.divider {
    border: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
}

/* Recommendation card styling */
.recommendation-box {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.recommendation-header {
    font-family: var(--font-header);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--color-accent);
    letter-spacing: 0.03em;
}

.recommendation-content {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.5;
}

/* Map panel canvas container */
.map-panel {
    border: 1px solid var(--border-card);
    border-radius: 16px;
    padding: 0.25rem;
    min-height: 500px;
    height: 100%;
}

.map-container {
    width: 100%;
    height: 100%;
    min-height: 492px;
    border-radius: 12px;
    background-color: #0b111e;
}

/* Leaflet dark styles overrides */
.leaflet-container {
    font-family: var(--font-body);
}

.leaflet-bar {
    border: 1px solid var(--border-card) !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4) !important;
    border-radius: 8px !important;
    overflow: hidden;
}

.leaflet-bar a {
    background-color: #0d1628 !important;
    color: #ffffff !important;
    border-bottom: 1px solid var(--border-card) !important;
    transition: var(--transition-smooth);
}

.leaflet-bar a:hover {
    background-color: #1a263c !important;
    color: var(--color-primary) !important;
}

.leaflet-bar a.leaflet-disabled {
    background-color: #090e18 !important;
    color: #475569 !important;
}

/* Tooltip & Popups overrides styling */
.leaflet-popup-content-wrapper {
    background: rgba(13, 22, 40, 0.9) !important;
    border: 1px solid var(--border-card) !important;
    backdrop-filter: blur(12px);
    color: #ffffff !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4) !important;
}

.leaflet-popup-tip {
    background: rgba(13, 22, 40, 0.9) !important;
    border: 1px solid var(--border-card) !important;
}

.leaflet-popup-content {
    font-size: 0.8rem !important;
    line-height: 1.4 !important;
    margin: 0.75rem 1rem !important;
}

.leaflet-popup-content strong {
    color: var(--color-primary);
}

/* Footer & Disclaimers */
.app-footer {
    border-top: 1px solid var(--border-card);
    padding-top: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    background: transparent;
    box-shadow: none;
}

.disclaimer-content {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.5;
    text-align: center;
    max-width: 800px;
}

.copyright {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.15);
    text-align: center;
    margin-top: 0.5rem;
}

/* Mobile and Tablet Responsiveness Updates */
@media (max-width: 600px) {
    body {
        padding: 1rem 0.75rem;
    }
    
    h1 {
        font-size: 1.75rem;
    }
    
    .badge {
        font-size: 0.7rem;
    }
    
    .app-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .card {
        padding: 1.25rem;
    }
    
    .venue-tabs {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .search-box {
        flex-direction: column;
        gap: 0.75rem;
        width: 100%;
    }
    
    .search-input {
        width: 100%;
    }
    
    .btn {
        width: 100%;
    }
    
    .map-panel {
        min-height: 350px;
        height: 350px;
    }
    
    .map-container {
        min-height: 342px;
    }
}

/* Suite Navigation Bar */
.suite-nav {
    display: flex;
    gap: 1.25rem;
    margin-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-card);
    padding-bottom: 0.75rem;
}

.suite-nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-family: var(--font-header);
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.suite-nav-link:hover {
    color: #ffffff;
}

.suite-nav-link.active {
    color: var(--color-primary);
}


