/* Emergency Service Directory - Custom Styles */

/* Global layout improvements */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Navbar improvements */
.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
}

.navbar-start, .navbar-end {
    display: flex;
    align-items: center;
}

/* Container improvements */
.container {
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

/* Card hover effects */
.emergency-card {
    transition: all 0.3s ease;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Clean button styles */

/* Ensure proper grid layout */
.lg\\:col-span-9 {
    width: 100%;
}

.lg\\:col-span-3 {
    width: 100%;
}

.emergency-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
}

/* Heart icon animation */
.heart-icon {
    transition: all 0.2s ease;
}

.heart-icon:hover {
    transform: scale(1.1);
}

.heart-icon.filled {
    color: #ef4444 !important;
}

/* Button hover effects */
.copy-btn, .call-btn {
    transition: all 0.2s ease;
}

.copy-btn:hover {
    transform: translateY(-1px);
}

.call-btn:hover {
    transform: translateY(-1px);
}

/* Badge styles */
.category-badge {
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.375rem 0.75rem;
    border-radius: 9999px;
}

/* Responsive design */
@media (max-width: 768px) {
    /* Mobile navbar - Stack vertically */
    .navbar {
        flex-direction: column !important;
        align-items: center !important;
        padding: 16px !important;
        height: auto !important;
        gap: 16px;
    }
    
    .navbar-start {
        order: 1;
    }
    
    .navbar-end {
        order: 2;
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
    }
    
    .navbar-end > div {
        width: auto !important;
        min-width: 100px !important;
    }
    
    /* Main content mobile spacing */
    main.container {
        padding: 16px 12px !important;
    }
    
    /* Emergency cards mobile layout */
    .emergency-card {
        height: auto !important;
        min-height: 320px !important;
        padding: 24px !important;
    }
    
    /* Main content mobile layout */
    .lg\\:col-span-9, .lg\\:col-span-3 {
        grid-column: span 1 !important;
    }
    
    /* Call history mobile improvements */
    .lg\\:col-span-3 .bg-white {
        margin-top: 24px !important;
        position: static !important;
    }
    
    /* Call history mobile */
    .history-scroll {
        max-height: 300px !important;
    }
    
    /* Hero section mobile */
    .hero-section .container {
        padding: 24px 16px !important;
        min-height: 200px !important;
    }
    
    /* Hero title mobile */
    .hero-section h1 {
        font-size: 28px !important;
        line-height: 1.3 !important;
    }
    
    /* Hero subtitle mobile */
    .hero-section p {
        font-size: 16px !important;
        line-height: 1.4 !important;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    /* Hero adjustments for tablet */
    .hero-section .container {
        padding: 28px 32px !important;
        min-height: 220px !important;
    }
    
    .hero-section h1 {
        font-size: 36px !important;
    }
    
    .hero-section p {
        font-size: 18px !important;
    }
}

@media (min-width: 1024px) {
    /* Desktop layout */
    .emergency-card {
        height: 360px !important;
    }
}

/* History section scrollbar */
.history-scroll {
    max-height: 600px;
    overflow-y: auto;
}

.history-scroll::-webkit-scrollbar {
    width: 6px;
}

.history-scroll::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

.history-scroll::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

.history-scroll::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* History item animation */
.history-item {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Loading states */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Success feedback */
.success-flash {
    animation: flash 0.6s ease-out;
}

@keyframes flash {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; background-color: #dcfce7; }
}

/* Error states */
.error-shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

