:root {
  --bg: #f5f7fb;
  --surface: #ffffff;
  --surface-soft: #eef4f8;
  --text: #121820;
  --muted: #66727f;
  --border: #dce4ea;
  --accent: #1769d8;
  --accent-strong: #0f4fa8;
  --green: #18a66a;
  --amber: #d88716;
  --danger: #c73838;
  --shadow: 0 12px 28px rgba(16, 24, 40, 0.08);
  --radius: 8px;
  --container: 1180px;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  letter-spacing: 0;
}

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

img {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
}

.container {
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(14px);
}

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

.nav-row {
  padding: 0 0 10px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: var(--accent);
  background: #e9f2ff;
  border: 1px solid #cfe2ff;
  border-radius: 8px;
}

.brand-mark svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linejoin: round;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  padding: 0 2px 2px;
}

.top-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: #283544;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.top-nav a:hover,
.top-nav a.is-active {
  color: var(--accent);
  background: #eef5ff;
  border-color: #d3e5fb;
}

.top-nav a.is-active {
  color: #fff;
  background: #111820;
  border-color: #111820;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.locale-switcher select {
  min-height: 38px;
  max-width: 190px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  padding: 0 34px 0 12px;
  font-size: 14px;
  font-weight: 700;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--muted);
  background: var(--surface);
}

.icon-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.news-band {
  padding: 18px 0;
}

.ticker {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.ticker strong {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 6px;
  background: #fff4e5;
  color: #965c0e;
  font-size: 13px;
  text-transform: uppercase;
}

.ticker div {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
}

.ticker a,
.ticker span {
  color: #2f3b49;
  font-size: 14px;
  font-weight: 700;
}

.home-grid,
.content-with-sidebar,
.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 28px;
  align-items: start;
}

.lead-column {
  min-width: 0;
}

.lead-story {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.lead-story a {
  display: block;
  padding: 18px;
}

.story-image {
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 10;
  background:
    linear-gradient(135deg, rgba(23, 105, 216, 0.12), rgba(24, 166, 106, 0.12)),
    #edf3f8;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  color: #466176;
  font-size: 13px;
  font-weight: 800;
}

.story-image-large {
  aspect-ratio: 16 / 8;
  margin-bottom: 18px;
}

.story-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-meta {
  margin-top: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.lead-story h1 {
  max-width: 820px;
  margin: 8px 0 8px;
  font-size: clamp(32px, 5vw, 54px);
  line-height: 1.02;
  letter-spacing: 0;
}

.lead-story p,
.story-card p,
.empty-state p,
.page-head span,
.site-footer p {
  color: var(--muted);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin: 34px 0 16px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
}

.section-heading h2,
.side-panel h2,
.similar-section h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}

.section-heading span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-align: right;
}

.story-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.story-grid-wide {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.story-card {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.story-card a {
  display: grid;
  gap: 8px;
  height: 100%;
  padding: 12px;
}

.story-card h2,
.story-card h3 {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.story-card p {
  margin: 0;
  font-size: 14px;
}

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

.compact-rail {
  margin-top: 14px;
}

.rail-item {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 12px;
  min-height: 104px;
  padding: 10px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.rail-image,
.popular-thumb {
  overflow: hidden;
  background: #edf3f8;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.rail-image {
  aspect-ratio: 4 / 3;
}

.rail-image img,
.popular-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rail-copy {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.rail-copy span {
  color: var(--green);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.rail-copy strong {
  display: -webkit-box;
  overflow: hidden;
  font-size: 16px;
  line-height: 1.32;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.zodiac-section {
  margin-bottom: 28px;
  padding: 18px;
  background: linear-gradient(180deg, #ffffff, #f6f9fc);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.zodiac-section h2 {
  margin: 0 0 14px;
  font-size: 22px;
  line-height: 1.2;
}

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

.zodiac-card {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 12px;
  row-gap: 2px;
  min-height: 82px;
  padding: 13px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 1px 0 rgba(16, 24, 40, 0.03);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.zodiac-card:hover,
.zodiac-card.is-active {
  border-color: #b9d4f6;
  box-shadow: var(--shadow);
  transform: translateY(-1px);
}

.zodiac-card.is-active {
  background: #f0f7ff;
}

.zodiac-icon {
  display: grid;
  place-items: center;
  grid-row: 1 / span 2;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: #e9f2ff;
  color: var(--accent);
  font-size: 22px;
  font-weight: 900;
}

.zodiac-card strong {
  font-size: 16px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.zodiac-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.sidebar {
  display: grid;
  gap: 18px;
  position: sticky;
  top: 92px;
}

.side-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
}

.popular-row {
  display: grid;
  grid-template-columns: 58px 28px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid var(--border);
}

.popular-row:first-of-type {
  border-top: 0;
}

.popular-row span {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #e9f2ff;
  color: var(--accent);
  font-weight: 900;
}

.popular-row strong {
  font-size: 14px;
  line-height: 1.35;
}

.popular-thumb {
  aspect-ratio: 1 / 1;
}

.ad-slot {
  display: grid;
  align-items: center;
  min-height: 112px;
  margin: 18px 0;
  padding: 8px;
  background: #f0f4f7;
  border: 1px dashed #bcc8d2;
  border-radius: 8px;
  color: #788592;
  text-align: center;
  overflow: hidden;
}

.ad-slot span {
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.ad-sidebar {
  min-height: 280px;
  margin-top: 0;
}

.ad-title {
  min-height: 96px;
}

.ad-inline {
  min-height: 140px;
}

.article-shell {
  position: relative;
}

.article-ad-rails {
  position: absolute;
  inset: 0;
  width: min(100%, 1540px);
  margin: 0 auto;
  pointer-events: none;
}

.article-ad-rail {
  position: sticky;
  top: 118px;
  z-index: 2;
  width: 160px;
  min-height: 420px;
  pointer-events: auto;
}

.article-ad-rail-left {
  float: left;
  margin-left: max(14px, calc((100vw - var(--container)) / 2 - 190px));
}

.article-ad-rail-right {
  float: right;
  margin-right: max(14px, calc((100vw - var(--container)) / 2 - 190px));
}

.ad-rail-slot {
  width: 160px;
  min-height: 560px;
  margin: 0;
  padding: 6px;
}

.sticky-bottom-ad {
  position: fixed;
  left: 50%;
  bottom: 12px;
  z-index: 60;
  width: min(728px, calc(100% - 24px));
  min-height: 86px;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 18px 48px rgba(16, 24, 40, 0.22);
}

.sticky-bottom-ad.is-hidden,
.ad-break:not(.is-visible) {
  display: none;
}

.sticky-bottom-ad .ad-slot {
  min-height: 78px;
  margin: 0;
  padding: 8px 42px 8px 10px;
  border: 0;
  background: transparent;
}

.ad-close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: #273544;
  cursor: pointer;
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
}

.ad-break {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(12, 18, 27, 0.54);
}

.ad-break-panel {
  position: relative;
  width: min(820px, 100%);
  min-height: 430px;
  padding: 46px 18px 18px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
}

.ad-break-title {
  position: absolute;
  top: 16px;
  left: 18px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.ad-break-slot {
  min-height: 340px;
  margin: 0;
}

.has-sticky-ad {
  padding-bottom: 118px;
}

.page-head {
  padding: 42px 0 24px;
}

.page-head p,
.category-link {
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.page-head h1 {
  margin: 4px 0;
  font-size: clamp(34px, 6vw, 64px);
  line-height: 1.04;
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  margin-top: 18px;
  padding: 0 16px;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  font-weight: 800;
}

.empty-state {
  padding: 34px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.empty-state h1,
.empty-state h2 {
  margin: 0 0 8px;
}

.empty-state.compact {
  margin-top: 18px;
  box-shadow: none;
}

.tool-panel {
  margin-bottom: 28px;
}

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

.calculator-card {
  display: grid;
  gap: 16px;
  min-width: 0;
  padding: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.health-tool-panel .calculator-card {
  grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.2fr) auto;
  align-items: end;
}

.tool-card-head {
  display: grid;
  gap: 4px;
}

.tool-card-head span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.tool-card-head h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.18;
}

.tool-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.tool-fields label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: #334050;
  font-size: 13px;
  font-weight: 900;
}

.tool-fields input,
.tool-fields select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0 12px;
  background: #fff;
  color: var(--text);
  font-weight: 700;
}

.tool-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  width: fit-content;
  padding: 0 16px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  font-weight: 900;
}

.tool-result {
  display: none;
  min-height: 50px;
  padding: 12px;
  border: 1px solid #cfe2ff;
  border-radius: 8px;
  background: #f1f7ff;
  color: #233140;
  font-size: 14px;
  font-weight: 800;
}

.tool-result.is-visible {
  display: block;
}

.tool-result strong {
  color: var(--accent);
}

.article-shell {
  padding-bottom: 40px;
}

.article-header {
  max-width: 900px;
  padding: 42px 0 18px;
}

.article-header h1 {
  margin: 10px 0;
  font-size: clamp(34px, 6vw, 66px);
  line-height: 1.02;
  letter-spacing: 0;
}

.article-header > p {
  max-width: 760px;
  color: #435160;
  font-size: 20px;
  line-height: 1.45;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.article-meta a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.article-hero {
  margin: 20px 0 0;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border);
}

.article-hero img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
}

.article-body {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: clamp(20px, 4vw, 44px);
}

.article-body p,
.article-body li {
  color: #233140;
  font-size: 19px;
  line-height: 1.78;
}

.article-body h2 {
  margin: 34px 0 10px;
  font-size: 30px;
  line-height: 1.18;
}

.inline-related {
  display: grid;
  gap: 4px;
  margin: 24px 0;
  padding: 16px;
  border-left: 4px solid var(--accent);
  background: #f1f6fd;
  border-radius: 8px;
}

.inline-related span {
  color: var(--accent);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.article-inline-media {
  margin: 26px 0;
}

.article-inline-media img {
  width: 100%;
  border-radius: 8px;
}

.article-inline-media figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}

.similar-section {
  margin-top: 34px;
}

.article-stream-shell {
  padding-bottom: 12px;
}

.stream-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 10px auto 2px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.stream-heading::before,
.stream-heading::after {
  content: "";
  height: 1px;
  flex: 1;
  background: var(--border);
}

.stream-article {
  margin-top: 26px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.stream-article .article-header {
  padding-top: 30px;
}

.stream-layout {
  display: grid;
  grid-template-columns: minmax(0, 900px);
  justify-content: center;
}

.stream-loader {
  display: none;
  min-height: 80px;
}

.stream-loader.is-loading {
  display: grid;
  place-items: center;
}

.stream-loader.is-loading::before {
  content: "";
  width: 30px;
  height: 30px;
  border: 3px solid #d3e5fb;
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: stream-spin 0.85s linear infinite;
}

.stream-sentinel {
  width: 100%;
  height: 1px;
}

@keyframes stream-spin {
  to {
    transform: rotate(360deg);
  }
}

.site-footer {
  margin-top: 52px;
  padding: 46px 0 24px;
  background: #0f1720;
  color: #fff;
}

.footer-shell {
  display: grid;
  grid-template-columns: minmax(240px, 1.25fr) repeat(3, minmax(0, 1fr));
  gap: 34px;
  align-items: start;
}

.footer-brand {
  display: grid;
  gap: 14px;
  max-width: 340px;
}

.footer-brandline {
  color: #fff;
}

.footer-brandline .brand-mark {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
  color: #86b8ff;
}

.footer-column {
  display: grid;
  gap: 10px;
}

.footer-column h2 {
  margin: 0 0 4px;
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.footer-column a {
  color: #d9e7f3;
  font-size: 14px;
  font-weight: 700;
}

.footer-column a:hover {
  color: #fff;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 34px;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: #9fb0c0;
  font-size: 13px;
}

.footer-bottom span:last-child {
  text-align: right;
}

.footer-grid a {
  display: inline-block;
  color: #d9e7f3;
  font-weight: 700;
}

.admin-body {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  min-height: 100vh;
  background: #eef3f7;
}

.admin-sidebar {
  position: sticky;
  top: 0;
  align-self: start;
  min-height: 100vh;
  padding: 20px;
  background: #121820;
  color: #fff;
}

.admin-brand {
  color: #fff;
  margin-bottom: 24px;
}

.admin-sidebar nav {
  display: grid;
  gap: 8px;
  margin: 20px 0;
}

.admin-sidebar nav a,
.plain-button {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #dce7ef;
  font-weight: 800;
  cursor: pointer;
}

.admin-sidebar nav a:hover,
.plain-button:hover {
  background: rgba(255, 255, 255, 0.08);
}

.admin-main {
  padding: 28px;
}

.admin-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  margin-bottom: 20px;
}

.admin-head h1 {
  margin: 0;
  font-size: 34px;
}

.admin-head p {
  margin: 4px 0 0;
  color: var(--muted);
}

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

.metric-card,
.admin-panel,
.login-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.metric-card {
  padding: 18px;
}

.metric-card span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.metric-card strong {
  display: block;
  margin-top: 6px;
  font-size: 34px;
}

.admin-panel {
  padding: 18px;
  overflow: hidden;
}

.admin-panel + .admin-panel {
  margin-top: 20px;
}

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

.panel-head h2,
.admin-panel h2 {
  margin: 0;
}

.panel-note {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.panel-head a,
.panel-head button,
.head-actions button,
.table-actions button,
.login-card button {
  min-height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.admin-table th,
.admin-table td {
  padding: 12px;
  border-top: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}

.admin-table th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
}

.admin-thumb {
  display: block;
  width: 54px;
  height: 42px;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #edf3f8;
}

.status-dot {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 8px;
  background: #edf3f8;
  color: #536273;
  font-size: 12px;
  font-weight: 900;
}

.status-dot.published,
.status-dot.complete {
  background: #e6f6ef;
  color: #0b7e4d;
}

.status-dot.suspended,
.status-dot.fallback {
  background: #fff0dc;
  color: #8a570e;
}

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

.translation-editor {
  border-top: 1px solid var(--border);
  padding: 14px 0;
}

.translation-editor summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  cursor: pointer;
}

.translation-editor label,
.login-card label {
  display: grid;
  gap: 6px;
  margin-top: 14px;
  color: #334050;
  font-size: 13px;
  font-weight: 900;
}

.translation-editor input,
.translation-editor textarea,
.login-card input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text);
  background: #fff;
  font-weight: 500;
}

.inspector {
  position: sticky;
  top: 20px;
}

.media-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-top: 1px solid var(--border);
  font-size: 13px;
}

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

.category-list span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 8px;
  background: #eef4f8;
  color: #314050;
  font-weight: 800;
}

.login-body {
  min-height: 100vh;
  background: #eef3f7;
}

.login-screen {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 24px;
}

.login-card {
  width: min(420px, 100%);
  padding: 26px;
  box-shadow: var(--shadow);
}

.login-card h1 {
  margin: 22px 0 10px;
}

.form-error {
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff0f0;
  color: var(--danger);
  font-weight: 800;
}

@media (max-width: 980px) {
  .header-inner {
    grid-template-columns: 1fr auto;
  }

  .top-nav {
    grid-column: 1 / -1;
    order: 3;
    padding-bottom: 12px;
  }

  .top-nav a {
    min-height: 34px;
  }

  .home-grid,
  .content-with-sidebar,
  .article-layout,
  .editor-grid {
    grid-template-columns: 1fr;
  }

  .sidebar,
  .inspector {
    position: static;
  }

  .story-grid,
  .story-grid-wide,
  .story-rail,
  .metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-shell {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-brand {
    max-width: none;
  }

  .admin-body {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    position: static;
    min-height: auto;
  }

  .article-ad-rails {
    display: none;
  }

  .tool-grid,
  .health-tool-panel .calculator-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 20px, var(--container));
  }

  .header-inner {
    gap: 12px;
  }

  .brand {
    font-size: 20px;
  }

  .locale-switcher select {
    max-width: 168px;
  }

  .lead-story a,
  .article-body,
  .empty-state {
    padding: 16px;
  }

  .story-grid,
  .story-grid-wide,
  .story-rail,
  .metric-grid {
    grid-template-columns: 1fr;
  }

  .zodiac-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .zodiac-section {
    padding: 14px;
  }

  .zodiac-card {
    grid-template-columns: 38px minmax(0, 1fr);
    min-height: 72px;
    padding: 10px;
  }

  .zodiac-icon {
    width: 38px;
    height: 38px;
    font-size: 19px;
  }

  .article-header > p {
    font-size: 18px;
  }

  .article-body p,
  .article-body li {
    font-size: 18px;
    line-height: 1.72;
  }

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

  .calculator-card {
    padding: 14px;
  }

  .sticky-bottom-ad {
    bottom: 8px;
    width: calc(100% - 16px);
  }

  .ad-break-panel {
    min-height: 360px;
    padding: 44px 12px 12px;
  }

  .ad-break-slot {
    min-height: 280px;
  }

  .footer-shell,
  .footer-bottom,
  .admin-head {
    display: grid;
  }

  .footer-shell {
    grid-template-columns: 1fr;
  }

  .footer-bottom span:last-child {
    text-align: left;
  }

  .admin-main {
    padding: 16px;
  }
}
