/* ══════════════════════════════════════════
   SecureNet — Shared Article Styles
   ══════════════════════════════════════════ */

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

:root {
  --bg0:   #05080f;
  --bg1:   #090e1a;
  --bg2:   #0f1830;
  --cyan:  #3cf0ff;
  --green: #2be7a6;
  --purple:#a855f7;
  --amber: #f59e0b;
  --red:   #f87171;
  --text:  #c8d6e8;
  --dim:   #6b7fa0;
  --border:rgba(60,240,255,.12);
  --card:  rgba(15,24,48,.7);
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg0);
  color: var(--text);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  line-height: 1.7;
  overflow-x: hidden;
}

/* animated grid bg */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image:
    linear-gradient(rgba(60,240,255,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(60,240,255,.035) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: gridMove 22s linear infinite;
  pointer-events: none; z-index: 0;
}
@keyframes gridMove { to { background-position: 60px 60px; } }

/* ── NAV ── */
.anav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 clamp(1rem, 5vw, 3rem); height: 60px;
  background: rgba(5,8,15,.88);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.anav-logo {
  font-size: 1.15rem; font-weight: 700; text-decoration: none;
  color: #fff; letter-spacing: .04em;
}
.anav-logo span { color: var(--cyan); }
.anav-back {
  display: flex; align-items: center; gap: .4rem;
  font-size: .85rem; color: var(--dim); text-decoration: none;
  transition: color .2s;
}
.anav-back:hover { color: var(--cyan); }
.anav-right { display: flex; align-items: center; gap: 1.5rem; }
.atag {
  padding: .18rem .65rem; border-radius: 4px; font-size: .68rem;
  font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
}
.atag-cyan   { background: rgba(60,240,255,.1);  border:1px solid var(--border); color: var(--cyan); }
.atag-green  { background: rgba(43,231,166,.1);  border:1px solid rgba(43,231,166,.2); color: var(--green); }
.atag-purple { background: rgba(168,85,247,.1);  border:1px solid rgba(168,85,247,.2); color: var(--purple); }
.atag-amber  { background: rgba(245,158,11,.1);  border:1px solid rgba(245,158,11,.2); color: var(--amber); }
.atag-red    { background: rgba(248,113,113,.1); border:1px solid rgba(248,113,113,.2); color: var(--red); }

/* ── HERO ── */
.ahero {
  position: relative; z-index: 1;
  padding: 8rem clamp(1rem,5vw,3rem) 4rem;
  max-width: 860px; margin: 0 auto; text-align: center;
}
.ahero-meta {
  display: flex; align-items: center; justify-content: center;
  gap: 1rem; flex-wrap: wrap; margin-bottom: 1.5rem;
}
.ahero-read { font-size: .8rem; color: var(--dim); }
.ahero h1 {
  font-size: clamp(2rem, 5.5vw, 3.6rem);
  font-weight: 800; color: #fff;
  letter-spacing: -.025em; line-height: 1.1; margin-bottom: 1rem;
}
.ahero h1 .c { color: var(--cyan); }
.ahero h1 .g { color: var(--green); }
.ahero-desc {
  font-size: 1.1rem; color: var(--dim);
  max-width: 600px; margin: 0 auto 2rem;
}
.ahero-divider {
  width: 60px; height: 2px; margin: 0 auto;
  background: linear-gradient(90deg, var(--cyan), var(--green));
  border-radius: 2px;
}

/* ── LAYOUT ── */
.alayout {
  position: relative; z-index: 1;
  max-width: 860px; margin: 0 auto;
  padding: 2rem clamp(1rem,5vw,3rem) 6rem;
}

/* TOC */
.atoc {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.5rem 1.8rem; margin-bottom: 3rem;
}
.atoc-title {
  font-size: .7rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--dim); margin-bottom: 1rem;
}
.atoc ol { padding-left: 1.2rem; }
.atoc li { margin: .35rem 0; }
.atoc a {
  color: var(--cyan); text-decoration: none; font-size: .88rem;
  transition: color .2s;
}
.atoc a:hover { color: #fff; }

/* Sections */
.asec { margin-bottom: 4rem; }
.asec h2 {
  font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 800;
  color: #fff; letter-spacing: -.02em;
  margin-bottom: 1.2rem; padding-top: 1rem;
  border-top: 1px solid var(--border);
  display: flex; align-items: center; gap: .6rem;
}
.asec h2 .num {
  font-size: .75rem; font-weight: 700; color: var(--cyan);
  background: rgba(60,240,255,.1); border: 1px solid var(--border);
  padding: .15rem .55rem; border-radius: 4px; letter-spacing: .06em;
}
.asec h3 {
  font-size: 1.1rem; font-weight: 700; color: #fff;
  margin: 1.6rem 0 .6rem;
}
.asec p { color: var(--text); margin-bottom: 1rem; }
.asec p:last-child { margin-bottom: 0; }

/* Callouts */
.callout {
  border-radius: 10px; padding: 1.1rem 1.4rem; margin: 1.5rem 0;
  border-left: 3px solid;
  display: flex; gap: .9rem; align-items: flex-start;
}
.callout-ico { font-size: 1.1rem; flex-shrink: 0; margin-top: .1rem; }
.callout-body { flex: 1; }
.callout-body strong { display: block; margin-bottom: .3rem; font-size: .9rem; }
.callout-body p { font-size: .88rem; margin: 0; }
.callout.info    { background: rgba(60,240,255,.06);  border-color: var(--cyan);   color: var(--text); }
.callout.tip     { background: rgba(43,231,166,.06);  border-color: var(--green);  color: var(--text); }
.callout.warning { background: rgba(245,158,11,.06);  border-color: var(--amber);  color: var(--text); }
.callout.danger  { background: rgba(248,113,113,.06); border-color: var(--red);    color: var(--text); }
.callout.info    .callout-body strong { color: var(--cyan); }
.callout.tip     .callout-body strong { color: var(--green); }
.callout.warning .callout-body strong { color: var(--amber); }
.callout.danger  .callout-body strong { color: var(--red); }

/* Checklists */
.checklist { list-style: none; margin: 1rem 0; }
.checklist li {
  display: flex; align-items: flex-start; gap: .75rem;
  padding: .6rem 0; border-bottom: 1px solid rgba(255,255,255,.04);
  font-size: .9rem;
}
.checklist li:last-child { border: none; }
.checklist li::before {
  content: '✓'; flex-shrink: 0;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(43,231,166,.1); border: 1px solid rgba(43,231,166,.3);
  color: var(--green); font-size: .7rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  margin-top: .1rem;
}
.checklist li.warn::before  { content: '!'; background: rgba(245,158,11,.1); border-color: rgba(245,158,11,.3); color: var(--amber); }
.checklist li.cross::before { content: '✗'; background: rgba(248,113,113,.1); border-color: rgba(248,113,113,.3); color: var(--red); }

/* Step list */
.steps { counter-reset: step; list-style: none; margin: 1rem 0; }
.steps li {
  counter-increment: step;
  display: flex; gap: 1rem; align-items: flex-start;
  padding: 1rem 0; border-bottom: 1px solid rgba(255,255,255,.04);
}
.steps li:last-child { border: none; }
.steps li::before {
  content: counter(step);
  flex-shrink: 0; width: 32px; height: 32px; border-radius: 50%;
  background: rgba(60,240,255,.1); border: 1px solid var(--border);
  color: var(--cyan); font-size: .85rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  margin-top: .1rem;
}
.steps li strong { color: #fff; display: block; margin-bottom: .2rem; font-size: .95rem; }
.steps li p { font-size: .88rem; color: var(--dim); margin: 0; }

/* Info cards grid */
.icards {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem; margin: 1.5rem 0;
}
.icard {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 10px; padding: 1.3rem 1.5rem;
  transition: border-color .25s, transform .25s;
}
.icard:hover { border-color: rgba(60,240,255,.3); transform: translateY(-3px); }
.icard-icon { font-size: 1.6rem; margin-bottom: .7rem; }
.icard h4 { color: #fff; font-size: .95rem; margin-bottom: .4rem; }
.icard p  { color: var(--dim); font-size: .83rem; line-height: 1.5; margin: 0; }

/* Comparison table */
.ctable-wrap { overflow-x: auto; margin: 1.5rem 0; border-radius: 10px; border: 1px solid var(--border); }
.ctable {
  width: 100%; border-collapse: collapse;
  font-size: .88rem;
}
.ctable th {
  background: rgba(60,240,255,.07); color: var(--cyan);
  padding: .8rem 1.1rem; text-align: left;
  font-size: .72rem; letter-spacing: .1em; text-transform: uppercase;
  border-bottom: 1px solid var(--border);
}
.ctable td {
  padding: .75rem 1.1rem; border-bottom: 1px solid rgba(255,255,255,.04);
  color: var(--text); vertical-align: top;
}
.ctable tr:last-child td { border: none; }
.ctable tr:hover td { background: rgba(255,255,255,.02); }
.ctable .ok   { color: var(--green); }
.ctable .warn { color: var(--amber); }
.ctable .bad  { color: var(--red); }
.ctable .name { color: #fff; font-weight: 600; }

/* Highlight box */
.hbox {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 12px; padding: 1.5rem 2rem; margin: 1.5rem 0;
}
.hbox h4 { color: var(--cyan); font-size: .88rem; margin-bottom: .8rem; letter-spacing: .06em; text-transform: uppercase; }

/* Timeline */
.timeline { margin: 1.5rem 0; }
.tl-item {
  display: flex; gap: 1.2rem; padding-bottom: 1.5rem;
  position: relative;
}
.tl-item::before {
  content: ''; position: absolute;
  left: 19px; top: 40px; bottom: 0; width: 1px;
  background: var(--border);
}
.tl-item:last-child::before { display: none; }
.tl-dot {
  flex-shrink: 0; width: 40px; height: 40px; border-radius: 50%;
  background: var(--card); border: 2px solid var(--cyan);
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem; color: var(--cyan); font-weight: 700;
  z-index: 1;
}
.tl-dot.green { border-color: var(--green); color: var(--green); }
.tl-dot.amber { border-color: var(--amber); color: var(--amber); }
.tl-dot.red   { border-color: var(--red);   color: var(--red); }
.tl-body { flex: 1; }
.tl-body h4 { color: #fff; font-size: .95rem; margin-bottom: .3rem; }
.tl-body p  { color: var(--dim); font-size: .85rem; margin: 0; }

/* Code inline */
code {
  font-family: 'Courier New', monospace; font-size: .85em;
  background: rgba(60,240,255,.07); border: 1px solid rgba(60,240,255,.15);
  padding: .1em .4em; border-radius: 4px; color: var(--cyan);
}

/* Key takeaway */
.takeaway {
  background: linear-gradient(135deg, rgba(43,231,166,.08), rgba(60,240,255,.05));
  border: 1px solid rgba(43,231,166,.2); border-radius: 12px;
  padding: 1.5rem 2rem; margin: 2rem 0;
}
.takeaway h3 { color: var(--green); font-size: .85rem; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 1rem; }
.takeaway ul { list-style: none; }
.takeaway ul li {
  padding: .4rem 0; color: var(--text); font-size: .92rem;
  display: flex; gap: .6rem;
}
.takeaway ul li::before { content: '→'; color: var(--green); flex-shrink: 0; }

/* Score badge */
.score-badge {
  display: inline-flex; flex-direction: column; align-items: center;
  padding: .8rem 1.4rem; border-radius: 10px; margin: .5rem;
  background: var(--card); border: 1px solid var(--border);
  min-width: 110px;
}
.score-val { font-size: 1.5rem; font-weight: 800; }
.score-lbl { font-size: .72rem; color: var(--dim); letter-spacing: .06em; margin-top: .2rem; }

/* Related articles */
.related {
  border-top: 1px solid var(--border); margin-top: 4rem; padding-top: 2rem;
}
.related h3 { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--dim); margin-bottom: 1.2rem; }
.related-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; }
.related-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 10px; padding: 1.2rem 1.4rem;
  text-decoration: none; transition: border-color .25s, transform .25s;
  display: block;
}
.related-card:hover { border-color: rgba(60,240,255,.3); transform: translateY(-3px); }
.related-card .rtag { font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin-bottom: .4rem; }
.related-card h4 { color: #fff; font-size: .9rem; line-height: 1.3; }

/* Footer */
.afooter {
  position: relative; z-index: 1; text-align: center;
  padding: 2rem; border-top: 1px solid var(--border);
  color: var(--dim); font-size: .82rem;
}
.afooter a { color: var(--cyan); text-decoration: none; }

/* Reveal */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s, transform .6s; }
.reveal.visible { opacity: 1; transform: none; }

/* Responsive */
@media (max-width: 640px) {
  .ahero h1 { font-size: 1.9rem; }
  .icards { grid-template-columns: 1fr; }
  .ctable th, .ctable td { padding: .6rem .8rem; }
}
