/* css/components.css - Blockout Hybrid UI/UX Components */

/* Modals */
.modal-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(4px);
    z-index: 2000;
    display: none;
    align-items: center; justify-content: center;
    padding: 16px;
}
.modal-content {
    background: var(--bg-surface);
    border-radius: var(--radius-xl);
    width: 100%; max-width: 500px;
    box-shadow: var(--shadow-lg);
    animation: modalSlideUp 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
}
@keyframes modalSlideUp { from { transform: translateY(30px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* Cards */
.card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
    transition: var(--transition-normal);
}
.card:hover {
    box-shadow: var(--shadow-md);
}
.card-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 12px;
}
.card-title {
    font-size: 18px; font-weight: 800; color: var(--text-primary); margin: 0;
}

/* Timeline */
.timeline {
    position: relative;
    padding-right: 20px;
    margin-top: 16px;
}
.timeline::before {
    content: ''; position: absolute; top: 0; bottom: 0; right: 6px;
    width: 2px; background: var(--border-color);
}
.timeline-item {
    position: relative; padding-bottom: 24px;
}
.timeline-dot {
    position: absolute; right: -20px; top: 4px;
    width: 14px; height: 14px; border-radius: 50%;
    background: var(--primary); border: 3px solid var(--bg-surface);
    z-index: 2;
}
.timeline-date {
    font-size: 12px; font-weight: 700; color: var(--primary); margin-bottom: 4px;
}
.timeline-content {
    background: var(--bg-surface-hover);
    padding: 12px 16px; border-radius: var(--radius-md);
    font-size: 14px; color: var(--text-secondary);
}

/* Badges */
.badge {
    padding: 6px 12px; border-radius: var(--radius-full);
    font-size: 11px; font-weight: 700; display: inline-block;
}
.badge-danger { background: var(--primary); color: white; }
.badge-success { background: var(--success); color: white; }
.badge-info { background: var(--info, #007AFF); color: white; }
.badge-warning { background: var(--warning); color: #111827; }
.badge-orange { background: #f97316; color: white; }
.badge-secondary { background: #6b7280; color: white; }
.badge-outline { background: transparent; border: 1px solid var(--border-color); color: var(--text-secondary); }

/* Buttons */
.btn {
    padding: 12px 24px; border-radius: var(--radius-md);
    font-family: var(--font-ar); font-size: 15px; font-weight: 700;
    cursor: pointer; border: none; transition: var(--transition-fast);
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-hover); }
.btn-outline { background: transparent; border: 1px solid var(--border-color); color: var(--text-primary); }
.btn-outline:hover { background: var(--bg-surface-hover); }
.btn-success { background: var(--success); color: white; }

/* Skeletons */
.skeleton {
    background: linear-gradient(90deg, var(--bg-surface-hover) 25%, var(--border-color) 50%, var(--bg-surface-hover) 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    border-radius: var(--radius-sm);
}
@keyframes loading { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* Map Container */
.gis-map-container {
    height: 400px; width: 100%; border-radius: var(--radius-lg); overflow: hidden;
    border: 1px solid var(--border-color);
}

/* iOS Safari Zoom Fix for Inputs */
@media screen and (max-width: 768px) {
    input, select, textarea {
        font-size: 16px !important;
    }
}
