/* ==========================================================================
   Flip 7 — thème sombre unique, minimaliste
   ========================================================================== */

:root {
  color-scheme: dark;

  --bg: #0e0f13;
  --surface: #16181e;
  --surface-2: #1d2028;
  --surface-3: #262a35;
  --border: #2b303c;
  --border-strong: #3a4050;
  --text: #eceef3;
  --text-muted: #a0a7b8;
  --accent: #8ab0ff;
  --accent-strong: #a9c4ff;
  --accent-ink: #0b1120;
  --accent-soft: rgba(138, 176, 255, 0.14);
  --danger: #ff7b7b;
  --danger-soft: rgba(255, 123, 123, 0.12);
  --success: #5fd99a;
  --success-soft: rgba(95, 217, 154, 0.12);
  --frozen: #7fd0f0;
  --frozen-soft: rgba(127, 208, 240, 0.12);
  --warn: #f2c35e;

  --radius: 10px;
  --radius-lg: 14px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --topbar-h: 56px;
  --card-w: clamp(46px, 12.5vw, 64px);
  --card-sm-w: 30px;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  margin: 0 0 12px;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

h1 {
  font-size: 1.6rem;
}

h2 {
  font-size: 1rem;
  font-weight: 600;
}

p {
  margin: 0 0 12px;
}

[hidden] {
  display: none !important;
}

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

.small {
  font-size: 0.85rem;
}

.center {
  text-align: center;
}

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

#main:focus,
[tabindex="-1"]:focus {
  outline: none;
}

.skip-link {
  position: absolute;
  left: 8px;
  top: -48px;
  z-index: 100;
  padding: 8px 12px;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 600;
}

.skip-link:focus {
  top: 8px;
}

/* --------------------------------------------------------------------------
   Contrôles
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.15s, border-color 0.15s, opacity 0.15s;
}

.btn:hover:not(:disabled) {
  background: var(--surface-3);
}

.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-primary {
  border-color: transparent;
  background: var(--accent);
  color: var(--accent-ink);
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent-strong);
}

.btn-ghost {
  border-color: transparent;
  background: transparent;
}

.btn-danger {
  border-color: transparent;
  background: transparent;
  color: var(--danger);
}

.btn-danger:hover:not(:disabled) {
  background: var(--danger-soft);
}

.btn-sm {
  padding: 0 12px;
  font-size: 0.9rem;
}

.btn-lg {
  min-height: 56px;
  font-size: 1.1rem;
}

.btn-block {
  width: 100%;
}

input[type="text"],
select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

input[type="text"]::placeholder {
  color: #6e7586;
}

input[type="text"]:focus,
select:focus {
  border-color: var(--accent);
}

.input-code {
  text-transform: uppercase;
  letter-spacing: 0.3em;
  font-weight: 600;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label {
  font-weight: 600;
}

.check {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  cursor: pointer;
}

.check input {
  width: 20px;
  height: 20px;
  accent-color: var(--accent);
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 1px 8px;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.chip-accent {
  border-color: var(--accent);
  color: var(--accent);
}

.chip-danger,
.status-busted {
  border-color: var(--danger);
  color: var(--danger);
}

.chip-success,
.status-flip7 {
  border-color: var(--success);
  color: var(--success);
}

.status-frozen {
  border-color: var(--frozen);
  color: var(--frozen);
  border-style: dashed;
}

.status-stayed {
  border-color: var(--text-muted);
  color: var(--text);
}

.status-active {
  border-color: var(--accent);
  color: var(--accent);
}

.status-left {
  border-style: dotted;
}

.chip-offline {
  border-color: var(--warn);
  color: var(--warn);
  border-style: dashed;
}

.notice {
  padding: 10px 14px;
  border: 1px solid var(--border-strong);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius);
  background: var(--surface);
}

.form-error {
  min-height: 1.5em;
  margin-top: 14px;
  color: var(--danger);
}

.card-surface {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

/* --------------------------------------------------------------------------
   Barre du haut
   -------------------------------------------------------------------------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 4px;
  height: var(--topbar-h);
  padding: 0 8px 0 16px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.brand {
  font-weight: 700;
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.topbar .btn {
  white-space: nowrap;
}

.topbar-room {
  margin-left: 10px;
  white-space: nowrap;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.05em;
}

.topbar-spacer {
  flex: 1;
}

.conn-banner {
  position: sticky;
  top: var(--topbar-h);
  z-index: 19;
  padding: 8px 16px;
  border-bottom: 1px solid var(--warn);
  background: #2a2414;
  color: var(--warn);
  font-size: 0.9rem;
  text-align: center;
}

/* --------------------------------------------------------------------------
   Écrans
   -------------------------------------------------------------------------- */

.screen {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px;
}

.home-panel {
  max-width: 400px;
  margin: 6vh auto 0;
}

.home-title {
  font-size: 2.6rem;
  font-weight: 800;
  letter-spacing: -0.04em;
}

.home-tagline {
  margin-bottom: 28px;
}

.resume-btn {
  margin-bottom: 22px;
}

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

.lobby-panel {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 560px;
  margin: 0 auto;
}

.invite {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.invite-code {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.code {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  font-variant-numeric: tabular-nums;
}

.invite-row {
  display: flex;
  gap: 8px;
}

.invite-row input {
  flex: 1;
  min-width: 0;
  color: var(--text-muted);
}

.lobby-players {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lobby-players li {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 4px 0 12px;
  border-radius: var(--radius);
  background: var(--surface-2);
}

.lobby-players .name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lobby-players .grow {
  flex: 1;
}

.settings {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* --------------------------------------------------------------------------
   Plateau
   -------------------------------------------------------------------------- */

.screen-game {
  padding-bottom: 0;
}

.game-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 20px;
}

.board {
  display: flex;
  flex-direction: column;
  gap: 14px;
  /* Hauteur d'écran moins la barre du haut et la marge haute de l'écran. */
  min-height: calc(100vh - var(--topbar-h) - 24px);
  min-height: calc(100dvh - var(--topbar-h) - 24px);
}

.game-info {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
}

.turn-banner {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.turn-banner.is-me {
  color: var(--accent);
}

.game-meta {
  margin: 0;
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}

.opponents {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.player {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color 0.2s;
}

.player.is-turn {
  border-color: var(--accent);
  border-left-color: var(--accent);
  background: linear-gradient(var(--accent-soft), var(--accent-soft)), var(--surface);
}

.player.is-busted {
  border-left-color: var(--danger);
}

.player.is-flip7 {
  border-color: var(--success);
  border-left-color: var(--success);
}

.player.is-frozen {
  border-left-color: var(--frozen);
}

.player.is-out .mini-row {
  opacity: 0.6;
}

.player.is-left {
  opacity: 0.5;
}

.player-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.player-name {
  max-width: 10em;
  overflow: hidden;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.player-nums {
  margin-left: auto;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.player-nums strong {
  color: var(--text);
}

.turn-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.mini-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-height: calc(var(--card-sm-w) * 1.4);
}

.empty-row {
  color: var(--text-muted);
  font-size: 0.8rem;
  align-self: center;
}

.player-extra {
  margin-top: 6px;
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* Journal compact (mobile) */
.log-mini {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.log-mini li:first-child {
  color: var(--text);
}

/* Ma zone */
.me {
  position: sticky;
  bottom: 0;
  z-index: 5;
  margin: auto -16px 0;
  padding: 14px 16px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.me.is-turn {
  border-top: 2px solid var(--accent);
}

.me-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.me-who {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.me-who strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.me-scores {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-variant-numeric: tabular-nums;
  line-height: 1.3;
}

.me-round {
  font-size: 1.15rem;
  font-weight: 700;
}

.me-extra {
  min-height: 1.3em;
  margin-bottom: 8px;
  font-size: 0.85rem;
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-height: calc(var(--card-w) * 1.4);
  margin-bottom: 14px;
}

.actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* Volet latéral : scores + journal */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border-left: 1px solid var(--border);
  background: var(--surface);
}

.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sidebar-head h2 {
  margin: 0;
}

.scoreboard {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.score-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 8px;
  font-size: 0.9rem;
}

.score-line .who {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.score-line.is-me .who {
  font-weight: 700;
}

.score-line .pts {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.progress {
  grid-column: 1 / -1;
  height: 4px;
  overflow: hidden;
  border-radius: 2px;
  background: var(--surface-3);
}

.progress > span {
  display: block;
  width: var(--p, 0%);
  height: 100%;
  border-radius: 2px;
  background: var(--accent);
  transition: width 0.4s ease;
}

.score-line.is-leader .progress > span {
  background: var(--success);
}

.log {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 50vh;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
  font-size: 0.875rem;
}

.log li {
  padding-left: 10px;
  border-left: 2px solid var(--border);
  color: var(--text-muted);
}

.log li:first-child {
  color: var(--text);
}

.log .ev-danger {
  border-left-color: var(--danger);
}

.log .ev-success {
  border-left-color: var(--success);
}

.log .ev-round {
  border-left-color: var(--accent);
}

.ev-danger-text {
  color: var(--danger);
}

.backdrop {
  position: fixed;
  inset: 0;
  z-index: 29;
  background: rgba(0, 0, 0, 0.55);
}

/* Mobile : volet en tiroir */
@media (max-width: 999px) {
  .sidebar {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 30;
    width: min(360px, 88vw);
    overflow-y: auto;
    border-left: 1px solid var(--border-strong);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.25s ease, visibility 0s linear 0.25s;
  }

  .sidebar.open {
    transform: none;
    visibility: visible;
    transition: transform 0.25s ease;
  }

  .log {
    max-height: none;
  }
}

/* Bureau : volet toujours visible */
@media (min-width: 1000px) {
  .game-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
  }

  .sidebar {
    position: sticky;
    top: calc(var(--topbar-h) + 16px);
    align-self: start;
    max-height: calc(100vh - var(--topbar-h) - 32px);
    overflow-y: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
  }

  .sidebar-close,
  #btn-scores,
  .backdrop,
  .log-mini {
    display: none !important;
  }

  .me {
    margin: auto 0 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
  }

  .me.is-turn {
    border: 1px solid var(--accent);
  }

  .actions {
    max-width: 480px;
  }
}

/* --------------------------------------------------------------------------
   Cartes (rendu CSS pur)
   Familles distinguées par la forme ET une étiquette, pas seulement la couleur :
   - numéro      : bordure pleine fine, grand chiffre, coins arrondis discrets
   - modificateur: bordure en tirets + étiquette « Bonus »
   - action      : double bordure, coins plus arrondis + étiquette « Action »
   -------------------------------------------------------------------------- */

.card {
  --w: var(--card-w);
  --h: 220;
  position: relative;
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: var(--w);
  height: calc(var(--w) * 1.4);
  border-radius: 8px;
  font-weight: 800;
  line-height: 1;
  user-select: none;
}

.card-label {
  position: absolute;
  top: 5px;
  left: 0;
  right: 0;
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
  opacity: 0.8;
}

.card-corner {
  position: absolute;
  top: 4px;
  left: 6px;
  font-size: 0.65rem;
  font-weight: 700;
  opacity: 0.7;
}

.card-value {
  font-size: calc(var(--w) * 0.5);
  font-variant-numeric: tabular-nums;
}

.card-name {
  margin-top: 4px;
  padding: 0 2px;
  font-size: 0.55rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.1;
}

.card-glyph {
  font-size: calc(var(--w) * 0.36);
  font-weight: 800;
}

/* Numéros : teinte légère selon la valeur */
.card--num {
  border: 1px solid hsl(var(--h) 38% 42%);
  background: hsl(var(--h) 28% 17%);
  color: hsl(var(--h) 80% 90%);
}

.card--num[data-v="0"] { --h: 220; }
.card--num[data-v="1"] { --h: 200; }
.card--num[data-v="2"] { --h: 178; }
.card--num[data-v="3"] { --h: 155; }
.card--num[data-v="4"] { --h: 128; }
.card--num[data-v="5"] { --h: 95; }
.card--num[data-v="6"] { --h: 55; }
.card--num[data-v="7"] { --h: 35; }
.card--num[data-v="8"] { --h: 18; }
.card--num[data-v="9"] { --h: 352; }
.card--num[data-v="10"] { --h: 325; }
.card--num[data-v="11"] { --h: 290; }
.card--num[data-v="12"] { --h: 258; }

.card--mod {
  border: 2px dashed #8f97aa;
  background: var(--surface-2);
  color: var(--text);
}

.card--mod .card-value {
  font-size: calc(var(--w) * 0.36);
}

.card--mod.is-times {
  border-color: var(--warn);
  color: var(--warn);
}

.card--act {
  border: 4px double var(--accent);
  border-radius: 14px;
  background: var(--bg);
  color: var(--accent);
}

.card--act.is-freeze {
  border-color: var(--frozen);
  color: var(--frozen);
}

.card--act.is-secondChance {
  border-color: var(--success);
  color: var(--success);
}

/* Petites cartes (adversaires) */
.card--sm {
  --w: var(--card-sm-w);
  border-radius: 5px;
}

.card--sm.card--act {
  border-width: 3px;
  border-radius: 8px;
}

.card--sm .card-label,
.card--sm .card-name,
.card--sm .card-corner {
  display: none;
}

.card--sm .card-value {
  font-size: 0.85rem;
}

.card--sm.card--mod .card-value {
  font-size: 0.68rem;
}

.card--sm .card-glyph {
  font-size: 0.75rem;
}

.card.is-dup {
  outline: 2px solid var(--danger);
  outline-offset: 1px;
}

.row-sep {
  flex-basis: 100%;
  height: 0;
}

/* --------------------------------------------------------------------------
   Fenêtres
   -------------------------------------------------------------------------- */

dialog {
  width: min(560px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
}

dialog::backdrop {
  background: rgba(5, 6, 9, 0.7);
}

.dialog-body {
  padding: 20px;
}

.dialog-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 16px;
}

.target-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.target-btn {
  justify-content: space-between;
  width: 100%;
  min-height: 52px;
  text-align: left;
}

.target-btn .info {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.table-wrap {
  overflow-x: auto;
}

.round-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
}

.round-table th,
.round-table td {
  padding: 8px 6px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

.round-table th {
  color: var(--text-muted);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.round-table .num {
  text-align: right;
}

.round-table .tag {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
}

.round-table .tag-danger {
  color: var(--danger);
}

.round-table .tag-success {
  color: var(--success);
}

.round-table tr.is-me td:first-child {
  font-weight: 700;
}

.over-winner {
  font-size: 1.3rem;
  font-weight: 700;
}

.ranking {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
  counter-reset: rank;
}

.ranking li {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 0 12px;
  border-radius: var(--radius);
  background: var(--surface-2);
  counter-increment: rank;
}

.ranking li::before {
  content: counter(rank);
  width: 1.5em;
  color: var(--text-muted);
  font-weight: 700;
}

.ranking li:first-child {
  border: 1px solid var(--success);
}

.ranking .grow {
  flex: 1;
}

.ranking .pts {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.rules h3 {
  margin: 16px 0 6px;
  font-size: 0.95rem;
}

.rules ul {
  margin: 0;
  padding-left: 20px;
  color: var(--text-muted);
}

.rules li {
  margin-bottom: 6px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 50;
  max-width: calc(100vw - 32px);
  padding: 10px 16px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface-3);
  color: var(--text);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  transform: translateX(-50%);
}

.toast.is-danger {
  border-color: var(--danger);
}

.toast.is-success {
  border-color: var(--success);
  color: var(--success);
}

/* --------------------------------------------------------------------------
   Animations sobres
   -------------------------------------------------------------------------- */

@keyframes card-in {
  from {
    opacity: 0;
    transform: perspective(400px) rotateY(80deg) scale(0.92);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

@keyframes pop {
  0% { transform: scale(1); }
  50% { transform: scale(1.03); }
  100% { transform: scale(1); }
}

.card--new {
  animation: card-in 0.35s ease-out both;
}

.shake {
  animation: shake 0.4s ease-in-out;
}

.pop {
  animation: pop 0.5s ease-out;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

@media (min-width: 600px) {
  .screen {
    padding: 24px;
  }

  .me {
    margin-left: -24px;
    margin-right: -24px;
    padding-left: 24px;
    padding-right: 24px;
  }
}

@media (min-width: 1000px) {
  .me {
    margin: auto 0 16px;
  }
}
