:root {
  color-scheme: light;
  --canvas: #f3f5f4;
  --surface: #ffffff;
  --ink: #191d1c;
  --muted: #66706c;
  --subtle: #89918e;
  --line: #dbe1df;
  --line-strong: #c9d1ce;
  --accent: #ed5d2a;
  --accent-hover: #d94e20;
  --accent-soft: #fff0ea;
  --success: #1d7652;
  --shadow: 0 18px 50px rgba(31, 43, 39, 0.08);
  font-family: Inter, "Segoe UI", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  background: var(--canvas);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px),
    var(--canvas);
  background-size: 48px 48px;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

.page-shell {
  width: min(100% - 40px, 1120px);
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.site-header {
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid var(--line-strong);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
}

.brand-mark {
  width: 27px;
  height: 27px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: end;
  gap: 3px;
}

.brand-mark span {
  display: block;
  background: var(--ink);
}

.brand-mark span:nth-child(1) {
  height: 12px;
}

.brand-mark span:nth-child(2) {
  height: 21px;
  background: var(--accent);
}

.brand-mark span:nth-child(3) {
  height: 17px;
}

.brand-name {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0;
}

.delivery-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 0 4px rgba(29, 118, 82, 0.1);
}

.download-main {
  width: 100%;
  display: grid;
  align-content: center;
  gap: 34px;
  padding: 56px 0 64px;
}

.intro {
  max-width: 680px;
}

.eyebrow {
  margin: 0 0 13px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
}

.intro h1 {
  margin: 0;
  font-size: 42px;
  line-height: 1.14;
  font-weight: 760;
  letter-spacing: 0;
}

.intro-copy {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.file-card {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.file-summary {
  min-width: 0;
  display: grid;
  grid-template-columns: 124px minmax(0, 1fr);
  gap: 30px;
  align-items: center;
  padding: 38px 40px;
}

.file-visual {
  width: 124px;
  height: 146px;
  position: relative;
  display: grid;
  place-items: center;
  color: var(--ink);
  background: var(--accent-soft);
  border: 1px solid #f1c7b7;
  border-radius: 6px;
}

.file-visual::before {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(237, 93, 42, 0.2);
}

.file-visual svg {
  width: 55px;
  height: 55px;
}

.extension-badge {
  position: absolute;
  right: 10px;
  bottom: 10px;
  min-width: 40px;
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 7px;
  color: #ffffff;
  background: var(--ink);
  border-radius: 4px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.file-details {
  min-width: 0;
}

.file-kicker {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 750;
}

.file-details h2 {
  max-width: 100%;
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 24px;
  line-height: 1.35;
  font-weight: 720;
  letter-spacing: 0;
}

.file-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin: 26px 0 0;
}

.file-meta div {
  min-width: 0;
}

.file-meta dt {
  margin-bottom: 5px;
  color: var(--subtle);
  font-size: 12px;
}

.file-meta dd {
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.45;
}

.download-actions {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 38px;
  background: #f8faf9;
  border-left: 1px solid var(--line);
}

.checksum {
  min-width: 0;
  margin-bottom: 22px;
}

.checksum span {
  display: block;
  margin-bottom: 7px;
  color: var(--subtle);
  font-size: 11px;
  font-weight: 700;
}

.checksum code {
  display: block;
  min-height: 19px;
  overflow: hidden;
  color: var(--muted);
  font: 12px/1.6 "Cascadia Mono", Consolas, monospace;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.download-button {
  width: 100%;
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 22px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  color: #ffffff;
  background: var(--accent);
  box-shadow: 0 8px 18px rgba(237, 93, 42, 0.2);
  cursor: pointer;
  font-size: 15px;
  font-weight: 750;
  transition: background-color 160ms ease, border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.download-button svg {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
}

.download-button:hover:not(:disabled) {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  box-shadow: 0 10px 22px rgba(217, 78, 32, 0.24);
  transform: translateY(-1px);
}

.download-button:active:not(:disabled) {
  transform: translateY(0);
}

.download-button:focus-visible {
  outline: 3px solid rgba(237, 93, 42, 0.22);
  outline-offset: 3px;
}

.download-button:disabled {
  color: #909895;
  background: #e4e8e6;
  border-color: #e4e8e6;
  box-shadow: none;
  cursor: wait;
}

.download-button.is-loading svg {
  animation: download-pulse 760ms ease-in-out infinite alternate;
}

.download-status {
  min-height: 20px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
}

.download-status.is-success {
  color: var(--success);
  font-weight: 650;
}

.download-status.is-error {
  color: #b3261e;
  font-weight: 650;
}

.site-footer {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line-strong);
  color: var(--subtle);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0;
}

@keyframes download-pulse {
  from {
    transform: translateY(-2px);
  }
  to {
    transform: translateY(2px);
  }
}

@media (max-width: 880px) {
  .download-main {
    align-content: start;
    padding-top: 44px;
  }

  .file-card {
    grid-template-columns: minmax(0, 1fr);
  }

  .download-actions {
    border-top: 1px solid var(--line);
    border-left: 0;
  }
}

@media (max-width: 620px) {
  .page-shell {
    width: min(100% - 28px, 1120px);
  }

  .site-header {
    min-height: 72px;
  }

  .brand-name {
    font-size: 17px;
  }

  .download-main {
    gap: 26px;
    padding: 36px 0 42px;
  }

  .intro h1 {
    font-size: 32px;
  }

  .intro-copy {
    font-size: 14px;
  }

  .file-summary {
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
    padding: 26px 22px;
  }

  .file-visual {
    width: 76px;
    height: 92px;
  }

  .file-visual svg {
    width: 38px;
    height: 38px;
  }

  .extension-badge {
    right: 6px;
    bottom: 6px;
    min-width: 34px;
    min-height: 20px;
    padding: 2px 5px;
    font-size: 9px;
  }

  .file-kicker {
    margin-top: 2px;
    margin-bottom: 7px;
  }

  .file-details h2 {
    font-size: 19px;
  }

  .file-meta {
    grid-template-columns: 1fr 1fr;
    gap: 15px 18px;
    margin-top: 20px;
  }

  .file-meta div:last-child {
    grid-column: 1 / -1;
  }

  .download-actions {
    padding: 26px 22px 24px;
  }

  .checksum {
    margin-bottom: 18px;
  }

  .site-footer {
    min-height: 62px;
  }
}

@media (max-width: 390px) {
  .delivery-label {
    font-size: 11px;
  }

  .file-summary {
    grid-template-columns: minmax(0, 1fr);
  }

  .file-visual {
    width: 100%;
    height: 90px;
  }

  .file-meta {
    grid-template-columns: 1fr;
  }

  .file-meta div:last-child {
    grid-column: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
