/* Transport-order archive, generator, and logistics review */
.documents-intro { display:flex; align-items:center; gap:14px; padding:17px 19px; margin-bottom:18px; }
.documents-intro-icon,.transport-order-icon { width:42px; height:42px; flex:0 0 auto; display:grid; place-items:center; color:var(--navy); background:#edf2fb; border-radius:12px; }
.documents-intro strong { font-size:14px; }
.documents-intro p { margin:5px 0 0; color:var(--muted); font-size:12px; line-height:1.5; }
.documents-counter { margin-left:auto; padding:7px 10px; color:#526074; background:#f5f6f8; border-radius:999px; font-size:11px; font-weight:700; white-space:nowrap; }
.documents-tools { display:flex; align-items:center; justify-content:space-between; gap:15px; margin:0 0 12px; }
.documents-tools .search-field { max-width:520px; }
.transport-order-list,.transport-deal-list { display:grid; gap:10px; }
.transport-order-row { display:grid; grid-template-columns:42px minmax(0,1fr) auto; align-items:center; gap:14px; padding:14px 16px; }
.transport-order-main { display:grid; gap:4px; min-width:0; }
.transport-order-main strong { font-size:13px; overflow-wrap:anywhere; }
.transport-order-main span,.transport-order-main small { color:var(--muted); font-size:11px; line-height:1.5; }
.transport-order-actions { display:flex; align-items:center; justify-content:flex-end; gap:7px; flex-wrap:wrap; }
.documents-empty-hint { margin-top:12px; padding:18px; }
.documents-empty-hint strong { font-size:13px; }
.documents-empty-hint p { margin:5px 0 12px; color:var(--muted); font-size:12px; }
.transport-toolbar { display:grid; grid-template-columns:minmax(220px,1fr) 190px auto; align-items:center; gap:12px; padding:12px; margin-bottom:13px; }
.transport-toolbar .search-field input { height:38px; }
.transport-toolbar select { min-width:0; height:38px; border:1px solid var(--line); border-radius:9px; padding:0 10px; background:#fff; color:var(--ink); }
.transport-toolbar > .subtle { white-space:nowrap; text-align:right; }
.transport-metrics { margin-bottom:15px; }
.transport-deal-row { display:grid; grid-template-columns:minmax(0,1fr) 210px; gap:20px; padding:17px 18px; }
.transport-deal-main { min-width:0; }
.transport-deal-title { display:flex; justify-content:space-between; align-items:flex-start; gap:14px; }
.transport-deal-title h2 { margin:4px 0 0; font-size:16px; letter-spacing:-.025em; overflow-wrap:anywhere; }
.transport-deal-meta { display:flex; gap:24px; flex-wrap:wrap; margin:15px 0 12px; }
.transport-deal-meta span { display:grid; gap:4px; min-width:120px; }
.transport-deal-meta small,.transport-client-facts dt { color:var(--muted); font-size:10px; }
.transport-deal-meta strong { font-size:12px; font-weight:650; }
.transport-stage { color:#707987; }
.transport-stage.stage-1 { color:#9b6208; }
.transport-stage.stage-2 { color:#7c5a07; }
.transport-stage.stage-3 { color:var(--navy); }
.transport-stage.stage-4 { color:var(--green); }
.transport-deal-files { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.transport-file-chip,.transport-file-count { display:inline-flex; align-items:center; gap:7px; min-height:30px; padding:5px 9px; border-radius:8px; background:#f6f7f9; color:#4d5b6d; text-decoration:none; font-size:10px; }
.transport-file-chip:hover { background:#edf2fb; color:var(--navy); }
.transport-file-chip span { max-width:min(420px,42vw); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.transport-file-chip strong { font-size:10px; color:var(--ink); }
.transport-file-open { padding:0; border:0; background:transparent; color:var(--navy); font:inherit; text-align:left; text-decoration:underline; cursor:pointer; overflow-wrap:anywhere; }
.transport-file-chip a { color:var(--navy); font-size:10px; text-decoration:none; white-space:nowrap; }
.transport-file-empty { color:var(--muted); font-size:11px; }
.transport-file-count { background:transparent; color:var(--muted); }
.transport-deal-actions { display:grid; align-content:center; gap:9px; }
.transport-deal-actions .field { margin:0; }
.transport-deal-actions .field-label { font-size:10px; }
.transport-deal-actions select { width:100%; min-height:38px; }
.transport-detail-page { display:grid; grid-template-columns:minmax(0,1fr); gap:15px; min-width:0; }
.transport-detail-hero { display:flex; align-items:flex-start; justify-content:space-between; gap:18px; padding:23px; }
.transport-detail-hero,.transport-stage-panel,.transport-detail-section { min-width:0; }
.transport-detail-hero h1 { margin:6px 0; font-size:25px; letter-spacing:-.04em; overflow-wrap:anywhere; }
.transport-detail-hero p { margin:0; color:var(--muted); font-size:12px; }
.transport-stage-panel,.transport-detail-section { padding:18px; }
.transport-stage-panel .panel-heading { align-items:center; }
.transport-stage-control { width:min(260px,100%); margin:0; }
.transport-timeline { display:grid; grid-template-columns:repeat(4,minmax(110px,1fr)); gap:8px; margin:12px 0 17px; }
.transport-timeline-step { position:relative; display:grid; justify-items:center; gap:8px; min-width:0; color:#929ba7; text-align:center; }
.transport-timeline-step:not(:last-child)::after { content:""; position:absolute; z-index:0; height:2px; top:13px; left:calc(50% + 18px); width:calc(100% - 28px); background:#e8ebef; }
.transport-timeline-step.done:not(:last-child)::after { background:#b8dccc; }
.transport-timeline-step i { position:relative; z-index:1; width:28px; height:28px; display:grid; place-items:center; border:1px solid #dfe4ea; border-radius:50%; background:#fff; font-size:11px; font-style:normal; }
.transport-timeline-step.done { color:var(--green); }
.transport-timeline-step.done i { color:var(--green); background:var(--green-soft); border-color:#b8dccc; }
.transport-timeline-step.current i { color:#fff; background:var(--navy); border-color:var(--navy); }
.transport-timeline-step strong { font-size:10px; font-weight:650; }
.transport-history { display:grid; grid-template-columns:repeat(auto-fit,minmax(175px,1fr)); gap:10px; padding-top:12px; border-top:1px solid var(--line); }
.transport-history > div { display:grid; grid-template-columns:9px minmax(0,1fr); column-gap:8px; align-items:center; }
.transport-history-dot { width:7px; height:7px; border-radius:50%; background:var(--green); grid-row:span 2; }
.transport-history strong { font-size:11px; }
.transport-history small { margin-top:3px; color:var(--muted); font-size:10px; }
.transport-detail-grid { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.transport-detail-grid > * { min-width:0; }
.transport-detail-section > header { display:flex; align-items:center; justify-content:space-between; gap:12px; padding-bottom:13px; margin-bottom:12px; border-bottom:1px solid var(--line); }
.transport-detail-section > header h2 { margin:0; font-size:14px; }
.transport-detail-section > header p { margin:4px 0 0; color:var(--muted); font-size:11px; }
.transport-detail-section > header > svg { color:var(--navy); flex:0 0 auto; }
.transport-client-facts { display:grid; grid-template-columns:1fr 1fr; gap:14px 18px; margin:0; }
.transport-client-facts > div { min-width:0; }
.transport-client-facts > div:nth-child(3) { grid-column:1/-1; }
.transport-client-facts dt { margin-bottom:4px; }
.transport-client-facts dd { margin:0; font-size:12px; line-height:1.55; overflow-wrap:anywhere; }
.transport-client-facts a { color:var(--navy); text-decoration:none; }
.transport-document-list { display:grid; gap:8px; }
.transport-document-row { display:flex; align-items:center; gap:11px; min-width:0; padding:9px; border:1px solid var(--line); border-radius:10px; text-decoration:none; color:var(--ink); }
.transport-document-row:hover { border-color:#c5d3ec; background:#fafbfe; }
.transport-document-open { display:flex; align-items:center; gap:11px; flex:1; min-width:0; padding:0; border:0; background:transparent; color:inherit; font:inherit; text-align:left; cursor:pointer; }
.transport-document-row .transport-order-icon { width:36px; height:36px; border-radius:9px; flex:0 0 auto; }
.transport-document-open > span:nth-child(2) { display:grid; gap:4px; flex:1; min-width:0; }
.transport-document-row strong { font-size:11px; overflow-wrap:anywhere; }
.transport-document-row small { color:var(--muted); font-size:10px; }
.transport-document-row > svg:last-child { color:#8d98a6; flex:0 0 auto; }
.app-dialog:has(.transport-dialog-inner) { width:min(1100px,calc(100vw - 28px)); max-height:min(94dvh,1000px); }
.transport-dialog-inner { width:auto; max-height:none; overflow:visible; padding:24px; }
.transport-dialog-header { position:sticky; z-index:5; top:-24px; margin:-24px -24px 16px; padding:22px 24px 14px; background:rgba(255,255,255,.97); border-bottom:1px solid var(--line); backdrop-filter:blur(12px); }
.transport-dialog-header h2 { margin:6px 0; font-size:21px; }
.transport-dialog-header p { margin:0; max-width:700px; color:var(--muted); font-size:11px; line-height:1.5; }
.transport-form-section { padding:17px 0; border-bottom:1px solid var(--line); }
.transport-section-title { display:flex; align-items:flex-start; gap:11px; margin-bottom:14px; }
.transport-section-title > span { display:grid; place-items:center; width:27px; height:27px; flex:0 0 auto; border-radius:8px; background:#edf2fb; color:var(--navy); font-size:10px; font-weight:800; }
.transport-section-title h3 { margin:2px 0 4px; font-size:14px; }
.transport-section-title p { margin:0; color:var(--muted); font-size:11px; line-height:1.5; }
.transport-form-columns { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.transport-form-card { min-width:0; padding:14px; border:1px solid var(--line); border-radius:12px; background:#fbfcfd; }
.transport-form-card h4 { margin:0 0 12px; font-size:12px; }
.transport-form-card .form-grid { grid-template-columns:1fr 1fr; gap:0 12px; }
.transport-form-card .field-full { grid-column:1/-1; }
.transport-form-section .field { min-width:0; margin-bottom:11px; }
.transport-form-section .field label { font-size:11px; }
.transport-form-section .field input,.transport-form-section .field select,.transport-form-section .field textarea { padding:9px 10px; border-radius:8px; font-size:13px; }
.transport-form-section .field textarea { min-height:76px; }
.transport-array-head { display:flex; justify-content:space-between; align-items:center; gap:10px; margin:9px 0; }
.transport-array-head > strong { font-size:12px; }
.transport-array-list { display:grid; gap:8px; overflow-x:auto; padding-bottom:2px; }
.transport-array-row { display:grid; align-items:end; gap:9px; min-width:600px; padding:11px; border:1px solid var(--line); border-radius:10px; background:#fff; }
.transport-goods-row { grid-template-columns:24px minmax(220px,2fr) minmax(90px,.7fr) minmax(100px,.8fr) 32px; }
.transport-dimension-row { grid-template-columns:24px repeat(3,minmax(65px,.65fr)) minmax(60px,.55fr) minmax(130px,1.5fr) 32px; }
.transport-array-row .field { margin:0; }
.transport-array-row .field label { font-size:10px; }
.transport-array-row .field input { padding:8px; font-size:12px; }
.transport-row-index { align-self:center; color:#909aa8; font-size:10px; text-align:center; }
.transport-row-remove { align-self:center; color:#909aa8; }
.transport-row-remove:hover { color:#b9212d; background:var(--red-soft); }
.transport-cargo-meta { margin-top:12px; }
.dimensions-head { padding-top:9px; margin-top:3px; }
.transport-suggest-wrap { position:relative; }
.field-suggestions { position:absolute; z-index:9; top:calc(100% + 4px); left:0; right:0; display:grid; max-height:200px; overflow:auto; padding:4px; border:1px solid var(--line); border-radius:9px; background:#fff; box-shadow:var(--shadow); }
.field-suggestions[hidden] { display:none; }
.field-suggestions button { border:0; border-radius:6px; padding:8px 9px; background:#fff; color:var(--ink); text-align:left; font-size:12px; line-height:1.4; overflow-wrap:anywhere; }
.field-suggestions button:hover { background:#f1f4f9; color:var(--navy); }
.transport-form-footer { position:sticky; z-index:4; bottom:-24px; display:flex; align-items:center; justify-content:space-between; gap:16px; margin:0 -24px -24px; padding:14px 24px; background:rgba(255,255,255,.97); border-top:1px solid var(--line); backdrop-filter:blur(12px); }
.transport-form-footer > span { color:var(--muted); font-size:11px; line-height:1.45; }
.transport-form-footer > span span { color:var(--red); font-weight:800; }
.transport-form-footer .dialog-actions { flex:0 0 auto; margin:0; }
.deal-transport-orders { display:grid; gap:6px; margin-top:13px; padding-top:11px; border-top:1px solid var(--line); }
.deal-transport-orders > strong { color:#5d6a7a; font-size:10px; }
.deal-transport-orders a { display:flex; align-items:center; gap:7px; color:var(--navy); font-size:10px; text-decoration:none; overflow-wrap:anywhere; }
.deal-transport-orders a small { margin-left:auto; color:var(--muted); white-space:nowrap; }
.deal-summary-transport { padding:18px; }

@media (max-width:900px) {
  .transport-toolbar { grid-template-columns:minmax(0,1fr) minmax(120px,.7fr); gap:9px; padding:10px; }
  .transport-toolbar .search-field { grid-column:1/-1; }
  .transport-toolbar > .subtle { grid-column:1/-1; text-align:left; }
  .transport-deal-row { grid-template-columns:minmax(0,1fr) 185px; gap:13px; }
  .transport-detail-grid,.transport-form-columns { grid-template-columns:1fr; }
  .transport-timeline { grid-template-columns:repeat(4,minmax(0,1fr)); }
  .transport-form-card .form-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:640px) {
  .documents-intro { align-items:flex-start; padding:14px; }
  .documents-intro-icon { width:36px; height:36px; }
  .documents-counter { font-size:9px; padding:6px 7px; }
  .documents-tools { align-items:stretch; flex-direction:column; gap:7px; }
  .documents-tools .search-field { max-width:none; }
  .transport-order-row { grid-template-columns:36px minmax(0,1fr); gap:11px; padding:12px; }
  .transport-order-row .transport-order-icon { width:36px; height:36px; }
  .transport-order-actions { grid-column:1/-1; justify-content:flex-start; }
  .transport-toolbar { grid-template-columns:minmax(0,1fr) minmax(120px,.7fr); gap:9px; padding:10px; }
  .transport-toolbar .search-field { grid-column:1/-1; }
  .transport-toolbar > .subtle { grid-column:1/-1; text-align:left; }
  .transport-deal-row { grid-template-columns:1fr; gap:12px; padding:14px; }
  .transport-deal-actions { grid-template-columns:minmax(0,1fr) auto; align-items:end; }
  .transport-deal-actions .button { min-height:38px; }
  .transport-deal-meta { gap:12px 18px; }
  .transport-deal-meta span { min-width:calc(50% - 12px); }
  .transport-detail-hero { padding:17px; }
  .transport-detail-hero h1 { font-size:20px; }
  .transport-stage-panel,.transport-detail-section { padding:14px; }
  .transport-stage-panel .panel-heading { align-items:flex-start; flex-direction:column; }
  .transport-stage-control { width:100%; }
  .transport-timeline { grid-template-columns:repeat(4,minmax(72px,1fr)); gap:4px; overflow-x:auto; padding-bottom:4px; }
  .transport-timeline-step strong { font-size:9px; }
  .transport-timeline-step:not(:last-child)::after { left:calc(50% + 15px); width:calc(100% - 22px); }
  .transport-client-facts { grid-template-columns:1fr 1fr; gap:12px; }
  .app-dialog:has(.transport-dialog-inner) { width:calc(100vw - 12px); max-height:96dvh; }
  .transport-dialog-inner { padding:15px; }
  .transport-dialog-header { top:-15px; margin:-15px -15px 8px; padding:15px 15px 12px; }
  .transport-dialog-header h2 { font-size:18px; }
  .transport-form-section { padding:14px 0; }
  .transport-form-card { padding:11px; }
  .transport-form-card .form-grid { grid-template-columns:1fr; }
  .transport-form-card .field-full { grid-column:auto; }
  .transport-array-row { min-width:0; gap:8px; padding:10px; }
  .transport-goods-row { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .transport-goods-row > .transport-row-index { grid-column:1; grid-row:1; justify-self:start; }
  .transport-goods-row > .field:nth-child(2) { grid-column:1/-1; }
  .transport-goods-row > .field:nth-child(3) { grid-column:1; }
  .transport-goods-row > .field:nth-child(4) { grid-column:2; }
  .transport-goods-row > .transport-row-remove { grid-column:2; grid-row:1; justify-self:end; }
  .transport-dimension-row { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .transport-dimension-row > .transport-row-index { grid-column:1; grid-row:1; justify-self:start; }
  .transport-dimension-row > .field:nth-child(2),.transport-dimension-row > .field:nth-child(3),.transport-dimension-row > .field:nth-child(4) { grid-row:2; }
  .transport-dimension-row > .field:nth-child(5) { grid-column:1; grid-row:3; }
  .transport-dimension-row > .field:nth-child(6) { grid-column:2/-1; grid-row:3; }
  .transport-dimension-row > .transport-row-remove { grid-column:3; grid-row:1; justify-self:end; }
  .transport-form-section .field input,.transport-form-section .field select,.transport-form-section .field textarea { min-height:44px; font-size:16px; }
  .transport-form-section .field textarea { min-height:108px; }
  .transport-array-row .field input { min-height:44px; font-size:16px; }
  .transport-row-remove { width:38px; height:38px; }
  .transport-array-head .button { min-height:40px; }
  .transport-form-footer { bottom:-15px; align-items:stretch; flex-direction:column; margin:0 -15px -15px; padding:12px 15px; }
  .transport-form-footer .dialog-actions { width:100%; }
  .transport-form-footer .dialog-actions .button { flex:1; }
}
