:root {
  --color-bg: #020b17;
  --color-ink: #eef7ff;
  --color-muted: #a8b9cc;
  --color-dim: #72849a;
  --color-gold: #d8a84f;
  --color-gold-strong: #f4c66a;
  --color-cyan: #80c7ff;
  --glass-fill: rgba(80, 112, 145, 0.2);
  --glass-fill-strong: rgba(70, 100, 136, 0.28);
  --glass-line: rgba(221, 239, 255, 0.3);
  --glass-line-strong: rgba(241, 249, 255, 0.5);
  --shadow-deep: 0 24px 76px rgba(0, 0, 0, 0.34);
  --shadow-glow: 0 0 0 1px rgba(206, 232, 255, 0.09), 0 0 34px rgba(109, 190, 255, 0.18);
  --radius-card: 8px;
  --radius-control: 8px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--color-ink);
  background:
    linear-gradient(180deg, rgba(1, 7, 18, 0.03), rgba(1, 7, 18, 0.34)),
    url("../img/fund7-cosmic-mountains.png") center center / cover fixed no-repeat,
    var(--color-bg);
  letter-spacing: 0;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(2, 8, 18, 0.08), transparent 28%, transparent 72%, rgba(2, 8, 18, 0.08)),
    linear-gradient(180deg, transparent 0%, rgba(4, 10, 18, 0.08) 100%);
}

a {
  color: #bfe4ff;
  text-decoration: none;
}

a:hover {
  color: #ffffff;
  text-decoration: none;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 14px 32px;
  background: rgba(5, 16, 30, 0.58);
  border-bottom: 1px solid rgba(207, 232, 255, 0.18);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(24px) saturate(165%);
  -webkit-backdrop-filter: blur(24px) saturate(165%);
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--color-ink);
  font-weight: 700;
  letter-spacing: 0;
}

.site-brand:hover {
  color: var(--color-ink);
}

.site-brand-mark {
  display: block;
  width: 54px;
  height: 54px;
  padding: 7px;
  object-fit: contain;
  border: 1px solid rgba(247, 219, 156, 0.52);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(249, 252, 255, 0.96), rgba(214, 231, 248, 0.72) 48%, rgba(111, 159, 205, 0.36)),
    rgba(238, 247, 255, 0.88);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    0 0 0 1px rgba(128, 199, 255, 0.16),
    0 12px 28px rgba(0, 0, 0, 0.26),
    0 0 24px rgba(244, 198, 106, 0.16);
  filter: saturate(1.12) contrast(1.08);
}

.site-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.site-brand-name {
  font-size: 16px;
}

.site-brand-subtitle {
  margin-top: 4px;
  color: var(--color-muted);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
}

main {
  position: relative;
  width: min(1180px, calc(100% - 40px));
  margin: 32px auto 56px;
  padding: 54px 0 0;
}

.home-page main {
  padding-top: 0;
}

h1,
h2,
h3 {
  color: var(--color-ink);
  letter-spacing: 0;
}

h1 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.08;
  font-weight: 760;
}

h2 {
  font-size: 22px;
}

h3 {
  font-size: 18px;
}

p {
  color: var(--color-muted);
}

table {
  width: 100%;
  overflow: hidden;
  border-spacing: 0;
  border-collapse: separate;
  background: rgba(34, 58, 86, 0.24);
  border: 1px solid var(--glass-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-glow);
  backdrop-filter: blur(24px) saturate(150%);
  -webkit-backdrop-filter: blur(24px) saturate(150%);
}

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(206, 229, 255, 0.14);
  color: #e8f4ff;
  text-align: left;
  vertical-align: top;
}

tr:last-child td {
  border-bottom: 0;
}

th {
  color: #d8ecff;
  background: rgba(143, 203, 255, 0.1);
  font-weight: 700;
}

tbody tr {
  transition: background 160ms ease, box-shadow 160ms ease;
}

tbody tr:hover {
  background: rgba(113, 187, 255, 0.08);
}

button,
.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 9px 14px;
  border: 1px solid rgba(248, 208, 124, 0.62);
  border-radius: var(--radius-control);
  color: #08111c;
  background: linear-gradient(180deg, #ffe08a 0%, #d8a84f 100%);
  box-shadow: 0 10px 24px rgba(216, 168, 79, 0.22);
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  transition: transform 140ms ease, border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

button:hover,
.button-link:hover {
  color: #03070d;
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(244, 198, 106, 0.3);
}

button:active,
.button-link:active {
  transform: translateY(0);
}

.button-link.secondary,
button.secondary {
  color: #e9f6ff;
  border-color: rgba(205, 231, 255, 0.24);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(20px) saturate(145%);
  -webkit-backdrop-filter: blur(20px) saturate(145%);
}

.button-link.secondary:hover,
button.secondary:hover {
  color: #ffffff;
  border-color: rgba(128, 199, 255, 0.5);
  background: rgba(128, 199, 255, 0.14);
  box-shadow: 0 10px 24px rgba(75, 153, 219, 0.18);
}

.button-link.full-width-link {
  display: flex;
  width: 100%;
  padding: 13px 16px;
}

.muted {
  color: var(--color-muted);
}

.panel,
.module-card,
.metric-item,
.chart-box,
.compare-product-option,
.empty-state {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.18), rgba(188, 216, 241, 0.08) 36%, rgba(35, 62, 92, 0.18)),
    var(--glass-fill);
  border: 1px solid var(--glass-line);
  border-radius: var(--radius-card);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    inset 0 -18px 48px rgba(244, 198, 106, 0.06),
    var(--shadow-glow);
  backdrop-filter: blur(34px) saturate(178%);
  -webkit-backdrop-filter: blur(34px) saturate(178%);
}

.panel::before,
.module-card::before,
.metric-item::before,
.chart-box::before,
.compare-product-option::before,
.empty-state::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(132deg, rgba(255, 255, 255, 0.32), rgba(255, 255, 255, 0.04) 36%, transparent 72%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent 42%, rgba(244, 198, 106, 0.06));
}

.panel > *,
.module-card > *,
.metric-item > *,
.chart-box > *,
.compare-product-option > *,
.empty-state > * {
  position: relative;
}

.panel {
  padding: 20px;
  margin-bottom: 22px;
}

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
  padding-right: 240px;
}

.page-header h1 {
  margin-bottom: 6px;
}

.product-summary-panel {
  min-height: 228px;
  padding: clamp(18px, 2vw, 24px);
}

.product-summary-grid {
  min-height: 180px;
  display: grid;
  grid-template-rows: auto auto auto;
  row-gap: 16px;
  align-items: start;
}

.product-summary-grid h1 {
  margin: 0;
  font-size: 22px;
  line-height: 1.04;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-summary-list {
  display: grid;
  gap: 12px 30px;
  margin: 0;
}

.product-summary-fields {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.product-summary-list div,
.product-summary-note {
  display: flex;
  align-items: baseline;
  min-width: 0;
  color: rgba(219, 235, 251, 0.72);
  font-size: 18px;
  line-height: 1.25;
  font-weight: 760;
}

.product-summary-list dt {
  flex: 0 0 auto;
  margin: 0;
  color: rgba(219, 235, 251, 0.82);
}

.product-summary-list dd {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}

.product-summary-note {
  align-self: start;
  padding-top: 2px;
}

.product-summary-note span {
  flex: 0 0 auto;
  color: rgba(219, 235, 251, 0.82);
}

.product-summary-note strong {
  min-width: 0;
  color: rgba(219, 235, 251, 0.72);
  font: inherit;
  overflow-wrap: anywhere;
}

.page-header-actions {
  flex: 0 0 auto;
  padding-top: 32px;
}

.page-intro {
  margin-top: -4px;
  margin-bottom: 20px;
  color: var(--color-muted);
}

.section-title {
  margin: 30px 0 14px;
}

.product-overview-anchor-spacer {
  min-height: 27px;
}

.section-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 18px;
  margin-top: 30px;
  margin-bottom: 14px;
}

.section-title-row .section-title {
  margin: 0;
}

.section-title-meta {
  color: #d9ecff;
  font-size: 14px;
  font-weight: 700;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-bottom: 14px;
}

.module-card {
  min-height: 150px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 16px;
}

.module-card h3 {
  margin: 0 0 8px;
}

.module-card p {
  margin: 0;
  color: var(--color-muted);
}

.rule-panel {
  border-left: 1px solid rgba(244, 198, 106, 0.72);
  box-shadow:
    inset 3px 0 0 rgba(244, 198, 106, 0.58),
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    var(--shadow-glow);
}

.rule-panel summary {
  cursor: pointer;
  color: #fff8dc;
  font-weight: 700;
}

.rule-panel ul {
  margin-bottom: 0;
  color: var(--color-muted);
}

.actions,
.table-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.table-primary-link {
  color: #f6fbff;
  font-weight: 750;
  text-decoration: none;
}

.table-primary-link:hover,
.table-primary-link:focus-visible {
  color: #ffffff;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
}

.form-row {
  margin-bottom: 16px;
}

.form-row label {
  display: block;
  margin-bottom: 7px;
  color: #f3fbff;
  font-weight: 700;
}

.form-row input,
.form-row select,
.form-row textarea,
.login-field input {
  width: min(100%, 640px);
  padding: 11px 12px;
  color: #f6fbff;
  border: 1px solid rgba(226, 241, 255, 0.28);
  border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.1);
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.form-row input[type="checkbox"] {
  width: auto;
}

.form-row input::placeholder,
.form-row textarea::placeholder,
.login-field input::placeholder {
  color: rgba(223, 239, 255, 0.5);
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus,
.login-field input:focus {
  border-color: rgba(244, 198, 106, 0.72);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 0 3px rgba(216, 168, 79, 0.14);
}

.form-row select option {
  color: #0b1726;
}

.filter-panel {
  padding: 18px 20px;
}

.nav-center-filter-panel {
  padding: 28px 32px;
}

.nav-center-filter-layout {
  display: grid;
  grid-template-columns: minmax(0, 780px) minmax(190px, 260px);
  align-items: center;
  justify-content: space-between;
  gap: 36px;
}

.nav-center-filter-form {
  min-width: 0;
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 18px;
  max-width: 780px;
}

.filter-grid .form-row {
  margin-bottom: 0;
}

.filter-grid .form-row input,
.filter-grid .form-row select {
  width: 100%;
}

.filter-actions {
  margin-top: 16px;
}

.bulk-email-import-form {
  justify-self: center;
  text-align: center;
}

.bulk-email-import-button {
  width: 190px;
  min-height: 108px;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 20px 24px;
  font-size: 22px;
  line-height: 1.08;
  white-space: normal;
}

.bulk-email-import-button span {
  display: block;
}

.bulk-email-import-button:disabled {
  cursor: not-allowed;
  opacity: 0.62;
  transform: none;
}

.bulk-email-import-status {
  min-height: 36px;
  margin: 10px 0 0;
  color: rgba(223, 239, 255, 0.74);
  font-size: 13px;
  line-height: 1.35;
}

.bulk-email-import-status strong,
.bulk-email-import-status span {
  display: block;
}

.bulk-email-import-status strong {
  color: #ffe1a0;
  font-size: 14px;
}

.bulk-email-import-status.is-complete strong,
.bulk-email-import-status.is-updating strong {
  color: #ffe1a0;
}

.bulk-email-import-status.is-blocked span {
  color: #ffd7ba;
}

.product-overview-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 420px);
  align-items: center;
  column-gap: 48px;
  min-height: 176px;
  margin-bottom: 18px;
}

.product-overview-search-form {
  grid-column: 1;
  grid-row: 1;
  max-width: none;
}

.product-overview-search .form-row {
  margin-bottom: 0;
}

.product-overview-control-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
}

.product-overview-search .form-row input {
  width: 100%;
  min-height: 56px;
}

.product-overview-search .filter-actions {
  flex-wrap: nowrap;
  margin-top: 0;
}

.product-overview-search .filter-actions button,
.product-overview-search .filter-actions .button-link {
  min-height: 56px;
  padding: 13px 22px;
  white-space: nowrap;
}

.weekly-overview-entry {
  grid-column: 2;
  grid-row: 1;
  align-self: end;
  width: 100%;
  height: 56px;
  min-height: 56px;
  margin-bottom: 27px;
  padding: 13px 18px;
  font-weight: 800;
}

.weekly-orbit-showcase {
  position: relative;
  min-height: 278px;
  margin: 60px 0 28px;
  overflow: visible;
}

.weekly-orbit-showcase::before,
.weekly-orbit-showcase::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.weekly-orbit-showcase::before {
  left: 50%;
  top: 55%;
  width: min(1300px, 98%);
  height: 150px;
  border: 1px solid rgba(247, 219, 156, 0.18);
  border-radius: 50%;
  box-shadow:
    0 0 0 1px rgba(128, 199, 255, 0.08),
    0 0 42px rgba(244, 198, 106, 0.1);
  transform: translate(-50%, -50%) rotate(-5deg);
}

.weekly-orbit-showcase::after {
  inset: 0;
  background:
    linear-gradient(180deg, transparent 0%, rgba(244, 198, 106, 0.09) 43%, rgba(128, 199, 255, 0.07) 50%, transparent 64%),
    radial-gradient(circle at 50% 58%, rgba(244, 198, 106, 0.14), transparent 34%);
}

.weekly-orbit-track {
  position: relative;
  min-height: 278px;
  z-index: 1;
}

.weekly-orbit-card {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(380px, 62vw);
  min-height: 184px;
  transform: translate(-50%, -50%);
  animation: weeklyOrbit var(--weekly-orbit-duration, 36s) linear infinite;
  animation-delay: var(--weekly-orbit-delay, 0s);
  will-change: transform, opacity, filter;
}

.weekly-orbit-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
  outline: none;
}

.weekly-orbit-card-link:hover,
.weekly-orbit-card-link:focus-visible {
  color: inherit;
  text-decoration: none;
}

.weekly-orbit-card-inner {
  min-height: 184px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 28px 30px 26px;
  border: 1px solid rgba(207, 232, 255, 0.24);
  border-radius: 24px;
  background:
    radial-gradient(circle at 58% 58%, rgba(244, 198, 106, 0.2), transparent 46%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.2), rgba(80, 112, 145, 0.26) 44%, rgba(17, 43, 73, 0.46)),
    rgba(255, 255, 255, 0.07);
  box-shadow:
    0 24px 54px rgba(0, 0, 0, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.24),
    inset 0 -24px 44px rgba(244, 198, 106, 0.08),
    0 0 0 1px rgba(206, 232, 255, 0.06);
  backdrop-filter: blur(32px) saturate(170%);
  -webkit-backdrop-filter: blur(32px) saturate(170%);
  transition: border-color 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.weekly-orbit-card-link:hover .weekly-orbit-card-inner,
.weekly-orbit-card-link:focus-visible .weekly-orbit-card-inner {
  border-color: rgba(244, 198, 106, 0.44);
  box-shadow:
    0 26px 58px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    inset 0 -24px 44px rgba(244, 198, 106, 0.11),
    0 0 0 1px rgba(244, 198, 106, 0.12);
}

.weekly-orbit-card h3,
.weekly-result-card h3 {
  margin: 0;
  color: #f3fbff;
  font-size: 26px;
  line-height: 1.12;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.weekly-orbit-card-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 14px;
}

.weekly-orbit-card-metric {
  min-width: 0;
}

.weekly-orbit-card-metric span {
  display: block;
  color: rgba(223, 239, 255, 0.7);
  font-size: 16px;
  font-weight: 700;
}

.weekly-orbit-card-metric strong {
  display: block;
  margin-top: 8px;
  color: #ffe1a0;
  font-size: 48px;
  line-height: 1;
  font-weight: 800;
}

.weekly-orbit-card.is-negative .weekly-orbit-card-metric strong {
  color: #9ee7d4;
}

.weekly-orbit-card.is-neutral .weekly-orbit-card-metric strong {
  color: #d7e8f8;
  font-size: 36px;
}

.weekly-orbit-card-strategy {
  max-width: 128px;
  padding: 8px 15px;
  border: 1px solid rgba(207, 232, 255, 0.18);
  border-radius: 999px;
  color: rgba(231, 243, 255, 0.82);
  background: rgba(7, 23, 42, 0.24);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
  font-size: 17px;
  font-weight: 700;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.weekly-orbit-empty {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(420px, 88%);
  padding: 24px;
  border: 1px solid rgba(207, 232, 255, 0.18);
  border-radius: var(--radius-card);
  color: var(--color-muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.06);
  transform: translate(-50%, -50%);
}

.weekly-result-strip {
  margin: 60px 0 28px;
  overflow: hidden;
}

.weekly-result-track {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding: 4px 2px 18px;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}

.weekly-result-card {
  flex: 0 0 clamp(320px, 31vw, 380px);
  min-height: 184px;
  scroll-snap-align: start;
}

.weekly-result-card .weekly-orbit-card-inner {
  height: 100%;
}

.weekly-result-card.is-negative .weekly-orbit-card-metric strong {
  color: #9ee7d4;
}

.weekly-result-card.is-neutral .weekly-orbit-card-metric strong {
  color: #d7e8f8;
  font-size: 36px;
}

.weekly-result-empty {
  width: 100%;
  padding: 24px;
  border: 1px solid rgba(207, 232, 255, 0.18);
  border-radius: var(--radius-card);
  color: var(--color-muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.06);
}

@keyframes weeklyOrbit {
  0% {
    opacity: 1;
    filter: saturate(1.08);
    transform: translate(-50%, -50%) translate3d(0, 0, 0) scale(1) rotate(0deg);
  }
  20% {
    opacity: 0.46;
    filter: saturate(0.86);
    transform: translate(-50%, -50%) translate3d(460px, -38px, 0) scale(0.76) rotate(3deg);
  }
  40% {
    opacity: 0.14;
    filter: saturate(0.7);
    transform: translate(-50%, -50%) translate3d(760px, -74px, 0) scale(0.5) rotate(5deg);
  }
  50% {
    opacity: 0;
    filter: saturate(0.7);
    transform: translate(-50%, -50%) translate3d(0, -92px, 0) scale(0.48) rotate(0deg);
  }
  60% {
    opacity: 0.14;
    filter: saturate(0.7);
    transform: translate(-50%, -50%) translate3d(-760px, -74px, 0) scale(0.5) rotate(-5deg);
  }
  80% {
    opacity: 0.46;
    filter: saturate(0.86);
    transform: translate(-50%, -50%) translate3d(-460px, -38px, 0) scale(0.76) rotate(-3deg);
  }
  100% {
    opacity: 1;
    filter: saturate(1.08);
    transform: translate(-50%, -50%) translate3d(0, 0, 0) scale(1) rotate(0deg);
  }
}

.weekly-overview-actions {
  margin: 16px 0 0;
}

.field-error,
.form-errors,
.error-list {
  color: #ffd4d4;
}

.error-list,
.success-message,
.warning-message {
  border-radius: var(--radius-card);
  padding: 11px 13px;
  margin-bottom: 16px;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.error-list {
  background: rgba(127, 29, 29, 0.42);
  border: 1px solid rgba(252, 165, 165, 0.36);
}

.success-message {
  color: #d9ffef;
  background: rgba(9, 88, 57, 0.38);
  border: 1px solid rgba(110, 231, 183, 0.36);
}

.warning-message {
  color: #fff1c2;
  background: rgba(120, 77, 15, 0.4);
  border: 1px solid rgba(251, 191, 36, 0.38);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.metric-item {
  padding: 14px;
}

.metric-label {
  color: var(--color-muted);
  font-size: 13px;
  margin-bottom: 6px;
}

.metric-value {
  color: #ffffff;
  font-size: 20px;
  font-weight: 760;
}

.chart-box {
  padding: 14px;
  margin-bottom: 22px;
  background: rgba(4, 17, 32, 0.68);
}

.chart-frame {
  position: relative;
  padding: 22px 16px 34px 72px;
}

.chart-box svg {
  display: block;
  width: 100%;
  height: 260px;
}

.product-nav-chart-svg {
  filter: drop-shadow(0 0 14px rgba(14, 165, 217, 0.18));
}

.compare-nav-chart-svg {
  filter: drop-shadow(0 0 14px rgba(244, 198, 106, 0.12));
}

.product-nav-chart-line {
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chart-y-label {
  position: absolute;
  left: 0;
  width: 64px;
  color: var(--color-muted);
  font-size: 13px;
  line-height: 1.2;
  text-align: right;
  white-space: nowrap;
}

.chart-y-label-max {
  top: 18px;
}

.chart-y-label-min {
  bottom: 35px;
}

.chart-x-labels {
  position: absolute;
  left: 72px;
  right: 16px;
  bottom: 6px;
  display: flex;
  justify-content: space-between;
  color: var(--color-muted);
  font-size: 13px;
  line-height: 1.2;
}

.chart-x-labels span {
  flex: 1;
  white-space: nowrap;
}

.chart-x-labels span:nth-child(2) {
  text-align: center;
}

.chart-x-labels span:nth-child(3) {
  text-align: right;
}

.chart-hover-layer {
  position: absolute;
  left: 72px;
  right: 16px;
  top: 22px;
  height: 260px;
  pointer-events: none;
}

.chart-point-marker {
  position: absolute;
  left: var(--chart-point-x);
  top: var(--chart-point-y);
  width: 24px;
  height: 24px;
  transform: translate(-50%, -50%);
  pointer-events: auto;
  cursor: crosshair;
}

.chart-point-dot {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 9px;
  height: 9px;
  border: 1px solid rgba(255, 237, 190, 0.9);
  border-radius: 999px;
  background:
    radial-gradient(circle at 40% 35%, #ffffff 0 16%, #ffe1a0 17% 42%, var(--chart-point-color, #f4c66a) 43% 100%);
  box-shadow:
    0 0 0 5px rgba(244, 198, 106, 0.14),
    0 0 18px rgba(244, 198, 106, 0.42),
    0 0 28px rgba(14, 165, 217, 0.2);
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.72);
  transition: opacity 140ms ease, transform 140ms ease;
}

.chart-point-guide {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 1px;
  height: 58px;
  background: linear-gradient(180deg, rgba(244, 198, 106, 0.65), transparent);
  opacity: 0;
  transform: translateX(-50%);
  transition: opacity 140ms ease;
}

.chart-point-tooltip {
  position: absolute;
  left: 50%;
  top: calc(100% + 9px);
  z-index: 2;
  display: grid;
  min-width: 144px;
  gap: 3px;
  padding: 10px 12px;
  border: 1px solid rgba(244, 198, 106, 0.32);
  border-radius: 12px;
  color: #eef8ff;
  background:
    linear-gradient(145deg, rgba(18, 38, 62, 0.9), rgba(5, 17, 31, 0.9)),
    rgba(255, 255, 255, 0.08);
  box-shadow:
    0 16px 34px rgba(0, 0, 0, 0.32),
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 0 18px rgba(244, 198, 106, 0.1);
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  opacity: 0;
  transform: translate(-50%, -6px) scale(0.96);
  transform-origin: top center;
  transition: opacity 140ms ease, transform 140ms ease;
  white-space: nowrap;
  pointer-events: none;
}

.compare-chart-point-tooltip {
  min-width: 174px;
  border-left: 3px solid var(--chart-point-color, #f4c66a);
}

.chart-point-tooltip::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -5px;
  width: 9px;
  height: 9px;
  border-left: 1px solid rgba(244, 198, 106, 0.32);
  border-top: 1px solid rgba(244, 198, 106, 0.32);
  background: rgba(18, 38, 62, 0.92);
  transform: translateX(-50%) rotate(45deg);
}

.chart-point-tooltip span {
  color: rgba(223, 239, 255, 0.7);
  font-size: 12px;
  font-weight: 700;
}

.chart-point-tooltip .chart-point-name {
  max-width: 240px;
  overflow: hidden;
  color: #eef8ff;
  text-overflow: ellipsis;
}

.chart-point-tooltip strong {
  color: #ffe1a0;
  font-size: 17px;
  line-height: 1;
  font-weight: 820;
}

.chart-point-marker:hover .chart-point-dot,
.chart-point-marker:hover .chart-point-guide,
.chart-point-marker:hover .chart-point-tooltip {
  opacity: 1;
}

.chart-point-marker:hover .chart-point-dot {
  transform: translate(-50%, -50%) scale(1);
}

.chart-point-marker:hover .chart-point-tooltip {
  transform: translate(-50%, 0) scale(1);
}

.compare-product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.compare-product-option {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  min-height: 46px;
  padding: 11px 12px;
}

.compare-product-option input {
  margin-top: 4px;
  flex: 0 0 auto;
}

.compare-product-text {
  min-width: 0;
}

.compare-product-name {
  color: #ffffff;
  font-weight: 700;
  overflow-wrap: anywhere;
}

.compare-product-meta {
  margin-top: 3px;
  color: var(--color-muted);
  font-size: 13px;
  overflow-wrap: anywhere;
}

.compare-chart-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  margin-bottom: 12px;
  color: var(--color-muted);
  font-size: 14px;
}

.compare-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.compare-legend-swatch {
  width: 18px;
  height: 3px;
  display: inline-block;
}

.compare-empty-hidden {
  display: none;
}

.portfolio-holding-list {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.portfolio-holding-row {
  display: grid;
  grid-template-columns: minmax(260px, 1.4fr) minmax(150px, 0.6fr) minmax(150px, 0.6fr) auto;
  gap: 12px;
  align-items: end;
  padding: 14px;
  border: 1px solid rgba(207, 232, 255, 0.16);
  border-radius: var(--radius-card);
  background: rgba(255, 255, 255, 0.05);
}

.portfolio-holding-row .form-row {
  margin-bottom: 0;
}

.portfolio-holding-row .form-row select,
.portfolio-holding-row .form-row input {
  width: 100%;
}

.portfolio-save-grid {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(320px, 1.2fr);
  gap: 14px;
}

.portfolio-save-grid .form-row textarea,
.portfolio-save-grid .form-row input,
.portfolio-valuation-select select {
  width: 100%;
}

.portfolio-valuation-select {
  max-width: 340px;
}

.portfolio-report-summary-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  margin-bottom: 28px;
}

.portfolio-report-metrics {
  margin-bottom: 0;
}

.portfolio-report-toolbar {
  display: flex;
  align-items: end;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 12px;
  margin: 0;
}

.portfolio-report-toolbar .form-row {
  margin-bottom: 0;
}

.portfolio-save-modal[hidden] {
  display: none;
}

.portfolio-save-modal {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(1, 10, 20, 0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.portfolio-save-dialog {
  width: min(760px, 100%);
  padding: 22px;
  border: 1px solid rgba(207, 232, 255, 0.26);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(26, 50, 80, 0.96), rgba(5, 20, 36, 0.96)),
    rgba(255, 255, 255, 0.08);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.42),
    inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.portfolio-save-dialog .section-title-row {
  margin-bottom: 16px;
}

.portfolio-chart-point-tooltip {
  min-width: 178px;
}

.full-width-table-button {
  width: 100%;
  justify-content: center;
}

.warning-row td {
  background: rgba(120, 77, 15, 0.2);
}

.portfolio-total-row td {
  color: #fff8dc;
  background: rgba(216, 168, 79, 0.12);
  font-weight: 800;
}

.portfolio-record-summary {
  margin-bottom: 26px;
}

@media (min-width: 1020px) {
  .portfolio-report-summary-layout {
    grid-template-columns: minmax(0, 1fr) minmax(430px, 0.38fr);
    align-items: start;
  }

  .portfolio-report-toolbar {
    align-self: start;
    margin-top: 108px;
  }
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px 18px;
  margin-bottom: 16px;
  color: var(--color-muted);
}

.detail-grid strong {
  color: #f3fbff;
}

.empty-state {
  color: var(--color-muted);
  border-style: dashed;
  padding: 14px 16px;
  margin-bottom: 16px;
}

.quick-actions {
  margin-bottom: 20px;
}

.compact-list {
  margin: 0;
  padding-left: 18px;
}

.compact-list li {
  margin-bottom: 6px;
  color: var(--color-muted);
}

.top-user-actions {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 10;
  justify-content: flex-end;
  font-size: 14px;
}

.top-user-actions form {
  margin: 0;
}

.top-user-actions .muted {
  padding: 9px 10px;
  border: 1px solid rgba(207, 232, 255, 0.18);
  border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.1);
}

.home-page .top-user-actions {
  top: 30px;
  right: 30px;
}

.home-hero {
  position: relative;
  min-height: 220px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 396px);
  gap: 24px;
  align-items: end;
  padding: 30px;
  margin-bottom: 28px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.18), rgba(90, 123, 158, 0.1) 42%, rgba(9, 24, 45, 0.2)),
    rgba(255, 255, 255, 0.08);
  border: 1px solid var(--glass-line-strong);
  border-radius: var(--radius-card);
  box-shadow:
    var(--shadow-deep),
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    inset 0 -32px 72px rgba(244, 198, 106, 0.07),
    var(--shadow-glow);
  backdrop-filter: blur(36px) saturate(180%);
  -webkit-backdrop-filter: blur(36px) saturate(180%);
}

.home-hero-brand {
  display: flex;
  align-items: center;
  gap: 18px;
}

.home-hero-logo {
  width: 124px;
  height: 124px;
  padding: 16px;
  object-fit: contain;
  flex: 0 0 auto;
  border: 1px solid rgba(247, 219, 156, 0.58);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(250, 253, 255, 0.96), rgba(224, 236, 250, 0.78) 44%, rgba(117, 169, 215, 0.34)),
    rgba(238, 247, 255, 0.9);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 0 0 1px rgba(128, 199, 255, 0.18),
    0 20px 44px rgba(0, 0, 0, 0.34),
    0 0 36px rgba(244, 198, 106, 0.18);
  filter: saturate(1.14) contrast(1.08);
}

.home-hero-eyebrow,
.login-eyebrow {
  margin: 0 0 8px;
  color: var(--color-gold-strong);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0;
}

.home-hero h1 {
  margin: 0;
}

.home-hero-copy {
  max-width: 640px;
  margin: 12px 0 0;
}

.home-hero-status {
  width: min(100%, 396px);
  justify-self: end;
  margin-left: auto;
  min-height: 118px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(72px, 8vw, 128px);
  padding: 26px 28px;
  border: 1px solid rgba(207, 232, 255, 0.2);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06)),
    rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.2),
    inset 0 -18px 42px rgba(244, 198, 106, 0.06);
}

.home-hero-status-label {
  color: #d9eaff;
  font-size: 23px;
  font-weight: 760;
  line-height: 1.2;
  white-space: nowrap;
}

.home-hero-status-value {
  flex: 0 0 auto;
  margin-top: 0;
  color: #ffffff;
  font-size: 48px;
  font-weight: 820;
  line-height: 1;
}

body.auth-page {
  min-height: 100vh;
}

body.auth-page .site-header,
body.auth-page .top-user-actions {
  display: none;
}

body.auth-page main {
  width: 100%;
  min-height: 100vh;
  display: grid;
  place-items: center;
  margin: 0;
  padding: 32px 20px;
}

.login-screen {
  width: 100%;
  display: grid;
  place-items: center;
}

.login-card {
  position: relative;
  overflow: hidden;
  width: min(420px, 100%);
  padding: 28px 38px 36px;
  border: 1px solid rgba(241, 249, 255, 0.48);
  border-radius: var(--radius-card);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.22), rgba(141, 167, 195, 0.1) 42%, rgba(22, 42, 67, 0.18)),
    rgba(255, 255, 255, 0.08);
  box-shadow:
    0 24px 76px rgba(0, 0, 0, 0.32),
    0 0 54px rgba(117, 198, 255, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.34),
    inset 0 -34px 70px rgba(244, 198, 106, 0.08);
  backdrop-filter: blur(38px) saturate(185%);
  -webkit-backdrop-filter: blur(38px) saturate(185%);
}

.login-card::before,
.login-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.login-card::before {
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0.05) 34%, transparent 70%),
    linear-gradient(180deg, transparent 0%, rgba(255, 210, 133, 0.1) 100%);
}

.login-card::after {
  border-radius: inherit;
  box-shadow:
    inset 1px 0 0 rgba(255, 255, 255, 0.24),
    inset -1px 0 0 rgba(157, 216, 255, 0.2),
    inset 0 -1px 0 rgba(255, 220, 154, 0.24);
}

.login-card > * {
  position: relative;
  z-index: 1;
}

.login-brand-lockup {
  display: grid;
  justify-items: center;
  margin: 0 auto 26px;
}

.login-logo {
  display: block;
  width: 112px;
  height: 122px;
  padding: 0;
  margin: 0 auto 8px;
  object-fit: contain;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  filter:
    saturate(1.2)
    contrast(1.18)
    brightness(1.08)
    drop-shadow(0 16px 20px rgba(0, 0, 0, 0.26))
    drop-shadow(0 0 12px rgba(244, 198, 106, 0.12));
}

.login-brand-name {
  color: #dce9f8;
  font-size: 32px;
  font-weight: 500;
  line-height: 1;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.16),
    0 8px 18px rgba(0, 0, 0, 0.24);
}

.login-brand-name span {
  color: var(--color-gold-strong);
  font-weight: 700;
}

.login-brand-subtitle {
  margin-top: 8px;
  color: rgba(235, 246, 255, 0.84);
  font-size: 9px;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
  text-shadow: 0 5px 12px rgba(0, 0, 0, 0.24);
}

.login-title {
  margin: 0 0 16px;
  text-align: center;
  font-size: 0;
  line-height: 1.18;
}

.login-mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin-bottom: 16px;
  padding: 4px;
  border: 1px solid rgba(226, 241, 255, 0.2);
  border-radius: var(--radius-control);
  background: rgba(255, 255, 255, 0.07);
}

.login-mode-switch button {
  min-height: 38px;
  color: #dcecff;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
}

.login-mode-switch button:hover {
  transform: none;
}

.login-mode-switch button.is-active {
  color: #0b1119;
  border-color: rgba(248, 208, 124, 0.62);
  background: linear-gradient(180deg, #ffe08a 0%, #d8a84f 100%);
  box-shadow: 0 8px 20px rgba(216, 168, 79, 0.24);
}

.login-form {
  margin: 0;
}

.login-field {
  margin-bottom: 13px;
}

.login-field label {
  display: none;
  margin-bottom: 0;
  color: #eef7ff;
  font-weight: 700;
}

.login-field input {
  width: 100%;
}

.login-error {
  margin: 0 0 14px;
  padding: 10px 12px;
  color: #ffd7d7;
  border: 1px solid rgba(252, 165, 165, 0.35);
  border-radius: var(--radius-card);
  background: rgba(127, 29, 29, 0.36);
}

.login-submit {
  width: 100%;
  min-height: 46px;
  margin-top: 8px;
}

.full-width-action {
  margin-top: 14px;
  margin-bottom: 24px;
}

@media (max-width: 1080px) {
  .product-overview-search {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .nav-center-filter-layout {
    grid-template-columns: 1fr;
  }

  .bulk-email-import-form {
    justify-self: start;
  }

  .product-overview-control-row {
    grid-template-columns: 1fr;
  }

  .product-overview-search .filter-actions {
    justify-content: flex-start;
  }

  .weekly-overview-entry {
    grid-column: 1;
    grid-row: 2;
    width: 100%;
    margin-top: 18px;
  }
}

@media (max-width: 900px) {
  .page-header {
    padding-right: 0;
  }

  main,
  .home-page main {
    padding-top: 0;
  }

  .top-user-actions {
    position: static;
    margin-bottom: 18px;
  }

  .home-page .top-user-actions {
    justify-content: flex-end;
  }

  .home-hero {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .product-summary-grid {
    row-gap: 16px;
  }

  .product-summary-fields {
    grid-template-columns: 1fr;
  }

  .home-hero-status {
    width: min(100%, 249px);
    margin-right: -30px;
    gap: clamp(22px, 4vw, 34px);
    padding: 24px 22px;
  }
}

@media (max-width: 760px) {
  .site-header {
    padding: 12px 18px;
  }

  .site-brand-subtitle {
    display: none;
  }

  main {
    width: min(100% - 28px, 1180px);
    margin-top: 22px;
  }

  h1 {
    font-size: 32px;
  }

  .filter-grid {
    grid-template-columns: 1fr;
  }

  .portfolio-holding-row,
  .portfolio-save-grid {
    grid-template-columns: 1fr;
  }

  .home-hero {
    padding: 22px;
  }

  .home-hero-status {
    margin-right: -22px;
  }

  .home-hero-brand {
    align-items: flex-start;
  }

  .home-hero-logo {
    width: 74px;
    height: 74px;
  }

  .product-summary-panel {
    min-height: 0;
    padding: 18px;
  }

  .product-summary-list div,
  .product-summary-note {
    font-size: 17px;
  }

  .login-card {
    padding: 28px 22px 30px;
  }

  th,
  td {
    padding: 10px 11px;
  }

  table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .weekly-orbit-showcase {
    min-height: 0;
    padding: 14px;
  }

  .weekly-result-strip {
    margin-top: 40px;
  }

  .weekly-orbit-showcase::before,
  .weekly-orbit-showcase::after {
    display: none;
  }

  .weekly-orbit-track {
    min-height: 0;
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .weekly-orbit-card {
    position: static;
    flex: 0 0 min(340px, 88%);
    width: auto;
    min-height: 178px;
    opacity: 1;
    animation: none;
    transform: none;
  }

  .weekly-result-card {
    flex: 0 0 min(340px, 88%);
    min-height: 178px;
  }

  .weekly-orbit-card-inner {
    min-height: 178px;
    padding: 24px;
  }

  .weekly-orbit-card h3,
  .weekly-result-card h3 {
    font-size: 24px;
  }

  .weekly-orbit-card-metric strong {
    font-size: 42px;
  }

  .weekly-orbit-card-metric span {
    font-size: 15px;
  }

  .weekly-orbit-card-content {
    align-items: end;
    gap: 12px;
  }

  .weekly-orbit-card-strategy {
    max-width: 112px;
    padding: 7px 12px;
    font-size: 15px;
  }

  thead,
  tbody,
  tr {
    width: max-content;
  }

  th,
  td {
    min-width: 96px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .weekly-orbit-card {
    animation: none;
  }
}
