/* Guest order tracking — Menas storefront */

.guest-track {
    max-width: 1000px;
    margin: 0 auto;
    padding: 16px;
    color: #333;
}

.guest-track__breadcrumb {
    font-size: 13px;
    color: #777;
    margin-bottom: 16px;
}
.guest-track__breadcrumb a { color: #777; text-decoration: none; }
.guest-track__breadcrumb a:hover { text-decoration: underline; }
.guest-track__breadcrumb .current { color: #333; }
.guest-track__breadcrumb span { margin: 0 6px; }

/* ---------------- Lookup form ---------------- */
.guest-track__form-wrap {
    max-width: 520px;
    margin: 24px auto;
    background: #fff;
    border: 1px solid #e6e6e6;
    border-radius: 12px;
    padding: 28px;
}
.guest-track__title {
    color: #333;
    font-size: 24px;
    margin: 0 0 8px;
    text-align: center;
}
.guest-track__hint { color: #666; font-size: 14px; margin: 0 0 20px; text-align: center; }
.guest-track__form .field { margin-bottom: 16px; }
.guest-track__form label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 14px; }
.guest-track__form label .req { color: #d9534f; margin-left: 2px; }
.guest-track__form input[type="text"] {
    width: 100%;
    height: 44px;
    border: 1px solid #d5d5d5;
    border-radius: 8px;
    padding: 0 14px;
    box-sizing: border-box;
    font-size: 14px;
}
.guest-track__form input[type="text"]:focus {
    border-color: #7a4fd6;
    outline: none;
    box-shadow: 0 0 0 2px rgba(122, 79, 214, 0.15);
}
.guest-track__submit {
    background: #647D36 !important;
    border-color: #647D36 !important;
    border-radius: 22px;
    width: 100%;
    height: 44px;
    font-weight: 400 !important;
}
/* Space between the submit button and the reCAPTCHA badge below it. */
.guest-track__form .actions { margin-bottom: 18px; }

/* ---------------- Action row (guest detail) ---------------- */
/* Below/outside the summary card (mockup): full-width countdown bar, then the
   "Thanh toán lại" (outline) + "Đặt lại" (filled) buttons bottom-right. */
.gt-order-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    margin: 0 0 24px;
}
/* Countdown bar: takes the whole row above the buttons. */
.gt-countdown-bar {
    flex: 0 0 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 8px;
    background: #fdecec;
    color: #262626;
    font-size: 14px;
    font-weight: 500;
}
.gt-countdown-bar .gt-countdown-icon { display: inline-flex; }
/* Push the timer to the far right of the bar (label stays left). */
.gt-countdown-bar .countdown-time { font-weight: 700; margin-left: auto; color: #cf1322; }
/* Shared pill for both action buttons. */
.gt-order-actions .gt-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    padding: 0 28px;
    border-radius: 20px;
    font-weight: 600;
    text-decoration: none;
}
/* Repayment = outline, Reorder = filled green. */
.gt-order-actions .repayment-action { background: #fff; border: 1.5px solid #647D36; color: #647D36; }
.gt-order-actions .repayment-action:hover { background: #f2f5ea; color: #647D36; text-decoration: none; }
.gt-order-actions .gt-reorder-btn { background: #647D36; border: 1.5px solid #647D36; color: #fff; }
.gt-order-actions .gt-reorder-btn:hover { background: #4A5D28; border-color: #4A5D28; color: #fff; text-decoration: none; }
.gt-order-actions .gt-action-btn.is-disabled { opacity: 0.5; pointer-events: none; }
.guest-track__error {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 12px 14px;
    background: #fdecea;
    border: 1px solid #f5c6c2;
    border-radius: 8px;
    color: #d9534f;
    font-size: 13px;
}
.guest-track__error-icon { width: 18px; height: 18px; flex-shrink: 0; }

/* ---------------- Detail heading ---------------- */
.guest-track__heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 8px 0 24px;
}
.guest-track__heading h1 { color: #5E2B24; font-size: 26px; margin: 0; }
.guest-track__badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 14px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
    background: #fff3e0;
    color: #e08a1e;
}
.guest-track__badge--complete { background: #e7f3e2; color: #647D36; }
.guest-track__badge--canceled { background: #fdecea; color: #d9534f; }
.guest-track__badge--closed,
.guest-track__badge--waiting_for_refund { background: #eef0f2; color: #666; }

/* ---------------- Timeline ---------------- */
.guest-track__timeline {
    display: flex;
    list-style: none;
    padding: 0;
    margin: 0 0 28px;
    counter-reset: step;
}
.guest-track__timeline li {
    flex: 1;
    text-align: center;
    position: relative;
    font-size: 13px;
    color: #9aa0a6;
}
.guest-track__timeline li .dot {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #d3d7db;
    color: #fff;
    margin: 0 auto 8px;
    position: relative;
    z-index: 1;
}
.guest-track__timeline li .dot svg { width: 26px; height: 26px; display: block; }
.guest-track__timeline li .dot i { font-size: 24px; }
/* Box + truck: outline icons the menas-icon font lacks (font only has solid versions).
   Box reuses the theme's shared dang_xu_ly.svg (same asset the logged-in order detail
   uses); truck uses the Figma export. Both as recolourable masks -> white on the dot. */
.guest-track__timeline li .dot .gt-mask {
    display: inline-block;
    width: 24px;
    height: 24px;
    background-color: currentColor;
    -webkit-mask-position: center; mask-position: center;
    -webkit-mask-size: contain; mask-size: contain;
    -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}
.gt-mask--box { -webkit-mask-image: url(../../images/dang_xu_ly.svg); mask-image: url(../../images/dang_xu_ly.svg); }
.gt-mask--truck { -webkit-mask-image: url(../images/timeline/truck.png); mask-image: url(../images/timeline/truck.png); }
.guest-track__timeline li .date { display: block; font-size: 12px; color: #9aa0a6; margin-top: 2px; font-weight: 400; }
.guest-track__timeline li::before {
    content: "";
    position: absolute;
    top: 24px;
    left: -50%;
    width: 100%;
    height: 3px;
    background: #e2e5e8;
    z-index: 0;
}
.guest-track__timeline li:first-child::before { display: none; }

/* Highlighted (done/active) */
.guest-track__timeline li.is-done .dot,
.guest-track__timeline li.is-active .dot { background: #647D36; }
/* Current step a touch lighter, matching the design. */
.guest-track__timeline li.is-active .dot { background: #8aa74f; }
.guest-track__timeline li.is-done,
.guest-track__timeline li.is-active { color: #647D36; font-weight: 600; }
.guest-track__timeline li.is-done::before,
.guest-track__timeline li.is-active::before { background: #647D36; }

/* Cancel node */
.guest-track__timeline li.is-cancel .dot { background: #d9534f; }
.guest-track__timeline li.is-cancel { color: #d9534f; }

/* ---------------- Cards ---------------- */
.guest-track__cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}
.gt-card {
    border: 1px solid #e6e6e6;
    border-radius: 10px;
    padding: 16px 18px;
    background: #fff;
    margin-bottom: 16px;
}
.gt-card h3 {
    color: #647D36;
    font-size: 12px;
    font-weight: 600;
    margin: 0 0 12px;
}
.gt-card dl {
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 8px 16px;
    margin: 0;
    font-size: 14px;
}
.gt-card dt { color: #6d6d6d; font-weight: 400; }
.gt-card dt::after { content: ":"; }
.gt-card dd { margin: 0; color: #262626; font-weight: 600; }
/* Info / receiver cards: one pair per line, value hugging its OWN label (per design).
   Each dt+dd is wrapped in a <div> flex row, so labels are never forced into a shared column. */
.gt-card .gt-kv { display: flex; flex-direction: column; gap: 4px; }
.gt-card .gt-kv > div { display: flex; column-gap: 8px; align-items: baseline; }
.gt-card .gt-kv > div > dt { flex: 0 0 auto; }
.gt-card .gt-kv > div > dd { flex: 1 1 auto; min-width: 0; }
.gt-vat { display: flex; flex-direction: column; gap: 8px; }
.gt-vat__row { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.gt-vat__row > dl:only-child { grid-column: 1 / -1; }
.gt-link-muted { color: #2f6fd6; margin-left: 8px; font-weight: 500; }

/* ---------------- Items ---------------- */
.gt-items { list-style: none; margin: 0; padding: 0; }
.gt-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}
.gt-item:last-child { border-bottom: none; }
.gt-item__thumb { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; margin-right: 12px; flex-shrink: 0; border: 1px solid #f0f0f0; }
/* When the thumb is linked, the anchor becomes the flex child instead of the img. */
.gt-item__thumb-link { display: flex; flex-shrink: 0; margin-right: 12px; }
.gt-item__thumb-link .gt-item__thumb { margin-right: 0; display: block; }
.gt-item__info { flex: 1; }
.gt-item__name { display: block; font-size: 14px; margin-bottom: 4px; color: #6d6d6d; }
a.gt-item__name { color: #6d6d6d; text-decoration: none; }
a.gt-item__name:hover { color: #647D36; text-decoration: underline; }
.gt-item__price { display: block; }
.gt-item__price .now { display: block; color: #5E2B24; font-weight: 700; }
.gt-item__price .was { color: #6d6d6d; text-decoration: line-through; font-size: 11px; }
.gt-item__price .save { color: #389E0D; margin-left: 8px; font-size: 11px; }
.gt-item__qty { color: #262626; font-weight: 600; }

/* ---------------- Summary ---------------- */
.gt-summary {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px 24px;
    margin: 0;
    font-size: 14px;
}
.gt-summary dt { color: #6d6d6d; font-weight: 400; }
.gt-summary dt::after { content: none; }
.gt-summary dd { margin: 0; text-align: right; color: #262626; font-weight: 600; }
.gt-summary dd.is-negative { color: #647D36; }
.gt-summary dt.grand { font-size: 14px; font-weight: 400; color: #6d6d6d; padding-top: 8px; }
.gt-summary dd.grand { font-size: 14px; font-weight: 600; color: #262626; padding-top: 8px; }
.gt-summary dd.grand small { display: block; font-weight: 400; font-size: 12px; color: #b0b0b0; }

@media (max-width: 700px) {
    .guest-track__cards { grid-template-columns: 1fr; }
    .gt-vat__row { grid-template-columns: 1fr; gap: 8px; }
    .guest-track__timeline li { font-size: 11px; }
}
