:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  background: #040713;
  color: #f8f3eb;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 50% -6%, rgba(112, 83, 169, 0.32), transparent 32rem),
    radial-gradient(circle at 12% 68%, rgba(43, 115, 144, 0.2), transparent 28rem),
    radial-gradient(circle at 86% 78%, rgba(174, 91, 92, 0.16), transparent 30rem),
    linear-gradient(180deg, #080b1d 0%, #040713 54%, #08101f 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
  opacity: 0.34;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.78) 0 1px, transparent 1.3px),
    radial-gradient(circle, rgba(187, 204, 255, 0.66) 0 0.8px, transparent 1.2px);
  background-position: 0 0, 3.2rem 2rem;
  background-size: 7rem 7rem, 9rem 9rem;
}

a {
  color: inherit;
}

.reflection-header {
  position: relative;
  z-index: 5;
  display: flex;
  width: min(72rem, calc(100% - 2rem));
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 0 auto;
  padding: max(1.1rem, env(safe-area-inset-top)) 0 1rem;
}

.reflection-brand {
  color: rgba(255, 248, 238, 0.94);
  font-size: 0.76rem;
  font-weight: 760;
  letter-spacing: 0.14em;
  text-decoration: none;
  text-transform: uppercase;
}

.reflection-nav {
  display: flex;
  align-items: center;
  gap: 0.48rem;
}

.reflection-nav > a,
.reflection-language {
  border: 1px solid rgba(232, 233, 245, 0.14);
  border-radius: 999px;
  background: rgba(5, 10, 25, 0.62);
  backdrop-filter: blur(14px);
}

.reflection-nav > a {
  min-height: 2.2rem;
  display: inline-flex;
  align-items: center;
  padding: 0.52rem 0.72rem;
  color: rgba(239, 238, 244, 0.68);
  font-size: 0.67rem;
  font-weight: 690;
  text-decoration: none;
}

.reflection-language {
  display: inline-flex;
  align-items: center;
  gap: 0.34rem;
  padding: 0.4rem 0.54rem;
}

.reflection-language button {
  appearance: none;
  padding: 0.2rem;
  border: 0;
  background: transparent;
  color: rgba(232, 233, 241, 0.48);
  cursor: pointer;
  font: inherit;
  font-size: 0.65rem;
  font-weight: 720;
}

.reflection-language button[aria-pressed="true"] {
  color: #fff8ed;
}

.reflection-main {
  position: relative;
  z-index: 1;
  width: min(68rem, calc(100% - 2rem));
  margin: 0 auto;
  padding: clamp(2.5rem, 8vw, 6.8rem) 0 6rem;
}

[data-locale-panel][hidden] {
  display: none !important;
}

.reflection-hero {
  max-width: 48rem;
  margin-bottom: clamp(2.2rem, 6vw, 4.4rem);
}

.reflection-eyebrow {
  margin: 0 0 0.85rem;
  color: rgba(244, 190, 144, 0.78);
  font-size: 0.7rem;
  font-weight: 780;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.reflection-hero h1 {
  max-width: 15ch;
  margin: 0;
  color: #fff9ef;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.45rem, 8vw, 5.7rem);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.98;
  text-wrap: balance;
}

.reflection-hero p:not(.reflection-eyebrow) {
  max-width: 42rem;
  margin: 1.25rem 0 0;
  color: rgba(229, 230, 239, 0.68);
  font-size: clamp(0.94rem, 2.4vw, 1.08rem);
  line-height: 1.75;
}

.reflection-disclaimer {
  display: inline-flex;
  margin-top: 1.1rem;
  padding: 0.55rem 0.72rem;
  border: 1px solid rgba(185, 208, 229, 0.15);
  border-radius: 999px;
  background: rgba(33, 75, 104, 0.14);
  color: rgba(211, 229, 241, 0.72);
  font-size: 0.68rem;
  font-weight: 650;
  line-height: 1.4;
}

.test-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 19rem), 1fr));
  gap: 1rem;
}

.test-card,
.test-intro-card,
.test-question,
.test-result-card {
  border: 1px solid rgba(239, 229, 214, 0.15);
  background:
    linear-gradient(145deg, rgba(25, 31, 55, 0.91), rgba(8, 14, 29, 0.92)),
    rgba(8, 14, 29, 0.9);
  box-shadow:
    0 1.7rem 5rem rgba(0, 0, 0, 0.34),
    inset 0 1px 0 rgba(255, 255, 255, 0.035);
  backdrop-filter: blur(18px);
}

.test-card {
  display: grid;
  min-height: 20rem;
  align-content: space-between;
  gap: 1.5rem;
  padding: 1.35rem;
  border-radius: 1.5rem;
}

.test-card-badge {
  width: fit-content;
  margin: 0 0 0.9rem;
  padding: 0.34rem 0.55rem;
  border: 1px solid rgba(244, 190, 144, 0.22);
  border-radius: 999px;
  color: rgba(250, 207, 169, 0.84);
  font-size: 0.64rem;
  font-weight: 760;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.test-card h2 {
  max-width: 16ch;
  margin: 0;
  color: #fff8ed;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.65rem, 4vw, 2.4rem);
  font-weight: 500;
  line-height: 1.12;
}

.test-card p {
  margin: 0.8rem 0 0;
  color: rgba(226, 228, 238, 0.62);
  font-size: 0.86rem;
  line-height: 1.65;
}

.test-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
  color: rgba(217, 218, 228, 0.48);
  font-size: 0.68rem;
}

.reflection-button,
.test-card-link {
  min-height: 3rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.78rem 1rem;
  border: 1px solid rgba(242, 201, 160, 0.28);
  border-radius: 0.95rem;
  background: linear-gradient(145deg, rgba(150, 93, 52, 0.82), rgba(89, 54, 37, 0.84));
  color: #fff7ec;
  cursor: pointer;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 740;
  text-align: center;
  text-decoration: none;
  box-shadow: 0 0.9rem 2.8rem rgba(190, 111, 58, 0.14);
}

.reflection-button.is-secondary {
  border-color: rgba(231, 232, 242, 0.16);
  background: rgba(255, 255, 255, 0.045);
  color: rgba(244, 242, 237, 0.78);
  box-shadow: none;
}

.reflection-button:hover,
.reflection-button:focus-visible,
.test-card-link:hover,
.test-card-link:focus-visible,
.reflection-nav a:hover,
.reflection-nav a:focus-visible,
.reflection-language button:focus-visible {
  transform: translateY(-1px);
  outline: 2px solid rgba(255, 240, 222, 0.28);
  outline-offset: 2px;
}

.test-intro-card {
  display: grid;
  gap: 1.2rem;
  margin-bottom: 1.25rem;
  padding: clamp(1.25rem, 4vw, 2rem);
  border-radius: 1.5rem;
}

.test-intro-card h2 {
  margin: 0;
  color: #fff8ee;
  font-size: 1.15rem;
}

.test-intro-card p {
  margin: 0;
  color: rgba(226, 228, 237, 0.65);
  font-size: 0.84rem;
  line-height: 1.7;
}

.test-form {
  display: grid;
  gap: 0.9rem;
}

.test-question {
  margin: 0;
  padding: clamp(1.05rem, 3vw, 1.45rem);
  border-radius: 1.25rem;
}

.test-question legend {
  width: 100%;
  margin-bottom: 0.85rem;
  padding: 0;
  color: #fff8ef;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.05rem, 3vw, 1.3rem);
  line-height: 1.4;
}

.test-options {
  display: grid;
  gap: 0.55rem;
}

.test-option {
  position: relative;
  display: flex;
  min-height: 3.15rem;
  align-items: center;
  padding: 0.72rem 0.82rem 0.72rem 2.7rem;
  border: 1px solid rgba(231, 232, 241, 0.11);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.028);
  color: rgba(239, 238, 235, 0.76);
  cursor: pointer;
  font-size: 0.82rem;
  line-height: 1.5;
  transition: border-color 140ms ease, background 140ms ease, transform 140ms ease;
}

.test-option::before {
  position: absolute;
  left: 0.9rem;
  width: 0.92rem;
  height: 0.92rem;
  border: 1px solid rgba(236, 229, 219, 0.3);
  border-radius: 50%;
  content: "";
}

.test-option:has(input:checked) {
  border-color: rgba(244, 190, 144, 0.42);
  background: rgba(144, 86, 49, 0.18);
  color: #fff8ed;
}

.test-option:has(input:checked)::before {
  border: 0.27rem solid rgba(255, 223, 188, 0.9);
  background: rgba(125, 72, 43, 0.9);
}

.test-option:hover {
  transform: translateY(-1px);
  border-color: rgba(237, 226, 211, 0.26);
}

.test-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.test-submit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem;
  margin-top: 0.65rem;
}

.test-error {
  margin: 0;
  color: rgba(255, 191, 181, 0.9);
  font-size: 0.75rem;
  line-height: 1.5;
}

.test-result {
  scroll-margin-top: 1rem;
}

.test-result[hidden] {
  display: none;
}

.test-result-card {
  position: relative;
  overflow: hidden;
  padding: clamp(1.35rem, 5vw, 2.4rem);
  border-radius: 1.7rem;
}

.test-result-card::after {
  position: absolute;
  right: -4rem;
  bottom: -5rem;
  width: 15rem;
  height: 15rem;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(244, 177, 116, 0.18), transparent 68%);
  content: "";
  pointer-events: none;
}

.test-result-label {
  margin: 0 0 0.65rem;
  color: rgba(244, 190, 144, 0.76);
  font-size: 0.68rem;
  font-weight: 780;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.test-result-card h2 {
  max-width: 16ch;
  margin: 0;
  color: #fff8ee;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 7vw, 4rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1.04;
}

.test-result-summary {
  max-width: 40rem;
  margin: 1.05rem 0 0;
  color: rgba(233, 232, 237, 0.75);
  font-size: clamp(0.94rem, 2.5vw, 1.08rem);
  line-height: 1.75;
}

.test-result-gentle {
  max-width: 38rem;
  margin: 0.85rem 0 0;
  padding-left: 0.85rem;
  border-left: 2px solid rgba(244, 190, 144, 0.28);
  color: rgba(218, 220, 229, 0.6);
  font-size: 0.82rem;
  line-height: 1.7;
}

.test-result-actions {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1.4rem;
}

.test-share-status {
  min-height: 1.3rem;
  margin: 0.75rem 0 0;
  color: rgba(211, 226, 237, 0.7);
  font-size: 0.7rem;
}

.reflection-footer {
  margin-top: 3rem;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(232, 233, 242, 0.1);
  color: rgba(217, 219, 229, 0.48);
  font-size: 0.7rem;
  line-height: 1.65;
}

.reflection-footer a {
  color: rgba(238, 236, 231, 0.7);
}

@media (max-width: 640px) {
  .reflection-header {
    width: min(100% - 1.25rem, 72rem);
    align-items: flex-start;
  }

  .reflection-nav {
    gap: 0.34rem;
  }

  .reflection-nav > a {
    display: none;
  }

  .reflection-main {
    width: min(100% - 1.25rem, 68rem);
    padding-top: 3.2rem;
  }

  .reflection-hero h1 {
    font-size: clamp(2.35rem, 13vw, 4rem);
  }

  .test-card {
    min-height: 17rem;
  }

  .test-submit-row,
  .test-result-actions {
    display: grid;
  }

  .reflection-button,
  .test-card-link {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .test-option,
  .reflection-button,
  .test-card-link {
    transition: none;
  }
}
