/* ==========================================================================
   TALLER LOS AMIGOS - MÓDULO DE GESTIÓN Y SEGUIMIENTO DE TRABAJOS
   Estilos Responsive Mobile-First
   ========================================================================== */

:root {
    --job-bg-dark: #12141C;
    --job-card-bg: #1A1D28;
    --job-border: #2A2E3D;
    --job-primary-red: #E62626;
    --job-primary-glow: rgba(230, 38, 38, 0.25);
    --job-green-success: #10B981;
    --job-green-glow: rgba(16, 185, 129, 0.2);
    --job-yellow-active: #F59E0B;
    --job-text-main: #FFFFFF;
    --job-text-muted: #A0A5B5;
    --job-radius: 14px;
}

/* --------------------------------------------------------------------------
   SECCIÓN PÚBLICA DE SEGUIMIENTO (index.html)
   -------------------------------------------------------------------------- */
.job-tracking-section {
    padding: 70px 0;
    background: linear-gradient(180deg, #0A0B0E 0%, #13151F 100%);
    position: relative;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.job-search-box {
    max-width: 580px;
    margin: 0 auto 35px auto;
    background: var(--job-card-bg);
    padding: 24px;
    border-radius: var(--job-radius);
    border: 1px solid var(--job-border);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

.job-search-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.15rem;
    color: var(--job-text-main);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.job-search-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

@media (min-width: 540px) {
    .job-search-form {
        flex-direction: row;
    }
}

.job-input-wrapper {
    position: relative;
    flex: 1;
}

.job-input-wrapper i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--job-primary-red);
    font-size: 1.1rem;
}

.job-search-input {
    width: 100%;
    padding: 14px 16px 14px 44px;
    background: #0D0E14;
    border: 1.5px solid var(--job-border);
    border-radius: 10px;
    color: #FFF;
    font-size: 1.1rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.job-search-input:focus {
    outline: none;
    border-color: var(--job-primary-red);
    box-shadow: 0 0 12px var(--job-primary-glow);
}

.job-search-btn {
    padding: 14px 24px;
    background: linear-gradient(135deg, #E62626 0%, #B91C1C 100%);
    color: #FFF;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    touch-action: manipulation;
}

.job-search-btn:hover, .job-search-btn:active {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px var(--job-primary-glow);
}

/* --------------------------------------------------------------------------
   TARJETA DE RESULTADO DE TRABAJO
   -------------------------------------------------------------------------- */
.job-result-container {
    max-width: 720px;
    margin: 0 auto;
}

.job-status-card {
    background: var(--job-card-bg);
    border-radius: var(--job-radius);
    border: 1px solid var(--job-border);
    overflow: hidden;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

.job-card-header {
    background: linear-gradient(135deg, #222636 0%, #171924 100%);
    padding: 20px 24px;
    border-bottom: 1px solid var(--job-border);
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.job-car-info {
    display: flex;
    align-items: center;
    gap: 14px;
}

.job-car-icon {
    width: 48px;
    height: 48px;
    background: rgba(230, 38, 38, 0.15);
    border: 1px solid rgba(230, 38, 38, 0.4);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--job-primary-red);
    font-size: 1.4rem;
}

.job-plate-badge {
    display: inline-block;
    background: #000;
    color: #FFF;
    border: 2px solid #FFF;
    border-radius: 6px;
    padding: 2px 10px;
    font-family: 'Orbitron', sans-serif;
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 2px;
}

.job-car-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #FFF;
    margin: 4px 0 0 0;
}

.job-order-id {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    color: var(--job-text-muted);
}

/* Timeline Responsiva */
.job-timeline-wrapper {
    padding: 28px 24px;
}

.job-timeline-title {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--job-text-muted);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.job-timeline {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 24px;
}

@media (min-width: 640px) {
    .job-timeline {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        gap: 0;
    }

    .job-timeline::before {
        content: '';
        position: absolute;
        top: 20px;
        left: 30px;
        right: 30px;
        height: 3px;
        background: var(--job-border);
        z-index: 1;
    }
}

.job-step {
    display: flex;
    align-items: center;
    gap: 16px;
    position: relative;
    z-index: 2;
}

@media (min-width: 640px) {
    .job-step {
        flex-direction: column;
        align-items: center;
        text-align: center;
        flex: 1;
        gap: 10px;
    }
}

.job-step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #0D0E14;
    border: 2px solid var(--job-border);
    color: var(--job-text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.job-step.completed .job-step-number {
    background: var(--job-green-success);
    border-color: var(--job-green-success);
    color: #FFF;
    box-shadow: 0 0 12px var(--job-green-glow);
}

.job-step.active .job-step-number {
    background: var(--job-primary-red);
    border-color: #FF5555;
    color: #FFF;
    box-shadow: 0 0 16px var(--job-primary-glow);
    animation: pulseStep 1.8s infinite;
}

@keyframes pulseStep {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.job-step-label {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--job-text-muted);
}

.job-step.completed .job-step-label,
.job-step.active .job-step-label {
    color: #FFF;
    font-weight: 700;
}

/* Barra de Avance */
.job-progress-bar-bg {
    width: 100%;
    height: 10px;
    background: #0D0E14;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--job-border);
    margin-bottom: 24px;
}

.job-progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #E62626 0%, #10B981 100%);
    border-radius: 20px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Detalles del Trabajo */
.job-card-details {
    padding: 20px 24px;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--job-border);
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 580px) {
    .job-card-details {
        grid-template-columns: 1fr 1fr;
    }
}

.job-detail-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.job-detail-icon {
    color: var(--job-primary-red);
    font-size: 1.1rem;
    margin-top: 3px;
}

.job-detail-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--job-text-muted);
    letter-spacing: 0.5px;

}

.job-detail-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: #FFF;
    margin-top: 2px;
}

.job-card-footer {
    padding: 18px 24px;
    background: #141620;
    border-top: 1px solid var(--job-border);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.job-wa-consult-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #25D366;
    color: #FFF;
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    transition: background 0.3s;
}

.job-wa-consult-btn:hover {
    background: #1EBE5A;
}

/* Estado Vacío / No Encontrado */
.job-not-found {
    text-align: center;
    padding: 30px 20px;
    background: var(--job-card-bg);
    border-radius: var(--job-radius);
    border: 1px dashed var(--job-border);
}

.job-not-found i {
    font-size: 2.5rem;
    color: var(--job-primary-red);
    margin-bottom: 12px;
}

.job-not-found h4 {
    font-size: 1.2rem;
    color: #FFF;
    margin-bottom: 6px;
}

.job-not-found p {
    color: var(--job-text-muted);
    font-size: 0.95rem;
    margin-bottom: 16px;
}

/* Badge de Acceso Admin sutil en el footer del buscador */
.job-admin-access {
    margin-top: 16px;
    text-align: center;
}

.job-admin-link {
    color: var(--job-text-muted);
    font-size: 0.82rem;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    opacity: 0.75;
    transition: opacity 0.2s, color 0.2s;
}

.job-admin-link:hover {
    opacity: 1;
    color: var(--job-primary-red);
}
