/* ============================================================
   KHADIZA DREAMS — track-order.css
   Used only by: track-order.html
   Depends on: styles.css (tokens, buttons, footer, drawers)
   ============================================================ */


/* ============================================================
   1. BREADCRUMBS
   ============================================================ */
.crumbs{
  padding-block:24px;
  font-size:10.5px;
  letter-spacing:.18em;
  text-transform:uppercase;
  color:var(--muted);
}
.crumbs a{ transition:color .3s; }
.crumbs a:hover{ color:var(--ink); }
.crumbs span{ margin-inline:9px; opacity:.45; }


/* ============================================================
   2. PAGE HEAD
   ============================================================ */
.track-head{
  padding-block:clamp(36px, 4.6vw, 64px) clamp(22px, 2.8vw, 36px);
  text-align:center;
  border-bottom:1px solid var(--line);
}

.track-head__eyebrow{
  font-size:10.5px;
  letter-spacing:.28em;
  text-transform:uppercase;
  color:var(--muted);
  margin-bottom:14px;
}

.track-head__title{
  font-size:clamp(30px, 4.4vw, 56px);
  font-weight:300;
  line-height:1.06;
  margin:0 auto 18px;
  max-width:20ch;
}

.track-head__title em{
  font-style:italic;
  color:var(--gold);
}

.track-head__text{
  max-width:52ch;
  margin:0 auto;
  font-size:15px;
  font-weight:300;
  line-height:1.75;
  color:var(--ink-soft);
}


/* ============================================================
   3. LOOKUP FORM
   ============================================================ */
.lookup{
  max-width:720px;
  margin:0 auto;
  padding-block:clamp(28px, 3.4vw, 44px);
}

.lookup__form{
  display:grid;
  grid-template-columns:1fr 1fr auto;
  gap:14px;
  align-items:end;
}

.lookup__field{
  display:flex;
  flex-direction:column;
  gap:8px;
  min-width:0;
}

.lookup__label{
  font-size:10px;
  font-weight:500;
  letter-spacing:.2em;
  text-transform:uppercase;
  color:var(--ink);
}

.lookup__input{
  width:100%;
  padding:14px 16px;
  background:var(--paper);
  border:1px solid var(--line-dark);
  border-radius:var(--radius);
  font-family:var(--font-body);
  font-size:14px;
  font-weight:300;
  color:var(--ink);
  outline:none;
  transition:border-color .3s, box-shadow .3s;
}
.lookup__input::placeholder{ color:var(--muted); }
.lookup__input:focus{
  border-color:var(--ink);
  box-shadow:0 0 0 3px rgba(176,141,87,.12);
}

.lookup__submit{
  padding:14px 30px;
  white-space:nowrap;
}

.lookup__hint{
  margin-top:14px;
  text-align:center;
  font-size:11.5px;
  letter-spacing:.06em;
  color:var(--muted);
}
.lookup__hint strong{ color:var(--ink); font-weight:500; }

.lookup__status{
  min-height:18px;
  margin-top:12px;
  text-align:center;
  font-size:12.5px;
  font-weight:300;
  color:var(--rose);
}


/* ============================================================
   4. IDLE STATE (before searching)
   ============================================================ */
.track-idle{
  padding-block:clamp(40px, 5vw, 72px) clamp(56px, 7vw, 96px);
}

.track-idle__inner{
  max-width:820px;
  margin:0 auto;
  padding:clamp(28px, 4vw, 52px);
  background:var(--soft);
  border-radius:var(--radius);
  text-align:center;
}

.track-idle__icon{
  display:inline-grid;
  place-items:center;
  width:72px;
  height:72px;
  margin-bottom:22px;
  border-radius:50%;
  background:var(--paper);
  color:var(--gold);
}
.track-idle__icon svg{
  width:30px;
  height:30px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.1;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.track-idle__title{
  font-family:var(--font-display);
  font-size:clamp(22px, 2.8vw, 32px);
  font-weight:300;
  line-height:1.15;
  margin-bottom:12px;
}

.track-idle__text{
  max-width:46ch;
  margin:0 auto 26px;
  font-size:13.5px;
  line-height:1.75;
  color:var(--muted);
}

.track-idle__demo{
  display:inline-flex;
  align-items:center;
  gap:10px;
  padding:10px 18px;
  background:var(--paper);
  border:1px dashed var(--line-dark);
  border-radius:99px;
  font-size:11.5px;
  letter-spacing:.04em;
  color:var(--ink-soft);
  transition:border-color .3s, color .3s;
}
.track-idle__demo:hover{
  border-color:var(--ink);
  color:var(--ink);
}
.track-idle__demo code{
  font-family:ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size:11.5px;
  color:var(--gold);
  letter-spacing:.02em;
}


/* ============================================================
   5. RESULT LAYOUT
   ============================================================ */
.track-result{
  padding-block:clamp(32px, 4vw, 56px) clamp(56px, 7vw, 96px);
}

.track-result__inner{
  display:grid;
  grid-template-columns:minmax(0, 1.6fr) minmax(0, 1fr);
  gap:clamp(24px, 3.4vw, 56px);
  align-items:start;
}

.track-result__main{
  display:flex;
  flex-direction:column;
  gap:clamp(22px, 3vw, 34px);
  min-width:0;
}

.track-result__side{
  display:flex;
  flex-direction:column;
  gap:clamp(18px, 2.4vw, 28px);
  position:sticky;
  top:calc(var(--header-h) + 28px);
}


/* ============================================================
   6. SUMMARY BAR
   ============================================================ */
.summary-bar{
  display:grid;
  grid-template-columns:repeat(4, 1fr);
  gap:0;
  padding:clamp(20px, 2.4vw, 28px) 0;
  background:var(--soft);
  border-radius:var(--radius);
  overflow:hidden;
}

.summary-bar__cell{
  display:flex;
  flex-direction:column;
  gap:6px;
  padding:0 clamp(16px, 2.4vw, 26px);
  border-right:1px solid var(--line-dark);
}
.summary-bar__cell:last-child{ border-right:0; }

.summary-bar__label{
  font-size:10px;
  letter-spacing:.2em;
  text-transform:uppercase;
  color:var(--muted);
}

.summary-bar__value{
  font-family:var(--font-display);
  font-size:clamp(15px, 1.4vw, 18px);
  font-weight:500;
  line-height:1.3;
  color:var(--ink);
  word-break:break-word;
}

.summary-bar__value small{
  display:block;
  margin-top:4px;
  font-family:var(--font-body);
  font-size:11px;
  font-weight:300;
  color:var(--muted);
}


/* ============================================================
   7. STATUS TIMELINE
   ============================================================ */
.status-card{
  padding:clamp(24px, 3vw, 40px);
  border:1px solid var(--line);
  border-radius:var(--radius);
  background:var(--paper);
  display:flex;
  flex-direction:column;
  gap:24px;
}

.status-card__head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
  flex-wrap:wrap;
  padding-bottom:20px;
  border-bottom:1px solid var(--line);
}

.status-card__title{
  font-family:var(--font-body);
  font-size:10.5px;
  font-weight:500;
  letter-spacing:.24em;
  text-transform:uppercase;
  color:var(--ink);
}

.status-badge{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 14px;
  border-radius:99px;
  font-size:10px;
  font-weight:500;
  letter-spacing:.18em;
  text-transform:uppercase;
  white-space:nowrap;
}
.status-badge::before{
  content:'';
  width:7px;
  height:7px;
  border-radius:50%;
}
.status-badge--pending{
  background:#fbf4e6; color:#8a6a2b;
}
.status-badge--pending::before{ background:#c9a227; }

.status-badge--making{
  background:#f3e9dc; color:#8b6235;
}
.status-badge--making::before{ background:#b08d57; }

.status-badge--shipped{
  background:#e9eff7; color:#3c5a83;
}
.status-badge--shipped::before{ background:#5b7fa5; }

.status-badge--out{
  background:#e4eaf5; color:#3c5a83;
}
.status-badge--out::before{ background:#4d6fa0; }

.status-badge--delivered{
  background:#e9f2e7; color:#486b3f;
}
.status-badge--delivered::before{ background:#6ea06e; }

.status-badge--cancelled{
  background:#f7e8e6; color:#8a2d26;
}
.status-badge--cancelled::before{ background:var(--rose); }


/* ---------- Timeline ---------- */
.timeline{
  display:flex;
  flex-direction:column;
  gap:0;
}

.timeline__step{
  display:grid;
  grid-template-columns:44px minmax(0, 1fr);
  gap:18px;
  align-items:flex-start;
  position:relative;
  padding-bottom:28px;
}

.timeline__step:last-child{
  padding-bottom:0;
}

.timeline__step::before{
  content:'';
  position:absolute;
  left:21px;
  top:44px;
  bottom:0;
  width:1.5px;
  background:var(--line);
}
.timeline__step:last-child::before{ display:none; }

.timeline__marker{
  position:relative;
  z-index:1;
  display:grid;
  place-items:center;
  width:44px;
  height:44px;
  border-radius:50%;
  background:var(--soft);
  color:var(--muted);
  border:1.5px solid var(--line);
  transition:background .3s, color .3s, border-color .3s;
}
.timeline__marker svg{
  width:18px;
  height:18px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.4;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.timeline__step--done .timeline__marker{
  background:var(--gold);
  color:#fff;
  border-color:var(--gold);
}
.timeline__step--done::before{
  background:var(--gold);
}

.timeline__step--current .timeline__marker{
  background:var(--ink);
  color:var(--paper);
  border-color:var(--ink);
  box-shadow:0 0 0 5px rgba(23,21,18,.06);
}
.timeline__step--current::before{
  background:linear-gradient(to bottom, var(--ink) 0%, var(--ink) 40%, var(--line) 40%);
}

.timeline__body{
  padding-top:8px;
  display:flex;
  flex-direction:column;
  gap:6px;
  min-width:0;
}

.timeline__title{
  font-size:15px;
  font-weight:500;
  line-height:1.3;
  color:var(--ink);
}
.timeline__step:not(.timeline__step--done):not(.timeline__step--current) .timeline__title{
  color:var(--muted);
  font-weight:400;
}

.timeline__text{
  font-size:13px;
  font-weight:300;
  line-height:1.65;
  color:var(--muted);
  max-width:56ch;
}

.timeline__time{
  margin-top:4px;
  font-size:11px;
  letter-spacing:.08em;
  color:var(--ink-soft);
}
.timeline__time strong{
  font-weight:500;
  color:var(--ink);
}


/* ============================================================
   8. ITEMS CARD
   ============================================================ */
.items-card{
  padding:clamp(24px, 3vw, 36px);
  border:1px solid var(--line);
  border-radius:var(--radius);
  background:var(--paper);
  display:flex;
  flex-direction:column;
  gap:18px;
}

.items-card__head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:16px;
  padding-bottom:16px;
  border-bottom:1px solid var(--line);
}

.items-card__title{
  font-family:var(--font-body);
  font-size:10.5px;
  font-weight:500;
  letter-spacing:.24em;
  text-transform:uppercase;
  color:var(--ink);
}

.items-card__count{
  font-size:11px;
  letter-spacing:.14em;
  text-transform:uppercase;
  color:var(--muted);
}

.item-row{
  display:grid;
  grid-template-columns:80px minmax(0, 1fr) auto;
  gap:16px;
  align-items:center;
}

.item-row__media{
  aspect-ratio:3 / 4;
  overflow:hidden;
  background:var(--soft);
  border-radius:var(--radius);
}
.item-row__media img{
  width:100%;
  height:100%;
  object-fit:cover;
}

.item-row__body{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:4px;
}

.item-row__name{
  font-size:14px;
  font-weight:400;
  line-height:1.35;
  color:var(--ink);
}

.item-row__meta{
  font-size:12px;
  color:var(--muted);
}

.item-row__price{
  font-family:var(--font-display);
  font-size:16px;
  font-weight:500;
  color:var(--ink);
  white-space:nowrap;
  text-align:right;
}
.item-row__price small{
  display:block;
  margin-top:3px;
  font-family:var(--font-body);
  font-size:11px;
  font-weight:300;
  color:var(--muted);
}


/* ============================================================
   9. SIDE PANELS
   ============================================================ */
.side-panel{
  padding:clamp(22px, 2.6vw, 32px);
  background:var(--soft);
  border-radius:var(--radius);
  display:flex;
  flex-direction:column;
  gap:18px;
}

.side-panel__title{
  font-family:var(--font-body);
  font-size:10.5px;
  font-weight:500;
  letter-spacing:.24em;
  text-transform:uppercase;
  color:var(--ink);
}

/* Address block */
.addr-block{
  display:flex;
  flex-direction:column;
  gap:5px;
  font-size:13.5px;
  font-weight:300;
  line-height:1.65;
  color:var(--ink-soft);
}
.addr-block strong{
  font-weight:500;
  color:var(--ink);
}
.addr-block__meta{
  margin-top:8px;
  padding-top:12px;
  border-top:1px solid var(--line-dark);
  font-size:12px;
  color:var(--muted);
}

/* Totals block */
.totals{
  display:flex;
  flex-direction:column;
  gap:11px;
  padding-top:18px;
  border-top:1px solid var(--line-dark);
}

.totals__row{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:14px;
  font-size:13px;
  font-weight:300;
  color:var(--ink-soft);
}
.totals__row strong{
  font-weight:400;
  color:var(--ink);
}

.totals__total{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:14px;
  padding-top:18px;
  margin-top:4px;
  border-top:1px solid var(--line-dark);
}
.totals__label{
  font-size:10.5px;
  letter-spacing:.22em;
  text-transform:uppercase;
  color:var(--ink);
}
.totals__total strong{
  font-family:var(--font-display);
  font-size:clamp(22px, 2.4vw, 28px);
  font-weight:500;
  color:var(--ink);
}

/* Help block */
.help-list{
  display:flex;
  flex-direction:column;
  gap:0;
}

.help-item{
  display:flex;
  align-items:center;
  gap:14px;
  padding:14px 0;
  border-bottom:1px solid var(--line-dark);
  font-size:13px;
  font-weight:300;
  color:var(--ink-soft);
  transition:padding-left .3s var(--ease), color .3s;
}
.help-item:last-child{ border-bottom:0; padding-bottom:0; }
.help-item:hover{ padding-left:4px; color:var(--ink); }

.help-item__icon{
  flex-shrink:0;
  display:grid;
  place-items:center;
  width:34px;
  height:34px;
  border-radius:50%;
  background:var(--paper);
  color:var(--gold);
}
.help-item__icon svg{
  width:15px;
  height:15px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.3;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.help-item__arrow{
  margin-left:auto;
  font-size:14px;
  opacity:.4;
  transition:opacity .3s, transform .35s var(--ease);
}
.help-item:hover .help-item__arrow{
  opacity:1;
  transform:translateX(3px);
}

.side-panel .btn{
  width:100%;
}


/* ============================================================
   10. NOT FOUND STATE
   ============================================================ */
.not-found{
  max-width:560px;
  margin:0 auto;
  padding:clamp(48px, 6vw, 88px) clamp(20px, 4vw, 40px);
  text-align:center;
  border:1px dashed var(--line-dark);
  border-radius:var(--radius);
  background:var(--soft);
}

.not-found__icon{
  display:inline-grid;
  place-items:center;
  width:64px;
  height:64px;
  margin-bottom:22px;
  border-radius:50%;
  background:var(--paper);
  color:var(--rose);
}
.not-found__icon svg{
  width:26px;
  height:26px;
  fill:none;
  stroke:currentColor;
  stroke-width:1.3;
  stroke-linecap:round;
  stroke-linejoin:round;
}

.not-found__title{
  font-family:var(--font-display);
  font-size:clamp(22px, 2.8vw, 32px);
  font-weight:300;
  line-height:1.15;
  margin-bottom:10px;
}

.not-found__text{
  max-width:42ch;
  margin:0 auto 26px;
  font-size:13.5px;
  line-height:1.75;
  color:var(--muted);
}

.not-found__actions{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  justify-content:center;
}


/* ============================================================
   11. RESPONSIVE
   ============================================================ */
@media (max-width:1024px){
  .track-result__inner{
    grid-template-columns:1fr;
    gap:28px;
  }
  .track-result__side{
    position:static;
    top:auto;
  }
  .summary-bar{
    grid-template-columns:repeat(2, 1fr);
  }
  .summary-bar__cell:nth-child(2){ border-right:0; }
  .summary-bar__cell:nth-child(-n+2){
    padding-bottom:18px;
    border-bottom:1px solid var(--line-dark);
  }
  .summary-bar__cell:nth-child(n+3){
    padding-top:18px;
  }
}

@media (max-width:720px){
  .lookup__form{
    grid-template-columns:1fr;
    gap:12px;
  }
  .lookup__submit{
    width:100%;
    justify-content:center;
  }

  .item-row{
    grid-template-columns:60px minmax(0, 1fr);
    gap:12px;
  }
  .item-row__price{
    grid-column:2;
    text-align:left;
    font-size:14px;
    margin-top:4px;
  }
  .item-row__price small{
    display:inline;
    margin-left:8px;
    margin-top:0;
  }
}

@media (max-width:480px){
  .summary-bar{
    grid-template-columns:1fr;
  }
  .summary-bar__cell{
    padding:14px 20px;
    border-right:0;
    border-bottom:1px solid var(--line-dark);
  }
  .summary-bar__cell:last-child{ border-bottom:0; }

  .timeline__step{
    grid-template-columns:36px minmax(0, 1fr);
    gap:14px;
  }
  .timeline__marker{
    width:36px;
    height:36px;
  }
  .timeline__marker svg{
    width:15px;
    height:15px;
  }
  .timeline__step::before{
    left:17.5px;
    top:36px;
  }
}