:root {
  --bg: #0e0e12;
  --bg-raised: #16161d;
  --bg-card: #16161d;
  --border: #2a2a33;
  --text: #e6e6e6;
  --text-muted: #9aa1ac;
  --text-faint: #6b6b76;
  --accent: #ff2d55;
  --accent-2: #e91e63;
  --accent-hover: #ff5c82;
  --accent-glow: rgba(255, 45, 85, 0.35);
  --font-display: "Bebas Neue", system-ui, sans-serif;
  --font-body: "Raleway", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

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

.staging-banner {
  background: #eab308;
  color: #000;
  text-align: center;
  font-weight: 700;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 6px;
}

.cookie-consent {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 150;
  background: var(--bg-card); border-top: 1px solid var(--border);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.3);
}
.cookie-consent-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 16px; flex-wrap: wrap;
}
.cookie-consent-inner p { margin: 0; color: var(--text-muted); font-size: 0.85rem; max-width: 70ch; }
.cookie-consent-inner a { color: var(--accent); }
.cookie-consent-actions { display: flex; gap: 10px; flex-shrink: 0; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(14, 14, 18, 0.6);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 14px 16px; }
.logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.logo-img { height: 42px; width: auto; display: block; }
.logo-fallback {
  display: none;
  font-family: var(--font-display);
  font-size: 1.7rem;
  letter-spacing: 0.02em;
  flex-direction: column;
  line-height: 0.95;
  text-transform: uppercase;
}
.logo-fallback span { color: var(--accent); }
.site-header nav { display: flex; gap: 28px; flex: 1; }
.site-header nav a {
  font-family: var(--font-body);
  font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--text-muted); padding-bottom: 4px; border-bottom: 2px solid transparent;
}
.site-header nav a:hover { color: var(--text); }
.site-header nav a.active { color: var(--accent); border-bottom-color: var(--accent); }

.header-search {
  display: flex; align-items: center; gap: 8px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 999px;
  padding: 9px 18px; flex-shrink: 0;
}
.header-search-icon { display: flex; color: var(--text-faint); }
.header-search input {
  background: transparent; border: none; outline: none; color: var(--text);
  font-family: var(--font-body); font-size: 0.8rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.03em; width: 130px;
}
.header-search input::placeholder { color: var(--text-faint); }

main.wrap { padding: 32px 16px; }

.hero-full {
  position: relative;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  margin-right: calc(-50vw + 50%);
  margin-top: -80px; /* pulls the image up to bleed behind the sticky header */
  min-height: 620px;
  overflow: hidden;
}
.hero-full-media { position: absolute; inset: 0; z-index: 0; background: var(--bg-card); }
.hero-full-image { width: 100%; height: 100%; object-fit: cover; }
.hero-full-fade {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(14,14,18,0.75) 0%, rgba(14,14,18,0.35) 45%, rgba(14,14,18,0.05) 65%),
    linear-gradient(180deg, rgba(14,14,18,0.45) 0%, rgba(14,14,18,0.1) 35%, rgba(14,14,18,0.5) 75%, rgba(14,14,18,0.92) 100%);
}
/* .hero-full-inner is a normal, non-flex block — its own centering (from
   the .wrap class: max-width:1200px + margin:auto) is unambiguous here.
   Its children are then pinned with plain position:absolute, which does
   not depend on any flex/auto-margin interaction at all. */
.hero-full-inner {
  position: relative;
  z-index: 1;
  height: 620px;
}
.hero-full-text {
  position: absolute;
  left: 16px;
  top: calc(80px + 56px);
  max-width: 560px;
}
.hero-eyebrow { width: 32px; height: 3px; background: var(--accent); margin: 0 0 16px; }
.hero-title { font-family: var(--font-display); font-weight: 400; font-size: 3.4rem; line-height: 0.95; margin: 0 0 16px; letter-spacing: 0.01em; text-transform: uppercase; }
.hero-title .highlight {
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-subtitle { color: var(--text-muted); font-size: 1rem; line-height: 1.5; margin: 0 0 24px; }
.hero-cta { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 12px 24px; font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.03em; }

.hero-full .category-tabs { position: absolute; left: 16px; right: 16px; bottom: 28px; margin: 0; }

@media (max-width: 900px) {
  .hero-full { margin-top: -70px; min-height: 680px; }
  .hero-full-inner { height: 680px; }
  .hero-full-text { top: calc(70px + 40px); max-width: calc(100% - 32px); }
  .header-search { display: none; }
}

.category-tabs { display: flex; gap: 10px; flex-wrap: wrap; margin: 8px 0 36px; }
.tab {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 10px 18px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--bg-card); color: var(--text-muted);
  font-family: var(--font-body);
  font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em;
}
.tab:hover { border-color: var(--accent); color: var(--text); }
.tab.active { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 20px var(--accent-glow); }
.tab-icon { display: flex; align-items: center; }

h1, h2, h3 { font-weight: 700; }
.page-title { font-family: var(--font-display); font-size: 2.2rem; text-transform: uppercase; letter-spacing: 0.01em; margin-bottom: 24px; }

.section { margin-bottom: 56px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; }
.section-head h2 { font-family: var(--font-display); font-size: 1.8rem; text-transform: uppercase; letter-spacing: 0.01em; margin: 0; font-weight: 400; }
.more-link { color: var(--accent); font-weight: 600; font-size: 0.9rem; }
.more-link:hover { color: var(--accent-hover); }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: border-color 0.15s, transform 0.15s;
}
.card:hover { border-color: var(--accent); transform: translateY(-2px); }
.card-image { display: block; position: relative; height: 190px; width: 100%; background: var(--bg-raised); overflow: hidden; }
.card-image img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 0.2s; }
.card:hover .card-image img { transform: scale(1.04); }
.card-badge {
  position: absolute; top: 10px; left: 10px;
  background: var(--accent); color: #fff;
  font-size: 0.65rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
  padding: 4px 10px; border-radius: 999px;
}
.card-body { padding: 14px 16px; }
.card-title { font-family: var(--font-body); font-weight: 700; font-size: 1.02rem; margin: 0 0 8px; line-height: 1.35; color: var(--text); }
.card-title a { color: var(--text); }
.card-title a:hover { color: var(--accent); }
.card-excerpt { font-size: 0.85rem; color: var(--text-muted); line-height: 1.5; margin: 0 0 10px; }
.card-meta { display: flex; gap: 14px; font-size: 0.75rem; color: var(--text-faint); margin: 0; }
.card-meta span { display: inline-flex; align-items: center; gap: 5px; }

.chip {
  display: inline-block;
  background: rgba(255, 45, 110, 0.12);
  color: var(--accent);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 999px;
}

.breadcrumb { font-size: 0.85rem; color: var(--text-faint); margin-bottom: 16px; }
.breadcrumb a:hover { color: var(--text-muted); }

.article-title { font-family: var(--font-body); font-weight: 800; font-size: 2rem; margin: 12px 0; line-height: 1.25; }
.article-meta { display: flex; gap: 10px; align-items: center; color: var(--text-muted); font-size: 0.9rem; margin-bottom: 20px; }
.article-hero { position: relative; aspect-ratio: 16 / 9; max-height: 500px; border-radius: 10px; overflow: hidden; margin-bottom: 24px; background: var(--bg-raised); }
.article-hero img { display: block; width: 100%; height: 100%; object-fit: cover; }

.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; align-items: start; }
.article-sidebar { position: sticky; top: 80px; display: flex; flex-direction: column; gap: 20px; }
@media (max-width: 900px) {
  .article-layout { grid-template-columns: 1fr; }
  .article-sidebar { position: static; }
}

.ad-slot { display: block; width: 100%; text-align: center; }
.ad-slot-header { margin: 16px 0; }
.ad-slot-in_article { margin: 32px 0; }
.ad-slot-manual { margin: 28px 0; }

.fb-promo { display: block; margin: 28px 0; border-radius: 10px; overflow: hidden; transition: opacity 0.15s; }
.fb-promo:hover { opacity: 0.9; }
.fb-promo img { display: block; width: 100%; height: auto; }

.sidebar-widget { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 16px; }
.sidebar-widget h3 { margin: 0 0 12px; font-size: 1rem; }
.sidebar-item { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid var(--border); }
.sidebar-item:first-of-type { border-top: none; padding-top: 0; }
.sidebar-item img { width: 56px; height: 56px; object-fit: cover; border-radius: 6px; flex-shrink: 0; }
.sidebar-item span { font-size: 0.85rem; line-height: 1.3; }
.sidebar-item:hover span { color: var(--accent); }

.article-body { max-width: none; }
.article-body h2 { font-size: 1.5rem; margin: 32px 0 12px; }
.article-body h3 { font-size: 1.25rem; margin: 24px 0 8px; }
.article-body p { margin: 0 0 16px; color: rgba(232,234,237,0.9); }
.article-body ul { margin: 0 0 16px; padding-left: 24px; }
.article-body img { border-radius: 10px; margin: 24px 0; }
.article-body blockquote { border-left: 3px solid var(--accent); margin: 16px 0; padding: 4px 0 4px 16px; color: var(--text-muted); }
.article-body a { color: var(--accent); text-decoration: underline; }
.article-body code {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 4px;
  padding: 2px 6px; font-family: ui-monospace, "SF Mono", Consolas, monospace; font-size: 0.88em;
}
.article-body pre {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 8px;
  padding: 16px 18px; margin: 20px 0; overflow-x: auto;
}
.article-body pre code {
  background: none; border: none; padding: 0; font-size: 0.85rem; line-height: 1.6; white-space: pre;
}
.video-embed { aspect-ratio: 16/9; margin: 24px 0; }
.video-embed iframe { width: 100%; height: 100%; border: 0; border-radius: 10px; }

.article-body blockquote.twitter-tweet {
  border-left: none; margin: 24px auto; max-width: 550px; padding: 16px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; color: var(--text-muted);
}

.article-body table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 0.92rem; }
.article-body th, .article-body td { padding: 10px 14px; border: 1px solid var(--border); text-align: left; }
.article-body th { background: var(--bg-card); font-weight: 700; }
.article-body tbody tr:nth-child(even) td { background: rgba(255,255,255,0.02); }

.article-body video { width: 100%; height: auto; border-radius: 10px; margin: 24px 0; display: block; background: #000; }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; margin: 24px 0; }
.gallery-item { display: block; aspect-ratio: 1; border-radius: 8px; overflow: hidden; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.15s; }
.gallery-item:hover img { transform: scale(1.06); }

.lightbox-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.92); display: none; align-items: center; justify-content: center; z-index: 100; }
.lightbox-overlay.open { display: flex; }
.lightbox-img { max-width: 88vw; max-height: 88vh; border-radius: 6px; }
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute; background: transparent; border: none; color: #fff;
  font-size: 1.8rem; cursor: pointer; padding: 12px; line-height: 1;
}
.lightbox-close { top: 12px; right: 20px; font-size: 2rem; }
.lightbox-prev { left: 8px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 8px; top: 50%; transform: translateY(-50%); }
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { color: var(--accent); }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 32px; padding-top: 24px; border-top: 1px solid var(--border); }
.tags a { border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px; font-size: 0.8rem; color: var(--text-muted); }
.tags a:hover { border-color: var(--accent); color: var(--accent); }

.pagination { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 40px; }
.pagination a, .pagination span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 38px; height: 38px; padding: 0 4px;
  border-radius: 999px; border: 1px solid var(--border);
  font-size: 0.9rem; color: var(--text-muted);
}
.pagination .current { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 700; }
.pagination a:hover { border-color: var(--accent); color: var(--text); }
.pagination .arrow { color: var(--text); }
.pagination .arrow.disabled { opacity: 0.3; pointer-events: none; }

.site-footer { border-top: 1px solid var(--border); margin-top: 64px; padding: 40px 0; color: var(--text-faint); font-size: 0.9rem; }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.footer-inner nav a { margin-right: 16px; }
.footer-inner nav a:hover { color: var(--text-muted); }

/* Admin */
.admin-body { background: var(--bg-raised); min-height: 100vh; }
.admin-header { background: var(--bg); border-bottom: 1px solid var(--border); padding: 16px 0; }
.admin-header .wrap { display: flex; align-items: center; justify-content: space-between; }
.admin-nav { display: flex; gap: 20px; }
.admin-nav a { color: var(--text-muted); font-size: 0.9rem; }
.admin-nav a:hover { color: var(--text); }
.admin-main { padding: 32px 16px; max-width: 1200px; margin: 0 auto; }

.btn {
  display: inline-block;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-family: var(--font-body);
}
.btn:hover { border-color: var(--accent); }
.btn-accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn-outline { background: transparent; border: 1.5px solid var(--accent); color: var(--accent); font-weight: 700; }
.btn-outline:hover { background: rgba(255, 45, 85, 0.08); border-color: var(--accent-hover); color: var(--accent-hover); }

.form-field { margin-bottom: 18px; }
.form-field label { display: block; font-size: 0.9rem; font-weight: 600; margin-bottom: 6px; }
.form-field input[type=text], .form-field input[type=email], .form-field input[type=password],
.form-field input[type=datetime-local], .form-field input[type=file],
.form-field textarea, .form-field select {
  width: 100%;
  padding: 8px 12px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  color: var(--text);
  font-size: 0.9rem;
  font-family: inherit;
}
.form-field textarea { font-family: ui-monospace, monospace; }
.form-hint { font-size: 0.8rem; color: var(--text-faint); margin-top: 4px; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.editor-tabs { display: flex; gap: 2px; margin-bottom: -1px; }
.editor-tab {
  border: 1px solid var(--border); border-bottom: none; background: var(--bg-raised);
  color: var(--text-muted); padding: 8px 18px; font-size: 0.85rem; font-weight: 600;
  border-radius: 6px 6px 0 0; cursor: pointer;
}
.editor-tab.active { background: var(--bg-card); color: var(--text); border-bottom: 1px solid var(--bg-card); }
.editor-tab:hover:not(.active) { color: var(--text); }

.toolbar { display: flex; flex-wrap: wrap; gap: 4px; background: var(--bg-card); border: 1px solid var(--border); border-bottom: 0; border-radius: 6px 6px 0 0; padding: 8px; }
.toolbar button { border: 1px solid var(--border); background: transparent; color: var(--text-muted); border-radius: 4px; padding: 4px 8px; font-size: 0.75rem; cursor: pointer; }
.toolbar button:hover { border-color: var(--accent); color: var(--accent); }
#content-editor { border-radius: 0 0 6px 6px; min-height: 320px; }

.visual-editor {
  border: 1px solid var(--border); border-radius: 0 0 6px 6px; background: var(--bg-card);
  min-height: 320px; padding: 16px 18px; max-width: none;
}
.visual-editor:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.visual-editor .editor-embed {
  background: var(--bg-raised); border: 1px dashed var(--border); border-radius: 8px;
  padding: 14px; margin: 12px 0; text-align: center; color: var(--text-muted);
  font-size: 0.9rem; user-select: none;
}

.media-modal {
  position: fixed; inset: 0; background: rgba(0,0,0,0.7);
  display: flex; align-items: center; justify-content: center; z-index: 200; padding: 20px;
}
.media-modal-inner {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px;
  width: 100%; max-width: 800px; max-height: 80vh; display: flex; flex-direction: column;
}
.media-modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.media-modal-header h3 { margin: 0; font-size: 1rem; }
.media-modal-close { background: none; border: none; color: var(--text-muted); font-size: 1.5rem; cursor: pointer; line-height: 1; }
.media-modal-close:hover { color: var(--accent); }
.media-modal-grid {
  padding: 20px; overflow-y: auto;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px;
}
.media-thumb {
  display: block; width: 100%; height: 110px;
  border-radius: 6px; overflow: hidden; border: 2px solid var(--border);
  background: var(--bg-raised); cursor: pointer; padding: 0;
}
.media-thumb:hover { border-color: var(--accent); }
.media-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }

.alert { padding: 10px 14px; border-radius: 6px; font-size: 0.9rem; margin-bottom: 16px; }
.alert-error { background: rgba(255,77,79,0.1); border: 1px solid rgba(255,77,79,0.4); color: var(--accent); }
.alert-warn { color: #eab308; }

table.admin-table { width: 100%; border-collapse: collapse; background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
table.admin-table th, table.admin-table td { padding: 12px; text-align: left; font-size: 0.9rem; border-top: 1px solid var(--border); }
table.admin-table th { background: var(--bg-card); color: var(--text-muted); border-top: none; }

.badge { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 700; }
.badge-draft { background: rgba(154,161,172,0.2); color: var(--text-muted); }
.badge-scheduled { background: rgba(234,179,8,0.15); color: #eab308; }
.badge-published { background: rgba(34,197,94,0.15); color: #22c55e; }

.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 16px; }
.login-box { width: 100%; max-width: 380px; background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 32px; }

.seo-preview { background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px; padding: 16px; }
.google-preview { background: #fff; border-radius: 6px; padding: 12px; margin-bottom: 20px; }
.google-preview .url { font-size: 0.75rem; color: #4d5156; }
.google-preview .title { font-size: 1.1rem; color: #1a0dab; margin: 2px 0; }
.google-preview .desc { font-size: 0.85rem; color: #4d5156; }
.social-preview { border: 1px solid var(--border); border-radius: 6px; overflow: hidden; margin-bottom: 20px; }
.social-preview .img { aspect-ratio: 1.91/1; background: var(--bg-raised); }
.social-preview .img img { width: 100%; height: 100%; object-fit: cover; }
.social-preview .body { padding: 10px; }

@media (max-width: 640px) {
  .site-header nav a { margin-left: 12px; font-size: 0.8rem; }
  .two-col { grid-template-columns: 1fr; }
}
