:root{
  /* Neutral base — soft atmospheric navy, deliberately not pure black */
  --bg: #0b1220;
  --bg-alt: #101a2c;
  --panel: #131f34;
  --panel-border: #253552;
  --text: #f1f4fa;
  --text-dim: #97a4bd;

  /* Mission colors — Astronautics (blue) is the default; Aviation (amber)
     overrides these on aviation pages via [data-section="aviation"] below. */
  --accent: #4c8fe0;
  --accent-strong: #72abed;
  --accent-soft: rgba(76,143,224,0.14);
  --accent-ink: #05101f;

  /* Warm highlight — used sparingly for live indicators, moon/satellite
     accents; a shared "starlight" tone that isn't tied to either section. */
  --warm: #f2c675;
  --warm-soft: rgba(242,198,117,0.16);

  /* Fixed semantic colors — same in both sections */
  --danger: #e2534a;
  --success: #3fb872;
  --warn: #e2a33d;

  --radius: 10px;
  --radius-lg: 14px;
  --ease: cubic-bezier(.2,.7,.3,1);
  font-size: 16px;
}

/* Aviation section re-themes the accent to a warm amber, distinguishing it
   from Astronautics' blue at a glance — same structure, different mission color. */
[data-section="aviation"]{
  --accent: #d98a2b;
  --accent-strong: #eba24a;
  --accent-soft: rgba(217,138,43,0.14);
  --accent-ink: #1a0f02;
}

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

body{
  background: radial-gradient(ellipse at 18% -12%, #101d38 0%, var(--bg) 48%) fixed,
              var(--bg);
  color: var(--text);
  font-family: "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

h1, h2, h3, .brand, button, .btn{
  font-family: "Space Grotesk", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, Helvetica, Arial, sans-serif;
}

/* Starfield background — subtle, not busy */
#starfield{
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.8;
}

.sr-only{
  position:absolute; width:1px; height:1px;
  padding:0; margin:-1px; overflow:hidden;
  clip:rect(0,0,0,0); white-space:nowrap; border:0;
}

.skip-link{
  position: absolute;
  top: -48px;
  left: 12px;
  z-index: 200;
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 700;
  padding: 10px 18px;
  border-radius: var(--radius);
  transition: top .15s ease;
}
.skip-link:focus{ top: 12px; text-decoration:none; }

.scroll-progress{
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--accent-strong));
  z-index: 100;
  box-shadow: 0 0 8px var(--accent-soft);
  pointer-events: none;
}

a{ color: var(--accent-strong); text-decoration: none; }
a:hover{ text-decoration: underline; }

::selection{ background: var(--accent-soft); color: var(--text); }

/* ---------- Icons ---------- */
.icon{
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.16em;
  flex-shrink: 0;
}
.icon-lg{ width: 1.3em; height: 1.3em; }
.icon-spin{ animation: icon-spin 0.7s linear; }
@keyframes icon-spin{ to{ transform: rotate(360deg); } }

/* ---------- Live indicator ---------- */
.live-indicator{
  display:inline-flex;
  align-items:center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--success);
}
.live-dot{
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 0 rgba(63,184,114,0.5);
  animation: live-pulse 1.8s ease-out infinite;
}
.live-indicator.warm{ color: var(--warm); }
.live-indicator.warm .live-dot{ background: var(--warm); box-shadow: 0 0 0 0 rgba(242,198,117,0.5); animation-name: live-pulse-warm; }
@keyframes live-pulse{
  0%{ box-shadow: 0 0 0 0 rgba(63,184,114,0.45); }
  70%{ box-shadow: 0 0 0 7px rgba(63,184,114,0); }
  100%{ box-shadow: 0 0 0 0 rgba(63,184,114,0); }
}
@keyframes live-pulse-warm{
  0%{ box-shadow: 0 0 0 0 rgba(242,198,117,0.45); }
  70%{ box-shadow: 0 0 0 7px rgba(242,198,117,0); }
  100%{ box-shadow: 0 0 0 0 rgba(242,198,117,0); }
}

/* ---------- Moon phase disc (replaces emoji moon glyphs) ---------- */
.moon-phase-disc{
  position: relative;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: #0e1830;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: inset 0 0 0 1px var(--panel-border), 0 0 16px var(--warm-soft);
}
.moon-phase-disc::after{
  content:"";
  position:absolute;
  top:0; left:0;
  width:100%; height:100%;
  border-radius:50%;
  background: radial-gradient(circle at 34% 30%, #fff, var(--warm) 72%);
  transform: translateX(var(--moon-offset, 0px));
  transition: transform .6s var(--ease);
}

/* ---------- Header / navigation ---------- */
.site-header{
  border-bottom: 2px solid var(--accent);
  background: rgba(7, 11, 22, 0.82);
  backdrop-filter: blur(10px);
  position: sticky;
  top:0;
  z-index: 50;
  transition: border-color .2s ease;
}

.header-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 16px;
  padding: 14px 28px 10px;
  flex-wrap: wrap;
}

.brand{
  display:flex;
  align-items:center;
  gap:10px;
  font-weight:700;
  font-size:1.2rem;
  letter-spacing: 0.01em;
  color: var(--text);
}
.brand:hover{ text-decoration:none; }
.brand .mark{
  width:30px; height:30px;
  display:flex; align-items:center; justify-content:center;
  border-radius: 7px;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  font-size: 1rem;
  flex-shrink:0;
}

/* Section switcher — the top-level Astronautics / Aviation toggle */
.section-tabs{
  display:flex;
  gap: 4px;
  background: var(--bg-alt);
  border: 1px solid var(--panel-border);
  border-radius: 999px;
  padding: 4px;
}
.section-tab{
  display:flex;
  align-items:center;
  gap: 7px;
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text-dim);
  white-space: nowrap;
}
.section-tab:hover{ color: var(--text); text-decoration:none; }
.section-tab:focus-visible{ outline: 2px solid var(--accent-strong); outline-offset: 2px; }
.section-tab .tab-icon{ font-size: 0.95rem; }
.section-tab.active.astro-tab{
  background: #4c8fe0;
  color: #05101f;
}
.section-tab.active.aviation-tab{
  background: #d98a2b;
  color: #1a0f02;
}

.sub-nav{
  display:flex;
  gap: 4px;
  flex-wrap: wrap;
  padding: 0 28px 12px;
}
.sub-nav a{
  color: var(--text-dim);
  padding: 6px 13px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 600;
  transition: all .15s ease;
}
.sub-nav a:hover{
  color: var(--text);
  background: var(--panel);
  text-decoration:none;
}
.sub-nav a:focus-visible{ outline: 2px solid var(--accent-strong); outline-offset: 2px; }
.sub-nav a.active{
  color: var(--accent-strong);
  background: var(--accent-soft);
}

main{
  max-width: 1180px;
  margin: 0 auto;
  padding: 32px 24px 80px;
}

.eyebrow{
  display:flex;
  align-items:center;
  gap: 9px;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  margin-bottom: 10px;
}
.eyebrow::before{
  content:"";
  width: 22px; height: 2px;
  background: var(--accent);
  display:inline-block;
}

.page-title{
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  font-weight: 700;
  margin: 0 0 8px;
  color: var(--text);
  letter-spacing: -0.01em;
}
.page-sub{
  color: var(--text-dim);
  margin: 0 0 28px;
  max-width: 70ch;
  font-size: 0.98rem;
}

/* ---------- Cards / panels ---------- */
.panel{
  background: linear-gradient(180deg, var(--panel), rgba(16,26,46,0.6));
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.grid{
  display:grid;
  gap: 18px;
}
.grid.cols-3{ grid-template-columns: repeat(3, 1fr); }
.grid.cols-2{ grid-template-columns: repeat(2, 1fr); }
@media (max-width: 900px){
  .grid.cols-3{ grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px){
  .grid.cols-3, .grid.cols-2{ grid-template-columns: 1fr; }
}

.card{
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-top: 2px solid transparent;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display:flex;
  flex-direction: column;
  transition: transform .2s var(--ease), border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.card:hover{
  transform: translateY(-3px);
  border-color: var(--panel-border);
  border-top-color: var(--accent);
  box-shadow: 0 12px 28px -14px rgba(0,0,0,.55);
}
.card img{ transition: transform .4s var(--ease); }
.card:hover img{ transform: scale(1.035); }
.card img{
  width:100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  background: #131d33;
  display:block;
}
.card .card-body{
  padding: 14px 16px 18px;
  display:flex;
  flex-direction: column;
  gap: 8px;
  flex:1;
}
.card h3{
  font-size: 1.01rem;
  font-weight: 600;
  margin: 0;
  line-height: 1.4;
  font-family: inherit;
}
.card p{
  color: var(--text-dim);
  font-size: 0.88rem;
  margin: 0;
  flex:1;
}
.card .meta{
  font-size: 0.76rem;
  color: var(--text-dim);
  display:flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
}
.badge{
  display:inline-flex;
  align-items:center;
  gap: 4px;
  font-size: 0.68rem;
  font-weight:700;
  text-transform: uppercase;
  letter-spacing: .05em;
  padding: 3px 9px;
  border-radius: 5px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  border: 1px solid rgba(255,255,255,0.06);
}
.badge.warn{ background: rgba(226,163,61,.14); color:#e2a33d; }
.badge.danger{ background: rgba(226,84,74,.14); color:var(--danger); }
.badge.success{ background: rgba(63,184,114,.14); color:var(--success); }

/* ---------- Controls ---------- */
.controls-row{
  display:flex;
  flex-wrap:wrap;
  gap: 10px;
  align-items:center;
  margin-bottom: 20px;
}
input[type="text"], input[type="search"], input[type="number"], input[type="datetime-local"], select{
  background: var(--bg-alt);
  border: 1px solid var(--panel-border);
  color: var(--text);
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-family: inherit;
}
input:focus, select:focus, button:focus{ outline: 2px solid var(--accent); outline-offset:1px; }

.input-wrap{ position:relative; }
.input-wrap .icon{
  position:absolute;
  left: 11px; top:50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  pointer-events:none;
}
.input-wrap input{ padding-left: 34px; }

button, .btn{
  display:inline-flex;
  align-items:center;
  gap: 7px;
  background: var(--accent);
  color: var(--accent-ink);
  border:none;
  padding: 9px 16px;
  border-radius: 8px;
  font-weight:700;
  font-size: 0.86rem;
  cursor:pointer;
  transition: filter .15s ease, transform .15s var(--ease), box-shadow .15s var(--ease);
}
button:hover{ filter: brightness(1.12); transform: translateY(-1px); box-shadow: 0 6px 16px -8px rgba(0,0,0,.5); }
button:active{ transform: scale(.97) translateY(0); }
button.secondary, .btn.secondary{
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--panel-border);
}
button:disabled{ opacity:.5; cursor:not-allowed; transform:none; box-shadow:none; }
a.btn:hover, a.btn.secondary:hover{ text-decoration:none; }

.chip-row{ display:flex; flex-wrap:wrap; gap:8px; }
.chip{
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: var(--bg-alt);
  color: var(--text-dim);
  font-size: 0.82rem;
  cursor:pointer;
  user-select:none;
  transition: color .15s ease, border-color .15s ease, background .15s ease;
}
.chip:hover{ color: var(--text); border-color: #34456b; }
.chip.active{
  background: var(--accent);
  color: var(--accent-ink);
  border-color: transparent;
  font-weight:700;
}

.location-bar{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  padding: 12px 16px;
  border-radius: var(--radius-lg);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  margin-bottom: 22px;
  font-size: 0.88rem;
}
.location-bar .loc-icon{ font-size:1.1rem; }
.location-bar .loc-text{ color: var(--text-dim); }
.location-bar strong{ color: var(--text); }

.state-msg{
  padding: 30px 16px;
  text-align:center;
  color: var(--text-dim);
}
.state-msg.error{ color: var(--danger); }

.skeleton{
  background: linear-gradient(90deg, var(--panel) 25%, #182339 37%, var(--panel) 63%);
  background-size: 400% 100%;
  animation: shimmer 1.4s ease infinite;
  border-radius: 8px;
}
@keyframes shimmer{
  0%{ background-position: 100% 50%; }
  100%{ background-position: 0 50%; }
}

section.block{ margin-bottom: 44px; }
h2.block-title{
  font-size: 1.2rem;
  font-weight: 600;
  margin: 0 0 4px;
  display:flex;
  align-items:center;
  gap:8px;
}
p.block-sub{ color: var(--text-dim); font-size:0.9rem; margin: 0 0 16px; }

table{
  width:100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
th, td{
  text-align:left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--panel-border);
}
th{ color: var(--text-dim); font-weight:600; font-size:0.76rem; text-transform:uppercase; letter-spacing:.04em; }
tr:hover td{ background: var(--accent-soft); }

footer{
  text-align:center;
  color: var(--text-dim);
  font-size: 0.8rem;
  padding: 30px 20px 50px;
  border-top: 1px solid var(--panel-border);
  margin-top: 50px;
}

/* ---------- Sky page specific ---------- */
.sky-wrap{
  display:grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  align-items:start;
}
@media (max-width: 900px){
  .sky-wrap{ grid-template-columns: 1fr; }
}
#skyCanvas{
  width:100%;
  aspect-ratio: 1/1;
  background: radial-gradient(circle at 50% 50%, #0f1830 0%, #0b1220 75%);
  border-radius: 50%;
  border: 1px solid var(--panel-border);
  display:block;
  touch-action: none;
  cursor: grab;
}
#skyCanvas:active{ cursor: grabbing; }

.sky-side .panel{ margin-bottom: 16px; }
.sky-side label{ display:block; font-size:0.8rem; color:var(--text-dim); margin-bottom:4px; }
.sky-side .field{ margin-bottom: 12px; }
.legend-item{ display:flex; align-items:center; gap:8px; font-size:0.82rem; margin-bottom:6px; color: var(--text-dim); }
.legend-swatch{ width:10px; height:10px; border-radius:50%; flex-shrink:0; }

.body-list-item{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding: 7px 0;
  border-bottom: 1px dashed var(--panel-border);
  font-size: 0.85rem;
}
.body-list-item:last-child{ border-bottom:none; }
.body-list-item .bname{ display:flex; align-items:center; gap:8px; }
.body-list-item .bdot{ width:9px; height:9px; border-radius:50%; }
.body-list-item .balt{ color: var(--text-dim); font-variant-numeric: tabular-nums; }
.body-list-item .below{ opacity: .4; }

/* ---------- Interactive timeline (axis of year-positioned events) ---------- */
.timeline-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom: 14px;
  flex-wrap:wrap;
}
.timeline-hint{ font-size:0.8rem; color:var(--text-dim); }

.timeline-wrap{
  position:relative;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 28px 24px 128px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--panel-border);
  background: linear-gradient(180deg, var(--panel), rgba(16,26,46,.6));
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.timeline-wrap::-webkit-scrollbar{ display: none; }
.timeline-track{ position:relative; height: 2px; }
.timeline-axis-line{
  position:absolute; top:0; left:0; right:0; height:2px;
  background: var(--panel-border);
}
.timeline-node{
  position:absolute;
  top:0;
  transform: translateX(-50%);
  display:flex;
  flex-direction:column;
  align-items:center;
  background:none;
  border:none;
  cursor:pointer;
  color: var(--text-dim);
  padding: 0 8px 8px;
  width: 150px;
  font-family: inherit;
  border-radius: 10px;
  transition: background .15s ease;
}
/* Explicitly reclaim transform/filter/box-shadow here — the global
   button:hover rule elsewhere otherwise wins on specificity and replaces
   this node's own translateX(-50%) centering with its translateY(-1px)
   hover lift, snapping the node sideways out from under the cursor and
   causing hover to flicker on/off in a loop. */
.timeline-node:hover, .timeline-node:focus-visible{
  background: rgba(255,255,255,.05);
  outline:none;
  transform: translateX(-50%);
  filter: none;
  box-shadow: none;
}
.timeline-node:active{ transform: translateX(-50%); }
.timeline-node .tl-node-dot{
  width:12px;height:12px;border-radius:50%;
  background: var(--bg);
  border: 2px solid var(--accent);
  transition: background .15s ease;
}
.timeline-node:hover .tl-node-dot, .timeline-node:focus-visible .tl-node-dot{ background: var(--accent); }
.timeline-node .tl-node-year{
  margin-top:10px;
  font-family:"Space Grotesk", sans-serif;
  font-weight:700;
  font-size:0.85rem;
  color: var(--accent-strong);
}
.timeline-node .tl-node-desc{
  margin-top: 4px;
  font-size:0.74rem;
  text-align:center;
  line-height:1.4;
  color: var(--text-dim);
  font-weight:500;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.timeline-node:hover .tl-node-desc, .timeline-node:focus-visible .tl-node-desc{ color: var(--text); font-weight:700; }

/* ---------- Fullscreen slideshow ("Play timeline") ---------- */
.tl-fullscreen{
  display:none;
  position:fixed; inset:0;
  z-index:320;
  background: radial-gradient(ellipse at 50% 0%, #101a2e 0%, #05080f 72%);
  flex-direction:column;
}
.tl-fullscreen.open{ display:flex; }
.tl-fs-topbar{
  display:flex; align-items:center; justify-content:space-between;
  padding: 16px 20px;
  gap: 16px;
}
.tl-fs-progress{
  flex:1;
  height:4px;
  background: rgba(255,255,255,.12);
  border-radius:2px;
  overflow:hidden;
}
.tl-fs-progress-fill{
  height:100%;
  width:0%;
  background: var(--accent);
}
.tl-fs-progress-fill.animating{ transition: width linear; }
.tl-fs-stage{
  flex:1;
  display:grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 30px;
  padding: 10px 36px;
  overflow:hidden;
  align-items:center;
}
.tl-fs-slideshow{
  position:relative;
  border-radius: var(--radius-lg);
  overflow:hidden;
  background: #06090f;
  aspect-ratio: 4/3;
  max-height: 62vh;
  border: 1px solid var(--panel-border);
}
.tl-fs-image{
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit: cover;
  opacity:1;
  transition: opacity .5s ease;
}
.tl-fs-image.fade{ opacity:0; }
.tl-fs-caption{
  position:absolute; left:0; right:0; bottom:0;
  padding: 10px 14px;
  background: linear-gradient(0deg, rgba(0,0,0,.8), transparent);
  color:#fff;
  font-size:0.8rem;
}
.tl-fs-dots{ display:flex; gap:6px; margin-top:14px; }
.tl-fs-dot{ width:7px;height:7px;border-radius:50%; background: var(--panel-border); cursor:pointer; border:none; padding:0; }
.tl-fs-dot.active{ background: var(--accent); }
.tl-fs-info{ max-width:54ch; color: var(--text); }
.tl-fs-year{ font-family:"Space Grotesk",sans-serif; font-weight:800; font-size:1.7rem; color: var(--accent-strong); }
.tl-fs-title{ margin: 4px 0 14px; font-size:1.5rem; color: var(--text); }
.tl-fs-story{ color: var(--text-dim); line-height:1.75; font-size:0.95rem; }
.tl-fs-controls{
  display:flex; align-items:center; justify-content:center; gap:16px;
  padding: 16px 20px 30px;
}
.tl-fs-counter{ color: var(--text-dim); font-size:0.85rem; font-variant-numeric:tabular-nums; min-width:4ch; text-align:center; }
.tl-fs-controls button.icon-btn{ width:42px; height:42px; padding:0; justify-content:center; border-radius:50%; }
@media (max-width: 900px){
  .tl-fs-stage{ grid-template-columns:1fr; grid-template-rows:auto auto; overflow-y:auto; padding:10px 18px 20px; }
  .tl-fs-slideshow{ max-height: 42vh; }
}

/* ---------- Timeline detail popup ---------- */
.tl-popup-overlay{
  display:none;
  position:fixed; inset:0;
  z-index:300;
  background: rgba(4,7,13,.72);
  backdrop-filter: blur(4px);
  align-items:center;
  justify-content:center;
  padding: 24px;
}
.tl-popup-overlay.open{ display:flex; }
.tl-popup-card{
  position:relative;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  max-width: 640px;
  width:100%;
  max-height: 85vh;
  overflow-y:auto;
  box-shadow: 0 30px 70px -20px rgba(0,0,0,.7);
}
.tl-popup-close{
  position:absolute; top:12px; right:12px; z-index:2;
  width:36px; height:36px; padding:0; justify-content:center; border-radius:50%;
}
.tl-popup-images{ display:flex; gap:2px; background:#06090f; }
.tl-popup-images img{ flex:1; min-width:0; height:220px; object-fit:cover; display:block; }
.tl-popup-body{ padding: 22px 26px 26px; }
.tl-popup-year{ font-family:"Space Grotesk",sans-serif; font-weight:800; font-size:1.4rem; color: var(--accent-strong); }
.tl-popup-title{ margin: 4px 0 12px; font-size:1.3rem; color: var(--text); }
.tl-popup-story{ color: var(--text-dim); line-height:1.75; font-size:0.95rem; margin:0; }
@media (max-width: 640px){
  .tl-popup-images{ flex-direction:column; }
  .tl-popup-images img{ height:150px; }
}

/* ---------- 3D Simulator — fullscreen immersive HUD ---------- */
.sim-immersive{
  position: fixed;
  left:0; right:0; bottom:0;
  top: var(--header-h, 108px);
  background:
    radial-gradient(circle at 50% 30%, #0b1830 0%, #04070d 72%);
  overflow: hidden;
  z-index: 1;
}
.sim-immersive canvas{ display:block; width:100%; height:100%; touch-action:none; cursor:grab; }
.sim-immersive canvas:active{ cursor:grabbing; }

/* subtle scanline / grid overlay for the "hologram bay" feel */
.sim-immersive::before{
  content:"";
  position:absolute; inset:0;
  pointer-events:none;
  background-image:
    linear-gradient(rgba(125,211,252,0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(125,211,252,0.05) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(ellipse at 50% 45%, rgba(0,0,0,.9) 0%, transparent 72%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 45%, rgba(0,0,0,.9) 0%, transparent 72%);
}

.sim-hud-top{
  position:absolute; top:0; left:0; right:0;
  z-index: 4;
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:12px;
  flex-wrap:wrap;
  padding: 16px;
  background: linear-gradient(180deg, rgba(4,7,13,.85), transparent);
  pointer-events:none;
}
.sim-hud-top > *{ pointer-events:auto; }
.sim-hud-title{ display:flex; flex-direction:column; gap:2px; }
.sim-hud-eyebrow{ font-size:0.7rem; text-transform:uppercase; letter-spacing:.08em; color: var(--accent-strong); font-weight:700; }
.sim-hud-name{ font-family:"Space Grotesk",sans-serif; font-weight:700; font-size:1.15rem; color:#fff; text-shadow:0 2px 12px rgba(0,0,0,.6); }
.sim-vehicle-tabs{ display:flex; gap:8px; flex-wrap:wrap; }
.sim-vehicle-tabs button{ background: rgba(11,18,32,.7); backdrop-filter: blur(6px); }
.sim-vehicle-tabs button.active{ background: var(--accent); color: var(--accent-ink); border-color:transparent; }
.sim-toolbar-right{ display:flex; gap:8px; flex-wrap:wrap; }
.sim-toolbar-right button{ background: rgba(11,18,32,.7); backdrop-filter: blur(6px); }
.sim-toolbar-right button.active{ background: var(--accent); color: var(--accent-ink); border-color:transparent; }

.sim-hint{
  position:absolute; left:16px; bottom:16px;
  font-size:0.76rem; color:var(--text-dim);
  background:rgba(11,18,32,.65);
  padding:6px 10px; border-radius:999px;
  pointer-events:none;
  z-index: 4;
}
.sim-loading{
  position:absolute; inset:0;
  display:flex; align-items:center; justify-content:center;
  color:var(--text-dim); font-size:0.9rem;
  z-index: 3;
}
.sim-disclaimer-fixed{
  position:absolute; left:0; right:0; bottom:0;
  text-align:center;
  font-size:0.72rem;
  color:var(--text-dim);
  font-style:italic;
  padding: 8px 16px;
  background: linear-gradient(0deg, rgba(4,7,13,.85), transparent);
  z-index: 4;
  pointer-events:none;
}

/* Back-to-vehicle button, shown only in engine drill-down mode */
.sim-back-btn{ display:none; }
.sim-immersive.engine-mode .sim-back-btn{ display:inline-flex; }
.sim-immersive.engine-mode .sim-vehicle-tabs{ display:none; }

/* Popup — the only place part/engine text appears */
.sim-popup{
  position:absolute;
  z-index: 5;
  width: min(360px, calc(100vw - 32px));
  max-height: min(70vh, 560px);
  overflow-y:auto;
  right: 16px;
  bottom: 60px;
  background: rgba(13,20,36,.88);
  backdrop-filter: blur(10px);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.7);
  opacity:0;
  transform: translateY(8px);
  pointer-events:none;
  transition: opacity .18s ease, transform .18s ease;
}
.sim-popup.open{ opacity:1; transform:translateY(0); pointer-events:auto; }
.sim-popup-close{
  position:absolute; top:10px; right:10px;
  width:28px; height:28px; padding:0;
  justify-content:center;
  background: var(--panel);
  border-radius:50%;
}
.sim-part-eyebrow{ font-size:0.72rem; text-transform:uppercase; letter-spacing:.06em; color:var(--text-dim); margin-bottom:6px; }
.sim-part-title{ font-family:"Space Grotesk",sans-serif; font-weight:700; font-size:1.1rem; margin:0 22px 8px 0; color:var(--text); }
.sim-part-text{ color:var(--text-dim); font-size:0.86rem; line-height:1.6; margin: 0 0 10px; }

.sim-popup-photo{
  position:relative;
  border-radius: var(--radius);
  overflow:hidden;
  margin-bottom: 12px;
  border: 1px solid var(--panel-border);
  background: var(--bg-alt);
}
.sim-popup-photo img{ display:block; width:100%; max-height:180px; object-fit:cover; }
.sim-popup-photo-caption{
  display:block;
  font-size: 0.7rem;
  color: var(--text-dim);
  padding: 6px 9px;
  background: rgba(0,0,0,.2);
}
.sim-part-cta{ margin-top: 6px; width:100%; justify-content:center; }

.sim-flow{ display:flex; align-items:center; flex-wrap:wrap; gap:6px; margin:12px 0; }
.sim-flow-step{ background:var(--bg-alt); border:1px solid var(--panel-border); border-radius:7px; padding:5px 8px; font-size:0.72rem; color:var(--text-dim); }
.sim-flow-arrow{ color: var(--accent-strong); font-size:0.78rem; }

.sim-specs{ display:grid; grid-template-columns:1fr 1fr; gap:8px 12px; font-size:0.78rem; margin:12px 0; }
.sim-specs dt{ color:var(--text-dim); margin:0; }
.sim-specs dd{ margin:2px 0 0; font-weight:600; color:var(--text); }

details.sim-physics{ margin-top:10px; border-top:1px solid var(--panel-border); padding-top:10px; }
details.sim-physics summary{ cursor:pointer; font-weight:700; color:var(--accent-strong); font-size:0.82rem; display:flex; align-items:center; gap:6px; }
details.sim-physics summary::-webkit-details-marker{ display:none; }
details.sim-physics p{ color:var(--text-dim); font-size:0.82rem; line-height:1.65; margin-top:8px; }

@media (max-width: 720px){
  .sim-popup{ left:16px; right:16px; width:auto; bottom: 56px; }
  .sim-hud-name{ font-size:1rem; }
  .sim-hint{ bottom: 44px; }
}

/* ---------- Live Flight Radar — fullscreen immersive map ---------- */
.radar-immersive{
  position: fixed;
  left:0; right:0; bottom:0;
  top: var(--header-h, 108px);
  overflow: hidden;
  z-index: 1;
  background: #0b1220;
}
.radar-immersive #flightMap{ position:absolute; inset:0; width:100%; height:100%; border:none; border-radius:0; }

.radar-hud-top{
  position:absolute; top:0; left:0; right:0;
  z-index: 900;
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:12px;
  flex-wrap:wrap;
  padding: 16px;
  background: linear-gradient(180deg, rgba(4,7,13,.85), transparent);
  pointer-events:none;
}
.radar-hud-top > *{ pointer-events:auto; }
.radar-hud-left{ display:flex; flex-direction:column; gap:10px; max-width:min(480px, 62vw); }
.radar-hud-eyebrow{ font-size:0.7rem; text-transform:uppercase; letter-spacing:.08em; color: var(--accent-strong); font-weight:700; }
.radar-hud-title{ font-family:"Space Grotesk",sans-serif; font-weight:700; font-size:1.15rem; color:#fff; text-shadow:0 2px 12px rgba(0,0,0,.6); }
.radar-loc-bar{
  display:flex; align-items:center; gap:8px; flex-wrap:wrap;
  background: rgba(11,18,32,.72); backdrop-filter: blur(6px);
  border: 1px solid var(--panel-border); border-radius: 999px;
  padding: 7px 8px 7px 14px; font-size:0.8rem; color: var(--text-dim);
}
.radar-loc-bar button.secondary{ background: rgba(255,255,255,.08); }
.radar-manual-form{
  display:none; gap:8px; flex-wrap:wrap; align-items:flex-end;
  background: rgba(11,18,32,.85); backdrop-filter: blur(6px);
  border: 1px solid var(--panel-border); border-radius: var(--radius);
  padding: 12px 14px;
}
.radar-manual-form.open{ display:flex; }
.radar-manual-form label{ font-size:0.75rem; color:var(--text-dim); display:block; margin-bottom:4px; }
.radar-chip-row{ display:flex; gap:8px; }
.radar-chip-row .chip{ background: rgba(11,18,32,.72); backdrop-filter: blur(6px); }

.radar-panel{
  position:absolute; top:16px; right:16px; bottom:16px;
  z-index: 850;
  width: min(340px, calc(100vw - 32px));
  display:flex; flex-direction:column;
  background: rgba(13,20,36,.9);
  backdrop-filter: blur(10px);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.7);
  overflow:hidden;
}
.radar-panel.minimized{ bottom:auto; }
.radar-panel.minimized .radar-panel-body{ display:none; }
.radar-panel-header{
  display:flex; align-items:center; justify-content:space-between; gap:8px;
  padding: 13px 14px; border-bottom: 1px solid var(--panel-border);
  cursor:pointer; background:none; border-left:none; border-right:none; border-top:none;
  width:100%; color:inherit; font-family:inherit;
}
.radar-panel.minimized .radar-panel-header{ border-bottom:none; }
.radar-panel-title{ display:flex; align-items:center; gap:8px; font-weight:700; font-size:0.88rem; color:var(--text); }
.radar-panel-min-btn{ width:26px; height:26px; padding:0; justify-content:center; border-radius:50%; flex:none; transition: transform .2s var(--ease); }
.radar-panel.minimized .radar-panel-min-btn{ transform: rotate(180deg); }
.radar-panel-body{ overflow-y:auto; padding: 8px 10px 14px; }

.radar-hint{
  position:absolute; left:66px; bottom:16px; z-index:800;
  font-size:0.76rem; color:var(--text-dim);
  background:rgba(11,18,32,.65);
  padding:6px 10px; border-radius:999px;
  pointer-events:none;
  max-width: min(46vw, 420px);
}
.radar-legal-links{
  position:absolute; left:16px; bottom:52px; z-index:800;
  font-size:0.72rem; color:var(--text-dim);
  background:rgba(11,18,32,.65);
  padding:6px 10px; border-radius:999px;
}
.radar-legal-links a{ color:var(--text-dim); }
.radar-legal-links a:hover{ color:var(--text); }
@media (max-width: 860px){
  .radar-panel{ left:16px; right:16px; width:auto; top:auto; bottom:16px; max-height: 42vh; }
  .radar-panel.minimized{ bottom:16px; }
  .radar-hud-left{ max-width: 100%; }
  .radar-hint{ display:none; }
  .radar-legal-links{ display:none; }
}

/* ---------- AR Sky View ---------- */
.ar-overlay{
  display:none;
  position: fixed;
  inset: 0;
  z-index: 300;
  background: #000;
  overflow: hidden;
}
.ar-overlay video{
  position:absolute; inset:0;
  width:100%; height:100%;
  object-fit: cover;
}
.ar-overlay canvas{
  position:absolute; inset:0;
  width:100%; height:100%;
}
.ar-topbar{
  position:absolute;
  top:0; left:0; right:0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 16px;
  z-index: 2;
  background: linear-gradient(180deg, rgba(0,0,0,.55), transparent);
}
.ar-heading-badge{
  background: rgba(11,18,32,0.7);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  padding: 7px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}
.ar-message{
  display:none;
  position:absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  max-width: min(90vw, 420px);
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  text-align:center;
  color: var(--text);
  font-size: 0.92rem;
  z-index: 2;
  box-shadow: 0 20px 50px rgba(0,0,0,.6);
}

.tooltip-box{
  position:absolute;
  background: #101a2e;
  border: 1px solid var(--panel-border);
  border-radius: 8px;
  padding: 8px 11px;
  font-size: 0.8rem;
  pointer-events:none;
  z-index: 60;
  max-width: 220px;
  box-shadow: 0 6px 20px rgba(0,0,0,.4);
  display:none;
}

/* ---------- Home page ---------- */
.hero{
  padding: 28px 0 44px;
  border-bottom: 1px solid var(--panel-border);
  margin-bottom: 40px;
}
.hero .page-title{ font-size: clamp(2rem, 4.5vw, 3.1rem); max-width: 18ch; }
.hero .page-sub{ font-size: 1.05rem; max-width: 62ch; }
.hero-ctas{ display:flex; flex-wrap:wrap; gap: 12px; margin-top: 8px; }

.side-card{
  display:flex;
  flex-direction: column;
  gap: 10px;
}
.side-card .side-mark{
  width: 44px; height: 44px;
  display:flex; align-items:center; justify-content:center;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 1.3rem;
  margin-bottom: 4px;
}
.side-card h2{ margin: 0; font-size: 1.3rem; }
.side-card p{ color: var(--text-dim); margin: 0; }
.side-card ul{ margin: 6px 0 0; padding-left: 20px; color: var(--text-dim); font-size: 0.9rem; line-height: 1.8; }
.side-card .side-link{
  margin-top: 8px;
  font-weight: 700;
  color: var(--accent-strong);
  display:inline-flex;
  align-items:center;
  gap: 5px;
}
.side-card.astro-flavor{ --accent: #4c8fe0; --accent-strong: #72abed; --accent-soft: rgba(76,143,224,0.14); --accent-ink: #05101f; }
.side-card.aviation-flavor{ --accent: #d98a2b; --accent-strong: #eba24a; --accent-soft: rgba(217,138,43,0.14); --accent-ink: #1a0f02; }
.side-card{ border-top: 3px solid var(--accent); }

.map-cta{
  display:flex;
  flex-direction: column;
  gap: 8px;
  transition: transform .2s var(--ease), border-color .2s var(--ease), box-shadow .2s var(--ease);
  border-top: 3px solid var(--accent);
}
.map-cta:hover{
  transform: translateY(-3px);
  text-decoration:none;
  box-shadow: 0 14px 30px -16px rgba(0,0,0,.6);
}
.map-cta .side-mark{
  width: 44px; height: 44px;
  display:flex; align-items:center; justify-content:center;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent-strong);
}
.map-cta h3{ margin: 4px 0 0; color: var(--text); font-size: 1.15rem; }
.map-cta p{ color: var(--text-dim); margin: 0; font-size: 0.9rem; }
.map-cta .side-link{ margin-top: 6px; font-weight: 700; color: var(--accent-strong); display:inline-flex; align-items:center; gap:5px; }
.map-cta.astro-flavor{ --accent: #4c8fe0; --accent-strong: #72abed; --accent-soft: rgba(76,143,224,0.14); }
.map-cta.aviation-flavor{ --accent: #d98a2b; --accent-strong: #eba24a; --accent-soft: rgba(217,138,43,0.14); }

.carousel-row{
  display:flex;
  gap: 18px;
  overflow-x: auto;
  padding: 6px 6px 14px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.carousel-row::-webkit-scrollbar{ display: none; }
.carousel-row .sample-card{
  flex: 0 0 300px;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .2s ease;
}
.carousel-row .sample-card.highlighted{
  transform: scale(1.045) translateY(-4px);
  border-color: var(--accent);
  box-shadow: 0 20px 44px -16px rgba(0,0,0,.65);
  z-index: 1;
}
@media (max-width: 640px){
  .carousel-row .sample-card{ flex-basis: 78vw; }
}

.section-header-row{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap: 12px;
  margin-bottom: 4px;
}
.section-header-row .see-all{ font-size: 0.85rem; font-weight: 700; white-space:nowrap; }

/* ---------- Aviation page specific ---------- */
.flight-row{
  display:flex;
  flex-wrap:wrap;
  gap:14px;
  align-items:center;
  justify-content:space-between;
  padding: 12px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--panel-border);
  margin-bottom: 8px;
  font-size: 0.88rem;
}
.flight-row .fcall{ font-weight:700; font-family: "Space Grotesk", monospace; letter-spacing: 0.03em; }
.flight-row .fmeta{ color: var(--text-dim); font-size: 0.82rem; }
.flight-stats{ display:flex; gap:18px; flex-wrap:wrap; text-align:right; }
.flight-stats div{ min-width: 64px; }
.flight-stats .stat-label{ display:block; font-size:0.68rem; color:var(--text-dim); text-transform:uppercase; letter-spacing:.04em; }
.flight-stats .stat-val{ font-weight:600; font-variant-numeric: tabular-nums; }

/* ---------- Flight radar map ---------- */
.flight-row.compact{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap: 10px;
  padding: 10px 12px;
  margin-bottom: 6px;
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}
.flight-row.compact:hover{ border-color: var(--accent); }
.flight-row.compact.active{ border-color: var(--accent); background: var(--accent-soft); }
.flight-row.compact .fline{ font-size: 0.78rem; color: var(--text-dim); font-variant-numeric: tabular-nums; }

/* Leaflet dark theme */
.leaflet-container{
  background: var(--bg-alt) !important;
  font-family: "Inter", sans-serif !important;
}
.leaflet-control-zoom a{
  background: var(--panel) !important;
  color: var(--text) !important;
  border-color: var(--panel-border) !important;
}
.leaflet-control-zoom a:hover{ background: var(--bg-alt) !important; }
.leaflet-control-attribution{
  background: rgba(11,18,32,0.78) !important;
  color: var(--text-dim) !important;
  font-size: 0.68rem !important;
}
.leaflet-control-attribution a{ color: var(--text-dim) !important; }
.leaflet-popup-content-wrapper{
  background: var(--panel) !important;
  color: var(--text) !important;
  border: 1px solid var(--panel-border);
  border-radius: var(--radius) !important;
  box-shadow: 0 12px 30px -10px rgba(0,0,0,.6) !important;
}
.leaflet-popup-tip{ background: var(--panel) !important; }
.leaflet-popup-content{ margin: 12px 14px !important; font-size: 0.85rem; line-height:1.5; }
.leaflet-popup-content .fcall{ font-weight:700; font-family:"Space Grotesk", monospace; }

.plane-marker{ transition: transform 1s linear; }
.plane-marker-rot{
  width: 22px; height: 22px;
  display:flex; align-items:center; justify-content:center;
  color: var(--accent-strong);
  filter: drop-shadow(0 0 4px rgba(0,0,0,.6));
  transition: transform .8s linear;
}
.plane-marker-rot .icon{ width: 18px; height: 18px; fill: currentColor; stroke: #0b1220; stroke-width: 1; }
.plane-marker-rot.selected{ color: var(--warm); }

.user-marker{
  width: 18px; height:18px;
  position:relative;
}
.user-marker::before{
  content:"";
  position:absolute; inset:0;
  border-radius:50%;
  background: var(--warm);
  box-shadow: 0 0 0 3px rgba(242,198,117,0.25);
}
.user-marker::after{
  content:"";
  position:absolute; inset:-8px;
  border-radius:50%;
  border: 2px solid var(--warm);
  opacity: .55;
  animation: live-pulse-warm 2.2s ease-out infinite;
}

/* ---------- Floating help & guide chatbot (present on every page) ---------- */
.se-assistant{
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 500;
  display:flex;
  flex-direction:column;
  align-items:flex-end;
  gap:14px;
}
.se-assistant-fab{
  width:56px; height:56px;
  border-radius:50%;
  display:flex; align-items:center; justify-content:center;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: var(--accent-ink);
  position:relative;
  box-shadow: 0 14px 30px -10px rgba(0,0,0,.6);
  order:2;
}
.se-assistant-fab .icon{ width:24px; height:24px; }
.se-assistant-fab-badge{
  position:absolute; top:-2px; right:-2px;
  width:18px; height:18px; border-radius:50%;
  background: var(--warm); color:#241a04;
  font-size:0.65rem; font-weight:800;
  display:flex; align-items:center; justify-content:center;
  border: 2px solid var(--bg);
  animation: se-badge-pulse 2.4s ease-in-out infinite;
}
@keyframes se-badge-pulse{ 0%,100%{ transform:scale(1); } 50%{ transform:scale(1.18); } }
.se-assistant.open .se-assistant-fab-badge{ display:none; }

.se-assistant-panel{
  display:none;
  flex-direction:column;
  order:1;
  width: min(380px, calc(100vw - 40px));
  height: min(560px, calc(100vh - 120px));
  background: linear-gradient(180deg, var(--panel), rgba(16,26,46,.96));
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-lg);
  box-shadow: 0 30px 70px -20px rgba(0,0,0,.75);
  overflow:hidden;
}
.se-assistant.open .se-assistant-panel{ display:flex; }

.se-assistant-header{
  display:flex; align-items:center; gap:10px;
  padding: 14px 10px 14px 16px;
  border-bottom: 1px solid var(--panel-border);
  background: rgba(255,255,255,.02);
  flex: none;
}
.se-assistant-avatar{
  width:34px; height:34px; border-radius:50%; flex:none;
  display:flex; align-items:center; justify-content:center;
  background: var(--accent-soft); color: var(--accent-strong);
}
.se-assistant-avatar .icon{ width:18px; height:18px; }
.se-assistant-heading{ display:flex; flex-direction:column; line-height:1.3; flex:1; min-width:0; }
.se-assistant-heading strong{ font-size:0.95rem; color:var(--text); }
.se-assistant-heading span{ font-size:0.74rem; color:var(--text-dim); }
.se-assistant-close{
  flex:none; width:34px; height:34px; padding:0;
  justify-content:center; border-radius:50%;
}

.se-assistant-messages{
  flex:1; overflow-y:auto; min-height:0;
  padding: 14px 14px 6px;
  display:flex; flex-direction:column; gap:10px;
}
.se-msg{
  max-width: 88%;
  padding: 10px 13px;
  border-radius: 14px;
  font-size: 0.86rem;
  line-height:1.55;
}
.se-msg-bot{
  align-self:flex-start;
  background: rgba(255,255,255,.06);
  border: 1px solid var(--panel-border);
  color: var(--text);
  border-bottom-left-radius:4px;
}
.se-msg-user{
  align-self:flex-end;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: var(--accent-ink);
  font-weight:600;
  border-bottom-right-radius:4px;
}
.se-msg-link{
  display:inline-flex; align-items:center; gap:5px;
  margin-top:8px; font-weight:700; font-size:0.82rem;
}
.se-msg-typing{ display:flex; gap:4px; padding: 13px 15px; align-items:center; }
.se-msg-typing span{
  width:6px; height:6px; border-radius:50%;
  background: var(--text-dim);
  animation: se-typing 1s ease-in-out infinite;
}
.se-msg-typing span:nth-child(2){ animation-delay:.15s; }
.se-msg-typing span:nth-child(3){ animation-delay:.3s; }
@keyframes se-typing{
  0%,60%,100%{ opacity:.3; transform:translateY(0); }
  30%{ opacity:1; transform:translateY(-3px); }
}

.se-assistant-chips{
  display:flex; flex-wrap:wrap; gap:6px;
  padding: 4px 14px 10px;
  flex: none;
}
.se-chip{
  border: 1px solid var(--panel-border);
  background: rgba(255,255,255,.04);
  color: var(--text-dim);
  border-radius:999px;
  padding: 6px 12px;
  font-size:0.76rem;
  font-weight:500;
  cursor:pointer;
  transition: border-color .15s ease, color .15s ease, background .15s ease;
}
.se-chip:hover{ border-color: var(--accent); color: var(--text); background: var(--accent-soft); }

.se-assistant-input-row{
  display:flex; gap:8px;
  padding: 10px 12px 12px;
  border-top: 1px solid var(--panel-border);
  flex: none;
}
.se-assistant-input-row input{ flex:1; min-width:0; }
.se-assistant-send{
  flex:none; width:40px; height:40px; padding:0;
  justify-content:center; border-radius:50%;
}

@media (max-width: 480px){
  .se-assistant{ right:12px; bottom:12px; }
  .se-assistant-panel{ width: calc(100vw - 24px); height: min(72vh, 560px); }
}

@media (prefers-reduced-motion: reduce){
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  #starfield{ display:none; }
}
