/* Minimal, airy, glassy overrides for Anatole */
:root {
  --bg: #f6f7f9;
  --surface: rgba(255, 255, 255, 0.65);
  --border: rgba(15, 23, 42, 0.06);
  --text: #222426;
  --muted: #6b7280;
  --accent: #4786D6; /* keep theme accent for continuity */
  --radius: 16px;
  --blur: 12px;
  --shadow-sm: 0 4px 12px rgba(0,0,0,0.06);
  --shadow-md: 0 12px 32px rgba(0,0,0,0.08);
}

html, body {
  /* Desktop gets a subtle radial gradient; avoid fixed on mobile */
  background: radial-gradient(1200px 800px at 10% -10%, #ffffff 0%, var(--bg) 60%, #eef1f6 100%);
  background-repeat: no-repeat;
  background-attachment: scroll;
  color: var(--text);
  font-size: 16px;
  letter-spacing: 0.1px;
}

/* Ensure full-viewport layout without bottom cut */
body { margin-bottom: 0 !important; }
.main { min-height: 100vh; }
.autopagerize_page_element { min-height: calc(100vh - 60px); }

/* Mobile background banding fix: use simpler gradient, no fixed attachment */
@media screen and (max-width: 960px) {
  html, body {
    background: linear-gradient(180deg, #ffffff 0%, #f6f7f9 100%);
    background-repeat: no-repeat;
    background-attachment: scroll;
  }
}

/* Links */
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: #2f69b3; text-decoration: underline; }

/* Sidebar: translucent glass card */
.sidebar {
  background: var(--surface) !important;
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border-right: 1px solid var(--border) !important;
  box-shadow: var(--shadow-sm);
}
.sidebar .logo-title { padding-top: 200px; }
.sidebar .logo-title .title h3 a { color: var(--text); }
.sidebar .social-links a { color: var(--muted); }
.sidebar .social-links a:hover { color: var(--accent); }

/* Top bar: translucent, floaty */
.page-top {
  background: var(--surface) !important;
  border-bottom: 1px solid var(--border) !important;
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
}
.page-top .nav a { color: var(--muted); }
.page-top .nav a.current,
.page-top .nav a:hover { color: var(--text); }

/* Content width and spacing */
.content { padding-bottom: 80px; }
.post { 
  margin: 32px;
  padding: 24px 24px 18px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}
.post:hover { 
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.post .post-title h3, 
.post .post-title h2, 
.post .post-title h1 { letter-spacing: 0; color: var(--text); }
.post .post-content { color: #333; }
.post .post-footer { border-bottom: none; padding-bottom: 8px; }
.post .post-footer .meta { color: var(--muted); }
.post .post-footer .meta a { color: var(--muted); }

/* Home list: title only */
.is-home .post .post-content,
.is-home .post .post-footer { display: none !important; }
.is-home .post { padding: 18px 20px; }
.is-home .post .post-title h3 { margin: 0; }

/* Pages: tidy spacing */
.is-page .post { padding: 18px 24px 28px; }
.is-page .post .post-title {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 48px;
  padding: 10px 0;
  margin-bottom: 6px;
}
.is-page .post .post-title h1,
.is-page .post .post-title h2,
.is-page .post .post-title h3 {
  margin: 0;
}

.is-page .post .post-content > *:first-child {
  margin-top: 0;
}

/* Hello page specific vertical centering */
.page-hello .post {
  padding: 12px 22px 20px;
}
.page-hello .post .post-title {
  display: flex;
  align-items: center;
  min-height: 44px;
  margin-bottom: 6px;
  padding: 0;
  transform: translateY(-8px);
}
.page-hello .post .post-title h1,
.page-hello .post .post-title h2,
.page-hello .post .post-title h3 {
  margin: 0;
  line-height: 1.1;
}
.page-hello .post .post-content > hr:first-of-type {
  margin-top: 4px;
}

/* Lists and archive cleanup */
.pagination { 
  margin: 24px 32px 48px; 
  padding-bottom: 24px;
  border-bottom: 1px dashed var(--border);
}

/* Buttons: pill, subtle */
.btn, .menu .btn-down li a {
  border-radius: 999px !important;
  border: 1px solid var(--border) !important;
  color: var(--text) !important;
  background: rgba(255,255,255,0.5) !important;
  backdrop-filter: blur(6px);
}
.btn:hover, .menu .btn-down li a:hover { 
  background: rgba(255,255,255,0.9) !important;
  border-color: rgba(15,23,42,.12) !important;
}

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(8px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

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

/* Mobile polish */
@media screen and (max-width: 960px) {
  .post { margin: 20px 16px; padding: 18px; }
  .sidebar .logo-title { padding-top: 120px; }
}

.site-icp{margin-top:60px;padding:32px 18px 48px;text-align:center;font-size:12px;color:#8e96ad;}
.site-icp a{color:#8e96ad;border-bottom:1px dashed rgba(142,150,173,0.45);padding-bottom:1px;transition:color .2s,border-color .2s;}
.site-icp a:hover{color:var(--accent);border-color:transparent;}

/* Prevent ICP footer flash during page transitions */
.site-icp{opacity:0;transition:opacity .3s ease .15s;}
body.page-ready .site-icp{opacity:1;}
