:root {
    /* Sophisticated HSL Palette */
    --primary-h: 230;
    --primary-s: 85%;
    --primary-l: 60%;
    
    --primary: hsl(var(--primary-h), var(--primary-s), var(--primary-l));
    --primary-light: hsl(var(--primary-h), var(--primary-s), 70%);
    --primary-dark: hsl(var(--primary-h), var(--primary-s), 45%);
    --primary-glow: hsla(var(--primary-h), var(--primary-s), var(--primary-l), 0.35);
    
    --accent-h: 12;
    --accent-s: 90%;
    --accent-l: 58%;
    --accent: hsl(var(--accent-h), var(--accent-s), var(--accent-l)); /* Coral/Red accent */
    
    --bg-base: #0c0e14; /* Deep dark background */
    --surface: rgba(255, 255, 255, 0.05);
    --surface-solid: #1e293b;
    
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    
    --border-light: rgba(255, 255, 255, 0.08);
    --border-glass: rgba(255, 255, 255, 0.12);

    /* Layout & Styling */
    --radius-xl: 36px;
    --radius-lg: 28px;
    --radius-md: 18px;
    --radius-sm: 12px;
    
    --shadow-soft: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    --shadow-float: 0 20px 45px 0 rgba(0, 0, 0, 0.45);
    
    --glass-bg: rgba(15, 23, 42, 0.75);
    --glass-blur: blur(20px) saturate(180%);
    --glass-border: 1px solid rgba(255, 255, 255, 0.1);
    
    --noise: url("https://www.transparenttextures.com/patterns/carbon-fibre.png");
}

/* Glassmorphism Noise Overlay */
.glass-noise {
    position: relative;
}
.glass-noise::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--noise);
    opacity: 0.03;
    pointer-events: none;
    z-index: -1;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

/* Hide scrollbars but keep functionality */
::-webkit-scrollbar {
    display: none;
}
* {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

body {
    font-family: 'Outfit', sans-serif;
    color: var(--text-main);
    margin: 0;
    padding: 0;
    height: 100vh;
    height: 100dvh;
    width: 100vw;
    overflow: hidden;
    background: #000; /* Dark background for splash */
}

/* Splash Screen */
#splash-screen {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: #020617;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 1s cubic-bezier(0.87, 0, 0.13, 1);
}

#splash-screen.hidden {
    transform: translateY(-100%);
}

.splash-content {
    text-align: center;
    color: white;
}

.splash-logo {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto 32px;
}

.splash-logo .material-icons-round {
    font-size: 90px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    z-index: 2;
    filter: drop-shadow(0 0 20px var(--primary-glow));
}

.logo-pulse {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 140%; height: 140%;
    background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
    border-radius: 50%;
    animation: pulseLogo 3s infinite cubic-bezier(0.4, 0, 0.6, 1);
}

@keyframes pulseLogo {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.3; }
    50% { transform: translate(-50%, -50%) scale(1.3); opacity: 0.6; }
}

.splash-title {
    font-size: 36px;
    font-weight: 800;
    letter-spacing: -1.5px;
    margin-bottom: 8px;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.splash-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 40px;
    font-weight: 500;
}

.loading-bar {
    width: 200px;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 100px;
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.loading-progress {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: 100px;
    box-shadow: 0 0 15px var(--primary-glow);
    animation: progress 2.8s cubic-bezier(0.65, 0, 0.35, 1) forwards;
}

@keyframes progress {
    0% { width: 0%; }
    30% { width: 40%; }
    60% { width: 75%; }
    100% { width: 100%; }
}

#app-container {
    position: relative;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background-color: var(--bg-base);
    overflow: hidden;
    contain: paint;
}




/* Map Area */
.map-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background-color: #E2E8F0;
    overflow: hidden;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
}

#map {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

/* Minimize Google Maps branding (still visible for ToS compliance) */
.gm-style .gmnoprint,
.gm-style .gm-style-cc {
    display: none !important;
}

.gm-style a[href^="https://maps.google.com"] {
    opacity: 0.3 !important;
    transform: scale(0.7);
    transform-origin: bottom left;
}

.gm-style img[alt="Google"] {
    opacity: 0.3 !important;
    transform: scale(0.7);
    transform-origin: bottom left;
}


/* Google Maps Marker Labels */
.marker-label {
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 11px !important;
    font-weight: 700 !important;
    color: #FFFFFF !important;
    margin-bottom: 40px; /* Position above the pin */
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    white-space: nowrap;
    pointer-events: none;
    transform: translateY(-5px);
    transition: all 0.3s ease;
}

@keyframes floatMarker {
    0%, 100% { transform: translateY(-5px); }
    50% { transform: translateY(-10px); }
}

/* Instruction Card at the Top */
.instruction-card {
    position: absolute;
    top: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(-150%);
    width: auto;
    min-width: 280px;
    max-width: 90%;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 100px; /* Capsule shape */
    padding: 8px 24px 8px 8px;
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 1100;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

.instruction-card.visible {
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.instruction-icon {
    width: 44px;
    height: 44px;
    background: var(--primary);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.instruction-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    overflow: hidden;
}

#navInstruction {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

#navMeta {
    font-size: 12px;
    color: var(--text-muted);
}

/* Weather Widget */
.weather-widget {
    position: absolute;
    top: 24px;
    left: 24px;
    z-index: 1010;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    padding: 12px 18px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: var(--shadow-soft);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: default;
}

.weather-widget:hover {
    transform: scale(1.04) translateY(-2px);
    background: rgba(30, 41, 59, 0.85);
    box-shadow: var(--shadow-float);
}

.weather-icon {
    font-size: 32px;
    background: linear-gradient(135deg, #FFD93D, #FF8400);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 8px rgba(255, 217, 61, 0.4));
}

.weather-info {
    display: flex;
    flex-direction: column;
}

.weather-info .temp {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.2;
}

.weather-info .city {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
}

/* Category Quick Filters */
.category-filters {
    position: absolute;
    top: 96px;
    left: 24px;
    z-index: 1010;
    display: flex;
    gap: 10px;
    padding: 4px 0 12px;
    max-width: calc(100% - 48px);
    overflow-x: auto;
    scrollbar-width: none;
}

.filter-chip {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    padding: 10px 20px;
    border-radius: 100px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-main);
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: var(--shadow-soft);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.filter-chip.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    border-color: transparent;
    box-shadow: 0 8px 20px var(--primary-glow);
    transform: scale(1.05);
}

.filter-chip:hover:not(.active) {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.2);
}

.search-bar {
    display: flex;
    align-items: center;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: var(--radius-xl);
    padding: 14px 22px;
    box-shadow: var(--shadow-float);
    gap: 14px;
    transition: all 0.3s ease;
}

.search-bar:focus-within {
    transform: scale(1.02);
    background: rgba(15, 23, 42, 0.85);
    border-color: var(--primary-light);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.search-icon {
    color: var(--primary);
    font-size: 24px;
}

.search-bar input {
    flex: 1;
    border: none;
    outline: none;
    background: transparent;
    font-family: inherit;
    font-size: 16px;
    color: var(--text-main);
    font-weight: 500;
}

.search-bar input::placeholder {
    color: var(--text-muted);
    font-weight: 400;
}

.icon-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: color 0.2s;
}

.icon-btn:active {
    color: var(--primary);
}

/* Quick Categories Removed */


/* Satellite / Map Toggle Button */
.map-toggle-btn {
    position: absolute;
    bottom: calc(160px + env(safe-area-inset-bottom));
    right: 24px;
    width: 44px;
    height: 44px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    color: var(--text-main);
    cursor: pointer;
    z-index: 1010;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.map-toggle-btn::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 30%;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    pointer-events: none;
}

.map-toggle-btn .material-icons-round {
    font-size: 20px;
}

.map-toggle-btn.active {
    background: #3B82F6;
    color: white;
    border-color: #3B82F6;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.5);
}

.map-toggle-btn:active {
    transform: scale(0.9);
}

/* GPS / My Location Button */
.gps-btn {
    position: absolute;
    bottom: calc(100px + env(safe-area-inset-bottom));
    right: 24px;
    width: 50px;
    height: 50px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    color: var(--text-main);
    cursor: pointer;
    z-index: 1010;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.gps-btn::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 30%;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    pointer-events: none;
}

.gps-btn.tracking {
    background: #3B82F6;
    color: white;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.6);
    border-color: #3B82F6;
}

.gps-btn:active {
    transform: scale(0.9);
}

/* Floating Action Button */
.fab {
    position: absolute;
    bottom: calc(32px + env(safe-area-inset-bottom));
    left: 50%;
    transform: translateX(-50%);
    width: 68px;
    height: 68px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 12px 30px var(--primary-glow);
    cursor: pointer;
    z-index: 1015;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.fab .material-icons-round {
    font-size: 32px;
}

.fab:hover {
    transform: translateX(-50%) translateY(-5px) scale(1.1);
    box-shadow: 0 15px 35px var(--primary-glow);
}

.fab:active {
    transform: translateX(-50%) scale(0.95);
}

.fab.hidden {
    transform: translateX(-50%) scale(0) rotate(90deg);
    opacity: 0;
    pointer-events: none;
}

/* Bottom Sheet */
.bottom-sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(24px) saturate(190%);
    -webkit-backdrop-filter: blur(24px) saturate(190%);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 32px 32px 0 0;
    padding: 24px 24px calc(24px + env(safe-area-inset-bottom));
    z-index: 2000;
    box-shadow: 0 -15px 50px rgba(0, 0, 0, 0.4);
    transform: translate3d(0, 100%, 0);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-height: 85vh;
}

.bottom-sheet.expanded {
    transform: translate3d(0, 0, 0);
}

.bottom-sheet::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 120px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.05), transparent);
    pointer-events: none;
    border-radius: 32px 32px 0 0;
}

.drag-handle {
    width: 40px;
    height: 5px;
    background: #CBD5E1;
    border-radius: 10px;
    margin: 0 auto;
    margin-bottom: 8px;
}

.sheet-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sheet-header h3 {
    font-size: 20px;
    font-weight: 600;
}

.sheet-header .close-btn {
    opacity: 0;
    /* hidden when collapsed */
    pointer-events: none;
    transition: opacity 0.2s;
    background: #F1F5F9;
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

.bottom-sheet.expanded .close-btn {
    opacity: 1;
    pointer-events: auto;
}

/* Routing Inputs */
.routing-inputs {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
    background: rgba(255, 255, 255, 0.04);
    padding: 20px;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.2);
}

.timeline-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    height: 70px;
    margin-top: 5px;
}

.timeline-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.timeline-dot.start {
    background: #3B82F6;
    /* Blue */
}

.timeline-dot.end {
    background: #EF4444;
    /* Red */
}

.timeline-line {
    width: 2px;
    flex: 1;
    background: repeating-linear-gradient(to bottom, #CBD5E1 0, #CBD5E1 4px, transparent 4px, transparent 8px);
}

.input-fields {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.input-wrapper {
    width: 100%;
}

.input-wrapper input {
    width: 100%;
    padding: 10px 0;
    border: none;
    border-bottom: 1px solid #E2E8F0;
    font-family: inherit;
    font-size: 15px;
    color: var(--text-main);
    background: transparent;
    outline: none;
}

.input-wrapper:last-child input {
    border-bottom: none;
}

.source-input {
    color: var(--primary) !important;
    font-weight: 500;
}

.swap-btn {
    background: #F8FAFC;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: var(--text-muted);
}

/* Suggested Section */
.suggested-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
    flex: 1;
    overflow-y: auto;
    min-height: 150px; /* Ensure it doesn't collapse too much */
    margin-bottom: 80px; /* Leave space for the Start Navigation button */
}

.bottom-sheet.expanded .suggested-section {
    opacity: 1;
    pointer-events: auto;
}

.suggested-section h4 {
    font-size: 14px;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.location-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Location Item Styling */
.location-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.location-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(8px);
    border-color: rgba(255, 255, 255, 0.15);
}

.location-item:active {
    transform: scale(0.98) translateX(4px);
}

.icon-box {
    width: 48px;
    height: 48px;
    background: rgba(99, 102, 241, 0.15);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-light);
}

.location-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.loc-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-main);
}

.loc-desc {
    font-size: 13px;
    color: var(--text-muted);
}

/* Primary Button */
.primary-btn {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    box-shadow: 0 10px 25px var(--primary-glow);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: auto;
}

.primary-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px var(--primary-glow);
    filter: brightness(1.1);
}

.primary-btn:active {
    background: var(--primary-light);
}

.bottom-sheet:not(.expanded) .primary-btn {
    display: none;
}

/* Ensure FAB is above Leaflet interactive layers */
.leaflet-interactive {
    cursor: pointer;
    z-index: 100;
}

/* Photo Overlay Modal */
.photo-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    z-index: 3000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.photo-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.photo-container {
    position: relative;
    width: 90%;
    max-width: 500px;
    background: var(--surface-solid);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transform: scale(0.9) translateY(20px);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.photo-overlay.active .photo-container {
    transform: scale(1) translateY(0);
}

.close-photo {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s;
}

.close-photo:hover {
    background: var(--accent);
    transform: rotate(90deg);
}

.photo-container img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
}

.photo-caption {
    padding: 24px;
    background: linear-gradient(to bottom, rgba(30, 41, 59, 0), rgba(30, 41, 59, 1));
}

.photo-caption h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    color: white;
}

.photo-caption p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.6;
}

/* Campus Timings Button */
.timings-btn {
    position: absolute;
    bottom: calc(220px + env(safe-area-inset-bottom));
    right: 24px;
    width: 44px;
    height: 44px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    color: var(--text-main);
    cursor: pointer;
    z-index: 1010;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
}

.timings-btn::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 30%;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    pointer-events: none;
}

.timings-btn:active {
    transform: scale(0.9);
}

/* Campus Timings Panel */
.timings-panel {
    position: absolute;
    top: 100px;
    right: -320px; /* Hidden by default */
    width: 280px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: 24px 0 0 24px;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    z-index: 1200;
    transition: right 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 20px;
}

.timings-panel.active {
    right: 0;
}

.timings-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 10px;
}

.timings-header h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
}

.close-timings {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
}

.timings-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.timings-item .material-icons-round {
    color: var(--primary);
    background: rgba(59, 130, 246, 0.1);
    padding: 8px;
    border-radius: 12px;
}

.timings-info {
    display: flex;
    flex-direction: column;
}

.timings-info .name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
}

.timings-info .time {
    font-size: 12px;
    color: var(--text-muted);
}

/* High-End Mini Compass */
.compass-container {
    position: absolute;
    top: calc(100px + env(safe-area-inset-top));
    left: 24px;
    width: 60px;
    height: 60px;
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-float);
    z-index: 1010;
    transition: transform 0.3s ease;
    overflow: visible; /* Changed from hidden to show labels */
}

.cardinal {
    position: absolute;
    font-size: 10px;
    font-weight: 800;
    color: var(--text-muted);
    transition: color 0.3s;
}

.cardinal.n { top: -14px; left: 50%; transform: translateX(-50%); color: #EF4444; }
.cardinal.e { right: -14px; top: 50%; transform: translateY(-50%); }
.cardinal.s { bottom: -14px; left: 50%; transform: translateX(-50%); }
.cardinal.w { left: -14px; top: 50%; transform: translateY(-50%); }


.pl {
  display: block;
  width: 45px;
  height: 45px;
}

.pl__arrows,
.pl__ring-rotate,
.pl__ring-stroke,
.pl__tick {
  animation-duration: 2s;
  animation-timing-function: linear;
  animation-iteration-count: infinite;
}

.pl__arrows {
  /* We will override transform via JS to point North */
  /* animation-name: arrows42; */ 
  transform-origin: 16px 52px;
}

.pl__ring-rotate,
.pl__ring-stroke {
  transform-origin: 80px 80px;
}

.pl__ring-rotate {
  animation-name: ringRotate42;
}

.pl__ring-stroke {
  animation-name: ringStroke42;
  transform: rotate(-45deg);
}

.pl__tick {
  animation-name: tick42;
}

.pl__tick:nth-child(2) { animation-delay: -1.75s; }
.pl__tick:nth-child(3) { animation-delay: -1.5s; }
.pl__tick:nth-child(4) { animation-delay: -1.25s; }
.pl__tick:nth-child(5) { animation-delay: -1s; }
.pl__tick:nth-child(6) { animation-delay: -0.75s; }
.pl__tick:nth-child(7) { animation-delay: -0.5s; }
.pl__tick:nth-child(8) { animation-delay: -0.25s; }

/* Animations */
@keyframes ringRotate42 {
  from { transform: rotate(0); }
  to { transform: rotate(720deg); }
}

@keyframes ringStroke42 {
  from, to {
    stroke-dashoffset: 452;
    transform: rotate(-45deg);
  }
  50% {
    stroke-dashoffset: 169.5;
    transform: rotate(-180deg);
  }
}

@keyframes tick42 {
  from, 3%, 47%, to { stroke-dashoffset: -12; }
  14%, 36% { stroke-dashoffset: 0; }
}





