:root {
  color-scheme: light;
  --bg: #f5f7f8;
  --surface: #ffffff;
  --surface-2: #f0f5f4;
  --surface-3: #e7eef0;
  --ink: #11191b;
  --muted: #5f6f73;
  --line: #d8e1e3;
  --accent: #e63b36;
  --accent-2: #f5b93d;
  --accent-3: #168ca3;
  --good: #147447;
  --warn: #a45b00;
  --nav: #101a1d;
  --shadow: 0 18px 50px rgba(18, 34, 38, 0.09);
  --shadow-soft: 0 10px 28px rgba(18, 34, 38, 0.06);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 14% 0, rgba(230, 59, 54, 0.12), transparent 26%),
    linear-gradient(180deg, #eef5f5 0, #f7f9f9 320px, var(--bg) 100%);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 12px clamp(16px, 4vw, 48px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--nav);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 5;
  box-shadow: 0 12px 34px rgba(12, 28, 31, 0.16);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.brandLink {
  color: inherit;
  text-decoration: none;
}

.brand img {
  width: 44px;
  height: 44px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  background: #fff;
  object-fit: cover;
}

.brandKicker {
  margin: 0 0 3px;
  color: #8edce1;
  font-size: 11px;
  font-weight: 700;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.topnav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.topnav a:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.topnav a.isActive {
  background: #fff;
  color: var(--nav);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.12);
}

[data-view-section][hidden] {
  display: none !important;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 23px;
  line-height: 1.1;
  letter-spacing: 0;
}

h2 {
  font-size: 18px;
}

main {
  width: min(1220px, 100%);
  margin: 0 auto;
  padding: 28px clamp(16px, 4vw, 44px) 56px;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 14px;
  padding: 36px 0 20px;
}

.heroEyebrow {
  display: inline-flex;
  margin-bottom: 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.intro h2 {
  max-width: 820px;
  margin-bottom: 10px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.03;
  letter-spacing: 0;
}

.intro p {
  max-width: 780px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.75;
}

.quickStats {
  display: grid;
  grid-template-columns: minmax(180px, 240px);
  gap: 10px;
  margin-bottom: 16px;
}

.quickStats article {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  padding: 14px;
  box-shadow: var(--shadow-soft);
}

.quickStats span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.quickStats strong {
  display: block;
  margin-top: 6px;
  font-size: 28px;
  line-height: 1;
}

.introActions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.primaryLink,
.secondaryLink {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 146px;
  min-height: 44px;
  border-radius: 8px;
  background: var(--nav);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
}

.secondaryLink {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 14px;
  box-shadow: none;
}

.primaryLink:hover {
  background: #1a2b2f;
}

.secondaryLink:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.noticeBar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin-bottom: 18px;
  padding: 11px 14px;
  border: 1px solid #ead6a2;
  border-radius: 8px;
  background: #fff8e7;
  color: #6c520d;
  font-size: 13px;
}

.insights,
.nowBoard,
.applicationsPanel,
.marketSection,
.newsLog {
  margin-bottom: 30px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.storyGrid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.storyCard {
  display: grid;
  align-content: start;
  min-height: 178px;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  padding: 18px;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}

.storyCard:first-child {
  grid-row: span 2;
  min-height: 360px;
  background: #101a1d;
  color: #fff;
}

.storyCardImage {
  width: calc(100% + 36px);
  height: 126px;
  margin: -18px -18px 4px;
  object-fit: cover;
  background: #eef4f5;
}

.storyCard:first-child .storyCardImage {
  height: 190px;
  opacity: 0.94;
}

.storyCard span {
  width: max-content;
  border-radius: 999px;
  background: #eef4f5;
  color: #426068;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 900;
}

.storyCard:first-child span {
  background: rgba(255, 255, 255, 0.12);
  color: #8edce1;
}

.storyCard strong {
  font-size: 19px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.storyCard:first-child strong {
  font-size: clamp(24px, 3vw, 34px);
}

.storyCard p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.storyCard:first-child p {
  color: rgba(255, 255, 255, 0.72);
}

.storyCard em {
  align-self: end;
  color: var(--accent);
  font-size: 13px;
  font-style: normal;
  font-weight: 900;
}

.storyCard small {
  width: fit-content;
  border-top: 1px solid var(--line);
  padding-top: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.storyCard:first-child small {
  border-top-color: rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.68);
}

.storyCard:first-child em {
  color: #f5b93d;
}

.applicationsLayout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 14px;
  align-items: start;
}

.applicationMain {
  padding: 14px;
}

.todoPanel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #101a1d;
  color: #fff;
  padding: 16px;
  box-shadow: var(--shadow-soft);
}

.todoPanel h3 {
  margin: 0 0 12px;
  font-size: 15px;
}

.todoSummary {
  display: grid;
  gap: 8px;
}

.todoSummary div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  padding: 8px 0;
}

.todoSummary span,
.todoSummary p {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.todoSummary strong {
  font-size: 22px;
}

.todoSummary p {
  margin-top: 8px;
  line-height: 1.6;
}

.marketShelves {
  display: grid;
  gap: 14px;
}

.cardPriceSearch {
  display: grid;
  gap: 14px;
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 1px 0 rgba(17, 25, 27, 0.02);
}

.cardPriceSearch h3 {
  margin: 0;
  font-size: 17px;
}

.cardPriceSearch p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.cardPriceForm {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.cardPriceForm input {
  box-sizing: border-box;
  min-width: 0;
}

.cardPriceSearch.isCardDetail .cardPriceForm,
.cardPriceSearch.isCardDetail .cardCandidateResults {
  display: none;
}

.cardPriceResults {
  display: grid;
  gap: 12px;
}

.cardCandidateResults {
  display: grid;
  gap: 12px;
}

.cardPriceResultHead,
.cardPriceSourceHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.cardPriceResultHead span,
.cardPriceItem span {
  color: var(--muted);
  font-size: 12px;
}

.cardPriceSource {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
}

.cardPriceSource.isBuy {
  border-left: 4px solid #d94b40;
}

.cardPriceSource.isSale {
  border-left: 4px solid #188f7b;
}

.cardPriceSourceHead > div {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.cardPriceSourceHead h4 {
  margin: 0;
  font-size: 14px;
}

.cardPriceSourceHead span,
.cardPriceItem small {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-width: 42px;
  height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: #f8ddd8;
  color: #b33a31;
  font-size: 11px;
  font-weight: 900;
}

.cardPriceSource.isSale .cardPriceSourceHead span,
.cardPriceItem.isSale small {
  background: #d9f1ec;
  color: #127866;
}

.cardPriceSourceHead a {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
}

.cardPriceList,
.cardCandidateList {
  display: grid;
  gap: 8px;
}

.cardCandidateList {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.cardPriceItem,
.cardCandidateItem {
  min-height: 58px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
}

.cardPriceItem {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
}

.cardCandidateItem {
  display: grid;
  grid-template-columns: 66px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  width: 100%;
  min-height: 122px;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.cardCandidateItem:hover,
.cardCandidateItem.isSelected {
  border-color: rgba(225, 68, 39, 0.42);
  background: #fff8f5;
}

.cardPriceItem img,
.cardCandidateItem img,
.cardPriceNoImage {
  flex: 0 0 42px;
  width: 42px;
  height: 56px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #f5f8f8;
  object-fit: contain;
}

.cardCandidateItem img,
.cardCandidateItem .cardPriceNoImage {
  grid-row: span 2;
  width: 66px;
  height: 92px;
}

.cardPriceNoImage {
  display: inline-grid;
  place-items: center;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
}

.cardPriceItem div,
.cardCandidateItem div {
  display: grid;
  gap: 4px;
  min-width: 0;
  margin-right: auto;
}

.cardPriceItem strong,
.cardCandidateItem strong {
  overflow: hidden;
  font-size: 13px;
  line-height: 1.45;
}

.cardPriceItem em,
.cardCandidateItem em {
  flex: 0 0 auto;
  font-size: 15px;
  font-style: normal;
  font-weight: 900;
}

.cardPriceItem.isBuy em {
  color: #d94b40;
}

.cardPriceItem.isSale em {
  color: #188f7b;
}

.cardCandidateItem small {
  color: var(--muted);
  font-size: 11px;
}

.cardCandidateItem em {
  display: grid;
  grid-column: 2;
  grid-template-columns: repeat(2, max-content);
  gap: 6px;
  justify-items: start;
  color: var(--ink);
  font-size: 12px;
}

.cardCandidatePrices span {
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 900;
}

.cardCandidatePrices .isBuy {
  background: #f8ddd8;
  color: #b33a31;
}

.cardCandidatePrices .isSale {
  background: #d9f1ec;
  color: #127866;
}

.cardPriceDetailHead {
  display: grid;
  gap: 12px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff8f5;
}

.cardPriceDetailHead > div {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.cardPriceDetailHead img,
.cardPriceDetailHead .cardPriceNoImage {
  width: 58px;
  height: 80px;
}

.cardPriceDetailHead section {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.cardPriceDetailHead strong {
  font-size: 16px;
  line-height: 1.45;
}

.cardPriceDetailHead span {
  color: var(--muted);
  font-size: 12px;
}

.cardPriceBackButton {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 104px;
  white-space: nowrap;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.cardPriceEmpty {
  padding: 12px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  font-size: 13px;
}

.cardPriceEmpty.isError {
  color: var(--accent);
}

.marketShelf {
  display: grid;
  gap: 0;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.marketRankHead {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.marketRankHead h3 {
  margin: 0;
  font-size: 17px;
}

.marketRankHead span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.marketRankHead > strong {
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 28px;
  border-radius: 999px;
  background: #101a1d;
  color: #fff;
  font-size: 13px;
}

.marketShelfBody {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 92px;
  min-width: 0;
}

.marketSliderViewport {
  min-width: 0;
  overflow: hidden;
}

.marketSlider {
  display: flex;
  width: max-content;
  min-width: 100%;
  gap: 10px;
  padding: 12px;
  animation: marketSlide 58s linear infinite;
}

.marketSlider:hover {
  animation-play-state: paused;
}

.marketSlider.isEmpty {
  width: 100%;
  animation: none;
}

.marketRankItem {
  display: grid;
  grid-template-columns: 28px 54px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  width: 260px;
  min-height: 108px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
}

.marketRankItem:hover {
  background: #f8fbfb;
  border-color: #bccbce;
}

.marketRankNo {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-align: right;
}

.marketRankItem img {
  width: 54px;
  height: 54px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.marketRankItem strong,
.marketRankItem span {
  display: block;
}

.marketRankItem strong {
  font-size: 13px;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.marketRankItem span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.marketRankItem em {
  grid-column: 3;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.marketRankItem em.isUp {
  color: var(--good);
}

.marketRankItem em.isDown {
  color: #d43f3a;
}

.marketSideActions {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  padding: 12px 10px;
  border-left: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.74), #fff);
}

.marketSideActions:empty {
  display: none;
}

.marketMoreButton {
  display: inline-grid;
  place-items: center;
  width: 52px;
  height: auto;
  min-height: 108px;
  padding: 12px 0;
  border: 1px solid #cfe2e5;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(20, 35, 40, 0.08);
  color: var(--accent);
  font-weight: 900;
  line-height: 1.1;
  text-orientation: mixed;
  white-space: nowrap;
  writing-mode: vertical-rl;
}

.marketMoreButton:hover {
  border-color: #9dcbd1;
  background: #f5fbfb;
  color: #0b7180;
}

@keyframes marketSlide {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .marketSliderViewport {
    width: 100%;
    overflow-x: auto;
  }

  .marketSlider {
    animation: none;
  }
}

.newsItems {
  display: grid;
  border-top: 1px solid var(--line);
}

.newsItem {
  display: grid;
  grid-template-columns: 116px 72px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}

.newsItem time,
.newsItem span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.newsItem span {
  width: max-content;
  border-radius: 999px;
  background: #eef4f5;
  color: #426068;
  padding: 3px 8px;
}

.newsItem strong {
  display: block;
  font-size: 15px;
  line-height: 1.4;
}

.newsItem a {
  color: inherit;
  text-decoration: none;
}

.newsItem a:hover strong {
  color: var(--accent);
}

.newsItem p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.insightGrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.insightPanel {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  padding: 16px;
  box-shadow: var(--shadow-soft);
}

.insightPanelWide {
  grid-column: span 2;
}

.insightPanel h3 {
  margin: 0 0 12px;
  font-size: 15px;
  letter-spacing: 0;
}

.panelLead {
  margin: -4px 0 10px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.insightList,
.calendarList,
.miniBars {
  display: grid;
  gap: 8px;
}

.targetRow,
.calendarItem {
  display: grid;
  gap: 6px;
  padding: 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  text-decoration: none;
}

.calendarItem {
  grid-template-columns: 64px minmax(0, 1fr);
  align-items: start;
  gap: 12px;
}

.calendarIcon {
  display: grid;
  place-items: center;
  width: 58px;
  min-height: 58px;
  border: 1px solid #cfdcdf;
  border-radius: 8px;
  background: #f7fbfb;
  color: var(--ink);
  text-align: center;
}

.calendarIcon img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  object-fit: contain;
}

.calendarIcon strong {
  font-size: 20px;
  line-height: 1.1;
}

.calendarMeta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 6px;
}

.calendarMeta span {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 7px;
  border-radius: 999px;
  background: #eef4f5;
  color: #426068;
  font-size: 11px;
  font-weight: 700;
}

.calendarMeta .statusPill {
  background: #e7f6ee;
  color: #17653c;
}

.calendarMeta .statusPill:first-child {
  border: 1px solid #b6e2c9;
}

.targetRow {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.targetRow:hover,
.calendarItem:hover {
  border-color: #b9cbcf;
  box-shadow: var(--shadow-soft);
  transform: translateY(-1px);
}

.targetRow strong,
.calendarItem strong {
  display: block;
  overflow-wrap: anywhere;
  font-size: 14px;
  line-height: 1.35;
}

.targetRow small,
.calendarItem span {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.applicationActions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.applicationActions .textButton {
  height: 32px;
  font-size: 12px;
}

.textButton.isTodoActive {
  border-color: #b7ded0;
  background: #e9f8f0;
  color: var(--good);
}

.textButton.isDisabled {
  cursor: not-allowed;
  border-color: var(--line);
  background: var(--panel);
  color: var(--muted);
}

.miniBar {
  position: relative;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  min-height: 34px;
  overflow: hidden;
  border-radius: 8px;
  background: #f2f6f6;
  padding: 8px 10px;
  font-size: 13px;
}

.miniBar::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--bar);
  background: rgba(22, 140, 163, 0.18);
  content: "";
}

.miniBar span,
.miniBar strong {
  position: relative;
  z-index: 1;
}

.miniBar span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.miniEmpty {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

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

.status {
  min-width: 88px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 13px;
  text-align: right;
}

.status[data-state="new"] {
  color: var(--good);
  font-weight: 800;
}

.status[data-state="busy"] {
  color: #ffd166;
}

.status[data-state="error"] {
  color: var(--accent);
  font-weight: 800;
}

button {
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  font-size: 20px;
}

button:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.filters {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) 150px 180px 180px;
  gap: 10px;
  margin-bottom: 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.74);
}

.xSearchPanel {
  margin-bottom: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 1px 0 rgba(17, 25, 27, 0.02);
}

.xSearchDisclosure {
  margin-top: 18px;
}

.xSearchDisclosure summary {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  margin-bottom: 10px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.xSearchDisclosure summary::-webkit-details-marker {
  display: none;
}

.xSearchGrid {
  display: grid;
  grid-template-columns: minmax(220px, 1.2fr) minmax(180px, 1fr) 180px 170px 150px;
  gap: 10px;
  align-items: end;
}

.xSearchGrid label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.xSearchGrid input,
.xSearchGrid select {
  width: 100%;
}

.xSearchActions {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
}

.xSearchPreview {
  min-width: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.primarySearchButton {
  width: auto;
  min-width: 190px;
  height: 42px;
  padding: 0 16px;
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 900;
}

.primarySearchButton:hover {
  border-color: #b92e2e;
  background: #b92e2e;
  color: #fff;
}

.searchChipBlock {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.searchChipBlock h3 {
  color: var(--muted);
  font-size: 13px;
}

.searchChips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.searchChips button {
  width: auto;
  height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.observedLogHead {
  margin-top: 20px;
}

.filterDisclosure {
  width: 100%;
  min-width: 0;
}

.filterDisclosure summary {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  margin-bottom: 10px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.filterDisclosure summary::-webkit-details-marker {
  display: none;
}

.logSection {
  margin: 28px 0 14px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

input,
select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  padding: 0 12px;
  font: inherit;
}

input:focus,
select:focus,
button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(232, 61, 61, 0.22);
  outline-offset: 2px;
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 22px;
  align-items: start;
}

body:not(.isAdmin) .layout {
  grid-template-columns: 1fr;
}

.sectionHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.sectionHead h2 {
  font-size: 20px;
}

.sectionHead span {
  display: inline-block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.refreshButton {
  flex: 0 0 auto;
}

.reports,
.runs,
.resaleItems {
  display: grid;
  gap: 10px;
}

.moreButton {
  margin-top: 12px;
}

.report,
.resaleCard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 40px;
  gap: 14px;
  align-items: center;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 15px;
  box-shadow: 0 1px 0 rgba(17, 25, 27, 0.02);
}

.report:hover,
.resaleCard:hover {
  border-color: #bccbce;
}

.reportTitle {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
}

.reportTitle strong {
  font-size: 15px;
  line-height: 1.35;
}

.reportTitle span,
.pill {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 12px;
}

.report p,
.resaleCard p {
  color: #263336;
  font-size: 14px;
  line-height: 1.55;
  margin-bottom: 10px;
}

.buySignals {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 10px;
}

.buySignal {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-decoration: none;
}

.buyScore {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 900;
}

.buyScore.scoreA {
  background: #dff6e9;
  color: #0f6a3f;
}

.buyScore.scoreB {
  background: #e7f4f2;
  color: #126d75;
}

.buyScore.scoreC {
  background: #fff3d1;
  color: #795200;
}

.buyScore.scoreD {
  background: var(--surface-2);
  color: var(--muted);
}

.buySignal.isActive {
  border-color: #b7ded0;
  background: #e9f8f0;
  color: var(--good);
}

a.buySignal:hover {
  border-color: var(--good);
}

.buySignalDetail {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.meta span {
  color: var(--muted);
  font-size: 12px;
}

.meta span::before {
  color: var(--line);
  content: "# ";
}

.sourceLink {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--nav);
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none;
}

.sourceLink svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
}

.sourceLink:hover {
  transform: translateY(-1px);
}

.sourceLink.isDisabled {
  cursor: not-allowed;
  background: var(--line);
  color: var(--muted);
  opacity: 0.7;
  transform: none;
}

.textButton,
.sendButton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 0;
  height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  text-decoration: none;
  cursor: pointer;
}

.textButton:hover,
.sendButton:hover {
  border-color: var(--accent);
  color: var(--accent);
}

details {
  flex: 1 1 260px;
  min-width: min(260px, 100%);
}

summary {
  display: inline-flex;
  align-items: center;
  height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  cursor: pointer;
  font-size: 13px;
  list-style: none;
}

summary::-webkit-details-marker {
  display: none;
}

.run {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 12px;
}

.sideNote {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  padding: 14px;
}

.publicNote {
  margin-top: 24px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}

.publicNote h2 {
  margin-bottom: 8px;
  font-size: 16px;
}

.publicNote p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.sideNote h2 {
  margin-bottom: 8px;
  font-size: 15px;
}

.sideNote p {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.infoGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.infoGrid article {
  padding: 16px 0;
}

.infoGrid h2 {
  margin-bottom: 8px;
}

.infoGrid p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.seoSection {
  display: grid;
  gap: 14px;
  margin-top: 24px;
  padding: 22px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.seoSection h2 {
  margin-bottom: 6px;
}

.seoSection p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.keywordLinks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.keywordLinks a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.keywordLinks a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border-top: 1px solid var(--line);
  padding: 24px;
  color: var(--muted);
  font-size: 13px;
}

footer a {
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
}

.run time {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 6px;
}

.run strong {
  font-size: 14px;
}

.empty {
  border: 1px dashed var(--line);
  border-radius: 8px;
  color: var(--muted);
  padding: 28px;
  text-align: center;
}

.empty strong,
.empty span {
  display: block;
}

.empty strong {
  margin-bottom: 6px;
  color: var(--ink);
}

.faq {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.faq > h2 {
  margin-bottom: 12px;
}

.faq details {
  width: 100%;
  min-width: 0;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
}

.faq summary {
  border: 0;
  padding: 0;
  height: auto;
  background: transparent;
  color: var(--ink);
  font-weight: 700;
}

.faq p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

@media (max-width: 860px) {
  .topbar {
    align-items: flex-start;
    position: static;
  }

  .topnav {
    order: 3;
    width: 100%;
    overflow-x: auto;
  }

  .intro {
    align-items: flex-start;
    grid-template-columns: 1fr;
  }

  .filters,
  .xSearchGrid,
  .cardPriceForm,
  .layout,
  .infoGrid,
  .insightGrid,
  .storyGrid,
  .applicationsLayout,
  .marketGrid,
  .quickStats {
    grid-template-columns: 1fr;
  }

  .insightPanelWide {
    grid-column: auto;
  }

  .storyCard:first-child {
    grid-row: auto;
    min-height: 0;
  }

  .storyCard:first-child .storyCardImage {
    height: 150px;
  }

  .newsItem {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .marketRankItem {
    width: clamp(220px, 58vw, 260px);
  }

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

  .primarySearchButton {
    width: 100%;
  }

  .cardPriceItem,
  .cardCandidateItem {
    align-items: flex-start;
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .cardCandidateItem {
    grid-template-columns: 66px minmax(0, 1fr);
  }

  .cardPriceResultHead,
  .cardPriceSourceHead {
    align-items: flex-start;
  }

  .cardPriceResultHead {
    display: grid;
    grid-template-columns: 1fr;
  }

  .cardPriceItem em,
  .cardCandidateItem em {
    grid-column: 2;
    justify-items: start;
  }
}

@media (max-width: 520px) {
  .topbar {
    flex-direction: column;
  }

  .actions {
    width: 100%;
    justify-content: flex-start;
  }

  .intro h2 {
    font-size: 40px;
  }

  .sectionHead {
    align-items: flex-start;
  }

  .xSearchPanel {
    padding: 12px;
  }

  .searchChips {
    flex-wrap: nowrap;
    margin-inline: -2px;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .calendarItem {
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 10px;
  }

  .calendarIcon {
    min-height: 54px;
    width: 54px;
  }

  .storyCard:first-child strong {
    font-size: 25px;
  }

  .marketRankHead {
    padding: 13px;
  }

  .marketShelfBody {
    grid-template-columns: minmax(0, 1fr) 66px;
  }

  .marketSliderViewport {
    overflow-x: auto;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
  }

  .marketSlider {
    gap: 8px;
    padding: 10px;
    animation: none;
  }

  .marketRankItem {
    grid-template-columns: 22px 46px minmax(0, 1fr);
    width: clamp(196px, calc(100vw - 120px), 248px);
    min-height: 104px;
    gap: 8px;
    padding: 10px;
    scroll-snap-align: start;
  }

  .marketRankItem img {
    width: 46px;
    height: 46px;
  }

  .marketRankItem strong {
    font-size: 12px;
  }

  .marketRankItem span,
  .marketRankItem em {
    font-size: 11px;
  }

  .marketMoreButton {
    width: 42px;
    min-height: 94px;
    padding: 10px 0;
    font-size: 12px;
  }
}
