:root {
  --ink: #172331;
  --ink-soft: #667085;
  --navy: #1f3a5b;
  --navy-2: #2f587f;
  --cream: #f7f0e8;
  --cream-2: #efe4d6;
  --white: #ffffff;
  --gold: #c98a45;
  --gold-soft: rgba(201, 138, 69, .14);
  --line: rgba(31, 58, 91, .13);
  --danger: #b42318;
  --success: #157347;
  --shadow: 0 22px 70px rgba(23, 35, 49, .12);
  --radius: 28px;
  --radius-sm: 18px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 8% 2%, rgba(201,138,69,.22), transparent 28%),
    radial-gradient(circle at 98% 0%, rgba(47,88,127,.18), transparent 30%),
    linear-gradient(135deg, var(--cream), var(--cream-2));
}

a {
  color: inherit;
  text-decoration: none;
}

.topbar {
  display: none;
}

.brief-page {
  padding: 22px;
}

.brief-shell {
  width: min(1380px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 340px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.brief-sidebar {
  position: sticky;
  top: 22px;
  min-height: calc(100vh - 44px);
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 34px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.9), rgba(255,255,255,.66));
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.brief-logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  margin-bottom: 42px;
  font-weight: 900;
  color: var(--navy);
}

.brief-logo span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: linear-gradient(135deg, var(--navy), var(--navy-2));
  color: white;
  box-shadow: 0 12px 28px rgba(31,58,91,.24);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.brief-sidebar-intro h1 {
  margin: 0;
  max-width: 260px;
  font-size: 38px;
  line-height: .95;
  letter-spacing: -.055em;
  color: var(--ink);
}

.brief-sidebar-intro p {
  margin: 16px 0 24px;
  color: var(--ink-soft);
  line-height: 1.62;
}

.brief-progress-card {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  margin-bottom: 22px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(31,58,91,.055);
}

.brief-progress-card span {
  color: var(--ink-soft);
  font-weight: 700;
}

.brief-progress-card strong {
  color: var(--navy);
}

.brief-steps {
  display: grid;
  gap: 8px;
}

.brief-steps a {
  display: grid;
  grid-template-columns: 38px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 18px;
  color: var(--ink-soft);
}

.brief-steps a:hover,
.brief-steps a.active {
  background: rgba(31,58,91,.075);
  color: var(--navy);
}

.brief-steps span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: white;
  color: var(--navy);
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(23,35,49,.06);
}

.brief-steps strong {
  font-size: 14px;
}

.brief-main {
  min-width: 0;
  display: grid;
  gap: 18px;
}

.brief-hero {
  padding: clamp(30px, 5vw, 56px);
  border-radius: 38px;
  background:
    radial-gradient(circle at 92% 18%, rgba(201,138,69,.28), transparent 32%),
    linear-gradient(135deg, #1f3a5b, #2f587f);
  color: white;
  box-shadow: var(--shadow);
}

.brief-hero .eyebrow {
  color: rgba(255,255,255,.72);
}

.brief-hero h2 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(42px, 6vw, 82px);
  line-height: .91;
  letter-spacing: -.07em;
}

.brief-hero p {
  max-width: 760px;
  margin: 22px 0 0;
  color: rgba(255,255,255,.78);
  font-size: 18px;
  line-height: 1.65;
}

.brief-alert {
  padding: 17px 19px;
  border: 1px solid rgba(21,115,71,.2);
  border-radius: 20px;
  background: rgba(21,115,71,.09);
  color: var(--success);
  font-weight: 850;
}

.brief-form {
  display: grid;
  gap: 18px;
}

.brief-section {
  border: 1px solid var(--line);
  border-radius: 34px;
  background: rgba(255,255,255,.74);
  box-shadow: 0 18px 55px rgba(23,35,49,.08);
  overflow: hidden;
}

.brief-section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  padding: 30px 34px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,.92), rgba(255,255,255,.58));
}

.brief-section-head h3 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(28px, 3.4vw, 44px);
  line-height: 1;
  letter-spacing: -.055em;
}

.brief-section-head p {
  max-width: 760px;
  margin: 12px 0 0;
  color: var(--ink-soft);
  line-height: 1.6;
}

.brief-section-pill {
  flex: 0 0 auto;
  padding: 9px 13px;
  border-radius: 999px;
  background: var(--gold-soft);
  color: #8c5724;
  font-size: 13px;
  font-weight: 900;
}

.brief-question-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.brief-question-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.brief-question {
  position: relative;
  display: grid;
  gap: 10px;
  padding: 30px 34px 32px 86px;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.56);
}

.brief-question:last-child {
  border-bottom: 0;
}

.brief-question.wide {
  grid-column: 1 / -1;
}

.question-number {
  position: absolute;
  top: 30px;
  left: 34px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: rgba(31,58,91,.08);
  color: var(--navy);
  font-size: 13px;
  font-weight: 900;
}

.question-label {
  max-width: 860px;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.35;
  font-weight: 900;
}

.question-label em {
  color: var(--danger);
  font-style: normal;
}

.question-help {
  max-width: 820px;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.5;
}

input,
textarea {
  width: 100%;
  margin-top: 8px;
  border: 1px solid rgba(31,58,91,.16);
  border-radius: 20px;
  padding: 16px 17px;
  background: rgba(255,255,255,.94);
  color: var(--ink);
  font: inherit;
  font-size: 16px;
  outline: none;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9);
}

textarea {
  min-height: 130px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: rgba(102,112,133,.66);
}

input:focus,
textarea:focus {
  border-color: rgba(201,138,69,.72);
  box-shadow:
    0 0 0 4px rgba(201,138,69,.12),
    inset 0 1px 0 rgba(255,255,255,.9);
}

.brief-submit-bar {
  position: sticky;
  bottom: 18px;
  z-index: 15;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 28px;
  background: rgba(255,255,255,.82);
  box-shadow: 0 20px 60px rgba(23,35,49,.14);
  backdrop-filter: blur(18px);
}

.brief-submit-bar strong {
  display: block;
  color: var(--navy);
}

.brief-submit-bar span {
  display: block;
  margin-top: 3px;
  color: var(--ink-soft);
  font-size: 14px;
}

.brief-submit-actions {
  display: flex;
  gap: 10px;
}

.btn {
  border: 0;
  border-radius: 999px;
  padding: 14px 20px;
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}

.btn.primary {
  color: white;
  background: linear-gradient(135deg, var(--navy), var(--navy-2));
  box-shadow: 0 14px 34px rgba(31,58,91,.25);
}

.btn.ghost {
  color: var(--navy);
  background: rgba(31,58,91,.09);
}

.page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 36px 18px;
}

.hero {
  width: min(980px, 100%);
  padding: clamp(28px, 6vw, 64px);
  border: 1px solid var(--line);
  border-radius: 34px;
  background: rgba(255,255,255,.72);
  box-shadow: var(--shadow);
}

.badge {
  display: inline-flex;
  padding: 8px 13px;
  border-radius: 999px;
  background: rgba(31,58,91,.1);
  color: var(--navy);
  font-size: 13px;
  font-weight: 900;
}

h1 {
  margin: 22px 0 8px;
  font-size: clamp(58px, 12vw, 128px);
  line-height: .88;
  letter-spacing: -0.08em;
  color: var(--navy);
}

.baseline {
  max-width: 720px;
  margin: 0 0 34px;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.14;
  font-weight: 800;
}

.card,
.mini-card {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255,255,255,.72);
}

.card {
  padding: 26px;
  margin-bottom: 18px;
}

.card h2,
.mini-card h3 {
  margin: 0 0 10px;
}

.card p,
.mini-card p {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.6;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.mini-card {
  padding: 20px;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 26px;
  color: var(--ink-soft);
  font-size: 14px;
}

.status-ok {
  color: var(--success) !important;
  font-weight: 800;
}

.status-error {
  color: var(--danger) !important;
  font-weight: 800;
}

.clean-list {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.clean-list li {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(31,58,91,.08);
  color: var(--navy);
  font-weight: 700;
}

pre {
  white-space: pre-wrap;
  padding: 14px;
  border-radius: 14px;
  background: rgba(180,35,24,.08);
  color: #7a271a;
}

@media (max-width: 1080px) {
  .brief-shell {
    grid-template-columns: 1fr;
  }

  .brief-sidebar {
    position: static;
    min-height: auto;
  }

  .brief-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .brief-page {
    padding: 12px;
  }

  .brief-sidebar,
  .brief-hero,
  .brief-section {
    border-radius: 24px;
  }

  .brief-steps,
  .brief-question-grid.two,
  .grid {
    grid-template-columns: 1fr;
  }

  .brief-section-head,
  .brief-submit-bar {
    flex-direction: column;
  }

  .brief-question {
    padding: 72px 20px 24px;
  }

  .question-number {
    left: 20px;
  }

  .brief-submit-actions {
    width: 100%;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}
