:root {
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --primary-light: #eef2ff;
  --azure: #0284c7;
  --azure-light: #e0f2fe;
  --emerald: #10b981;
  --emerald-light: #d1fae5;
  --amber: #f59e0b;
  --amber-light: #fef3c7;
  --bg-page: #f8fafc;
  --bg-card: #ffffff;
  --border: #e2e8f0;
  --border-subtle: #f1f5f9;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px -2px rgba(0, 0, 0, 0.06);
  --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.03);
  --shadow-float: 0 20px 35px -8px rgba(79, 70, 229, 0.15);
  --font-sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-mono: "JetBrains Mono", monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* =====================================================================
   App Header (Airbnb / Linear Style)
   ===================================================================== */
.app-header {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0.85rem 2.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  cursor: pointer;
}

.logo-spark {
  color: var(--primary);
  font-size: 1.4rem;
  font-weight: 800;
}

.logo-name {
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text-main);
}

.logo-sub {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-light);
  padding: 0.15rem 0.5rem;
  border-radius: 9999px;
  margin-left: 0.2rem;
}

.network-badge {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: #f1f5f9;
  border: 1px solid var(--border);
  padding: 0.3rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Destination Pill Tabs */
.destination-tabs {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: #f1f5f9;
  padding: 0.3rem;
  border-radius: 9999px;
  border: 1px solid var(--border);
}

.dest-tab {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: transparent;
  border: none;
  padding: 0.45rem 1rem;
  border-radius: 9999px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.dest-tab:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.6);
}

.dest-tab.active {
  background: #ffffff;
  color: var(--text-main);
  box-shadow: var(--shadow-sm);
}

.dest-tab.custom-tab {
  color: var(--primary);
}

.dest-tab.custom-tab:hover {
  background: var(--primary-light);
}

.tab-emoji {
  font-size: 1rem;
}

.btn-primary-action {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, #4f46e5, #4338ca);
  color: #ffffff;
  border: none;
  padding: 0.65rem 1.35rem;
  border-radius: 9999px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(79, 70, 229, 0.3);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-primary-action:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(79, 70, 229, 0.4);
}

/* =====================================================================
   Search / Capsule Bar (Airbnb Style)
   ===================================================================== */
.search-capsule-wrapper {
  max-width: 1280px;
  margin: 1.5rem auto 0 auto;
  padding: 0 2rem;
}

.search-capsule {
  background: #ffffff;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  border-radius: 9999px;
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem 0.5rem 1.75rem;
  transition: box-shadow 0.2s;
}

.search-capsule:hover {
  box-shadow: var(--shadow-card);
}

.capsule-segment {
  display: flex;
  flex-direction: column;
  padding: 0.2rem 1.25rem;
  flex: 1;
}

.segment-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-light);
}

.segment-val {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.capsule-divider {
  width: 1px;
  height: 32px;
  background: var(--border);
}

.capsule-cta {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: #f1f5f9;
  color: var(--text-main);
  border: 1px solid var(--border);
  padding: 0.65rem 1.25rem;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
}

.capsule-cta:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: #c7d2fe;
}

/* =====================================================================
   Main Consumer Viewport (2-Column Grid)
   ===================================================================== */
.consumer-viewport {
  max-width: 1280px;
  margin: 1.75rem auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 2rem;
  align-items: start;
}

/* Left Column: Itinerary Feed */
.itinerary-feed {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.feed-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.feed-title-group h1 {
  font-size: 1.85rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

.feed-sub {
  font-size: 0.95rem;
  color: var(--text-muted);
}

.badge-saved {
  background: var(--emerald-light);
  color: #065f46;
  border: 1px solid #a7f3d0;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.3rem 0.75rem;
  border-radius: 9999px;
  white-space: nowrap;
}

/* Stepper */
.workflow-stepper {
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.25rem;
  box-shadow: var(--shadow-sm);
}

.step-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.step-num {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 800;
}

.step-item.active .step-num {
  background: var(--primary);
  color: #ffffff;
}

.step-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
}

.step-line {
  flex: 1;
  height: 2px;
  background: var(--border);
  margin: 0 0.85rem;
}

/* =====================================================================
   Provider Cards (Hotel, Ride, Experience)
   ===================================================================== */
.provider-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s, box-shadow 0.2s;
}

.provider-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -6px rgba(0, 0, 0, 0.08);
}

.card-media {
  height: 140px;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1rem 1.25rem;
}

.hotel-media {
  background: linear-gradient(135deg, #1e3a8a, #0284c7, #38bdf8);
}

.transfer-media {
  background: linear-gradient(135deg, #090d16, #0f172a, #06b6d4);
}

.experience-media {
  background: linear-gradient(135deg, #78350f, #d97706, #fbbf24);
}

.media-badge {
  align-self: flex-start;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.3rem 0.7rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.media-overlay {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 700;
}

.card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.card-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.card-title-row h3 {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.card-address {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.card-price-pill {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

.price-amount {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1;
}

.price-period {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.price-direct {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--emerald);
  background: var(--emerald-light);
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  margin-top: 0.25rem;
}

.sub-section-title {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-light);
}

/* Room Selection Grid */
.rooms-selection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.85rem;
}

.room-option-card {
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
  background: #ffffff;
}

.room-option-card:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.room-option-card.selected {
  border-color: var(--primary);
  background: #f5f3ff;
  box-shadow: 0 0 0 1px var(--primary);
}

.room-tier-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
}

.room-view-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

.room-rate-tag {
  font-size: 0.92rem;
  font-weight: 800;
  color: var(--primary);
  margin-top: 0.4rem;
}

/* Perks Row */
.perks-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.perk-chip {
  background: #f8fafc;
  border: 1px solid var(--border);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 0.3rem 0.65rem;
  border-radius: 9999px;
}

/* Card Actions Bar */
.card-actions-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-subtle);
}

.btn-card-action {
  background: #f1f5f9;
  color: var(--text-main);
  border: 1px solid var(--border);
  font-size: 0.88rem;
  font-weight: 700;
  padding: 0.55rem 1.15rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s;
}

.btn-card-action:hover {
  background: var(--text-main);
  color: #ffffff;
}

.status-pill {
  font-size: 0.82rem;
  font-weight: 700;
  padding: 0.3rem 0.75rem;
  border-radius: 9999px;
}

.status-ready {
  background: #f1f5f9;
  color: var(--text-muted);
}

.status-confirmed {
  background: var(--emerald-light);
  color: #065f46;
  border: 1px solid #a7f3d0;
}

/* Flight Telemetry Callout */
.telemetry-callout {
  display: flex;
  gap: 0.85rem;
  background: #f0f9ff;
  border: 1px solid #bae6fd;
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
}

.telemetry-icon {
  font-size: 1.4rem;
  color: #0284c7;
}

.telemetry-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #0369a1;
}

.telemetry-desc {
  font-size: 0.82rem;
  color: #0c4a6e;
  margin-top: 0.15rem;
}

.vehicle-specs-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  background: #f8fafc;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.spec-col {
  display: flex;
  flex-direction: column;
}

.spec-label {
  font-size: 0.75rem;
  color: var(--text-light);
  font-weight: 600;
}

.spec-val {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  margin-top: 0.15rem;
}

.experience-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* =====================================================================
   Right Column: Digital Master Pass & AI Chat
   ===================================================================== */
.sidebar-checkout {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
  position: sticky;
  top: 90px;
}

/* Apple Wallet / Boarding Pass Style Card */
.checkout-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

.checkout-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  background: linear-gradient(90deg, #4f46e5, #06b6d4, #10b981);
}

.pass-header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
}

.pass-brand {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: 0.05em;
}

.pass-spark {
  font-size: 1rem;
}

.pass-code-pill {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-muted);
  background: #f1f5f9;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
}

.pass-destination-block {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px dashed var(--border);
}

.pass-dest-city {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.pass-dest-dates {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.pass-receipt-items {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.receipt-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

.receipt-name {
  color: var(--text-muted);
}

.receipt-price {
  font-weight: 700;
  color: var(--text-main);
}

.receipt-divider {
  height: 1px;
  background: var(--border);
  margin: 0.5rem 0;
}

.total-row .total-label {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
}

.total-row .total-amount {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary);
}

.savings-row .savings-label {
  font-size: 0.82rem;
  color: var(--text-light);
}

.ota-strike {
  font-size: 0.85rem;
  text-decoration: line-through;
  color: var(--text-light);
}

.savings-highlight-box {
  background: var(--emerald-light);
  border: 1px solid #a7f3d0;
  border-radius: var(--radius-sm);
  padding: 0.65rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  color: #065f46;
  margin-top: 0.65rem;
}

.pass-actions {
  margin-top: 1.25rem;
}

.btn-download-pass {
  width: 100%;
  background: #0f172a;
  color: #ffffff;
  border: none;
  padding: 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-download-pass:hover {
  background: var(--primary);
}

/* =====================================================================
   In-Browser AI Concierge Chat Widget
   ===================================================================== */
.concierge-chat-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 0.85rem;
}

.chat-agent-info {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.agent-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
}

.agent-name {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-main);
}

.agent-status-line {
  font-size: 0.75rem;
  color: var(--emerald);
  font-weight: 600;
}

.btn-reset {
  background: #f1f5f9;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  cursor: pointer;
}

.btn-reset:hover {
  background: #e2e8f0;
}

.agent-chat-runtime {
  min-height: 220px;
  max-height: 280px;
  overflow-y: auto;
}

.chat-chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--border-subtle);
}

.prompt-chip {
  background: #f8fafc;
  border: 1px solid var(--border);
  color: var(--text-main);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35rem 0.65rem;
  border-radius: 9999px;
  cursor: pointer;
  transition: all 0.15s;
}

.prompt-chip:hover {
  background: var(--primary-light);
  color: var(--primary);
  border-color: #c7d2fe;
}

/* =====================================================================
   Custom Trip Modal
   ===================================================================== */
.custom-modal {
  border: none;
  border-radius: var(--radius-lg);
  padding: 0;
  max-width: 580px;
  width: 90%;
  margin: auto;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.custom-modal::backdrop {
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
}

.modal-card {
  background: #ffffff;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  font-size: 1.3rem;
  font-weight: 800;
}

.close-btn {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-muted);
}

.form-group input {
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-family: inherit;
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.btn-secondary {
  background: #f1f5f9;
  border: 1px solid var(--border);
  color: var(--text-main);
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
}

.btn-primary {
  background: var(--primary);
  color: #ffffff;
  border: none;
  padding: 0.65rem 1.25rem;
  border-radius: var(--radius-sm);
  font-weight: 700;
  cursor: pointer;
}

/* =====================================================================
   Federated Agent Swarm Bar
   ===================================================================== */
.swarm-bar-wrapper {
  max-width: 1320px;
  margin: 0.75rem auto 1rem auto;
  padding: 0 1.5rem;
}

.swarm-bar {
  background: #ffffff;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.25rem;
  box-shadow: 0 2px 6px -1px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.swarm-bar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.swarm-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.92rem;
  color: var(--text-main);
}

.swarm-icon {
  font-size: 1.15rem;
}

.swarm-count-pill {
  font-size: 0.75rem;
  font-weight: 700;
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  letter-spacing: 0.02em;
}

.swarm-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-swarm-add {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #4f46e5;
  color: #ffffff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-swarm-add:hover {
  background: #4338ca;
  transform: translateY(-1px);
}

.btn-swarm-discover {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-sm);
  padding: 0.45rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-swarm-discover:hover {
  background: #e2e8f0;
  color: #0f172a;
  border-color: #94a3b8;
  transform: translateY(-1px);
}

.swarm-chips-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
}

.swarm-node-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 0.4rem 0.7rem;
  transition: all 0.2s ease;
}

.swarm-node-chip:hover {
  border-color: #94a3b8;
  background: #ffffff;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.chip-icon {
  font-size: 1.15rem;
  line-height: 1;
}

.chip-info {
  display: flex;
  flex-direction: column;
}

.chip-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.chip-role {
  font-size: 0.7rem;
  color: var(--text-muted);
}

.chip-status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
}

.chip-unlink-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  font-size: 1rem;
  cursor: pointer;
  padding: 0 0.15rem;
  line-height: 1;
  border-radius: 4px;
}

.chip-unlink-btn:hover {
  color: #ef4444;
  background: #fee2e2;
}

/* =====================================================================
   Agent Discovery & Catalog Modal
   ===================================================================== */
.wide-modal {
  max-width: 860px;
}

.modal-search-row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1rem;
}

.modal-search-row input {
  flex: 1;
  padding: 0.65rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-family: inherit;
}

.modal-search-row select {
  padding: 0.65rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  background: #ffffff;
  cursor: pointer;
}

.discover-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  max-height: 460px;
  overflow-y: auto;
  padding-right: 0.35rem;
}

.discover-agent-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1rem;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.75rem;
  transition: all 0.2s ease;
}

.discover-agent-card:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.discover-card-top {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.discover-card-avatar {
  font-size: 1.8rem;
  background: #f8fafc;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
}

.discover-card-meta {
  display: flex;
  flex-direction: column;
}

.discover-agent-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.2;
}

.discover-agent-cat {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.discover-agent-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 0;
}

.discover-tools-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.tool-tag {
  font-size: 0.68rem;
  font-family: monospace;
  background: #f1f5f9;
  color: #475569;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  border: 1px solid #e2e8f0;
}

.btn-mount-agent {
  width: 100%;
  padding: 0.5rem;
  background: #4f46e5;
  color: #ffffff;
  border: none;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-mount-agent:hover {
  background: #4338ca;
}

.linked-indicator {
  display: block;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: #16a34a;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 6px;
  padding: 0.45rem;
}

/* Protocol & BYOK Telemetry Pill */
.telemetry-pill {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0.5rem 0.75rem;
  padding: 0.4rem 0.65rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  font-size: 0.72rem;
  color: #475569;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.telemetry-dot {
  color: #16a34a;
  font-size: 0.8rem;
  animation: telemetryPulse 2s infinite ease-in-out;
}

@keyframes telemetryPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.9); }
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .consumer-viewport {
    grid-template-columns: 1fr;
  }
  .sidebar-checkout {
    position: static;
  }
}
