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

:root {
  --bg: #0d1117;
  --surface: #161b22;
  --surface2: #1c2230;
  --border: #30363d;
  --accent: #2f81f7;
  --accent-dim: #1a4a8a;
  --green: #3fb950;
  --text: #e6edf3;
  --text-muted: #8b949e;
  --text-dim: #6e7681;
  --radius: 10px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; }

/* ── HEADER ── */
header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  gap: 20px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 600;
  font-size: 15px;
  text-decoration: none;
  flex-shrink: 0;
}
.logo img { border-radius: 6px; }
.logo span { display: none; }
@media (min-width: 480px) { .logo span { display: inline; } }

nav { display: flex; gap: 4px; flex-wrap: wrap; }
nav a {
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  transition: color 0.15s, background 0.15s;
  text-decoration: none;
}
nav a:hover, nav a.active {
  color: var(--text);
  background: rgba(255,255,255,0.07);
}

/* ── PARTY BANNER ── */
.party-banner {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 40px 24px;
}
.party-banner-inner {
  max-width: 960px;
  margin: 0 auto;
}
.party-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 10px;
}
.party-banner h1 {
  font-size: clamp(26px, 5vw, 40px);
  font-weight: 800;
  letter-spacing: -1px;
  margin-bottom: 8px;
}
.party-banner p {
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 20px;
}
.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 10px 22px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
}
.btn:hover { background: #1f6fd1; text-decoration: none; }

/* ── SUBPROJECTS ── */
.subprojects {
  max-width: 960px;
  margin: 40px auto 0;
  padding: 0 24px;
}
.subprojects h2 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.subproject-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}
.subproject-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 18px;
  text-decoration: none;
  transition: border-color 0.2s, transform 0.15s;
}
.subproject-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  text-decoration: none;
}
.sp-icon { font-size: 28px; display: block; margin-bottom: 10px; }
.subproject-card h3 { font-size: 14px; color: var(--text); margin-bottom: 6px; }
.subproject-card p { font-size: 12px; color: var(--text-muted); line-height: 1.5; }

/* ── POSTS LIST ── */
.posts-section {
  max-width: 960px;
  margin: 48px auto;
  padding: 0 24px;
}
.posts-section h2 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 20px;
}
.posts-list { display: flex; flex-direction: column; gap: 16px; }

.post-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  transition: border-color 0.2s;
}
.post-card:hover { border-color: #484f58; }
.post-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}
.post-meta time { font-size: 12px; color: var(--text-dim); }
.cats, .cat-tag {
  font-size: 11px;
  background: rgba(47,129,247,0.12);
  color: #79c0ff;
  border: 1px solid rgba(47,129,247,0.25);
  border-radius: 4px;
  padding: 2px 8px;
}
.post-card h2 { font-size: 16px; margin-bottom: 8px; }
.post-card h2 a { color: var(--text); }
.post-card h2 a:hover { color: var(--accent); text-decoration: none; }
.post-card p { font-size: 13px; color: var(--text-muted); margin-bottom: 12px; }
.read-more { font-size: 13px; color: var(--accent); }

/* ── SINGLE POST / PAGE ── */
.container {
  max-width: 780px;
  margin: 48px auto;
  padding: 0 24px;
}
.post-single h1, .page-content h1 {
  font-size: clamp(22px, 4vw, 32px);
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 24px;
  line-height: 1.3;
}
.post-single .post-meta { margin-bottom: 24px; }

/* ── PROSE (WordPress content) ── */
.prose {
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1.75;
}
.prose p { margin-bottom: 16px; }
.prose h1, .prose h2, .prose h3, .prose h4 {
  color: var(--text);
  margin: 28px 0 12px;
  line-height: 1.3;
}
.prose h2 { font-size: 20px; }
.prose h3 { font-size: 17px; }
.prose a { color: var(--accent); }
.prose img {
  border-radius: 8px;
  margin: 16px 0;
  max-width: 100%;
}
.prose ul, .prose ol {
  padding-left: 24px;
  margin-bottom: 16px;
}
.prose li { margin-bottom: 6px; }
.prose blockquote {
  border-left: 3px solid var(--border);
  padding-left: 16px;
  color: var(--text-dim);
  font-style: italic;
  margin: 20px 0;
}
.prose strong { color: var(--text); }
.prose figure { margin: 20px 0; }
.prose figcaption { font-size: 12px; color: var(--text-dim); margin-top: 6px; }
/* hide WordPress block wrapper classes visual clutter */
.prose [class*="wp-block"] { max-width: 100% !important; }
.prose [class*="wp-container"] { max-width: 100% !important; }

/* contact form */
.prose input, .prose textarea, .prose select {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  padding: 8px 12px;
  font-size: 14px;
  width: 100%;
  margin-bottom: 12px;
}
.prose input:focus, .prose textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.prose button, .prose input[type="submit"] {
  background: var(--accent);
  color: white;
  border: none;
  padding: 10px 22px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  width: auto;
}

.post-nav { margin-top: 40px; }
.btn-back {
  display: inline-block;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 13px;
  text-decoration: none;
}
.btn-back:hover { border-color: #484f58; color: var(--text); text-decoration: none; }

/* ── FOOTER ── */
footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 28px 24px;
  margin-top: auto;
}
.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
}
.footer-projects {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.footer-projects strong { color: var(--text-muted); margin-right: 4px; }
.footer-projects a {
  color: var(--text-dim);
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 12px;
}
.footer-projects a:hover { color: var(--text); text-decoration: none; }
.footer-contact { display: flex; gap: 12px; }
.footer-contact a { color: var(--text-muted); }
.footer-copy { color: var(--text-dim); }
