:root {
  color-scheme: light;
  --ink: #252525;
  --muted: #6d6963;
  --paper: #f6f1ea;
  --surface: #ffffff;
  --soft: #eee5d9;
  --line: #ded4c5;
  --brand: #347f73;
  --brand-dark: #216257;
  --brand-soft: #d9ebe7;
  --gold: #b99353;
  --wood: #8c5b34;
  --charcoal: #171717;
  font-family:
    Arial, Helvetica, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: var(--paper);
}

button {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: var(--surface);
  box-shadow: 0 1px 0 rgba(37, 37, 37, 0.08);
}

.main-nav {
  width: min(1180px, calc(100% - 32px));
  min-height: 78px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(180px, 250px) minmax(220px, 460px) 1fr;
  gap: 28px;
  align-items: center;
}

.site-logo {
  width: min(250px, 42vw);
  height: auto;
  display: block;
}

.page-title {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 24px;
  color: var(--brand);
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  font-size: clamp(1.15rem, 2.1vw, 1.8rem);
  font-weight: 800;
  text-align: center;
}

.app-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 58px;
}

.intro-panel,
.advisor-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 16px 44px rgba(61, 44, 29, 0.09);
}

.intro-panel {
  min-height: 620px;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(300px, 0.98fr);
  gap: clamp(24px, 5vw, 56px);
  align-items: center;
  padding: clamp(24px, 5vw, 58px);
}

.hero-copy {
  padding-top: 10px;
}

.advisor-panel {
  width: min(900px, 100%);
  margin: 0 auto;
  padding: clamp(20px, 4vw, 36px);
}

.is-hidden {
  display: none;
}

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

h1 {
  max-width: 680px;
  margin-bottom: 20px;
  color: #1e1d1b;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.35rem, 5vw, 5rem);
  font-weight: 700;
  line-height: 1;
}

h2 {
  margin-bottom: 13px;
  color: #1e1d1b;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.6rem, 3vw, 2.55rem);
  line-height: 1.12;
}

h3 {
  margin-bottom: 10px;
  color: var(--brand-dark);
  font-size: 1rem;
}

.intro-panel p,
.question-copy,
.result-copy {
  max-width: 680px;
  color: var(--muted);
  font-size: 1.04rem;
  line-height: 1.65;
}

.intro-actions,
.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin-top: 30px;
}

.micro-proof {
  color: var(--muted);
  font-size: 0.92rem;
}

.primary-action,
.secondary-action,
.ghost-action {
  min-height: 46px;
  border: 1px solid transparent;
  border-radius: 2px;
  cursor: pointer;
  font-weight: 800;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease,
    background 160ms ease;
}

.primary-action {
  padding: 0 24px;
  color: #fff;
  background: var(--brand);
  box-shadow: 0 12px 22px rgba(52, 127, 115, 0.22);
}

.secondary-action {
  padding: 0 18px;
  color: var(--brand-dark);
  background: #fff;
  border-color: var(--brand-soft);
}

.ghost-action {
  min-width: 76px;
  padding: 0 12px;
  color: var(--brand-dark);
  background: #fff;
  border-color: var(--line);
}

.primary-action:hover,
.secondary-action:hover,
.ghost-action:hover,
.option-button:hover {
  transform: translateY(-1px);
}

.primary-action:focus-visible,
.secondary-action:focus-visible,
.ghost-action:focus-visible,
.option-button:focus-visible {
  outline: 3px solid rgba(52, 127, 115, 0.22);
  outline-offset: 2px;
}

.material-board {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-self: stretch;
}

.material-tile {
  position: relative;
  min-height: 180px;
  overflow: hidden;
  background: #eee;
  border: 8px solid #fff;
  box-shadow: 0 12px 26px rgba(61, 44, 29, 0.14);
}

.material-tile img {
  width: 100%;
  height: 100%;
  min-height: 180px;
  display: block;
  object-fit: cover;
  transition: transform 220ms ease;
}

.material-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, 0.46));
}

.material-tile span {
  position: absolute;
  left: 16px;
  bottom: 14px;
  z-index: 1;
  padding: 7px 10px;
  color: #fff;
  background: var(--brand);
  border-radius: 4px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.08rem;
  font-weight: 700;
}

.material-tile:hover img {
  transform: scale(1.035);
}

.progress-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 32px;
}

.progress-track {
  height: 7px;
  overflow: hidden;
  background: var(--soft);
  border-radius: 999px;
}

.progress-fill {
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--brand), var(--gold));
  border-radius: inherit;
  transition: width 220ms ease;
}

.progress-text {
  min-width: 66px;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: right;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 26px;
}

.option-button {
  min-height: 92px;
  padding: 18px;
  color: var(--ink);
  text-align: left;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 4px solid transparent;
  border-radius: 2px;
  cursor: pointer;
}

.option-button:hover {
  border-left-color: var(--brand);
  box-shadow: 0 10px 24px rgba(61, 44, 29, 0.09);
}

.option-title {
  display: block;
  margin-bottom: 7px;
  font-weight: 800;
}

.option-note {
  display: block;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.35;
}

.result-layout {
  max-width: 760px;
  margin: 0 auto;
}

.result-badge {
  width: fit-content;
  margin-bottom: 16px;
  padding: 8px 12px;
  color: #fff;
  background: var(--brand);
  border-radius: 2px;
  font-size: 0.84rem;
  font-weight: 800;
}

.recommendation-list,
.answer-summary,
.result-link-grid {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.recommendation-list li,
.answer-summary li {
  padding: 12px 14px;
  background: #fbf7f1;
  border: 1px solid var(--line);
  border-radius: 2px;
}

.answer-summary {
  margin-top: 0;
}

.summary-panel {
  margin-top: 22px;
  padding: 18px;
  background: #fbf7f1;
  border: 1px solid var(--line);
  border-radius: 2px;
}

.secondary-link {
  display: inline-flex;
  margin-top: -6px;
  margin-bottom: 4px;
  color: var(--brand-dark);
  font-weight: 800;
  font-size: 0.92rem;
  text-decoration: none;
}

.secondary-link:hover {
  text-decoration: underline;
}

.material-preference {
  display: inline-flex;
  align-items: center;
  margin-bottom: 14px;
  padding: 8px 14px;
  background: var(--brand-soft);
  border: 1px solid var(--brand);
  border-radius: 4px;
  color: var(--brand-dark);
  font-size: 0.92rem;
}

.result-link-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  margin-top: 24px;
}

.result-link-card {
  min-height: 210px;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: 16px;
  color: #fff;
  text-decoration: none;
  background: #ddd;
  border: 8px solid #fff;
  box-shadow: 0 12px 26px rgba(61, 44, 29, 0.12);
}

.result-link-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease;
}

.result-link-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 25%, rgba(0, 0, 0, 0.62));
}

.result-link-card:hover img {
  transform: scale(1.04);
}

.result-link-content {
  position: relative;
  z-index: 1;
}

.result-link-label {
  display: inline-flex;
  margin-bottom: 8px;
  padding: 6px 9px;
  background: var(--brand);
  border-radius: 4px;
  font-weight: 800;
}

.result-link-title {
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
  font-weight: 700;
}

.mail-icon {
  margin-right: 8px;
  font-size: 1.05rem;
  line-height: 1;
}

@media (max-width: 840px) {
  .main-nav {
    min-height: 68px;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px 0;
  }

  .page-title {
    font-size: 1rem;
    justify-content: flex-start;
    width: fit-content;
  }

  .intro-panel {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .material-board {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .app-shell {
    width: min(100% - 20px, 1180px);
    padding-top: 18px;
  }

  .intro-panel,
  .advisor-panel {
    padding: 22px;
  }

  .progress-row {
    grid-template-columns: 1fr auto;
  }

  .progress-track {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .option-grid,
  .result-link-grid {
    grid-template-columns: 1fr;
  }

  .material-tile {
    min-height: 120px;
  }

  .material-tile img {
    min-height: 120px;
  }
}
