/* variables */
:root {
  --yellow: #ffa812;
  --blue: #219ebc;
  --text: #121212;
  --radius: 16px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  --border: 1px solid rgba(0, 0, 0, 0.08);
  --bg: #ffffff;
  --ink: #111111;
  --muted: #6b7280;
  --accent: #111111;
  --dot: 10px;
  --gap: 14px;
}
/* boilerplate styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "BenchNine", sans-serif;
  scroll-behavior: smooth;
}
img {
  max-width: 100%;
}
input,
textarea,
button {
  background-color: transparent;
  border: none;
  outline: none;
  &:focus {
    border: none;
    outline: none;
  }
}
a {
  text-decoration: none;
}
ul,
li {
  list-style-type: none;
}
/* Global Styles */
.flex {
  display: flex;
}
.align-center {
  align-items: center;
}
/* Hero Section */
.hero-section {
  background: url("./images/skyline.png");
  background-repeat: no-repeat;
  background-position: top;
  background-size: contain;
  padding-top: 60px;
  header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1270px;
    width: 100%;
    margin: auto;
    .logo-section {
      display: flex;
      align-items: center;
      gap: 1rem;
      .logo {
        /* width: 50px; */
        width: 60px;
        img {
          object-fit: contain;
        }
      }
      h1.title {
        color: var(--yellow);
        /* font-size: 24px; */
        font-size: 36px;
        line-height: 130%;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 3.6px;
        span {
          letter-spacing: 0;
          font-weight: 300;
        }
      }
    }
    nav {
      width: 330px;
      ul {
        display: flex;
        align-items: center;
        justify-content: space-between;
        li {
          a {
            color: var(--blue);
            font-size: 24px;
            font-weight: 400;
            text-transform: uppercase;
          }
        }
      }
    }
  }
  section.about {
    text-align: center;
    max-width: 700px;
    width: 100%;
    margin: auto;
    padding: 0 20px;
    padding-top: 330px;
    h1 {
      color: var(--yellow);
      font-size: 89px;
      font-weight: 400;
      line-height: 120%;
      letter-spacing: 1px;
      text-transform: uppercase;
    }
    div.flex {
      font-size: 20px;
      font-weight: 300;
      letter-spacing: 4.2px;
      text-transform: uppercase;
      justify-content: center;
      padding: 4px 46px;
      gap: 10px;
    }
    .bio-section {
      font-size: 20px;
      letter-spacing: 1.2px;
      line-height: 34px;
      padding: 124px 0;
    }
  }
  .mobile-nav {
    display: none;
  }
}
main {
  max-width: 969px;
  width: 100%;
  margin: auto;
  padding: 20px 24px;
  .projects-start {
    border-bottom: 3px solid var(--blue);
    width: fit-content;
    margin: auto;
    &.end {
      border-top: 3px solid var(--blue);
      border-bottom: 0;
    }
    p {
      text-align: center;
      font-size: 20px;
      font-weight: 400;
      line-height: 34px;
      letter-spacing: 1.2px;
    }
  }
  .vertical-line {
    height: 465px;
    width: 3px;
    margin: auto;
    background-color: var(--blue);
  }
  .box {
    height: 396px;
    width: 100%;
    border-top: 3px solid var(--blue);
    position: relative;
    &.half {
      width: 50%;
    }
    &.half-right {
      width: 50%;
      margin-left: auto;
    }
    &.left {
      border-left: 3px solid var(--blue);
      text-align: left;
    }
    &.right {
      border-right: 3px solid var(--blue);
      text-align: right;
    }
    .project-preview {
      display: flex;
      align-items: start;
      gap: 20px;
      position: absolute;
      top: 50%;
      transform: translateY(-50%);
      cursor: pointer;
      .project-description {
        p.title {
          font-size: 32px;
          font-weight: 700;
        }
        p {
          font-size: 24px;
          font-weight: 400;
          text-transform: uppercase;
        }
      }
      &.zyra {
        left: -67px;
        .project-img {
          width: 130px;
        }
      }
      &.racktrack {
        right: -190px;
        .project-img {
          width: 365px;
        }
      }
      &.zine {
        left: -105px;
        .project-img {
          width: 211px;
        }
      }
      &.winelabel {
        right: -37px;
        .project-img {
          width: 73px;
        }
      }
      &.ferreira-house {
        left: -150px;
        .project-img {
          width: 300px;
        }
      }
      &.mchouse {
        right: -150px;
        .project-img {
          width: 300px;
        }
      }
    }
  }
  .quick-links {
    padding: 90px 0 160px 0;
    justify-content: center;
    gap: 90px;
    .link-box {
      max-width: 200px;
      width: 100%;
      text-align: center;
      p {
        text-transform: uppercase;
        color: var(--blue);
        font-size: 24px;
        margin-bottom: 8px;
        white-space: nowrap;
      }
    }
  }
}
footer {
  background-color: var(--blue);
  padding: 116px 0;
  .container {
    max-width: 1270px;
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1270px;
    width: 100%;
    margin: auto;
    padding: 0 24px;
    .logo-section {
      display: flex;
      align-items: center;
      gap: 1rem;
      .logo {
        /* width: 50px; */
        width: 60px;
        img {
          object-fit: contain;
        }
      }
      h1.title {
        color: var(--yellow);
        /* font-size: 24px; */
        font-size: 36px;
        line-height: 130%;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 3.6px;
        span {
          letter-spacing: 0;
          font-weight: 300;
        }
      }
    }
    nav {
      width: 330px;
      ul {
        display: flex;
        align-items: center;
        justify-content: space-between;
        li {
          a {
            color: var(--yellow);
            font-size: 24px;
            font-weight: 400;
            text-transform: uppercase;
          }
        }
      }
    }
  }
}
@media only screen and (max-width: 768px) {
  .hero-section {
    background-size: 1510px 366px;
    background-position: left top;
    padding: 60px 24px 0 24px;
    header {
      .logo-section {
        .logo {
          width: 50px;
        }
        h1.title {
          font-size: 24px;
        }
      }
    }
  }
  main {
    max-width: 385px;
  }
  footer {
    .container {
      .logo-section {
        .logo {
          width: 50px;
        }
        h1.title {
          font-size: 24px;
        }
      }
    }
  }
}

@media only screen and (max-width: 600px) {
  .hero-section {
    background-size: 865px 268px;
    section.about {
      padding-top: 150px;
      h1 {
        font-size: 70px;
        span {
          display: block;
        }
      }
    }
    header {
      nav {
        display: none;
      }
      .mobile-nav {
        display: block;
        i {
          color: var(--blue);
        }
      }
    }
  }
  main {
    max-width: 205px;
    .vertical-line {
      height: 120px;
    }
    .projects-start {
      p {
        white-space: nowrap;
      }
    }
    .box {
      height: 260px;
      &.half-right {
        height: 120px;
      }
      .project-preview {
        .project-description {
          p {
            white-space: nowrap;
          }
        }
        &.zyra {
          left: -47px;
          .project-img {
            width: 90px;
            img {
              object-fit: contain;
              max-height: 100%;
            }
          }
        }
        &.racktrack {
          right: -110px;
          .project-img {
            width: 228px;
          }
        }
        &.zine {
          left: -75px;
          .project-img {
            width: 130px;
          }
        }
        &.ferreira-house {
          left: -96px;
          .project-img {
            width: 160px;
          }
        }
        &.mchouse {
          right: -77px;
          .project-img {
            width: 160px;
          }
        }
        &.winelabel {
          right: -28px;
          .project-img {
            width: 62px;
            height: 200px;
            img {
              object-fit: contain;
              max-height: 100%;
            }
          }
        }
      }
    }
  }
  .quick-links {
    flex-direction: column;
    gap: 32px !important;
    padding-bottom: 50px !important;
  }
  .plus {
    display: none;
  }
  .about {
    .flex {
      flex-direction: column;
    }
  }
  footer {
    padding: 60px 0;
    .container {
      flex-direction: column-reverse;
      gap: 24px;
      nav {
        width: 70%;
      }
    }
  }
}

/* modal styling */
.modal {
  display: none;
}
.modal.open {
  display: block;
}
.carousel-zine {
  position: fixed;
  max-width: initial;
  z-index: 2;
  top: 5vh;
  bottom: 5vh;
  left: 15vw;
  right: 15vw;
  background-color: #c5c5c5;
  .carousel__head {
    padding: 12px 24px 0 24px;
  }
}
.carousel {
  border: var(--border);
  padding: 18px;
  position: absolute;
  top: 0;
  background-color: #eeeeee;
  border-radius: 12px;
  transform: translateX(217px);
  z-index: 9;
  max-width: 700px;
  box-shadow: 28px 28px 56px #727272, -28px -28px 56px #e3e3e3;

  &::after {
    content: "";
    display: block;
    position: absolute;
    left: -19px;
    top: 68px;
    width: 0;
    height: 0;
    border-top: 20px solid transparent;
    border-bottom: 20px solid transparent;
    border-right: 20px solid #eeeeee;
  }
}
#racktrack-modal {
  .carousel {
    left: -10%;
    transform: none;
    &::after {
      left: initial;
      right: -19px;
      border-left: 20px solid #eeeeee;
      border-right: 0;
    }
  }
}

/* Header row */
.carousel__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.carousel__title {
  font-size: 2.5rem;
  font-weight: 650;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 2px;
}

/* Viewport masks overflow */
.carousel__viewport {
  overflow: hidden;
  border-radius: calc(var(--radius) - 6px);
  outline: none; /* we'll handle focus style below */
  position: relative;
}

.carousel__viewport:focus-visible {
  box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.2);
}

/* Track holds slides in a row */
.carousel__track {
  display: flex;
  gap: var(--gap);
  will-change: transform;
  transition: transform 300ms ease;
  padding: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .carousel__track {
    transition: none;
  }
}

/* Each slide */
.carousel__slide {
  flex: 0 0 100%;
  min-width: 0;
  border-radius: 14px;
  display: flex;
  gap: 24px;
  .prev-img {
    max-width: 230px;
    min-width: 230px;
  }
  .prev-text {
    display: flex;
    flex-direction: column;
    gap: 24px;
    h2 {
      letter-spacing: 1.5px;
      font-size: 22px;
      font-weight: normal;
      text-transform: uppercase;
      margin-bottom: 8px;
    }
    p,
    li {
      letter-spacing: 1px;
      font-weight: 300;
    }
    ul {
      padding-left: 1rem;
      li {
        list-style: circle;
      }
    }
  }
}
.primary-btn {
  background-color: #007b98;
  color: var(--yellow);
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 1.2px;
  padding: 8px 12px;
  border-radius: 12px;
  text-transform: uppercase;
  width: 100%;
  cursor: pointer;
  a {
    color: var(--yellow);
  }
}
/* Example content styling */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--muted);
  background: #f2f3f7;
  padding: 4px 10px;
  border-radius: 999px;
  width: fit-content;
}

.slide-title {
  font-size: 1.5rem;
  margin: 0;
}

.slide-text {
  margin: 0;
  color: #333;
  line-height: 1.5;
}

/* Buttons */
.carousel__btn {
  appearance: none;
  border: var(--border);
  background: #fff;
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  transition: transform 120ms ease, background 120ms ease, opacity 120ms ease;
}

.carousel__btn:hover {
  background: #f6f6f9;
  transform: translateY(-1px);
}

.carousel__btn:active {
  transform: translateY(0);
}

.carousel__btn[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.carousel__controls {
  display: flex;
  gap: 8px;
}

/* Dots */
.carousel__dots {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-top: 12px;
  flex-wrap: wrap;
}

.carousel__dot {
  width: var(--dot);
  height: var(--dot);
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.15);
  background: #fff;
  cursor: pointer;
  padding: 0;
  transition: transform 120ms ease, background 120ms ease,
    border-color 120ms ease;
}

.carousel__dot:hover {
  transform: scale(1.08);
}

.carousel__dot[aria-current="true"] {
  background: var(--accent);
  border-color: var(--accent);
}

/* Optional: make it 2-up on wider screens */
@media (min-width: 820px) {
  .carousel[data-slides-per-view="2"] .carousel__slide {
    flex-basis: calc(50% - (var(--gap) / 2));
  }
}

/* Optional: make it 3-up on very wide screens */
@media (min-width: 1100px) {
  .carousel[data-slides-per-view="3"] .carousel__slide {
    flex-basis: calc(33.333% - (2 * var(--gap) / 3));
  }
}

.image-gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 16px;
  .img-slide {
    width: 90px;
    transition: transform 300ms cubic-bezier(0.2, 0.8, 0.2, 1),
      filter 300ms cubic-bezier(0.2, 0.8, 0.2, 1),
      opacity 300ms cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform;
    transform: scale(1);
    transform-origin: top left;

    &.multi-line:nth-last-of-type(-n + 4) {
      transform-origin: bottom left;
    }

    img {
      height: 100%;
      width: 100%;
      object-fit: contain;
    }

    &:hover {
      transform: scale(2);
      filter: saturate(2);
      z-index: 2;
      background-color: white;
      box-shadow: 0 0 4px 10px #c4c4c411;
    }
  }

  &:hover .img-slide {
    filter: saturate(0.9);
    opacity: 0.55;
  }

  &:hover .img-slide:hover {
    filter: saturate(2);
    opacity: 1;
  }

  &:hover .img-slide:not(:hover) {
    filter: blur(2px) saturate(0.9);
  }
}
.backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
}
.magazine {
  width: 100%;
  height: calc(100% - 67px);
  background-color: rgb(226, 127, 127);
  display: flex;
  justify-content: center;
}

/* Left-side page image (front) */
.book-page,
.book-page-2 {
  position: relative;
  max-width: 100%;
  min-height: 100%;
  min-width: 50%;

  img {
    max-height: 100%;
    width: 100%;
    object-fit: contain;
    position: absolute;
    inset: 0;
    transition: transform 500ms cubic-bezier(0.2, 0.8, 0.2, 1);
    backface-visibility: hidden;
  }
}

/* Default state for left/front page */
.book-page {
  img {
    transform: rotateY(0deg);
    transform-origin: left;
  }

  img.flip {
    transform: rotateY(90deg);
  }
}

/* Default state for right/back page */
.book-page-2 {
  img {
    transform: rotateY(90deg);
    transform-origin: right;
  }

  img.flipback {
    transform: rotateY(0deg);
  }
}
