/* The Share Link recipient page. Its colours are the web app's colour roles (src/InfiniteStorage.Host/Web/wwwroot/app.css), copied because the page is on
   another origin and cannot load that stylesheet; share-site.test.mjs checks they stay the same and that every text reaches 4.5:1 in both schemes. The page
   follows the reader's device, with no switch, and stores nothing. */

:root {
  color-scheme: light dark;
  --bg: #f5f6f7;
  --surface: #ffffff;
  --surface-2: #eef0f2;
  --border: #dfe3e7;
  --text: #1d242b;
  --muted: #5b6773;
  --accent: #2b6a88;
  --accent-text: #ffffff;
  --accent-soft: #e2eff5;
  --ok: #24724f;
  --ok-soft: #e2f2ea;
  --warn: #8a5f00;
  --warn-soft: #fbf0d9;
  --bad: #ad3535;
  --bad-soft: #fae6e6;
  --radius: 0.625rem;
  --radius-small: 0.375rem;
  --tap: 2.75rem;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14181c;
    --surface: #1c2227;
    --surface-2: #262d33;
    --border: #333b43;
    --text: #e6eaee;
    --muted: #a0abb6;
    --accent: #7db6d1;
    --accent-text: #10181e;
    --accent-soft: #1f3540;
    --ok: #7fcfa8;
    --ok-soft: #1c3329;
    --warn: #e0bd6f;
    --warn-soft: #3a2f16;
    --bad: #ef9a9a;
    --bad-soft: #3d2222;
  }
}

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

[hidden] {
  display: none !important;
}

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 1rem/1.5 var(--font);
}

p,
h1 {
  margin: 0;
}

.page {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 34rem;
  margin: 0 auto;
  padding: 2rem 1rem 1.25rem;
}

.label {
  color: var(--muted);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.card {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  padding: 1.125rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

h1 {
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.small {
  font-size: 0.875rem;
}

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

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: baseline;
  justify-content: space-between;
}

.button {
  width: 100%;
  min-height: var(--tap);
  padding: 0.5rem 1rem;
  border: 0;
  border-radius: var(--radius-small);
  background: var(--accent);
  color: var(--accent-text);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.button.secondary {
  border: 1px solid var(--muted);
  background: var(--surface);
  color: var(--text);
}

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

progress {
  width: 100%;
  height: 0.5rem;
  accent-color: var(--accent);
}

.notes {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.notes:empty {
  display: none;
}

.note {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  padding: 0.875rem 1rem;
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--text);
}

.note.ok {
  background: var(--ok-soft);
}

.note.ok b {
  color: var(--ok);
}

.note.warn {
  background: var(--warn-soft);
}

.note.warn b {
  color: var(--warn);
}

.note.bad {
  background: var(--bad-soft);
}

.note.bad b {
  color: var(--bad);
}

.note .button {
  margin-top: 0.5rem;
}

/* "Look in your Downloads." on a phone; "... Downloads folder." where there is a mouse or touchpad. */
.on-computer {
  display: none;
}

@media (any-pointer: fine) {
  .on-computer {
    display: inline;
  }
}

@media (min-width: 48rem) {
  .page {
    padding-top: 5rem;
  }

  h1 {
    font-size: 1.375rem;
  }
}
