:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface-soft: #eef4f8;
  --text: #111318;
  --muted: #626b76;
  --line: #dfe4ea;
  --blue: #155eef;
  --blue-ink: #0f3fa8;
  --green: #147d64;
  --amber: #b7791f;
  --danger: #bd2f2f;
  --shadow: 0 18px 50px rgba(16, 24, 40, 0.08);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  letter-spacing: 0;
}

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

button,
input,
textarea,
select {
  font: inherit;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--text);
  padding: 13px 14px;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

input:focus,
textarea:focus,
select:focus {
  border-color: rgba(21, 94, 239, 0.7);
  box-shadow: 0 0 0 4px rgba(21, 94, 239, 0.1);
}

textarea {
  resize: vertical;
  line-height: 1.6;
}

label {
  display: grid;
  gap: 8px;
  color: #2c343f;
  font-weight: 650;
}

fieldset {
  border: 0;
  padding: 0;
  margin: 0;
}

legend {
  margin-bottom: 10px;
  font-weight: 760;
}

main {
  min-height: calc(100vh - 190px);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 76px;
  padding: 16px clamp(20px, 4vw, 64px);
  background: rgba(246, 247, 249, 0.88);
  border-bottom: 1px solid rgba(223, 228, 234, 0.78);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 820;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius);
  background: var(--text);
  color: #fff;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--muted);
  font-weight: 650;
}

.site-nav a {
  white-space: nowrap;
}

.nav-button,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 12px 18px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  font-weight: 760;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover,
.nav-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(16, 24, 40, 0.1);
}

.button.primary,
.nav-button {
  background: var(--text);
  color: #fff;
}

.button.ghost {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.78);
}

.button.small {
  min-height: 38px;
  padding: 9px 13px;
  font-size: 14px;
}

.button.full {
  width: 100%;
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  transform: none;
  box-shadow: none;
}

.hero,
.page-hero,
.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
  gap: clamp(28px, 5vw, 70px);
  align-items: center;
  padding: clamp(64px, 10vw, 118px) clamp(20px, 5vw, 76px) clamp(44px, 7vw, 84px);
}

.page-hero,
.dashboard-hero {
  grid-template-columns: minmax(0, 1fr);
  max-width: 1120px;
  margin: 0 auto;
  padding-bottom: 30px;
}

.page-hero.compact {
  padding-bottom: 10px;
}

.hero h1,
.page-hero h1,
.dashboard-hero h1 {
  margin: 0;
  max-width: 820px;
  font-size: 64px;
  line-height: 1.02;
  font-weight: 850;
}

.hero-sub,
.page-hero p,
.dashboard-hero p,
.section-head p {
  color: var(--muted);
  font-size: 19px;
  line-height: 1.7;
}

.hero-actions,
.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 820;
  text-transform: uppercase;
}

.product-preview {
  border: 1px solid rgba(223, 228, 234, 0.9);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.product-preview img {
  display: block;
  width: 100%;
  height: auto;
}

.preview-top {
  display: flex;
  gap: 8px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.preview-top span {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #c5ccd6;
}

.preview-grid {
  display: grid;
  gap: 18px;
  padding: 28px;
}

.preview-line {
  height: 28px;
  width: 72%;
  border-radius: var(--radius);
  background: #17202b;
}

.preview-meter {
  height: 12px;
  border-radius: 999px;
  background: #d9e2ef;
  overflow: hidden;
}

.preview-meter span,
.progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--blue);
}

.preview-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 20px;
}

.preview-card p {
  margin-bottom: 0;
  color: var(--muted);
}

.preview-card.accent {
  border-color: rgba(20, 125, 100, 0.25);
  background: #effaf6;
}

.preview-timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
}

.preview-timeline span {
  height: 72px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line);
}

.section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 54px clamp(20px, 4vw, 42px);
}

.section.narrow {
  max-width: 860px;
}

.section-head {
  max-width: 760px;
  margin: 0 auto 28px;
  text-align: center;
}

.section-head.align-left {
  margin-left: 0;
  text-align: left;
}

.section h2,
.panel h2,
.result-panel h2 {
  margin: 0 0 14px;
  font-size: 34px;
  line-height: 1.18;
}

.value-grid,
.junior-grid,
.service-grid,
.metric-grid,
.dashboard-grid,
.result-layout {
  display: grid;
  gap: 18px;
}

.value-grid,
.service-grid,
.metric-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.junior-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.panel,
.metric,
.status-panel,
.tool-panel,
.analysis-preview,
.auth-form,
.stack-form,
.empty-state,
.project-summary,
.wbs-form,
.complete-panel,
.result-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 10px 35px rgba(16, 24, 40, 0.045);
}

.card,
.panel,
.metric,
.status-panel,
.tool-panel,
.analysis-preview,
.auth-form,
.stack-form,
.empty-state,
.project-summary,
.wbs-form,
.complete-panel,
.result-panel {
  padding: 24px;
}

.card h3,
.process-step h3,
.idea-item h3,
.project-row h3 {
  margin: 0 0 10px;
  font-size: 21px;
}

.card p,
.panel p,
.empty-state p,
.result-panel p,
.service-detail p,
.process-step p {
  color: var(--muted);
  line-height: 1.65;
}

.card-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  border-radius: var(--radius);
  background: #eaf1ff;
  color: var(--blue-ink);
  font-weight: 850;
}

.card-icon.green {
  background: #e8f6f1;
  color: var(--green);
}

.card-icon.amber {
  background: #fff4df;
  color: var(--amber);
}

.split-band {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(280px, 1fr);
  gap: 30px;
  align-items: center;
  max-width: none;
  background: #111318;
  color: #fff;
  padding-left: clamp(20px, 7vw, 90px);
  padding-right: clamp(20px, 7vw, 90px);
}

.split-band p {
  color: rgba(255, 255, 255, 0.72);
}

.voice-demo {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
  padding: 24px;
}

.mic-button {
  width: 76px;
  height: 76px;
  border: 0;
  border-radius: 999px;
  background: radial-gradient(circle at 50% 38%, #fff 0 9px, transparent 10px), linear-gradient(180deg, #155eef, #147d64);
}

.transcript-label,
.muted,
.form-help {
  color: var(--muted);
}

.text-link {
  display: inline-flex;
  color: var(--blue);
  font-weight: 760;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.process-step {
  border-top: 3px solid var(--blue);
  padding: 22px 0;
}

.process-step span {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
  border-radius: var(--radius);
  background: var(--text);
  color: #fff;
  font-weight: 800;
}

.tool-layout,
.auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 24px;
  align-items: start;
}

.stack-form,
.tool-panel,
.auth-form {
  display: grid;
  gap: 18px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.analysis-preview {
  position: sticky;
  top: 96px;
}

.check-list,
.feature-list {
  display: grid;
  gap: 10px;
  padding: 0;
  margin: 16px 0 0;
  list-style: none;
}

.check-list li,
.feature-list li {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  background: #fff;
}

.filter-bar,
.segmented {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.chip,
.segmented span {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 10px 14px;
  font-weight: 760;
}

.chip.active {
  background: var(--text);
  color: #fff;
}

.segmented input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.segmented label input:checked + span {
  background: var(--text);
  color: #fff;
}

.conditional-panel {
  display: none;
  gap: 16px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.conditional-panel.is-active {
  display: grid;
}

.inline-check {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  font-weight: 650;
}

.inline-check input {
  width: auto;
}

.auth-shell {
  max-width: 1050px;
  margin: 0 auto;
  padding: 72px 20px;
}

.auth-copy h1 {
  font-size: 46px;
  line-height: 1.1;
  margin: 0 0 14px;
}

.auth-copy p {
  color: var(--muted);
  line-height: 1.7;
}

.form-errors {
  border: 1px solid rgba(189, 47, 47, 0.25);
  border-radius: var(--radius);
  background: #fff1f1;
  color: var(--danger);
  padding: 12px 14px;
}

.form-errors p {
  margin: 4px 0;
}

.flash-wrap {
  position: fixed;
  right: 20px;
  top: 92px;
  z-index: 30;
  display: grid;
  gap: 8px;
  max-width: 380px;
}

.flash {
  margin: 0;
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
  background: #fff;
}

.flash.success {
  border-left: 4px solid var(--green);
}

.flash.error {
  border-left: 4px solid var(--danger);
}

.flash.notice {
  border-left: 4px solid var(--blue);
}

.dashboard-hero {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
}

.metric-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 42px) 24px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.metric span {
  display: block;
  margin-bottom: 6px;
  font-size: 34px;
  font-weight: 850;
}

.metric p {
  margin: 0;
  color: var(--muted);
  font-weight: 650;
}

.dashboard-grid {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 42px) 24px;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
}

.panel.wide {
  grid-column: auto;
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.compact-form {
  padding: 0;
  border: 0;
  box-shadow: none;
}

.dashboard-section {
  padding-top: 28px;
}

.idea-list,
.project-list {
  display: grid;
  gap: 14px;
}

.idea-item,
.project-row,
.service-detail {
  display: grid;
  gap: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 22px;
}

.analysis-card {
  margin-top: 16px;
  border: 1px solid rgba(21, 94, 239, 0.18);
  border-radius: var(--radius);
  background: #f4f7ff;
  padding: 16px;
}

.analysis-card ul {
  margin-bottom: 0;
}

.media-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.media-list li {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fbfcfd;
  color: var(--muted);
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 650;
}

.project-row {
  grid-template-columns: minmax(220px, 1fr) minmax(160px, 220px) 60px minmax(260px, 1fr);
  align-items: center;
}

.progress {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: #e5eaf1;
}

.inline-feedback {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.project-summary {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 20px;
  margin-bottom: 18px;
}

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

.summary-grid article {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  background: #fbfcfd;
}

.summary-grid span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 760;
}

.wbs-table {
  display: grid;
  gap: 8px;
}

.wbs-head,
.wbs-row {
  display: grid;
  grid-template-columns: 52px minmax(140px, 1fr) 120px 96px minmax(160px, 1fr) minmax(160px, 1fr);
  gap: 8px;
  align-items: center;
}

.wbs-head {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.wbs-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px;
  background: #fbfcfd;
}

.complete-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 16px;
}

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

.result-panel.wide {
  grid-column: 1 / -1;
}

.result-tasks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.result-tasks div {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  background: #fbfcfd;
}

.service-detail {
  grid-template-columns: minmax(0, 1fr) minmax(260px, 0.45fr);
}

.service-detail-list {
  display: grid;
  gap: 16px;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 34px clamp(20px, 4vw, 64px);
  color: var(--muted);
  border-top: 1px solid var(--line);
}

@media (max-width: 980px) {
  .hero,
  .tool-layout,
  .auth-shell,
  .project-summary,
  .dashboard-grid,
  .split-band,
  .service-detail {
    grid-template-columns: 1fr;
  }

  .hero h1,
  .page-hero h1,
  .dashboard-hero h1 {
    font-size: 46px;
  }

  .value-grid,
  .junior-grid,
  .service-grid,
  .metric-grid,
  .process-grid,
  .result-layout,
  .result-tasks {
    grid-template-columns: 1fr 1fr;
  }

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

  .wbs-head {
    display: none;
  }

  .wbs-row {
    grid-template-columns: 48px 1fr;
  }

  .wbs-row select,
  .wbs-row input {
    grid-column: 1 / -1;
  }
}

@media (max-width: 720px) {
  .site-header {
    position: static;
    align-items: flex-start;
    flex-direction: column;
  }

  .site-nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .hero,
  .page-hero,
  .dashboard-hero {
    padding-top: 42px;
  }

  .hero h1,
  .page-hero h1,
  .dashboard-hero h1,
  .auth-copy h1 {
    font-size: 38px;
  }

  .value-grid,
  .junior-grid,
  .service-grid,
  .metric-grid,
  .process-grid,
  .summary-grid,
  .form-grid,
  .result-layout,
  .result-tasks {
    grid-template-columns: 1fr;
  }

  .product-preview {
    min-height: 360px;
  }

  .flash-wrap {
    position: static;
    max-width: none;
    margin: 12px 20px 0;
  }

  .complete-panel,
  .site-footer {
    flex-direction: column;
    align-items: stretch;
  }
}
