/* =====================
   01. TOKENS
===================== */

:root {
  --bg: #04070d;
  --bg-2: #0b1320;

  --text: #e8edf5;
  --text-2: #b0bac8;
  --text-3: #7b8798;

  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.12);

  --accent-blue: #3aa7e2;
  --accent-green: #b7f13d;
  --accent-green-2: #99eb45;

  --radius-xl: 28px;
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --radius-pill: 999px;

  --shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
  --blur: blur(18px);
}

/* =====================
   02. BASE
===================== */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, sans-serif;
}

body {
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

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

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

button {
  appearance: none;
  -webkit-appearance: none;
}

/* =====================
   03. BACKGROUND
===================== */

.page-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.page-bg__gradient,
.page-bg__grid,
.page-bg__glow,
.page-bg__vignette {
  position: absolute;
  inset: 0;
}

.page-bg__gradient {
  background:
    radial-gradient(circle at 12% 16%, rgba(183, 241, 61, 0.12), transparent 24%),
    radial-gradient(circle at 82% 22%, rgba(58, 167, 226, 0.12), transparent 26%),
    radial-gradient(circle at 78% 82%, rgba(58, 167, 226, 0.08), transparent 26%),
    linear-gradient(180deg, #02050a 0%, #08111d 100%);
}

.page-bg__grid {
  background-image:
    linear-gradient(rgba(255,255,255,0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.045) 1px, transparent 1px);
  background-size: 68px 68px;
}

.page-bg__glow {
  filter: blur(34px);
  border-radius: 999px;
}

.page-bg__glow--1 {
  inset: auto auto 58% 60%;
  width: 700px;
  height: 700px;
  background: radial-gradient(circle, rgba(58,167,226,0.14) 0%, rgba(58,167,226,0.05) 34%, rgba(58,167,226,0) 72%);
}

.page-bg__glow--2 {
  inset: 68% auto auto -6%;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(183,241,61,0.08) 0%, rgba(183,241,61,0.03) 34%, rgba(183,241,61,0) 72%);
}

.page-bg__vignette {
  background:
    linear-gradient(180deg, rgba(3,8,20,0.08) 0%, rgba(3,8,20,0) 18%, rgba(3,8,20,0) 78%, rgba(3,8,20,0.18) 100%),
    linear-gradient(90deg, rgba(2,8,20,0.14) 0%, rgba(2,8,20,0) 12%, rgba(2,8,20,0) 88%, rgba(2,8,20,0.10) 100%);
}

/* =====================
   04. PANELS
===================== */

.panel {
  position: relative;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.01) 100%),
    rgba(13, 24, 40, 0.72);
  box-shadow: var(--shadow);
  overflow: hidden;
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0) 42%);
  pointer-events: none;
}

/* =====================
   05. LAYOUT
===================== */

.shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* =====================
   06. HEADER
===================== */

.site-header {
  border-bottom: 1px solid var(--line);
  background: rgba(4, 7, 13, 0.72);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.site-header__logo {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-header__logo-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-green);
}


/* =====================
   07. CATALOG LAYOUT
===================== */

.catalog-wrap {
  padding: 40px 0 80px;
}

.catalog-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
  align-items: start;
}

/* =====================
   08. SIDEBAR / FILTERS
===================== */

.sidebar {
  position: sticky;
  top: 88px;
  padding: 24px;
}

.sidebar__title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  margin: 0 0 12px;
}

.sidebar__section {
  margin-bottom: 24px;
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.filter-btn {
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-3);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: border-color 160ms ease, color 160ms ease, background 160ms ease;
}

.filter-btn:hover {
  border-color: var(--line-2);
  color: var(--text-2);
}

.filter-btn.active {
  border-color: var(--accent-blue);
  color: var(--accent-blue);
  background: rgba(58, 167, 226, 0.08);
}

.filter-btn--reset {
  color: var(--text-3);
  border-color: transparent;
  font-size: 11px;
  padding: 4px 10px;
}

.filter-btn--reset:hover {
  color: var(--text-2);
  border-color: var(--line);
}

/* =====================
   09. CARD GRID
===================== */

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

.article-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-xl);
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.01) 100%),
    rgba(13, 24, 40, 0.72);
  box-shadow: var(--shadow);
  overflow: hidden;
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  transition: border-color 200ms ease, transform 200ms ease;
  text-decoration: none;
  color: var(--text);
}

.article-card:hover {
  border-color: var(--line-2);
  transform: translateY(-2px);
}

.article-card__image {
  aspect-ratio: 16 / 9;
  background: var(--bg-2);
  overflow: hidden;
}

.article-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-card__image--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 30% 40%, rgba(58,167,226,0.08) 0%, transparent 60%),
    var(--bg-2);
}

.article-card__image--placeholder span {
  font-size: 32px;
  opacity: 0.2;
}

.article-card__body {
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 10px;
}

.article-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.article-card__date {
  font-size: 11px;
  color: var(--text-3);
}

.article-card__title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0;
}

.article-card__excerpt {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-2);
  margin: 0;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 4px;
}

/* =====================
   10. TAGS / BADGES
===================== */

.tag-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.04);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-3);
  white-space: nowrap;
}

.badge-product {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(58, 167, 226, 0.3);
  background: rgba(58, 167, 226, 0.08);
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-blue);
  white-space: nowrap;
}

/* =====================
   11. EMPTY STATE
===================== */

.empty-state {
  grid-column: 1 / -1;
  padding: 80px 40px;
  text-align: center;
  border-radius: var(--radius-xl);
  border: 1px dashed var(--line);
  background: rgba(13, 24, 40, 0.4);
}

.empty-state__icon {
  font-size: 40px;
  margin-bottom: 16px;
  opacity: 0.4;
}

.empty-state__title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-2);
  margin: 0 0 8px;
}

.empty-state__text {
  font-size: 13px;
  color: var(--text-3);
  margin: 0;
}

/* =====================
   12. FOOTER
===================== */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 48px 0 40px;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
}

.site-footer__col-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 14px;
}

.site-footer__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.site-footer__link {
  font-size: 13px;
  color: var(--text-3);
  transition: color 160ms ease;
}

.site-footer__link:hover {
  color: var(--text);
}

.site-footer__col--right {
  text-align: right;
}

.site-footer__sign {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
  margin: 0 0 6px;
}

.site-footer__copy {
  font-size: 12px;
  color: var(--text-3);
  margin: 0;
}

/* =====================
   13. PAGE HEADER
===================== */

.page-header {
  padding: 48px 0 32px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 0;
}

.page-header__eyebrow {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-green);
  margin: 0 0 12px;
}

.page-header__title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  margin: 0 0 12px;
}

.page-header__desc {
  font-size: 15px;
  color: var(--text-2);
  margin: 0;
  max-width: 520px;
  line-height: 1.6;
}

/* =====================
   14. NO-RESULTS
===================== */

.no-results {
  display: none;
  grid-column: 1 / -1;
  padding: 48px 32px;
  text-align: center;
  color: var(--text-3);
  font-size: 14px;
}

/* =====================
   15. ARTICLE DETAIL
===================== */

.article-wrap {
  max-width: 740px;
  margin: 0 auto;
  padding: 40px 0 80px;
}

.article-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-3);
  margin-bottom: 32px;
  transition: color 160ms ease;
}

.article-breadcrumb:hover {
  color: var(--accent-blue);
}

.article-breadcrumb::before {
  content: "←";
}

.article-header {
  margin-bottom: 40px;
}

.article-header__eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.article-header__date {
  font-size: 13px;
  color: var(--text-3);
}

.article-header__title {
  font-size: clamp(24px, 4vw, 38px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.25;
  color: var(--text);
  margin: 0 0 20px;
}

.article-header__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* =====================
   16. ARTICLE BODY (PROSE)
===================== */

.article-body {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-2);
}

.article-body h2 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 2.4em 0 0.6em;
}

.article-body h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  margin: 2em 0 0.5em;
}

.article-body h4 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-2);
  margin: 1.6em 0 0.4em;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.article-body p {
  margin: 0 0 1.2em;
}

.article-body ul,
.article-body ol {
  padding-left: 1.4em;
  margin: 0 0 1.2em;
}

.article-body li {
  margin-bottom: 0.4em;
}

.article-body strong {
  color: var(--text);
  font-weight: 600;
}

.article-body a {
  color: var(--accent-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: opacity 160ms ease;
}

.article-body a:hover {
  opacity: 0.8;
}

.article-body code {
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 0.875em;
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  color: var(--accent-green);
}

.article-body pre {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  overflow-x: auto;
  margin: 0 0 1.4em;
}

.article-body pre code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.88em;
  color: var(--text-2);
}

.article-body blockquote {
  border-left: 3px solid var(--accent-blue);
  margin: 0 0 1.4em;
  padding: 12px 20px;
  background: rgba(58, 167, 226, 0.05);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-2);
  font-style: italic;
}

.article-body hr {
  border: none;
  border-top: 1px solid var(--line);
  margin: 2.4em 0;
}

.article-body img {
  max-width: 100%;
  border-radius: var(--radius-lg);
  margin: 1.4em 0;
  display: block;
}

/* =====================
   17. VIDEO & SHARE
===================== */

.video-section {
  margin: 32px 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: var(--radius-lg);
  border: 1px solid var(--line);
}

.video-embed iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.share-section {
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.share-label {
  font-size: 13px;
  color: var(--text-3);
  font-weight: 500;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text-2);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: border-color 160ms ease, color 160ms ease, background 160ms ease;
}

.share-btn:hover {
  border-color: var(--line-2);
  color: var(--text);
}

.share-btn--copied {
  border-color: var(--accent-green);
  color: var(--accent-green);
}
