html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  font-family: "Figtree", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-body);
  background: var(--bg);
}

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

/* ===================== HEADER ===================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: 60px;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
}

.header-inner {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-brand a {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.header-brand .brand-mark {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.header-brand .brand-text {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.header-nav a {
  font-family: "Figtree", sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.15s ease;
}

.header-nav a:hover {
  color: var(--text-primary);
}

.header-nav a.active {
  color: var(--text-primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn-download {
  display: inline-flex;
  align-items: center;
  background: var(--text-primary);
  color: var(--white);
  font-family: "Figtree", sans-serif;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: 6px;
  transition: background 0.15s ease;
}

.btn-download:hover {
  background: #333;
}

.github-link {
  display: flex;
  align-items: center;
  color: var(--text-secondary);
  transition: color 0.15s ease;
}

.github-link:hover {
  color: var(--text-primary);
}

.github-link svg {
  width: 20px;
  height: 20px;
}

/* ===================== PAGE HEADER ===================== */
.page-header {
  padding-top: 140px;
  padding-bottom: 48px;
  max-width: 800px;
  margin: 0 auto;
  padding-left: 32px;
  padding-right: 32px;
}

.page-header .label {
  display: inline-block;
  font-family: "Figtree", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-light);
  padding: 4px 12px;
  border-radius: 4px;
  margin-bottom: 16px;
}

.page-header h1 {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 48px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.page-header .subtitle {
  font-family: "Figtree", sans-serif;
  font-size: 18px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* ===================== FILTERS ===================== */
.filters {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 32px 40px;
  display: flex;
  align-items: center;
  gap: 4px;
  border-bottom: 1px solid var(--border);
}

.filter-link {
  font-family: "Figtree", sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  padding: 6px 14px;
  border-radius: 6px;
  transition: color 0.15s ease, background 0.15s ease;
  cursor: pointer;
}

.filter-link:hover {
  color: var(--text-secondary);
  background: var(--bg-subtle);
}

.filter-link.active {
  color: var(--text-primary);
  background: var(--bg-subtle);
}

/* ===================== TIMELINE ===================== */
.timeline-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 48px 32px 80px;
}

.timeline {
  position: relative;
  padding-left: 140px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 120px;
  top: 8px;
  bottom: 0;
  width: 1px;
  background: var(--border);
}

.timeline-entry {
  position: relative;
  padding-bottom: 56px;
}

.timeline-entry:last-child {
  padding-bottom: 0;
}

.timeline-entry:last-child .timeline::before {
  display: none;
}

.timeline-date {
  position: absolute;
  left: -140px;
  top: 2px;
  width: 108px;
  text-align: right;
  font-family: "Figtree", sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
}

.timeline-dot {
  position: absolute;
  left: -25px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border-dark);
}

.timeline-dot.latest {
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-light);
}

.timeline-content {
  padding-left: 0;
}

.version-badges {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.version-badge {
  display: inline-block;
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-light);
  padding: 3px 10px;
  border-radius: 20px;
}

.badge-latest {
  display: inline-block;
  font-family: "Figtree", sans-serif;
  font-size: 11px;
  font-weight: 600;
  color: var(--white);
  background: var(--accent);
  padding: 2px 8px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.timeline-title {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.release-section {
  margin-bottom: 20px;
}

.release-section h4 {
  font-family: "Figtree", sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.release-section h4 .emoji {
  font-size: 14px;
}

.release-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.release-section ul li {
  font-family: "Figtree", sans-serif;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.65;
  color: var(--text-body);
  padding: 3px 0 3px 20px;
  position: relative;
}

.release-section ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 12px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--border-dark);
}

.download-row {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.download-link {
  font-family: "Figtree", sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  transition: color 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.download-link:hover {
  color: var(--accent-hover);
}

.collapsible-toggle {
  display: inline-block;
  font-family: "Figtree", sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  margin-left: 24px;
  cursor: pointer;
  transition: color 0.15s ease;
  border: none;
  background: none;
  padding: 0;
}

.collapsible-toggle:hover {
  color: var(--text-secondary);
}

.collapsible-content {
  display: none;
  margin-top: 12px;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px 20px;
}

.collapsible-content.open {
  display: block;
}

.file-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.file-list li {
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  color: var(--text-body);
  padding: 4px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.file-list li .file-name {
  color: var(--text-body);
}

.file-list li .file-size {
  color: var(--text-muted);
  font-family: "Figtree", sans-serif;
  font-size: 12px;
}

/* ===================== FOOTER ===================== */
.site-footer {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  padding: 64px 0 32px;
}

.footer-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand .brand-title {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-brand .brand-title .fmark {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}

.footer-brand .brand-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.footer-col h4 {
  font-family: "Figtree", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col ul li a {
  font-size: 14px;
  color: var(--text-secondary);
  transition: color 0.15s ease;
}

.footer-col ul li a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
}

/* ===================== MOBILE ===================== */
@media (max-width: 768px) {
  .header-nav {
    display: none;
  }

  .page-header {
    padding-top: 110px;
    padding-bottom: 32px;
  }

  .page-header h1 {
    font-size: 32px;
  }

  .page-header .subtitle {
    font-size: 16px;
  }

  .timeline {
    padding-left: 0;
  }

  .timeline::before {
    display: none;
  }

  .timeline-dot {
    display: none;
  }

  .timeline-date {
    position: static;
    width: auto;
    text-align: left;
    margin-bottom: 8px;
  }

  .timeline-entry {
    padding-bottom: 40px;
    padding-left: 0;
    border-left: none;
    border-bottom: 1px solid var(--border);
    margin-bottom: 0;
  }

  .timeline-entry:last-child {
    border-bottom: none;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .collapsible-toggle {
    display: block;
    margin-left: 0;
    margin-top: 8px;
  }
}

@media (max-width: 480px) {
  .header-inner {
    padding: 0 16px;
  }

  .page-header {
    padding-left: 16px;
    padding-right: 16px;
  }

  .page-header h1 {
    font-size: 28px;
  }

  .filters {
    padding-left: 16px;
    padding-right: 16px;
  }

  .timeline-container {
    padding: 32px 16px 64px;
  }

  .footer-inner {
    padding: 0 16px;
  }
}
