body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 76% 4%, rgba(51, 159, 143, 0.13), transparent 25%),
    linear-gradient(rgba(17, 72, 67, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(17, 72, 67, 0.025) 1px, transparent 1px);
  background-size: auto, 40px 40px, 40px 40px;
  mask-image: linear-gradient(to bottom, #000, transparent 65%);
}

.sidebar {
  width: 244px;
  padding: 34px 25px 28px;
  background:
    radial-gradient(circle at 40% 8%, rgba(93, 202, 178, 0.13), transparent 24%),
    linear-gradient(180deg, #103e3a 0%, #0c312f 100%);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.brand {
  position: relative;
  letter-spacing: -0.4px;
}

.brand-mark {
  width: 31px;
  height: 31px;
  border-color: rgba(222, 236, 116, 0.42);
  box-shadow: inset 0 0 18px rgba(222, 236, 116, 0.08), 0 0 20px rgba(222, 236, 116, 0.08);
}

.brand-beta {
  align-self: flex-start;
  margin-top: -4px;
  color: #ddec74;
  font-size: 7px;
  letter-spacing: 1.2px;
}

.sidebar nav {
  margin-top: 78px;
}

.nav-item {
  position: relative;
  overflow: hidden;
  min-height: 47px;
}

.nav-item span {
  width: 25px;
  color: #72918d;
  font-size: 9px;
  letter-spacing: 1px;
}

.nav-item.active span {
  color: #ddec74;
}

.nav-item.active::after {
  content: "";
  position: absolute;
  right: 12px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ddec74;
  box-shadow: 0 0 10px #ddec74;
}

main {
  max-width: 1540px;
  margin-left: 244px;
}

.topbar {
  margin-bottom: 30px;
}

.topbar h1 {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -1.1px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 15px;
}

.sync-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #718985;
  font-size: 10px;
}

.sync-status i,
.ambient-label i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #55bca9;
  box-shadow: 0 0 0 4px rgba(85, 188, 169, 0.11);
}

.profile-button {
  border: 4px solid #fff;
  box-shadow: 0 8px 26px rgba(24, 59, 56, 0.14);
}

.hero-grid {
  grid-template-columns: minmax(570px, 1.7fr) minmax(260px, 0.72fr);
  gap: 18px;
}

.risk-card {
  min-height: 356px;
  padding: 38px 42px;
  isolation: isolate;
  border: 1px solid rgba(222, 236, 116, 0.13);
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    radial-gradient(circle at 74% 54%, rgba(47, 164, 145, 0.28), transparent 30%),
    linear-gradient(135deg, #0c4541 0%, #0d645d 100%);
  background-size: 34px 34px, 34px 34px, auto, auto;
  box-shadow: 0 25px 65px rgba(12, 69, 65, 0.2);
}

.risk-card::after {
  content: "";
  position: absolute;
  inset: auto -5% -55% 38%;
  height: 300px;
  z-index: -1;
  border-radius: 50%;
  background: rgba(222, 236, 116, 0.08);
  filter: blur(55px);
}

.risk-copy {
  width: 59%;
}

.status-pill {
  border-color: rgba(222, 236, 116, 0.22);
  background: rgba(222, 236, 116, 0.08);
  color: #e8efc4;
}

.risk-card h2 {
  margin: 25px 0 12px;
  font-size: clamp(30px, 3vw, 39px);
  line-height: 1.25;
}

.risk-card p {
  margin-bottom: 0;
}

.signal-meta {
  display: flex;
  gap: 25px;
  margin: 22px 0 18px;
}

.signal-meta span {
  padding-left: 11px;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
}

.signal-meta small,
.signal-meta strong {
  display: block;
}

.signal-meta small {
  margin-bottom: 4px;
  color: rgba(213, 231, 227, 0.58);
  font-size: 8px;
}

.signal-meta strong {
  color: #eef7f4;
  font-size: 10px;
  font-weight: 600;
}

.radar-wrap {
  width: 300px;
  height: 300px;
  right: 4.5%;
  top: 27px;
}

.radar-wrap::before,
.radar-wrap::after,
.radar-ring {
  opacity: 0.78;
}

.radar-sweep {
  animation-duration: 8s;
}

.orbit-label {
  position: absolute;
  z-index: 3;
  color: rgba(224, 239, 235, 0.44);
  font-size: 7px;
  letter-spacing: 1px;
}

.orbit-now { right: 16px; top: 145px; }
.orbit-risk { left: 54px; top: 48px; }

.risk-score {
  width: 108px;
  height: 108px;
  box-shadow: 0 0 0 10px rgba(255, 255, 255, 0.07), 0 15px 35px rgba(1, 39, 36, 0.22);
}

.weather-card {
  position: relative;
  overflow: hidden;
  padding: 31px;
  background: linear-gradient(150deg, #fff 55%, #f2f8f6 100%);
}

.weather-card::after {
  content: "";
  position: absolute;
  top: -55px;
  right: -55px;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(54, 168, 149, 0.08);
}

.ambient-label {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 12px 0 0;
  color: #839592;
  font-size: 8px;
}

.temperature {
  margin-top: 31px;
}

.temperature > strong {
  font-size: 62px;
  letter-spacing: -4px;
}

.quick-log {
  padding-top: 38px;
}

.shortcut-pill {
  margin-left: 7px;
  padding: 4px 7px;
  border: 1px solid #d7e4e1;
  border-radius: 999px;
  color: #4f7771;
  font-size: 8px;
}

.action-card,
.action-card.coral,
.action-card.violet {
  position: relative;
  overflow: hidden;
  min-height: 82px;
  border-color: rgba(24, 59, 56, 0.09);
  box-shadow: 0 9px 28px rgba(24, 59, 56, 0.035);
}

.action-card::after {
  content: "";
  position: absolute;
  right: -24px;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  opacity: 0.08;
}

.action-card.coral::after { background: var(--coral); }
.action-card.violet::after { background: var(--violet); }

.action-card .arrow {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #f4f7f6;
}

.panel {
  box-shadow: 0 12px 36px rgba(24, 59, 56, 0.045);
}

.prediction-item {
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.prediction-item:hover {
  transform: translateX(3px);
  border-color: #c9dbd7;
}

.meter i {
  box-shadow: 0 0 12px rgba(13, 112, 104, 0.25);
}

.profile-panel {
  margin-top: 20px;
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(205px, .9fr) minmax(420px, 1.9fr);
  align-items: center;
  gap: 18px;
  margin-top: 25px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.profile-heading-copy { margin: 7px 0 0; color: var(--muted); font-size: 10px; }

.profile-summary {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 92px;
  padding: 18px;
  border: 1px solid #d8e8e4;
  border-radius: 18px;
  background: linear-gradient(135deg, #eef8f5, #fff);
}

.profile-avatar {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  color: #fff;
  background: linear-gradient(145deg, #0d7068, #09524d);
  box-shadow: 0 8px 20px rgba(13,112,104,.2);
  font-weight: 800;
}

.profile-summary strong,
.profile-summary small {
  display: block;
}

.profile-summary strong {
  margin: 3px 0 5px;
  font-size: 16px;
}

.profile-summary small {
  color: var(--muted);
  font-size: 9px;
}

.profile-summary .profile-owner-label { color: var(--teal); font-size: 7px; font-weight: 800; letter-spacing: 1.2px; }

.profile-grid dl {
  display: grid;
  grid-template-columns: repeat(5, minmax(76px, 1fr));
  gap: 8px;
  margin: 0;
}

.profile-grid dl div {
  min-height: 82px;
  padding: 14px 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.profile-grid dt {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 9px;
}

.profile-grid dd {
  margin: 0;
  font-size: 13px;
  font-weight: 700;
}

.profile-actions {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding-top: 2px;
}

.profile-actions button {
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  background: #fff;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
}

.profile-actions button:hover {
  color: #fff;
  border-color: var(--teal);
  background: var(--teal);
}

@media (max-width: 1000px) {
  .sidebar { width: 196px; }
  main { margin-left: 196px; }
  .hero-grid { grid-template-columns: 1fr; }
  .risk-copy { width: 57%; }
  .profile-grid { grid-template-columns: 1fr; }
  .profile-grid dl { grid-template-columns: repeat(5, minmax(70px, 1fr)); }
  .profile-actions { grid-column: auto; }
}

@media (max-width: 720px) {
  body::before { background-size: auto, 28px 28px, 28px 28px; }
  main { margin-left: 0; }
  .topbar h1 { font-size: 21px; }
  .sync-status { display: none; }
  .hero-grid { display: block; }
  .risk-card {
    min-height: 434px;
    padding: 27px 24px;
    background-size: 28px 28px, 28px 28px, auto, auto;
  }
  .risk-copy { width: 100%; }
  .risk-card h2 { font-size: 30px; }
  .signal-meta { gap: 18px; margin-top: 18px; }
  .radar-wrap {
    width: 222px;
    height: 222px;
    top: 219px;
    right: -3px;
  }
  .risk-score { width: 88px; height: 88px; }
  .orbit-label { display: none; }
  .weather-card { padding: 25px; }
  .temperature > strong { font-size: 57px; }
  .section-heading p { line-height: 1.8; }
  .shortcut-pill { display: inline-block; }
  .profile-grid { grid-template-columns: 1fr; }
  .profile-grid dl { grid-template-columns: repeat(2, 1fr); gap: 12px 8px; }
  .profile-actions { display: grid; grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .radar-sweep { animation: none; }
  * { scroll-behavior: auto !important; }
}
