/* Lanyard's public site. Mobile first; the colours are the app's (web/src/index.css):
   production blue #2563eb for buttons in both appearances, dark links #6b95ff,
   light links #1d4ed8. Green is not used here: in Lanyard it means only "good". */

:root {
  --canvas: #f3f4f6;
  --surface: #ffffff;
  --border: #e4e7ec;
  --text: #101828;
  --text-secondary: #475467;
  --link: #1d4ed8;
  --link-hover: #1e40af;
  --brand: #2563eb;
  --brand-hover: #1d4ed8;
  --brand-text: #ffffff;
  --focus: rgba(37, 99, 235, 0.35);
  --gutter: 16px;
  --measure: 42rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --canvas: #0b0d10;
    --surface: #14171c;
    --border: #23272e;
    --text: #eef0f3;
    --text-secondary: #9aa3ad;
    --link: #6b95ff;
    --link-hover: #8fb0ff;
    --focus: rgba(107, 149, 255, 0.4);
    color-scheme: dark;
  }
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  overflow-wrap: anywhere;
}

a {
  color: var(--link);
}

a:hover {
  color: var(--link-hover);
}

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

img {
  max-width: 100%;
  height: auto;
}

.wrap {
  width: 100%;
  max-width: var(--measure);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--surface);
  padding: 8px 12px;
  border-radius: 8px;
}

.skip:focus {
  left: 8px;
  z-index: 1;
}

/* Header */

.top {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.top-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  min-height: 56px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 650;
  font-size: 1.125rem;
  margin-right: auto;
}

.mark {
  width: 28px;
  height: 28px;
  border-radius: 7px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 4px 16px;
}

.nav a {
  color: var(--text-secondary);
  text-decoration: none;
  padding: 10px 0;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--text);
}

.nav a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-color: var(--brand);
  text-underline-offset: 6px;
  text-decoration-thickness: 2px;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-weight: 600;
  text-decoration: none;
  line-height: 1.2;
}

.btn-primary {
  background: var(--brand);
  color: var(--brand-text);
}

.btn-primary:hover {
  background: var(--brand-hover);
  color: var(--brand-text);
}

.btn-secondary {
  border-color: var(--border);
  background: var(--surface);
  color: var(--text);
}

.nav .btn-secondary {
  color: var(--text);
}

.btn-small {
  min-height: 36px;
  padding: 6px 14px;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0;
}

.actions .btn {
  flex: 1 1 100%;
}

@media (min-width: 480px) {
  .actions .btn {
    flex: 0 0 auto;
    min-width: 11rem;
  }
}

/* Content */

main {
  padding-top: 32px;
  padding-bottom: 48px;
}

h1 {
  font-size: 1.75rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
}

h2 {
  font-size: 1.25rem;
  line-height: 1.3;
  margin: 32px 0 8px;
}

h3 {
  font-size: 1.05rem;
  margin: 24px 0 6px;
}

p,
ul,
ol {
  margin: 0 0 16px;
}

ul,
ol {
  padding-left: 1.4em;
}

li {
  margin-bottom: 6px;
}

.lede {
  font-size: 1.125rem;
  color: var(--text-secondary);
}

.eyebrow {
  margin-bottom: 4px;
  font-size: 0.9375rem;
}

.eyebrow a {
  text-decoration: none;
}

.byline {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.prose a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.prose .btn {
  text-decoration: none;
}

.prose blockquote {
  margin: 0 0 16px;
  padding-left: 16px;
  border-left: 3px solid var(--border);
  color: var(--text-secondary);
}

.prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9375em;
}

.prose pre {
  overflow-x: auto;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
}

@media (min-width: 720px) {
  main {
    padding-top: 48px;
  }

  h1 {
    font-size: 2.25rem;
  }

  h2 {
    font-size: 1.5rem;
  }
}

/* Facts: the home page's short list of what Lanyard does */

.facts {
  list-style: none;
  padding: 0;
  margin: 24px 0;
  display: grid;
  gap: 12px;
}

.facts li {
  margin: 0;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.facts strong {
  display: block;
  margin-bottom: 2px;
}

@media (min-width: 640px) {
  .facts {
    grid-template-columns: 1fr 1fr;
  }
}

/* Price */

.price {
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin: 24px 0;
}

.price .amount {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.price .per {
  color: var(--text-secondary);
}

.placeholder {
  border-bottom: 2px dashed var(--text-secondary);
}

/* Blog index */

.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.post-list li {
  padding: 16px 0;
  border-top: 1px solid var(--border);
  margin: 0;
}

.post-list h2 {
  margin: 0 0 4px;
  font-size: 1.25rem;
}

.post-list time {
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.post-list p {
  margin: 6px 0 0;
}

/* Legal documents */

.contents ol {
  padding-left: 1.4em;
  columns: 1;
}

.contents li {
  padding: 4px 0;
}

.legal section {
  scroll-margin-top: 16px;
}

.legal-contact {
  margin-top: 32px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* Footer */

.foot {
  border-top: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.foot-row {
  padding-top: 20px;
  padding-bottom: 28px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: baseline;
}

.foot p {
  margin: 0;
  flex: 1 1 100%;
}

.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
}

.foot a {
  color: var(--text-secondary);
  padding: 6px 0;
  display: inline-block;
}

.foot a:hover {
  color: var(--text);
}

@media (min-width: 640px) {
  .foot p {
    flex: 1 1 auto;
  }
}
