@font-face {
  font-family:Roboto;
  src:url('../assets/fonts/roboto-400.ttf') format('truetype');
  font-style:normal;
  font-weight:400;
  font-display:swap
}

@font-face {
  font-family:Roboto;
  src:url('../assets/fonts/roboto-500.ttf') format('truetype');
  font-style:normal;
  font-weight:500;
  font-display:swap
}

@font-face {
  font-family:Roboto;
  src:url('../assets/fonts/roboto-900.ttf') format('truetype');
  font-style:normal;
  font-weight:900;
  font-display:swap
}

:root {
  font-family:Roboto,Arial,Helvetica,sans-serif;
  color:#222;
  background:#fff;
  font-synthesis:none;
  color-scheme:light
}

* {
  box-sizing:border-box
}

body {
  margin:0;
  min-width:280px
}

button,input {
  font:inherit
}

button {
  cursor:pointer
}

button:disabled {
  cursor:wait
}

button:focus-visible {
  outline:2px solid #1a73e8;
  outline-offset:3px
}

[hidden] {
  display:none!important
}

.stage {
  min-height:100svh;
  display:grid;
  place-items:center;
  padding:40px 12px 90px
}

.widget {
  width:304px;
  height:78px;
  border:1px solid #d3d3d3;
  border-radius:3px;
  background:#fafafa;
  box-shadow:0 1px 4px #00000012;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 11px 0 12px;
  user-select:none
}

.checkbox-trigger {
  border:0;
  background:transparent;
  display:flex;
  align-items:center;
  gap:12px;
  padding:0;
  height:60px;
  color:#000
}

.checkbox-label {
  font-size:14px;
  white-space:nowrap
}

.checkbox {
  width:28px;
  height:28px;
  border:2px solid #c1c1c1;
  border-radius:2px;
  background:white;
  display:block
}

.checkbox-trigger:hover .checkbox {
  border-color:#a0a0a0
}

.checkbox.loading {
  border-radius:50%;
  width:28px;
  height:28px;
  border:3px solid #e6e6e6;
  border-top-color:#4285f4;
  animation:spin .8s linear infinite
}

.branding {
  display:flex;
  flex-direction:column;
  align-items:center;
  width:65px;
  padding-top:3px
}

.branding img {
  margin-bottom:3px
}

.brand {
  font-size:10px;
  color:#555;
  line-height:12px
}

.legal {
  font-size:8px;
  color:#555;
  line-height:12px;
  white-space:nowrap
}

.legal button {
  border:0;
  background:none;
  color:inherit;
  padding:0;
  font-size:inherit
}

.legal button:hover {
  text-decoration:underline
}

.page-footer {
  position:fixed;
  bottom:22px;
  left:12px;
  right:12px;
  text-align:center;
  font-size:11px;
  line-height:16px;
  color:#9b9b9b;
  pointer-events:none
}

.challenge-layer {
  position:fixed;
  inset:0;
  display:flex;
  justify-content:center;
  align-items:center;
  padding:14px 10px;
  z-index:2;
  background:#fff
}

.challenge {
  width:400px;
  max-width:100%;
  background:white;
  border:1px solid #ccc;
  box-shadow:0 2px 10px #0003;
  padding:7px 7px 0;
  max-height:calc(100svh - 28px);
  overflow:auto;
  animation:appear .12s ease-out
}

.challenge-header {
  height:113px;
  background:#1a73e8;
  color:white;
  padding:24px;
  margin-bottom:7px
}

.prompt {
  font-size:16px;
  line-height:20px
}

h1 {
  font-size:28px;
  line-height:33px;
  margin:0 0 4px;
  font-weight:900
}

.challenge-header p {
  font-size:14px;
  line-height:18px;
  margin:0;
  min-height:18px
}

.grid {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:4px
}

.tile {
  position:relative;
  aspect-ratio:1;
  border:0;
  margin:0;
  padding:0;
  background:white;
  overflow:hidden;
  isolation:isolate;
  transition:opacity .1s ease;
  -webkit-tap-highlight-color:transparent
}

.tile-photo {
  position:absolute;
  inset:0;
  background-size:100% 100%;
  background-position:center;
  background-repeat:no-repeat;
  transition:transform .1s ease;
  transform:scale(1)
}

.tile.selected {
  background:white
}

.tile.selected .tile-photo {
  transform:scale(.8)
}

.tile-check {
  position:absolute;
  left:0;
  top:0;
  width:32px;
  height:32px;
  background:url('../assets/icons/selection-check.png') no-repeat center;
  background-size:32px 32px;
  display:none
}

.tile-check svg {
  width:16px;
  height:16px;
  stroke:white;
  stroke-width:2.5;
  fill:none
}

.tile.selected .tile-check {
  display:block
}

.tile:focus-visible {
  outline:3px solid #1a73e8;
  outline-offset:-3px;
  z-index:1
}

.error {
  font-size:14px;
  line-height:19px;
  color:#d93025;
  text-align:center;
  padding:7px 0;
  margin:0
}

.challenge-footer {
  min-height:71px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-top:1px solid #dfdfdf;
  margin:8px -7px 0;
  padding:12px 12px 12px 9px;
  gap:12px
}

.tools {
  display:flex;
  align-items:center;
  gap:5px
}

.icon-button {
  width:35px;
  height:35px;
  display:grid;
  place-items:center;
  border:0;
  background:transparent;
  color:#737373;
  padding:7px;
  border-radius:2px
}

.icon-button:hover {
  background:#f2f2f2;
  color:#333
}

.icon-button svg {
  width:23px;
  height:23px;
  fill:none;
  stroke:currentColor;
  stroke-width:2.5;
  stroke-linecap:round;
  stroke-linejoin:round
}

.verify {
  height:42px;
  min-width:100px;
  border:0;
  border-radius:2px;
  background:#1a73e8;
  color:#fff;
  font-size:14px;
  font-weight:500;
  padding:0 20px;
  transition:background .1s
}

.verify:hover {
  background:#185abc
}

.verify:disabled {
  background:rgba(73,143,225,.5)
}

.info-box {
  font-size:13px;
  line-height:1.5;
  padding:16px 14px 4px;
  color:#555
}

.info-box strong {
  font-weight:600
}

.info-box p {
  margin:8px 0
}

.audio-view {
  min-height:310px;
  padding:24px 18px;
  font-size:14px
}

.audio-view h2 {
  font-size:18px;
  font-weight:400;
  margin:0 0 26px
}

.audio-play {
  background:#eee;
  border:1px solid #ccc;
  border-radius:2px;
  padding:12px 24px;
  display:block;
  margin:0 auto 24px;
  color:#444;
  font-size:13px
}

.audio-view p {
  line-height:1.5
}

.audio-view label {
  display:block;
  margin:24px 0 8px;
  color:#555
}

.audio-view input {
  width:100%;
  padding:10px;
  border:1px solid #b9b9b9;
  border-radius:2px
}

.legal-dialog {
  width:360px;
  max-width:calc(100% - 32px);
  padding:24px;
  border:1px solid #ccc;
  border-radius:3px;
  box-shadow:0 3px 15px #0002;
  line-height:1.6;
  font-size:14px
}

.legal-dialog::backdrop {
  background:#0002
}

.legal-dialog h2 {
  font-size:20px;
  font-weight:400;
  margin:0
}

.legal-dialog .verify {
  float:right;
  margin-top:8px
}

.grid.split-grid {
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:2px;
  aspect-ratio:1
}

.split-grid .tile:focus-visible {
  outline-offset:-3px
}

@keyframes spin {
  to {
    transform:rotate(360deg)
  }
}

@keyframes appear {
  from {
    opacity:0;
    transform:translateY(4px)
  }
  to {
    opacity:1;
    transform:translateY(0)
  }
}

@media(max-height:650px) {
  .challenge-header {
    min-height:90px;
    padding:14px 22px 12px
  }
  .challenge {
    width:min(400px,calc(100svh - 175px))
  }
  .prompt {
    font-size:14px
  }
  h1 {
    font-size:25px;
    line-height:30px
  }
  .challenge-header p {
    font-size:12px
  }
  .challenge-footer {
    min-height:60px;
    padding-top:8px;
    padding-bottom:8px
  }
  .verify {
    height:38px
  }
  .page-footer {
    bottom:8px;
    font-size:10px
  }
}

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

.tile.dynamic-selected {
  opacity:.01;
  transition:opacity 2s ease
}

.tile.dynamic-selected .tile-check {
  display:block;
  width:60px;
  height:60px;
  background-size:60px 60px;
  left:50%;
  top:50%;
  margin-left:-30px;
  margin-top:-30px
}
