/* ============================================================
   TEKNO NEWS — portal berita bergaya "broadcast tech"
   Font: Oswald (display) / Barlow (body) / IBM Plex Mono (data)
   ============================================================ */
:root {
  --bg: #070a10;
  --bg2: #0b1019;
  --panel: #101827;
  --panel2: #0d1522;
  --line: #1d2a45;
  --line2: #27395e;
  --txt: #e9eef8;
  --muted: #8b98b4;
  --red: #ff2e3f;
  --red-dark: #c1121f;
  --cyan: #3fe0ff;
  --amber: #ffb020;
  --green: #34e39a;
  --font-display: 'Oswald', sans-serif;
  --font-body: 'Barlow', sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;
  --radius: 10px;
  --shadow: 0 18px 50px rgba(0, 0, 0, .55);
  --safe-area-inset-top: env(safe-area-inset-top, 0px);
  --safe-area-inset-bottom: env(safe-area-inset-bottom, 0px);
  --safe-area-inset-left: env(safe-area-inset-left, 0px);
  --safe-area-inset-right: env(safe-area-inset-right, 0px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--txt);
  padding-bottom: 52px; /* ruang ticker bawah */
  overflow-x: hidden;
  padding-top: max(var(--safe-area-inset-top), 0);
  padding-left: var(--safe-area-inset-left);
  padding-right: var(--safe-area-inset-right);
}
body::before {
  content: '';
  position: fixed; inset: 0; z-index: -2;
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(255, 46, 63, .14), transparent 60%),
    radial-gradient(900px 600px at -10% 20%, rgba(63, 224, 255, .07), transparent 60%),
    var(--bg);
}
body::after {
  content: '';
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .018) 1px, transparent 1px);
  background-size: 44px 44px;
  opacity: .5;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }
::selection { background: var(--red); color: #fff; }
::-webkit-scrollbar { width: 10px; height: 8px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: var(--line2); border-radius: 6px; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ============ TOP BAR ============ */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 10, 16, .92);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--red-dark);
}
.topbar-inner { display: flex; align-items: center; gap: 12px; height: 62px; flex-wrap: wrap; padding: 0 16px; }
.logo { display: flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; flex-shrink: 0; }
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--txt);
  font-size: 24px;
  padding: 6px;
  border-radius: 6px;
  flex-shrink: 0;
  margin-right: auto;
}
.mobile-menu-btn:hover { background: rgba(255,255,255,.08); }
.mobile-menu-btn svg { width: 24px; height: 24px; display: block; }
.logo-mark {
  width: 36px; height: 36px; border-radius: 8px;
  background: linear-gradient(135deg, var(--red), #ff6a3d);
  display: grid; place-items: center;
  font-family: var(--font-display); font-weight: 700; font-size: 15px; color: #071018;
  box-shadow: 0 0 22px rgba(255, 46, 63, .5);
}
.logo-text { font-family: var(--font-display); font-size: 23px; font-weight: 700; letter-spacing: .04em; line-height: 1; }
.logo-text em { font-style: normal; color: var(--red); }
.logo-sub { font-family: var(--font-mono); font-size: 8.5px; letter-spacing: .32em; color: var(--muted); text-transform: uppercase; }

.nav { display: flex; gap: 2px; flex: 1; overflow-x: auto; }
.nav a {
  font-family: var(--font-display); font-weight: 500; font-size: 13.5px;
  letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
  padding: 8px 13px; border-radius: 6px; white-space: nowrap; position: relative;
  transition: color .18s, background .18s;
}
.nav a:hover { color: var(--txt); background: rgba(255, 255, 255, .05); }
.nav a.active { color: #fff; }
.nav a.active::after {
  content: ''; position: absolute; left: 13px; right: 13px; bottom: 2px; height: 2px;
  background: var(--red); box-shadow: 0 0 10px var(--red);
}

.searchbox { position: relative; }
.searchbox input {
  background: var(--panel2); border: 1px solid var(--line); color: var(--txt);
  font-family: var(--font-body); font-size: 13px;
  padding: 8px 34px 8px 12px; border-radius: 20px; width: 190px; outline: none;
  transition: border-color .2s, width .25s;
}
.searchbox input:focus { border-color: var(--red); width: 240px; }
.searchbox button {
  position: absolute; right: 4px; top: 3px; width: 26px; height: 26px;
  background: none; border: none; color: var(--muted); border-radius: 50%;
}
.searchbox button:hover { color: var(--red); }

.live-pill {
  display: flex; align-items: center; gap: 7px;
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .18em; color: var(--red);
  border: 1px solid rgba(255, 46, 63, .4); padding: 5px 11px; border-radius: 20px; white-space: nowrap;
}
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--red); animation: blink 1.2s infinite; }
@keyframes blink { 0%, 100% { opacity: 1; box-shadow: 0 0 8px var(--red); } 50% { opacity: .25; box-shadow: none; } }

.datestrip {
  background: linear-gradient(90deg, var(--red-dark), rgba(193, 18, 31, .25));
  font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .14em; color: #ffd9dc;
  text-transform: uppercase; padding: 5px 0;
}
.datestrip .wrap { display: flex; justify-content: space-between; }
.datestrip b { color: #fff; }

/* ============ HEADLINE SLIDER ============ */
.hero { margin: 26px 0 34px; position: relative; }
.slider {
  position: relative; border-radius: var(--radius); overflow: hidden;
  aspect-ratio: 16 / 7.4; min-height: 330px; box-shadow: var(--shadow);
  border: 1px solid var(--line);
  background: var(--panel2);
}
.slide {
  position: absolute; inset: 0; opacity: 0; transform: scale(1.04);
  transition: opacity .8s ease, transform 4.5s linear;
  pointer-events: none; cursor: pointer;
}
.slide.active { opacity: 1; transform: scale(1); pointer-events: auto; }
.slide-bg { position: absolute; inset: 0; }
.slide-bg img { width: 100%; height: 100%; object-fit: cover; }
.slide-shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(7, 10, 16, .1) 30%, rgba(7, 10, 16, .88) 86%, #070a10),
              linear-gradient(90deg, rgba(7, 10, 16, .55), transparent 40%);
}
.slide-meta {
  position: absolute; left: 34px; right: 34px; bottom: 30px;
  display: flex; flex-direction: column; gap: 12px;
}
.slide-tag {
  display: flex; gap: 8px; align-items: center;
}
.slide-title {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(22px, 3.4vw, 40px);
  line-height: 1.12; text-transform: uppercase; letter-spacing: .01em;
  max-width: 850px; text-shadow: 0 4px 30px rgba(0, 0, 0, .8);
}
.slide-excerpt { color: #c3ccdf; max-width: 640px; font-size: 14.5px; line-height: 1.5; }
.slide-progress { position: absolute; left: 0; bottom: 0; height: 3px; background: var(--red); width: 0; z-index: 5; }
.slide-progress.run { animation: slideprog 6s linear; }
@keyframes slideprog { from { width: 0; } to { width: 100%; } }

.slider-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 6;
  width: 42px; height: 42px; border-radius: 50%;
  background: rgba(7, 10, 16, .65); border: 1px solid var(--line2); color: var(--txt);
  display: grid; place-items: center; font-size: 18px; transition: background .2s, border-color .2s;
}
.slider-arrow:hover { background: var(--red); border-color: var(--red); }
.slider-arrow.prev { left: 16px; }
.slider-arrow.next { right: 16px; }
.slider-dots { position: absolute; right: 30px; top: 22px; display: flex; gap: 7px; z-index: 6; }
.slider-dots span {
  width: 22px; height: 4px; border-radius: 3px; background: rgba(255, 255, 255, .25); cursor: pointer;
  transition: background .2s;
}
.slider-dots span.on { background: var(--red); box-shadow: 0 0 8px var(--red); }

/* ============ PLACEHOLDER COVER ============ */
.ph {
  display: grid; place-items: center; position: relative; overflow: hidden;
  font-family: var(--font-display);
}
.ph::after {
  content: ''; position: absolute; inset: 0;
  background: repeating-linear-gradient(135deg, transparent 0 14px, rgba(255, 255, 255, .035) 14px 16px);
}
.ph .ph-label {
  font-size: 13px; letter-spacing: .28em; text-transform: uppercase; color: rgba(255, 255, 255, .85);
  font-weight: 500; z-index: 1;
}
.ph .ph-icon { position: absolute; font-size: 74px; opacity: .13; font-weight: 700; z-index: 0; }

/* ============ LAYOUT ============ */
.cols { display: grid; grid-template-columns: 1fr 330px; gap: 28px; align-items: start; }
.section { margin: 34px 0; }
.section-head {
  display: flex; align-items: center; gap: 12px; margin-bottom: 18px;
  border-bottom: 1px solid var(--line); padding-bottom: 12px;
}
.section-head h2 {
  font-family: var(--font-display); font-weight: 600; font-size: 21px;
  text-transform: uppercase; letter-spacing: .05em;
  border-left: 4px solid var(--red); padding-left: 12px; line-height: 1;
}
.section-head .count { font-family: var(--font-mono); font-size: 11px; color: var(--muted); margin-left: auto; }
.section-head a.more { font-family: var(--font-mono); font-size: 11px; color: var(--cyan); letter-spacing: .1em; }
.section-head a.more:hover { text-decoration: underline; }

/* ============ NEWS GRID ============ */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .22s, border-color .22s, box-shadow .22s;
  animation: rise .5s ease both;
}
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.card:hover { transform: translateY(-4px); border-color: var(--line2); box-shadow: var(--shadow); }
.card-cover { aspect-ratio: 16 / 9; position: relative; overflow: hidden; }
.card-cover img, .card-cover .ph { position: absolute; inset: 0; width: 100%; height: 100%; }
.card-cover img { object-fit: cover; transition: transform .4s; }
.card:hover .card-cover img { transform: scale(1.05); }
.card-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-kicker {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase;
}
.chip { background: rgba(255, 46, 63, .16); color: var(--red); border: 1px solid rgba(255, 46, 63, .35); padding: 2px 9px; border-radius: 20px; }
.chip.cy { background: rgba(63, 224, 255, .1); color: var(--cyan); border-color: rgba(63, 224, 255, .35); }
.chip.am { background: rgba(255, 176, 32, .1); color: var(--amber); border-color: rgba(255, 176, 32, .35); }
.card-title { font-family: var(--font-display); font-weight: 500; font-size: 17px; line-height: 1.28; letter-spacing: .01em; }
.card:hover .card-title { color: var(--red); }
.card-excerpt { color: var(--muted); font-size: 13px; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { margin-top: auto; display: flex; gap: 14px; font-family: var(--font-mono); font-size: 10.5px; color: var(--muted); }

/* ============ SIDEBAR ============ */
.sidebar { display: flex; flex-direction: column; gap: 22px; position: sticky; top: 86px; }
.side-box {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px;
}
.side-title {
  font-family: var(--font-display); font-size: 13.5px; font-weight: 600; letter-spacing: .12em;
  text-transform: uppercase; margin-bottom: 14px; display: flex; align-items: center; gap: 8px;
}
.side-title::before { content: ''; width: 6px; height: 16px; background: var(--red); border-radius: 2px; box-shadow: 0 0 8px rgba(255, 46, 63, .7); }

/* jam digital */
.clock-digits { font-family: var(--font-mono); font-size: 40px; font-weight: 600; text-align: center; color: #fff; letter-spacing: .04em; }
.clock-digits .colon { color: var(--red); animation: blink 1s infinite; }
.clock-tz { text-align: center; font-family: var(--font-mono); font-size: 11px; color: var(--muted); letter-spacing: .3em; margin-top: 6px; }
.clock-date { text-align: center; font-size: 13px; color: var(--txt); margin-top: 10px; border-top: 1px dashed var(--line); padding-top: 10px; }

/* kalender mini */
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.cal-head b { font-family: var(--font-display); font-size: 15px; text-transform: uppercase; letter-spacing: .06em; }
.cal-head button { background: none; border: 1px solid var(--line); color: var(--muted); width: 26px; height: 26px; border-radius: 6px; }
.cal-head button:hover { color: var(--red); border-color: var(--red); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.cal-grid .dow { font-family: var(--font-mono); font-size: 9px; color: var(--muted); text-align: center; padding: 4px 0; }
.cal-cell {
  text-align: center; font-size: 12.5px; padding: 7px 0; border-radius: 6px; color: var(--txt);
}
.cal-cell.dim { color: #3b4763; }
.cal-cell.today { background: var(--red); color: #fff; font-weight: 700; box-shadow: 0 0 12px rgba(255, 46, 63, .5); }

/* populer */
.pop-item { display: flex; gap: 12px; padding: 11px 0; border-bottom: 1px dashed var(--line); cursor: pointer; }
.pop-item:last-child { border-bottom: none; }
.pop-rank { font-family: var(--font-display); font-size: 26px; font-weight: 700; color: var(--line2); line-height: 1; width: 34px; }
.pop-item:nth-child(1) .pop-rank { color: var(--red); }
.pop-item:nth-child(2) .pop-rank { color: var(--amber); }
.pop-item:nth-child(3) .pop-rank { color: var(--cyan); }
.pop-title { font-size: 13.5px; font-weight: 600; line-height: 1.4; }
.pop-meta { font-family: var(--font-mono); font-size: 10px; color: var(--muted); margin-top: 4px; }

/* ============ VIDEO ============ */
.video-card { position: relative; cursor: pointer; }
.video-play {
  position: absolute; inset: 0; display: grid; place-items: center; z-index: 2;
  background: rgba(7, 10, 16, .25); opacity: 0; transition: opacity .25s;
}
.video-card:hover .video-play { opacity: 1; }
.video-play .disc {
  width: 58px; height: 58px; border-radius: 50%; background: rgba(255, 46, 63, .92);
  display: grid; place-items: center; box-shadow: 0 0 30px rgba(255, 46, 63, .6);
}
.video-dur { position: absolute; right: 8px; bottom: 8px; z-index: 3; font-family: var(--font-mono); font-size: 10px; background: rgba(7, 10, 16, .85); padding: 2px 7px; border-radius: 4px; }

/* ============ SHORTS / REELS RAIL ============ */
.shorts-rail { display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 14px; scroll-snap-type: x mandatory; }
.short-card {
  flex: 0 0 172px; scroll-snap-align: start; cursor: pointer;
  aspect-ratio: 9 / 16; border-radius: var(--radius); overflow: hidden; position: relative;
  border: 1px solid var(--line); background: var(--panel2);
}
.short-card video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.short-card .shade { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(7, 10, 16, .92)); }
.short-info { position: absolute; left: 12px; right: 12px; bottom: 12px; }
.short-title { font-size: 13px; font-weight: 600; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.short-badge {
  position: absolute; top: 10px; left: 10px; font-family: var(--font-mono); font-size: 9px;
  letter-spacing: .18em; color: #fff; background: rgba(255, 46, 63, .85); padding: 3px 8px; border-radius: 4px;
}
.shorts-head-icon { display: flex; align-items: center; gap: 7px; color: var(--red); }

/* ============ DETAIL BERITA ============ */
.detail { max-width: 880px; margin: 0 auto; }
.detail-back {
  display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono);
  font-size: 11px; letter-spacing: .12em; color: var(--muted); margin: 26px 0 16px; cursor: pointer;
}
.detail-back:hover { color: var(--red); }
.detail-title {
  font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 3.6vw, 42px);
  line-height: 1.14; text-transform: uppercase; margin: 12px 0 16px;
}
.detail-meta {
  display: flex; flex-wrap: wrap; gap: 10px 18px; align-items: center;
  font-family: var(--font-mono); font-size: 11.5px; color: var(--muted);
  padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 24px;
}
.detail-hero { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); aspect-ratio: 16/8; margin-bottom: 26px; position: relative; }
.detail-hero img { width: 100%; height: 100%; object-fit: cover; }

.article-body { font-size: 16.5px; line-height: 1.85; color: #d5dcea; }
.article-body h2, .article-body h3 {
  font-family: var(--font-display); text-transform: uppercase; letter-spacing: .02em;
  color: #fff; margin: 34px 0 14px; line-height: 1.25;
}
.article-body h2 { font-size: 23px; border-left: 4px solid var(--red); padding-left: 14px; }
.article-body h3 { font-size: 18px; color: var(--cyan); }
.article-body p { margin: 16px 0; }
.article-body a { color: var(--cyan); text-decoration: underline; }
.article-body ul, .article-body ol { margin: 16px 0 16px 24px; }
.article-body li { margin: 7px 0; }
.article-body blockquote {
  border-left: 3px solid var(--red); background: rgba(255, 46, 63, .06);
  padding: 16px 22px; margin: 22px 0; font-style: italic; color: #fff; border-radius: 0 10px 10px 0;
}
.article-body img { border-radius: 10px; margin: 18px auto; }
.article-body strong { color: #fff; }
.article-body pre { background: var(--panel2); border: 1px solid var(--line); border-radius: 8px; padding: 16px; overflow-x: auto; font-family: var(--font-mono); font-size: 13px; margin: 18px 0; }

/* video landscape di detail */
.video-wrap { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: #000; margin-bottom: 26px; }
.video-wrap video { width: 100%; aspect-ratio: 16 / 9; display: block; }

/* reels di detail */
.reels-wrap { display: grid; place-items: center; background: #000; border-radius: var(--radius); border: 1px solid var(--line); padding: 20px 0; margin-bottom: 26px; }
.reels-wrap video { height: min(72vh, 620px); aspect-ratio: 9 / 16; border-radius: 12px; background: #000; }

/* pdf / dokumen */
.doc-wrap { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin-bottom: 26px; background: var(--panel2); }
.doc-head { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.doc-head .fname { font-family: var(--font-mono); font-size: 12px; color: var(--cyan); word-break: break-all; }
.doc-head a {
  margin-left: auto; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em;
  border: 1px solid var(--line2); padding: 6px 14px; border-radius: 6px; color: var(--txt);
}
.doc-head a:hover { border-color: var(--red); color: var(--red); }
.doc-body { padding: 26px 30px; }
.doc-body .article-body { max-width: 760px; margin: 0 auto; }
.doc-frame { width: 100%; height: 76vh; border: none; display: block; background: #fff; }

/* ============ SHORTS PAGE ============ */
.shorts-feed {
  height: calc(100vh - 62px); overflow-y: auto; scroll-snap-type: y mandatory;
  background: #04070c; margin-top: -26px;
}
.shorts-item { height: calc(100vh - 62px); scroll-snap-align: start; display: grid; place-items: center; position: relative; }
.shorts-item video { height: 100%; aspect-ratio: 9/16; object-fit: contain; }
.shorts-item .shade { position: absolute; inset: 0; background: radial-gradient(transparent 40%, rgba(4, 7, 12, .55)); pointer-events: none; }
.shorts-item .info {
  position: absolute; left: 50%; transform: translateX(-50%); bottom: 28px; width: min(420px, 86vw);
  text-align: center; pointer-events: auto;
}
.shorts-item .short-title { font-family: var(--font-display); font-size: 19px; text-transform: uppercase; }

/* ============ TICKER BAWAH ============ */
.ticker {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 80; height: 46px;
  background: #05080d; border-top: 2px solid var(--red-dark);
  display: flex; align-items: center; overflow: hidden;
}
.ticker-label {
  flex: 0 0 auto; display: flex; align-items: center; gap: 8px; height: 100%;
  background: linear-gradient(135deg, var(--red), var(--red-dark));
  color: #fff; font-family: var(--font-display); font-weight: 600; font-size: 12px;
  letter-spacing: .16em; text-transform: uppercase; padding: 0 18px; position: relative; z-index: 2;
  box-shadow: 4px 0 18px rgba(255, 46, 63, .4);
}
.ticker-track { flex: 1; overflow: hidden; position: relative; }
.ticker-move { display: inline-flex; white-space: nowrap; will-change: transform; animation: tickmove 40s linear infinite; }
.ticker-move:hover { animation-play-state: paused; }
.ticker-item {
  font-family: var(--font-mono); font-size: 12.5px; color: #d7deec; padding: 0 26px; display: inline-flex; align-items: center; gap: 10px;
}
.ticker-item::before { content: '◆'; color: var(--red); font-size: 9px; }
@keyframes tickmove { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ============ POPUP MODAL ============ */
.popup-mask {
  position: fixed; inset: 0; z-index: 120; background: rgba(4, 7, 12, .8);
  backdrop-filter: blur(6px); display: grid; place-items: center; padding: 20px;
  animation: fadein .3s ease;
}
@keyframes fadein { from { opacity: 0; } }
.popup-card {
  width: min(560px, 94vw); background: var(--panel); border: 1px solid var(--line2);
  border-radius: 14px; overflow: hidden; box-shadow: var(--shadow);
  animation: pop .35s cubic-bezier(.2, 1.4, .4, 1);
}
@keyframes pop { from { transform: scale(.85) translateY(20px); opacity: 0; } }
.popup-top { background: linear-gradient(135deg, var(--red), var(--red-dark)); padding: 12px 20px; display: flex; align-items: center; gap: 10px; }
.popup-top b { font-family: var(--font-display); letter-spacing: .14em; font-size: 13px; text-transform: uppercase; color: #fff; }
.popup-top button { margin-left: auto; background: none; border: none; color: #fff; font-size: 20px; }
.popup-body { padding: 26px; cursor: pointer; }
.popup-body h3 { font-family: var(--font-display); font-size: 22px; line-height: 1.25; text-transform: uppercase; margin-bottom: 12px; }
.popup-body p { color: var(--muted); font-size: 14px; line-height: 1.6; }
.popup-cta { display: inline-flex; margin-top: 16px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .14em; color: var(--red); }

/* ============ FOOTER ============ */
.footer { margin-top: 60px; border-top: 1px solid var(--line); background: var(--bg2); padding: 34px 0 26px; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
.footer-note { font-family: var(--font-mono); font-size: 11px; color: var(--muted); letter-spacing: .08em; }

/* ============ MISC ============ */
.loading { display: grid; place-items: center; padding: 60px 0; color: var(--muted); font-family: var(--font-mono); font-size: 12px; letter-spacing: .2em; }
.loading::after { content: '▮▮▮'; margin-top: 10px; color: var(--red); animation: blink 1s infinite; }
.errbox { background: rgba(255, 46, 63, .08); border: 1px solid rgba(255, 46, 63, .4); color: #ff9aa3; border-radius: 10px; padding: 18px 22px; margin: 30px auto; max-width: 640px; text-align: center; font-size: 14px; }
.empty { text-align: center; color: var(--muted); padding: 50px 0; font-size: 14px; }
.load-more {
  display: block; margin: 26px auto 0; background: none; border: 1px solid var(--line2); color: var(--txt);
  font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .16em; padding: 12px 34px; border-radius: 30px;
  transition: all .2s;
}
.load-more:hover { border-color: var(--red); color: var(--red); box-shadow: 0 0 20px rgba(255, 46, 63, .25); }

.page-head {
  margin: 30px 0 8px; display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap;
}
.page-head h1 { font-family: var(--font-display); font-size: 30px; font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.page-head h1 span { color: var(--red); }
.page-head .sub { font-family: var(--font-mono); font-size: 11px; color: var(--muted); letter-spacing: .1em; }

/* ============ MOBILE MENU OVERLAY ============ */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(7, 10, 16, .96);
  backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  opacity: 0;
  visibility: hidden;
  transition: opacity .25s ease, visibility .25s ease;
  padding: max(var(--safe-area-inset-top), 20px) 20px 20px;
}
.mobile-menu.open {
  opacity: 1;
  visibility: visible;
}
.mobile-menu-header {
  display: flex; align-items: center; justify-content: space-between; padding-bottom: 16px; border-bottom: 1px solid var(--line); margin-bottom: 20px;
}
.mobile-menu-header .logo-text { font-size: 20px; }
.mobile-menu-close {
  background: none; border: none; color: var(--txt); font-size: 24px; padding: 4px; border-radius: 6px;
}
.mobile-menu-nav { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.mobile-menu-nav a {
  font-family: var(--font-display); font-weight: 600; font-size: 17px;
  letter-spacing: .04em; text-transform: uppercase; color: var(--muted);
  padding: 14px 16px; border-radius: 10px; display: block; transition: all .18s;
}
.mobile-menu-nav a:hover { color: #fff; background: rgba(255,255,255,.06); }
.mobile-menu-nav a.active { color: #fff; background: rgba(255,46,63,.15); }
.mobile-menu-footer { padding-top: 20px; border-top: 1px solid var(--line); font-family: var(--font-mono); font-size: 11px; color: var(--muted); letter-spacing: .1em; }
.mobile-menu-footer .admin-link { color: var(--red); text-decoration: underline; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1020px) {
  .cols { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 700px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .nav { display: none; }
  .mobile-menu-btn { display: block; }
  .searchbox input { width: 130px; }
  .searchbox input:focus { width: 160px; }
  .slide-meta { left: 18px; right: 18px; bottom: 18px; }
  .slider-arrow { display: none; }
  .logo-sub { display: none; }
  .live-pill { display: none; }
  .topbar-inner { padding: 0 14px; gap: 10px; }
  .logo-mark { width: 32px; height: 32px; font-size: 14px; }
  .logo-text { font-size: 20px; }
  body { padding-bottom: 64px; } /* lebih ruang untuk ticker di ponsel */
}
@media (max-width: 480px) {
  .wrap { padding: 0 14px; }
  .page-head h1 { font-size: 22px; }
  .detail-title { font-size: 24px; line-height: 1.25; }
  .topbar-inner { height: 56px; }
  .mobile-menu-btn { font-size: 22px; padding: 5px; }
}
/* PWA standalone adjustments */
body.pwa-standalone { padding-top: max(var(--safe-area-inset-top), 0); }
.pwa-standalone .topbar { position: fixed; width: 100%; }

/* ===== Tema Nuansa Warna (konsisten dengan admin) ===== */
body[data-theme="matrix"] {
  --red: #00ff41;
  --red-dark: #00cc33;
  --cyan: #00ff41;
  --amber: #00cc33;
  --green: #00ff41;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(0, 255, 65, .1), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(0, 255, 65, .04), transparent 60%);
}
body[data-theme="sunset"] {
  --red: #ff6b35;
  --red-dark: #e5512b;
  --cyan: #ff9f43;
  --amber: #feca57;
  --green: #ff6b35;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(255, 107, 53, .12), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(255, 107, 53, .05), transparent 60%);
}
body[data-theme="cyber"] {
  --red: #bc13fe;
  --red-dark: #a119e0;
  --cyan: #00f2ff;
  --amber: #ff00ff;
  --green: #bc13fe;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(188, 19, 254, .12), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(188, 19, 254, .05), transparent 60%);
}
body[data-theme="midnight"] {
  --bg: #02040a;
  --bg2: #04060c;
  --panel: #080c14;
  --panel2: #05080e;
  --line: #141c2e;
  --line2: #1e2a44;
  --txt: #b8c2d6;
  --muted: #6b7a98;
  --red: #2d8bff;
  --red-dark: #1e6fd0;
  --cyan: #6c9cff;
  --amber: #8ab4ff;
  --green: #2d8bff;
  background-image: none;
}
body[data-theme="forest"] {
  --red: #4ade80;
  --red-dark: #22c55e;
  --cyan: #4ade80;
  --amber: #a3e635;
  --green: #4ade80;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(74, 222, 128, .1), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(74, 222, 128, .04), transparent 60%);
}
body[data-theme="ocean"] {
  --red: #22d3ee;
  --red-dark: #0891b2;
  --cyan: #22d3ee;
  --amber: #67e8f9;
  --green: #22d3ee;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(34, 211, 238, .1), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(34, 211, 238, .04), transparent 60%);
}
body[data-theme="vintage"] {
  --red: #f59e0b;
  --red-dark: #d97706;
  --cyan: #f59e0b;
  --amber: #fbbf24;
  --green: #f59e0b;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(245, 158, 11, .1), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(245, 158, 11, .04), transparent 60%);
}
body[data-theme="neon"] {
  --red: #39ff14;
  --red-dark: #2ecc10;
  --cyan: #39ff14;
  --amber: #39ff14;
  --green: #39ff14;
  background-image: radial-gradient(1100px 500px at 85% -10%, rgba(57, 255, 20, .12), transparent 60%),
                    radial-gradient(900px 600px at -10% 20%, rgba(57, 255, 20, .05), transparent 60%);
}
