/* Orders — Filament ledger (ol-*)
   Dynamic Island chrome · high-contrast controls · --lg-nav-* baseline */

.ol-orders {
  width: min(920px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 100px;
  color: var(--lg-ink);
}

.ol-kicker {
  margin: 0;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--lg-copper-deep);
  font-weight: 800;
}

.ol-mast {
  margin-bottom: 24px;
  animation: lgFadeUp 0.7s var(--lg-ease) both;
}

.ol-mast h1 {
  margin: 8px 0;
  font-family: var(--lg-font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--lg-ink);
}

.ol-mast h1 span {
  color: var(--lg-sap);
  font-style: italic;
  font-weight: 600;
}

.ol-mast > p {
  margin: 0;
  max-width: 48ch;
  color: var(--lg-nav-muted);
  line-height: 1.55;
  font-weight: 500;
}

.ol-loading {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 20px;
  border-radius: var(--lg-nav-radius);
  border: 1px dashed rgba(19, 32, 25, 0.22);
  background: rgba(255, 255, 255, 0.9);
  color: var(--lg-nav-muted);
  font-weight: 600;
}

.ol-loading-bar {
  width: 42px;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--lg-sap), var(--lg-copper), var(--lg-sap));
  background-size: 200% 100%;
  animation: olShimmer 1.1s linear infinite;
}

@keyframes olShimmer {
  to { background-position: -200% 0; }
}

.ol-gate,
.ol-empty {
  padding: 40px 28px;
  text-align: center;
  border-radius: var(--lg-nav-radius);
  background: rgba(255, 255, 255, 0.92);
  border: 1px dashed rgba(19, 32, 25, 0.22);
  box-shadow: 0 10px 28px rgba(19, 32, 25, 0.06);
}

.ol-gate h2,
.ol-empty h2 {
  margin: 0 0 8px;
  font-family: var(--lg-font-display);
  font-size: 1.5rem;
  color: var(--lg-ink);
}

.ol-gate p,
.ol-empty p {
  margin: 0 auto;
  max-width: 40ch;
  color: var(--lg-nav-muted);
  font-weight: 500;
  line-height: 1.5;
}

.ol-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 16px;
  min-height: 52px;
  padding: 0 20px;
  border-radius: var(--lg-nav-radius-sm);
  border: 1.5px solid var(--lg-nav-active-bg);
  background: var(--lg-nav-active-bg);
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
  font-size: 0.8rem;
  box-shadow: 0 10px 24px rgba(15, 107, 72, 0.22);
  transition: background 0.25s var(--lg-ease), border-color 0.25s, transform 0.25s, color 0.25s;
}

.ol-cta:hover,
.ol-cta:focus-visible {
  background: #0c563a;
  border-color: #0c563a;
  color: #ffffff;
  transform: translateY(-1px);
  outline: none;
}

.ol-hub { display: grid; gap: 20px; }

.ol-meters {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.ol-meter {
  padding: 14px 16px;
  border-radius: var(--lg-nav-radius);
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(19, 32, 25, 0.14);
  animation: lgFadeUp 0.55s var(--lg-ease) both;
  animation-delay: calc(var(--m, 0) * 45ms);
}

.ol-meter span {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lg-nav-muted);
  font-weight: 800;
}

.ol-meter strong {
  display: block;
  margin-top: 6px;
  font-family: var(--lg-font-display);
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  color: var(--lg-ink);
}

.ol-meter em {
  display: block;
  margin-top: 4px;
  font-style: normal;
  font-size: 0.82rem;
  color: var(--lg-copper-deep);
  font-weight: 700;
}

.ol-meter--wide {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 2px 16px;
  align-items: baseline;
  background:
    linear-gradient(135deg, rgba(179, 92, 42, 0.1), transparent 45%),
    rgba(255, 255, 255, 0.94);
}

.ol-meter--wide span { grid-column: 1 / -1; }
.ol-meter--wide strong { color: var(--lg-sap); }

@media (max-width: 720px) {
  .ol-meters { grid-template-columns: 1fr 1fr; }
}

.ol-list { display: grid; gap: 12px; }

.ol-slate {
  border-radius: var(--lg-nav-radius);
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(19, 32, 25, 0.14);
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(19, 32, 25, 0.06);
  animation: lgFadeUp 0.5s var(--lg-ease) both;
  animation-delay: calc(var(--i, 0) * 40ms);
  transition: border-color 0.25s var(--lg-ease), transform 0.25s var(--lg-ease), box-shadow 0.25s;
}

.ol-slate:hover {
  border-color: rgba(15, 107, 72, 0.45);
  box-shadow: 0 12px 32px rgba(19, 32, 25, 0.08);
}

.ol-slate.is-open {
  border-color: var(--lg-sap);
  transform: translateY(-1px);
}

.ol-face {
  appearance: none;
  width: 100%;
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border: 0;
  background: transparent;
  color: var(--lg-ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 0.2s;
}

.ol-face:hover,
.ol-face:focus-visible {
  background: var(--lg-panel);
  outline: none;
}

@media (max-width: 640px) {
  .ol-face { grid-template-columns: 56px 1fr; }
  .ol-state {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
}

.ol-date {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: var(--lg-nav-radius-sm);
  background: var(--lg-nav-ink);
  color: #f4f8f5;
  text-align: center;
  line-height: 1.05;
}

.ol-date-day {
  font-family: var(--lg-font-display);
  font-size: 1.35rem;
  font-weight: 800;
}

.ol-date-mon,
.ol-date-yr {
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.85;
  font-weight: 700;
}

.ol-issue {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--lg-copper-deep);
  font-weight: 800;
}

.ol-id {
  display: block;
  margin-top: 2px;
  font-family: var(--lg-font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--lg-ink);
}

.ol-meta {
  display: block;
  margin-top: 2px;
  color: var(--lg-nav-muted);
  font-size: 0.86rem;
  font-weight: 500;
}

.ol-state {
  display: grid;
  justify-items: end;
  gap: 6px;
}

.ol-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 10px;
  border-radius: var(--lg-nav-radius-sm);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: var(--lg-panel);
  color: var(--lg-nav-muted);
  border: 1px solid rgba(19, 32, 25, 0.14);
}

.ol-badge i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.tone-placed .ol-badge {
  color: var(--lg-copper-deep);
  border-color: rgba(179, 92, 42, 0.4);
  background: #f8efe6;
}

.tone-packed .ol-badge {
  color: #0c563a;
  border-color: rgba(15, 107, 72, 0.4);
  background: rgba(15, 107, 72, 0.1);
}

.tone-shipped .ol-badge {
  color: #154a6b;
  border-color: rgba(26, 95, 138, 0.35);
  background: rgba(26, 95, 138, 0.08);
}

.tone-delivered .ol-badge {
  color: #0c563a;
  border-color: rgba(20, 145, 95, 0.4);
  background: rgba(20, 145, 95, 0.1);
}

.tone-cancelled .ol-badge {
  color: #6b1f1f;
  border-color: rgba(138, 48, 48, 0.35);
  background: #f8eaea;
}

.ol-total {
  font-family: var(--lg-font-display);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--lg-ink);
}

.ol-chev {
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--lg-nav-muted);
  border-bottom: 2px solid var(--lg-nav-muted);
  transform: rotate(45deg);
  transition: transform 0.28s var(--lg-ease), border-color 0.2s;
  justify-self: end;
}

.ol-slate.is-open .ol-chev,
.ol-face:hover .ol-chev {
  border-color: var(--lg-sap);
}

.ol-slate.is-open .ol-chev {
  transform: rotate(225deg);
}

.ol-invoice {
  padding: 0 16px 18px;
  border-top: 1px dashed rgba(19, 32, 25, 0.18);
  animation: lgFadeUp 0.4s var(--lg-ease) both;
}

.ol-invoice[hidden] { display: none !important; }

.ol-stamp {
  position: relative;
  display: grid;
  gap: 12px;
  padding: 16px 0 8px;
}

.ol-stamp-kicker {
  margin: 0;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lg-copper-deep);
  font-weight: 800;
}

.ol-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 0;
}

.ol-facts div {
  padding: 10px 12px;
  border-radius: var(--lg-nav-radius-sm);
  background: var(--lg-panel);
  border: 1px solid rgba(19, 32, 25, 0.12);
}

.ol-facts dt {
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lg-nav-muted);
  font-weight: 800;
}

.ol-facts dd {
  margin: 4px 0 0;
  font-weight: 700;
  color: var(--lg-ink);
}

.ol-seal {
  position: absolute;
  right: 0;
  top: 8px;
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  text-align: center;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lg-sap);
  border: 2px dashed rgba(15, 107, 72, 0.45);
  border-radius: 50%;
  transform: rotate(-12deg);
  opacity: 0.85;
  pointer-events: none;
}

@media (max-width: 720px) {
  .ol-facts { grid-template-columns: 1fr 1fr; }
  .ol-seal { display: none; }
}

.ol-pipe,
.ol-cargo { margin-top: 14px; }

.ol-pipe h3,
.ol-cargo h3 {
  margin: 0 0 10px;
  font-family: var(--lg-font-display);
  font-size: 1rem;
  color: var(--lg-ink);
}

.ol-pipe-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.ol-pipe-step {
  display: grid;
  grid-template-columns: 88px 1fr 28px;
  gap: 10px;
  align-items: center;
}

.ol-pipe-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--lg-nav-muted);
}

.ol-pipe-track {
  height: 6px;
  border-radius: 999px;
  background: var(--lg-panel);
  border: 1px solid rgba(19, 32, 25, 0.12);
  overflow: hidden;
}

.ol-pipe-fill {
  display: block;
  height: 100%;
  width: 0;
  background: rgba(19, 32, 25, 0.18);
  transition: width 0.45s var(--lg-ease);
}

.ol-pipe-step.is-done .ol-pipe-fill,
.ol-pipe-step.is-active .ol-pipe-fill {
  width: 100%;
  background: linear-gradient(90deg, var(--lg-sap), var(--lg-sap-bright));
}

.ol-pipe-step.is-done .ol-pipe-label,
.ol-pipe-step.is-active .ol-pipe-label {
  color: var(--lg-ink);
}

.ol-pipe-mark {
  font-size: 0.72rem;
  font-weight: 800;
  text-align: center;
  color: var(--lg-nav-muted);
}

.ol-pipe-step.is-active .ol-pipe-mark { color: var(--lg-sap); }
.ol-pipe-step.is-done .ol-pipe-mark { color: var(--lg-sap-bright); }

.ol-cancel {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 14px;
  border-radius: var(--lg-nav-radius-sm);
  background: #f8eaea;
  border: 1px solid rgba(138, 48, 48, 0.3);
  color: #6b1f1f;
}

.ol-cancel-ring {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid currentColor;
  flex-shrink: 0;
}

.ol-cancel p { margin: 0; font-weight: 700; }

.ol-lines { display: grid; gap: 8px; }

.ol-line {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--lg-nav-radius-sm);
  background: var(--lg-panel);
  border: 1px solid rgba(19, 32, 25, 0.12);
  align-items: center;
}

.ol-line-title {
  font-weight: 700;
  color: var(--lg-ink);
}

.ol-line-qty {
  color: var(--lg-nav-muted);
  font-size: 0.86rem;
  font-weight: 600;
}

.ol-line-total {
  font-weight: 800;
  color: var(--lg-ink);
}

.ol-cargo-empty {
  margin: 0;
  color: var(--lg-nav-muted);
  font-weight: 500;
}

.ol-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(19, 32, 25, 0.14);
}

.ol-track {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 16px;
  border-radius: var(--lg-nav-radius-sm);
  border: 1.5px solid var(--lg-nav-active-bg);
  background: var(--lg-nav-active-bg);
  color: #ffffff;
  text-decoration: none;
  font-weight: 800;
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  box-shadow: 0 8px 20px rgba(15, 107, 72, 0.2);
  transition: background 0.25s var(--lg-ease), border-color 0.25s, transform 0.2s, color 0.2s;
}

.ol-track:hover,
.ol-track:focus-visible {
  background: #0c563a;
  border-color: #0c563a;
  color: #ffffff;
  transform: translateY(-1px);
  outline: none;
}

.ol-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 16px;
  border-radius: var(--lg-nav-radius-sm);
  border: 1.5px solid rgba(19, 32, 25, 0.18);
  color: var(--lg-nav-ink);
  text-decoration: none;
  font-weight: 800;
  font-size: 0.8rem;
  background: var(--lg-panel);
  transition: background 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
}

.ol-secondary:hover,
.ol-secondary:focus-visible {
  background: var(--lg-nav-ink);
  border-color: var(--lg-nav-ink);
  color: #ffffff;
  transform: translateY(-1px);
  outline: none;
}

@media (max-width: 560px) {
  .ol-foot { flex-direction: column; }
  .ol-track,
  .ol-secondary,
  .ol-cta { width: 100%; justify-content: center; }
}
