/* ===================================
   CaronaBTZ Check-in — Mobile PWA CSS
   =================================== */

:root {
    --checkin-primary: #0d6efd;
    --checkin-success: #198754;
    --checkin-danger: #dc3545;
    --checkin-warning: #ffc107;
    --checkin-bg: #f8f9fa;
}

/* Body */
.checkin-body {
    background-color: var(--checkin-bg);
    min-height: 100vh;
    padding-bottom: 2rem;
    -webkit-tap-highlight-color: transparent;
}

/* Header */
.checkin-header {
    background: var(--checkin-primary);
    color: #fff;
    padding: 0.75rem 1rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

/* Sync Banner */
.sync-banner {
    background: var(--checkin-warning);
    color: #000;
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

/* Content */
.checkin-content {
    padding: 1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Code Input */
.code-input {
    font-size: 2rem;
    text-align: center;
    letter-spacing: 0.5rem;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    text-transform: uppercase;
    padding: 0.75rem;
    border: 3px solid var(--checkin-primary);
    border-radius: 12px;
}
.code-input:focus {
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}
.code-input::placeholder {
    letter-spacing: 0.2rem;
    font-size: 1.2rem;
    color: #adb5bd;
}

/* Cards */
.checkin-card {
    border-radius: 12px;
    border: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    margin-bottom: 1rem;
}
.checkin-card .card-header {
    border-radius: 12px 12px 0 0;
    font-weight: 600;
}

/* Info Row */
.info-row {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid #e9ecef;
}
.info-row:last-child {
    border-bottom: none;
}
.info-label {
    color: #6c757d;
    font-size: 0.85rem;
}
.info-value {
    font-weight: 600;
    text-align: right;
}

/* Checklist Toggles */
.checklist-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: #fff;
    border-radius: 10px;
    border: 2px solid #dee2e6;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
    -webkit-user-select: none;
}
.checklist-item.checked {
    border-color: var(--checkin-success);
    background: #d1e7dd;
}
.checklist-item.problem {
    border-color: var(--checkin-danger);
    background: #f8d7da;
}
.checklist-item .checklist-icon {
    font-size: 1.5rem;
    width: 40px;
    text-align: center;
}
.checklist-item .checklist-label {
    flex: 1;
    font-weight: 500;
    padding-left: 0.5rem;
}
.checklist-item .checklist-status {
    font-size: 1.5rem;
    width: 40px;
    text-align: center;
}

/* Passenger List */
.passenger-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: #fff;
    border-radius: 10px;
    border: 2px solid #dee2e6;
    transition: all 0.2s ease;
}
.passenger-item.present {
    border-color: var(--checkin-success);
    background: #d1e7dd;
}
.passenger-item.absent {
    border-color: var(--checkin-danger);
    background: #f8d7da;
}
.passenger-name {
    font-weight: 500;
    flex: 1;
}
.passenger-badge {
    font-size: 0.7rem;
    margin-left: 0.5rem;
}

/* Big Action Button */
.btn-checkin {
    width: 100%;
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    margin-bottom: 0.75rem;
}

/* Status Badge */
.status-large {
    font-size: 1rem;
    padding: 0.5rem 1rem;
    border-radius: 20px;
}

/* KM Input */
.km-input {
    font-size: 1.5rem;
    text-align: center;
    font-weight: bold;
    padding: 0.75rem;
    border-radius: 10px;
}

/* Observation Textarea */
.obs-textarea {
    border-radius: 10px;
    resize: vertical;
    min-height: 80px;
}

/* Geo Status */
.geo-status {
    font-size: 0.85rem;
    padding: 0.5rem;
    border-radius: 8px;
    background: #fff;
    border: 1px solid #dee2e6;
    text-align: center;
}

/* Loading spinner */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Placa display */
.placa-display {
    font-family: 'Courier New', monospace;
    font-size: 1.5rem;
    font-weight: bold;
    background: #fff;
    border: 3px solid #333;
    border-radius: 8px;
    padding: 0.25rem 0.75rem;
    display: inline-block;
    letter-spacing: 2px;
}

/* Success checkmark */
.success-icon {
    font-size: 4rem;
    color: var(--checkin-success);
}

/* Responsive adjustments */
@media (max-width: 380px) {
    .code-input {
        font-size: 1.5rem;
        letter-spacing: 0.3rem;
    }
    .checkin-content {
        padding: 0.75rem;
    }
}
