/* Frontend Bed Availability Display */

.bed-availability-container {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 15px;
    padding: 40px;
    margin: 30px 0;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    text-align: center;
    border-left: 6px solid #32006A;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.bed-availability-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #32006A, #DAA627, #32006A);
    border-radius: 15px 15px 0 0;
}

.bed-availability-container:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 50px rgba(0,0,0,0.15);
}

/* Status-based styling */
.bed-availability-container.no-beds {
    border-left-color: #ef4444;
    background: linear-gradient(135deg, #fef2f2 0%, #ffffff 100%);
}

.bed-availability-container.no-beds::before {
    background: linear-gradient(90deg, #ef4444, #dc2626, #b91c1c);
}

.bed-availability-container.low-beds {
    border-left-color: #DAA627;
    background: linear-gradient(135deg, #fffbeb 0%, #ffffff 100%);
}

.bed-availability-container.low-beds::before {
    background: linear-gradient(90deg, #DAA627, #b8941e, #9a7a18);
}

.bed-availability-container.beds-available {
    border-left-color: #32006A;
    background: linear-gradient(135deg, #f5f3ff 0%, #ffffff 100%);
}

/* Main bed count display */
.bed-count {
    margin-bottom: 25px;
    position: relative;
}

.bed-count h3 {
    font-size: 3.5em;
    margin: 0 0 15px 0;
    color: #1f2937;
    font-weight: 800;
    line-height: 1;
    position: relative;
    display: inline-block;
}

.bed-count h3::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
   background: linear-gradient(90deg, #32006A, #DAA627, #32006A);
    border-radius: 2px;
    opacity: 0.3;
}

.status-text {
    font-size: 1.3em;
    margin: 0;
    color: #6b7280;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

/* Status-specific colors */
.no-beds .bed-count h3 { 
    color: #ef4444;
    animation: pulse-red 2s infinite;
}

.low-beds .bed-count h3 { 
    color: #DAA627;
    animation: pulse-yellow 2s infinite;
}

.beds-available .bed-count h3 { 
    color: #32006A;
}

/* Pulse animations for urgent states */
@keyframes pulse-red {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

@keyframes pulse-yellow {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

/* Information section */
.bed-info {
    background-color: transparent;
    background-image: linear-gradient(90deg, var( --e-global-color-f53d9f0 ) 0%, var( --e-global-color-efa1fc9 ) 100%);
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    margin-top: 25px;
    backdrop-filter: blur(10px);
}

.bed-info p {
    margin: 8px 0;
    font-size: 1em;
    color: white !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 500;
}

.bed-info p:first-child {
    margin-top: 0;
}

.bed-info p:last-child {
    margin-bottom: 0;
}

.last-updated {
    font-weight: 600;
}

/*.updated-by {*/
/*    opacity: 1;*/
/*}*/

/* Error state */
.bed-availability-error {
    background: #fef2f2;
    color: #b91c1c;
    padding: 20px;
    border-radius: 10px;
    border: 2px solid #fecaca;
    text-align: center;
    font-weight: 600;
}

/* Emergency contact info */
.emergency-info {
    background: linear-gradient(135deg, #f5f3ff 0%, #e0e7ff 100%);
    border: 2px solid #32006A;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
    text-align: center;
}

.emergency-info h4 {
    margin: 0 0 10px 0;
    color: #32006A;
    font-size: 1.1em;
}

.emergency-info p {
    margin: 0;
    color: #32006A;
    font-weight: 500;
}

.emergency-phone {
    font-size: 1.3em;
    font-weight: 700;
    color: #32006A;
}

/* Responsive design */
@media (max-width: 768px) {
    .bed-availability-container {
        padding: 25px 20px;
        margin: 20px 0;
    }
    
    .bed-count h3 {
        font-size: 2.8em;
    }
    
    .status-text {
        font-size: 1.1em;
    }
    
    .bed-info {
        padding: 15px;
    }
    
    .bed-info p {
        font-size: 0.95em;
        flex-direction: column;
        gap: 5px;
    }
}

@media (max-width: 480px) {
    .bed-availability-container {
        padding: 20px 15px;
        margin: 15px 0;
    }
    
    .bed-count h3 {
        font-size: 2.5em;
    }
    
    .status-text {
        font-size: 1em;
        letter-spacing: 0.5px;
    }
    
    .bed-info {
        padding: 12px;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .bed-availability-container {
        background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
        color: #f9fafb;
        border-left-color: #32006A;
    }
    
    .bed-count h3 {
        color: #f9fafb;
    }
    
    .status-text {
        color: #d1d5db;
    }
    
    .bed-info {
                background-color: transparent;
    background-image: linear-gradient(90deg, var( --e-global-color-f53d9f0 ) 0%, var( --e-global-color-efa1fc9 ) 100%);
    }
    
    .bed-info p {
        color: #ffff;
    }
    
    .no-beds .bed-count h3 { color: #f87171; }
    .low-beds .bed-count h3 { color: #DAA627; }
    .beds-available .bed-count h3 { color: #9f7aea; }
}

/* Print styles */
@media print {
    .bed-availability-container {
        box-shadow: none;
        border: 2px solid #000;
        background: white !important;
    }
    
    .bed-count h3 {
        color: #000 !important;
    }
    
    .status-text,
    .bed-info p {
        color: #000 !important;
    }
}