/**
 * Hasiči - CSS styly pro komponenty
 * Styly přesunuté z Template.php a dalších PHP souborů
 */

/* ==========================================================================
   ONLINE USERS SECTION
   ========================================================================== */

.online-section {
    background: linear-gradient(135deg, #ecfdf5 0%, #eff6ff 100%);
    border-top: 3px solid #10b981;
    padding: 1rem 0;
}

.online-section-inner {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
}

.online-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.online-pulse {
    width: 10px;
    height: 10px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse 2s infinite;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.1); }
}

.online-title {
    font-weight: 600;
    color: #047857;
    font-size: 0.9rem;
}

.online-count {
    background: #10b981;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.125rem 0.5rem;
    border-radius: 10px;
}

.online-users-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
}

.online-user-card {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #fff;
    padding: 0.375rem 0.75rem;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.2s;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.online-user-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.15);
    border-color: #10b981;
}

.online-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #10b981;
}

.online-user-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.online-user-name {
    color: #1f2937;
    font-weight: 500;
    font-size: 0.8125rem;
    line-height: 1.2;
}

.online-user-time {
    color: #6b7280;
    font-size: 0.6875rem;
}

/* ==========================================================================
   SITE FOOTER
   ========================================================================== */

.site-footer {
    background: #1f2937;
    color: #9ca3af;
    padding: 1rem;
    text-align: center;
    font-size: 0.8125rem;
    margin-top: auto;
}

.site-footer strong {
    color: #f3f4f6;
}

.site-footer a {
    color: #f3f4f6;
    text-decoration: none;
}

.site-footer a:hover {
    color: #10b981;
}

/* ==========================================================================
   PWA QR MODAL
   ========================================================================== */

.pwa-qr-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    color: #fff !important;
    border-radius: 6px;
    margin: 0 0.5rem;
    transition: all 0.2s;
}

.pwa-qr-link:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(220, 38, 38, 0.4);
}

.pwa-qr-link svg {
    width: 16px;
    height: 16px;
}

.pwa-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.pwa-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.pwa-modal {
    background: #fff;
    border-radius: 16px;
    padding: 2rem;
    max-width: 360px;
    width: 90%;
    text-align: center;
    transform: scale(0.9);
    transition: transform 0.3s;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.pwa-modal-overlay.active .pwa-modal {
    transform: scale(1);
}

.pwa-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #6b7280;
}

.pwa-modal-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.pwa-modal-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.pwa-modal-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.pwa-qr-container {
    background: #fff;
    padding: 1rem;
    border-radius: 12px;
    display: inline-block;
    margin-bottom: 1rem;
    border: 2px solid #e5e7eb;
}

.pwa-qr-container img {
    display: block;
}

.pwa-instructions {
    background: #fef3c7;
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
    text-align: left;
    font-size: 0.8125rem;
    color: #92400e;
}

.pwa-instructions-title {
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.pwa-instructions ol {
    margin: 0;
    padding-left: 1.25rem;
}

.pwa-instructions li {
    margin-bottom: 0.25rem;
}

/* ==========================================================================
   THEME TOGGLE
   ========================================================================== */

.theme-toggle-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #fff !important;
    border-radius: 6px;
    margin: 0 0.25rem;
    transition: all 0.2s;
}

.theme-toggle-link:hover {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.4);
}

.theme-toggle-link svg {
    width: 16px;
    height: 16px;
}

body.dark-mode .theme-icon-light {
    display: none !important;
}

body.dark-mode .theme-icon-dark {
    display: block !important;
}

/* ==========================================================================
   QR LOGIN (login page)
   ========================================================================== */

.qr-login-section {
    margin-top: 1.5rem;
}

.qr-login-divider {
    display: flex;
    align-items: center;
    margin: 1rem 0;
    color: #6b7280;
    font-size: 0.875rem;
}

.qr-login-divider::before,
.qr-login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

.qr-login-divider span {
    padding: 0 1rem;
}

.qr-login-box {
    background: #f9fafb;
    border-radius: 12px;
    padding: 1.25rem;
    text-align: center;
    border: 1px solid #e5e7eb;
}

.qr-login-title {
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.25rem;
}

.qr-icon {
    margin-right: 0.5rem;
}

.qr-login-description {
    font-size: 0.8rem;
    color: #6b7280;
    margin-bottom: 1rem;
}

.qr-code-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 180px;
    background: white;
    border-radius: 8px;
    margin-bottom: 0.75rem;
}

.qr-code-container canvas,
.qr-code-container img {
    max-width: 160px !important;
    height: auto !important;
}

.qr-loading {
    color: #6b7280;
    font-size: 0.875rem;
}

.qr-status {
    font-size: 0.8rem;
    min-height: 1.25rem;
}

.qr-status.success {
    color: #059669;
}

.qr-status.error {
    color: #dc2626;
}

.qr-status.waiting {
    color: #f59e0b;
}

.qr-timer {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 0.25rem;
}

/* ==========================================================================
   DARK MODE PRELOAD
   ========================================================================== */

.dark-mode-preload {
    background: #0f172a !important;
}
