/* ==========================================================================
   Big Dawg's Homepage ~ a Mac OS 9 (Platinum) desktop
   One hand-written stylesheet. No build step, no external hosts, no fonts
   downloaded from anywhere: the Chicago/Charcoal look comes from the
   system font stack below (licence-clean, nothing to ship).
   Every class is prefixed os- so it is easy to grep.

   Two layouts from one markup:
   - JS off: the menu bar sits on top and every window stacks down the
     page in normal flow, fully readable.
   - JS on (desk.js adds .os-js to <html> first thing): the desktop fills
     the screen, windows are absolutely placed and hidden unless .os-open.
     desk.js sets inline left/top/width/height + z-index; when a window is
     zoomed or the screen is 700px or narrower it removes left/top/width/
     height so the size comes from the rules here (no !important needed).
   ========================================================================== */

/* ---- Platinum palette --------------------------------------------------- */
:root {
  --os-desktop: #9999cc;      /* periwinkle */
  --os-face: #dddddd;         /* menu bar and window chrome */
  --os-face-dark: #cccccc;
  --os-hilite: #ffffff;       /* bevel highlight edge */
  --os-shadow: #808080;       /* bevel shadow edge */
  --os-stripe: #999999;       /* title bar stripe */
  --os-outline: #000000;
  --os-paper: #ffffff;        /* window content */
  --os-ink: #000000;
  --os-ink-soft: #444444;
  --os-ink-dim: #808080;      /* inactive title text */
  --os-select: #000080;       /* selected icon label */
  --os-link: #0000cc;
  --os-visited: #551a8b;
  --os-focus: #000080;
  --os-menu-select: #3535a8;  /* menu highlight (blue-violet, as in OS 9) */
  --os-note-yellow: #ffffa0;
  --os-note-green: #c8ffc8;
  --os-note-pink: #ffc8c8;
  --os-note-blue: #c8c8ff;
  --os-menubar-h: 20px;
  --os-font: "Charcoal", "Chicago", "Geneva", "Lucida Grande", Verdana, sans-serif;
  /* Geneva has no bold face, so bold text skips it (Charcoal is heavy anyway). */
  --os-font-bold: "Charcoal", "Chicago", "Lucida Grande", Verdana, sans-serif;
  --os-mono: "Monaco", "Courier New", Courier, monospace;
}

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

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

.os-body {
  margin: 0;
  min-height: 100vh;
  background: var(--os-desktop);
  color: var(--os-ink);
  font-family: var(--os-font);
  font-size: 14px;
  line-height: 1.45;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.os-body h2,
.os-body h3,
.os-body h4 {
  line-height: 1.25;
}

.os-body h1,
.os-body h2,
.os-body h3,
.os-body h4,
.os-body strong,
.os-body b,
.os-body th,
.os-menubar,
.os-new {
  font-family: var(--os-font-bold);
}

.os-body img {
  max-width: 100%;
  height: auto;
  border: 0;
}

.os-body a {
  color: var(--os-link);
  text-decoration: underline;
}

.os-body a:visited {
  color: var(--os-visited);
}

/* Visible focus ring on every interactive thing. */
.os-body a:focus-visible,
.os-body button:focus-visible,
.os-body [tabindex]:focus-visible {
  outline: 2px solid var(--os-focus);
  outline-offset: 2px;
}

.os-visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* ---- Menu bar ------------------------------------------------------------ */
.os-menubar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 14px;
  height: var(--os-menubar-h);
  /* The Apple sits inside a padded title, so the bar's own left pad is small. */
  padding: 0 12px 0 6px;
  background: var(--os-face);
  border-bottom: 1px solid var(--os-outline);
  box-shadow: inset 0 1px 0 var(--os-hilite);
  font-size: 12px;
  font-weight: bold;
  line-height: 1;
  white-space: nowrap;
  user-select: none;
  -webkit-user-select: none;
}

.os-apple {
  display: block;
  flex: none;
  width: 14px;
  height: 16px;
}

/* Titles stretch top to bottom so the open-title bar fills the menu bar;
   the spacing between titles lives in their padding, not a gap. */
.os-menus {
  display: flex;
  align-self: stretch;
  gap: 0;
  min-width: 0;
  overflow: hidden;
}

.os-menu-title {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 8px;
  cursor: default;
}

/* Open title, and a keyboard-focused title (the highlight is the focus
   ring): the OS 9 blue-violet bar with white text. */
.os-menu-title.os-menu-open,
.os-menu-title:focus-visible {
  background: var(--os-menu-select);
  color: var(--os-hilite);
}

.os-body .os-menu-title:focus-visible,
.os-body .os-menu-item:focus-visible {
  outline: 0;
}

/* ---- Pull-down panel (one shared panel, built by desk.js) --------------- */
/* A sibling of .os-menus inside .os-menubar, so the overflow clip on the
   titles never cuts it; desk.js sets its left under the open title. */
.os-menu-panel {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 120px;
  padding: 1px 0;
  background: var(--os-face);
  color: var(--os-ink);
  border: 1px solid var(--os-outline);
  box-shadow:
    1px 1px 0 var(--os-outline),
    2px 2px 0 rgba(0, 0, 0, 0.35);
  font: bold 12px var(--os-font-bold);
  line-height: 1;
  white-space: nowrap;
}

.os-menu-panel[hidden] {
  display: none;
}

.os-menu-item {
  display: flex;
  align-items: center;
  height: 16px;
  padding: 0 12px 0 0;
  cursor: default;
  outline: 0;
}

.os-menu-check {
  flex: none;
  width: 16px;
  text-align: center;
}

.os-menu-label {
  flex: 1 1 auto;
}

.os-menu-key {
  flex: none;
  margin-left: 24px;
  text-align: right;
}

/* Submenu arrow: a small black triangle that turns white on highlight. */
.os-menu-arrow {
  flex: none;
  box-sizing: content-box;
  width: 0;
  height: 0;
  margin: 0 5px 0 24px;
  border-left: 5px solid currentColor;
  border-top: 4px solid transparent;
  border-bottom: 4px solid transparent;
}

.os-menu-item:not(.os-menu-disabled):hover,
.os-menu-item:not(.os-menu-disabled):focus {
  background: var(--os-menu-select);
  color: var(--os-hilite);
}

/* Greyed items never highlight, as in OS 9. */
.os-menu-disabled,
.os-menu-disabled:hover,
.os-menu-disabled:focus {
  background: transparent;
  color: var(--os-shadow);
}

.os-menu-sep {
  height: 2px;
  margin: 2px 0;
  border-top: 1px solid var(--os-shadow);
  border-bottom: 1px solid var(--os-hilite);
}

/* ---- Sleep / Shut Down veil --------------------------------------------- */
.os-veil {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  color: #fff;
  font: bold 16px var(--os-font-bold);
  text-align: center;
}

.os-body .os-veil:focus {
  outline: 0;
}

.os-veil-text {
  margin: 0;
  padding: 0 16px;
}

/* The clock ships empty and only desk.js fills it. */
.os-clock {
  display: none;
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}

.os-js .os-clock {
  display: block;
}

/* ---- Desktop: JS off (normal flow) -------------------------------------- */
.os-desktop {
  display: block;
  padding: 24px 16px 32px;
}

/* Desktop icons do nothing without desk.js, so they only show with it. */
.os-icons {
  display: none;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* ---- Desktop icons ------------------------------------------------------- */
.os-icon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  width: 84px;
  margin: 0;
  padding: 4px 2px;
  background: transparent;
  border: 0;
  color: var(--os-ink);
  font-family: var(--os-font);
  font-size: 11px;
  line-height: 1.2;
  text-align: center;
  cursor: default;
  -webkit-tap-highlight-color: transparent;
}

.os-icon img {
  display: block;
  width: 32px;
  height: 32px;
  image-rendering: pixelated;
}

.os-icon span {
  max-width: 100%;
  padding: 1px 3px;
  background: var(--os-paper);
  color: var(--os-ink);
}

.os-icon.os-selected img {
  filter: brightness(0.55);
}

.os-icon.os-selected span {
  background: var(--os-select);
  color: var(--os-hilite);
}

.os-body .os-icon:focus-visible {
  outline: 2px dotted var(--os-outline);
  outline-offset: 1px;
}

/* ---- Windows ------------------------------------------------------------- */
.os-window {
  display: flex;
  flex-direction: column;
  max-width: 760px;
  margin: 0 auto 24px;
  /* No-JS #win-<name> jumps land below the sticky menu bar, title visible. */
  scroll-margin-top: calc(var(--os-menubar-h) + 12px);
  padding: 0 5px 5px;
  background: var(--os-face);
  border: 1px solid var(--os-outline);
  box-shadow:
    inset 1px 1px 0 var(--os-hilite),
    inset -1px -1px 0 var(--os-shadow),
    2px 2px 0 rgba(0, 0, 0, 0.35);
  color: var(--os-ink);
}

.os-body .os-window:focus {
  outline: none;
}

.os-body .os-window:focus-visible {
  outline: 2px dotted var(--os-outline);
  outline-offset: 2px;
}

/* Title bar: active (and JS-off) windows get the striped Platinum bar. */
.os-titlebar {
  position: relative;
  display: flex;
  flex: none;
  align-items: center;
  gap: 8px;
  height: 22px;
  padding: 0 3px;
  background:
    repeating-linear-gradient(
      to bottom,
      var(--os-hilite) 0,
      var(--os-hilite) 1px,
      var(--os-stripe) 1px,
      var(--os-stripe) 2px
    )
    center / 100% 12px no-repeat,
    var(--os-face);
  user-select: none;
  -webkit-user-select: none;
}

.os-title {
  flex: 0 1 auto;
  min-width: 0;
  margin: 0 auto;
  padding: 0 8px;
  background: var(--os-face);
  color: var(--os-ink);
  font-size: 12px;
  font-weight: bold;
  line-height: 22px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Close and zoom boxes: a bevelled square, the zoom box with a box inside. */
.os-close,
.os-zoom {
  position: relative;
  flex: none;
  width: 13px;
  height: 13px;
  margin: 0;
  padding: 0;
  background: linear-gradient(135deg, var(--os-shadow), var(--os-hilite));
  border: 1px solid var(--os-outline);
  border-radius: 0;
  box-shadow:
    0 0 0 2px var(--os-face),
    inset 1px 1px 0 var(--os-hilite),
    inset -1px -1px 0 var(--os-shadow);
  cursor: default;
  /* They do nothing without desk.js. */
  visibility: hidden;
}

.os-js .os-close,
.os-js .os-zoom {
  visibility: visible;
}

.os-zoom::before {
  content: "";
  position: absolute;
  top: 1px;
  left: 1px;
  width: 6px;
  height: 6px;
  border: 1px solid var(--os-outline);
}

/* A bigger invisible hit area round the 13px box. */
.os-close::after,
.os-zoom::after {
  content: "";
  position: absolute;
  inset: -6px;
}

.os-close:active,
.os-zoom:active {
  background: var(--os-ink-soft);
  box-shadow:
    0 0 0 2px var(--os-face),
    inset 1px 1px 0 var(--os-outline);
}

.os-content {
  flex: 1 1 auto;
  min-height: 0;
  padding: 12px 16px;
  background: var(--os-paper);
  color: var(--os-ink);
  border: 1px solid var(--os-outline);
  box-shadow: -1px -1px 0 var(--os-shadow), 1px 1px 0 var(--os-hilite);
}

.os-content > :first-child {
  margin-top: 0;
}

.os-content > :last-child {
  margin-bottom: 0;
}

.os-content h3 {
  margin: 1.1em 0 0.4em;
  font-size: 15px;
}

.os-content h4 {
  margin: 1em 0 0.3em;
  font-size: 14px;
}

/* ---- Desktop: JS on ------------------------------------------------------ */
.os-js .os-body {
  overflow: hidden;
}

.os-js .os-menubar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
}

.os-js .os-desktop {
  position: fixed;
  z-index: 0;
  top: var(--os-menubar-h);
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0;
  overflow: hidden;
}

/* Icons down the right edge; extra icons wrap into a column to the left. */
.os-js .os-icons {
  position: absolute;
  top: 12px;
  right: 10px;
  bottom: 12px;
  display: grid;
  grid-auto-flow: column;
  grid-template-rows: repeat(auto-fill, 76px);
  grid-auto-columns: 84px;
  gap: 4px;
  direction: rtl;
}

.os-js .os-icons > li {
  direction: ltr;
}

.os-js .os-window {
  position: absolute;
  left: 0;
  top: 0;
  width: 480px;
  height: 360px;
  min-width: 200px;
  min-height: 90px;
  max-width: none;
  margin: 0;
}

.os-js .os-window:not(.os-open) {
  display: none;
}

.os-js .os-content {
  overflow: auto;
  overscroll-behavior: contain;
}

/* Platinum scroll bars: always visible, so a long window says it scrolls
   (macOS hides overlay scroll bars, OS 9 never did). */
.os-js .os-content::-webkit-scrollbar {
  width: 16px;
  height: 16px;
}

.os-js .os-content::-webkit-scrollbar-track {
  background: var(--os-face);
  border-left: 1px solid var(--os-outline);
  box-shadow: inset 1px 1px 0 var(--os-shadow);
}

.os-js .os-content::-webkit-scrollbar-thumb {
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent 2px,
      rgba(0, 0, 0, 0.35) 2px,
      rgba(0, 0, 0, 0.35) 3px
    )
    center / 8px 9px no-repeat,
    var(--os-note-blue);
  border: 1px solid var(--os-outline);
  box-shadow: inset 1px 1px 0 var(--os-hilite);
}

.os-js .os-content::-webkit-scrollbar-corner {
  background: var(--os-face);
}

@supports not selector(::-webkit-scrollbar) {
  .os-js .os-content {
    scrollbar-color: var(--os-note-blue) var(--os-face);
  }
}

/* Inactive windows: flat grey bar, dimmed title (Platinum behaviour). */
.os-js .os-window:not(.os-active) .os-titlebar {
  background: var(--os-face);
}

.os-js .os-window:not(.os-active) .os-title {
  color: var(--os-ink-dim);
}

.os-js .os-window:not(.os-active) .os-close,
.os-js .os-window:not(.os-active) .os-zoom {
  background: var(--os-face);
  border-color: var(--os-shadow);
  box-shadow: 0 0 0 2px var(--os-face);
}

.os-js .os-window:not(.os-active) .os-zoom::before {
  border-color: var(--os-shadow);
}

.os-js .os-window.os-active {
  box-shadow:
    inset 1px 1px 0 var(--os-hilite),
    inset -1px -1px 0 var(--os-shadow),
    3px 3px 0 rgba(0, 0, 0, 0.45);
}

/* Zoomed: fill the desktop. desk.js has removed the inline size. */
.os-js .os-window.os-zoomed {
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
}

/* Drag affordance only where dragging happens (wider than 700px). */
@media (min-width: 701px) {
  .os-js .os-window:not(.os-zoomed) .os-titlebar {
    cursor: grab;
    touch-action: none;
  }
}

.os-dragging,
.os-js .os-window.os-dragging .os-titlebar {
  cursor: grabbing;
  user-select: none;
  -webkit-user-select: none;
}

/* ---- Sticky notes -------------------------------------------------------- */
.os-note {
  margin: 0 0 12px;
  padding: 10px 12px;
  background: var(--os-note-yellow);
  color: var(--os-ink);
  border: 1px solid rgba(0, 0, 0, 0.45);
  box-shadow: 2px 2px 0 rgba(0, 0, 0, 0.25);
}

.os-note > :first-child {
  margin-top: 0;
}

.os-note > :last-child {
  margin-bottom: 0;
}

.os-note-yellow {
  background: var(--os-note-yellow);
}

.os-note-green {
  background: var(--os-note-green);
}

.os-note-pink {
  background: var(--os-note-pink);
}

.os-note-blue {
  background: var(--os-note-blue);
}

/* ---- Push button (Start Here: "See My Resume") -------------------------- */
.os-button,
.os-body a.os-button,
.os-body a.os-button:visited {
  display: inline-block;
  min-width: 96px;
  margin: 2px 6px 2px 0;
  padding: 4px 14px;
  background: linear-gradient(to bottom, #f4f4f4, var(--os-face-dark));
  color: var(--os-ink);
  border: 1px solid var(--os-outline);
  border-radius: 5px;
  box-shadow:
    inset 1px 1px 0 var(--os-hilite),
    inset -1px -1px 0 var(--os-shadow);
  font-family: var(--os-font);
  font-size: 13px;
  font-weight: bold;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  cursor: default;
}

.os-button:active,
.os-body a.os-button:active {
  background: linear-gradient(to bottom, #666666, #888888);
  color: var(--os-hilite);
  box-shadow: inset 1px 1px 0 var(--os-outline);
}

/* ---- Resume brag wall ---------------------------------------------------- */
.os-new {
  padding: 1px 4px;
  background: var(--os-select);
  color: var(--os-hilite);
  font-size: 10px;
  font-weight: bold;
  vertical-align: middle;
}

.os-job {
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px dotted var(--os-shadow);
}

.os-job h3,
.os-job h4 {
  margin: 0;
}

.os-when {
  margin: 2px 0 6px;
  color: var(--os-ink-soft);
  font-family: var(--os-mono);
  font-size: 12px;
}

.os-job ul {
  margin: 0;
}

.os-aside {
  color: var(--os-ink-soft);
  font-style: italic;
}

/* ---- Visitor counter: an inset Platinum readout ------------------------- */
.os-counter {
  display: inline-block;
  padding: 1px 6px;
  background: var(--os-paper);
  color: var(--os-ink);
  border: 1px solid var(--os-outline);
  box-shadow: inset 1px 1px 0 var(--os-shadow);
  font-family: var(--os-mono);
  font-weight: bold;
  letter-spacing: 0.15em;
  font-variant-numeric: tabular-nums;
}

/* ---- About Me stats table + Top 5 --------------------------------------- */
.os-stats {
  border-collapse: collapse;
  width: 100%;
  max-width: 100%;
  margin: 0 0 12px;
}

.os-stats th,
.os-stats td {
  padding: 4px 8px;
  border: 1px solid var(--os-shadow);
  text-align: left;
  vertical-align: top;
}

.os-stats th {
  width: 34%;
  background: var(--os-face);
  font-weight: bold;
}

.os-top5 {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: os-top5;
}

.os-top5 li {
  counter-increment: os-top5;
}

.os-top5 li::before {
  content: counter(os-top5) ".\00a0";
  font-weight: bold;
}

/* An amber monochrome terminal line, for the Amber Phosphor project. */
.os-amber {
  padding: 8px 12px;
  background: #17100a;
  color: #ffb000;
  border: 1px solid var(--os-outline);
  box-shadow: inset 1px 1px 0 var(--os-shadow);
  font-family: var(--os-mono);
  font-weight: bold;
  text-shadow: 0 0 6px #ff8c00;
}

/* ---- Link lists ---------------------------------------------------------- */
.os-links {
  margin: 0;
  padding: 0;
  list-style: none;
}

.os-links li {
  margin: 0 0 6px;
  padding-left: 1.2em;
  text-indent: -1.2em;
}

.os-links li::before {
  content: "\25B8\00a0\00a0"; /* small right-pointing triangle */
  color: var(--os-ink-soft);
}

/* ---- Small helpers ------------------------------------------------------- */
.os-center {
  text-align: center;
}

.os-fineprint {
  font-size: 12px;
  color: var(--os-ink-soft);
}

/* ---- Alert dialog (the 404 "system error") ------------------------------ */
.os-alert {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 14px 16px;
  max-width: 440px;
  margin: 12vh auto 0;
  padding: 18px 20px 16px;
  background: var(--os-face);
  color: var(--os-ink);
  border: 1px solid var(--os-outline);
  outline: 3px solid var(--os-face);
  box-shadow:
    inset 1px 1px 0 var(--os-hilite),
    inset -1px -1px 0 var(--os-shadow),
    0 0 0 4px var(--os-outline),
    5px 5px 0 2px rgba(0, 0, 0, 0.35);
}

/* The Platinum caution sign: a yellow triangle with the "!" inside. */
.os-alert-icon {
  display: flex;
  flex: none;
  align-items: flex-end;
  justify-content: center;
  width: 40px;
  height: 36px;
  padding-bottom: 3px;
  background: linear-gradient(to bottom, #ffee66, #f2c200);
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  font-family: var(--os-font-bold);
  font-size: 22px;
  font-weight: bold;
  line-height: 1;
}

.os-alert-icon img {
  width: 32px;
  height: 32px;
}

.os-alert-text {
  flex: 1 1 240px;
  min-width: 0;
}

.os-alert-text > :first-child {
  margin-top: 0;
}

.os-alert-text > :last-child {
  margin-bottom: 0;
}

/* Alert text is body-sized and bold, as in a real OS 9 alert. */
.os-alert-text h1 {
  margin: 0 0 0.6em;
  font-size: 15px;
}

/* The button row sits bottom right; the button is the default one, with
   the thick rounded ring OS 9 drew round it. */
.os-alert > .os-center {
  flex: 1 0 100%;
  margin: 0;
  text-align: right;
}

.os-alert .os-button,
.os-body .os-alert a.os-button {
  margin: 4px;
  box-shadow:
    inset 1px 1px 0 var(--os-hilite),
    inset -1px -1px 0 var(--os-shadow),
    0 0 0 2px var(--os-face),
    0 0 0 4px var(--os-outline);
}

/* Inside a window (the Trash) the alert is just content: the window is
   already the frame, so no second dialog border, ring or shadow. */
.os-content .os-alert {
  max-width: none;
  margin: 0;
  padding: 4px 0 0;
  background: transparent;
  border: 0;
  outline: 0;
  box-shadow: none;
}

/* ---- Phones and narrow screens ------------------------------------------ */
/* Windows become full-desktop sheets (one at a time), icons form a grid,
   and there is no drag affordance. desk.js has removed the inline size. */
@media (max-width: 700px) {
  .os-menubar {
    gap: 10px;
    padding: 0 8px;
  }

  /* No gap: the titles' padding spaces them, so highlight bars meet. */
  .os-menus {
    gap: 0;
  }

  .os-menu-title {
    padding: 0 6px;
  }

  .os-desktop {
    padding: 12px 8px 24px;
  }

  .os-content {
    padding: 10px 12px;
  }

  .os-js .os-desktop {
    padding: 0;
    overflow-y: auto;
  }

  .os-js .os-icons {
    position: static;
    grid-auto-flow: row;
    grid-template-rows: none;
    grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
    grid-auto-columns: auto;
    justify-items: center;
    gap: 12px 4px;
    padding: 16px 8px;
    direction: ltr;
  }

  .os-js .os-window,
  .os-js .os-window.os-zoomed {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    min-width: 0;
    border-left: 0;
    border-right: 0;
    box-shadow: none;
  }

  .os-js .os-window .os-titlebar {
    height: 32px;
    cursor: default;
  }

  .os-title {
    line-height: 32px;
  }

  /* Bigger close and zoom boxes for fingers. */
  .os-close,
  .os-zoom {
    width: 20px;
    height: 20px;
  }

  .os-zoom::before {
    width: 10px;
    height: 10px;
    top: 2px;
    left: 2px;
  }

  .os-alert {
    margin-top: 6vh;
  }
}

@media (max-width: 420px) {
  /* Apple (child 1), File and Edit stay; View, Special and Help go. */
  .os-menus .os-menu-title:nth-child(n + 4) {
    display: none;
  }
}

/* ---- Touch: finger-sized menu bar and items (WCAG 2.5.8) ---------------- */
@media (pointer: coarse) {
  :root {
    --os-menubar-h: 28px;
  }

  .os-menu-item {
    height: 28px;
  }
}

/* ---- Reduced motion: nothing animates ----------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

/* ---- Applications: Finder list view ------------------------------------- */
.os-finder-count {
  margin: 0 0 4px;
  color: var(--os-ink-soft);
  font-size: 11px;
}

.os-finder {
  border-collapse: collapse;
  width: 100%;
  margin: 0;
  background: #ffffff;
  border: 1px solid var(--os-shadow);
}

.os-finder th {
  padding: 2px 8px;
  background: var(--os-face);
  border-bottom: 1px solid var(--os-shadow);
  border-right: 1px solid var(--os-shadow);
  font-weight: bold;
  text-align: left;
}

.os-finder th:first-child::after {
  content: "\00a0\25BE"; /* sort arrow on Name, as the Finder draws it */
}

.os-finder td {
  padding: 2px 8px;
  border-bottom: 1px solid #eeeeee;
  white-space: nowrap;
}

.os-finder-name img {
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 4px;
  vertical-align: middle;
  image-rendering: pixelated;
}

.os-finder tbody tr:nth-child(even) td {
  background: #f2f2f7;
}
