:root {
  --bg: #0b1020;
  --bg2: #16213f;
  --card: rgba(255, 255, 255, .06);
  --border: rgba(255, 255, 255, .14);
  --text: #eef2ff;
  --muted: #9aa6c4;
  --accent1: #6ee7ff;
  --accent2: #a78bfa;
  --accent3: #f472b6;
  --ok: #34d399;
}

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

body {
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(1200px 600px at 15% -10%, var(--bg2) 0%, transparent 60%),
    radial-gradient(900px 500px at 110% 10%, #1d1b3a 0%, transparent 55%),
    var(--bg);
  background-attachment: fixed;
}

a { color: inherit; }

.container { width: min(94vw, 1040px); margin: 0 auto; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(11, 16, 32, .72);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.nav {
  display: flex;
  align-items: center;
  gap: 26px;
  padding: 16px 0;
  flex-wrap: wrap;
}

.brand {
  font-weight: 800;
  letter-spacing: .16em;
  font-size: 18px;
  text-decoration: none;
  background: linear-gradient(90deg, var(--accent1), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav .spacer { flex: 1; }

.nav a.link {
  color: var(--muted);
  text-decoration: none;
  font-size: 15px;
  transition: color .2s ease;
}
.nav a.link:hover,
.nav a.link[aria-current="page"] { color: var(--text); }

/* ---------- Hero ---------- */
.hero { padding: 64px 0 40px; max-width: 780px; }

.hero h1 {
  font-size: clamp(30px, 5vw, 46px);
  letter-spacing: -.02em;
  background: linear-gradient(90deg, var(--accent1), var(--accent2), var(--accent3));
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shine 6s linear infinite;
}

@keyframes shine { to { background-position: 200% center; } }

.lead {
  margin-top: 16px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.65;
}

/* ---------- Sections & cards ---------- */
.section { padding: 8px 0 56px; }
.section h2 { font-size: 24px; margin-bottom: 22px; letter-spacing: -.01em; }

.grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
}

.card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 26px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  text-decoration: none;
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
  animation: rise .8s cubic-bezier(.2, .7, .2, 1) both;
}

.card:hover {
  transform: translateY(-6px);
  border-color: rgba(167, 139, 250, .55);
  background: rgba(255, 255, 255, .09);
}

.tag {
  align-self: flex-start;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #0b1020;
  background: linear-gradient(135deg, var(--accent1), var(--accent2));
}

.card h3 { font-size: 20px; line-height: 1.35; }

.card p { color: var(--muted); font-size: 15px; line-height: 1.6; flex: 1; }

.meta { color: var(--muted); font-size: 13px; opacity: .85; }
.more { color: var(--accent1); font-weight: 600; font-size: 14px; }

/* ---------- Panels (about / contacts) ---------- */
.panel {
  padding: 32px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  margin-bottom: 22px;
  animation: rise .8s cubic-bezier(.2, .7, .2, 1) both;
}

.panel h2 { font-size: 22px; margin-bottom: 14px; }
.panel p { color: #cdd6ef; line-height: 1.7; margin-bottom: 14px; }
.panel p:last-child { margin-bottom: 0; }
.panel ul { color: #cdd6ef; line-height: 1.7; margin: 0 0 14px 22px; }
.panel li { margin-bottom: 8px; }

.contact-list { list-style: none; display: grid; gap: 12px; }

.contact-list li {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, .04);
}

.contact-list .icon { font-size: 20px; }
.contact-list a { color: var(--accent1); text-decoration: none; font-weight: 600; }
.contact-list a:hover { text-decoration: underline; }
.contact-list .note { display: block; color: var(--muted); font-size: 14px; font-weight: 400; margin-top: 3px; }

/* ---------- Article prose ---------- */
.prose { max-width: 740px; padding: 52px 0 64px; animation: rise .8s cubic-bezier(.2, .7, .2, 1) both; }

.back {
  display: inline-block;
  margin-bottom: 26px;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
}
.back:hover { color: var(--text); }

.prose h1 {
  font-size: clamp(28px, 4.5vw, 40px);
  letter-spacing: -.02em;
  margin-bottom: 14px;
  line-height: 1.15;
}

.prose h2 { font-size: 23px; margin: 36px 0 14px; }
.prose p { color: #cdd6ef; font-size: 17px; line-height: 1.75; margin-bottom: 16px; }

.prose ul, .prose ol { color: #cdd6ef; font-size: 17px; line-height: 1.75; margin: 0 0 16px 22px; }
.prose li { margin-bottom: 8px; }

.prose blockquote {
  margin: 24px 0;
  padding: 18px 22px;
  border-left: 3px solid var(--accent2);
  background: var(--card);
  border-radius: 0 14px 14px 0;
  color: var(--muted);
  font-style: italic;
  line-height: 1.65;
}

.prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: .92em;
  background: rgba(255, 255, 255, .08);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 7px;
}

.prose a { color: var(--accent1); }

.prose .signoff { color: var(--muted); font-size: 15px; margin-top: 34px; }

/* ---------- Decorative blobs ---------- */
.blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .3;
  z-index: 0;
  pointer-events: none;
  animation: drift 18s ease-in-out infinite alternate;
}
.blob.b1 { width: 420px; height: 420px; background: var(--accent1); top: -120px; left: -100px; }
.blob.b2 { width: 380px; height: 380px; background: var(--accent2); bottom: -140px; right: -80px; animation-delay: -6s; }
.blob.b3 { width: 260px; height: 260px; background: var(--accent3); top: 55%; left: 12%; animation-delay: -12s; opacity: .18; }

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(60px, -40px, 0) scale(1.15); }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: auto;
  padding: 26px 0;
  border-top: 1px solid rgba(255, 255, 255, .08);
  color: var(--muted);
  font-size: 13px;
  text-align: center;
  letter-spacing: .03em;
}

@media (max-width: 640px) {
  .nav { gap: 16px; }
  .hero { padding-top: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; }
}
