/* What the settings page (views/ajustes.js) turns on, read from the page's own
   attributes set by js/access.js: data-text (normal, big, huge), data-motion (full,
   reduce) and data-contrast (normal, more). Plus the look of the page itself. */

/* ---------- text size ---------- */
/* (every size in the app is in rem, so the page's own size is all that changes) */
html[data-text="huge"] { font-size: 143.75%; }

/* ---------- less motion ---------- */
/* the phone's own setting is already read by the rules next to each animation in
   styles.css; this is the rider asking for it here, whatever the phone says */
html[data-motion="reduce"] *, html[data-motion="reduce"] *::before, html[data-motion="reduce"] *::after {
  animation: none !important;
  transition: none !important;
  scroll-behavior: auto !important;
}

/* ---------- more contrast ---------- */
/* greys that were a quiet second voice become near the text's own colour, borders
   show, links are underlined and the focus ring is thick (WCAG 1.4.6, 1.4.11, 2.4.7) */
html[data-contrast="more"] { --muted: #33444f; --line: #6b7f8b; }
html[data-contrast="more"][data-theme="dark"] { --muted: #c9d6de; --line: #7e93a0; }
html[data-contrast="more"] a:not(.button):not(.brand):not(.badge):not([data-tab]):not(.arr a) { text-decoration: underline; }
html[data-contrast="more"] :focus-visible { outline: 4px solid var(--ink); outline-offset: 2px; }
html[data-contrast="more"] .seg { border-color: var(--ink); }
html[data-contrast="more"] .card { border: 2px solid var(--line); }

/* ---------- the page itself ---------- */
.setnote { display: block; margin-top: 2px; font-size: 0.82rem; max-width: 30ch; }
.legal { list-style: none; margin: 0; padding: 0 16px; display: grid; gap: 4px; }
.legal a { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); text-decoration: underline; }
.legal li:last-child a { border-bottom: 0; }
.button[disabled] { opacity: 0.5; cursor: default; }
@media (max-width: 380px) {
  #tabs a { font-size: 0.68rem; }
  #tabs a svg { padding: 3px 9px; }
}
