html,
body,
.card,
.sidebar,
.mobile-nav,
input,
select,
textarea,
button {
  transition: background-color .22s ease, border-color .22s ease, color .22s ease;
}

.card {
  background: color-mix(in srgb, var(--paper) 94%, transparent);
  border-color: var(--line);
}

.sidebar,
.mobile-nav {
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-color: var(--line);
}

input,
select,
textarea,
.quick,
.chip,
.day {
  background: var(--paper);
  border-color: var(--line);
  color: var(--ink);
}

.score-card {
  background: linear-gradient(135deg, var(--soft), color-mix(in srgb, var(--soft) 38%, var(--paper)));
}

.score-ring::after {
  background: color-mix(in srgb, var(--soft) 62%, var(--paper));
}

.coach-tease {
  background: var(--ink);
  color: var(--paper);
}

.coach-tease p {
  color: color-mix(in srgb, var(--paper) 72%, var(--muted));
}

.appearance-card {
  width: min(760px, 100%);
  margin-inline: auto;
  padding: clamp(22px, 4vw, 34px);
}

.appearance-card > h2 {
  margin: 12px 0 24px;
  font-size: clamp(31px, 4vw, 42px);
  line-height: 1.08;
}

.appearance-card .theme-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.theme {
  display: grid;
  gap: 18px;
  width: 100%;
  min-height: 126px;
  height: auto;
  padding: 20px;
  text-align: left;
  border: 1px solid color-mix(in srgb, var(--line) 85%, #b9afa9);
  border-radius: 24px;
  background: var(--paper);
  color: var(--ink);
  box-shadow: 0 4px 18px rgba(63, 48, 42, .025);
}

.theme:hover {
  border-color: color-mix(in srgb, var(--accent) 64%, var(--line));
  transform: translateY(-1px);
}

.theme:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 46%, transparent);
  outline-offset: 3px;
}

.theme.active {
  border: 2px solid var(--accent);
  padding: 19px;
  box-shadow: 0 7px 26px color-mix(in srgb, var(--accent) 16%, transparent);
}

.theme-heading {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.theme-icon {
  display: grid;
  flex: 0 0 54px;
  width: 54px;
  height: 54px;
  place-items: center;
  border-radius: 50%;
  background: color-mix(in srgb, var(--soft) 48%, var(--paper));
  font-size: 25px;
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--line) 62%, transparent);
}

.theme-copy {
  display: grid;
  min-width: 0;
}

.theme-copy strong {
  font-size: 21px;
  line-height: 1.2;
  letter-spacing: -.02em;
}

.theme-copy small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.25;
}

.theme-selected {
  display: grid;
  width: 26px;
  height: 26px;
  margin-left: auto;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  color: var(--paper);
  opacity: 0;
  transform: scale(.7);
}

.theme.active .theme-selected {
  opacity: 1;
  transform: scale(1);
}

.theme-swatches {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.theme-swatches i {
  display: block;
  height: 18px;
  border: 1px solid rgba(95, 78, 70, .12);
  border-radius: 999px;
  background: var(--theme-color);
}

html[data-theme="midnight"] .avatar,
html[data-theme="midnight"] .primary,
html[data-theme="midnight"] .chip.active,
html[data-theme="midnight"] .day.selected,
html[data-theme="midnight"] .bubble.user {
  background: var(--accent);
  color: #1d1b1a;
}

html[data-theme="midnight"] .theme {
  box-shadow: none;
}

@media (max-width: 900px) {
  .mobile-nav .nav-button.active {
    background: var(--soft);
    color: var(--ink);
  }
}

@media (max-width: 580px) {
  .appearance-card {
    padding: 24px 18px;
    border-radius: 18px;
  }

  .appearance-card > h2 {
    margin-bottom: 20px;
    font-size: 34px;
  }

  .appearance-card .theme-grid {
    gap: 14px;
  }

  .theme {
    min-height: 120px;
    padding: 18px;
    border-radius: 21px;
  }

  .theme.active {
    padding: 17px;
  }

  .theme-copy strong {
    font-size: 20px;
  }

  .theme-copy small {
    font-size: 14px;
  }
}
