/* pbutcher.uk */
/* Copyright Peter Butcher 2024 */

html,
body {
  margin: 0px;
  font-family: "Roboto", sans-serif;
  height: 100%;
}

body {
  background-image: url("../img/homepage-background.jpg");
  background-size: cover;
  background-attachment: fixed;
  background-position: center center;
  position: relative;
}

/* Cut out */

.cutout-img {
  position: absolute;
  z-index: 2;
  height: 95%;
  right: 3%;
  bottom: 0;
  animation: slide 2s ease-in-out forwards;
  animation-iteration-count: 1;
  animation-delay: 0.5s;
  opacity: 0;
}

/* Introduction */

.introduction {
  position: absolute;
  margin: 10vh 8vw;
  z-index: 3;
  box-sizing: border-box;
}

.introduction h1 {
  width: 34vw;
  font-size: 3.5vw;
  background: linear-gradient(to left, #f6cef7, #7f9fca);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  font-family: "Inter", "Roboto", sans-serif;
  margin-bottom: 2vw;
  animation: appear 1s ease-in-out forwards;
  animation-iteration-count: 1;
  animation-delay: 0.5s;
  opacity: 0;
}

.introduction p {
  color: #f0f0f0;
  font-weight: 100;
  font-size: 1.5vw;
  margin: 0.7vw 0vw;
  animation: appear 1s ease-in-out forwards;
  animation-iteration-count: 1;
  opacity: 0;
}

.introduction div p:nth-child(1) {
  animation-delay: 0.75s;
}

.introduction div p:nth-child(2) {
  animation-delay: 0.9s;
}

.introduction div p:nth-child(3) {
  animation-delay: 1.05s;
}

.introduction a {
  color: #f0f0f0;
  font-weight: 700;
  text-decoration: none;
}

.introduction a:hover {
  opacity: 0.75;
}

/* Links */

.links {
  margin-top: 2.5vw;
  display: flex;
  animation: appear 1s ease-in-out forwards;
  animation-iteration-count: 1;
  opacity: 0;
}

.links a {
  display: block;
  margin-right: 2.5vw;
  position: relative;
  animation: jolt 1s ease-in-out forwards;
  animation-iteration-count: 1;
  opacity: 0;
}

.links a:nth-child(1) {
  animation-delay: 1.2s;
}

.links a:nth-child(2) {
  animation-delay: 1.3s;
}

.links a:nth-child(3) {
  animation-delay: 1.4s;
}

.links a:nth-child(4) {
  animation-delay: 1.5s;
}

.links a:nth-child(5) {
  animation-delay: 1.6s;
}

.links a:nth-child(6) {
  animation-delay: 1.7s;
}

.links a:nth-child(7) {
  animation-delay: 1.8s;
}

.links a i:hover {
  opacity: 0.75;
}

.links a:last-child {
  margin-right: 0vw;
}

.links i {
  font-size: 2vw;
}

/* Main Navigation */

.main-navigation {
  margin-top: 2.5vw;
  font-size: 1.5vw;
  overflow: auto;
  animation: fadein 1s ease-in-out forwards;
  animation-iteration-count: 1;
  animation-delay: 1.95s;
  opacity: 0;
  word-spacing: 0.75em;
}

.main-navigation a {
  border: solid 0.2vw #ffffff;
  border-radius: 4px;
  font-weight: 500;
  padding: 1.25vw;
  margin-right: 1vw;
  text-transform: uppercase;
  display: inline-block;
  word-spacing: 0px;
}

.main-navigation a:hover {
  opacity: 1;
  background-color: rgba(255, 255, 255, 0.1);
}

.main-navigation a[disabled] {
  opacity: 0.25;
  border: none;
}

.main-navigation a[disabled]:hover {
  opacity: 0.25;
  background-color: transparent;
}

/* Affiliations */

.affiliations {
  position: absolute;
  bottom: 10vh;
  left: 8vw;
  display: flex;
  z-index: 3;
}

.affiliations a {
  display: flex;
  width: 12vw;
  height: 14vh;
  background-size: 100%;
  background-repeat: no-repeat;
  margin-right: 4vw;
  animation: rise 1s ease-in-out forwards;
  animation-iteration-count: 1;
  opacity: 0;
}

.affiliations a:nth-child(1) {
  animation-delay: 2.1s;
}

.affiliations a:nth-child(2) {
  animation-delay: 2.35s;
}

.affiliations a:nth-child(3) {
  animation-delay: 2.6s;
}

.affiliations a:last-child {
  margin-right: 0vw;
}

.affiliations a.affiliation-bu {
  background-image: url("../img/bu-white.png");
}

.affiliations a.affiliation-bu:hover {
  background-image: url("../img/bu-colour.png");
}

.affiliations a.affiliation-sbtv {
  background-image: url("../img/sbtv-white.png");
}

.affiliations a.affiliation-sbtv:hover {
  background-image: url("../img/sbtv-colour.png");
}

.affiliations a.affiliation-rr {
  background-image: url("../img/rr-white.png");
}

.affiliations a.affiliation-rr:hover {
  background-image: url("../img/rr-colour.png");
}

/* Animation */

@keyframes slide {
  0% {
    opacity: 0;
    transform: translateX(25px);
  }
  100% {
    opacity: 1;
    transform: translateX(0px);
  }
}

@keyframes appear {
  0% {
    opacity: 0;
    transform: translateY(-10px);
  }
  100% {
    opacity: 1;
    transform: translateY(0px);
  }
}

@keyframes fadein {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@keyframes jolt {
  0% {
    opacity: 0;
    transform: translateX(-10px);
  }
  100% {
    opacity: 1;
    transform: translateX(0px);
  }
}

@keyframes rise {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0px);
  }
}

/* Media */

@media (max-width: 900px) {
  .cutout-img {
    width: auto;
    height: 64%;
    left: 0px;
    right: 0px;
    margin: 0 auto;
  }

  .introduction {
    position: absolute;
    margin: 5vh auto;
    z-index: 3;
    width: 100%;
    padding: 0px 15px;
  }

  .introduction h1 {
    text-align: center;
    width: 100%;
    font-size: 2em;
    margin-bottom: 0.5em;
  }

  .introduction p {
    text-align: center;
    font-size: 1em;
    margin: 0.25em 0px;
  }

  /* Links */

  .links {
    margin-top: 1.5em;
    justify-content: center;
  }

  .links a {
    margin-right: 1.5em;
  }

  .links a:last-child {
    margin-right: 0px;
  }

  .links i {
    font-size: 1.25em;
  }

  /* Main Navigation */

  .main-navigation {
    margin-top: 1.5em;
    font-size: 1em;
    text-align: center;
  }

  .main-navigation a {
    border: solid 1px #ffffff;
    border-radius: 4px;
    font-weight: 400;
    padding: 0.8em;
    margin-right: 0px;
    text-transform: uppercase;
  }

  /* Affiliations */

  .affiliations {
    width: 100%;
    box-sizing: border-box;
    position: absolute;
    bottom: 1.5em;
    left: 0px;
    justify-content: center;
    display: flex;
    z-index: 3;
  }

  .affiliations a {
    display: flex;
    width: 8em;
    height: 3em;
    background-size: 100%;
    background-repeat: no-repeat;
    margin-right: 15px;
    margin-left: 15px;
    justify-content: space-between;
  }

  .affiliations a:last-child {
    margin-right: 30px;
  }
  .affiliations a:first-child {
    margin-left: 30px;
  }
}

@media (min-width: 900px) and (max-height: 600px) {
  .affiliations {
    display: none;
    /* left: auto; */
    /* right: 8vw; */
  }
}

@media (max-width: 900px) and (max-height: 750px) {
  .cutout-img {
    width: auto;
    height: 55%;
    left: 0px;
    right: 0px;
    margin: 0 auto;
  }
}

@media (max-width: 900px) and (max-height: 600px) {
  .cutout-img {
    width: auto;
    height: 45%;
    left: 0px;
    right: 0px;
    margin: 0 auto;
  }
}

@media (max-width: 900px) and (max-height: 500px) {
  .cutout-img {
    display: none;
  }
}
