:root {
  --brand: #11998e;
  --brand-light: #1ab3a6;
  --text: #111827;
  --muted: #4b5563;
  --soft: #f9fafb;
  --line: #e5e7eb;
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-hover: 0 12px 30px rgba(15, 23, 42, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #fff;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  border: 0;
  font: inherit;
}

img,
svg {
  display: block;
}

.site-shell {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.header {
  position: fixed;
  top: 0;
  z-index: 40;
  width: 100%;
  background: #fff;
  box-shadow: var(--shadow);
}

.nav {
  display: flex;
  height: 48px;
  max-width: 100rem;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 auto;
  padding: 0 48px;
}

.brand {
  display: flex;
  min-width: 150px;
  align-items: center;
  transition: transform 0.2s ease;
}

.brand:hover {
  transform: scale(1.05);
}

.nav__links {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 0;
}

.nav__links a {
  border-radius: 8px;
  padding: 8px 12px;
  color: #4b5563;
  font-size: 16px;
  font-weight: 500;
  white-space: nowrap;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.nav__links a:hover {
  background: #f3f4f6;
  color: #111827;
}

.nav__links .active {
  background: #e5e7eb;
  color: #111827;
  box-shadow: var(--shadow);
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.login {
  min-width: 50px;
  color: #4b5563;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
  transition: color 0.2s ease;
}

.login:hover {
  color: var(--brand);
}

.signup {
  min-width: 90px;
  border-radius: 6px;
  background: var(--brand);
  padding: 6px 16px;
  color: #fff;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.signup:hover {
  background: var(--brand-light);
  box-shadow: 0 6px 16px rgba(17, 153, 142, 0.24);
}

.language {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-radius: 8px;
  background: #f5f7fa;
  padding: 4px;
  color: #374151;
  font-size: 14px;
  font-weight: 500;
}

.language__option {
  border-radius: 6px;
  background: transparent;
  color: #4b5563;
  cursor: pointer;
  padding: 6px 10px;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.language__option:hover {
  color: var(--brand);
}

.language__option.active {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 4px 10px rgba(17, 153, 142, 0.22);
}

.menu {
  display: none;
  border-radius: 6px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  padding: 6px;
}

.menu svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.main {
  flex: 1;
  padding: 80px 16px 80px;
}

.download-section {
  max-width: 80rem;
  margin: 0 auto;
  padding: 48px 16px 0;
}

.download-section h1 {
  margin: 0 0 48px;
  color: #111827;
  font-size: 40px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  text-align: center;
}

.download-grid {
  display: grid;
  max-width: 56rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
  margin: 0 auto;
}

.download-card {
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.download-card:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.download-card__top {
  display: flex;
  min-height: 298px;
  flex-direction: column;
  align-items: center;
  border-bottom: 1px solid #f3f4f6;
  padding: 32px;
  text-align: center;
}

.platform-icon {
  position: relative;
  display: grid;
  width: 96px;
  height: 96px;
  place-items: center;
  margin-bottom: 24px;
}

.platform-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.platform-icon--apple {
  padding: 16px;
}

.download-card h2 {
  margin: 0 0 8px;
  color: #111827;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.35;
}

.download-button {
  display: inline-flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  cursor: pointer;
  font-weight: 500;
  margin-top: 14px;
  padding: 12px 24px;
  box-shadow: 0 10px 18px rgba(17, 153, 142, 0.2);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.download-button:hover {
  background: var(--brand-light);
  box-shadow: 0 14px 26px rgba(17, 153, 142, 0.3);
  transform: scale(1.02);
}

.download-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.download-button--disabled {
  background: #9ca3af;
  box-shadow: none;
  cursor: not-allowed;
}

.download-button--disabled:hover {
  background: #9ca3af;
  box-shadow: none;
  transform: none;
}

.server-note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 6px 0 0;
  color: #6b7280;
  font-size: 12px;
}

.server-note svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.requirements {
  background: #f9fafb;
  padding: 24px;
}

.requirements h3 {
  margin: 0 0 16px;
  color: #111827;
  font-size: 14px;
  font-weight: 500;
}

.requirements ul {
  display: grid;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.requirements li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: #4b5563;
  font-size: 14px;
}

.requirement-icon {
  position: relative;
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  color: #9ca3af;
}

.requirement-icon::before,
.requirement-icon::after {
  position: absolute;
  content: "";
}

.requirement-icon.drive::before {
  inset: 3px 1px 4px;
  border: 2px solid currentColor;
  border-radius: 4px;
}

.requirement-icon.drive::after {
  left: 5px;
  right: 5px;
  bottom: 7px;
  height: 2px;
  background: currentColor;
  box-shadow: 0 4px 0 currentColor;
}

.requirement-icon.cpu::before {
  inset: 4px;
  border: 2px solid currentColor;
  border-radius: 4px;
}

.requirement-icon.cpu::after {
  inset: 8px;
  border: 2px solid currentColor;
  border-radius: 2px;
  box-shadow:
    0 -9px 0 -4px currentColor,
    0 9px 0 -4px currentColor,
    -9px 0 0 -4px currentColor,
    9px 0 0 -4px currentColor;
}

.requirement-icon.chip::before {
  inset: 2px;
  border: 2px solid currentColor;
  border-radius: 4px;
}

.requirement-icon.chip::after {
  left: 7px;
  top: 7px;
  width: 6px;
  height: 6px;
  border: 2px solid currentColor;
  border-radius: 2px;
}

.footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 48px 16px 0;
}

.footer__grid {
  display: grid;
  max-width: 56rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 32px;
  justify-items: start;
  margin: 0 auto;
}

.footer h2 {
  margin: 0 0 16px;
  color: #111827;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.footer a {
  display: block;
  color: #4b5563;
  font-size: 16px;
  margin-top: 12px;
  transition: color 0.2s ease;
}

.footer a:hover {
  color: var(--brand);
}

.copyright {
  max-width: 80rem;
  border-top: 1px solid var(--line);
  color: #6b7280;
  font-size: 16px;
  margin: 32px auto 0;
  padding: 32px 0;
  text-align: center;
}

.tutorial-section {
  max-width: 80rem;
  margin: 0 auto;
  padding: 48px 16px 0;
}

.tutorial-hero {
  max-width: 48rem;
  margin: 0 auto 40px;
  text-align: center;
}

.tutorial-eyebrow {
  margin: 0 0 12px;
  color: var(--brand);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tutorial-hero h1 {
  margin: 0 0 16px;
  color: #111827;
  font-size: 40px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.tutorial-lead {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.6;
}

.tutorial-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

.tutorial-toc {
  position: sticky;
  top: 72px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 20px;
}

.tutorial-toc__title {
  margin: 0 0 12px;
  color: #111827;
  font-size: 14px;
  font-weight: 600;
}

.tutorial-toc ol {
  display: grid;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
}

.tutorial-toc li {
  counter-increment: toc;
}

.tutorial-toc a {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  border-radius: 6px;
  color: #4b5563;
  font-size: 14px;
  line-height: 1.45;
  padding: 8px 10px;
  transition: background 0.2s ease, color 0.2s ease;
}

.tutorial-toc a::before {
  content: counter(toc, decimal-leading-zero);
  color: var(--brand);
  font-weight: 600;
}

.tutorial-toc a:hover {
  background: #f3f4f6;
  color: #111827;
}

.tutorial-content {
  display: grid;
  gap: 24px;
}

.tutorial-card {
  scroll-margin-top: 80px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 28px 32px;
}

.tutorial-card__header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.tutorial-step-badge {
  display: inline-grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(17, 153, 142, 0.12);
  color: var(--brand);
  font-size: 14px;
  font-weight: 700;
}

.tutorial-card h2 {
  margin: 0;
  color: #111827;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.3;
}

.tutorial-steps {
  display: grid;
  gap: 20px;
  margin: 0;
  padding: 0 0 0 22px;
  color: #374151;
  font-size: 16px;
  line-height: 1.65;
}

.tutorial-steps > li::marker {
  color: var(--brand);
  font-weight: 600;
}

.tutorial-steps p {
  margin: 0;
}

.tutorial-steps a {
  color: var(--brand);
  font-weight: 500;
}

.tutorial-steps a:hover {
  text-decoration: underline;
}

.tutorial-figure {
  margin: 16px 0 0;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  padding: 16px;
}

.tutorial-figure img {
  width: 100%;
  max-width: 640px;
  height: auto;
  margin: 0 auto;
  border-radius: 4px;
}

.tutorial-figure--narrow img {
  max-width: 320px;
}

.tutorial-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-weight: 500;
  padding: 12px 20px;
  box-shadow: 0 10px 18px rgba(17, 153, 142, 0.2);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.tutorial-cta:hover {
  background: var(--brand-light);
  box-shadow: 0 14px 26px rgba(17, 153, 142, 0.3);
  transform: scale(1.02);
}

.tutorial-cta svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.changelog-section {
  max-width: 56rem;
  margin: 0 auto;
  padding: 48px 16px 0;
}

.changelog-hero {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.changelog-hero__icon {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  color: #5bb8d4;
}

.changelog-hero__icon svg {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.6;
}

.changelog-hero h1 {
  margin: 0;
  color: #111827;
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.changelog-panel {
  overflow: hidden;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow);
}

.changelog-years {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  background: #f3f4f6;
  border-bottom: 1px solid #e5e7eb;
  padding: 14px 20px;
}

.changelog-year {
  border-radius: 6px;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
  font-size: 15px;
  font-weight: 500;
  padding: 8px 14px;
  transition: background 0.2s ease, color 0.2s ease;
}

.changelog-year:hover {
  background: rgba(255, 255, 255, 0.7);
  color: #111827;
}

.changelog-year.active {
  background: #fff;
  color: #111827;
  font-weight: 700;
  box-shadow: var(--shadow);
}

.changelog-body {
  padding: 28px 32px 32px;
}

.changelog-year-panel {
  display: none;
}

.changelog-year-panel.active {
  display: grid;
  gap: 28px;
}

.changelog-entry__version {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  color: #2f9a57;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.4;
}

.changelog-entry__version::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 auto;
}

.changelog-entry__version time {
  font-weight: 600;
}

.changelog-entry ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0 0 0 22px;
  color: #374151;
  font-size: 15px;
  line-height: 1.65;
  list-style: disc;
}

.changelog-entry li::marker {
  color: #9ca3af;
}

@media (max-width: 1160px) {
  .nav {
    padding: 0 24px;
  }

  .nav__links {
    gap: 2px;
  }

  .nav__links a {
    padding: 8px 9px;
  }

  .nav__actions {
    gap: 10px;
  }
}

@media (max-width: 900px) {
  .nav {
    padding: 0 16px;
  }

  .nav__links,
  .nav__actions {
    display: none;
  }

  .menu {
    display: grid;
    place-items: center;
  }

  .main {
    padding-top: 80px;
  }

  .download-grid {
    grid-template-columns: 1fr;
  }

  .download-section {
    max-width: 36rem;
  }

  .tutorial-layout {
    grid-template-columns: 1fr;
  }

  .tutorial-toc {
    position: static;
  }

  .changelog-section {
    max-width: 42rem;
  }

  .footer__grid {
    max-width: 42rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .main {
    padding: 80px 16px 64px;
  }

  .download-section {
    padding-left: 0;
    padding-right: 0;
  }

  .download-section h1 {
    margin-bottom: 32px;
    font-size: 32px;
  }

  .download-card__top,
  .requirements {
    padding: 24px;
  }

  .tutorial-section {
    padding-left: 0;
    padding-right: 0;
  }

  .tutorial-hero h1 {
    font-size: 32px;
  }

  .tutorial-lead {
    font-size: 16px;
  }

  .tutorial-card {
    padding: 24px;
  }

  .tutorial-card h2 {
    font-size: 20px;
  }

  .changelog-section {
    padding-left: 0;
    padding-right: 0;
  }

  .changelog-hero h1 {
    font-size: 28px;
  }

  .changelog-years {
    padding: 12px 14px;
  }

  .changelog-body {
    padding: 20px 18px 24px;
  }

  .changelog-entry__version {
    font-size: 16px;
  }

  .footer__grid {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }
}
