/* ============ BLOG — stesso linguaggio visivo della home ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #000000;
  --bg-card: rgba(255,255,255,.035);
  --bg-card2: rgba(255,255,255,.07);
  --border: rgba(255,255,255,.08);
  --border2: rgba(255,255,255,.16);
  --blue: #0A84FF;
  --teal: #64D2FF;
  --text: #ffffff;
  --text-2: rgba(255,255,255,.66);
  --text-3: rgba(255,255,255,.40);
  --max: 1060px;
  --r: 16px;
}

html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, sans-serif;
  background: var(--bg); color: var(--text);
  line-height: 1.6; font-size: 17px;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

/* sfondo costellazione */
.bg-canvas { position: fixed; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; }
/* vignette */
body::after {
  content: ''; position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(ellipse 100% 80% at center, transparent 0%, rgba(0,0,0,.30) 70%, rgba(0,0,0,.6) 100%);
}

/* ── NAV (identico alla home) ── */
nav {
  position: fixed; top: 14px; left: 50%; transform: translateX(-50%);
  width: calc(100% - 40px); max-width: 680px; z-index: 999;
  background: rgba(3,3,8,.72);
  backdrop-filter: blur(32px) saturate(200%); -webkit-backdrop-filter: blur(32px) saturate(200%);
  border: 1px solid rgba(255,255,255,.05); border-top-color: rgba(255,255,255,.16);
  border-radius: 22px; box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 8px 32px rgba(0,0,0,.4);
}
.nav-i { display: flex; align-items: center; justify-content: space-between; height: 52px; padding: 0 16px; }
.nav-brand { display: flex; align-items: center; font-family: 'Poppins',sans-serif; font-weight: 700; font-size: 14.5px; color: var(--text); letter-spacing: -.2px; }
.nav-status { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #32D74B; margin-right: 9px; flex-shrink: 0; box-shadow: 0 0 7px rgba(50,215,75,.7); animation: pulse-status 2.5s ease-in-out infinite; }
@keyframes pulse-status { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .5; transform: scale(.8); } }
.nav-links { display: flex; align-items: center; gap: 24px; list-style: none; }
.nav-links a { font-size: 14.5px; font-weight: 500; color: var(--text-2); transition: color .2s; }
.nav-links a:hover, .nav-links a.is-active { color: var(--text); }
.nav-cta { background: var(--blue); color: #fff; font-size: 13.5px; font-weight: 600; padding: 8px 18px; border-radius: 100px; transition: background .2s, transform .2s, box-shadow .2s; }
.nav-cta:hover { background: #1a8fff; transform: translateY(-1px); box-shadow: 0 4px 16px rgba(10,132,255,.45); }
.nav-hamburger { display: none; flex-direction: column; justify-content: center; gap: 5px; width: 36px; height: 36px; cursor: pointer; background: none; border: none; padding: 4px; }
.nav-hamburger span { display: block; height: 1.5px; width: 22px; background: var(--text-2); border-radius: 2px; transition: transform .3s, opacity .3s; }
.nav-hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }
.nav-mobile { display: none; flex-direction: column; border-top: 1px solid var(--border); padding: 8px 0 14px; }
.nav-mobile.open { display: flex; }
.nav-mobile a { font-size: 15px; font-weight: 500; color: var(--text-2); padding: 12px 18px; transition: color .2s; }
.nav-mobile a:hover { color: var(--text); }
.nav-mobile .nav-cta { margin: 8px 18px 0; text-align: center; padding: 11px 18px; border-radius: 9px; }
@media (max-width: 860px) {
  .nav-links, .nav-i > .nav-cta { display: none; }
  .nav-hamburger { display: flex; }
}

/* ── MAIN ── */
.b-main { position: relative; z-index: 2; max-width: var(--max); margin: 0 auto; padding: 130px 28px 40px; }

/* ── BLOG INDEX ── */
.b-blog-hd { text-align: center; max-width: 640px; margin: 0 auto 64px; }
.b-tag {
  display: inline-flex; align-items: center; gap: 7px; font-size: 11px; font-weight: 600;
  letter-spacing: 1.4px; text-transform: uppercase; color: rgba(255,255,255,.55);
  background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.08);
  border-top-color: rgba(255,255,255,.14); padding: 5px 12px; border-radius: 100px; margin-bottom: 18px;
}
.b-tag-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--teal); box-shadow: 0 0 6px rgba(100,210,255,.7); }
.b-blog-title { font-family: 'Poppins',sans-serif; font-size: clamp(38px, 6vw, 60px); font-weight: 900; letter-spacing: -2px; line-height: 1.04; }
.b-blog-title em {
  font-family: 'DM Serif Display', serif; font-style: italic; font-weight: 400;
  background: linear-gradient(130deg, var(--teal), var(--blue)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.b-blog-tagline { font-size: 18px; color: var(--text-2); line-height: 1.5; margin-top: 16px; }

.b-posts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 720px) { .b-posts { grid-template-columns: 1fr; } }
.b-post-card {
  display: flex; flex-direction: column; overflow: hidden; border-radius: var(--r);
  background: var(--bg-card); border: 1px solid rgba(255,255,255,.05); border-top-color: rgba(255,255,255,.16);
  backdrop-filter: blur(30px) saturate(160%); -webkit-backdrop-filter: blur(30px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.10), 0 18px 50px rgba(0,0,0,.35);
  transition: transform .35s cubic-bezier(.16,1,.3,1), background .3s, box-shadow .3s, border-color .3s;
}
.b-post-card:hover {
  transform: translateY(-5px); background: var(--bg-card2); border-top-color: rgba(100,210,255,.3);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.16), 0 28px 70px rgba(10,132,255,.16);
}
.b-post-cover { aspect-ratio: 16/9; overflow: hidden; background: rgba(255,255,255,.03); }
.b-post-cover img { width: 100%; height: 100%; object-fit: cover; }
.b-post-body { padding: 26px 26px 28px; display: flex; flex-direction: column; flex: 1; }
.b-post-meta { font-size: 12px; color: var(--text-3); letter-spacing: .3px; margin-bottom: 12px; text-transform: uppercase; }
.b-post-title { font-family: 'Poppins',sans-serif; font-size: 21px; font-weight: 700; letter-spacing: -.6px; line-height: 1.2; }
.b-post-excerpt { font-size: 15px; color: var(--text-2); line-height: 1.55; margin-top: 10px; }
.b-post-more { margin-top: auto; padding-top: 18px; font-family: 'Poppins',sans-serif; font-size: 14px; font-weight: 600; color: var(--teal); }
.b-empty { text-align: center; color: var(--text-3); grid-column: 1/-1; padding: 40px 0; }

/* ── ARTICOLO ── */
.b-article {
  max-width: 720px; margin: 0 auto;
  background: #000;
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 56px 60px 48px;
  box-shadow: 0 30px 90px rgba(0,0,0,.7);
}
@media (max-width: 720px) { .b-article { padding: 36px 22px 32px; border-radius: 16px; } }
.b-article-hd { margin-bottom: 36px; }
.b-back { display: inline-block; font-size: 13px; font-weight: 500; color: var(--text-3); margin-bottom: 28px; transition: color .2s; }
.b-back:hover { color: var(--teal); }
.b-article-meta { font-size: 12px; color: var(--text-3); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 16px; }
.b-cat { color: var(--teal); }
.b-article-title { font-family: 'Poppins',sans-serif; font-size: clamp(32px, 5vw, 50px); font-weight: 900; letter-spacing: -1.6px; line-height: 1.08; }
.b-article-lead { font-size: 20px; color: var(--text-2); line-height: 1.5; margin-top: 20px; }
.b-article-cover { width: 100%; border-radius: var(--r); margin-bottom: 36px; border: 1px solid var(--border); }

/* prosa leggibile */
.b-prose { font-size: 18px; color: rgba(255,255,255,.78); line-height: 1.75; }
.b-prose > * + * { margin-top: 22px; }
.b-prose h2 { font-family: 'Poppins',sans-serif; font-size: 28px; font-weight: 800; letter-spacing: -.8px; line-height: 1.2; color: #fff; margin-top: 48px; }
.b-prose h3 { font-family: 'Poppins',sans-serif; font-size: 21px; font-weight: 700; letter-spacing: -.4px; color: #fff; margin-top: 36px; }
.b-prose a { color: var(--teal); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: rgba(100,210,255,.4); }
.b-prose a:hover { text-decoration-color: var(--teal); }
.b-prose strong { color: #fff; }
.b-prose ul, .b-prose ol { padding-left: 24px; }
.b-prose li { margin-top: 8px; }
.b-prose blockquote {
  border-left: 2px solid var(--teal); padding: 4px 0 4px 22px; color: var(--text);
  font-size: 20px; line-height: 1.5; font-style: italic;
}
.b-prose img { border-radius: 12px; border: 1px solid var(--border); }
.b-prose code {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: 15px;
  background: rgba(255,255,255,.07); padding: 2px 7px; border-radius: 6px;
}
.b-prose pre { background: rgba(255,255,255,.04); border: 1px solid var(--border); border-radius: 12px; padding: 18px 20px; overflow-x: auto; }
.b-prose pre code { background: none; padding: 0; }
.b-prose hr { border: none; height: 1px; background: var(--border); margin: 40px 0; }

.b-article-cta {
  margin-top: 56px; padding: 32px; text-align: center; border-radius: var(--r);
  background: linear-gradient(150deg, rgba(10,132,255,.10), rgba(100,210,255,.045));
  border: 1px dashed rgba(100,210,255,.35);
}
.b-article-cta p { font-size: 17px; color: var(--text); margin-bottom: 18px; }
.b-btn {
  display: inline-block; background: var(--blue); color: #fff;
  font-family: 'Poppins',sans-serif; font-size: 15px; font-weight: 600;
  padding: 14px 30px; border-radius: 100px; transition: transform .25s, box-shadow .25s, background .2s;
  box-shadow: 0 4px 20px rgba(10,132,255,.35);
}
.b-btn:hover { transform: translateY(-2px); background: #1a8fff; box-shadow: 0 10px 32px rgba(10,132,255,.5); }

/* ── FOOTER ── */
.b-footer { position: relative; z-index: 2; max-width: var(--max); margin: 0 auto; padding: 56px 28px 32px; }
.b-foot-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 24px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.b-foot-logo { font-family: 'Poppins',sans-serif; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.b-foot-sub { font-size: 13px; color: var(--text-3); }
.b-foot-links { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; }
.b-foot-links a { font-size: 13px; color: var(--text-3); transition: color .2s; }
.b-foot-links a:hover { color: var(--text); }
.b-foot-bottom { padding-top: 20px; font-size: 12px; color: var(--text-3); }
