/* http://meyerweb.com/eric/tools/css/reset/
   v4.0 | 20180602
   License: none (public domain)
*/
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
main, menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}

article, aside, details, figcaption, figure,
footer, header, hgroup, main, menu, nav, section {
  display: block;
}

*[hidden] {
  display: none;
}

body {
  line-height: 1;
}

ol, ul {
  list-style: none;
}

blockquote, q {
  quotes: none;
}

blockquote:before, blockquote:after,
q:before, q:after {
  content: "";
  content: none;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

* {
  box-sizing: border-box;
}

.container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.panel {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.panel,
.panel .panel__inner {
  animation-duration: 10s;
  animation-iteration-count: infinite;
  animation-fill-mode: forwards;
  animation-timing-function: linear;
}

.panel:nth-child(1) .panel__content {
  background-color: #b95e82;
  animation: fade-1 3s linear alternate infinite;
}

.panel:nth-child(2) .panel__content {
  background-color: #54acc7;
  animation: fade-2 3s linear alternate infinite;
}

.panel:nth-child(3) .panel__content {
  background-color: #ada13e;
  animation: fade-3 3s linear alternate infinite;
}

.panel:nth-child(4) .panel__content {
  background-color: #173aff;
  animation: fade-4 3s linear alternate infinite;
}

@keyframes fade-1 {
  from { background-color: #b95e82; }
  to { background-color: #b95e52; }
}

@keyframes fade-2 {
  from { background-color: #54acc7; }
  to { background-color: #9db1fc; }
}

@keyframes fade-3 {
  from { background-color: #ada13e; }
  to { background-color: #5ea13e; }
}

@keyframes fade-4 {
  from { background-color: #173aff; }
  to { background-color: #9b3aff; }
}

.panel:nth-child(1),
.panel:nth-child(1) .panel__inner {
  transform-origin: top left;
}

.panel:nth-child(2),
.panel:nth-child(2) .panel__inner {
  transform-origin: top right;
}

.panel:nth-child(3),
.panel:nth-child(3) .panel__inner {
  transform-origin: bottom left;
}

.panel:nth-child(4),
.panel:nth-child(4) .panel__inner {
  transform-origin: bottom right;
}

.panel:nth-child(1) {
  animation-name: scale0outer;
}

.panel:nth-child(1) .panel__inner {
  animation-name: scale0inner;
}

.panel:nth-child(2) {
  animation-name: scale1outer;
}

.panel:nth-child(2) .panel__inner {
  animation-name: scale1inner;
}

.panel:nth-child(3) {
  animation-name: scale2outer;
}

.panel:nth-child(3) .panel__inner {
  animation-name: scale2inner;
}

.panel:nth-child(4) {
  animation-name: scale3outer;
}

.panel:nth-child(4) .panel__inner {
  animation-name: scale3inner;
}

.panel__inner {
  width: 100%;
  height: 100%;
}

.panel__content {
  width: 100%;
  height: 100%;
  padding: 10vw;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  font-family: sans-serif;
  font-size: 45px;
}

.panel__image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

@media screen and (max-width: 800px) {
  .panel__content {
    font-size: 28px;
  }
}
