@charset "UTF-8";
/* ================================================================
   كان نيوز — وكالة كربلاء للأنباء
   Design system: RTL, responsive, light/dark
   ================================================================ */

:root {
  --ink: #0e1220;
  --ink-2: #16233f;
  --paper: #ffffff;
  --surface: #f5f6fa;
  --surface-2: #eceef5;
  --line: #e3e6ef;
  --text: #14181f;
  --muted: #5c6474;
  --brand: #b8162c;
  --brand-dark: #92101f;
  --gold: #c9a227;
  --gold-soft: #e6b74a;
  --teal: #0e7a6f;
  --violet: #6d3bb0;
  --blue: #1f5fbf;
  --shadow-sm: 0 1px 2px rgba(14, 18, 32, .06), 0 6px 18px rgba(14, 18, 32, .05);
  --shadow-lg: 0 18px 44px rgba(14, 18, 32, .16);
  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;
  --wrap: 1240px;
  --font-head: "Tajawal", "Segoe UI", Tahoma, sans-serif;
  --font-body: "IBM Plex Sans Arabic", "Tajawal", "Segoe UI", Tahoma, sans-serif;
}

[data-theme="dark"] {
  --paper: #0f1320;
  --surface: #151a2b;
  --surface-2: #1c2236;
  --line: #262d44;
  --text: #eef1f8;
  --muted: #a2abc1;
  --brand: #e0324a;
  --brand-dark: #b31c30;
  --gold: #e0bb4d;
  --gold-soft: #f0c961;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .5), 0 8px 22px rgba(0, 0, 0, .35);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, .55);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.85;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  line-height: 1.35;
  margin: 0;
  font-weight: 800;
  letter-spacing: -.01em;
}

p { margin: 0; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; cursor: pointer; }
input, textarea { font: inherit; color: inherit; }

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
  border-radius: 4px;
}

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: 22px; }

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

.skip {
  position: fixed;
  inset-block-start: 8px;
  inset-inline-start: 8px;
  z-index: 200;
  background: var(--ink);
  color: #fff;
  padding: 10px 18px;
  border-radius: var(--r-sm);
}

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 15px;
  transition: transform .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--brand { background: var(--brand); color: #fff; box-shadow: 0 8px 18px rgba(184, 22, 44, .25); }
.btn--brand:hover { background: var(--brand-dark); }
.btn--gold { background: var(--gold); color: #14181f; }
.btn--gold:hover { background: var(--gold-soft); }
.btn--ghost { border-color: var(--line); background: transparent; color: var(--text); }
.btn--block { width: 100%; }

.iconbtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  color: inherit;
  transition: background .18s, color .18s, border-color .18s;
}
.iconbtn:hover { background: var(--surface-2); color: var(--brand); }

/* ---------------------------------------------------------------- topbar */
.topbar {
  background: var(--ink);
  color: #b9c1d6;
  font-size: 13.5px;
}
.topbar__inner {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 42px;
  flex-wrap: wrap;
}
.topbar__date { display: flex; align-items: center; gap: 8px; color: var(--gold-soft); font-weight: 600; }
.topbar__date .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px rgba(184, 22, 44, .25); }
.topbar__tagline { flex: 1; }
.topbar__side { display: flex; align-items: center; gap: 14px; }
.topbar .iconbtn { border-color: rgba(255, 255, 255, .16); width: 34px; height: 34px; }
.topbar .iconbtn:hover { background: rgba(255, 255, 255, .1); color: var(--gold-soft); }

.social { display: flex; gap: 8px; align-items: center; }
.social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--muted);
  transition: background .18s, color .18s, transform .18s;
}
.social a:hover { background: var(--brand); color: #fff; transform: translateY(-2px); }
.social--sm a { width: 28px; height: 28px; background: transparent; color: inherit; }
.social--sm a:hover { background: rgba(255, 255, 255, .12); color: var(--gold-soft); transform: none; }
.social--stack { flex-wrap: wrap; margin-top: 14px; }

/* ---------------------------------------------------------------- masthead */
.masthead {
  position: sticky;
  top: 0;
  z-index: 60;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.masthead__inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 78px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand__mark { width: 46px; height: 46px; flex: none; }
.brand__text { display: flex; flex-direction: column; line-height: 1.2; }
.brand__name { font-family: var(--font-head); font-weight: 800; font-size: 27px; letter-spacing: -.02em; color: var(--text); }
.brand__name span { color: var(--brand); }
.brand__name--sm { font-size: 22px; }
.brand__sub { font-size: 12.5px; color: var(--muted); letter-spacing: .01em; }

.nav { margin-inline-start: auto; }
.nav ul { display: flex; gap: 4px; align-items: center; }
.nav a {
  display: block;
  padding: 9px 13px;
  border-radius: var(--r-sm);
  font-family: var(--font-head);
  font-weight: 500;
  font-size: 15.5px;
  color: var(--text);
  transition: background .16s, color .16s;
}
.nav a:hover { background: var(--surface-2); color: var(--brand); }
.nav a.is-active { color: var(--brand); font-weight: 700; background: color-mix(in srgb, var(--brand) 9%, transparent); }

.masthead__actions { display: flex; align-items: center; gap: 10px; }
.masthead__cta { padding: 9px 18px; }
.iconbtn--menu { display: none; }

/* ---------------------------------------------------------------- ticker */
.ticker {
  background: linear-gradient(90deg, var(--brand-dark), var(--brand));
  color: #fff;
}
.ticker__inner { display: flex; align-items: center; gap: 16px; height: 44px; }
.ticker__label {
  flex: none;
  background: var(--gold);
  color: #14181f;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 14px;
  padding: 4px 15px;
  border-radius: 999px;
  letter-spacing: .02em;
}
.ticker__viewport {
  flex: 1;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 3%, #000 97%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 3%, #000 97%, transparent);
}
.ticker__track {
  display: flex;
  align-items: center;
  gap: 34px;
  white-space: nowrap;
  width: max-content;
  animation: ticker-slide 46s linear infinite;
}
.ticker__viewport:hover .ticker__track { animation-play-state: paused; }
.ticker__item { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; }
.ticker__item:hover { color: var(--gold-soft); }
.ticker__cat { font-size: 12.5px; opacity: .82; border: 1px solid rgba(255, 255, 255, .4); padding: 1px 9px; border-radius: 999px; }
@keyframes ticker-slide { from { transform: translateX(0); } to { transform: translateX(50%); } }

.progress { position: fixed; inset-inline: 0; top: 0; height: 3px; z-index: 90; background: transparent; }
.progress span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--gold), var(--brand)); transition: width .1s linear; }

/* ---------------------------------------------------------------- cards */
.pill {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 12.5px;
  padding: 5px 13px;
  border-radius: 999px;
  letter-spacing: .01em;
}
.pill--red { background: var(--brand); }
.pill--gold { background: var(--gold); color: #14181f; }
.pill--teal { background: var(--teal); }
.pill--violet { background: var(--violet); }
.pill--blue { background: var(--blue); }
.pill--ink { background: var(--ink-2); }
.pill--brand { background: var(--brand); }
.pill--ghost { background: transparent; color: var(--muted); border: 1px solid var(--line); }

.meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--muted);
  flex-wrap: wrap;
}
.meta--light { color: rgba(255, 255, 255, .85); }
.meta__sep { opacity: .5; }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--brand) 35%, var(--line)); }
.card__media { position: relative; display: block; overflow: hidden; aspect-ratio: 16 / 9; background: var(--surface-2); }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card__media img { transform: scale(1.06); }
.card__media .pill { position: absolute; inset-block-start: 12px; inset-inline-start: 12px; z-index: 2; }
.card__body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 9px; flex: 1; }
.card__title { font-size: 19px; font-weight: 700; line-height: 1.5; }
.card__title a { background-image: linear-gradient(currentColor, currentColor); background-size: 0 2px; background-repeat: no-repeat; background-position: 100% 100%; transition: background-size .3s ease; }
.card:hover .card__title a { background-size: 100% 2px; color: var(--brand); }
.card__excerpt { color: var(--muted); font-size: 15px; line-height: 1.8; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card .meta { margin-top: auto; }

.card--overlay { background: linear-gradient(165deg, var(--ink-2), var(--ink)); border-color: transparent; }
.card--overlay:hover { border-color: color-mix(in srgb, var(--gold) 55%, transparent); }
.card--overlay .card__media { aspect-ratio: 16 / 10; }
.card--overlay .card__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(9, 12, 22, .75)); }
.card--overlay .card__body { padding: 14px 16px 16px; gap: 7px; }
.card--overlay .card__title { color: #fff; font-size: 16.5px; line-height: 1.6; }
.card--overlay .card__title a:hover { color: var(--gold-soft); }
.card--overlay .meta { color: rgba(255, 255, 255, .72); }

/* ---------------------------------------------------------------- hero */
.hero { display: grid; grid-template-columns: 1.5fr 1fr; gap: 22px; padding-block: 30px 6px; }
.hero__lead { min-width: 0; }
.hero__side { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-content: start; }

.lead { position: relative; display: block; border-radius: var(--r-lg); overflow: hidden; height: 100%; min-height: 430px; }
.lead img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.lead:hover img { transform: scale(1.04); }
.lead__grad { position: absolute; inset: 0; background: linear-gradient(0deg, rgba(8, 11, 20, .95) 8%, rgba(8, 11, 20, .45) 48%, rgba(8, 11, 20, .1) 100%); }
.lead__body { position: absolute; inset-inline: 0; inset-block-end: 0; padding: 30px 32px; display: flex; flex-direction: column; align-items: flex-start; gap: 14px; z-index: 2; }
.lead__title { font-family: var(--font-head); font-weight: 800; font-size: clamp(24px, 2.6vw, 36px); line-height: 1.4; color: #fff; }
.lead__excerpt { color: rgba(255, 255, 255, .82); font-size: 16px; line-height: 1.8; max-width: 62ch; }

.headlines {
  grid-column: 1 / -1;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 18px 20px;
}
.headlines__title { font-size: 17px; display: flex; align-items: center; gap: 9px; padding-bottom: 10px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--brand); animation: pulse 1.6s infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(184, 22, 44, .55); } 60% { box-shadow: 0 0 0 8px rgba(184, 22, 44, 0); } }
.headlines li + li { border-top: 1px dashed var(--line); }
.headlines a { display: flex; gap: 12px; padding: 11px 0; font-family: var(--font-head); font-weight: 500; font-size: 15.5px; line-height: 1.6; transition: color .16s; }
.headlines a:hover { color: var(--brand); }
.headlines a span { flex: none; color: var(--brand); font-size: 12.5px; font-weight: 700; padding-top: 3px; }


/* ---------------------------------------------------------------- sections */
.section { padding-block: 34px; }
.section--split { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 34px; align-items: start; }
.section__main { min-width: 0; }

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}
.section-head__title {
  font-size: clamp(20px, 2vw, 25px);
  position: relative;
  padding-inline-start: 16px;
}
.section-head__title::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  inset-block: 4px;
  width: 5px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--gold), var(--brand));
}
.section-head__link { font-family: var(--font-head); font-weight: 700; font-size: 14.5px; color: var(--brand); white-space: nowrap; }
.section-head__link:hover { text-decoration: underline; }

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

.rows { display: flex; flex-direction: column; gap: 4px; }
.row {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.row__media { flex: none; width: 132px; aspect-ratio: 4 / 3; border-radius: var(--r-sm); overflow: hidden; background: var(--surface-2); }
.row__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.row:hover .row__media img { transform: scale(1.07); }
.row__body { min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.row__cat { font-family: var(--font-head); font-weight: 700; font-size: 12.5px; color: var(--brand); }
.row__title { font-size: 18px; font-weight: 700; line-height: 1.55; }
.row__title a:hover { color: var(--brand); }
.row__excerpt { color: var(--muted); font-size: 15px; line-height: 1.8; }
.rank { flex: none; font-family: var(--font-head); font-weight: 800; font-size: 26px; color: var(--line); line-height: 1; padding-top: 4px; }

.ranklist li + li { border-top: 1px solid var(--line); }
.ranklist a { display: flex; gap: 14px; align-items: flex-start; padding: 14px 0; transition: color .16s; }
.ranklist a:hover { color: var(--brand); }
.ranklist .num {
  flex: none;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 15px;
  color: var(--gold);
  background: color-mix(in srgb, var(--gold) 16%, transparent);
  border-radius: var(--r-sm);
  min-width: 34px; height: 34px;
  display: grid; place-items: center;
}
.ranklist .txt { font-family: var(--font-head); font-weight: 500; font-size: 15.5px; line-height: 1.7; }

/* photo tiles */
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.tile { position: relative; display: block; border-radius: var(--r-md); overflow: hidden; aspect-ratio: 4 / 3.2; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(8, 11, 20, .92) 6%, rgba(8, 11, 20, .25) 55%, transparent 100%); }
.tile:hover img { transform: scale(1.07); }
.tile__body { position: absolute; inset-inline: 0; inset-block-end: 0; padding: 22px; display: flex; flex-direction: column; gap: 9px; z-index: 2; }
.tile__cat { font-family: var(--font-head); font-weight: 700; font-size: 12.5px; color: var(--gold-soft); }
.tile__title { font-family: var(--font-head); font-weight: 700; font-size: 18px; line-height: 1.55; color: #fff; }
.tile:hover .tile__title { color: var(--gold-soft); }

/* ---------------------------------------------------------------- aside */
.aside-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: 20px 22px 24px;
  margin-bottom: 22px;
}
.aside-card__title {
  font-size: 17.5px;
  padding-bottom: 12px;
  margin-bottom: 6px;
  border-bottom: 3px solid var(--brand);
  display: inline-block;
}
.aside-card__text { color: var(--muted); font-size: 15px; }
.aside-card--rank { background: var(--paper); }

.catlist li + li { border-top: 1px solid var(--line); }
.catlist a { display: flex; justify-content: space-between; align-items: center; padding: 11px 0; font-family: var(--font-head); font-weight: 500; font-size: 15.5px; }
.catlist a:hover { color: var(--brand); }
.catlist .count { background: var(--paper); border: 1px solid var(--line); color: var(--muted); font-size: 12.5px; border-radius: 999px; padding: 1px 10px; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 14px; }
.stat { text-align: center; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 14px 8px; }
.stat strong { display: block; font-family: var(--font-head); font-size: 24px; font-weight: 800; color: var(--brand); line-height: 1.2; }
.stat span { font-size: 12.5px; color: var(--muted); }

/* ---------------------------------------------------------------- newsletter */
.newsletter {
  background: linear-gradient(135deg, var(--ink-2), var(--ink));
  color: #e9edf7;
  border-radius: var(--r-lg);
  padding: 34px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 26px;
  align-items: center;
  position: relative;
  overflow: hidden;
}
.newsletter::before {
  content: "";
  position: absolute;
  inset-inline-end: -60px;
  inset-block-start: -60px;
  width: 220px; height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 39, .35), transparent 68%);
}
.newsletter__text { position: relative; z-index: 1; }
.newsletter__text h2 { font-size: clamp(21px, 2.2vw, 27px); color: #fff; margin-bottom: 10px; }
.newsletter__text p { color: #aeb8d0; font-size: 15.5px; line-height: 1.9; }
.newsletter__form { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 10px; }
.newsletter__form input {
  width: 100%;
  padding: 13px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .07);
  color: #fff;
}
.newsletter__form input::placeholder { color: #97a1bb; }
.newsletter__form .btn { width: 100%; }
.newsletter__msg { font-size: 14.5px; color: var(--gold-soft); }
.newsletter--aside { grid-template-columns: 1fr; padding: 24px 22px 26px; }

/* ---------------------------------------------------------------- footer */
.footer { background: var(--ink); color: #a9b2c9; margin-top: 50px; padding-block: 52px 26px; }
.footer__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 34px; }
.brand--footer .brand__name { color: #fff; }
.brand--footer .brand__sub { color: #8791ab; }
.footer__brand p { margin-top: 16px; font-size: 14.5px; line-height: 1.95; }
.footer__brand .social { margin-top: 16px; }
.footer__brand .social a { background: rgba(255, 255, 255, .08); color: #cbd2e3; }
.footer__title { font-size: 17px; color: #fff; margin-bottom: 16px; padding-bottom: 10px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.footer__links li + li { margin-top: 9px; }
.footer__links a { font-size: 15px; transition: color .16s, padding .16s; }
.footer__links a:hover { color: var(--gold-soft); padding-inline-start: 5px; }
.footer__contact li { display: flex; flex-direction: column; gap: 3px; font-size: 15px; padding: 7px 0; border-bottom: 1px dashed rgba(255, 255, 255, .12); }
.footer__contact span { font-size: 12.5px; color: var(--gold-soft); }
.footer__contact a:hover { color: #fff; }
.footer__bottom {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 34px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: 13.5px;
}
.footer__note { color: #7b8499; }
.footer__contact--dark li { border-bottom-color: var(--line); }

.to-top { position: fixed; inset-inline-end: 18px; inset-block-end: 18px; z-index: 55; opacity: 0; pointer-events: none; transform: translateY(12px); transition: .25s; }
.to-top.is-visible { opacity: 1; pointer-events: auto; transform: none; }
.to-top .iconbtn { background: var(--brand); color: #fff; border-color: transparent; box-shadow: var(--shadow-lg); width: 46px; height: 46px; }

/* ---------------------------------------------------------------- drawer + search */
.drawer, .searchbox { position: fixed; inset: 0; z-index: 120; }
.drawer::before, .searchbox::before { content: ""; position: absolute; inset: 0; background: rgba(8, 11, 20, .62); backdrop-filter: blur(3px); animation: fade .2s ease; }
.drawer__panel {
  position: absolute;
  inset-block: 0;
  inset-inline-end: 0;
  width: min(88vw, 340px);
  background: var(--paper);
  display: flex;
  flex-direction: column;
  padding: 22px;
  gap: 18px;
  animation: slide-in .28s cubic-bezier(.2, .8, .3, 1);
  overflow-y: auto;
}
@keyframes slide-in { from { transform: translateX(-100%); } to { transform: translateX(0); } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.drawer__head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.drawer__nav li { border-bottom: 1px solid var(--line); }
.drawer__nav a { display: block; padding: 14px 4px; font-family: var(--font-head); font-weight: 700; font-size: 17px; }
.drawer__nav a:hover { color: var(--brand); }
.drawer__foot { margin-top: auto; display: flex; flex-direction: column; gap: 16px; }

.searchbox__panel {
  position: relative;
  max-width: 720px;
  margin: 8vh auto 0;
  background: var(--paper);
  border-radius: var(--r-lg);
  padding: 20px;
  box-shadow: var(--shadow-lg);
  animation: panel-in .25s ease;
  max-height: 78vh;
  overflow-y: auto;
}
@keyframes panel-in { from { transform: translateY(-16px); opacity: 0; } to { transform: none; opacity: 1; } }
.searchbox__form { display: flex; align-items: center; gap: 12px; border-bottom: 2px solid var(--line); padding-bottom: 12px; }
.searchbox__form input { flex: 1; border: 0; background: transparent; font-size: 19px; padding: 8px 0; outline: none; }
.searchbox__results { margin-top: 12px; display: flex; flex-direction: column; }
.searchbox__results .sr-item { display: flex; gap: 14px; padding: 13px 4px; border-bottom: 1px dashed var(--line); align-items: center; }
.searchbox__results .sr-item img { width: 74px; height: 56px; object-fit: cover; border-radius: 6px; flex: none; }
.searchbox__results .sr-item h4 { font-size: 15.5px; font-weight: 700; line-height: 1.6; }
.searchbox__results .sr-item p { font-size: 13px; color: var(--muted); }
.searchbox__results .sr-empty { padding: 22px 6px; color: var(--muted); text-align: center; }

/* ---------------------------------------------------------------- article */
.breadcrumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13.5px; color: var(--muted); margin-bottom: 18px; }
.breadcrumb a:hover { color: var(--brand); }
.breadcrumb__sep { opacity: .5; }

.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 40px; padding-block: 28px 10px; align-items: start; }
.article__head { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; margin-bottom: 26px; }
.article__title { font-size: clamp(26px, 3.4vw, 42px); line-height: 1.4; }
.article__standfirst { font-size: 18.5px; line-height: 1.95; color: var(--muted); border-inline-start: 3px solid var(--gold); padding-inline-start: 16px; }
.article__meta { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; width: 100%; padding-block: 6px; border-block: 1px solid var(--line); }
.byline { display: flex; align-items: center; gap: 12px; padding-block: 6px; }
.byline__avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--gold));
  color: #fff;
  display: grid; place-items: center;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 19px;
}
.byline__name { display: block; font-family: var(--font-head); font-weight: 700; font-size: 15.5px; }

.share { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.share__label { font-family: var(--font-head); font-weight: 700; font-size: 14.5px; color: var(--muted); }
.share__btn {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  border-radius: 999px;
  padding: 7px 16px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 13.5px;
  transition: .16s;
}
.share__btn:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
.share__btn--copy:hover { background: var(--teal); border-color: var(--teal); }

.article__figure { margin: 0 0 26px; }
.article__figure img { width: 100%; border-radius: var(--r-md); }
.article__figure figcaption, .gallery figcaption { font-size: 13.5px; color: var(--muted); margin-top: 10px; line-height: 1.7; }

.gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-bottom: 26px; }
.gallery__item { margin: 0; }
.gallery__item img { border-radius: var(--r-md); aspect-ratio: 16/9; object-fit: cover; width: 100%; }

.prose { font-size: 17.5px; line-height: 2.1; }
.prose p { margin-bottom: 20px; }
.prose h2 { font-size: 25px; margin: 34px 0 14px; }
.prose a { color: var(--brand); text-decoration: underline; }
.prose strong { color: var(--brand); }

.article__tags { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--line); }
.chip {
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--text);
  border-radius: 999px;
  padding: 8px 18px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 14.5px;
  transition: .16s;
}
.chip:hover { border-color: var(--brand); color: var(--brand); }
.chip.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.chip--sm { font-size: 13.5px; padding: 6px 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }

.postnav { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 28px; }
.postnav__item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: 16px 18px; display: flex; flex-direction: column; gap: 7px; transition: .18s; }
.postnav__item:hover { border-color: var(--brand); transform: translateY(-3px); }
.postnav__item span { font-size: 13px; color: var(--muted); }
.postnav__item strong { font-family: var(--font-head); font-weight: 700; font-size: 15.5px; line-height: 1.6; }
.postnav__item--next { text-align: end; }

/* ---------------------------------------------------------------- category hero */
.cat-hero {
  background:
    linear-gradient(120deg, rgba(10, 14, 24, .94), rgba(10, 14, 24, .7)),
    var(--cat-hero, none) center/cover no-repeat,
    var(--ink-2);
  color: #eef1f8;
  padding-block: 44px;
}
.cat-hero--plain { background: linear-gradient(120deg, var(--ink-2), var(--ink)); }
.cat-hero__inner { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.cat-hero .breadcrumb { color: rgba(255, 255, 255, .65); }
.cat-hero .breadcrumb a:hover { color: var(--gold-soft); }
.cat-hero__kicker { font-family: var(--font-head); font-weight: 700; font-size: 13.5px; color: var(--gold-soft); letter-spacing: .06em; }
.cat-hero__title { font-size: clamp(30px, 4vw, 48px); color: #fff; }
.cat-hero__desc { color: #b9c1d6; font-size: 16.5px; line-height: 1.9; max-width: 70ch; }
.cat-hero__count { font-size: 13.5px; color: rgba(255, 255, 255, .7); background: rgba(255, 255, 255, .12); padding: 5px 14px; border-radius: 999px; }
.cat-hero .chip { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .22); color: #eef1f8; }
.cat-hero .chip:hover { border-color: var(--gold); color: var(--gold-soft); }
.cat-hero .chip.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }

.result-count { font-size: 14.5px; color: var(--muted); margin-bottom: 18px; }
.rows--wide .row__media { width: 200px; aspect-ratio: 16/10; }
.rows--wide .row { padding: 20px 0; gap: 22px; }
.rows--wide .row__title { font-size: 20px; }
.row.is-hidden { display: none; }

/* ---------------------------------------------------------------- forms */
.split-text { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 40px; align-items: start; padding-block: 34px; }
.contact-form, .search-page { display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field label { font-family: var(--font-head); font-weight: 700; font-size: 14.5px; }
.field input, .field textarea {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--r-sm);
  padding: 12px 15px;
  font-size: 16px;
  transition: border-color .16s, box-shadow .16s;
}
.field input:focus, .field textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent); outline: none; }
.contact-form .btn { align-self: flex-start; }
.contact-form__msg { color: var(--teal); font-weight: 600; }
.search-page { flex-direction: row; align-items: center; flex-wrap: wrap; gap: 12px; }
.search-page input {
  flex: 1;
  min-width: 240px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 999px;
  padding: 14px 22px;
  font-size: 17px;
}
.search-page input:focus { border-color: var(--brand); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 16%, transparent); }

/* ---------------------------------------------------------------- credits / 404 */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-md); }
.credits { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 720px; }
.credits th, .credits td { padding: 13px 16px; text-align: start; border-bottom: 1px solid var(--line); vertical-align: middle; }
.credits thead th { background: var(--surface); font-family: var(--font-head); font-size: 14.5px; }
.credits img { width: 56px; height: 56px; object-fit: cover; border-radius: 6px; }
.credits a { color: var(--brand); font-weight: 600; }

.notfound { text-align: center; padding-block: 90px 70px; }
.notfound__code { font-family: var(--font-head); font-weight: 800; font-size: clamp(70px, 14vw, 150px); line-height: 1; background: linear-gradient(180deg, var(--brand), var(--gold)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.notfound h1 { font-size: clamp(24px, 3vw, 34px); margin: 14px 0 10px; }
.notfound p { color: var(--muted); }
.notfound__actions { margin-top: 26px; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

/* ---------------------------------------------------------------- responsive */
@media (max-width: 1080px) {
  .hero { grid-template-columns: 1fr; }
  .lead { min-height: 360px; }
  .section--split, .article-layout, .split-text { grid-template-columns: 1fr; }
  .article__side, .section__side { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; align-items: start; }
  .article__side .aside-card, .section__side .aside-card { margin-bottom: 0; }
}

@media (max-width: 940px) {
  .nav { display: none; }
  .iconbtn--menu { display: inline-flex; }
  .masthead__cta { display: none; }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .newsletter { grid-template-columns: 1fr; padding: 28px 24px; }
}

@media (max-width: 720px) {
  body { font-size: 16px; }
  .topbar__tagline { display: none; }
  .hero { padding-block-start: 20px; }
  .lead { min-height: 320px; }
  .lead__body { padding: 20px; gap: 11px; }
  .grid--2, .grid--3, .tiles, .gallery { grid-template-columns: 1fr; }
  .hero__side { grid-template-columns: 1fr; }
  .rows--wide .row { flex-direction: column; gap: 12px; }
  .rows--wide .row__media { width: 100%; aspect-ratio: 16/9; }
  .row__media { width: 110px; }
  .article__title { font-size: 26px; }
  .article__standfirst { font-size: 17px; }
  .prose { font-size: 17px; line-height: 2.05; }
  .stats { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; gap: 26px; }
  .ticker__track { animation-duration: 34s; }
  .searchbox__panel { margin: 0; border-radius: 0; min-height: 100%; max-height: 100%; }
}

@media (max-width: 480px) {
  .wrap { padding-inline: 16px; }
  .brand__mark { width: 40px; height: 40px; }
  .brand__name { font-size: 23px; }
  .masthead__inner { min-height: 66px; gap: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}

@media print {
  .topbar, .masthead, .footer, .article__side, .share, .to-top, .drawer, .searchbox { display: none !important; }
  body { color: #000; background: #fff; }
}
