:root {
  --bg: #ffffff;
  --fg: #0f172a;
  --muted: #475569;
  --card: #f8fafc;
  --border: #e2e8f0;
  --primary: #2563eb;
  --primary-press: #1e40af;
  --radius: 16px;
  --shadow: 0 4px 12px rgba(2, 6, 23, 0.08);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b1020;
    --fg: #e5e7eb;
    --muted: #9aa3b2;
    --card: #111827;
    --border: #1f2937;
    --primary: #60a5fa;
    --primary-press: #3b82f6;
    --shadow: 0 8px 20px rgba(0,0,0,0.3);
  }
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  height: 100%;
  overflow-x: hidden;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  color: var(--fg);
  background: var(--bg);
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

.container {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding: 0 20px;
}

.site-header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(8px);
  background: color-mix(in oklab, var(--bg), transparent 20%);
  border-bottom: 1px solid var(--border);
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand-mark {
  font-size: 18px;
  line-height: 1;
}

.brand-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
}

.brand-title {
  font-weight: 700;
  font-size: 18px;
  color: var(--fg);
}

.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  z-index: 101;
}

.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--fg);
  transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  height: 100vh;
  background: var(--card);
  border-left: 1px solid var(--border);
  padding: 80px 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: right 0.3s ease;
  z-index: 99;
}

.nav.active {
  right: 0;
}

.nav-link {
  text-decoration: none;
  color: var(--muted);
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 18px;
  transition: all 0.2s ease;
}

.nav-link:hover {
  color: var(--fg);
  background: color-mix(in oklab, var(--card), var(--bg) 20%);
}

.mobile-subscribe {
  margin-top: 20px;
  display: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  padding: 0 24px;
  border-radius: 12px;
  border: none;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  transition: all 0.2s ease;
  white-space: nowrap;
  width: 100%;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover {
  background: var(--primary-press);
}

.btn-ghost {
  background: transparent;
  color: var(--fg);
  border: 1px solid var(--border);
}

.btn-lg {
  height: 56px;
  font-size: 18px;
}

.section {
  padding: 60px 0;
}

.hero {
  padding-top: 40px;
  text-align: center;
}

.h1 {
  font-size: 32px;
  line-height: 1.2;
  margin: 0 0 16px;
  font-weight: 700;
}

.h2 {
  font-size: 24px;
  margin: 0 0 12px;
  font-weight: 600;
}

.lead {
  font-size: 18px;
  color: var(--muted);
  margin: 0 0 24px;
}

.actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 24px;
}

.mobile-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}

.card h2 {
  margin-top: 0;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 30px 0;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  max-width: 100%;
}

.footer-links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  padding: 4px 8px;
  text-align: center;
  flex-shrink: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.footer-links a:hover {
  color: var(--fg);
}

@media (max-width: 360px) {
  .footer-links {
    gap: 8px;
  }
  
  .footer-links a {
    font-size: 12px;
    padding: 3px 6px;
  }
}

@media (max-width: 768px) {
  .footer-inner {
    text-align: center;
    padding: 0 10px;
  }
  
  .footer-links {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }
  
  .footer-links a {
    width: auto;
    white-space: normal;
    text-align: center;
    line-height: 1.4;
  }
}

@media (max-width: 480px) {
  .footer-links {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    text-align: center;
    gap: 10px;
  }
  
  .footer-links a {
    white-space: normal;
    word-break: break-word;
    padding: 6px 4px;
  }
}

.muted {
  color: var(--muted);
}

@media (min-width: 480px) {
  .actions {
    flex-direction: row;
    justify-content: center;
  }
  
  .btn {
    width: auto;
  }
}

@media (min-width: 1000px) {
  .menu-toggle {
    display: none;
  }
  
  .nav {
    position: static;
    width: auto;
    height: auto;
    background: transparent;
    border: none;
    padding: 0;
    flex-direction: row;
    align-items: center;
    margin-left: auto;
  }
  
  .mobile-subscribe {
    display: none;
  }
  
  .mobile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
  }
  
  .container {
    max-width: 720px;
  }
}

@media (min-width: 1000px) {
  .container {
    max-width: 960px;
  }
  
  .h1 {
    font-size: 40px;
  }
}

.error-title {
  color: #c23838;
}

.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 15px 0;
  z-index: 10000;
  box-shadow: 0 -4px 12px rgba(0,0,0,0.1);
}

.cookie-banner p {
  margin: 0;
  font-size: 14px;
  color: var(--fg);
}

.cookie-banner a {
  color: var(--primary);
  text-decoration: underline;
}

.cookie-banner button {
  white-space: nowrap;
}