/* ==========================================================================
   reset.css — a small, modern CSS reset
   --------------------------------------------------------------------------
   Every browser ships slightly different default styling (margins on headings,
   list bullets, form font sizes...). This file flattens those differences so
   main.css starts from a predictable blank canvas.

   Keep this file boring. Game styling belongs in main.css.
   ========================================================================== */

/* Sizes include padding and border. Far easier to reason about than the
   default, where padding is added *on top of* the width you set. */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Remove default spacing browsers add to text elements. */
html,
body,
h1, h2, h3, h4, h5, h6,
p,
figure,
blockquote,
ul, ol, dl, dd {
  margin: 0;
  padding: 0;
}

/* Lists used for menus/HUDs should not show bullets. */
ul, ol {
  list-style: none;
}

/* Let the page fill the browser window. 100% height on both is needed
   because a child cannot be "100% tall" unless its parent has a height. */
html,
body {
  height: 100%;
}

body {
  /* Prevent iOS/Android from auto-inflating font sizes in landscape. */
  -webkit-text-size-adjust: 100%;
  /* Slightly smoother text on dark backgrounds. */
  -webkit-font-smoothing: antialiased;
}

/* Media should never overflow its container on small screens. */
img,
picture,
video,
canvas,
svg {
  display: block;
  max-width: 100%;
}

/* Form controls do not inherit fonts by default. Make them do so. */
input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

/* Buttons should feel like game buttons, not web page buttons. */
button {
  background: none;
  border: none;
  cursor: pointer;
  /* Removes the blue flash Android/iOS shows when tapping. */
  -webkit-tap-highlight-color: transparent;
}

/* The "hidden" HTML attribute must always win.
   Browsers hide [hidden] elements with a display:none rule of their own, but
   any class of ours that sets display (e.g. .hud { display: flex }) would
   quietly override it. !important keeps hidden meaning hidden. */
[hidden] {
  display: none !important;
}

/* Respect users who have asked their device for less motion. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
