:root {
  --navy: #071c3b;
  --navy-2: #0e2b51;
  --blue: #013893;
  --blue-soft: #e9f0ff;
  --teal: #075e54;
  --teal-soft: #e6f5f2;
  --gold: #d8a42f;
  --gold-soft: #fff6dc;
  --red: #c92c43;
  --red-soft: #fff0f2;
  --purple: #7650a5;
  --purple-soft: #f2ecfa;
  --ink: #14213a;
  --muted: #627087;
  --line: #dce3ed;
  --surface: #ffffff;
  --canvas: #f3f6fa;
  --shadow: 0 14px 34px rgba(7, 28, 59, 0.09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 280px;
  background: var(--canvas);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
  letter-spacing: 0;
  overflow-x: hidden;
}
a { color: inherit; }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button, select { cursor: pointer; }
img { display: block; max-width: 100%; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { line-height: 1.15; }
code { padding: 2px 5px; background: #eef2f7; border-radius: 3px; font-size: 0.92em; }
[hidden] { display: none !important; }
.hp-field { position: fixed !important; left: -10000px !important; width: 1px !important; height: 1px !important; opacity: 0 !important; }
.eyebrow { margin: 0 0 8px; color: var(--red); font-size: 0.76rem; font-weight: 800; text-transform: uppercase; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--navy);
  text-decoration: none;
}
.brand img { object-fit: contain; }
.brand span { display: grid; }
.brand strong { font-size: 1rem; line-height: 1.1; text-transform: uppercase; }
.brand small { margin-top: 4px; color: var(--muted); font-size: 0.7rem; font-weight: 700; text-transform: uppercase; }

.primary-button,
.secondary-button,
.text-button,
.row-link,
.signout-form button {
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 15px;
  font-weight: 800;
  text-decoration: none;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}
.primary-button { background: var(--blue); color: #fff; }
.primary-button:hover, .primary-button:focus-visible { background: #002d78; }
.secondary-button { border-color: #b8c4d5; background: #fff; color: var(--navy); }
.secondary-button:hover, .secondary-button:focus-visible { border-color: var(--blue); color: var(--blue); }
.text-button { min-height: 36px; padding: 6px 9px; background: transparent; color: var(--blue); }
.text-button.danger { color: var(--red); }
.primary-button:active, .secondary-button:active { transform: translateY(1px); }

label { display: grid; gap: 7px; color: var(--navy); font-size: 0.88rem; font-weight: 750; }
label > span, legend { font-size: 0.76rem; font-weight: 850; text-transform: uppercase; }
input, select, textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid #c7d1df;
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
  outline: none;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(1, 56, 147, 0.12); }
input:disabled { background: #edf1f6; color: #6b7584; }
label small { color: var(--muted); font-size: 0.76rem; font-weight: 500; }

.alert {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px 14px;
  margin: 0 0 18px;
  border: 1px solid #b9d8cf;
  border-left: 4px solid var(--teal);
  border-radius: 5px;
  background: var(--teal-soft);
  padding: 13px 15px;
}
.alert strong { color: var(--teal); }
.alert.error { border-color: #efbac3; border-left-color: var(--red); background: var(--red-soft); }
.alert.error strong { color: var(--red); }

/* Authentication */
.auth-body { min-height: 100vh; background: var(--navy); }
.auth-header {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px clamp(18px, 5vw, 76px);
  background: #fff;
  border-top: 4px solid var(--gold);
}
.site-return { color: var(--blue); font-weight: 800; text-decoration: none; }
.auth-shell {
  width: min(1120px, calc(100% - 32px));
  min-height: calc(100vh - 126px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(420px, 1.05fr);
  align-items: center;
  gap: clamp(32px, 7vw, 96px);
  padding: 48px 0;
}
.auth-context { color: #fff; }
.auth-context .eyebrow { color: #f0c75c; }
.auth-context h1 { max-width: 590px; margin-bottom: 18px; font-size: 3.6rem; }
.auth-context > p { max-width: 600px; color: #d7e0ef; font-size: 1.05rem; }
.auth-points { margin: 34px 0; border-top: 1px solid rgba(255,255,255,.18); }
.auth-points div { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.18); }
.auth-points b { color: #f0c75c; }
.auth-points span { font-weight: 700; }
.support-line { font-size: 0.88rem !important; }
.support-line a { color: #fff; text-decoration-color: rgba(255,255,255,.45); }
.auth-card {
  max-height: calc(100vh - 122px);
  overflow-y: auto;
  border-radius: 7px;
  background: #fff;
  box-shadow: 0 26px 70px rgba(0,0,0,.28);
  padding: clamp(24px, 4vw, 42px);
}
.auth-card-head { margin-bottom: 24px; }
.auth-card-head h2 { margin-bottom: 8px; color: var(--navy); font-size: 1.8rem; }
.auth-card-head p { color: var(--muted); }
.auth-card-head a { color: var(--blue); font-weight: 800; }
.auth-form { display: grid; gap: 16px; }
.auth-form .field-grid { gap: 15px; }
.check-line { display: flex; align-items: center; gap: 9px; }
.check-line input { width: 18px; min-height: 18px; height: 18px; }
.check-line span { font-size: 0.82rem; text-transform: none; }
.form-note { margin: 0; color: var(--muted); font-size: 0.82rem; }
.auth-footer { min-height: 50px; color: #aebbd0; text-align: center; font-size: 0.78rem; }

/* App shell */
.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 26px;
  padding: 9px 24px;
  border-top: 4px solid var(--gold);
  border-bottom: 1px solid #d8e0ea;
  background: #fff;
}
.app-header .brand { min-width: 238px; }
.header-account { margin-left: auto; display: grid; text-align: right; }
.header-account span { font-weight: 850; }
.header-account small { color: var(--muted); }
.nav-toggle { display: none; border: 1px solid var(--line); background: #fff; min-height: 44px; padding: 9px 12px; }
.nav-toggle span { width: 20px; height: 2px; background: var(--navy); }
.nav-toggle b { margin-left: 6px; }
.app-layout { min-width: 0; min-height: calc(100vh - 112px); display: grid; grid-template-columns: 250px minmax(0, 1fr); }
.app-sidebar {
  position: sticky;
  top: 72px;
  align-self: start;
  height: calc(100vh - 72px);
  display: flex;
  flex-direction: column;
  background: var(--navy);
  color: #fff;
  padding: 24px 15px 18px;
  overflow-y: auto;
}
.app-sidebar nav { display: grid; gap: 5px; }
.nav-item {
  min-height: 48px;
  display: grid;
  grid-template-columns: 31px 1fr;
  align-items: center;
  gap: 9px;
  border: 1px solid transparent;
  border-radius: 5px;
  color: #cbd6e7;
  padding: 8px 10px;
  text-decoration: none;
}
.nav-item > span { width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.2); border-radius: 4px; font-size: .67rem; font-weight: 900; }
.nav-item strong { font-size: .88rem; }
.nav-item:hover, .nav-item.active { border-color: rgba(255,255,255,.12); background: #12335f; color: #fff; }
.nav-item.active > span { border-color: #f0c75c; color: #f0c75c; }
.sidebar-help { margin-top: auto; display: grid; gap: 8px; border-top: 1px solid rgba(255,255,255,.16); padding: 20px 8px 14px; }
.sidebar-help strong { font-size: .8rem; text-transform: uppercase; }
.sidebar-help a { color: #cbd6e7; font-size: .78rem; }
.signout-form button { width: 100%; border-color: rgba(255,255,255,.2); background: transparent; color: #fff; }
.signout-form button:hover { background: rgba(255,255,255,.08); }
.workspace { width: 100%; min-width: 0; max-width: 1600px; margin: 0 auto; padding: clamp(22px, 3vw, 42px); }
.workspace-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.workspace-heading h1 { margin: 0; color: var(--navy); font-size: 2.35rem; overflow-wrap: anywhere; }
.account-chip { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.account-chip > span { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; background: var(--blue); color: #fff; font-weight: 900; }
.account-chip div { display: grid; }
.account-chip strong { font-size: .84rem; }
.account-chip small { color: var(--muted); font-size: .72rem; }
.app-footer { min-height: 40px; display: flex; justify-content: space-between; gap: 20px; padding: 11px 28px 11px 278px; background: #fff; border-top: 1px solid var(--line); color: var(--muted); font-size: .75rem; }

/* Dashboard */
.dashboard-intro { display: flex; justify-content: space-between; align-items: center; gap: 22px; margin-bottom: 20px; padding: 22px 24px; border-left: 5px solid var(--gold); background: var(--navy); color: #fff; }
.dashboard-intro h2 { margin-bottom: 6px; font-size: 1.65rem; }
.dashboard-intro p { margin: 0; color: #cbd6e7; }
.dashboard-actions { display: flex; gap: 10px; flex: 0 0 auto; }
.attention-banner { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin: 0 0 20px; border: 1px solid #e6c76c; border-left: 5px solid var(--gold); background: var(--gold-soft); padding: 14px 18px; color: #6f5010; text-decoration: none; }
.attention-banner span { color: var(--blue); font-weight: 800; }
.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 26px; }
.metric-card { position: relative; min-height: 142px; border: 1px solid var(--line); border-top: 4px solid var(--purple); border-radius: 6px; background: #fff; padding: 20px; box-shadow: 0 6px 18px rgba(7,28,59,.05); }
.metric-card span, .metric-card small { display: block; color: var(--muted); }
.metric-card span { font-size: .75rem; font-weight: 850; text-transform: uppercase; }
.metric-card strong { display: block; margin: 9px 0 3px; color: var(--navy); font-size: 2.2rem; }
.metric-card small { font-size: .78rem; }
.metric-card.blue { border-top-color: var(--blue); }
.metric-card.amber { border-top-color: var(--gold); }
.metric-card.green { border-top-color: var(--teal); }
.compact-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.section-head, .panel-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.section-head { margin: 0 0 16px; }
.section-head h2, .panel-head h2 { margin: 0; color: var(--navy); font-size: 1.35rem; }
.section-head > a, .panel-head > a { color: var(--blue); font-weight: 800; text-decoration: none; }
.workflow-section { margin: 0 0 28px; }
.workflow-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.workflow-card { min-height: 108px; display: grid; grid-template-columns: 1fr auto; gap: 5px 10px; border: 1px solid var(--line); border-left: 4px solid #8390a3; background: #fff; padding: 15px; color: var(--ink); text-decoration: none; }
.workflow-card span { font-size: .82rem; font-weight: 800; }
.workflow-card strong { grid-row: span 2; color: var(--navy); font-size: 1.9rem; }
.workflow-card small { color: var(--muted); }
.workflow-card.blue { border-left-color: var(--blue); }
.workflow-card.amber { border-left-color: var(--gold); }
.workflow-card.green { border-left-color: var(--teal); }
.workflow-card.purple { border-left-color: var(--purple); }
.workflow-card.red { border-left-color: var(--red); }
.split-dashboard { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .7fr); gap: 20px; align-items: start; }
.panel { min-width: 0; border: 1px solid var(--line); border-radius: 6px; background: #fff; box-shadow: 0 8px 22px rgba(7,28,59,.05); overflow: hidden; }
.panel-head { min-height: 76px; border-bottom: 1px solid var(--line); padding: 16px 20px; }
.panel-head > span { color: var(--muted); font-size: .76rem; text-align: right; }
.compact-list > a { display: flex; justify-content: space-between; gap: 20px; padding: 15px 20px; border-bottom: 1px solid var(--line); text-decoration: none; }
.compact-list > a:last-child { border-bottom: 0; }
.compact-list > a:hover { background: #f8faff; }
.compact-list div { display: grid; gap: 4px; }
.compact-list div:last-child { justify-items: end; }
.compact-list span, .compact-list small { color: var(--muted); font-size: .77rem; }
.next-step-panel { border-top: 5px solid var(--gold); background: var(--navy); color: #fff; padding: 23px; }
.next-step-panel .eyebrow { color: #f0c75c; }
.next-step-panel h2 { font-size: 1.45rem; }
.next-step-panel ol { margin: 20px 0 0; padding: 0; list-style: none; }
.next-step-panel li { display: grid; grid-template-columns: 34px 1fr; gap: 12px; padding: 14px 0; border-top: 1px solid rgba(255,255,255,.14); }
.next-step-panel li > span { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid #f0c75c; border-radius: 50%; color: #f0c75c; font-weight: 900; }
.next-step-panel strong { display: block; }
.next-step-panel p { margin: 3px 0 0; color: #becbe0; font-size: .8rem; }
.empty-state { padding: 36px 24px; text-align: center; }
.empty-state strong { display: block; color: var(--navy); font-size: 1.15rem; }
.empty-state p { max-width: 560px; margin: 7px auto 18px; color: var(--muted); }
.empty-state.compact { padding: 24px 18px; }

/* Catalogue */
.catalog-toolbar, .list-toolbar { display: flex; align-items: end; gap: 12px; margin-bottom: 22px; border: 1px solid var(--line); background: #fff; padding: 16px; }
.catalog-toolbar > div { min-width: 170px; display: grid; gap: 6px; }
.catalog-toolbar > div:first-child { flex: 1 1 320px; }
.catalog-toolbar label, .list-toolbar label span { font-size: .72rem; }
.catalog-toolbar > p { margin: 0 0 10px auto; color: var(--muted); white-space: nowrap; }
.catalog-toolbar > p strong { color: var(--navy); }
.package-catalog { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.portal-package { display: grid; grid-template-columns: minmax(190px, .75fr) minmax(0, 1.25fr); min-height: 430px; border: 1px solid var(--line); border-radius: 6px; background: #fff; overflow: hidden; }
.package-image { position: relative; min-height: 100%; background: var(--navy); overflow: hidden; }
.package-image img { width: 100%; height: 100%; object-fit: cover; }
.package-image::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(7,28,59,.72)); }
.package-image span { position: absolute; z-index: 1; left: 14px; bottom: 14px; color: #fff; font-size: .72rem; font-weight: 850; text-transform: uppercase; }
.package-content { min-width: 0; padding: 20px; }
.package-title { display: flex; justify-content: space-between; gap: 14px; }
.package-title p { margin: 0 0 5px; color: var(--red); font-size: .7rem; font-weight: 850; text-transform: uppercase; }
.package-title h2 { margin: 0; color: var(--navy); font-size: 1.3rem; }
.package-title > strong { flex: 0 0 auto; color: var(--blue); font-size: .76rem; }
.package-content > p { margin: 15px 0; color: var(--muted); font-size: .88rem; }
.package-content dl { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 0; }
.package-content dl div { border-top: 1px solid var(--line); padding-top: 8px; }
.package-content dt { color: var(--muted); font-size: .68rem; font-weight: 800; text-transform: uppercase; }
.package-content dd { margin: 3px 0 0; font-size: .82rem; font-weight: 700; }
.tag-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.tag-list span { border: 1px solid #cfd8e5; border-radius: 4px; background: #f7f9fc; padding: 4px 7px; font-size: .7rem; font-weight: 700; }
.package-itinerary { margin-top: 14px; border-top: 1px solid var(--line); }
.package-itinerary summary { padding: 11px 0; color: var(--blue); font-size: .8rem; font-weight: 800; }
.package-itinerary ol { margin: 0 0 12px; padding-left: 22px; color: var(--muted); font-size: .78rem; }
.package-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.package-actions .primary-button, .package-actions .secondary-button { min-height: 38px; font-size: .78rem; }

/* Forms */
.field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 17px; }
.field-grid .wide { grid-column: 1 / -1; }
.builder-form { display: grid; gap: 18px; }
.builder-progress { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); background: #fff; }
.builder-progress div { min-height: 62px; display: flex; align-items: center; gap: 9px; border-right: 1px solid var(--line); padding: 10px 14px; }
.builder-progress div:last-child { border-right: 0; }
.builder-progress span, .form-section-head > span { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: #edf1f6; color: var(--navy); font-size: .78rem; font-weight: 900; }
.builder-progress .active span { background: var(--blue); color: #fff; }
.builder-progress strong { font-size: .8rem; }
.form-section { border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: 22px; }
.form-section-head { display: flex; gap: 13px; margin-bottom: 22px; }
.form-section-head > span { border-radius: 4px; background: var(--navy); color: #fff; }
.form-section-head h2 { margin: 0 0 4px; font-size: 1.25rem; }
.form-section-head p { margin: 0; color: var(--muted); font-size: .83rem; }
.service-checks { margin: 20px 0; border: 1px solid var(--line); padding: 15px; }
.service-checks legend { padding: 0 7px; color: var(--navy); }
.service-checks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.service-checks label { display: flex; align-items: center; gap: 8px; border: 1px solid #d9e0e9; background: #f8fafc; padding: 9px; font-size: .78rem; font-weight: 700; }
.service-checks input { width: 17px; min-height: 17px; height: 17px; }
.service-checks label span { font-size: .75rem; text-transform: none; }
.builder-submit { display: flex; justify-content: space-between; align-items: center; gap: 22px; border: 1px solid #b8c7da; border-left: 5px solid var(--blue); background: var(--blue-soft); padding: 21px; }
.builder-submit h2 { margin-bottom: 5px; font-size: 1.3rem; }
.builder-submit p:last-child { margin: 0; color: var(--muted); }
.builder-submit > div:last-child { display: flex; gap: 9px; flex: 0 0 auto; }
.profile-form { padding: 22px; }
.profile-form > .primary-button { margin-top: 20px; }

/* Lists and records */
.list-toolbar { justify-content: space-between; align-items: center; }
.list-toolbar form { flex: 1; display: grid; grid-template-columns: minmax(220px, 1fr) minmax(170px, .45fr) auto auto; align-items: end; gap: 10px; }
.table-wrap { width: 100%; min-width: 0; max-width: 100%; overflow-x: auto; }
.data-table { width: 100%; min-width: 860px; border-collapse: collapse; }
.data-table th { background: var(--navy); color: #fff; padding: 12px 14px; font-size: .72rem; text-align: left; text-transform: uppercase; }
.data-table td { border-bottom: 1px solid var(--line); padding: 14px; vertical-align: top; font-size: .82rem; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table td strong, .data-table td span { display: block; }
.data-table td span { margin-top: 4px; color: var(--muted); font-size: .73rem; }
.row-link { min-height: 32px; padding: 4px 8px; color: var(--blue); }
.row-link.muted { color: var(--muted); }
.status-pill { display: inline-flex !important; width: fit-content; border-radius: 999px; background: #e9edf2; color: #4f5d70 !important; padding: 5px 8px; font-size: .67rem !important; font-weight: 850; text-transform: uppercase; white-space: nowrap; }
.status-pill.blue { background: var(--blue-soft); color: var(--blue) !important; }
.status-pill.amber { background: var(--gold-soft); color: #795711 !important; }
.status-pill.green { background: var(--teal-soft); color: var(--teal) !important; }
.status-pill.purple { background: var(--purple-soft); color: var(--purple) !important; }
.status-pill.red { background: var(--red-soft); color: var(--red) !important; }
.record-banner { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-bottom: 18px; border: 1px solid var(--line); background: #fff; padding: 14px 17px; }
.record-banner > div { display: flex; align-items: center; gap: 12px; }
.record-banner p { margin: 0; color: var(--muted); font-size: .82rem; }
.record-layout { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(330px, .7fr); gap: 18px; align-items: start; }
.record-main, .record-side { min-width: 0; display: grid; gap: 18px; }
.detail-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; margin: 0; padding: 4px 20px 20px; }
.detail-grid > div { min-width: 0; border-bottom: 1px solid var(--line); padding: 14px 10px 14px 0; }
.detail-grid dt { color: var(--muted); font-size: .68rem; font-weight: 800; text-transform: uppercase; }
.detail-grid dd { margin: 5px 0 0; overflow-wrap: anywhere; font-size: .87rem; font-weight: 700; }
.detail-grid dd small { display: block; margin-top: 4px; color: var(--muted); font-size: .72rem; font-weight: 500; }
.detail-block { margin: 0 20px; border-top: 1px solid var(--line); padding: 18px 0; }
.detail-block h3 { margin-bottom: 8px; font-size: .9rem; }
.detail-block p { margin: 0; color: var(--muted); font-size: .84rem; }
.itinerary-list { margin: 0; padding: 0; list-style: none; }
.itinerary-list li { display: grid; grid-template-columns: 30px 1fr; gap: 9px; padding: 8px 0; }
.itinerary-list span { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: var(--blue-soft); color: var(--blue); font-size: .7rem; font-weight: 900; }
.itinerary-list p { align-self: center; color: var(--ink); }
.message-list { display: grid; gap: 12px; padding: 18px 20px; }
.message { max-width: 88%; border: 1px solid var(--line); border-left: 4px solid var(--blue); background: #f8faff; padding: 13px; }
.message.from-partner { margin-left: auto; border-left-color: var(--teal); background: #f3fbf9; }
.message > div { display: flex; justify-content: space-between; gap: 12px; }
.message > div span { color: var(--muted); font-size: .7rem; }
.message p { margin: 8px 0 0; font-size: .84rem; }
.message-form { display: grid; gap: 12px; border-top: 1px solid var(--line); background: #f9fbfd; padding: 18px 20px; }
.message-form .primary-button { justify-self: start; }
.document-list { display: grid; }
.document-list > a { display: grid; grid-template-columns: 48px 1fr; gap: 12px; border-bottom: 1px solid var(--line); padding: 13px 20px; text-decoration: none; }
.document-list > a:hover { background: #f8faff; }
.file-mark { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 5px; background: var(--blue-soft); color: var(--blue); font-size: .65rem; font-weight: 900; }
.document-list div { min-width: 0; display: grid; gap: 2px; }
.document-list div span, .document-list div small { color: var(--muted); font-size: .72rem; overflow-wrap: anywhere; }
.upload-form { display: grid; grid-template-columns: .6fr 1fr auto; gap: 10px; align-items: end; background: #f9fbfd; padding: 16px 20px; }
.file-picker input { min-height: 42px; padding: 7px; }
.file-picker b { color: var(--muted); font-size: .7rem; font-weight: 500; }
.quote-panel, .admin-panel, .timeline-panel, .profile-summary { border: 1px solid var(--line); border-top: 5px solid var(--gold); background: #fff; padding: 20px; }
.quote-total { display: grid; grid-template-columns: auto 1fr; align-items: end; gap: 0 9px; margin: 20px 0 4px; }
.quote-total span { color: var(--blue); font-size: 1rem; font-weight: 900; }
.quote-total strong { color: var(--navy); font-size: 2.2rem; line-height: 1; overflow-wrap: anywhere; }
.quote-total small { grid-column: 2; color: var(--muted); }
.quote-valid { border-bottom: 1px solid var(--line); padding-bottom: 14px; color: var(--red); font-size: .76rem; font-weight: 800; }
.quote-copy h3 { margin: 15px 0 5px; font-size: .82rem; }
.quote-copy p { margin: 0; color: var(--muted); font-size: .8rem; }
.quote-empty { margin-top: 17px; background: var(--gold-soft); padding: 16px; }
.quote-empty p { margin: 6px 0 0; color: #725c26; font-size: .82rem; }
.quote-response, .admin-panel form { display: grid; gap: 12px; margin-top: 18px; }
.quote-response > div { display: flex; flex-wrap: wrap; gap: 7px; }
.admin-panel { border-top-color: var(--blue); }
.admin-panel h2, .timeline-panel h2 { font-size: 1.15rem; }
.admin-panel hr { margin: 24px 0; border: 0; border-top: 1px solid var(--line); }
.quote-fields { display: grid; grid-template-columns: .55fr 1fr; gap: 9px; }
.timeline-panel { border-top-color: var(--purple); }
.timeline-panel ol { margin: 16px 0 0; padding: 0; list-style: none; }
.timeline-panel li { display: grid; grid-template-columns: 14px 1fr; gap: 8px; border-left: 1px solid #ccd5e1; margin-left: 6px; padding: 0 0 18px 13px; }
.timeline-panel li > span { width: 11px; height: 11px; margin-left: -19px; border: 2px solid #fff; border-radius: 50%; background: var(--purple); box-shadow: 0 0 0 1px var(--purple); }
.timeline-panel li strong { font-size: .78rem; }
.timeline-panel li p { margin: 3px 0; color: var(--muted); font-size: .75rem; }
.timeline-panel li small { color: #7a8494; font-size: .68rem; }

/* Partner administration and profile */
.partner-directory { display: grid; }
.partner-directory > article { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; align-items: center; border-bottom: 1px solid var(--line); padding: 18px 20px; }
.partner-directory > article:last-child { border-bottom: 0; }
.partner-avatar, .profile-summary > span { width: 50px; height: 50px; display: grid; place-items: center; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 900; }
.partner-details { min-width: 0; display: grid; grid-template-columns: minmax(200px, .8fr) minmax(0, 1.2fr); align-items: center; gap: 18px; }
.partner-details h2 { margin: 7px 0 3px; font-size: 1rem; }
.partner-details p { margin: 0; color: var(--muted); font-size: .76rem; }
.partner-details dl { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0; }
.partner-details dt { color: var(--muted); font-size: .65rem; font-weight: 850; text-transform: uppercase; }
.partner-details dd { margin: 3px 0 0; font-size: .74rem; overflow-wrap: anywhere; }
.profile-layout { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(280px, .65fr); gap: 18px; align-items: start; }
.profile-summary { border-top-color: var(--teal); }
.profile-summary > span { margin-bottom: 16px; background: var(--teal); }
.profile-summary h2 { margin-bottom: 5px; font-size: 1.3rem; overflow-wrap: anywhere; }
.profile-summary > p { color: var(--muted); }
.profile-summary dl { margin: 20px 0; }
.profile-summary dl div { display: flex; justify-content: space-between; gap: 15px; border-top: 1px solid var(--line); padding: 10px 0; }
.profile-summary dt { color: var(--muted); font-size: .74rem; }
.profile-summary dd { margin: 0; text-align: right; font-size: .76rem; font-weight: 800; }
.profile-summary > p:last-child { margin: 0; font-size: .78rem; }

/* Direct package bookings */
.booking-package-summary {
  display: grid;
  grid-template-columns: minmax(260px, .75fr) minmax(0, 1.25fr);
  min-height: 250px;
  border: 1px solid var(--line);
  border-left: 5px solid var(--teal);
  background: #fff;
  overflow: hidden;
}
.booking-package-summary > img { width: 100%; height: 100%; min-height: 250px; object-fit: cover; }
.booking-package-summary > div { align-self: center; padding: 24px; }
.booking-package-summary h2 { margin-bottom: 9px; color: var(--navy); font-size: 1.55rem; }
.booking-package-summary > div > p:not(.eyebrow) { margin-bottom: 18px; color: var(--muted); }
.booking-package-summary dl { display: grid; grid-template-columns: .55fr 1.45fr; gap: 12px; margin: 0; }
.booking-package-summary dl div { border-top: 1px solid var(--line); padding-top: 9px; }
.booking-package-summary dt { color: var(--muted); font-size: .68rem; font-weight: 850; text-transform: uppercase; }
.booking-package-summary dd { margin: 3px 0 0; font-size: .82rem; font-weight: 750; }
.booking-submit-actions { min-width: min(100%, 470px); display: grid !important; gap: 11px; }
.booking-submit-actions .check-line { grid-template-columns: 20px 1fr; color: var(--navy); }
.booking-submit-actions .check-line span { color: var(--muted); font-size: .76rem; }
.booking-submit-actions .primary-button { width: 100%; background: var(--teal); }
.booking-submit-actions .primary-button:hover, .booking-submit-actions .primary-button:focus-visible { background: #054a43; }
.booking-attention { border-color: #9fcfc5; border-left-color: var(--teal); background: var(--teal-soft); color: var(--teal); }

@media (max-width: 1240px) {
  .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .workflow-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .package-catalog { grid-template-columns: 1fr; }
  .partner-details { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .auth-shell { grid-template-columns: 1fr; align-items: start; padding: 36px 0; }
  .auth-context h1 { font-size: 2.6rem; }
  .auth-context .auth-points { display: none; }
  .auth-card { max-height: none; }
  .nav-toggle { margin-left: auto; display: grid; grid-template-columns: 20px auto; grid-template-rows: repeat(3, 5px); align-items: center; column-gap: 6px; }
  .nav-toggle b { grid-column: 2; grid-row: 1 / 4; }
  .app-header .brand { min-width: 0; }
  .header-account { display: none; }
  .app-layout { grid-template-columns: 1fr; }
  .app-sidebar { position: fixed; z-index: 45; top: 72px; left: 0; width: min(310px, 88vw); height: calc(100vh - 72px); transform: translateX(-105%); transition: transform 180ms ease; box-shadow: 18px 0 42px rgba(7,28,59,.25); }
  .partner-nav-open .app-sidebar { transform: translateX(0); }
  .app-footer { padding-left: 28px; }
  .split-dashboard, .record-layout, .profile-layout { grid-template-columns: 1fr; }
  .record-side { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .record-side .quote-panel { grid-column: 1 / -1; }
  .service-checks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .partner-directory > article { grid-template-columns: 52px minmax(0, 1fr); }
  .partner-directory > article form { grid-column: 2; }
}

@media (max-width: 680px) {
  .auth-header, .app-header { padding-left: 14px; padding-right: 14px; }
  .auth-header .brand small { max-width: 180px; }
  .auth-shell { width: min(100% - 20px, 560px); gap: 24px; }
  .auth-context h1 { font-size: 2.1rem; }
  .auth-context > p { font-size: .95rem; }
  .auth-card { padding: 21px 16px; }
  .workspace { padding: 20px 12px 30px; }
  .workspace-heading { align-items: flex-start; }
  .account-chip { display: none; }
  .workspace-heading h1 { font-size: 1.7rem; }
  .dashboard-intro, .builder-submit, .record-banner { align-items: stretch; flex-direction: column; }
  .dashboard-actions, .builder-submit > div:last-child, .record-banner > div { width: 100%; flex-wrap: wrap; }
  .dashboard-actions > *, .builder-submit > div:last-child > *, .record-banner > div > * { flex: 1 1 150px; }
  .metric-grid, .compact-metrics, .workflow-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
  .metric-card { min-height: 124px; padding: 15px; }
  .metric-card strong { font-size: 1.85rem; }
  .workflow-card { min-height: 95px; padding: 12px; }
  .section-head, .panel-head { align-items: flex-start; }
  .panel-head > span { max-width: 145px; }
  .compact-list > a { padding: 13px; }
  .catalog-toolbar { align-items: stretch; flex-direction: column; }
  .catalog-toolbar > div { width: 100%; min-width: 0; }
  .catalog-toolbar > p { margin: 0; }
  .portal-package { grid-template-columns: 1fr; }
  .package-image { min-height: 230px; max-height: 230px; }
  .package-content { padding: 17px; }
  .package-title { flex-direction: column; }
  .package-content dl, .field-grid, .detail-grid, .record-side, .quote-fields { grid-template-columns: 1fr; }
  .field-grid .wide { grid-column: auto; }
  .builder-progress { grid-template-columns: repeat(4, minmax(70px, 1fr)); overflow-x: auto; }
  .builder-progress div { min-width: 98px; align-items: flex-start; flex-direction: column; }
  .service-checks { grid-template-columns: 1fr; }
  .form-section { padding: 17px 14px; }
  .list-toolbar { align-items: stretch; flex-direction: column; }
  .list-toolbar form { grid-template-columns: 1fr; }
  .list-toolbar > .primary-button { width: 100%; }
  .booking-table { min-width: 0; }
  .booking-table thead { display: none; }
  .booking-table tbody { display: grid; }
  .booking-table tr { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 14px; border-bottom: 1px solid var(--line); padding: 15px 14px; }
  .booking-table tr:last-child { border-bottom: 0; }
  .booking-table td { min-width: 0; border: 0; padding: 0; overflow-wrap: anywhere; }
  .booking-table td::before { content: attr(data-label); display: block; margin-bottom: 4px; color: var(--muted); font-size: .64rem; font-weight: 850; text-transform: uppercase; }
  .booking-table td[data-label="Booking"], .booking-table td[data-label="Travel"], .booking-table td[data-label="Action"] { grid-column: 1 / -1; }
  .booking-table .row-link { width: 100%; border-color: #b8c4d5; background: #fff; }
  .record-banner > div { display: flex; }
  .detail-grid { padding: 4px 14px 16px; }
  .detail-block { margin: 0 14px; }
  .message { max-width: 96%; }
  .message > div { flex-direction: column; gap: 2px; }
  .upload-form { grid-template-columns: 1fr; }
  .upload-form .secondary-button { width: 100%; }
  .partner-directory > article { grid-template-columns: 44px minmax(0, 1fr); padding: 15px 12px; }
  .partner-avatar { width: 42px; height: 42px; }
  .partner-details dl { grid-template-columns: 1fr 1fr; }
  .partner-directory > article form { grid-column: 1 / -1; }
  .partner-directory > article form button { width: 100%; }
  .booking-package-summary { grid-template-columns: 1fr; }
  .booking-package-summary > img { min-height: 210px; max-height: 210px; }
  .booking-package-summary > div { padding: 18px 15px; }
  .booking-package-summary dl { grid-template-columns: 1fr; }
  .booking-submit-actions { min-width: 0; }
  .booking-submit-actions .check-line { flex: none !important; }
  .app-footer { align-items: center; flex-direction: column; gap: 2px; padding: 10px 14px; text-align: center; }
}

@media (max-width: 410px) {
  .brand { gap: 8px; }
  .brand img { width: 44px; height: 44px; }
  .brand strong { font-size: .82rem; }
  .brand small { font-size: .58rem; }
  .site-return { font-size: .78rem; }
  .metric-grid, .compact-metrics, .workflow-grid { grid-template-columns: 1fr; }
  .package-content dl { grid-template-columns: 1fr; }
  .record-banner > div > * { flex-basis: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
