/* RSUD Tugu Koja - Custom Styling & Mobile First Enhancements */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #0f766e;
    --primary-dark: #115e59;
    --primary-light: #ccfbf1;
    --secondary: #0284c7;
    --accent: #0ea5e9;
    --emergency: #e11d48;
    --surface: #ffffff;
    --bg-main: #f8fafc;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-main);
    color: #1e293b;
    -webkit-tap-highlight-color: transparent;
    padding-bottom: 70px; /* Space for mobile sticky bottom nav */
}

@media (min-width: 1024px) {
    body {
        padding-bottom: 0px;
    }
}

/* Glassmorphism Navigation */
.nav-glass {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px -2px rgba(15, 118, 110, 0.08);
}

/* Bottom Navigation Bar for Mobile */
.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid #e2e8f0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.06);
}

.mobile-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 4px 6px;
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    transition: all 0.2s ease;
    text-decoration: none;
}

.mobile-nav-item.active {
    color: var(--primary);
}

.mobile-nav-item.active svg {
    color: var(--primary);
    transform: translateY(-2px);
}

/* Emergency Center Button in Mobile Nav */
.mobile-nav-emergency {
    position: relative;
    top: -16px;
    background: linear-gradient(135deg, #e11d48, #be123c);
    color: #ffffff !important;
    border-radius: 9999px;
    padding: 10px;
    box-shadow: 0 6px 18px rgba(225, 29, 72, 0.4);
    border: 3px solid #ffffff;
    transition: transform 0.2s ease;
}

.mobile-nav-emergency:active {
    transform: scale(0.94);
}

/* Running Text Ticker */
.running-text-container {
    overflow: hidden;
    white-space: nowrap;
}

.running-text {
    display: inline-block;
    padding-left: 100%;
    animation: marquee 28s linear infinite;
}

.running-text:hover {
    animation-play-state: paused;
}

@keyframes marquee {
    0% { transform: translate(0, 0); }
    100% { transform: translate(-100%, 0); }
}

/* Card Hover & Touch Optimization */
.card-hover {
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-hover:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px -4px rgba(15, 118, 110, 0.12);
}

/* Pulse Badge Animation */
.badge-pulse {
    position: relative;
}

.badge-pulse::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 8px;
    height: 8px;
    background-color: #10b981;
    border-radius: 50%;
    animation: pulse 1.8s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
    70% { transform: scale(1.1); box-shadow: 0 0 0 7px rgba(16, 185, 129, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Quick Floating Action Button for WhatsApp */
.floating-whatsapp {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 45;
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: white;
    padding: 10px 18px;
    border-radius: 9999px;
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.35);
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.floating-whatsapp:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(37, 211, 102, 0.45);
}

/* Tablet & Mobile: Berikan ruang di atas sticky bottom navigation bar */
@media (max-width: 1023px) {
    .floating-whatsapp {
        bottom: 80px;
        right: 18px;
    }
}

@media (max-width: 640px) {
    .floating-whatsapp span {
        display: none;
    }
    .floating-whatsapp {
        padding: 12px;
        bottom: 78px;
        right: 16px;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Bed availability progress bars */
.progress-bar-fill {
    transition: width 1s ease-in-out;
}
