:root {
  color-scheme: light;
  --ink: #18202a;
  --muted: #667085;
  --line: #d7dde6;
  --surface: #ffffff;
  --soft: #f4f7fa;
  --brand: #0f6cbd;
  --brand-strong: #084a83;
  --accent: #168c72;
  --warning: #b35309;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--soft);
  color: var(--ink);
}

.site-header {
  align-items: center;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: 24px;
  justify-content: space-between;
  padding: 18px clamp(18px, 4vw, 48px);
}

.brand {
  color: var(--brand-strong);
  font-size: 1.35rem;
  font-weight: 800;
}

nav {
  display: flex;
  gap: 18px;
}

nav a {
  color: var(--muted);
  font-size: 0.95rem;
  text-decoration: none;
}

main {
  margin: 0 auto;
  max-width: 1120px;
  padding: 56px 20px 120px;
}

.support-hero {
  align-items: stretch;
  display: grid;
  gap: 28px;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.8fr);
}

.eyebrow {
  color: var(--accent);
  font-weight: 800;
  margin: 0 0 10px;
  text-transform: uppercase;
}

h1 {
  font-size: clamp(2.2rem, 6vw, 4.7rem);
  letter-spacing: 0;
  line-height: 1;
  margin: 0;
  max-width: 820px;
}

.intro {
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1.6;
  max-width: 660px;
}

.status-panel,
.content-band {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
}

.status-panel h2,
.content-band h2 {
  font-size: 1.1rem;
  margin: 0 0 14px;
}

.status-panel ul {
  color: var(--muted);
  line-height: 1.9;
  margin: 0;
  padding-left: 20px;
}

.content-band {
  margin-top: 36px;
}

.content-band p {
  color: var(--muted);
  line-height: 1.7;
  margin: 0;
  max-width: 780px;
}

.chat-launcher {
  background: var(--brand);
  border: 0;
  border-radius: 999px;
  bottom: 22px;
  box-shadow: 0 16px 38px rgba(15, 108, 189, 0.28);
  color: white;
  cursor: pointer;
  font-weight: 800;
  padding: 16px 20px;
  position: fixed;
  right: 22px;
}

.chat-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  bottom: 22px;
  box-shadow: 0 24px 60px rgba(16, 24, 40, 0.2);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  height: min(620px, calc(100vh - 44px));
  max-width: calc(100vw - 28px);
  position: fixed;
  right: 22px;
  width: 390px;
}

.chat-panel[hidden] {
  display: none;
}

.chat-header {
  align-items: center;
  background: var(--brand-strong);
  color: white;
  display: flex;
  grid-row: 1;
  justify-content: space-between;
  padding: 16px;
}

.chat-header h2,
.chat-header p {
  margin: 0;
}

.chat-header h2 {
  font-size: 1rem;
}

.chat-header p {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.83rem;
}

.chat-header button {
  background: transparent;
  border: 0;
  color: white;
  cursor: pointer;
  font-size: 1.2rem;
}

.chat-messages {
  display: flex;
  flex-direction: column;
  gap: 10px;
  grid-row: 2;
  min-height: 0;
  overflow-y: auto;
  padding: 16px;
}

.message {
  border-radius: 8px;
  line-height: 1.45;
  max-width: 88%;
  padding: 10px 12px;
}

.message.assistant {
  align-self: flex-start;
  background: #eef4fb;
  color: var(--ink);
}

.message.rich-message {
  background: transparent;
  max-width: 94%;
  padding: 0;
}

.message.user {
  align-self: flex-end;
  background: var(--brand);
  color: white;
}

.message.error {
  background: #fff4e6;
  color: var(--warning);
}

.package-card {
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(16, 24, 40, 0.08);
  width: 100%;
  padding: 12px;
}

.package-card-header {
  align-items: flex-start;
  display: flex;
  gap: 8px;
  justify-content: space-between;
}

.package-card h3 {
  font-size: 0.95rem;
  margin: 0 0 6px;
}

.package-card-toggle {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--brand-strong);
  cursor: pointer;
  flex: 0 0 auto;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 4px 8px;
}

.package-card-toggle:hover {
  border-color: var(--brand);
}

.package-card-compact {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.package-card.is-collapsed .package-card-details {
  display: none;
}

.package-card:not(.is-collapsed) .package-card-compact {
  display: none;
}

.package-card p {
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.45;
  margin: 0;
}

.package-list {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.package-row {
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  gap: 5px;
  padding: 10px;
}

.package-row-heading {
  font-size: 0.88rem;
  font-weight: 800;
}

.package-meta,
.package-items {
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.4;
  overflow-wrap: anywhere;
}

.package-row a {
  color: var(--brand-strong);
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: none;
}

.suggestion-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.suggestion-chips button {
  background: var(--surface);
  border: 1px solid var(--brand);
  border-radius: 999px;
  color: var(--brand-strong);
  cursor: pointer;
  font: inherit;
  font-size: 0.8rem;
  padding: 6px 11px;
}

.suggestion-chips button:hover {
  background: #eef4fb;
}

.timeline {
  display: flex;
  margin: 10px 0 12px;
}

.timeline-node {
  color: var(--muted);
  flex: 1;
  font-size: 0.72rem;
  position: relative;
  text-align: center;
}

.timeline-node::before {
  background: var(--line);
  content: "";
  height: 2px;
  left: -50%;
  position: absolute;
  top: 5px;
  width: 100%;
}

.timeline-node:first-child::before {
  display: none;
}

.timeline-dot {
  background: var(--line);
  border-radius: 50%;
  display: block;
  height: 12px;
  margin: 0 auto 5px;
  position: relative;
  width: 12px;
  z-index: 1;
}

.timeline-node.done .timeline-dot {
  background: var(--accent);
}

.timeline-node.in_transit .timeline-dot {
  background: var(--brand);
}

.timeline-node.late .timeline-dot,
.timeline-node.cancelled .timeline-dot {
  background: var(--warning);
}

.timeline-node.done .timeline-label {
  color: var(--ink);
  font-weight: 800;
}

.timeline-node.late .timeline-label,
.timeline-node.cancelled .timeline-label {
  color: var(--warning);
  font-weight: 800;
}

.timeline-date {
  margin-top: 2px;
}

.flag-card {
  border-left: 4px solid var(--accent);
}

.flag-reference {
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.flag-card p {
  margin: 4px 0 0;
}

.chat-form {
  border-top: 1px solid var(--line);
  display: flex;
  gap: 8px;
  grid-row: 3;
  padding: 12px;
}

.chat-form input {
  border: 1px solid var(--line);
  border-radius: 8px;
  flex: 1;
  font: inherit;
  min-width: 0;
  padding: 12px;
}

.chat-form button {
  background: var(--accent);
  border: 0;
  border-radius: 8px;
  color: white;
  cursor: pointer;
  font-weight: 800;
  padding: 0 16px;
}

@media (max-width: 720px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .support-hero {
    grid-template-columns: 1fr;
  }

  .chat-panel {
    bottom: 12px;
    height: calc(100vh - 24px);
    right: 14px;
    width: calc(100vw - 28px);
  }
}
