/* ==============================================================================
 * MinarOS Mosque Display - Pre-Iqamah Countdown & Prohibited Salah Overlay CSS
 * High-End Glassmorphism & Mosque Ambient Design System
 * ============================================================================== */

#prayer-mode-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 999999;
    background: radial-gradient(circle at 50% 30%, rgba(38, 24, 18, 0.94), rgba(15, 10, 8, 0.98)),
                url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" viewBox="0 0 100 100"><path d="M50 0 L100 50 L50 100 L0 50 Z" fill="none" stroke="rgba(217,119,6,0.03)" stroke-width="1"/></svg>');
    background-size: cover, 80px 80px;
    color: #f8fafc;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    display: none;
    flex-direction: column;
    justify-content: space-between;
    padding: 32px 48px;
    box-sizing: border-box;
    opacity: 0;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
    user-select: none;
}

#prayer-mode-overlay.pm-visible {
    display: flex;
    opacity: 1;
    pointer-events: auto;
}

/* --- Top Header Bar --- */
.pm-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.pm-header-time-group {
    display: flex;
    align-items: baseline;
    gap: 16px;
}

.pm-header-clock {
    font-size: 3.2rem;
    font-weight: 800;
    letter-spacing: -1px;
    color: #ffffff;
    line-height: 1;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.pm-header-clock .pm-ampm {
    font-size: 1.4rem;
    font-weight: 700;
    margin-left: 4px;
    color: #fbbf24;
}

.pm-header-date {
    font-size: 1.25rem;
    font-weight: 500;
    color: rgba(241, 245, 249, 0.75);
    letter-spacing: 0.2px;
}

.pm-mosque-logo {
    max-height: 64px;
    max-width: 160px;
    object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
}

.pm-mosque-logo-icon {
    font-size: 2.8rem;
    color: #d97706;
}

/* --- Center Content Canvas --- */
.pm-center-canvas {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    gap: 24px;
    margin: auto 0;
}

/* --- Prohibited Salah Alert Banner --- */
.pm-prohibited-card {
    background: linear-gradient(135deg, rgba(185, 28, 28, 0.85), rgba(153, 27, 27, 0.95));
    border: 1px solid rgba(248, 113, 113, 0.35);
    border-radius: 20px;
    padding: 16px 36px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    box-shadow: 0 12px 32px rgba(153, 27, 27, 0.4), 0 0 20px rgba(239, 68, 68, 0.2);
    backdrop-filter: blur(12px);
    animation: pm-pulse 3s infinite ease-in-out;
}

@keyframes pm-pulse {
    0%, 100% { box-shadow: 0 12px 32px rgba(153, 27, 27, 0.4), 0 0 20px rgba(239, 68, 68, 0.2); }
    50% { box-shadow: 0 16px 40px rgba(185, 28, 28, 0.6), 0 0 30px rgba(248, 113, 113, 0.4); }
}

.pm-prohibited-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: 2px;
    color: #ffffff;
    text-transform: uppercase;
}

.pm-prohibited-icon {
    background: #ffffff;
    color: #991b1b;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    font-weight: 900;
}

.pm-prohibited-subtitle {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: #fecaca;
    text-transform: uppercase;
}

.pm-prohibited-times-capsule {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    padding: 6px 20px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #ffffff;
    display: flex;
    gap: 16px;
    margin-top: 4px;
}

/* --- Pre-Iqamah Countdown Box --- */
.pm-countdown-card {
    background: rgba(45, 30, 22, 0.75);
    border: 1px solid rgba(217, 119, 6, 0.3);
    border-radius: 28px;
    padding: 32px 56px;
    min-width: 580px;
    max-width: 720px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.1);
    backdrop-filter: blur(16px);
}

.pm-countdown-title {
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: #fbbf24;
    text-transform: uppercase;
}

.pm-countdown-body {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 24px;
}

.pm-countdown-digits {
    font-size: 5.5rem;
    font-weight: 900;
    font-family: "Courier New", Courier, monospace, sans-serif;
    color: #ffffff;
    letter-spacing: -2px;
    line-height: 1;
    text-shadow: 0 4px 24px rgba(0,0,0,0.7);
}

.pm-silent-icon-wrapper {
    background: rgba(239, 68, 68, 0.15);
    border: 2px solid rgba(239, 68, 68, 0.5);
    border-radius: 50%;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ef4444;
    font-size: 2.2rem;
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.25);
}

/* --- Progress Bar --- */
.pm-progress-container {
    width: 100%;
    height: 14px;
    background: rgba(15, 23, 42, 0.6);
    border-radius: 999px;
    overflow: hidden;
    padding: 3px;
    box-sizing: border-box;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.pm-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #d97706, #f59e0b, #fbbf24);
    border-radius: 999px;
    transition: width 1s linear;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.6);
}

/* --- Bottom Bar --- */
.pm-bottom-bar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    width: 100%;
}

.pm-upcoming-card {
    background: rgba(30, 20, 15, 0.8);
    border: 1px solid rgba(217, 119, 6, 0.25);
    border-radius: 16px;
    padding: 16px 28px;
    display: flex;
    align-items: center;
    gap: 28px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
    backdrop-filter: blur(12px);
}

.pm-upcoming-prayer-identity {
    display: flex;
    align-items: center;
    gap: 12px;
}

.pm-upcoming-icon {
    font-size: 1.8rem;
    color: #f59e0b;
}

.pm-upcoming-name {
    font-size: 1.3rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.pm-upcoming-times-divider {
    width: 1px;
    height: 36px;
    background: rgba(255, 255, 255, 0.15);
}

.pm-upcoming-time-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.pm-upcoming-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pm-upcoming-value {
    font-size: 1.15rem;
    font-weight: 700;
    color: #f1f5f9;
}
