@import url("https://fonts.googleapis.com/css2?family=Libre+Baskerville:ital,wght@0,400..700;1,400..700&family=Space+Grotesk:wght@300..700&display=swap");

:root {
  --blue: #1f5b73;
  --green: #93d929;
  --grey: #d2dee3;
  --yellow: #f29f05;
  --red: #d91111;
  --font1: "Space Grotesk", Helvetica;
  --font2: "Libre Baskerville", Georgia;
  --headsize: 32px;
  --parasize: 16px;
  --nav-height: 62px;
  --headsize-s: 28px;
  --parasize-s: 14px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  padding: var(--nav-height) 0 0 0;
  margin: 0;
}

h1 {
  font-family: var(--font1);
  font-size: var(--headsize);
  text-align: center;
  color: var(--blue);
}

p {
  font-family: var(--font2);
  font-size: var(--parasize);
  text-align: justify;
  line-height: 1.8;
}

a {
  font-family: var(--font2);
  font-size: var(--parasize);
  text-decoration: underline var(--blue) 3px;
  transition: all 0.4s;
}

a:hover {
  text-decoration-color: var(--green);
}

button {
  font-family: var(--font1);
  font-size: var(--parasize);
  color: white;
  /*background-color: var(--blue);*/
  background: linear-gradient(to right, var(--blue), var(--green));
  background-size: 600% 100%;
  background-position: left;
  padding: 5px 10px;
  border: none;
  border-radius: 5px;
  transition: all 0.6s;
  cursor: pointer;
}

button:hover {
  /*background-color: var(--green);*/
  background-position: right;
}

#ad_lb {
  width: 728px;
  height: 90px;
  background-image: url("ads/onplus1.png");
  background-size: cover;
  background-position: center;
}

#ad_mlb {
  width: 320px;
  height: 100px;
  background-image: url("ads/onplus2.png");
  background-size: cover;
  background-position: center;
}

#ad_sc {
  width: 160px;
  height: 600px;
  background-image: url("ads/trbox1.png");
  background-size: cover;
  background-position: center;
}

#ad_rect {
  width: 300px;
  height: 250px;
  background-image: url("ads/trbox2.png");
  background-size: cover;
  background-position: center;
}

#ad_lb,
#ad_mlb,
#ad_sc,
#ad_rect {
  cursor: pointer;
}

.green {
  color: var(--green);
}

.white {
  color: white;
}

#content {
  padding: 1rem;
  margin-top: 20px;
  margin-bottom: 20px;
}

#content p {
  margin-top: 20px;
  margin-left: 5px;
  margin-right: 5px;
}

#content,
.line {
  max-width: 1440px;
  margin-left: auto;
  margin-right: auto;
}

.line {
  background-color: var(--grey);
  height: 2px;
  margin-top: 2px;
  margin-bottom: 2px;
}

/* ===== NAVBAR STYLES ===== */

.navbar {
  background: var(--blue);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1001;
  height: var(--nav-height);
}

.navbar-brand .logo {
  display: block;
}

.logo-img {
  height: 30px;
  width: auto;
  display: block;
}

/* Right side icons */
.navbar-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

/* Search and Hamburger Icons */
.search-icon,
.hamburger {
  color: white;
  font-size: 1.25rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s;
}

.search-icon:hover,
.hamburger:hover {
  opacity: 0.8;
}

.hamburger.active {
  transform: rotate(0deg);
}

.nav-menu {
  position: fixed;
  top: 62px;
  right: -100%;
  width: 100%;
  max-width: 300px;
  height: calc(100vh - 62px);
  background: var(--blue);
  flex-direction: column;
  justify-content: flex-start;
  padding: 0.5rem 0;
  gap: 1rem;
  transition: right 0.3s ease;
  z-index: 998;
  list-style: none;
  margin: 0;
  box-shadow: -1px 10px 10px rgba(0, 0, 0, 0.1);
}

.nav-menu.active {
  left: auto;
  right: 0;
}

.nav-menu li {
  width: 100%;
  text-align: center;
}

.nav-menu a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  font-size: var(--parasize);
  display: block;
  padding: 0.44rem 1rem;
  transition: all 0.4s;
}

.nav-menu a:hover {
  text-decoration: underline var(--green) 3px;
}

.btn-list {
  background: var(--green);
  transition: all 0.6s;
}

.btn-list:hover {
  background: var(--blue);
  border: var(--green) 2px;
  color: var(--green);
}

.nav_ad_d,
.nav_ad_m {
  margin-left: auto;
  margin-right: auto;
}

.nav_ad_m {
  margin-top: 30%;
  margin-bottom: auto;
}

/* Footer */
.footer {
  display: flex;
  flex-direction: column;
  background-color: var(--grey);
  color: var(--blue);
  text-align: center;
  padding: 1.5rem 1.5rem 0 1.5rem;
  margin-top: 2rem;
  font-size: 0.85rem;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto; /* centers the content block */
  text-align: center;
}

.footer a {
  color: var(--blue);
  text-decoration: none;
  margin: 0 0.25rem;
}

.footer a:hover {
  color: var(--green);
}

.footer-content p {
  margin: 0.3rem;
  text-align: center;
}

.footer img {
  height: auto;
  width: 90vw;
  margin-bottom: 0;
}
/* Prevent body scroll when menu open */
body.menu-open {
  overflow: hidden;
}

.hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background-color: var(--blue);
}

/*====RESPONSIVE====*/
@media (max-width: 768px) {
  .navbar {
    padding: 1rem;
  }

  .logo-img {
    height: 32px;
  }

  .search-icon,
  .hamburger {
    font-size: 1.3rem;
  }

  .navbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 0;
    padding: 0;
  }

  .nav-menu {
    max-width: 100%;
  }

  .nav_ad_d {
    display: none;
  }

  .about_ad_d,
  .hero_ad_d {
    display: none;
  }
}

/* Condition colors | product & marketplace */
.condition-pre-owned {
  color: var(--blue);
}

.condition-used {
  color: var(--green);
}

.condition-for-parts {
  color: var(--yellow);
}

.condition-damaged {
  color: var(--red);
}

.condition-untested {
  color: var(--grey);
}

@media (max-width: 580px) {
  h1 {
    font-size: var(--headsize-s);
  }

  p,
  a {
    font-size: var(--parasize-s);
  }
}

@media (min-width: 769px) {
  .nav-menu {
    max-width: 280px;
  }
  .nav_ad_m {
    display: none;
  }
  .about_ad_m,
  .hero_ad_m {
    display: none;
  }
}

@media (max-width: 1440px) {
  #content,
  .line {
    width: 100%;
  }
  #content {
    margin-left: 7px;
    margin-right: 7px;
  }
}
