html[data-theme="dark"] {
  color-scheme: dark;
  --ink: #e8edf1;
  --muted: #a4b0ba;
  --line: #35414b;
  --soft: #202a33;
  --paper: #171f26;
  --accent: #8ab9ef;
  --accent-dark: #a5cafa;
  --success: #7ac49a;
}

html[data-theme="light"] {
  color-scheme: light;
}

html[data-theme="light"] body.homepage {
  background: #fff;
}

body.homepage .shell {
  width: min(1320px, calc(100% - 40px));
}

body.homepage .hero {
  min-height: 520px;
}

body.homepage .catalog-section,
body.homepage .info-section,
body.homepage .contacts-section {
  padding-block: 60px;
}

html[data-theme="light"] body.homepage .catalog-section {
  position: relative;
  isolation: isolate;
}

@media (max-width: 560px) {
  body.homepage .shell {
    width: min(1320px, calc(100% - 28px));
  }

  body.homepage .hero {
    min-height: auto;
  }
}

.hero h1 .hero-title-outline {
  color: transparent;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 1.5px #17202a;
}

html[data-theme="dark"] .hero h1 .hero-title-outline {
  -webkit-text-stroke-color: var(--ink);
}

.detail-copy .description {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 10;
}

.detail-copy .description.expanded {
  display: block;
  -webkit-line-clamp: unset;
}

.description-toggle {
  margin: 0 0 18px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent);
  font:
    600 13px Inter,
    sans-serif;
  cursor: pointer;
}

.description-toggle[hidden] {
  display: none;
}

html[data-theme="dark"] body,
html[data-theme="dark"] .site-header {
  background: #171f26;
}

html[data-theme="dark"] .brand-mark,
html[data-theme="dark"] .primary {
  background: #e8edf1;
  color: #171f26;
}

html[data-theme="dark"] .header-inner nav a,
html[data-theme="dark"] .hero h1 span,
html[data-theme="dark"] .panel-label,
html[data-theme="dark"] .hero-panel p,
html[data-theme="dark"] .cover-label,
html[data-theme="dark"] .site-footer,
html[data-theme="dark"] .back-link {
  color: var(--muted);
}

html[data-theme="dark"] .hero-panel,
html[data-theme="dark"] .order-card,
html[data-theme="dark"] .success-card,
html[data-theme="dark"] .product-card,
html[data-theme="dark"] .filter,
html[data-theme="dark"] .account-panel {
  background: var(--paper);
}

html[data-theme="dark"] .product-cover,
html[data-theme="dark"] .detail-cover {
  background: #222e38;
}

html[data-theme="dark"] .filter {
  color: var(--muted);
}

html[data-theme="dark"] .filter.active,
html[data-theme="dark"] .filter:hover {
  border-color: var(--ink);
  color: var(--ink);
}

html[data-theme="dark"] .steps,
html[data-theme="dark"] .steps > div {
  border-color: var(--line);
}

html[data-theme="dark"] .notice {
  background: #202d38;
  color: #c2ccd4;
}

html[data-theme="dark"] .success-icon {
  background: #20382c;
}

html[data-theme="dark"] .download-box {
  border-color: #385644;
  background: #1b2b22;
}

html[data-theme="dark"] .account-form input,
html[data-theme="dark"] .admin-editor input,
html[data-theme="dark"] .admin-editor textarea,
html[data-theme="dark"] .admin-upload input[type="file"],
html[data-theme="dark"] .account-logout,
html[data-theme="dark"] .admin-secondary,
html[data-theme="dark"] .admin-actions button,
html[data-theme="dark"] .admin-actions a {
  border-color: #46535e;
  background: #202a33;
  color: var(--ink);
}

.theme-toggle {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid #cbd1d6;
  border-radius: 6px;
  background: transparent;
  color: var(--ink);
  font:
    600 12px Inter,
    sans-serif;
  cursor: pointer;
}

.theme-toggle:hover {
  border-color: var(--ink);
}

.theme-icon {
  width: 14px;
  height: 14px;
  border: 2px solid currentColor;
  border-radius: 50%;
  box-shadow: inset -4px -2px 0 -2px currentColor;
}

@media (max-width: 850px) {
  .theme-toggle {
    margin-left: auto;
  }
}

@media (max-width: 560px) {
  .theme-toggle {
    margin-left: 0;
    padding: 8px;
  }

  .theme-toggle > span:last-child {
    display: none;
  }
}

html[data-theme="light"] body.homepage .catalog-section > .bg800 {
  position: absolute;
  z-index: 0;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  background: url("../images/bg800.jpg") top center / 100% auto repeat-y;
  filter: blur(3px) brightness(0.92);
  pointer-events: none;
}

.homepage .catalog-section > :not(.bg800) {
  position: relative;
  z-index: 1;
}
