/* =========================
   TRACK HERO
========================= */

.track-hero {
    background-image: var(--gradient-navy);

    padding: 70px 6% 100px;

    text-align: center;

    color: white;
}

.track-hero h1 {
    font-size: 2.6rem;
    font-weight: 800;
    margin-bottom: 12px;
}

.track-hero > p {
    max-width: 600px;
    margin: 0 auto 35px;

    font-size: 1rem;
    color: rgba(255,255,255,.85);
}

.track-card {

    max-width: 650px;

    margin: auto;

    background: #fff;

    border-radius: var(--radius-lg);

    padding: 20px;

    box-shadow:
        0 15px 40px
        rgba(0,0,0,.12);

    text-align: left;

}

.track-card label {

    display: block;

    margin-bottom: 10px;

    font-size: .95rem;

    font-weight: 600;

    color: var(--color-text-dark);

}

.track-input {

    display: flex;

    gap: 12px;

}

.track-input input {
    flex: 1;
    min-height: 52px;      /* better than relying on padding */
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-sm);
    padding: 0 18px;
    font-size: .95rem;
    font-family: 'Poppins', sans-serif;
    outline: none;
    transition: border-color var(--transition-base);
}

.track-input input:focus {

    border-color: var(--color-cyan);

}

.track-input button {

    border: none;

    background: var(--color-navy-deep);

    color: white;

    padding: 0 28px;

    border-radius: var(--radius-md);

    font-size: .95rem;

    font-weight: 600;

    cursor: pointer;

    transition: background var(--transition-base);
}

/* Was lightening to #0b2b7a on hover — every other primary button
   on the site darkens on hover, this brings it back in line. */
.track-input button:hover {

    background: var(--color-navy-hover);

}

/* =========================
   TABLET
========================= */

@media (max-width: 768px) {

    .track-hero {
        padding: 60px 5% 80px;
    }

    .track-hero h1 {
        font-size: 2.1rem;
    }

    .track-card {
        padding: 22px;
    }

    .track-input {
        flex-direction: column;
        gap: 15px;
    }

    .track-input input {
        width: 100%;
        height: 56px;           /* add this */
        font-size: 1rem;
        padding: 0 18px;
    }

    .track-input button {
        width: 100%;
        height: 56px;
        font-size: 1rem;
    }

}

/* =========================
   MOBILE
========================= */

@media (max-width: 480px) {

    .track-hero h1 {
        font-size: 1.8rem;
    }

    .track-card {
        padding: 18px;
        border-radius: var(--radius-md);
    }

    .track-card label {
        font-size: .9rem;
        margin-bottom: 8px;
    }

    .track-input input {
        height: 54px;          /* add this */
        padding: 0 16px;
        border-radius: var(--radius-sm);
    }

    .track-input button {
        height: 54px;
        border-radius: var(--radius-sm);
    }

}
/* =========================
   TRACKING RESULT
========================= */

.tracking-result {
    display: none;
    padding: 0 6% 80px;
}

.tracking-card {
    max-width: 900px;
    margin: auto;

    background: white;
    border-radius: var(--radius-xl);
    padding: 34px;

    border: 1px solid var(--color-border-light);
    box-shadow: 0 10px 30px rgba(0,0,0,.06);
}

/* =========================
   NOT FOUND STATE
========================= */

.tracking-not-found {
    text-align: center;
    padding: 60px 34px;
}

.not-found-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;

    border-radius: 50%;
    background: var(--color-chip-bg);
    color: var(--color-text-muted);

    display: flex;
    align-items: center;
    justify-content: center;
}

.tracking-not-found h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--color-text-dark);
    margin-bottom: 10px;
}

.tracking-not-found p {
    color: var(--color-text-muted);
    font-size: .95rem;
    max-width: 420px;
    margin: 0 auto;
    line-height: 1.7;
}

.tracking-not-found a {
    color: var(--color-cyan);
    font-weight: 600;
    text-decoration: none;
}

.tracking-not-found a:hover {
    text-decoration: underline;
}

/* =========================
   HEADER + STATUS BADGE
========================= */

.tracking-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;

    margin-bottom: 24px;
}

.tracking-print-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    margin-bottom: 24px;
    padding: 10px 18px;

    background: var(--color-field-bg);
    border-radius: 50px;

    color: var(--color-text-dark);
    text-decoration: none;
    font-weight: 600;
    font-size: .85rem;

    transition: background var(--transition-base);
}

.tracking-print-link:hover {
    background: var(--color-border-light);
}

.tracking-label {
    font-size: .72rem;
    letter-spacing: 2px;
    color: var(--color-text-muted);
    font-weight: 700;
}

.tracking-header h2 {
    margin-top: 8px;
    font-size: 1.8rem;
    color: var(--color-text-dark);
    font-weight: 700;
    letter-spacing: .5px;
}

.tracking-status-badge {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 999px;

    font-size: .85rem;
    font-weight: 700;
    white-space: nowrap;
}

.tracking-status-badge.active {
    background: #e0f7fa;
    color: #0799b3;
}

.tracking-status-badge.completed {
    background: #dcfce7;
    color: #16a34a;
}

.tracking-status-badge.pending {
    background: var(--color-chip-bg);
    color: var(--color-text-muted);
}

.tracking-status-badge.cancelled {
    background: #fee2e2;
    color: #dc2626;
}

/* =========================
   PROGRESS BAR
========================= */

.tracking-progress {
    margin-bottom: 34px;
}

.tracking-progress-bar {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: var(--color-chip-bg);
    overflow: hidden;
}

.tracking-progress-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--color-cyan), var(--color-cyan-hover));
    transition: width .5s ease;
}

/* =========================
   TIMELINE
========================= */

.timeline {
    position: relative;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 21px;
    top: 4px;
    bottom: 4px;
    width: 2px;
    background: var(--color-border-light);
    z-index: 1;
}

.timeline-progress-fill-line {
    position: absolute;
    left: 21px;
    top: 4px;
    width: 2px;
    height: 0;
    background: linear-gradient(180deg, var(--color-navy-deep), var(--color-cyan));
    border-radius: 2px;
    z-index: 1;
    transition: height .6s ease;
}

.timeline-item {
    display: flex;
    gap: 20px;
    position: relative;
    margin-bottom: 26px;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-dot {
    width: 44px;
    height: 44px;
    border-radius: 50%;

    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;

    z-index: 2;
    background: var(--color-chip-bg);
    color: var(--color-text-muted);

    box-shadow: 0 0 0 4px #fff;
}

.timeline-dot svg {
    width: 20px;
    height: 20px;
}

.timeline-item.completed .timeline-dot {
    background: var(--color-navy-deep);
    color: white;
}

.timeline-item.cancelled .timeline-dot {
    background: #dc2626;
    color: white;
}

.timeline-item.active .timeline-dot {
    background: var(--color-cyan);
    color: white;
    box-shadow: 0 0 0 4px #fff, 0 0 0 8px rgba(8,182,214,.25);
}

.timeline-item.pending .timeline-dot {
    background: var(--color-chip-bg);
    color: var(--color-text-muted);
}

.timeline-content {
    padding-top: 8px;
}

.timeline-content h4 {
    font-size: 1.05rem;
    color: var(--color-text-dark);
    margin-bottom: 4px;
    font-weight: 600;
}

.timeline-item.pending .timeline-content h4 {
    color: var(--color-text-muted);
}

.timeline-content span {
    color: var(--color-text-muted);
    font-size: .87rem;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 768px) {

    .tracking-result {
        padding: 0 5% 60px;
    }

    .tracking-card {
        padding: 24px;
    }

    .tracking-header {
        flex-direction: column;
        gap: 12px;
    }

    .tracking-header h2 {
        font-size: 1.5rem;
    }

    .timeline-content h4 {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {

    .tracking-card {
        padding: 18px;
    }

    .tracking-not-found {
        padding: 40px 18px;
    }

    .timeline-item {
        gap: 12px;
    }

    .timeline-dot {
        width: 36px;
        height: 36px;
    }

    .timeline-dot svg {
        width: 16px;
        height: 16px;
    }

    .timeline-content h4 {
        font-size: .92rem;
        overflow-wrap: break-word;
    }

    .timeline-content span {
        font-size: .82rem;
    }
}

.track-error {
    display: none;
    margin-top: 12px;
    color: #dc2626;
    font-size: .9rem;
    font-weight: 500;
}

.input-error {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 4px rgba(220,38,38,.1);
}