:root {
  --backgroundColour: #ccccff86;
  --mainColour: #7e7eff;
  /* Hamburger menu variables */
  --barWidth: 1.2cm;
  --barHeight: 0.16cm;
  --hamburgerGap: 0.2cm;
  --animationTiming: 200ms ease-in-out;
  --hamburgerHeight: calc(var(--barHeight) * 3 + var(--hamburgerGap) * 2);
}
/* Imported fonts */
@font-face {
  font-family: "cooperBold";
  src: url(../Fonts/Cooper-ttf/Cooper-Bold.ttf) format("truetype");
}
@font-face {
  font-family: "cooperBlack";
  src: url(../Fonts/Cooper-ttf/Cooper-Black.ttf) format("truetype");
}
@font-face {
  font-family: "cooperMedium";
  src: url(../Fonts/Cooper-ttf/Cooper-Medium.ttf) format("truetype");
}
@font-face {
  font-family: "cooper";
  src: url(../Fonts/Cooper-ttf/Cooper-Regular.ttf) format("truetype");
}
@font-face {
  font-family: "cooperSemiBold";
  src: url(../Fonts/Cooper-ttf/Cooper-SemiBold.ttf) format("truetype");
}

/* Hide hamburger menu on desktop */
@media (orientation: landscape) {
  .hamburgerDiv {
    display: none;
  }
  .sideNav {
    display: none;
  }
  /* Hide view more button (in reviews section) */
  .dots {
    display: none;
  }
  .readMoreBtn {
    display: none;
  }
  /* Hide mobile version of smarthail links */
  .smarthailLinksMobile {
    display: none;
  }
}

html {
  background: url("images/bg.jpg") no-repeat center fixed;
  background-size: cover;
}
body {
  font: 0.75cm Helvetica;
  margin: 0;
}

.headerBG {
  width: 100%;
  height: 3.5cm;
  position: absolute;
  z-index: -1;
}

.titleBox {
  background-color: #7984ffbd;
  backdrop-filter: blur(3px);
  display: flex;
  justify-content: center;
  align-items: center;
}
.titleText {
  width: 100%;
  color: #000000;
  display: flex;
  font-size: 0.6cm;
  align-items: center;
}
.logoImage {
  height: 2.5cm;
  padding: 0.5cm;
  margin-left: 5vw;
  margin-right: 7vw;
}
.footerBox {
  display: flex;
  flex-direction: row;
  background-color: #ffd186;
  justify-content: space-evenly;
  height: auto;
}
.footerBoxChild {
  display: flex;
  flex-direction: column;
  width: fit-content;
  margin-top: 0.15cm;
}
.footerText {
  margin: 0;
  color: black;
}
.smarthailImage {
  width: 7cm;
}
.divMain {
  display: flex;
  flex-direction: column;
}
.smarthailContainer {
  align-self: center;
  display: flex;
  flex-direction: row;
  width: 70vw;
  justify-content: space-between;
}
.grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
}
.smarthailLinks {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: fit-content;
}
.subtitle {
  font-family: "cooperBold";
  text-align: center;
  font-size: 1.2cm;
  width: 100%;
  margin-bottom: 1cm;
}
.text {
  max-width: 12cm;
  text-align: left;
  font-size: 0.75cm;
  border-radius: 0.2cm;
  font-weight: bolder;
  margin-left: 0.2cm;
  margin-right: 0.2cm;
}
.secondaryText {
  font-weight: 0;
}
.secondaryTextTitle {
  font-weight: bold;
}
.storeLink {
  width: 6.5cm;
}

.textDiv {
  height: fit-content;
  min-width: fit-content;
  width: 15cm;
  max-width: 100%;
  text-align: center;
  margin-bottom: 3cm;
  font-family: "cooperSemiBold";
}
.jobPostingTitle {
  font-weight: bold;
  font-size: 1cm;
  margin: 0;
}
.jobPostingText {
  font-weight: bold;
  font-size: 0.75cm;
  margin-top: 0.3cm;
  margin-bottom: 0.2cm;
}
.jobPosting {
  align-self: center;
  width: 100vw;
  margin-bottom: 0.5cm;
  position: relative;
  text-align: center;
  left: 0;
  text-align: center;
  background-color: red;
  color: white;
}

@media (orientation: portrait) {
  .jobPosting {
    width: 100vw;
    position: relative;
    text-align: center;
  }
  .jobPostingText {
    font-weight: bold;
  }
}
/* --- Reviews --- */
.customerReviewsIntro {
  margin-left: 0.5cm;
  font-weight: bold;
  font-size: 0.8cm;
  text-decoration: underline;
  text-decoration-thickness: 0.1cm;
}

.reviewsBlock {
  position: relative;
  width: 70vw;
  margin: 0 auto;
  margin-top: 1cm;
  margin-bottom: 1cm;
  box-sizing: border-box;
  padding: 0.75rem;
  background-color: rgba(255, 255, 255, 0.491);
  border-radius: 0.5rem;
}

.reviewsScroller {
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  width: 100%;
  padding-bottom: 0.5rem; /* avoid clipping card shadows */
}

.reviewsRow {
  display: flex;
  gap: 1rem;
}

.reviewCard {
  flex: 0 0 auto;
  scroll-snap-align: start;
  width: clamp(260px, 80vw, 420px);
  box-sizing: border-box;
  background: #ffffff00;
  border: 0.1rem solid black;
  border-radius: 0.5rem;
  padding: 1rem;
}

.reviewStars {
  font-size: 0.7cm;
  line-height: 1;
  letter-spacing: 0.1rem;
}

.reviewText {
  margin: 0.5rem 0 0.75rem 0;
  font-size: 0.5cm;
  line-height: 1.5;
}

.reviewMeta {
  margin: 0;
  font-size: 0.875rem;
  opacity: 0.8;
}

.reviewsNav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: 0.1rem solid #000;
  background: #fff;
  border-radius: 999px;
  width: 2.25rem;
  height: 2.25rem;
  display: grid;
  place-items: center;
  cursor: pointer;
  user-select: none;
}

.reviewsNav.prev {
  left: 0.25rem;
}
.reviewsNav.next {
  right: 0.25rem;
}

.reviewsNav:disabled {
  opacity: 0.4;
  cursor: default;
}

/* Show swipe, hide arrows on small phones */
@media (max-width: 600px) {
  .reviewsNav {
    display: none;
  }
}

.reviewsScroller::-webkit-scrollbar {
  height: 8px;
}
.reviewsScroller::-webkit-scrollbar-thumb {
  background: #bbb;
  border-radius: 4px;
}
.reviewsScroller::-webkit-scrollbar-track {
  background: transparent;
}

@media (prefers-reduced-motion: reduce) {
  .reviewsScroller {
    scroll-behavior: auto;
  }
}

/* Show QRcode when landscape */
@media (orientation: landscape) {
  .qrCode {
    height: 7cm;
    width: 7cm;
    border: solid black;
    border-radius: 2cm;
    border-width: 0.2cm;
    margin-bottom: 0.5cm;
    background-image: url("images/qrCode.png");
    background-size: cover;
  }
}

/* --- Side panel layout --- */
.sideLayout {
  display: flex;
  gap: 1cm;
  align-items: flex-start;
  margin: 1rem auto;
  padding: 1rem;
  box-sizing: border-box;
}

.sidePanel {
  display: flex;
  gap: 4vw;
  padding: 1cm;
  border-radius: 0.35cm;
  margin: 0;
  align-items: center;
  /* background-image: linear-gradient(to bottom, #ffffff44, #ffffff00); */
}
.sidePanelMobile {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1cm;
  top: 0.5rem;
}

.sideLink {
  color: #000000;
  text-decoration: none;
  font-weight: 0;
}

.sideLink[aria-current="page"] {
  color: white;
  font-weight: bold;
}

.sideMain {
  background-image: linear-gradient(to bottom, #b8b8ff86, #ccccff86);
  backdrop-filter: blur(8px);
  overflow: auto;
}
.route {
  padding: 1cm;
}
.route[hidden] {
  display: none !important;
}

/* --- Fares section --- */
table {
  width: 100%;
  border: solid 0.1cm black;
  border-spacing: 0;
}
th,
td {
  border: solid 0.05cm black;
  padding: 0;
  padding-left: 0.2cm;
  padding-right: 0.2cm;
}

/* Phone Styling */
@media (orientation: portrait) {
  .logoImage {
    height: 2cm;
    padding: 0.2cm;
  }
  .headerBG {
    height: 2.4cm;
  }
  .route {
    padding: 0.25cm;
  }
  .smarthailImage {
    width: 3cm;
    margin-right: 0.5cm;
  }
  .smarthailContainer {
    flex-direction: column-reverse;
    align-items: center;
    width: 100%;
  }
  .smarthailLinks {
    display: none;
  }
  .smarthailLinksMobile {
    display: flex;
    flex-direction: row;
    width: fit-content;
  }
  .subtitle {
    font-size: 0.8cm;
    margin: 0;
  }
  .textDiv {
    font-size: 0.6cm;
    margin: 0;
    margin-top: 0.75cm;
  }
  .sideLink {
    margin-bottom: 0.5cm;
  }
  .text {
    max-width: 12cm;
    text-align: left;
    font-size: 0.55cm;
    border-radius: 0.2cm;
    font-weight: bolder;
    margin-left: 0.2cm;
    margin-right: 0.2cm;
  }
  .reviewsBlock {
    width: 90vw;
    margin: 0 auto;
    margin-top: 1cm;
    margin-bottom: 1cm;
    box-sizing: border-box;
  }
  .secondaryText {
    font-size: 0.55cm;
  }
  .secondaryTextTitle {
    font-size: 0.55cm;
  }
  table {
    font-size: 0.25cm;
  }
  .storeLink {
    width: 4cm;
  }
  .jobPostingTitle {
    font-weight: bold;
    font-size: 0.8cm;
    margin: 0;
  }
  .jobPostingText {
    font-weight: 0;
    font-size: 0.65cm;
  }
  .customerReviewsIntro {
    font-size: 0.65cm;
    text-decoration-thickness: 0.05cm;
  }
  .more {
    display: none;
  }
  .footerBox {
    flex-direction: column;
    align-items: center;
  }
  .footerBoxChild {
    margin-bottom: 0.2cm;
    margin-top: 0.2cm;
    width: 96%;
    border: solid black;
  }
  .footerText {
    font-size: 0.5cm;
  }
  .sidePanel {
    display: none;
  }
  .sideLayout {
    max-width: 100vw;
    width: 100vw;
    margin: 0;
    padding: 0;
  }

  /* Hamburger */

  .hamburgerDiv {
    height: fit-content;
    width: fit-content;
  }

  .hamburgerMenu {
    --hamburgerXWidth: calc(var(--hamburgerHeight) * 1.41421356237);
    --Banner-Link-Colour: rgb(0, 0, 0);

    display: flex;
    flex-direction: column;
    gap: var(--hamburgerGap);
    width: 1.2cm;
    position: relative;
    z-index: 2;
    cursor: pointer;
  }
  .hamburgerMenu:has(input:focus-visible)::before,
  .hamburgerMenu:has(input:focus-visible)::after,
  .hamburgerMenu input:focus-visible {
    border: 1px solid var(--Banner-Link-Colour);
    box-shadow: 0 0 0 1px var(--Banner-Link-Colour);
  }

  .hamburgerMenu::before,
  .hamburgerMenu::after,
  .hamburgerMenu input {
    content: "";
    width: var(--barWidth);
    height: var(--barHeight);
    background-color: var(--Banner-Link-Colour);
    border-radius: 9999px;
    transform-origin: left center;
    transition: opacity var(--animationTiming), width var(--animationTiming),
      rotate var(--animationTiming), translate var(--animationTiming),
      background-color var(--animationTiming);
  }

  .hamburgerMenu input {
    appearance: none;
    padding: 0;
    margin: 0;
    outline: none;
    pointer-events: none;
  }

  .hamburgerMenu:has(input:checked)::before {
    rotate: 45deg;
    width: var(--hamburgerXWidth);
    translate: 0 calc(var(--barHeight) / -2);
  }

  .hamburgerMenu:has(input:checked)::after {
    rotate: -45deg;
    width: var(--hamburgerXWidth);
    translate: 0 calc(var(--barHeight) / 2);
  }

  .hamburgerMenu input:checked {
    opacity: 0;
    width: 0;
  }

  .sideNav {
    display: flex;
    flex-direction: column;
    justify-content: start;
    height: 100%;
    width: 0;
    max-width: 100%;
    position: fixed;
    z-index: 1;
    top: 0;
    right: 0;
    background-color: var(--mainColour);
    overflow-x: hidden;
    transition: 0.5s;
    padding-top: 2cm;
  }

  .buttonMobile {
    display: flex;
    cursor: pointer;
    position: absolute;
    top: 0.76cm;
    right: 0.75cm;
    height: fit-content;
    flex-direction: row-reverse;
    border: none;
  }
}
