:root {
  color-scheme: dark;
  font-family: 'Segoe UI Variable', 'Segoe UI', Arial, sans-serif;
  --bg: #080b1b;
  --panel: #11162b;
  --line: #293148;
  --text: #f3f4ff;
  --muted: #a6b0ce;
  --cyan: #35f2d7;
  --purple: #a890ff;
  --error: #ffb3c4;
  --warning: #ffd39a;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; min-width: 0; min-height: 100vh; background: var(--bg); color: var(--text); line-height: 1.5; }
h1, h2, h3, p, dl, dd, ul { margin: 0; }
button, input { font: inherit; }
a { color: var(--cyan); text-underline-offset: .22em; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.sky {
  pointer-events: none;
  position: fixed;
  z-index: -1;
  inset: 0;
  background: radial-gradient(ellipse at 88% 6%, #4528784d, transparent 45%),
    radial-gradient(ellipse at 0% 56%, #18386032, transparent 46%),
    radial-gradient(ellipse at 68% 100%, #12575d26, transparent 52%);
}
.sky::after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: .32;
  background: radial-gradient(1px 1px at 23px 47px, #b4a5ff 75%, transparent),
    radial-gradient(1px 1px at 50px 95px, #9ce9ff 75%, transparent),
    radial-gradient(1px 1px at 180px 85px, #ccd4f2 75%, transparent);
  background-size: 177px 141px, 209px 167px, 281px 193px;
  mask-image: linear-gradient(#000, #0008 45%, transparent 94%);
}

.shell { width: min(1120px, calc(100% - 80px)); margin: 0 auto; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 18px; min-height: 78px; border-bottom: 1px solid #ffffff16; }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--text); font-size: 1rem; font-weight: 730; letter-spacing: .16em; text-decoration: none; }
.brand:hover { color: var(--cyan); }
.brand-mark { position: relative; width: 31px; height: 31px; border-radius: 50%; background: radial-gradient(circle at 32% 24%, #3bd9ee, #6747b87a 62%, #3a276705); box-shadow: 0 0 16px #7d58ff54; }
.brand-mark::before, .brand-mark::after { content: ''; position: absolute; inset: 10px 1px; border: 1px solid #b5fff3; border-radius: 50%; transform: rotate(-36deg); }
.brand-mark::after { transform: rotate(45deg); border-color: #bcb2ff; }
.brand-mark i { position: absolute; inset: 13px; background: white; border-radius: 50%; box-shadow: 0 0 8px #75ffe9; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; border: 1px solid transparent; border-radius: 9px; font-weight: 650; cursor: pointer; white-space: nowrap; }
.button:disabled { cursor: wait; opacity: .65; }
.secondary { min-height: 40px; padding: 7px 13px; border-color: #7964a563; background: #8f6fcd12; color: #e3d8ff; font-size: .875rem; }
.secondary:hover { border-color: #a890ffad; background: #a890ff25; }
.sliders { width: 17px; height: 14px; display: grid; align-content: space-between; }
.sliders i { height: 1px; background: #ba9cff; position: relative; }
.sliders i::after { content: ''; position: absolute; left: 4px; top: -2px; width: 5px; height: 5px; border: 1px solid #d6bfff; border-radius: 50%; background: #231c3d; }
.sliders i:nth-child(2)::after { left: 10px; }
.sliders i:last-child::after { left: 7px; }
.primary { background: var(--cyan); border-color: #7dffe9; padding: 12px 20px; color: #082522; box-shadow: 0 4px 21px #35f2d724; }
.primary:hover:not(:disabled) { background: #78ffe8; }

.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 440px); align-items: center; min-height: 302px; gap: 22px; position: relative; isolation: isolate; }
.hero-text { padding: 44px 0 42px; }
h1 { font-size: clamp(3rem, 6.2vw, 5rem); font-weight: 720; letter-spacing: -.064em; line-height: .99; }
h1 span { color: #c9bcff; background: linear-gradient(96deg, #e6ddff 10%, #ab91ff 89%); background-clip: text; -webkit-text-fill-color: transparent; }
.hero p { max-width: 460px; margin-top: 22px; color: #b8c2df; font-size: 1.0625rem; }

.orbits { position: relative; height: 268px; align-self: center; z-index: -1; }
.orbits::before { content: ''; position: absolute; inset: -12% -5%; background: radial-gradient(ellipse at center, #895dff26, transparent 58%); }
.orbit, .orbit-axis { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); }
.orbit { width: var(--orbit-size); aspect-ratio: 1; border: 1px solid #9e7cee45; border-radius: 50%; }
.orbit-outer { --orbit-size: 260px; border-color: #9d7dec30; }
.orbit-middle { --orbit-size: 208px; }
.orbit-inner { --orbit-size: 161px; border-color: #6a87dc62; }
.orbit-axis { width: 93%; height: 1px; background: linear-gradient(90deg, transparent, #a890ff64, #7f68b94d, transparent); }
.orbit-axis::after { content: ''; position: absolute; top: 50%; left: 50%; width: 238px; height: 1px; transform: translate(-50%, -50%) rotate(90deg); background: linear-gradient(90deg, transparent, #9389d64f, transparent); }
.orbit i, .satellite { position: absolute; width: 6px; height: 6px; border-radius: 50%; background: #ba9fff; box-shadow: 0 0 13px #a887ffb3; }
.orbit-middle i { right: 18%; top: 8%; }
.orbit-inner i { left: 12%; bottom: 12%; background: #6affed; box-shadow: 0 0 14px #35f2d7; }
.satellite-left { top: calc(50% - 2px); left: 10%; width: 4px; height: 4px; background: #6ecbe1; }
.satellite-right { top: calc(50% - 2px); right: 9%; width: 4px; height: 4px; }
.orb { position: absolute; top: 50%; left: 50%; width: 119px; height: 119px; transform: translate(-50%, -50%); border: 1px solid #b7a4ff9c; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 30% 18%, #563e91, #222547 62%, #151833 81%); box-shadow: 0 0 48px #9372ff44, inset 0 0 29px #c0abff22; }
.orb-doc { position: relative; display: grid; align-content: center; gap: 6px; width: 38px; height: 47px; padding: 0 7px; border: 1px solid #dacfff; border-radius: 5px; margin: 0 8px 3px 0; }
.orb-doc i { height: 1px; background: #dacfffbb; }
.orb-doc i:last-child { width: 52%; }
.orb-check { position: absolute; display: grid; place-items: center; top: 56%; left: 55%; width: 27px; height: 27px; border: 1px solid #63fae6; border-radius: 50%; background: #143c47; box-shadow: 0 0 18px #35f2d74b; }
.orb-check::after { content: ''; width: 10px; height: 6px; margin-top: -2px; border-left: 1.5px solid #7dffe9; border-bottom: 1.5px solid #7dffe9; transform: rotate(-45deg); }

.panel { border: 1px solid var(--line); border-radius: 14px; }
.search-panel { padding: 23px 26px 19px; background: linear-gradient(110deg, #161c33, #12162b 80%); border-color: #3c4464; box-shadow: 0 12px 36px #0507125e, inset 0 1px 0 #bdb7ff17; }
#lookup > label { display: block; margin-bottom: 8px; font-weight: 650; }
.search-controls { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; }
.input-wrap { position: relative; display: flex; }
.input-symbol { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); font-size: 1.125rem; font-weight: 650; color: #afb6d2; pointer-events: none; }
#inn { width: 100%; min-height: 52px; border: 1px solid #414c72; border-radius: 9px; padding: 10px 13px 10px 45px; background: #0b1024; color: var(--text); font-variant-numeric: tabular-nums; }
#inn::placeholder { color: #9da7c6; opacity: 1; }
#inn:hover { border-color: #6876a0; }
#inn[aria-invalid='true'] { border-color: var(--error); }
#submit { min-width: 168px; }
.search-icon { width: 13px; height: 13px; margin-right: 3px; border: 1.6px solid currentColor; border-radius: 50%; position: relative; }
.search-icon::after { content: ''; position: absolute; right: -5px; bottom: -2px; width: 6px; height: 1.6px; background: currentColor; transform: rotate(45deg); border-radius: 2px; }
.hint, .form-error { font-size: .875rem; margin-top: 8px; }
.hint { color: var(--muted); }
.form-error { color: var(--error); }

.result-panel { margin-top: 16px; padding: 23px 26px; background: linear-gradient(120deg, #11172be8, #101427d7); }
.empty { display: flex; align-items: center; min-height: 64px; gap: 16px; }
.empty-icon { display: grid; place-content: center; gap: 5px; flex: 0 0 46px; height: 46px; border: 1px solid #8d79b955; border-radius: 10px; background: #a890ff13; }
.empty-icon i { display: block; height: 1px; width: 19px; background: #baa5ff; }
.empty-icon i:last-child { width: 12px; }
h2 { font-size: 1.25rem; font-weight: 670; letter-spacing: -.02em; line-height: 1.24; }
.empty p, #full-name { margin-top: 5px; color: var(--muted); font-size: .9375rem; }
.result-title { display: flex; justify-content: space-between; align-items: start; gap: 12px 22px; }
.result-title > div { min-width: 0; overflow-wrap: anywhere; }
.result-title h2 { font-size: clamp(1.45rem, 3vw, 2rem); }
.status { font-weight: 650; font-size: .875rem; border: 1px solid #777e9b65; border-radius: 9px; padding: 6px 10px; min-width: 0; max-width: min(100%, 360px); text-align: left; overflow-wrap: anywhere; color: #cfdaef; background: #8ba0c710; }
.status[data-state='active'] { color: #88ffe9; background: #35f2d715; border-color: #35f2d760; }
.status[data-state='attention'] { color: var(--warning); background: #ffc28513; border-color: #ffbd6b58; }
.closure { color: var(--warning); margin-top: 12px; }
.details-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-top: 18px; }
.details-grid:empty { display: none; }
.detail { padding: 12px 14px; background: #080d2088; border: 1px solid #303750; border-radius: 9px; overflow-wrap: anywhere; }
.detail dt { font-size: .875rem; color: var(--muted); }
.detail dd { font-weight: 620; margin-top: 3px; }
.detail dd + dd { margin-top: 8px; }
.numeric { font-variant-numeric: tabular-nums; }
.detail-note { display: block; margin-top: 2px; color: var(--muted); font-size: .875rem; font-weight: 400; overflow-wrap: anywhere; }

.risk-section { margin-top: 19px; padding-top: 17px; border-top: 1px solid var(--line); }
.risk-title { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 4px 12px; margin-bottom: 8px; }
.risk-title h3 { font-size: 1.0625rem; }
#risk-summary { color: var(--muted); font-size: .875rem; }
.risk-list { display: grid; gap: 4px; list-style: none; padding: 0; }
.risk-item { display: flex; justify-content: space-between; align-items: start; gap: 6px 14px; padding: 8px 0; }
.risk-item + .risk-item { border-top: 1px solid #ffffff0e; }
.risk-copy { min-width: 0; overflow-wrap: anywhere; }
.badge { white-space: nowrap; border: 1px solid #8d99b446; background: #a6b0ce12; color: #c4cde7; border-radius: 999px; padding: 3px 9px; font-size: .8125rem; }
.badge[data-state='warning'] { background: #ffbb6c16; color: var(--warning); border-color: #ffbd6b5a; }
.badge[data-state='clear'] { background: #35f2d712; color: #92ddcf; border-color: #35f2d74d; }

.footer { display: flex; justify-content: space-between; align-items: baseline; gap: 5px 20px; flex-wrap: wrap; margin-top: 23px; padding: 17px 0 24px; border-top: 1px solid #ffffff16; color: var(--muted); }
.footer p { font-size: .875rem; }
.footer small { font-size: .8125rem; }

dialog { width: min(510px, calc(100% - 28px)); max-height: calc(100% - 30px); padding: 23px; border: 1px solid #7561a3; border-radius: 14px; background: #151b33; color: var(--text); box-shadow: 0 20px 90px #000b; }
dialog::backdrop { background: #030717c9; backdrop-filter: blur(5px); }
fieldset { margin: 16px 0 0; padding: 9px 10px 10px; border: 1px solid #3b4565; border-radius: 9px; }
legend { padding-inline: 6px; color: #c4cce1; font-size: .875rem; }
.options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3px; }
.option { display: flex; align-items: start; gap: 8px; padding: 5px; border-radius: 6px; font-size: .875rem; cursor: pointer; }
.option:hover, .option:focus-within { background: #a890ff18; }
.option input { margin: 3px 0 0; flex: 0 0 16px; height: 16px; accent-color: var(--cyan); }
.dialog-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 17px; }
.dialog-actions .primary { padding: 7px 16px; }

@media (max-width: 740px) {
  .shell { width: calc(100% - 44px); }
  .hero { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .hero-text { padding: 43px 0 33px; }
  .hero p { max-width: min(100%, 410px); }
  .orbits { position: absolute; width: 62%; right: -2%; top: -8px; opacity: .45; }
  .details-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 500px) {
  .shell { width: calc(100% - 30px); }
  .topbar { min-height: 65px; }
  .orbits { display: none; }
  h1 { font-size: clamp(2.5rem, 9.6vw, 3.3rem); }
  .hero-text { padding: 34px 0 25px; }
  .hero p { margin-top: 16px; font-size: 1rem; }
  .search-panel, .result-panel { padding: 16px; }
  .search-controls { grid-template-columns: 1fr; gap: 9px; }
  .primary { min-height: 45px; }
  .result-title { flex-direction: column; }
  .details-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 365px) {
  .options { grid-template-columns: minmax(0, 1fr); }
}
