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

body {
  margin: 0;
}

main {
  display: block;
}

h1 {
  font-size: 2em;
  margin: 0.67em 0;
}

hr {
  box-sizing: content-box;
  height: 0;
  overflow: visible;
}

pre {
  font-family: monospace, monospace;
  font-size: 1em;
}

a {
  background-color: transparent;
}

abbr[title] {
  border-bottom: none;
  text-decoration: underline;
  -webkit-text-decoration: underline dotted;
          text-decoration: underline dotted;
}

b, strong {
  font-weight: bolder;
}

code, kbd, samp {
  font-family: monospace, monospace;
  font-size: 1em;
}

small {
  font-size: 80%;
}

sub, sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

img {
  border-style: none;
}

button, input, optgroup, select, textarea {
  font-family: inherit;
  font-size: 100%;
  line-height: 1.15;
  margin: 0;
}

button, input {
  overflow: visible;
}

button, select {
  text-transform: none;
}

[type=button], [type=reset], [type=submit], button {
  -webkit-appearance: button;
}

[type=button]::-moz-focus-inner, [type=reset]::-moz-focus-inner, [type=submit]::-moz-focus-inner, button::-moz-focus-inner {
  border-style: none;
  padding: 0;
}

[type=button]:-moz-focusring, [type=reset]:-moz-focusring, [type=submit]:-moz-focusring, button:-moz-focusring {
  outline: 1px dotted ButtonText;
}

fieldset {
  padding: 0.35em 0.75em 0.625em;
}

legend {
  box-sizing: border-box;
  color: inherit;
  display: table;
  max-width: 100%;
  padding: 0;
  white-space: normal;
}

progress {
  vertical-align: baseline;
}

textarea {
  overflow: auto;
}

[type=checkbox], [type=radio] {
  box-sizing: border-box;
  padding: 0;
}

[type=number]::-webkit-inner-spin-button, [type=number]::-webkit-outer-spin-button {
  height: auto;
}

[type=search] {
  -webkit-appearance: textfield;
  outline-offset: -2px;
}

[type=search]::-webkit-search-decoration {
  -webkit-appearance: none;
}

::-webkit-file-upload-button {
  -webkit-appearance: button;
  font: inherit;
}

details {
  display: block;
}

summary {
  display: list-item;
}

template {
  display: none;
}

[hidden] {
  display: none;
}

html {
  background: #E5E5E5;
}

body {
  min-width: 320px;
  background: #fff;
  font: 16px/1.4 Georgia, serif;
  margin: 0 auto;
}

a {
  color: inherit;
  text-decoration: none;
}

address {
  font-style: normal;
}

button {
  background: transparent;
  padding: 0;
  border: none;
}

h1, h2, h3, h4, h5, h6 {
  margin: 0;
}

hr {
  margin: 0;
}

p {
  margin: 0;
}

ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.content {
  box-sizing: border-box;
  min-width: 1000px;
  padding: 15px;
}
.title {
  font-size: 40px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: #0066cc;
  margin-bottom: 20px;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, 32%);
  grid-auto-rows: minmax(233px, 380px);
  justify-content: center;
  gap: 12px;
}

.card {
  display: block;
  position: relative;
  line-height: 0;
  overflow: hidden;
}
.card:hover .card__img {
  transform: scale(1.2);
}
.card:hover .card__overlay {
  opacity: 1;
}

.card__img {
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  transform: scale(1);
  transition: transform 2s;
}

.card__overlay {
  display: flex;
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: absolute;
  top: 0;
  left: 0;
  line-height: 1.4;
  opacity: 0;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 10px;
  transition: opacity 0.3s;
}

.card__title {
  font-size: 24px;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #6db4f9;
  margin-bottom: 10px;
}

.card__description {
  font-size: 20px;
}

.explosion {
  display: none;
  min-width: 1023px;
  min-height: 600px;
  width: 100vw;
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  background: #fff;
  opacity: 0;
}
.explosion_opening {
  display: block;
  transition: none;
}
.explosion_opened {
  display: block;
}
.explosion_opened .explosion-actions {
  margin-top: 0;
}
.explosion_opened .explosion-description {
  width: 960px;
  padding-left: 50px;
  padding-right: 50px;
}
.explosion_closing {
  display: block;
}
.explosion__img {
  position: absolute;
  -o-object-fit: cover;
     object-fit: cover;
  transition: all 0.7s;
}

.explosion__close {
  cursor: pointer;
}
.explosion__close img {
  width: 50px;
  height: 50px;
}

.explosion-actions {
  display: flex;
  height: 350px;
  min-width: 60px;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  position: absolute;
  right: 24%;
  z-index: 3;
  margin-top: -700px;
  transition: margin-top 0.7s;
}

.explosion-nav {
  display: flex;
  min-width: 60px;
  flex-direction: column;
  align-items: center;
}

.explosion__btn {
  width: 50px;
  height: 50px;
  opacity: 1;
  background-color: transparent;
  background-repeat: no-repeat;
  line-height: 0;
  cursor: pointer;
  border: 3px solid #000;
  border-radius: 50%;
  transition: all 0.3s;
}
.explosion__btn:disabled {
  pointer-events: none;
  opacity: 0.3;
}
.explosion__btn_up {
  background-image: url("../img/icons/arrow-up.svg");
}
.explosion__btn_up:hover {
  background-color: #000;
  background-image: url("../img/icons/arrow-up-white.svg");
}
.explosion__btn_down {
  background-image: url("../img/icons/arrow-down.svg");
}
.explosion__btn_down:hover {
  background-color: #000;
  background-image: url("../img/icons/arrow-down-white.svg");
}

.explosion__counter {
  text-align: center;
  font-size: 24px;
  margin: 20px 0;
}

.explosion-description {
  box-sizing: border-box;
  width: 0%;
  position: absolute;
  bottom: 0;
  left: 0;
  z-index: 3;
  overflow: hidden;
  white-space: nowrap;
  background: #51346c;
  padding: 20px 0;
  transition: width 0.7s, padding-left 0.7s, padding-right 0.7s;
}

.explosion-description-wrapper {
  opacity: 1;
  transition: opacity 0.25s;
}

.explosion__title {
  font-size: 42px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  color: lightgoldenrodyellow;
}

.explosion__text {
  font-size: 24px;
  color: #c5fffc;
}