@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap');

[hidden] { display: none !important; }

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

/* html provides the page background so the canvas can sit in between */
html {
  background: var(--bg);
  color: var(--ink);
  transition: background 0.2s ease;
}

body {
  font-family: 'Inter', sans-serif;
  background: transparent; /* let html bg show through behind the canvas */
  color: var(--ink);
  min-height: 100vh;
  padding: 0 20px;
}

/* Particle canvas — sits between html bg and body content */
#particle-canvas {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.column {
  max-width: 460px;
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 1;
}

a {
  color: inherit;
  text-decoration: none;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---- Icon button base ---- */
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  color: var(--ink);
  flex-shrink: 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.icon-btn:hover {
  background: var(--accent-soft);
  border-color: var(--ink);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---- Sun/moon toggle visibility ---- */
.icon-sun { display: none; }
.icon-moon { display: block; }
[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }

/* ---- Theme toggle — fixed top-right on desktop, scrolls away on mobile ---- */
.theme-toggle {
  position: fixed;
  top: 16px;
  right: 20px;
  z-index: 50;
}

@media (max-width: 767px) {
  .theme-toggle {
    position: static;
  }
}

/* ---- Sub-page header ---- */
.sub-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 28px;
}

.sub-header-title h1 {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 22px;
  color: var(--ink);
  white-space: nowrap;
  letter-spacing: -0.02em;
}

.sub-header-rule {
  flex: 1;
  height: 1px;
  background: var(--line);
  align-self: center;
}

.sub-header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

/* ---- Sub-page main content ---- */
.page-content {
  background: var(--surface);
  border-radius: 20px;
  border: 1px solid var(--line);
  box-shadow: 0 2px 24px rgba(13, 15, 26, 0.05);
  padding: 28px;
  margin-top: 16px;
  margin-bottom: 24px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

[data-theme="dark"] .page-content {
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.28);
}

/* ---- Sub-page footer (social icon cards) ---- */
.sub-footer {
  padding: 20px 0 32px;
  border-top: 1px solid var(--line);
}

.sub-footer .social-icons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.sub-footer .social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--accent-soft);
  border: 1px solid var(--line);
  color: var(--muted);
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  line-height: 0;
}

.sub-footer .social-icon:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--surface);
}

.sub-footer .social-icon svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  stroke: none;
}

.sub-footer .social-icon .svg-inline--fa {
  width: 16px;
  height: 16px;
}

/* ---- Shared empty state ---- */
.empty-state {
  font-size: 14px;
  color: var(--muted);
  font-style: italic;
  padding: 24px 0;
}
