/* =========================================================
   WEBMASTERG — CREATIONS
   ========================================================= */

.creations-page {

  width: 720px;

  max-width:
    calc(100% - 20px);

  margin:
    14px auto 0;

  color: #aaa;

}


/* =========================================================
   HIDDEN DURING INTRO
   ========================================================= */

.creations-hidden {

  opacity: 0;

  visibility: hidden;

  pointer-events: none;

}


.creations-visible {

  visibility: visible;

  pointer-events: auto;

  animation:
    creationsAppear
    .65s
    cubic-bezier(.22,.8,.25,1)
    forwards;

}


/* =========================================================
   PAGE HEADER
   ========================================================= */

.creations-header {

  margin-bottom: 10px;

  border:
    1px solid
    #343a3c;

  background:
    linear-gradient(
      180deg,
      #111415,
      #060707
    );

}


.creations-title {

  height: 17px;

  display: flex;

  align-items: center;

  justify-content: space-between;

  padding:
    0 8px;

  color: #d4d8d9;

  background:
    linear-gradient(
      90deg,
      #25292b,
      #080909
    );

  border-bottom:
    1px solid
    #3e4548;

  font-size: 7px;

  letter-spacing: 2px;

}


.creations-code {

  color: #555d60;

  font-size: 5px;

  letter-spacing: 1px;

}


.creations-intro {

  padding:
    12px 14px 14px;

}


.creations-intro-label {

  margin-bottom: 6px;

  color: #5d666a;

  font-size: 6px;

  letter-spacing: 1.5px;

}


.creations-intro p {

  max-width: 570px;

  margin: 0;

  color: #777d80;

  font-size: 8px;

  line-height: 1.7;

}


/* =========================================================
   CREATION CARD / PAD
   ========================================================= */

.creation-card {

  display: grid;

  grid-template-columns:
    300px 1fr;

  gap: 18px;

  min-height: 190px;

  margin-bottom: 10px;

  padding: 12px;

  border:
    1px solid
    #343a3c;

  background:
    linear-gradient(
      180deg,
      #111415,
      #060707
    );

  opacity: 0;

}


/* =========================================================
   IMAGE
   ========================================================= */

.creation-image {

  position: relative;

  width: 100%;

  height: 165px;

  overflow: hidden;

  border:
    1px solid
    #484e51;

  background: #020303;

}


.creation-image img {

  width: 100%;

  height: 100%;

  display: block;

  object-fit: cover;

  /* Imagen gris por defecto */

  filter:
    grayscale(100%)
    contrast(1.08);

  opacity: .75;

  transition:
    filter .4s ease,
    opacity .3s ease,
    transform .4s ease;

}


/* =========================================================
   PAD HOVER
   ========================================================= */

/*
   La imagen recupera el color cuando el cursor
   está EN CUALQUIER PARTE del .creation-card.
*/

.creation-card:hover .creation-image img {

  filter:
    grayscale(0%)
    contrast(1.08);

  opacity: 1;

  transform:
    scale(1.035);

}


.creation-index {

  position: absolute;

  top: 6px;

  right: 7px;

  color: #ddd;

  font-size: 6px;

  text-shadow:
    0 1px 4px
    #000;

}


/* =========================================================
   INFORMATION
   ========================================================= */

.creation-info {

  padding:
    4px 5px;

}


.creation-type {

  color: #555e62;

  font-size: 5px;

  letter-spacing: 2px;

}


.creation-info h1 {

  margin:
    8px 0 3px;

  color: #c7cbcc;

  font-size: 14px;

  font-weight: normal;

  letter-spacing: 2px;

}


.creation-date {

  margin-bottom: 12px;

  color: #4f575a;

  font-size: 6px;

  letter-spacing: 1.5px;

}


.creation-info p {

  max-width: 310px;

  margin:
    0 0 14px;

  color: #777e81;

  font-size: 8px;

  line-height: 1.7;

}


/* =========================================================
   LINKS / PADS
   ========================================================= */

.creation-links {

  display: flex;

  flex-wrap: wrap;

  gap: 5px;

}


.creation-links a {

  display: inline-flex;

  align-items: center;

  height: 19px;

  padding:
    0 8px;

  color: #858d90;

  text-decoration: none;

  border:
    1px solid
    #41484b;

  background:
    linear-gradient(
      #25292b,
      #080909
    );

  font-size: 6px;

  letter-spacing: 1px;

  transition:
    color .16s,
    border-color .16s,
    background .16s,
    transform .16s;

}


.creation-links a:hover {

  color: #fff;

  border-color: #777;

  background:
    linear-gradient(
      #303537,
      #0b0c0d
    );

  transform:
    translateY(-1px);

}


/* =========================================================
   END
   ========================================================= */

.creations-end {

  padding:
    16px 0 22px;

  text-align: center;

  color: #3e4649;

  font-size: 5px;

  letter-spacing: 2px;

}


/* =========================================================
   FOOTER
   ========================================================= */

.creations-footer {

  width: 720px;

  max-width:
    calc(100% - 20px);

  margin:
    0 auto 30px;

  text-align: center;

  color: #3e4548;

  font-size: 5px;

  letter-spacing: 2px;

  opacity: 0;

}


/* =========================================================
   PAGE REVEAL
   ========================================================= */

.creations-visible .creations-header {

  animation:
    creationFade
    .55s
    ease-out
    .05s
    both;

}


.creations-visible .creation-card {

  animation:
    creationCardAppear
    .65s
    cubic-bezier(.22,.8,.25,1)
    both;

}


.creations-visible
.creation-card:nth-of-type(2) {

  animation-delay:
    .22s;

}


.creations-visible
.creation-card:nth-of-type(3) {

  animation-delay:
    .38s;

}


.creations-visible
.creation-card:nth-of-type(4) {

  animation-delay:
    .54s;

}


.creations-visible
.creation-card:nth-of-type(5) {

  animation-delay:
    .70s;

}


.creations-visible .creations-end {

  animation:
    creationFade
    .5s
    ease-out
    1s
    both;

}


.creations-visible + .creations-footer {

  animation:
    creationFade
    .5s
    ease-out
    1.1s
    both;

}


/* =========================================================
   KEYFRAMES
   ========================================================= */

@keyframes creationsAppear {

  from {

    opacity: 0;

  }

  to {

    opacity: 1;

  }

}


@keyframes creationFade {

  from {

    opacity: 0;

    transform:
      translateY(10px);

  }

  to {

    opacity: 1;

    transform:
      translateY(0);

  }

}


@keyframes creationCardAppear {

  from {

    opacity: 0;

    transform:
      translateY(24px)
      scale(.975);

  }

  to {

    opacity: 1;

    transform:
      translateY(0)
      scale(1);

  }

}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 650px) {

  .creations-page {

    width:
      calc(100% - 20px);

  }


  .creation-card {

    grid-template-columns:
      1fr;

    gap: 12px;

  }


  .creation-image {

    height: 190px;

  }


  .creation-info p {

    max-width: none;

  }

}


@media (max-width: 420px) {

  .creations-page {

    margin-top: 10px;

  }


  .creation-image {

    height: 160px;

  }


  .creation-info h1 {

    font-size: 12px;

  }

}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

  .creations-visible,
  .creations-visible *,
  .creations-visible .creation-card,
  .creations-visible .creations-header,
  .creations-visible .creations-end,
  .creations-visible + .creations-footer {

    animation: none !important;

    opacity: 1;

    visibility: visible;

    transform: none;

  }

}