/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  background: #001539;
  min-height: 100vh;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: #001539;
  color: #1a1a2e;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

/* ── Header ── */
header {
  background: #0f1b35;
  border-bottom: 1px solid #1e2d4d;
  position: sticky;
  top: 0;
  z-index: 100;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 14px 40px;
}

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

.logo img { height: 32px; border-radius: 6px; }

.logo-text {
  font-size: 1.15rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.02em;
}

nav {
  display: flex;
  gap: 4px;
  flex: 1;
}

nav a {
  color: #a8b8d0;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 6px;
  transition: background 0.15s, color 0.15s;
}

nav a:hover, nav a.active {
  background: #1e3a5f;
  color: #fff;
}

.topbar-actions { display: flex; gap: 8px; }

.btn {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
  white-space: nowrap;
}
.btn:hover { opacity: 0.88; transform: translateY(-1px); }
.btn-primary { background: #2563eb; color: #fff; }
.btn-secondary { background: transparent; color: #a8b8d0; border: 1px solid #2d4a6e; }
.btn-secondary:hover { color: #fff; border-color: #4a7ab5; }
.btn-download {
  background: #16a34a;
  color: #fff;
  padding: 7px 16px;
  font-size: 0.8rem;
  border-radius: 6px;
  letter-spacing: 0.04em;
}

/* ── Page Layout ── */
.page-wrap {
  display: flex;
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 40px 24px;
  gap: 40px;
}

/* ── Sidebar ── */
.sidebar {
  width: 220px;
  flex-shrink: 0;
}

.sidebar h2 {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #b0c4de;
  margin-bottom: 10px;
  padding-left: 4px;
}

.filter-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.filter-list li a {
  display: block;
  padding: 7px 12px;
  border-radius: 6px;
  font-size: 0.875rem;
  color: #b0c4de;
  transition: background 0.15s, color 0.15s;
}

.filter-list li a:hover,
.filter-list li a.active {
  background: #1e3a5f;
  color: #fff;
  font-weight: 600;
}

/* ── Main Content ── */
.releases-main { flex: 1; min-width: 0; }

.releases-main h1 {
  font-size: 1.75rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 6px;
}

.releases-main .subtitle {
  color: #b0c4de;
  font-size: 0.9rem;
  margin-bottom: 32px;
}

/* ── Release Card ── */
.release-card {
  background: #0f1b35;
  border: 1px solid #1e2d4d;
  border-radius: 12px;
  margin-bottom: 20px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.release-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 24px;
  border-bottom: 1px solid #1e2d4d;
  flex-wrap: wrap;
}

.release-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #64b5f6;
  flex: 1;
  min-width: 200px;
}

.release-title:hover { text-decoration: underline; }

.badge {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.badge-stable   { background: #dcfce7; color: #15803d; }
.badge-early    { background: #fef9c3; color: #854d0e; }
.badge-platform { background: #ede9fe; color: #6d28d9; }
.badge-agents   { background: #dbeafe; color: #1e40af; }
.badge-licensing { background: #fce7f3; color: #9d174d; }

.release-meta {
  font-size: 0.8rem;
  color: #90caf9;
  white-space: nowrap;
}

.release-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

.checksum-link {
  font-size: 0.75rem;
  color: #90caf9;
  text-decoration: underline;
  cursor: pointer;
}
.checksum-link:hover { color: #bbdefb; }

/* ── Release Body ── */
.release-body {
  padding: 20px 24px;
}

.release-body p {
  font-size: 0.9rem;
  color: #d0d8e0;
  line-height: 1.7;
  margin-bottom: 14px;
}

.release-body h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #ffffff;
  margin: 18px 0 8px;
}

.release-body ul, .release-body ol {
  padding-left: 20px;
  margin-bottom: 12px;
}

.release-body li {
  font-size: 0.875rem;
  color: #d0d8e0;
  line-height: 1.7;
  margin-bottom: 4px;
}

.release-body .read-more {
  display: inline-block;
  font-size: 0.8rem;
  color: #2563eb;
  font-weight: 600;
  margin-top: 6px;
  cursor: pointer;
  text-decoration: underline;
}

.release-body .eula-note {
  font-size: 0.75rem;
  color: #90caf9;
  border-top: 1px solid #1e2d4d;
  padding-top: 12px;
  margin-top: 16px;
}

.release-body .eula-note a { color: #64b5f6; text-decoration: underline; }

/* ── Platform label strip ── */
.platform-strip {
  display: flex;
  gap: 6px;
  padding: 10px 24px;
  background: #0f1b35;
  border-bottom: 1px solid #1e2d4d;
}

/* ── Collapsible details ── */
details summary {
  list-style: none;
  cursor: pointer;
  font-size: 0.8rem;
  color: #64b5f6;
  font-weight: 600;
  margin-top: 6px;
}
details summary::-webkit-details-marker { display: none; }
details summary::before { content: "▶ "; font-size: 0.65rem; }
details[open] summary::before { content: "▼ "; }
details .detail-body { margin-top: 12px; }

/* ── Archive link ── */
.archive-link {
  text-align: center;
  padding: 24px;
  font-size: 0.875rem;
  color: #b0c4de;
}
.archive-link a { color: #64b5f6; text-decoration: underline; }

/* ── Footer ── */
footer {
  background: #0f1b35;
  color: #b0c4de;
  text-align: center;
  padding: 20px;
  font-size: 0.8rem;
  margin-top: auto;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .topbar { padding: 12px 16px; gap: 16px; }
  nav { display: none; }
  .page-wrap { flex-direction: column; padding: 24px 16px; gap: 24px; }
  .sidebar { width: 100%; }
  .filter-list { flex-direction: row; flex-wrap: wrap; }
}
