/* Reset + page shell + typography. Blueprint atmosphere lives here. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  color-scheme: dark;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.6;
  color: var(--ink);
  background-color: var(--bg);
  background-image: var(--bg-glow);
  background-repeat: no-repeat;
  background-attachment: fixed;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img,
svg {
  display: block;
  max-width: 100%;
}

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

button {
  cursor: pointer;
}

a {
  color: var(--copper-strong);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

h1,
h2,
h3,
h4 {
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.02em;
  overflow-wrap: break-word;
}

h1 {
  font-size: var(--text-2xl);
}

h2 {
  font-size: var(--text-xl);
}

h3 {
  font-size: var(--text-lg);
}

p {
  overflow-wrap: break-word;
}

:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 2px;
}

::placeholder {
  color: var(--ink-faint);
}

/* Page shell */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--sp-5);
}

main.container {
  flex: 1;
  padding-block: var(--sp-6) var(--sp-8);
}

/* Discovery layout: filter strip on top, preview panel + startup list below */
.dashboard-layout {
  display: flex;
  flex-direction: column;
  gap: var(--sp-6);
}

.dashboard-main {
  display: grid;
  grid-template-columns: minmax(440px, 1.28fr) minmax(0, 1.32fr);
  gap: var(--sp-6);
  align-items: start;
}

.startup-results-panel {
  min-width: 0;
}

/* Blueprint vocabulary ------------------------------------------------ */

/* Map-node marker: the deck's plotted-city dot */
.node-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--copper);
  box-shadow: 0 0 0 3px var(--copper-soft);
  flex: none;
}

/* Measurement-tick rule: hairline with survey ticks every 48px */
.rule-ticks {
  border: 0;
  height: 7px;
  margin-block: var(--sp-5);
  background:
    repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 48px) top / 100% 5px no-repeat,
    linear-gradient(var(--line), var(--line)) bottom / 100% 1px no-repeat;
}

.page-head {
  margin-bottom: var(--sp-5);
}

.page-head h1 {
  margin-top: var(--sp-1);
}

.page-head .lede {
  color: var(--ink-muted);
  max-width: 60ch;
  margin-top: var(--sp-2);
}

.page-head .lede[data-i18n="dashboard.lede"] {
  max-width: 78ch;
  word-break: keep-all;
  line-break: strict;
}

/* Utility */
.mono {
  font-family: var(--font-mono);
}

.muted {
  color: var(--ink-muted);
}

.small {
  font-size: var(--text-sm);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.stack-sm > * + * {
  margin-top: var(--sp-2);
}

.stack > * + * {
  margin-top: var(--sp-4);
}

.row {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  flex-wrap: wrap;
}

.row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  flex-wrap: wrap;
}

/* Footer */
.site-footer {
  border-top: var(--border);
  background: var(--card);
  padding-block: var(--sp-5);
  margin-top: auto;
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  gap: var(--sp-4);
  flex-wrap: wrap;
  color: var(--ink-muted);
  font-size: var(--text-sm);
}

/* Responsive */
@media (max-width: 900px) {
  .dashboard-main {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: var(--text-xl);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
