/* ==========================================================================
   Kapasiteci.com — Master Design System
   Dark Premium — Brass / Petrol / Ink
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  --ink:          #12151b;
  --ink-deep:     #0c0f14;
  --surf-1:       #1a1f28;
  --surf-2:       #212837;
  --surf-3:       #293044;
  --line:         #2c3444;
  --line-light:   #3d4a60;
  --paper:        #ece4d3;
  --paper-mid:    #c9bb98;
  --brass:        #c8973f;
  --brass-lt:     #e2b768;
  --brass-glow:   rgba(200,151,63,.18);
  --petrol:       #4c7c6d;
  --petrol-lt:    #6a9c8b;
  --ember:        #b6532f;
  --hi:           #f0ede7;
  --mid:          #c0c7d4;
  --lo:           #8390a2;
  --radius:       6px;
  --t:            all .22s cubic-bezier(.16,1,.3,1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--ink);
  color: var(--mid);
  font-family: 'IBM Plex Sans', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { padding-left: 0; list-style: none; }
::selection { background: var(--brass); color: var(--ink); }
:focus-visible { outline: 2px solid var(--brass-lt); outline-offset: 3px; }

.wrap {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 32px;
}
@media (max-width: 640px) { .wrap { padding: 0 18px; } }

/* ---------- Typography ---------- */
h1,h2,h3,h4 {
  font-family: 'Fraunces', Georgia, serif;
  color: var(--hi);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -.015em;
}
h1 { font-size: clamp(30px, 4.5vw, 52px); }
h2 { font-size: clamp(22px, 2.8vw, 34px); }
h3 { font-size: clamp(18px, 2vw, 24px); }
h4 { font-size: 17px; color: var(--hi); }

p { line-height: 1.75; }

.eyebrow {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--brass-lt);
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 24px;
  height: 1.5px;
  background: var(--brass);
  flex-shrink: 0;
}

/* ---------- Header ---------- */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(18,21,27,.95);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Fraunces', serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--hi);
  white-space: nowrap;
}
.logo span { color: var(--brass-lt); }
.logo-mark { width: 28px; height: 28px; flex-shrink: 0; }

/* Nav Links */
.nav-links {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  white-space: nowrap;
}
.nav-links a { color: var(--mid); transition: var(--t); }
.nav-links a:hover,
.nav-links a.active { color: var(--brass-lt); }

.nav-cta {
  background: var(--brass) !important;
  color: var(--ink) !important;
  font-weight: 700;
  font-size: 13px;
  padding: 9px 18px;
  border-radius: var(--radius);
  transition: var(--t);
  white-space: nowrap;
}
.nav-cta:hover {
  background: var(--brass-lt) !important;
  transform: translateY(-1px);
}

/* Hamburger */
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}
.burger span { display: block; width: 22px; height: 2px; background: var(--hi); transition: var(--t); }
.burger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.active span:nth-child(2) { opacity: 0; }
.burger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1080px) {
  .nav-links {
    position: fixed;
    top: 74px; left: 0; right: 0; bottom: 0;
    background: var(--ink-deep);
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 40px 32px;
    gap: 28px;
    font-size: 18px;
    transform: translateX(100%);
    transition: transform .3s ease;
    overflow-y: auto;
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links .nav-cta { width: 100%; text-align: center; margin-top: 8px; }
  .burger { display: flex; }
}

/* ---------- Page Hero ---------- */
.page-hero {
  padding: 60px 0 52px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(175deg, rgba(200,151,63,.07) 0%, transparent 60%);
}
.page-hero h1 { margin-bottom: 16px; max-width: 900px; }
.page-hero .lead {
  font-size: 17px;
  color: var(--mid);
  max-width: 680px;
  line-height: 1.7;
}
.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 18px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  color: var(--lo);
}

/* ---------- Main Content Area ---------- */
main { padding: 60px 0 80px; }
.article-body { max-width: 860px; margin: 0 auto; }
.article-body > * + * { margin-top: 20px; }

.article-body h2 {
  font-size: clamp(20px, 2.5vw, 28px);
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
  margin-top: 48px;
}
.article-body h3 {
  font-size: 19px;
  color: var(--brass-lt);
  margin-top: 30px;
}
.article-body p {
  font-size: 16px;
  color: var(--mid);
}
.article-body strong { color: var(--hi); }

/* ---------- Info Block (Bordered Card) ---------- */
.info-block {
  background: var(--surf-1);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 32px;
}
.info-block.gold  { border-left: 3px solid var(--brass); }
.info-block.petrol { border-left: 3px solid var(--petrol); }
.info-block.ember { border-left: 3px solid var(--ember); }

.info-block h3 {
  font-size: 18px;
  color: var(--hi);
  margin: 0 0 18px 0;
}

/* ---------- Step List ---------- */
.step-list { display: flex; flex-direction: column; gap: 16px; }
.step-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.step-num {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--brass);
  color: var(--ink);
  font-weight: 700;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
  font-family: 'IBM Plex Mono', monospace;
}
.step-item-body { flex: 1; }
.step-item-body strong { display: block; color: var(--hi); font-size: 15px; margin-bottom: 3px; }
.step-item-body span { font-size: 14.5px; color: var(--mid); line-height: 1.6; }

/* ---------- Check List ---------- */
.check-list { display: flex; flex-direction: column; gap: 12px; }
.check-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 15px;
  color: var(--mid);
}
.check-icon {
  width: 20px; height: 20px;
  background: rgba(200,151,63,.15);
  border: 1px solid var(--brass);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--brass-lt);
  font-size: 11px;
  font-weight: 700;
}
.check-item strong { color: var(--hi); }

/* ---------- Data Table ---------- */
.data-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  font-size: 15px;
}
.data-table thead tr { background: var(--surf-2); }
.data-table th {
  padding: 14px 18px;
  text-align: left;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--brass-lt);
  border-bottom: 1px solid var(--line);
  font-weight: 500;
}
.data-table td {
  padding: 13px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--mid);
  vertical-align: top;
}
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: var(--surf-1); }
.data-table td strong { color: var(--hi); }

/* ---------- Summary Box ---------- */
.summary-box {
  background: var(--surf-2);
  border: 1px solid var(--brass);
  border-radius: var(--radius);
  padding: 28px 30px;
}
.summary-box h3 {
  color: var(--brass-lt);
  font-size: 17px;
  margin: 0 0 18px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.summary-box .summary-items { display: flex; flex-direction: column; gap: 12px; }
.summary-row {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 15px;
}
.summary-row .s-num {
  background: var(--brass);
  color: var(--ink);
  font-weight: 700;
  font-size: 11px;
  width: 22px; height: 22px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
  font-family: 'IBM Plex Mono', monospace;
}
.summary-row p { color: var(--mid); line-height: 1.55; margin: 0; font-size: 15px; }
.summary-row strong { color: var(--hi); }

/* ---------- Risk Grid ---------- */
.risk-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.risk-card {
  background: var(--surf-1);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
}
.risk-card .risk-icon { font-size: 24px; margin-bottom: 10px; }
.risk-card h4 { font-size: 15px; color: var(--hi); margin-bottom: 8px; }
.risk-card p { font-size: 14px; color: var(--lo); line-height: 1.55; margin: 0; }

/* ---------- CTA Box ---------- */
.cta-box {
  background: var(--surf-2);
  border: 1px solid var(--brass);
  border-radius: var(--radius);
  padding: 40px;
  text-align: center;
}
.cta-box h3 { color: var(--hi); font-size: 22px; margin-bottom: 10px; }
.cta-box p { color: var(--mid); font-size: 15.5px; margin-bottom: 24px; max-width: 560px; margin-left: auto; margin-right: auto; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius);
  font-size: 14.5px;
  font-weight: 600;
  transition: var(--t);
  border: 1.5px solid transparent;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}
.btn-primary { background: var(--brass); color: var(--ink); border-color: var(--brass); }
.btn-primary:hover { background: var(--brass-lt); border-color: var(--brass-lt); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(200,151,63,.25); }
.btn-ghost { background: transparent; color: var(--hi); border-color: var(--line-light); }
.btn-ghost:hover { border-color: var(--brass); color: var(--brass-lt); }
.btn-wa { background: rgba(37,211,102,.1); color: #8fe0ac; border-color: rgba(37,211,102,.35); }
.btn-wa:hover { background: rgba(37,211,102,.2); border-color: #25d366; color: #a8ecc0; }

/* ---------- Footer ---------- */
footer {
  background: var(--ink-deep);
  border-top: 1px solid var(--line);
  padding: 56px 0 32px;
  font-size: 14px;
  color: var(--lo);
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 44px;
}
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px)  { .footer-grid { grid-template-columns: 1fr; } }

.footer-brand strong {
  display: block;
  font-family: 'Fraunces', serif;
  font-size: 19px;
  color: var(--hi);
  margin-bottom: 10px;
}
.footer-brand strong span { color: var(--brass-lt); }
.footer-brand p { font-size: 13.5px; line-height: 1.65; max-width: 300px; }

.footer-col h4 {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--brass-lt);
  margin-bottom: 16px;
  font-weight: 500;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul a { color: var(--lo); transition: var(--t); }
.footer-col ul a:hover { color: var(--hi); }

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
}

/* ---------- Utility ---------- */
.divider { height: 1px; background: var(--line); margin: 40px 0; }
.text-brass { color: var(--brass-lt); }
.text-lo { color: var(--lo); }
.mt-8  { margin-top: 8px;  }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mt-40 { margin-top: 40px; }
.mt-48 { margin-top: 48px; }
.mt-12 { margin-top: 12px; }

/* ---------- Article Tag Badge ---------- */
.article-tag {
  display: inline-block;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 2px;
  border: 1px solid var(--brass);
  color: var(--brass-lt);
  margin-bottom: 8px;
}

/* ---------- Article Navigation (Prev / Next) ---------- */
.article-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}
@media (max-width: 640px) {
  .article-nav { grid-template-columns: 1fr; }
}
.article-nav-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 22px 24px;
  background: var(--surf-1);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: var(--t);
  text-decoration: none;
}
.article-nav-item:hover {
  border-color: var(--brass);
  background: var(--surf-2);
}
.article-nav-item.next { text-align: right; }
.article-nav-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--lo);
  display: flex;
  align-items: center;
  gap: 6px;
}
.article-nav-item.next .article-nav-label { justify-content: flex-end; }
.article-nav-title {
  font-family: 'Fraunces', serif;
  font-size: 16px;
  color: var(--hi);
  line-height: 1.35;
}
.article-nav-item:hover .article-nav-title { color: var(--brass-lt); }

/* ---------- Related Articles ---------- */
.related-articles {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}
.related-articles h3 {
  font-size: 20px;
  margin-bottom: 20px;
  color: var(--hi);
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.related-card {
  background: var(--surf-1);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: var(--t);
}
.related-card:hover { border-color: var(--brass); background: var(--surf-2); }
.related-card .rc-tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--lo);
}
.related-card .rc-title {
  font-family: 'Fraunces', serif;
  font-size: 17px;
  color: var(--hi);
  line-height: 1.35;
}
.related-card:hover .rc-title { color: var(--brass-lt); }
.related-card .rc-desc {
  font-size: 13.5px;
  color: var(--lo);
  line-height: 1.55;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

/* ---------- Feature List ---------- */
.feature-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}
.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  color: var(--mid);
  line-height: 1.5;
}
.feature-list li svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--brass-lt);
  margin-top: 2px;
}
