/* Shared styles and icon-inspired colors for the Vidy static site. */

:root {
  color-scheme: light;
  --bg-page: #eef2ff;
  --bg-button: #1b2742;
  --bg-button-hover: #293958;
  --text-heading: #0d142a;
  --text-prose: #3d4965;
  --text-button: #f6f8ff;
  --text-on-accent: #0d142a;
  --text-link: #075f7a;
  --text-link-hover: #6e238f;
  --accent-cyan: #00d8ff;
  --accent-purple: #d852ff;
  --accent-gold: #ffb700;
  --accent-pink: #ff0074;
}

/* Match the icon's Display P3 accents on browsers that support them. */
@supports (color: color(display-p3 1 1 1)) {
  :root {
    --accent-cyan: color(display-p3 0 0.831373 1);
    --accent-purple: color(display-p3 0.784314 0.356863 0.984314);
    --accent-gold: color(display-p3 1 0.733333 0);
    --accent-pink: color(display-p3 1 0 0.458824);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text-heading);
  background-color: var(--bg-page);
  font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji",
    "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  color: var(--text-on-accent);
  background-color: var(--accent-cyan);
}

a:focus-visible {
  outline: 3px solid var(--text-link-hover);
  outline-offset: 4px;
}

/* ---------- Landing page ---------- */


body.landing {
  background-color: var(--bg-page);
  background-image: linear-gradient(145deg, #e0e8ff, #f5f7ff 60%, #e8deff);
  font-weight: 700;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.landing-card {
  padding: 1.5rem;
  max-width: 24rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.landing-card .logo {
  width: 8rem;
  height: auto;
}

.landing-card .logomark {
  width: 8rem;
  height: auto;
  padding-top: 0.75rem;
}

.landing-card h1,
.landing-card h2 {
  font-weight: 900;
  font-size: 1.875rem;
  line-height: 2.25rem;
  margin: 0;
}

.landing-links {
  width: 100%;
}

.landing-links a {
  display: block;
  margin: 0.625rem auto;
  padding: 0.625rem 1.5rem;
  font-size: 1.25rem;
  line-height: 1.75rem;
  font-weight: 700;
  cursor: pointer;
  background-color: var(--bg-button);
  border: 0;
  border-radius: 0.75rem;
  color: var(--text-button);
  text-decoration: none;
  text-align: center;
  transition: background-color 300ms;
}

.landing-links a:nth-child(1) {
  --bg-button: var(--accent-cyan);
  --bg-button-hover: #53def5;
  --text-button: var(--text-on-accent);
}

.landing-links a:nth-child(2) {
  --bg-button: var(--accent-purple);
  --bg-button-hover: #df83ff;
  --text-button: var(--text-on-accent);
}

.landing-links a:nth-child(3) {
  --bg-button: var(--accent-gold);
  --bg-button-hover: #ffd04d;
  --text-button: var(--text-on-accent);
}

.landing-links a:nth-child(4) {
  --bg-button: var(--accent-pink);
  --bg-button-hover: #ff52ad;
  --text-button: var(--text-on-accent);
}

.landing-links a:hover {
  background-color: var(--bg-button-hover);
}

/* ---------- Prose pages (Terms of Service, Privacy) ---------- */

body.prose-page {
  background-color: var(--bg-page);
}

.prose {
  max-width: 56rem;
  margin: 0 auto;
  padding: 1.5rem;
  color: var(--text-prose);
  font-size: 1rem;
  line-height: 1.75;
}

.prose h1 {
  color: var(--text-heading);
  font-size: 2.25rem;
  line-height: 1.1;
  font-weight: 800;
  margin: 0 0 0.9em;
}

.prose h2 {
  color: var(--text-heading);
  font-size: 1.5rem;
  line-height: 1.33;
  font-weight: 700;
  margin: 2em 0 1em;
}

.prose h3 {
  color: var(--text-heading);
  font-size: 1.25rem;
  line-height: 1.6;
  font-weight: 600;
  margin: 1.6em 0 0.6em;
}

.prose p {
  margin: 1.25em 0;
}

.prose strong {
  color: var(--text-heading);
  font-weight: 600;
}

.prose a {
  color: var(--text-link);
  text-decoration: underline;
  font-weight: 500;
}

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

.prose ol,
.prose ul {
  margin: 1.25em 0;
  padding-left: 1.625em;
}

.prose li {
  margin: 0.5em 0;
}

.prose u {
  color: var(--text-heading);
}
