:root {
  --bg: #0a1628;
  --panel: rgba(255, 255, 255, 0.03);
  --panel-2: rgba(255, 255, 255, 0.05);
  --line: rgba(255, 255, 255, 0.1);
  --text: #f1f5f9;
  --muted: rgba(241, 245, 249, 0.55);
  --muted-2: rgba(241, 245, 249, 0.35);
  --teal: #14b8a6;
  --teal-soft: #5eead4;
  --blue: #0891b2;
  --indigo: #818cf8;
  --danger: #f87171;
  --ok: #10b981;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "Noto Sans SC", "IBM Plex Sans", -apple-system, BlinkMacSystemFont, sans-serif;
  scroll-behavior: smooth;
}

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

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-thumb { background: rgba(20, 184, 166, 0.35); border-radius: 999px; }

.app {
  min-height: 100vh;
  padding-bottom: 84px;
}

.container {
  width: min(1280px, 100%);
  margin: 0 auto;
  padding: 0 16px;
}

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 22, 40, 0.95);
  border-bottom: 1px solid rgba(20, 184, 166, 0.15);
  backdrop-filter: blur(12px);
}

.header-row {
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.brand-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  display: grid;
  place-items: center;
  font-weight: 700;
  color: #fff;
  font-size: 14px;
}

.brand h1 { margin: 0; font-size: 15px; letter-spacing: 0.01em; }
.brand p { margin: 0; color: var(--teal-soft); font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase; }

.desktop-nav { display: none; align-items: center; gap: 6px; }
.desktop-nav a {
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 14px;
  color: rgba(241, 245, 249, 0.7);
}
.desktop-nav a.active {
  color: var(--teal);
  background: rgba(20, 184, 166, 0.1);
}

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

.btn {
  border: 1px solid var(--line);
  color: var(--text);
  background: var(--panel);
  border-radius: 12px;
  min-height: 44px;
  padding: 0 14px;
  cursor: pointer;
  font-weight: 600;
}
.btn.small { min-height: 36px; padding: 0 10px; font-size: 12px; }
.btn.primary {
  background: linear-gradient(135deg, var(--teal), var(--blue));
  border-color: transparent;
  color: #fff;
}
.btn.indigo {
  background: linear-gradient(135deg, var(--indigo), #6366f1);
  border-color: transparent;
  color: #fff;
}
.btn.ghost { background: transparent; }

.page { padding: 20px 0 30px; }

.hero {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  padding: 34px 24px;
  background: linear-gradient(135deg, rgba(20, 184, 166, 0.08), rgba(8, 145, 178, 0.05));
}
.hero h2 {
  margin: 10px 0;
  font-size: clamp(28px, 5vw, 52px);
  line-height: 1.2;
}
.hero p { color: var(--muted); line-height: 1.8; max-width: 680px; }
.home-stats { margin-top: 16px; }
.home-stats > div { display: grid; gap: 2px; }
.home-stats strong { color: var(--teal); font-size: 24px; }
.home-stats span { color: var(--muted-2); font-size: 12px; }
.ticker { margin-top: 16px; display: grid; gap: 10px; }
.ticker-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; }
.ticker-row span {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  color: rgba(241,245,249,0.75);
  padding: 6px 10px;
  border-radius: 9px;
  white-space: nowrap;
  font-size: 12px;
}
.feature-card { display: grid; gap: 12px; margin-top: 16px; }
.feature-card img { width: 100%; border-radius: 14px; height: 220px; object-fit: cover; opacity: 0.62; }
.recent-grid { margin-top: 16px; display: grid; grid-template-columns: 1fr; gap: 12px; }
.recent-card { border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.02); border-radius: 14px; overflow: hidden; }
.recent-card img { width: 100%; height: 120px; object-fit: cover; opacity: 0.65; }
.recent-card h4 { margin: 0 0 5px; font-size: 15px; }
.recent-card p { margin: 0; font-size: 12px; line-height: 1.6; }
.recent-card > div { padding: 10px; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--teal-soft);
  border: 1px solid rgba(20, 184, 166, 0.3);
  background: rgba(20, 184, 166, 0.1);
}

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.panel {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 18px;
  background: var(--panel);
  padding: 18px;
}

.panel h3 {
  margin: 0 0 10px;
  font-size: 18px;
}

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

input, select, textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  border-radius: 12px;
  min-height: 44px;
  padding: 10px 12px;
  font: inherit;
}
textarea { min-height: 84px; resize: vertical; }

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

label { display: grid; gap: 6px; color: rgba(241, 245, 249, 0.86); font-size: 14px; }

.muted { color: var(--muted); }
.muted2 { color: var(--muted-2); }
.success { color: var(--ok); }
.error { color: var(--danger); }

.list { margin: 0; padding-left: 18px; display: grid; gap: 10px; }
.list li { line-height: 1.55; }

.daily-head h2 { margin: 10px 0 6px; font-size: 30px; }
.daily-controls { margin: 14px 0 16px; display: grid; gap: 12px; }
.daily-search { display: flex; gap: 8px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  color: rgba(241, 245, 249, 0.5);
  font-size: 13px;
}
.chip.active { color: var(--teal); border-color: rgba(20, 184, 166, 0.3); background: rgba(20, 184, 166, 0.12); }
.daily-list { display: grid; gap: 12px; }
.daily-item {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.02);
}
.daily-item img {
  width: 100%;
  height: 88px;
  object-fit: cover;
  border-radius: 10px;
  opacity: 0.7;
}
.daily-item h3 { margin: 0 0 4px; font-size: 16px; }
.daily-item p { margin: 0 0 8px; font-size: 13px; }
.daily-tags { display: flex; gap: 6px; margin-bottom: 6px; flex-wrap: wrap; }
.daily-tags span {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 999px;
  color: rgba(94, 234, 212, 0.88);
  background: rgba(20, 184, 166, 0.1);
  border: 1px solid rgba(20, 184, 166, 0.2);
}
.meta { font-size: 12px; }
.signal-panel { position: sticky; top: 76px; height: fit-content; }
.signal-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.signal-list li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 8px;
}
.signal-list li strong { font-size: 14px; }
.signal-list li span { font-weight: 700; color: var(--text); }
.signal-list li em { font-style: normal; color: var(--teal); font-size: 12px; margin-left: 6px; }

.content-hero {
  height: 220px;
  background-size: cover;
  background-position: center;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  margin-bottom: 12px;
}
.content-hero .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(10,22,40,0.25), rgba(10,22,40,0.95));
}
.score-bar {
  height: 7px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  overflow: hidden;
  margin: 8px 0 12px;
}
.score-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--teal), var(--blue));
}
.article-html { line-height: 1.8; color: rgba(241, 245, 249, 0.78); }
.related { margin-top: 18px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,0.08); }
.related-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.related-card { border: 1px solid rgba(255,255,255,0.07); border-radius: 12px; overflow: hidden; background: rgba(255,255,255,0.02); }
.related-card img { width: 100%; height: 96px; object-fit: cover; opacity: 0.62; }
.related-card p { margin: 0; padding: 8px; font-size: 13px; color: rgba(241,245,249,0.75); }

.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.usage-wrap { margin-top: 12px; }
.usage-bar { height: 8px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; margin-bottom: 6px; }
.usage-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--blue)); }
.report-cards { margin-top: 12px; display: grid; gap: 10px; }
.report-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.02);
}
.report-row h4 { margin: 0 0 5px; font-size: 15px; }
.report-row p { margin: 0 0 6px; font-size: 12px; }
.result-grid { display: grid; grid-template-columns: 1fr; gap: 10px; margin-top: 8px; }

.popular { border-color: rgba(129,140,248,0.4); box-shadow: 0 0 24px rgba(129,140,248,0.12); }
.faq { border-top: 1px solid rgba(255,255,255,0.08); padding: 8px 0; }
.faq summary { cursor: pointer; color: rgba(241,245,249,0.8); }
.faq p { margin: 8px 0 0; font-size: 13px; }

.profile-head .avatar {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 20px;
  color: #fff;
}
.profile-tabs { display: flex; gap: 8px; margin-top: 14px; overflow-x: auto; }
.profile-metrics {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.profile-metrics > div {
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
  border-radius: 12px;
  text-align: center;
  padding: 10px 6px;
}
.profile-metrics strong { display: block; color: var(--teal); font-size: 22px; }
.profile-metrics span { color: var(--muted-2); font-size: 12px; }
.stack { display: grid; gap: 8px; margin-top: 12px; }
.kv {
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
  border-radius: 12px;
  padding: 10px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
}
.kv strong { font-size: 14px; }
.kv span { font-size: 13px; color: var(--muted); }

.admin-shell { min-height: 100vh; background: var(--bg); }
.admin-head {
  border-bottom: 1px solid rgba(20, 184, 166, 0.15);
  background: rgba(10,22,40,0.9);
  backdrop-filter: blur(12px);
}
.admin-head .header-row { height: 66px; }
.admin-grid { display: grid; grid-template-columns: 1fr; gap: 16px; margin-top: 18px; }
.comment-admin { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.comment-admin li { border: 1px solid rgba(255,255,255,0.07); border-radius: 12px; padding: 10px; background: rgba(255,255,255,0.02); }
.comment-actions { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }

.price {
  font-size: 42px;
  line-height: 1;
  font-weight: 700;
}

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 22, 40, 0.97);
  border-top: 1px solid rgba(20, 184, 166, 0.15);
  backdrop-filter: blur(10px);
  height: 70px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.bottom-nav a {
  display: grid;
  place-items: center;
  color: rgba(241, 245, 249, 0.45);
  font-size: 11px;
}
.bottom-nav a.active { color: var(--teal); }

.bare {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}
.bare .panel { width: min(520px, 100%); }

@media (min-width: 900px) {
  .app { padding-bottom: 0; }
  .desktop-nav { display: flex; }
  .bottom-nav { display: none; }
  .grid.two { grid-template-columns: 1.7fr 1fr; }
  .grid.three { grid-template-columns: repeat(3, 1fr); }
  .form-grid.two { grid-template-columns: 1fr 1fr; }
  .related-grid { grid-template-columns: repeat(3, 1fr); }
  .feature-card { grid-template-columns: 1.2fr 1fr; align-items: center; }
  .recent-grid { grid-template-columns: repeat(3, 1fr); }
  .admin-grid { grid-template-columns: 1fr 1.3fr; }
  .result-grid { grid-template-columns: 1fr 1fr; }
}
