:root {
  --ink: #182735;
  --ink-soft: #42576a;
  --muted: #718598;
  --muted-light: #98a8b7;
  --line: #dce5ec;
  --line-strong: #c7d4df;
  --canvas: #f4f7f9;
  --paper: #fff;
  --paper-soft: #f8fafc;
  --blue: #1685ed;
  --blue-deep: #086bc8;
  --blue-soft: #eaf5ff;
  --yellow: #d99400;
  --yellow-soft: #fff7dc;
  --green: #168750;
  --green-soft: #e8f7ef;
  --red: #c33a47;
  --red-soft: #fff0f1;
  --orange: #bd6412;
  --orange-soft: #fff3e5;
  --sidebar: #122433;
  --sidebar-soft: #1b3244;
  --focus: 0 0 0 3px rgba(22, 133, 237, .18);
  --radius: 8px;
  --radius-sm: 5px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--canvas);
}

* { box-sizing: border-box; }
html { min-width: 320px; background: var(--canvas); }
body { margin: 0; min-height: 100dvh; color: var(--ink); background: var(--canvas); font-size: 14px; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }
:focus-visible { outline: none; box-shadow: var(--focus); }

.skip-link { position: fixed; left: 16px; top: -60px; z-index: 100; padding: 10px 14px; background: var(--ink); color: #fff; border-radius: 4px; }
.skip-link:focus { top: 16px; }

/* Login */
.login-view { min-height: 100dvh; display: grid; place-items: center; padding: 32px; background: linear-gradient(135deg, #edf5fb, #f7f9fb 58%); }
.login-shell { width: min(980px, 100%); min-height: 560px; display: grid; grid-template-columns: minmax(0, 1.18fr) minmax(350px, .82fr); border: 1px solid var(--line-strong); background: var(--paper); box-shadow: 0 24px 70px rgba(31, 57, 78, .11); }
.login-context { display: flex; flex-direction: column; justify-content: space-between; gap: 48px; padding: 54px; color: #fff; background: radial-gradient(circle at 80% 8%, rgba(61, 170, 255, .35), transparent 32%), linear-gradient(145deg, #102c42, #0c2131); }
.brand-mark { width: 58px; height: 58px; display: grid; place-items: center; border: 0; background: transparent; }
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand-mark.small { width: 36px; height: 36px; flex: none; font-size: 12px; }
.brand-approved { display:inline-flex; align-items:center; gap:10px; flex-shrink:0; }
.brand-approved-icon { display:block; width:58px; height:58px; object-fit:contain; }
.brand-approved-type { display:block; width:77px; height:auto; filter:brightness(0) invert(1); }
.sidebar-brand .brand-approved-icon { width:46px; height:46px; }
.sidebar-brand .brand-approved-type { width:61px; }
.brand-operations-label { white-space:nowrap; font-size:11px; color:#a5bdce; }
.product-label, .page-context { display: block; margin: 0 0 8px; color: var(--blue-deep); font-size: 11px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.login-context .product-label { margin-top: 30px; color: #86c9ff; }
.login-context h1 { max-width: 560px; margin: 0; font-size: clamp(32px, 4vw, 48px); line-height: 1.16; letter-spacing: -.045em; }
.login-context p { max-width: 560px; margin: 20px 0 0; color: #c5d7e4; font-size: 15px; line-height: 1.9; }
.login-principles { display: grid; gap: 0; margin: 0; border-top: 1px solid rgba(255,255,255,.14); }
.login-principles div { display: grid; grid-template-columns: 56px 1fr; gap: 14px; padding: 15px 0; border-bottom: 1px solid rgba(255,255,255,.12); }
.login-principles dt { color: #80c8ff; font-weight: 800; }
.login-principles dd { margin: 0; color: #c5d7e4; line-height: 1.6; }
.login-panel { align-self: center; padding: 54px 48px; }
.login-panel header span { color: var(--blue-deep); font-size: 12px; font-weight: 800; }
.login-panel h2 { margin: 7px 0 32px; font-size: 30px; letter-spacing: -.035em; }
.login-form { display: grid; gap: 9px; }
.login-form label { margin-top: 7px; color: var(--ink-soft); font-size: 13px; font-weight: 700; }
.login-form input { height: 46px; padding: 0 13px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); color: var(--ink); background: #fff; }
.login-form input:focus { border-color: var(--blue); box-shadow: var(--focus); outline: none; }
.login-footnote { margin: 20px 0 0; color: var(--muted); font-size: 12px; text-align: center; line-height: 1.7; }
.form-error { margin: 5px 0; padding: 10px 12px; border-left: 3px solid var(--red); background: var(--red-soft); color: #992a34; font-size: 13px; }

/* Shell */
.admin-shell { min-height: 100dvh; display: grid; grid-template-columns: 232px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; height: 100dvh; display: flex; flex-direction: column; padding: 22px 14px 18px; color: #d9e5ed; background: var(--sidebar); overflow: auto; }
.sidebar-brand { display: flex; align-items: center; gap: 11px; min-height: 48px; padding: 0 8px 18px; border-bottom: 1px solid rgba(255,255,255,.1); }
.sidebar-brand strong, .sidebar-brand small { display: block; }
.sidebar-brand strong { color: #fff; font-size: 15px; }
.sidebar-brand small { margin-top: 3px; color: #8198a9; font-size: 10px; letter-spacing: .04em; }
#primary-nav { display: grid; gap: 3px; margin-top: 15px; }
.nav-section { margin: 18px 10px 5px; color: #708899; font-size: 10px; font-weight: 800; letter-spacing: .14em; }
#primary-nav a { position: relative; display: flex; align-items: center; min-height: 39px; padding: 8px 12px; border-radius: 5px; color: #b9cbd7; font-size: 13px; font-weight: 650; }
#primary-nav a:hover { color: #fff; background: rgba(255,255,255,.07); }
#primary-nav a.active { color: #fff; background: var(--sidebar-soft); }
#primary-nav a.active::before { content: ""; position: absolute; left: 0; top: 9px; bottom: 9px; width: 3px; background: #44a8ff; }
.sidebar-boundary { margin-top: auto; padding: 16px 11px 4px; border-top: 1px solid rgba(255,255,255,.1); }
.sidebar-boundary strong, .sidebar-boundary small { display: block; }
.sidebar-boundary strong { color: #dbe8f0; font-size: 12px; }
.sidebar-boundary small { margin-top: 7px; color: #7790a2; font-size: 11px; line-height: 1.55; }
.workspace { min-width: 0; }
.topbar { position: sticky; top: 0; z-index: 30; min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 12px 28px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.94); backdrop-filter: blur(12px); }
.topbar .page-context { margin-bottom: 3px; color: var(--muted); }
.topbar h1 { margin: 0; font-size: 20px; letter-spacing: -.025em; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.environment-badge { padding: 4px 7px; border: 1px solid #abd2f5; color: var(--blue-deep); background: var(--blue-soft); border-radius: 4px; font-size: 10px; font-weight: 850; }
.admin-name { color: var(--ink-soft); font-size: 13px; }
.main-content { min-width: 0; max-width: 1680px; margin: 0 auto; padding: 28px 30px 52px; }
#content, .detail-stack, .panel, .data-shell { min-width: 0; }
.mobile-only { display: none !important; }

/* Controls */
.button, .icon-button, .segmented button { min-height: 36px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 7px 13px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); color: #29445a; background: #fff; cursor: pointer; font-weight: 750; font-size: 13px; line-height: 1; transition: border-color .14s ease, background .14s ease, color .14s ease; }
.button:hover, .icon-button:hover { border-color: #86bdea; color: var(--blue-deep); background: #f5faff; }
.button.primary { border-color: var(--blue); color: #fff; background: var(--blue); }
.button.primary:hover { border-color: var(--blue-deep); background: var(--blue-deep); }
.button.danger { border-color: var(--red); color: #fff; background: var(--red); }
.button.danger:hover { border-color: #a92c38; color: #fff; background: #a92c38; }
.button.quiet { border-color: transparent; background: transparent; }
.button.small { min-height: 31px; padding: 6px 10px; font-size: 12px; }
.button.full { width: 100%; min-height: 44px; margin-top: 13px; }
.button[disabled], .icon-button[disabled], .segmented button[disabled] { opacity: .45; cursor: not-allowed; }
.button[disabled]:hover { border-color: var(--line-strong); color: #29445a; background: #fff; }
.icon-button { min-width: 36px; padding-inline: 10px; }
.link-button { padding: 0; border: 0; color: var(--blue-deep); background: transparent; cursor: pointer; font: inherit; font-weight: 750; text-align: left; }
.link-button:hover { text-decoration: underline; text-underline-offset: 3px; }
.order-link { font-variant-numeric: tabular-nums; letter-spacing: .025em; }

.page-intro { display: flex; align-items: flex-end; justify-content: space-between; gap: 22px; margin-bottom: 19px; }
.page-intro h2 { margin: 0; font-size: 26px; letter-spacing: -.035em; }
.page-intro p { max-width: 800px; margin: 7px 0 0; color: var(--muted); line-height: 1.65; }
.toolbar { min-height: 58px; display: flex; align-items: center; gap: 9px; margin-bottom: 14px; padding: 10px; border: 1px solid var(--line); background: #fff; }
.toolbar input, .toolbar select, .field input, .field select, .field textarea { min-height: 38px; padding: 8px 11px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); color: var(--ink); background: #fff; outline: none; }
.toolbar input:focus, .toolbar select:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); box-shadow: var(--focus); }
.toolbar input { width: min(360px, 36vw); }
.toolbar select { min-width: 150px; }
.toolbar .spacer { flex: 1; }
.muted { color: var(--muted); }
.numeric { white-space: nowrap; font-variant-numeric: tabular-nums; text-align: right; }
.notice { position: fixed; z-index: 90; right: 24px; top: 88px; max-width: 440px; padding: 12px 15px; border-left: 3px solid var(--green); color: #126a42; background: var(--green-soft); box-shadow: 0 12px 36px rgba(24,39,53,.14); }
.notice.error { border-color: var(--red); color: #962d38; background: var(--red-soft); }
.segmented { display: inline-flex; padding: 3px; border: 1px solid var(--line); background: var(--paper-soft); border-radius: 6px; }
.segmented button { min-height: 31px; border: 0; background: transparent; }
.segmented button.active { color: var(--blue-deep); background: #fff; box-shadow: 0 1px 3px rgba(31,57,78,.1); }

/* Data */
.metrics { display: grid; grid-template-columns: repeat(5, minmax(0,1fr)); margin-bottom: 18px; border: 1px solid var(--line); background: #fff; }
.metric { min-height: 116px; padding: 20px; border-right: 1px solid var(--line); }
.metric:last-child { border-right: 0; }
.metric span, .metric small { display: block; color: var(--muted); }
.metric span { font-size: 12px; font-weight: 750; }
.metric strong { display: block; margin: 10px 0 6px; font-size: 28px; line-height: 1; letter-spacing: -.04em; font-variant-numeric: tabular-nums; }
.metric small { font-size: 11px; line-height: 1.45; }
.metric.attention { box-shadow: inset 0 3px var(--yellow); }
.catalog-metrics { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; margin-bottom: 18px; }
.catalog-metric { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border: 1px solid var(--line); background: var(--paper-soft); }
.catalog-metric span { color: var(--muted); font-size: 12px; }
.catalog-metric strong { font-size: 21px; font-variant-numeric: tabular-nums; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.42fr) minmax(280px, .58fr); gap: 16px; align-items: start; }
.panel, .data-shell { border: 1px solid var(--line); background: #fff; }
.panel + .panel { margin-top: 14px; }
.panel-header { min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 17px; border-bottom: 1px solid var(--line); }
.panel-body { padding: 17px; }
.section-title { margin: 0; font-size: 15px; letter-spacing: -.015em; }
.section-subtitle { margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.55; }
.queue-row, .refund-check-row { display: grid; grid-template-columns: 1.1fr 1.1fr auto auto; gap: 18px; align-items: center; padding: 13px 0; border-bottom: 1px solid var(--line); }
.queue-row:last-child, .refund-check-row:last-child { border-bottom: 0; }
.queue-row strong, .queue-row small { display: block; }
.queue-row small { margin-top: 4px; color: var(--muted); font-size: 11px; }
.refund-check-row { grid-template-columns: 1fr auto; }
.refund-check-row p { margin: 4px 0 0; color: var(--muted); }
.boundary-list { display: grid; gap: 0; }
.boundary-list > div { padding: 12px 0; border-bottom: 1px solid var(--line); }
.boundary-list > div:last-child { border-bottom: 0; }
.boundary-list strong, .boundary-list span { display: block; }
.boundary-list span { margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.55; }

.table-scroll { width: 100%; min-width: 0; max-width: 100%; overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; min-width: 900px; }
.data-table th { position: sticky; top: 0; z-index: 1; padding: 11px 13px; border-bottom: 1px solid var(--line-strong); color: #5d7183; background: #f7f9fb; font-size: 11px; font-weight: 800; letter-spacing: .02em; text-align: left; white-space: nowrap; }
.data-table th.numeric { text-align: right; }
.data-table td { padding: 12px 13px; border-bottom: 1px solid #e8eef3; color: var(--ink-soft); vertical-align: middle; line-height: 1.5; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover td { background: #f8fbfd; }
.data-table .primary-cell { color: var(--ink); min-width: 190px; }
.primary-cell strong, .primary-cell small { display: block; }
.primary-cell strong { font-weight: 750; }
.primary-cell small { max-width: 330px; margin-top: 3px; color: var(--muted); font-size: 10px; overflow-wrap: anywhere; }
.catalog-table { min-width: 960px; table-layout: fixed; }
.catalog-table th:first-child { width: 22%; }
.catalog-table th:last-child { width: 138px; }
.boats-table th:first-child { width: 24%; }
.offers-table th:nth-child(2) { width: 25%; }
.destinations-table th:first-child { width: 24%; }
.cell-details { display: grid; gap: 5px; min-width: 130px; margin: 0; }
.cell-details > div { display: grid; grid-template-columns: minmax(70px, .8fr) minmax(0, 1.2fr); gap: 10px; align-items: baseline; }
.cell-details dt { color: var(--muted); font-size: 10px; white-space: nowrap; }
.cell-details dd { min-width: 0; margin: 0; color: var(--ink); font-size: 12px; font-weight: 700; overflow-wrap: anywhere; }
.cell-details .link-button { font-size: 12px; }
.status-stack { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; max-width: 190px; }
.status { display: inline-flex; align-items: center; min-height: 24px; padding: 3px 7px; border: 1px solid var(--line-strong); border-radius: 4px; color: #526578; background: #f7f9fb; font-size: 11px; font-weight: 800; white-space: nowrap; }
.status.blue { border-color: #b7dcfb; color: #086bc8; background: var(--blue-soft); }
.status.green { border-color: #b8e1ca; color: #157a4a; background: var(--green-soft); }
.status.yellow { border-color: #ead28b; color: #986600; background: var(--yellow-soft); }
.status.red { border-color: #efc4c8; color: #aa3540; background: var(--red-soft); }
.pagination { min-height: 55px; display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 10px 13px; border-top: 1px solid var(--line); }
.pagination span { margin-right: auto; color: var(--muted); font-size: 12px; }
.empty { min-height: 180px; display: grid; place-content: center; justify-items: center; gap: 7px; padding: 30px; color: var(--muted); text-align: center; }
.empty strong { color: var(--ink-soft); font-size: 15px; }
.empty span { max-width: 460px; line-height: 1.7; }

/* Details */
.detail-stack { display: grid; gap: 14px; }
.detail-stack > .panel + .panel { margin-top: 0; }
.detail-layout { display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 15px; align-items: start; }
.detail-actions { position: sticky; top: 92px; margin: 0 !important; }
.entity-hero { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 24px; align-items: start; padding: 21px; border: 1px solid var(--line); background: #fff; }
.entity-hero h2 { margin: 0; font-size: 25px; letter-spacing: -.035em; }
.entity-hero .original-name { margin: 5px 0 0; color: var(--ink-soft); font-size: 14px; }
.entity-hero .entity-meta { margin: 10px 0 0; color: var(--muted); font-size: 11px; overflow-wrap: anywhere; }
.entity-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.count-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px,1fr)); border: 1px solid var(--line); border-top: 0; background: var(--paper-soft); }
.count-item { padding: 13px 16px; border-right: 1px solid var(--line); }
.count-item:last-child { border-right: 0; }
.count-item span, .count-item strong { display: block; }
.count-item span { color: var(--muted); font-size: 11px; }
.count-item strong { margin-top: 5px; font-size: 17px; font-variant-numeric: tabular-nums; }
.overview-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px,1fr)); border: 1px solid var(--line); border-top: 0; background: var(--paper-soft); }
.overview-group { min-width: 0; padding: 15px 17px; border-right: 1px solid var(--line); }
.overview-group:last-child { border-right: 0; }
.overview-group h3 { margin: 0 0 9px; color: var(--ink-soft); font-size: 12px; }
.overview-group .cell-details { gap: 7px; }
.overview-group .cell-details > div { grid-template-columns: minmax(80px, 1fr) auto; }
.overview-group .cell-details dd { font-size: 14px; font-variant-numeric: tabular-nums; text-align: right; }
.summary-grid, .fact-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); }
.summary-item, .fact-item { min-height: 74px; padding: 13px 16px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.summary-item:nth-child(3n), .fact-item:nth-child(3n) { border-right: 0; }
.summary-item span, .summary-item strong, .fact-item dt, .fact-item dd { display: block; }
.summary-item span, .fact-item dt { color: var(--muted); font-size: 11px; }
.summary-item strong, .fact-item dd { margin: 6px 0 0; color: var(--ink); font-size: 14px; font-weight: 720; line-height: 1.55; overflow-wrap: anywhere; }
.fact-item dd a { color: var(--blue-deep); }
.fact-groups { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.fact-group { min-width: 0; border-right: 1px solid var(--line); }
.fact-group:last-child { border-right: 0; }
.fact-group > header { min-height: 72px; padding: 14px 16px; border-bottom: 1px solid var(--line); background: var(--paper-soft); }
.fact-group > header h4 { margin: 0; color: var(--ink); font-size: 13px; }
.fact-group > header p { margin: 5px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.fact-group .fact-grid { grid-template-columns: 1fr; }
.fact-group .fact-item { min-height: 62px; border-right: 0; }
.fact-group .fact-item:last-child { border-bottom: 0; }
.spec-groups, .facility-groups { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; padding: 14px; }
.spec-group, .facility-group { border: 1px solid var(--line); background: var(--paper-soft); }
.spec-group h4, .facility-group h4 { margin: 0; padding: 11px 13px; border-bottom: 1px solid var(--line); color: var(--ink-soft); font-size: 12px; }
.spec-list { margin: 0; }
.spec-list div { display: grid; grid-template-columns: minmax(100px,.7fr) minmax(0,1.3fr); gap: 14px; padding: 9px 13px; border-bottom: 1px solid #e9eef2; }
.spec-list div:last-child { border-bottom: 0; }
.spec-list dt { color: var(--muted); font-size: 12px; }
.spec-list dd { margin: 0; color: var(--ink); font-weight: 700; text-align: right; overflow-wrap: anywhere; }
.facility-list { display: flex; flex-wrap: wrap; gap: 7px; padding: 12px; }
.facility-chip { padding: 5px 8px; border: 1px solid var(--line); color: var(--ink-soft); background: #fff; border-radius: 4px; font-size: 12px; }
.facility-chip em { margin-left: 5px; color: var(--green); font-style: normal; font-size: 10px; }
.text-blocks { display: grid; gap: 12px; padding: 14px; }
.text-block { padding: 14px; border-left: 3px solid #aad3f7; background: var(--paper-soft); }
.text-block h4 { margin: 0 0 7px; font-size: 13px; }
.text-block p { margin: 0; color: var(--ink-soft); line-height: 1.8; white-space: pre-line; }
.media-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 10px; padding: 14px; }
.media-item { min-width: 0; margin: 0; border: 1px solid var(--line); background: var(--paper-soft); }
.media-item img, .media-item video { width: 100%; aspect-ratio: 4/3; display: block; object-fit: cover; background: #e8eef3; }
.media-item figcaption { padding: 8px 9px; color: var(--muted); font-size: 10px; overflow-wrap: anywhere; }
.relation-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 9px; padding: 14px; }
.relation-card { min-width: 0; padding: 12px; border: 1px solid var(--line); background: var(--paper-soft); }
.relation-card strong, .relation-card span, .relation-card small { display: block; }
.relation-card strong { color: var(--ink); }
.relation-card span { margin-top: 5px; color: var(--ink-soft); }
.relation-card small { margin-top: 5px; color: var(--muted); font-size: 10px; }
.json-block { max-height: 360px; margin: 0; padding: 14px; color: #cbe1f2; background: #142432; overflow: auto; font: 11px/1.6 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre-wrap; overflow-wrap: anywhere; }
.action-group { display: grid; gap: 9px; }
.action-note { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.65; }

/* Existing order/user components */
.amount-list { display: grid; gap: 8px; }
.amount-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.amount-row.total { font-size: 16px; }
.order-hero { padding: 20px; border: 1px solid var(--line); background: #fff; }
.order-hero h2 { margin: 0; }
.order-hero .status { margin-top: 10px; }
.order-price { font-size: 23px; }
.traveler { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; gap: 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.traveler-index { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line); color: var(--muted); border-radius: 50%; font-weight: 800; }
.traveler-main strong, .traveler-main span { display: block; }
.traveler-main span { margin-top: 4px; color: var(--muted); font-size: 12px; }
.traveler-main > small { display: block; margin-top: 3px; color: var(--muted); }
.traveler-main dl { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 9px 0 0; }
.traveler-main dl div { display: flex; gap: 6px; }
.traveler-main dt { color: var(--muted); font-size: 11px; }
.traveler-main dd { margin: 0; color: var(--ink-soft); font-size: 11px; }
.traveler-side { display: grid; gap: 4px; justify-items: end; color: var(--ink-soft); font-size: 12px; }
.traveler-list { display: grid; }
.contact-card { padding: 15px; border: 1px solid var(--line); background: var(--paper-soft); }
.contact-card > strong { display: block; margin-bottom: 10px; }
.contact-card dl, .admin-fact-list, .admin-text-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; margin: 0; }
.contact-card dl div, .admin-fact-list div { padding: 9px 11px; border: 1px solid var(--line); background: #fff; }
.contact-card dt, .admin-fact-list dt { color: var(--muted); font-size: 11px; }
.contact-card dd, .admin-fact-list dd { margin: 5px 0 0; color: var(--ink); font-weight: 700; }
.booking-facts { display: grid; gap: 14px; }
.admin-text-list article { padding: 12px; border-left: 3px solid #b9d9f4; background: var(--paper-soft); }
.admin-text-list article p { margin: 6px 0 0; color: var(--ink-soft); line-height: 1.7; }
.timeline { display: grid; gap: 0; }
.timeline-item { position: relative; padding: 13px 13px 13px 19px; border-left: 2px solid var(--line-strong); border-bottom: 1px solid var(--line); }
.timeline-item:last-child { border-bottom: 0; }
.timeline-item::before { content: ""; position: absolute; left: -5px; top: 20px; width: 8px; height: 8px; border: 2px solid #fff; border-radius: 50%; background: var(--blue); }
.timeline-item p { margin: 5px 0 0; color: var(--ink-soft); line-height: 1.55; }
.timeline-item time { display: block; margin-top: 6px; color: var(--muted); font-size: 10px; }
.quote-version { padding-right: 150px; }
.quote-payable { position: absolute; top: 11px; right: 12px; display: grid; justify-items: end; }
.quote-payable span { color: var(--muted); font-size: 10px; }
.quote-payable b { margin-top: 4px; font-size: 17px; }
.discount { color: var(--green); }
.field { display: grid; gap: 6px; margin: 13px 0; }
.field label { color: var(--ink-soft); font-size: 12px; font-weight: 800; }
.field small { color: var(--muted); line-height: 1.55; }
.field textarea { min-height: 100px; resize: vertical; }
.quote-row { display: grid; grid-template-columns: 120px minmax(0,1fr) 130px 40px; gap: 8px; align-items: end; padding: 10px 0; border-bottom: 1px solid var(--line); }
.quote-row .field { margin: 0; }
.refund-warning, .refund-check-message { padding: 12px; border-left: 3px solid var(--yellow); color: #72510c; background: var(--yellow-soft); line-height: 1.65; }
.refund-confirm-reason { padding: 12px; background: var(--paper-soft); }

/* Dialog */
.action-dialog { width: min(720px, calc(100vw - 28px)); max-height: calc(100dvh - 40px); padding: 0; border: 0; background: transparent; }
.action-dialog::backdrop { background: rgba(8, 21, 31, .55); backdrop-filter: blur(2px); }
.dialog-shell { border: 1px solid var(--line); background: #fff; box-shadow: 0 22px 70px rgba(10,30,44,.28); }
.dialog-shell > header { min-height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 13px 17px; border-bottom: 1px solid var(--line); }
.dialog-shell h2 { margin: 0; font-size: 19px; }
#dialog-content { max-height: calc(100dvh - 130px); padding: 18px; overflow: auto; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }

.skeleton { min-height: 360px; border: 1px solid var(--line); background: linear-gradient(90deg,#f3f6f8 25%,#fbfcfd 37%,#f3f6f8 63%); background-size: 400% 100%; animation: shimmer 1.3s infinite; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: 0 0; } }

@media (max-width: 1180px) {
  .metrics { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .metric:nth-child(3) { border-right: 0; }
  .metric:nth-child(n+4) { border-top: 1px solid var(--line); }
  .catalog-metrics { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .dashboard-grid, .detail-layout { grid-template-columns: 1fr; }
  .detail-actions { position: static; }
  .media-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
}

@media (max-width: 760px) {
  .login-view { padding: 0; }
  .login-shell { min-height: 100dvh; grid-template-columns: 1fr; border: 0; }
  .login-context { min-height: 260px; padding: 28px 24px; gap: 24px; }
  .login-context h1 { font-size: 29px; }
  .login-context p, .login-principles { display: none; }
  .login-panel { padding: 35px 24px; }
  .admin-shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; z-index: 60; left: 0; top: 0; width: min(278px,86vw); transform: translateX(-100%); transition: transform .18s ease; box-shadow: 18px 0 46px rgba(0,0,0,.2); }
  .admin-shell.nav-open .sidebar { transform: translateX(0); }
  .mobile-only { display: inline-flex !important; }
  .topbar { min-height: 66px; padding: 10px 13px; gap: 10px; }
  .topbar .page-context, .environment-badge, .admin-name { display: none; }
  .topbar h1 { font-size: 17px; }
  .main-content { padding: 18px 13px 36px; }
  .page-intro { align-items: flex-start; flex-direction: column; }
  .page-intro h2 { font-size: 22px; }
  .toolbar { align-items: stretch; flex-wrap: wrap; }
  .toolbar input, .toolbar select { width: 100%; min-width: 0; }
  .toolbar .spacer { display: none; }
  .metrics { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .metric { border-right: 1px solid var(--line) !important; border-top: 1px solid var(--line); }
  .metric:nth-child(-n+2) { border-top: 0; }
  .metric:nth-child(2n) { border-right: 0 !important; }
  .catalog-metrics { grid-template-columns: 1fr 1fr; }
  .queue-row { grid-template-columns: 1fr auto; }
  .queue-row > :nth-child(2) { display: none; }
  .entity-hero { grid-template-columns: 1fr; padding: 17px; }
  .entity-actions { justify-content: flex-start; }
  .count-strip { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .count-item:nth-child(2n) { border-right: 0; }
  .summary-grid, .fact-grid { grid-template-columns: 1fr 1fr; }
  .summary-item:nth-child(3n), .fact-item:nth-child(3n) { border-right: 1px solid var(--line); }
  .summary-item:nth-child(2n), .fact-item:nth-child(2n) { border-right: 0; }
  .spec-groups, .facility-groups { grid-template-columns: 1fr; }
  .overview-strip, .fact-groups { grid-template-columns: 1fr; }
  .overview-group, .fact-group { border-right: 0; border-bottom: 1px solid var(--line); }
  .overview-group:last-child, .fact-group:last-child { border-bottom: 0; }
  .fact-group .fact-grid { grid-template-columns: 1fr 1fr; }
  .fact-group .fact-item:nth-child(2n) { border-right: 0; }
  .relation-grid { grid-template-columns: 1fr; }
  .media-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .contact-card dl, .admin-fact-list, .admin-text-list { grid-template-columns: 1fr; }
  .traveler { grid-template-columns: 34px minmax(0,1fr); align-items: start; }
  .traveler-side { grid-column: 2; justify-items: start; }
  .quote-row { grid-template-columns: 1fr 1fr; }
  .dialog-actions { flex-wrap: wrap; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* Order support, 2026-10-24 */
.order-quick-links { display:flex; flex-wrap:wrap; gap:8px; margin-top:8px; }
.supplier-email .panel-header { flex-wrap:wrap; gap:12px; }
.supplier-email .field { margin-top:16px; }
.supplier-email textarea { width:100%; min-height:360px; line-height:1.65; resize:vertical; font-family:inherit; }
.supplier-copy-actions { display:flex; flex-wrap:wrap; align-items:center; gap:10px; margin-top:16px; }
.supplier-warnings { padding-left:20px; color:#846020; font-size:13px; line-height:1.7; }

/* Order originals remain adjacent to the saved Chinese, including on mobile. */
.order-bilingual-local, .order-bilingual-original { display: block; white-space: pre-line; overflow-wrap: anywhere; }
.summary-item .order-bilingual-local { color: inherit; font-size: inherit; }
.order-bilingual-original { margin-top: 4px; color: var(--ink-soft); font-size: 12px; font-weight: 450; line-height: 1.6; }
.order-itinerary { margin-top: 6px; color: var(--ink-soft); font-size: 12px; }
.traveler-side small { max-width: 180px; text-align: right; overflow-wrap: anywhere; }

.supplier-email-toggle { cursor: pointer; list-style: none; }
.supplier-email-toggle::-webkit-details-marker { display: none; }
.supplier-email-toggle .section-title, .supplier-email-toggle .section-subtitle { display: block; }
.supplier-email-toggle::after { content: "展开 ＋"; flex-shrink: 0; color: var(--ink-soft); font-size: 12px; }
.supplier-email[open] > .supplier-email-toggle::after { content: "收起 −"; }
.supplier-email-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: -3px; }
.supplier-email-toolbar { display: flex; justify-content: flex-end; margin-bottom: 12px; }
