/* Download page */

.download-page .download-main {
  padding: calc(var(--header-h) + 2.5rem) 0 4rem;
  min-height: calc(100vh - var(--header-h));
}

.download-hero {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 2.5rem;
}

.download-hero h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.75rem;
}

.download-hero p {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.65;
}

.download-status {
  text-align: center;
  color: var(--text-muted);
  padding: 2rem;
}

.download-status--error {
  color: #f87171;
}

.download-grid {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  max-width: 720px;
  margin-inline: auto;
}

/* Platform groups — full-width rows */
.dl-platform {
  padding: 1.5rem 1.75rem;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--bg-card);
  width: 100%;
}

.dl-platform--windows {
  border-left: 3px solid #0078d4;
  background: linear-gradient(90deg, rgba(0, 120, 212, 0.06) 0%, var(--bg-card) 30%);
}

.dl-platform--macos {
  border-left: 3px solid #a2aaad;
  background: linear-gradient(90deg, rgba(162, 170, 173, 0.06) 0%, var(--bg-card) 30%);
}

.dl-platform--linux {
  border-left: 3px solid #e95420;
  background: linear-gradient(90deg, rgba(233, 84, 32, 0.06) 0%, var(--bg-card) 30%);
}

.dl-platform-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.dl-platform-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  flex-shrink: 0;
}

.dl-platform-icon svg {
  width: 26px;
  height: 26px;
}

.dl-platform-icon--win {
  background: rgba(0, 120, 212, 0.15);
  color: #0078d4;
}

.dl-platform-icon--mac {
  background: rgba(162, 170, 173, 0.15);
  color: #d4d4d8;
}

.dl-platform-icon--linux {
  background: rgba(233, 84, 32, 0.15);
  color: #e95420;
}

.dl-platform-head h2 {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.1rem;
}

.dl-platform-head p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* File rows */
.dl-file-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.dl-file {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  background: var(--bg-card-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: var(--transition);
}

.dl-platform--windows .dl-file:hover {
  border-color: rgba(0, 120, 212, 0.4);
}

.dl-platform--macos .dl-file:hover {
  border-color: rgba(162, 170, 173, 0.4);
}

.dl-platform--linux .dl-file:hover {
  border-color: rgba(233, 84, 32, 0.4);
}

.dl-file-info {
  min-width: 0;
}

.dl-file-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
  word-break: break-all;
}

.dl-file-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

.dl-btn {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
  white-space: nowrap;
}

.dl-btn svg {
  width: 16px;
  height: 16px;
}

.dl-btn--win {
  background: #0078d4;
  color: #fff;
}

.dl-btn--win:hover {
  background: #1084d8;
  box-shadow: 0 4px 16px rgba(0, 120, 212, 0.35);
}

.dl-btn--mac {
  background: #3a3a3c;
  color: #f5f5f7;
  border: 1px solid #636366;
}

.dl-btn--mac:hover {
  background: #48484a;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

.dl-btn--linux {
  background: #e95420;
  color: #fff;
}

.dl-btn--linux:hover {
  background: #ed6530;
  box-shadow: 0 4px 16px rgba(233, 84, 32, 0.35);
}

.dl-empty {
  font-size: 0.85rem;
  color: var(--text-dim);
  font-style: italic;
  padding: 0.5rem 0.25rem;
}

.download-archive {
  text-align: center;
  margin-top: 1.75rem;
}

.download-archive a {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
}

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

@media (max-width: 600px) {
  .dl-file {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }

  .dl-btn {
    justify-content: center;
  }
}
