:root {
  color-scheme: light;
  --bg: #f5f6f7;
  --surface: #ffffff;
  --surface-strong: #111827;
  --text: #172033;
  --muted: #647084;
  --line: #dfe4ea;
  --brand: #d7212f;
  --brand-dark: #961622;
  --accent: #0f766e;
  --gold: #b8892f;
  --shadow: 0 22px 60px rgba(18, 27, 43, 0.12);
  --radius: 8px;
  --max-width: 1180px;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #10151f;
  --surface: #171d29;
  --surface-strong: #f6f7f9;
  --text: #f4f6f8;
  --muted: #a8b2c2;
  --line: #2b3547;
  --brand: #ff4d5e;
  --brand-dark: #ff8793;
  --accent: #38b2a6;
  --gold: #d8aa52;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.32);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.6;
}

.article-main {
  background:
    linear-gradient(90deg, rgba(17, 24, 39, 0.035) 0, rgba(17, 24, 39, 0) 17%, rgba(17, 24, 39, 0) 83%, rgba(17, 24, 39, 0.035) 100%),
    var(--bg);
  padding-bottom: 28px;
}

body.menu-open,
body.search-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.top-strip,
.masthead,
.category-bar {
  width: min(100% - 32px, var(--max-width));
  margin: 0 auto;
}

.top-strip {
  min-height: 38px;
  display: grid;
  align-items: center;
  justify-content: start;
  color: var(--muted);
  font-size: 0.82rem;
  border-bottom: 1px solid var(--line);
}

.top-strip p {
  margin: 0;
  font-weight: 700;
}

.nav-links a:hover,
.footer-bottom a:hover,
.footer-categories a:hover,
.ranked-list a:hover {
  color: var(--brand);
}

.masthead {
  min-height: 122px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 44px;
  padding: 24px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
  min-width: 168px;
}

.brand-image {
  width: 220px;
  max-height: 76px;
  object-fit: contain;
}

.brand-fallback {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  position: relative;
  width: 44px;
  height: 38px;
  color: var(--surface-strong);
  font-weight: 800;
  letter-spacing: 0;
  overflow: hidden;
  text-indent: -999px;
}

.brand-mark::before,
.brand-mark::after {
  content: "";
  position: absolute;
  top: 6px;
  width: 6px;
  height: 30px;
  background: var(--surface-strong);
  transform: skewX(-24deg);
}

.brand-mark::before {
  left: 10px;
  box-shadow: 10px 0 0 var(--surface-strong);
}

.brand-mark::after {
  right: 7px;
  height: 24px;
  background: var(--brand);
}

.brand strong {
  display: block;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height: 1;
  color: var(--surface-strong);
  letter-spacing: -0.04em;
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: clamp(0.62rem, 1vw, 0.78rem);
  font-weight: 700;
  letter-spacing: 0.16em;
  margin-top: 4px;
}

.ad-space {
  flex: 1;
  max-width: 728px;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 18px 26px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(8, 13, 22, 0.88), rgba(8, 13, 22, 0.35)),
    url("https://images.unsplash.com/photo-1497366754035-f200968a6e72?auto=format&fit=crop&w=1200&q=80");
  background-position: center;
  background-size: cover;
  color: #fff;
}

.ad-space span,
.ad-space small {
  display: block;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ad-space strong {
  display: block;
  margin: 2px 0;
  font-size: clamp(1.05rem, 2vw, 1.4rem);
  line-height: 1.1;
}

.ad-space em {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: #fff;
  font-style: normal;
  font-size: 0.84rem;
  font-weight: 900;
  text-transform: uppercase;
}

.nav-panel {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 22px;
  flex: 1;
}

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 2vw, 24px);
  margin: 0;
  padding: 0;
  font-size: 0.94rem;
  font-weight: 700;
}

.search-trigger,
.button,
.newsletter-form button,
.search-box button[type="submit"] {
  min-height: 42px;
  border: 0;
  border-radius: var(--radius);
  font-weight: 800;
  transition: transform 160ms ease, background-color 160ms ease, color 160ms ease;
}

.search-trigger {
  padding: 0 14px;
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}

.search-trigger:hover,
.button:hover,
.newsletter-form button:hover,
.search-box button[type="submit"]:hover {
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 44px;
  aspect-ratio: 1;
  padding: 9px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  align-items: center;
  justify-content: center;
  gap: 5px;
  box-shadow: 0 8px 24px rgba(18, 27, 43, 0.08);
  transition: background-color 160ms ease, border-color 160ms ease;
}

.menu-toggle span:not(.visually-hidden) {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: transform 160ms ease, opacity 160ms ease;
}

.menu-toggle[aria-expanded="true"] {
  border-color: color-mix(in srgb, var(--brand) 45%, var(--line));
  background: color-mix(in srgb, var(--brand) 8%, var(--surface));
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.category-bar {
  position: relative;
}

.category-menu {
  min-height: 54px;
  display: flex;
  align-items: stretch;
  justify-content: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.category-menu > li {
  display: flex;
  align-items: stretch;
}

.category-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 54px;
  padding: 0 clamp(10px, 1.8vw, 18px);
  border: 0;
  background: transparent;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 900;
  text-transform: uppercase;
  white-space: nowrap;
}

.category-tools {
  margin-left: auto;
  align-items: center;
  gap: 8px;
}

.category-tools .search-trigger {
  min-height: 36px;
  padding: 0 11px;
  font-size: 0.82rem;
}

.category-link span {
  display: none;
  color: var(--muted);
  font-size: 0.68rem;
}

.category-link::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 0;
  height: 3px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 160ms ease;
}

.category-link:hover,
.category-link:focus-visible,
.category-link.is-active {
  color: var(--brand);
}

.category-link:hover::after,
.category-link:focus-visible::after,
.category-link.is-active::after,
.has-mega.is-open > .category-link::after,
.has-mega:hover > .category-link::after,
.has-mega:focus-within > .category-link::after {
  transform: scaleX(1);
}

.has-mega {
  position: static;
}

.mega-menu {
  display: none;
  position: absolute;
  left: 50%;
  top: 100%;
  z-index: 25;
  width: min(100vw - 32px, var(--max-width));
  grid-template-columns: 190px 1fr;
  gap: 24px;
  padding: 22px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
  transition: opacity 160ms ease, transform 160ms ease;
}

.has-mega:hover > .mega-menu,
.has-mega:focus-within > .mega-menu,
.has-mega.is-open > .mega-menu {
  display: none;
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}

.mega-tabs {
  display: grid;
  align-content: start;
  gap: 2px;
  border-right: 1px solid var(--line);
  padding-right: 18px;
}

.mega-tabs a {
  display: block;
  padding: 10px 0;
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 800;
}

.mega-tabs a:hover,
.mega-tabs a.is-active {
  color: var(--brand);
}

.mega-stories {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.mega-stories article {
  min-width: 0;
  transition: opacity 160ms ease, transform 160ms ease;
}

.mega-stories article.is-hidden {
  display: none;
}

.mega-stories img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--line);
}

.mega-stories span {
  display: inline-block;
  margin-top: 9px;
  padding: 3px 7px;
  background: var(--surface-strong);
  color: var(--bg);
  font-size: 0.66rem;
  font-weight: 900;
}

.mega-stories h3 {
  margin: 8px 0 4px;
  color: var(--surface-strong);
  font-size: 1rem;
  line-height: 1.26;
}

.mega-stories time {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.content-grid,
.ad-slot-wide,
.insight-band,
.footer-grid {
  width: min(100% - 32px, var(--max-width));
  margin-inline: auto;
}

.search-status {
  width: min(100% - 32px, var(--max-width));
  margin: 0 auto 22px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--brand);
}

.search-status[hidden] {
  display: none;
}

.search-status p {
  margin: 0;
  color: var(--text);
  font-size: 0.94rem;
  font-weight: 800;
}

.search-status button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: transparent;
  color: var(--text);
  font-weight: 800;
}

.single-post-page,
.post-after-content {
  width: min(100% - 32px, 760px);
  margin: 34px auto;
}

.single-post-page {
  background: transparent;
  padding: 0;
  border: 0;
  box-shadow: none;
}

.post-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 0.78rem;
}

.post-breadcrumb a {
  color: var(--muted);
}

.post-breadcrumb a:hover {
  color: var(--brand);
}

.post-category-row {
  display: flex;
  gap: 6px;
  margin-bottom: 8px;
}

.single-post-category {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  background: var(--brand);
  color: var(--bg);
  font-size: 0.64rem;
  font-weight: 900;
  text-transform: uppercase;
}

.single-post-header h1 {
  max-width: 720px;
  margin: 0 0 14px;
  color: var(--surface-strong);
  font-family: Arial, Helvetica, sans-serif;
  font-size: clamp(2.35rem, 4.8vw, 4rem);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: 0;
}

.article-info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.single-post-meta {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.share-icons {
  display: flex;
  gap: 7px;
}

.share-icons a {
  display: grid;
  place-items: center;
  min-width: 34px;
  height: 30px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 0.7rem;
  font-weight: 900;
}

.single-post-media {
  margin: 0 0 28px;
  background: var(--line);
}

.single-post-media img,
.article-inline-image {
  width: 100%;
  object-fit: cover;
  background: var(--line);
}

.single-post-media img {
  aspect-ratio: 16 / 9;
}

.single-post-content {
  padding: 0;
}

.single-post-body {
  display: grid;
  gap: 18px;
  color: #334155;
  font-size: 1.02rem;
  line-height: 1.82;
}

.single-post-body h2 {
  margin: 14px 0 -4px;
  color: var(--surface-strong);
  font-size: 1.18rem;
  line-height: 1.35;
}

.single-post-body p {
  margin: 0;
}

.single-post-lead {
  color: #1f2937;
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.75;
}

.article-inline-image {
  margin: 16px 0;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
}

.post-after-content {
  display: grid;
  gap: 28px;
  padding: 0;
  border-top: 1px solid var(--line);
}

.previous-article {
  display: grid;
  gap: 6px;
  padding: 18px 0 0;
  color: var(--muted);
  font-size: 0.78rem;
}

.previous-article a {
  color: var(--surface-strong);
  font-weight: 800;
}

.author-box {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 16px;
  min-height: 112px;
  padding: 22px;
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 12px 36px rgba(17, 24, 39, 0.06);
}

.author-avatar {
  display: grid;
  place-items: center;
  width: 64px;
  aspect-ratio: 1;
  background: var(--surface-strong);
  color: var(--bg);
  font-size: 1.7rem;
  font-weight: 900;
}

.author-box h2 {
  margin: 4px 0 8px;
  color: var(--surface-strong);
  font-size: 1rem;
}

.author-box p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.tab-heading {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid #4aa3df;
  margin-bottom: 16px;
}

.tab-heading span {
  min-height: 24px;
  padding: 0 9px;
  display: inline-flex;
  align-items: center;
  background: var(--surface-strong);
  color: var(--bg);
  font-size: 0.62rem;
  font-weight: 900;
  text-transform: uppercase;
}

.related-mini {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 14px;
  width: 100%;
  padding: 0;
}

.related-mini img {
  width: 120px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.related-mini h3 {
  margin: 0;
  color: var(--surface-strong);
  font-size: 0.95rem;
  line-height: 1.3;
}

.related-mini time {
  color: var(--muted);
  font-size: 0.68rem;
}

.comment-form {
  display: grid;
  gap: 10px;
  padding: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.comment-form h2 {
  margin: 0 0 6px;
  color: var(--surface-strong);
  font-size: 1.05rem;
  text-transform: uppercase;
}

.comment-form label {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
}

.comment-form textarea,
.comment-form input:not([type="checkbox"]) {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  padding: 9px;
  min-height: 40px;
  outline: none;
}

.comment-form textarea:focus,
.comment-form input:not([type="checkbox"]):focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 12%, transparent);
}

.remember-me {
  display: flex;
  align-items: center;
  gap: 8px;
}

.comment-form button {
  width: fit-content;
  min-height: 40px;
  padding: 0 16px;
  border: 0;
  background: var(--surface-strong);
  color: var(--bg);
  font-weight: 900;
}

.showcase-card {
  position: relative;
  overflow: hidden;
  min-width: 0;
  background: #e8e8e8;
  color: #fff;
}

.showcase-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.showcase-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.04) 58%);
}

.showcase-card div {
  position: absolute;
  left: clamp(16px, 2.4vw, 24px);
  right: clamp(16px, 2.4vw, 24px);
  bottom: clamp(14px, 2.4vw, 24px);
  z-index: 1;
}

.showcase-card span {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 7px;
  background: var(--surface-strong);
  color: var(--bg);
  font-size: 0.66rem;
  font-weight: 900;
  text-transform: uppercase;
}

.showcase-card h1,
.showcase-card h2 {
  margin: 8px 0 0;
  max-width: 20ch;
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.16;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.45);
}

.showcase-card h1 {
  font-size: clamp(1.85rem, 3vw, 2.45rem);
}

.showcase-card h2 {
  font-size: clamp(1.05rem, 2vw, 1.55rem);
}

.showcase-card p {
  margin: 12px 0 0;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 800;
}

.post-is-hidden {
  display: none;
}

.managed-posts {
  width: min(100% - 32px, var(--max-width));
  margin: 0 auto 38px;
  display: grid;
  gap: 34px;
}

.managed-group {
  display: grid;
  gap: 18px;
}

.managed-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 2px solid var(--line);
}

.managed-heading .mag-heading {
  flex: 1;
  border-bottom: 0;
}

.managed-heading a,
.category-see-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--surface-strong);
  font-size: 0.82rem;
  font-weight: 900;
  white-space: nowrap;
}

.managed-post-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.managed-post-card {
  display: grid;
  background: var(--surface);
  border: 1px solid var(--line);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.managed-post-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.managed-post-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.managed-post-card div {
  padding: 14px;
}

.managed-post-card h2 {
  margin: 7px 0 8px;
  color: var(--surface-strong);
  font-size: 1rem;
  line-height: 1.25;
}

.managed-post-card p {
  margin: 0 0 10px;
  color: var(--muted);
  font-size: 0.86rem;
}

.admin-shell {
  width: min(100% - 28px, 1120px);
  margin: 0 auto;
  padding: 26px 0 48px;
}

.admin-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.admin-header h1 {
  margin: 0;
  color: var(--surface-strong);
  font-size: clamp(1.7rem, 3vw, 2.35rem);
}

.admin-header p {
  margin: 0;
  color: var(--muted);
}

.admin-header-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.admin-header-actions a,
.admin-header-actions button,
.admin-form button,
.admin-row-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: var(--surface-strong);
  color: var(--bg);
  font-weight: 900;
  font-size: 0.82rem;
}

.admin-header-actions .reset-posts,
.admin-form .clear-form,
.admin-row-actions button[data-delete] {
  background: var(--surface);
  color: var(--brand);
  border-color: color-mix(in srgb, var(--brand) 30%, var(--line));
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.admin-stats article {
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.admin-stats span {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-stats strong {
  display: block;
  margin-top: 2px;
  color: var(--surface-strong);
  font-size: 1.15rem;
}

.admin-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 340px;
  gap: 18px;
  align-items: start;
}

.admin-sidebar,
.admin-form,
.admin-posts {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 16px;
}

.admin-sidebar {
  position: sticky;
  top: 20px;
  display: grid;
  gap: 8px;
}

.admin-sidebar-title {
  color: var(--surface-strong);
  font-size: 0.86rem;
  font-weight: 900;
  text-transform: uppercase;
}

.admin-category-nav {
  display: grid;
  gap: 6px;
}

.admin-category-filter {
  width: 100%;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  text-align: left;
  font-weight: 800;
}

.admin-category-filter span,
.admin-category-filter small {
  display: block;
}

.admin-category-filter small {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 700;
}

.admin-category-filter:hover,
.admin-category-filter.is-active {
  background: color-mix(in srgb, var(--brand) 8%, transparent);
  border-color: color-mix(in srgb, var(--brand) 28%, var(--line));
  color: var(--brand);
}

.admin-form {
  position: sticky;
  top: 20px;
  display: grid;
  gap: 8px;
}

.admin-form h2 {
  margin: 0;
  color: var(--surface-strong);
  font-size: 1.1rem;
}

.admin-form label {
  color: var(--surface-strong);
  font-size: 0.78rem;
  font-weight: 900;
}

.admin-form input,
.admin-form select,
.admin-form textarea,
.admin-filters input,
.admin-filters select {
  width: 100%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--text);
  padding: 9px;
}

.admin-form input[type="file"] {
  padding: 8px;
  background: color-mix(in srgb, var(--line) 26%, #fff);
}

.admin-field-note {
  margin: -3px 0 3px;
  color: var(--muted);
  font-size: 0.75rem;
  line-height: 1.35;
}

.admin-image-preview {
  width: 100%;
  max-height: 150px;
  aspect-ratio: 16 / 8;
  object-fit: cover;
  border: 1px solid var(--line);
}

.admin-form-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.admin-section-title h2 {
  margin: 0;
  color: var(--surface-strong);
  font-size: 1.15rem;
}

.admin-section-title p {
  margin: 4px 0 18px;
  color: var(--muted);
}

.admin-filters {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  align-items: end;
  margin: 12px 0 16px;
}

.admin-filters label {
  display: grid;
  gap: 6px;
  color: var(--surface-strong);
  font-size: 0.78rem;
  font-weight: 900;
}

.admin-post-list {
  display: grid;
  gap: 16px;
}

.admin-category-block {
  display: grid;
  gap: 8px;
}

.admin-category-block h3 {
  margin: 0;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  color: var(--surface-strong);
  font-size: 0.95rem;
}

.admin-category-block h3 span {
  float: right;
  color: var(--brand);
}

.admin-post-row {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 10px 0;
  border: 1px solid var(--line);
  border-width: 0 0 1px;
}

.admin-post-row img {
  width: 72px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.admin-post-row h4 {
  margin: 0 0 3px;
  color: var(--surface-strong);
}

.admin-post-row p {
  margin: 0 0 5px;
  color: var(--muted);
  font-size: 0.82rem;
}

.admin-post-row span,
.empty-category {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.admin-row-actions {
  display: flex;
  gap: 6px;
}

.ad-slot {
  display: grid;
  place-items: center;
  align-content: center;
  min-height: 90px;
  padding: 16px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--surface) 74%, transparent), color-mix(in srgb, var(--line) 68%, transparent));
  border: 1px dashed color-mix(in srgb, var(--muted) 52%, transparent);
  color: var(--muted);
  text-align: center;
}

.ad-slot span {
  color: var(--brand);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.ad-slot strong {
  display: block;
  margin-top: 3px;
  color: var(--surface-strong);
  font-size: 0.98rem;
}

.ad-slot small {
  display: block;
  margin-top: 2px;
  font-size: 0.78rem;
}

.ad-slot-wide {
  margin-bottom: 34px;
}

.ad-slot-sidebar {
  min-height: 250px;
}

.eyebrow,
.category,
.newsletter-card span {
  color: var(--brand);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
}

.newsletter-form button,
.search-box button[type="submit"] {
  background: var(--brand);
  color: #fff;
}

.button.secondary {
  border: 1px solid color-mix(in srgb, var(--surface-strong) 25%, transparent);
  background: var(--surface-strong);
  color: var(--bg);
}

.side-panel,
.newsletter-card {
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}

.newsletter-card h2,
.insight-band h2,
.search-box h2,
.footer-grid h2 {
  margin: 4px 0 0;
  color: var(--surface-strong);
  line-height: 1.12;
}

.newsletter-card h2 {
  font-size: clamp(1.45rem, 2.3vw, 2.1rem);
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 34px;
  padding: 18px 0 42px;
  align-items: start;
}

.main-feed {
  display: grid;
  gap: 34px;
}

.mag-section {
  display: grid;
  gap: 18px;
}

.mag-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 30px;
  border-bottom: 2px solid var(--line);
}

.section-more-link {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.mag-heading span,
.mag-heading a,
.widget-title span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  background: var(--surface-strong);
  color: var(--bg);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.mag-heading.yellow {
  border-color: #f4c400;
}

.mag-heading.yellow span,
.mag-heading.yellow a {
  background: #f4c400;
  color: #111827;
}

.mag-heading.green {
  border-color: #23a455;
}

.mag-heading.green span,
.mag-heading.green a {
  background: #23a455;
}

.mag-heading.blue {
  border-color: #3289c8;
}

.mag-heading.blue span,
.mag-heading.blue a {
  background: #3289c8;
}

.mag-heading.red {
  border-color: #e12929;
}

.mag-heading.red span {
  background: #e12929;
}

.mag-heading.dark {
  border-color: #1f2937;
}

.mag-heading.cyan {
  border-color: #1ea7d4;
}

.mag-heading.cyan span,
.mag-heading.cyan a {
  background: #1ea7d4;
}

.mag-heading.olive {
  border-color: #687f2a;
}

.mag-heading.olive span,
.mag-heading.olive a {
  background: #687f2a;
}

.mag-heading.gray {
  border-color: #7b7f87;
}

.mag-heading.gray span,
.mag-heading.gray a {
  background: #7b7f87;
}

.dont-miss-layout,
.two-column-posts {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 24px;
  align-items: start;
}

.two-column-posts {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mag-post,
.small-card,
.list-post,
.mini-post,
.review-card,
.overlay-post,
.category-column a {
  min-width: 0;
}

.mag-post img,
.small-card img,
.review-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--line);
}

.mag-post h2,
.list-post h2 {
  margin: 8px 0 6px;
  color: var(--surface-strong);
  font-size: clamp(1.12rem, 2vw, 1.45rem);
  line-height: 1.18;
}

.lead-post h2 {
  font-size: clamp(1.45rem, 2.8vw, 2.1rem);
}

.mag-post p,
.list-post p,
.review-card p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.compact-list,
.thumb-list,
.story-list {
  display: grid;
  gap: 16px;
}

.mini-post {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 12px;
  align-items: start;
}

.mini-post img {
  width: 96px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: var(--line);
}

.mini-post h3,
.small-card h3,
.review-card h3,
.category-column a {
  margin: 0;
  color: var(--surface-strong);
  font-size: 0.96rem;
  line-height: 1.28;
}

.mini-post time,
.small-card time {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
}

.three-card-row,
.category-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.small-card {
  display: grid;
  gap: 8px;
}

.list-post {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.list-post img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.in-feed-ad {
  width: 100%;
  margin: 0;
}

.category-column {
  display: grid;
  gap: 13px;
}

.category-column a {
  display: block;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  font-weight: 800;
}

.overlay-post {
  position: relative;
  min-height: 180px;
  overflow: hidden;
  background: var(--surface-strong);
}

.overlay-post img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.overlay-post::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.12));
}

.overlay-post h3 {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  z-index: 1;
  margin: 0;
  color: #fff;
  font-size: 1rem;
  line-height: 1.24;
}

.news-card {
  display: grid;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.news-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.news-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
}

.news-card div {
  padding: 18px;
}

.news-card h3 {
  margin: 8px 0;
  color: var(--surface-strong);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.45rem;
  line-height: 1.16;
}

.news-card p {
  margin: 0 0 14px;
  color: var(--muted);
}

.news-card time,
.post-meta {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.post-meta span::before {
  content: "";
  display: inline-block;
  width: 4px;
  aspect-ratio: 1;
  margin: 0 8px 2px 0;
  border-radius: 50%;
  background: var(--muted);
}

.category-main {
  width: min(100% - 32px, var(--max-width));
  margin: 0 auto;
  padding: 34px 0 48px;
}

.category-page-hero {
  display: grid;
  gap: 16px;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.category-page-hero h1 {
  margin: 0;
  color: var(--surface-strong);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.5rem, 5vw, 4.4rem);
  line-height: 0.98;
}

.category-page-hero p {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.category-tabs a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.86rem;
  font-weight: 800;
}

.category-tabs a:hover,
.category-tabs a:focus-visible,
.category-tabs a.is-active {
  background: var(--surface-strong);
  color: var(--bg);
}

.category-post-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.category-post-card {
  cursor: pointer;
}

.category-see-more {
  margin: 26px auto 0;
  min-height: 42px;
  background: var(--surface-strong);
  color: var(--bg);
  cursor: pointer;
}

.sidebar {
  position: sticky;
  top: 136px;
  display: grid;
  gap: 22px;
}

.side-panel,
.newsletter-card {
  padding: 22px;
}

.widget-title {
  margin-bottom: 14px;
  border-bottom: 2px solid var(--surface-strong);
}

.social-panel {
  display: grid;
  gap: 10px;
}

.social-panel a {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
  min-height: 42px;
  padding: 0 10px;
  background: color-mix(in srgb, var(--line) 42%, transparent);
  font-size: 0.86rem;
  font-weight: 800;
}

.social-panel strong {
  color: var(--surface-strong);
}

.social-panel em {
  color: var(--brand);
  font-style: normal;
  text-transform: uppercase;
  font-size: 0.72rem;
}

.review-card {
  display: grid;
  gap: 10px;
}

.ranked-list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: popular;
}

.ranked-list li {
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 12px;
  padding: 15px 0;
  border-top: 1px solid var(--line);
  counter-increment: popular;
}

.ranked-list li::before {
  content: counter(popular);
  display: grid;
  place-items: center;
  width: 34px;
  aspect-ratio: 1;
  border-radius: 50%;
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  color: var(--accent);
  font-weight: 900;
}

.ranked-list a {
  font-weight: 800;
  line-height: 1.32;
}

.newsletter-card {
  background: var(--surface-strong);
  color: var(--bg);
}

.newsletter-card h2 {
  color: var(--bg);
}

.newsletter-card p {
  color: color-mix(in srgb, var(--bg) 76%, transparent);
}

.newsletter-form {
  display: grid;
  gap: 10px;
}

.newsletter-form input,
.search-box input {
  min-height: 46px;
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 14px;
  background: var(--surface);
  color: var(--text);
  outline: none;
}

.newsletter-form input:focus,
.search-box input:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 16%, transparent);
}

.insight-band {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(260px, 1fr) auto;
  align-items: center;
  gap: 28px;
  margin-bottom: 46px;
  padding: clamp(24px, 4vw, 42px);
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}

.insight-band h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.8rem, 3vw, 3rem);
}

.insight-band p {
  margin: 0;
  color: var(--muted);
}

.site-footer {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(rgba(4, 7, 12, 0.88), rgba(4, 7, 12, 0.9)),
    url("https://images.unsplash.com/photo-1518005020951-eccb494ad742?auto=format&fit=crop&w=1800&q=80") center / cover;
  color: #f8fafc;
  padding: 0;
}

.footer-main {
  width: min(100% - 32px, var(--max-width));
  margin: 0 auto;
  padding: clamp(38px, 6vw, 72px) 0 36px;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(280px, 1fr) minmax(240px, 0.8fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: start;
}

.footer-panel h2,
.footer-about h2,
.footer-social h2 {
  margin: 0 0 20px;
  color: #fff;
  font-size: 1.05rem;
  font-weight: 900;
  text-transform: uppercase;
}

.footer-post-list {
  display: grid;
  gap: 18px;
}

.footer-post {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  cursor: pointer;
}

.footer-post img {
  width: 110px;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.1);
}

.footer-post h3 {
  margin: 0 0 6px;
  color: #fff;
  font-size: 0.95rem;
  line-height: 1.35;
  transition: color 160ms ease;
}

.footer-post:hover h3 {
  color: #58c4ff;
}

.footer-post time {
  color: #8f98a7;
  font-size: 0.78rem;
}

.footer-categories a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  margin: 0;
  padding: 5px 0;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
}

.footer-categories strong {
  color: #fff;
  font-size: 0.92rem;
}

.footer-about-row {
  display: grid;
  grid-template-columns: 220px minmax(280px, 1fr) minmax(220px, 0.55fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: center;
  margin-top: clamp(38px, 7vw, 72px);
  padding-top: clamp(28px, 5vw, 48px);
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.footer-logo {
  display: block;
  width: min(220px, 100%);
  height: 72px;
  background: url("assets/logo-white.png") left center / contain no-repeat;
}

.footer-about p {
  max-width: 540px;
  margin: 0 0 18px;
  color: #d6dce7;
  line-height: 1.7;
}

.footer-about a {
  color: #35c5ff;
}

.footer-social > div {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.footer-social a {
  display: inline-grid;
  place-items: center;
  width: 42px;
  aspect-ratio: 1;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.footer-social a:hover {
  border-color: rgba(53, 197, 255, 0.45);
  background: rgba(53, 197, 255, 0.12);
  color: #7ddfff;
}

.footer-social svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.footer-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 14px max(16px, calc((100vw - var(--max-width)) / 2));
  background: rgba(0, 0, 0, 0.45);
  color: #bec6d4;
  font-size: 0.82rem;
}

.footer-bottom p {
  margin: 0;
}

.footer-bottom nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  justify-content: flex-end;
}

.footer-bottom a {
  color: #d7dde7;
}

.search-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: start center;
  padding: 12vh 20px 20px;
  background: rgba(7, 11, 18, 0.72);
  backdrop-filter: blur(10px);
}

.search-modal[hidden] {
  display: none;
}

.search-box {
  width: min(680px, 100%);
  position: relative;
  padding: clamp(24px, 5vw, 40px);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.search-box form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

.search-feedback {
  min-height: 24px;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}

.clear-search {
  display: none;
  min-height: 38px;
  margin-top: 8px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: transparent;
  color: var(--text);
  font-weight: 800;
}

.clear-search.is-visible {
  display: inline-flex;
  align-items: center;
}

.close-search {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: transparent;
  color: var(--text);
  font-size: 1.45rem;
  line-height: 1;
}

.to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 18;
  width: 44px;
  aspect-ratio: 1;
  border: 0;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 1.25rem;
  box-shadow: var(--shadow);
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 160ms ease, transform 160ms ease;
}

.to-top.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

@media (min-width: 1280px) {
  :root {
    --max-width: 1240px;
  }

  .content-grid {
    grid-template-columns: minmax(0, 1fr) 340px;
  }

  .brand-image {
    width: 238px;
  }
}

@media (max-width: 1180px) {
  :root {
    --max-width: 1080px;
  }

  .masthead {
    gap: 30px;
  }

  .brand-image {
    width: 190px;
  }

  .ad-space {
    max-width: 640px;
  }

  .category-link {
    padding-inline: 11px;
    font-size: 0.82rem;
  }

  .content-grid {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 26px;
  }

  .managed-post-grid {
    gap: 16px;
  }
}

@media (max-width: 1040px) {
  .masthead {
    gap: 24px;
  }

  .ad-space {
    max-width: 620px;
  }

  .brand-image {
    width: 180px;
  }

  .category-menu {
    justify-content: flex-start;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .category-menu::-webkit-scrollbar {
    display: none;
  }

  .category-link {
    font-size: 0.84rem;
  }

  .mega-menu {
    grid-template-columns: 160px 1fr;
  }

  .mega-stories {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .mega-stories article:nth-child(3) {
    display: none;
  }

  .content-grid {
    grid-template-columns: 1fr;
  }

  .two-column-posts {
    grid-template-columns: 1fr;
  }

  .dont-miss-layout {
    grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr);
  }

  .three-card-row,
  .category-columns,
  .category-post-grid,
  .managed-post-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .admin-layout {
    grid-template-columns: 1fr;
  }

  .admin-stats {
    grid-template-columns: 1fr 1fr;
  }

  .admin-form,
  .admin-sidebar {
    position: static;
  }

  .sidebar {
    position: static;
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .insight-band {
    grid-template-columns: 1fr;
  }

  .footer-top-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-categories {
    grid-column: 1 / -1;
  }

  .footer-about-row {
    grid-template-columns: minmax(180px, 0.55fr) minmax(280px, 1fr);
  }

  .footer-social {
    grid-column: 2;
  }
}

@media (max-width: 860px) {
  .masthead {
    min-height: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    padding: 18px 0;
  }

  .brand {
    justify-self: start;
  }

  .brand-image {
    width: min(230px, 68vw);
    max-height: 70px;
  }

  .ad-space {
    grid-column: 1 / -1;
    max-width: none;
    min-height: 82px;
    width: 100%;
  }

  .menu-toggle {
    display: inline-flex;
    flex-direction: column;
    align-self: center;
    justify-self: end;
  }

  .top-strip {
    min-height: 32px;
    font-size: 0.75rem;
  }

  .nav-panel {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    display: grid;
    align-content: start;
    gap: 22px;
    height: calc(100vh - 72px);
    padding: 24px;
    background: var(--surface);
    border-top: 1px solid var(--line);
    transform: translateX(100%);
    transition: transform 180ms ease;
  }

  .nav-panel.is-open {
    transform: translateX(0);
  }

  .category-bar {
    width: 100%;
    max-height: 0;
    overflow: visible;
    border-top: 0;
    opacity: 0;
    transform: translateY(-8px);
    pointer-events: none;
    transition: max-height 220ms ease, opacity 180ms ease, transform 180ms ease;
  }

  .category-bar.is-open {
    max-height: calc(100vh - 96px);
    overflow-y: auto;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .category-menu {
    display: grid;
    justify-content: stretch;
    align-items: stretch;
    min-height: 0;
    width: min(100% - 22px, var(--max-width));
    margin: 0 auto 12px;
    padding: 8px;
    overflow: visible;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 18px 50px rgba(18, 27, 43, 0.14);
  }

  .category-tools {
    position: static;
    padding-left: 0;
    background: var(--surface);
  }

  .category-menu > li {
    display: grid;
    border-bottom: 1px solid var(--line);
  }

  .category-menu > li:last-child {
    border-bottom: 0;
  }

  .category-link {
    justify-content: space-between;
    min-height: 46px;
    padding: 0 14px;
    border-radius: calc(var(--radius) - 2px);
  }

  .category-link span {
    display: none;
  }

  .category-link::after {
    left: 14px;
    right: 14px;
  }

  .category-link:hover,
  .category-link:focus-visible,
  .category-link.is-active {
    background: color-mix(in srgb, var(--brand) 8%, transparent);
  }

  .mega-menu {
    position: static;
    width: 100%;
    max-height: none;
    overflow-y: auto;
    display: none;
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 14px;
    border: 0;
    border-top: 1px solid var(--line);
    background: color-mix(in srgb, var(--bg) 62%, var(--surface));
    box-shadow: none;
    transform: none;
  }

  .has-mega:hover > .mega-menu,
  .has-mega:focus-within > .mega-menu {
    opacity: 0;
    pointer-events: none;
    transform: none;
  }

  .has-mega.is-open > .mega-menu {
    display: none;
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }

  .mega-tabs {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 0 0 12px;
    scrollbar-width: none;
  }

  .mega-tabs::-webkit-scrollbar {
    display: none;
  }

  .mega-tabs a {
    flex: 0 0 auto;
    padding: 7px 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
  }

  .mega-stories {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .mega-stories article:nth-child(3) {
    display: block;
  }

  .mega-stories article {
    display: grid;
    grid-template-columns: 96px 1fr;
    gap: 12px;
    align-items: start;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
  }

  .mega-stories article.is-hidden {
    display: none;
  }

  .mega-stories img {
    grid-row: span 3;
    aspect-ratio: 4 / 3;
  }

  .mega-stories span {
    margin-top: 0;
    width: fit-content;
  }

  .mega-stories h3 {
    margin: 0;
    font-size: 0.95rem;
  }

  .nav-links {
    display: grid;
    gap: 0;
    align-items: stretch;
    font-size: 1.18rem;
  }

  .nav-links a {
    display: block;
    padding: 16px 0;
    border-bottom: 1px solid var(--line);
  }

  .sidebar,
  .footer-grid,
  .three-card-row,
  .category-columns,
  .category-post-grid,
  .managed-post-grid {
    grid-template-columns: 1fr;
  }

  .dont-miss-layout,
  .two-column-posts {
    grid-template-columns: 1fr;
  }

  .managed-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .list-post {
    grid-template-columns: 150px 1fr;
  }

  .insight-band {
    align-items: start;
  }

  .footer-top-grid,
  .footer-about-row,
  .footer-bottom {
    grid-template-columns: 1fr;
  }

  .footer-categories,
  .footer-social {
    grid-column: auto;
  }

  .footer-logo {
    width: 190px;
  }

  .footer-bottom nav {
    justify-content: flex-start;
  }

}

@media (max-width: 560px) {
  .masthead,
  .managed-posts,
  .single-post-page,
  .post-after-content,
  .related-posts,
  .category-main,
  .content-grid,
  .search-status,
  .ad-slot-wide,
  .insight-band,
  .footer-grid,
  .copyright {
    width: min(100% - 22px, var(--max-width));
  }

  .brand {
    min-width: 0;
    justify-self: start;
  }

  .brand-image {
    width: min(190px, 58vw);
    max-height: 58px;
  }

  .brand strong {
    font-size: 2.35rem;
  }

  .brand-mark {
    width: 44px;
  }

  .brand small {
    font-size: 0.58rem;
    letter-spacing: 0.08em;
  }

  .single-post-page {
    margin-top: 22px;
  }

  .single-post-header h1 {
    font-size: clamp(2rem, 10vw, 2.8rem);
  }

  .article-info-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .single-post-body {
    font-size: 0.98rem;
  }

  .author-box,
  .related-mini {
    grid-template-columns: 1fr;
  }

  .related-mini img {
    width: 100%;
  }

  .ad-space {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
    padding: 16px;
    min-height: 118px;
  }

  .ad-space em {
    min-height: 34px;
    padding-inline: 13px;
    font-size: 0.76rem;
  }

  .mag-section {
    gap: 14px;
  }

  .mag-heading {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 8px;
  }

  .section-more-link {
    margin-left: 0;
  }

  .news-card img {
    height: 205px;
  }

  .mag-post h2,
  .lead-post h2,
  .list-post h2 {
    font-size: clamp(1.18rem, 7vw, 1.7rem);
  }

  .mag-post p,
  .list-post p,
  .review-card p {
    font-size: 0.88rem;
  }

  .list-post {
    grid-template-columns: 1fr;
  }

  .list-post img {
    aspect-ratio: 16 / 9;
  }

  .mini-post {
    grid-template-columns: 92px 1fr;
    gap: 10px;
  }

  .footer-main {
    width: min(100% - 22px, var(--max-width));
    padding: 28px 0 24px;
  }

  .footer-top-grid {
    gap: 22px;
  }

  .footer-panel,
  .footer-about,
  .footer-social {
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.045);
    backdrop-filter: blur(4px);
  }

  .footer-panel h2,
  .footer-about h2,
  .footer-social h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
  }

  .footer-panel h2::before,
  .footer-about h2::before,
  .footer-social h2::before {
    content: "";
    width: 18px;
    height: 3px;
    border-radius: 999px;
    background: #35c5ff;
  }

  .footer-post-list {
    gap: 12px;
  }

  .footer-post {
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    min-height: 74px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  }

  .footer-post:last-child {
    padding-bottom: 0;
    border-bottom: 0;
  }

  .footer-post img {
    width: 86px;
    border-radius: 4px;
  }

  .footer-post h3 {
    font-size: 0.88rem;
    line-height: 1.3;
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .footer-post time {
    font-size: 0.72rem;
  }

  .footer-categories > div {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .footer-categories a {
    min-height: 42px;
    padding: 8px 10px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    background: rgba(255, 255, 255, 0.04);
    font-size: 0.8rem;
    line-height: 1.25;
  }

  .footer-categories strong {
    min-width: 24px;
    min-height: 24px;
    display: inline-grid;
    place-items: center;
    border-radius: 999px;
    background: rgba(53, 197, 255, 0.14);
    color: #7ddfff;
    font-size: 0.78rem;
  }

  .footer-about-row {
    gap: 16px;
    margin-top: 22px;
    padding-top: 20px;
  }

  .footer-logo {
    width: 178px;
    height: 56px;
    justify-self: center;
    background-position: center;
  }

  .footer-about {
    text-align: center;
  }

  .footer-about p {
    margin-bottom: 12px;
    font-size: 0.9rem;
    line-height: 1.6;
  }

  .footer-social {
    text-align: center;
  }

  .footer-social h2 {
    justify-content: center;
  }

  .footer-social > div {
    justify-content: center;
  }

  .footer-social a {
    width: 40px;
    background: rgba(255, 255, 255, 0.08);
  }

  .footer-bottom {
    justify-items: center;
    gap: 10px;
    padding: 14px 11px 16px;
    text-align: center;
  }

  .footer-bottom nav {
    justify-content: center;
    gap: 8px 14px;
    font-size: 0.78rem;
  }

  .mini-post img {
    width: 92px;
  }

  .search-box form {
    grid-template-columns: 1fr;
  }

  .admin-header,
  .admin-stats,
  .admin-filters,
  .admin-post-row {
    grid-template-columns: 1fr;
  }

  .admin-header {
    display: grid;
  }

  .admin-post-row img {
    width: 100%;
  }

  .admin-row-actions {
    justify-content: flex-start;
  }

  .search-modal {
    padding: 78px 12px 16px;
  }

  .site-footer {
    padding-top: 34px;
  }

  .site-footer .brand::before {
    width: 146px;
    height: 44px;
  }
}

@media (max-width: 380px) {
  .menu-toggle {
    width: 40px;
    padding: 8px;
  }

  .menu-toggle span:not(.visually-hidden) {
    width: 20px;
  }

  .category-link {
    padding-inline: 9px;
    font-size: 0.76rem;
  }

  .footer-categories > div {
    grid-template-columns: 1fr;
  }

  .footer-post {
    grid-template-columns: 76px minmax(0, 1fr);
  }

  .footer-post img {
    width: 76px;
  }

  .brand-image {
    width: min(168px, 62vw);
  }

  .mini-post {
    grid-template-columns: 1fr;
  }

  .mega-stories article {
    grid-template-columns: 1fr;
  }

  .mega-stories img {
    grid-row: auto;
    aspect-ratio: 16 / 9;
  }

  .mini-post img {
    width: 100%;
    aspect-ratio: 16 / 9;
  }

  .insight-band {
    padding: 20px;
  }
}

@media (max-height: 520px) and (orientation: landscape) {
  .nav-panel {
    overflow-y: auto;
  }

}
