/* ═══════════════════════════════════════
   CR Informatics · blog.css
   ═══════════════════════════════════════ */

:root {
  --black:     #0f1e34;
  --dark:      #162338;
  --card:      #1a2d44;
  --border:    #253d58;
  --red:       #c41e1e;
  --red-light: #e03030;
  --white:     #eef2f7;
  --muted:     #9ab0c8;
  --radius:    3px;
  --font-display: 'Barlow Condensed', sans-serif;
  --font-body:    'Crimson Pro', serif;
  --font-mono:    'JetBrains Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--font-body);
  font-size: 1.15rem;
  line-height: 1.75;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 999;
  opacity: 0.35;
}

/* ─── NAV ─── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 1rem 5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(15,30,52,0.97);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

.nav-logo {
  background: #fff;
  padding: 0.28rem 0.5rem;
  border-radius: var(--radius);
  display: inline-flex;
  align-items: center;
}
.nav-logo img { height: 44px; width: auto; display: block; }

.nav-links { display: flex; align-items: center; gap: 2.5rem; list-style: none; }
.nav-links a {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--white); }
.nav-cta {
  color: var(--black) !important;
  background: var(--red);
  padding: 0.5rem 1.2rem;
  border-radius: var(--radius);
}
.nav-cta:hover { background: var(--red-light) !important; }

/* ─── ARTICLE LAYOUT ─── */
.blog-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 8rem 2rem 5rem;
}

.blog-tag {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--red-light);
  margin-bottom: 1rem;
  display: block;
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 700;
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 1.25rem;
  letter-spacing: -0.01em;
}

.blog-meta {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--muted);
  text-transform: uppercase;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2.5rem;
}

h2 {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 600;
  color: var(--white);
  margin: 2.5rem 0 0.75rem;
  letter-spacing: 0.01em;
}

h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--white);
  margin: 2rem 0 0.5rem;
}

p { margin-bottom: 1.1rem; color: var(--white); opacity: 0.9; }

ul, ol { padding-left: 1.5rem; margin-bottom: 1.25rem; }
li { margin-bottom: 0.4rem; opacity: 0.9; }

strong { color: var(--white); opacity: 1; font-weight: 700; }

a { color: var(--red-light); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ─── CALLOUT ─── */
.callout {
  background: var(--card);
  border-left: 3px solid var(--red);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  font-family: var(--font-body);
}
.callout strong { color: var(--red-light); }

/* ─── TABLE ─── */
.table-wrap { overflow-x: auto; margin: 2rem 0; }
table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-mono);
  font-size: 0.78rem;
}
th {
  background: var(--card);
  color: var(--muted);
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.6rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
td {
  padding: 0.7rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--white);
  opacity: 0.85;
}
tr:last-child td { border-bottom: none; }

.tag-ok   { color: #4ade80; font-weight: 700; }
.tag-warn { color: #fbbf24; font-weight: 700; }
.tag-ko   { color: var(--red-light); font-weight: 700; }

/* ─── CTA BLOCK ─── */
.cta-block {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  margin: 2.5rem 0;
}
.cta-block .cta-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.75rem;
}
.cta-block .cta-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 1.25rem;
}
.btn-cta {
  display: inline-block;
  background: var(--red);
  color: var(--white) !important;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.85rem 2rem;
  border-radius: var(--radius);
  text-decoration: none !important;
  transition: background 0.2s;
}
.btn-cta:hover { background: var(--red-light); }

/* ─── ARTICLE FOOTER ─── */
.article-footer {
  margin-top: 4rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ─── BLOG INDEX ─── */
.blog-grid { display: grid; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; margin-top: 2rem; }
.article-card {
  background: var(--dark);
  padding: 1.75rem 2rem;
  text-decoration: none;
  display: block;
  transition: background 0.15s;
}
.article-card:hover { background: var(--card); }
.article-card .tag {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--red-light);
  margin-bottom: 0.5rem;
}
.article-card .title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 0.4rem;
  line-height: 1.2;
}
.article-card .desc { font-size: 0.95rem; color: var(--muted); margin-bottom: 0.5rem; }
.article-card .meta { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--border); }

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
  nav { padding: 1rem 1.5rem; }
  .nav-links { display: none; }
  .blog-wrap { padding: 6rem 1.25rem 4rem; }
}
