﻿:root {
  --bg-top: #06203d;
  --bg-mid: #083053;
  --bg-bottom: #0a3d66;
  --line: rgba(173, 221, 255, 0.18);
  --text: #eef7ff;
  --muted: #adc9de;
  --gold: #e8c46f;
  --sky: #8bd8ff;
  --sky-strong: #d9f4ff;
  --radius-lg: 26px;
  --radius-md: 18px;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--bg-bottom);
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.016) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent 90%);
  opacity: 0.18;
}

a {
  color: inherit;
}

p,
h1,
h2,
h3 {
  margin: 0;
}

button,
input,
textarea {
  font: inherit;
}

.page {
  position: relative;
  min-height: 100vh;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: min(31vh, 260px);
  padding: 0 0 3.1rem;
}

.hero-media,
.hero-glow,
.hero-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-media {
  background:
    linear-gradient(180deg, rgba(6, 32, 61, 0.02) 0%, rgba(6, 32, 61, 0.08) 24%, rgba(10, 61, 102, 0.54) 56%, rgba(10, 61, 102, 0.9) 78%, rgba(10, 61, 102, 1) 100%),
    url("./morphose_img.jpg") center -300px / cover no-repeat;
  opacity: 0.2;
  transform: scale(1.1);
}

.hero-glow {
  background:
    radial-gradient(circle at 50% -8%, rgba(255, 255, 255, 0.12), transparent 30%),
    linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(9, 45, 76, 0.14) 38%, rgba(10, 61, 102, 0.9) 82%, rgba(10, 61, 102, 1) 100%);
}

.hero-vignette {
  background:
    linear-gradient(90deg, rgba(4, 16, 32, 0.36), transparent 24%, transparent 76%, rgba(4, 16, 32, 0.34)),
    linear-gradient(180deg, rgba(4, 16, 32, 0.2), transparent 26%, transparent 74%, rgba(4, 16, 32, 0.4));
}

.hero-inner,
.shell {
  width: min(calc(100% - 2rem), var(--max));
  margin: 0 auto;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding-top: 0.35rem;
}

.hero-copy {
  display: grid;
  justify-items: center;
  gap: 0.55rem;
  text-align: center;
  padding-top: 0;
}

.hero-logo {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  justify-content: center;
  width: 100%;
  max-width: 100%;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.3rem, 5.8vw, 3.8rem);
  line-height: 0.92;
  letter-spacing: 0.035em;
  text-transform: uppercase;
  color: transparent;
  background: linear-gradient(180deg, #fff4c9 0%, #f0d887 38%, #c99845 72%, #8d6325 100%);
  -webkit-background-clip: text;
  background-clip: text;
  font-weight: 700;
  text-align: center;
  text-shadow:
    0 1px 0 rgba(255, 252, 230, 0.9),
    0 2px 0 rgba(211, 176, 91, 0.92),
    0 3px 0 rgba(147, 104, 36, 0.92),
    0 4px 0 rgba(110, 73, 20, 0.96),
    1px 1px 0 rgba(0, 0, 0, 0.22),
    0 4px 8px rgba(0, 0, 0, 0.12);
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.14));
}

.hero-logo-word,
.hero-logo-tail {
  position: relative;
  display: inline-block;
}

.hero-logo-tail {
  margin-left: 0.12em;
  font-size: 0.42em;
  vertical-align: 0.24em;
  letter-spacing: 0.02em;
}

.hero-logo-tail::before,
.hero-logo-word::before {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  color: transparent;
  background: linear-gradient(105deg, transparent 0%, transparent 42%, rgba(255, 255, 255, 0.08) 48%, rgba(255, 255, 255, 0.98) 50%, rgba(255, 255, 255, 0.1) 52%, transparent 58%, transparent 100%);
  background-size: 240% 100%;
  background-position: 140% 0;
  -webkit-background-clip: text;
  background-clip: text;
  opacity: 0;
  pointer-events: none;
  animation: logoOverlayIn 40ms linear 1.1s forwards, logoShine 3.8s linear 1.15s infinite;
}

.hero-logo-tail::after,
.hero-logo-word::after {
  content: attr(data-text);
  position: absolute;
  inset: 0;
  color: transparent;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.3),
    0 -1px 0 rgba(92, 60, 16, 0.42),
    0 2px 0 rgba(0, 0, 0, 0.16);
  opacity: 0;
  pointer-events: none;
  animation: logoOverlayIn 40ms linear 1.03s forwards;
}

.hero-letter {
  display: inline-block;
  color: transparent;
  background: linear-gradient(180deg, #fff4c9 0%, #f0d887 38%, #c99845 72%, #8d6325 100%);
  -webkit-background-clip: text;
  background-clip: text;
  opacity: 0;
  transform: translateY(18px) scale(0.975);
  filter: blur(4px);
  text-shadow: 0 0 0 rgba(255, 255, 255, 0), 0 0 0 rgba(255, 255, 255, 0);
  animation: heroLetterIn 980ms cubic-bezier(0.2, 0.9, 0.18, 1) forwards;
  animation-delay: calc(0.08s + (var(--i) * 0.09s));
}

.panel-top {
  display: grid;
  gap: 0.58rem;
  justify-items: center;
  width: min(100%, 430px);
}

.progress-chip {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.progress-chip strong {
  display: inline;
}

.progress-chip span {
  display: inline;
}

.progress-bar {
  position: relative;
  width: 100%;
  height: 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 240, 195, 0.18);
  background: rgba(5, 18, 34, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.progress-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, #fff4c9 0%, #f0d887 38%, #c99845 72%, #8d6325 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.34), 0 6px 18px rgba(201, 152, 69, 0.22);
  transition: width 220ms ease;
}

.shell {
  position: relative;
  z-index: 2;
  width: min(calc(100% - 2rem), 840px);
  margin-top: -5.8rem;
  padding-bottom: 3.6rem;
}

.question-flow {
  display: grid;
  justify-items: center;
}

.question-card {
  position: relative;
  display: grid;
  gap: 0.85rem;
  width: min(100%, 760px);
  min-height: 460px;
  padding: 0;
  background: none;
  border: 0;
}

.question-card.is-forward {
  animation: swapForward 260ms cubic-bezier(0.2, 0.9, 0.2, 1);
}

.question-card.is-back {
  animation: swapBack 260ms cubic-bezier(0.2, 0.9, 0.2, 1);
}

.question-meta {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 0.45rem;
  text-align: center;
}

.question-icon {
  display: grid;
  place-items: center;
  width: clamp(120px, 18vw, 160px);
  aspect-ratio: 1;
  margin-bottom: -0.08rem;
  filter: drop-shadow(0 16px 32px rgba(0, 0, 0, 0.22));
}

.question-icon-image {
  width: 100%;
  height: 100%;
  display: block;
}

.question-text {
  max-width: 24ch;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.14rem, 2vw, 1.55rem);
  line-height: 1.08;
  color: #ffffff;
  text-wrap: balance;
}

.question-help,
.limit-note {
  display: none;
}

.answer-region {
  display: grid;
  gap: 0.95rem;
  width: min(100%, 680px);
  margin: 0.1rem auto 0;
}

.field-input,
.field-textarea,
.field-url {
  width: 100%;
  padding: 0.92rem 1.02rem;
  border-radius: 18px;
  border: 1px solid rgba(173, 221, 255, 0.16);
  background: linear-gradient(180deg, rgba(5, 20, 38, 0.76), rgba(8, 31, 57, 0.94));
  color: var(--text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.field-input:focus,
.field-textarea:focus,
.field-url:focus {
  outline: none;
  border-color: rgba(139, 216, 255, 0.42);
  box-shadow: 0 0 0 3px rgba(139, 216, 255, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transform: translateY(-1px);
}

.field-input::placeholder,
.field-textarea::placeholder,
.field-url::placeholder {
  color: rgba(173, 201, 222, 0.58);
}

.field-textarea {
  min-height: 3.35rem;
  resize: vertical;
  line-height: 1.45;
}

.option-grid {
  display: grid;
  gap: 0.82rem;
}

.option-button {
  width: 100%;
  padding: 0.98rem 1.08rem 0.98rem 1.18rem;
  border: 1px solid rgba(173, 221, 255, 0.16);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(8, 31, 57, 0.84), rgba(8, 28, 50, 0.96));
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.option-button:hover {
  transform: translateY(-1px);
  border-color: rgba(139, 216, 255, 0.28);
  background: linear-gradient(180deg, rgba(10, 37, 67, 0.92), rgba(8, 31, 57, 0.98));
}

.option-button.is-selected {
  border-color: rgba(232, 196, 111, 0.42);
  background: linear-gradient(180deg, rgba(18, 54, 90, 0.96), rgba(10, 43, 76, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 0 0 2px rgba(232, 196, 111, 0.08);
}

.option-label {
  display: inline-flex;
  align-items: center;
  gap: 0.62rem;
  font-size: 1rem;
  line-height: 1.4;
}

.option-label::before {
  content: "›";
  flex: 0 0 auto;
  font-size: 1.22rem;
  line-height: 1;
  color: #d7ebfb;
  transform: translateY(-1px);
}

.file-shell {
  display: grid;
  gap: 0.95rem;
  width: min(100%, 680px);
  margin: 0 auto;
}

.file-drop {
  position: relative;
  display: grid;
  justify-items: center;
  padding: 1.1rem 1rem;
  border-radius: 22px;
  border: 1px dashed rgba(139, 216, 255, 0.26);
  background: linear-gradient(180deg, rgba(11, 38, 67, 0.82), rgba(6, 25, 46, 0.88));
  text-align: center;
}

.file-drop strong {
  color: #ffffff;
  font-size: 1.02rem;
}

.file-drop span,
.draft-warning {
  display: none;
}

.file-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.file-status,
.inline-feedback {
  padding: 0.82rem 0.95rem;
  border-radius: 16px;
  border: 1px solid rgba(139, 216, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  line-height: 1.45;
}

.inline-feedback.is-error {
  border-color: rgba(232, 196, 111, 0.22);
  color: #ffdca6;
}

.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.9rem;
  margin-top: auto;
}

.nav-actions,
.summary-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  justify-content: center;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.92rem 1.38rem;
  border-radius: 999px;
  border: 1px solid rgba(173, 221, 255, 0.16);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.button:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: rgba(139, 216, 255, 0.28);
  background: rgba(255, 255, 255, 0.07);
}

.button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.button-primary {
  border-color: rgba(255, 232, 163, 0.46);
  background: linear-gradient(180deg, rgba(255, 247, 214, 0.82) 0%, rgba(238, 204, 116, 0.9) 34%, rgba(190, 137, 48, 0.96) 100%);
  color: #fff9eb;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.42), inset 0 -1px 0 rgba(110, 73, 20, 0.26), 0 14px 30px rgba(0, 0, 0, 0.26);
  text-shadow: 0 1px 0 rgba(122, 84, 24, 0.72), 0 2px 8px rgba(0, 0, 0, 0.18);
}

.button-primary:hover:not(:disabled) {
  background: linear-gradient(180deg, rgba(248, 232, 178, 0.84) 0%, rgba(216, 174, 81, 0.92) 34%, rgba(166, 113, 33, 0.98) 100%);
}

.button-secondary {
  color: var(--sky-strong);
}

.button-ghost {
  background: transparent;
  color: var(--muted);
}

.summary-view {
  display: grid;
  gap: 1rem;
  width: min(100%, 720px);
  margin: 0 auto;
}

.summary-top {
  display: grid;
  gap: 0.75rem;
  justify-items: center;
  text-align: center;
}

.summary-top h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.55rem, 2.8vw, 2.1rem);
  line-height: 1.08;
}

.summary-top p {
  color: var(--muted);
  line-height: 1.45;
}

.answer-list {
  display: grid;
  gap: 0.8rem;
}

.answer-item {
  padding: 0.95rem 1rem;
  border-radius: 18px;
  border: 1px solid rgba(173, 221, 255, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.answer-item strong {
  display: block;
  margin-bottom: 0.28rem;
  color: #ffffff;
}

.answer-item span {
  display: block;
  color: var(--muted);
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}

.answer-item button {
  margin-top: 0.72rem;
  border: 0;
  background: none;
  color: var(--sky);
  cursor: pointer;
  padding: 0;
  font-size: 0.92rem;
}

.loading,
.fatal {
  display: grid;
  gap: 0.9rem;
  place-items: center;
  min-height: 360px;
  text-align: center;
  color: var(--muted);
}

.loading-spinner {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 3px solid rgba(139, 216, 255, 0.18);
  border-top-color: rgba(232, 196, 111, 0.88);
  animation: spin 900ms linear infinite;
}

.submit-status {
  padding: 0.9rem 1rem;
  border-radius: 18px;
  border: 1px solid rgba(173, 221, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  line-height: 1.5;
}

.submit-status.is-success {
  border-color: rgba(139, 216, 255, 0.22);
  color: #dcf4ff;
}

.submit-status.is-error {
  border-color: rgba(232, 196, 111, 0.22);
  color: #ffe1ac;
}

@keyframes heroLetterIn {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.975);
    filter: blur(4px);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes logoOverlayIn {
  to {
    opacity: 1;
  }
}

@keyframes logoShine {
  to {
    background-position: -140% 0;
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes swapForward {
  0% {
    opacity: 0;
    transform: translate3d(28px, 0, 0);
  }

  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes swapBack {
  0% {
    opacity: 0;
    transform: translate3d(-28px, 0, 0);
  }

  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@media (max-width: 720px) {
  .hero {
    min-height: 28vh;
    padding-bottom: 2.6rem;
  }

  .hero-media {
    background-position: center -110px;
  }

  .shell {
    margin-top: -3.9rem;
  }

  .question-card {
    min-height: 0;
  }

  .nav-bar {
    flex-direction: column;
    align-items: stretch;
  }

  .summary-actions,
  .nav-actions,
  .button {
    width: 100%;
  }
}
