* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--hc-text);
  background: var(--hc-bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  line-height: 1.55;
}

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

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

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

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

.shell {
  width: min(calc(100% - 40px), var(--hc-shell));
  margin-inline: auto;
}

.narrow-shell {
  max-width: 760px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand-mark {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex: 0 0 34px;
  border-radius: 11px;
  box-shadow: 0 8px 22px rgba(37, 67, 187, 0.18);
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 750;
  cursor: pointer;
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button-primary {
  color: #fff;
  background: var(--hc-purple);
  box-shadow: 0 10px 24px rgba(108, 53, 212, 0.22);
}

.button-secondary {
  color: var(--hc-purple-dark);
  border-color: var(--hc-border-strong);
  background: #fff;
}

.button-muted {
  color: var(--hc-text-soft);
  border-color: var(--hc-border);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 8px 22px rgba(49, 27, 85, 0.04);
}

.button-muted:hover,
.button-muted:focus-visible {
  color: var(--hc-purple-dark);
  border-color: var(--hc-border-strong);
  background: #fff;
}

.button-small {
  min-height: 36px;
  padding: 7px 12px;
  border-radius: 9px;
  font-size: 13px;
}

.button-full {
  width: 100%;
}

.eyebrow,
.admin-kicker,
.admin-auth-kicker {
  display: inline-block;
  margin-bottom: 14px;
  color: var(--hc-purple);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.flash {
  margin-bottom: 20px;
  padding: 12px 14px;
  border: 1px solid var(--hc-border);
  border-radius: 10px;
  background: #fff;
  font-size: 14px;
}

.flash-error {
  color: #8b1e16;
  border-color: #f0c4c0;
  background: #fff5f4;
}

.flash-success {
  color: #12653f;
  border-color: #b8dfca;
  background: #f0fbf5;
}

.stack-form {
  display: grid;
  gap: 16px;
}

.stack-form label {
  display: grid;
  gap: 7px;
  color: var(--hc-text);
  font-size: 13px;
  font-weight: 700;
}

.stack-form input,
.stack-form select,
.stack-form textarea,
.user-access-form select {
  width: 100%;
  min-height: 42px;
  padding: 9px 11px;
  color: var(--hc-text);
  border: 1px solid var(--hc-border-strong);
  border-radius: 10px;
  outline: none;
  background: #fff;
}

.stack-form input:focus,
.stack-form select:focus,
.stack-form textarea:focus,
.user-access-form select:focus {
  border-color: var(--hc-purple);
  box-shadow: 0 0 0 3px var(--hc-purple-soft);
}

.stack-form textarea {
  resize: vertical;
}

.stack-form fieldset {
  display: grid;
  gap: 16px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.stack-form small {
  color: var(--hc-text-soft);
  font-weight: 500;
}

@media (max-width: 640px) {
  .shell {
    width: min(calc(100% - 28px), var(--hc-shell));
  }
}
