/* rem and em do NOT depend on html font-size in media queries! Instead, 1rem = 1em = 16px */

/**************************/
/* BELOW 1344px (Smaller desktops) */
/**************************/

@media (max-width: 84em) {
  .hero {
    max-width: 120rem;
  }

  .heading-primary {
    font-size: 4.4rem;
  }
}
/**************************/
/* BELOW 1200px (Landscape Tablets) */
/**************************/

@media (max-width: 75em) {
  html {
    /* 9px / 16px  */
    font-size: 56.25%;
  }

  .grid {
    column-gap: 4.8rem;
    row-gap: 6.4rem;
  }

  .heading-secondary {
    font-size: 3.6rem;
  }

  .heading-tertiary {
    font-size: 2.4rem;
  }
  .header {
    padding: 0 3.2rem;
  }
  .main-nav-list {
    gap: 3.2rem;
  }
}
/* BELOW 1056px  */
@media (max-width: 66em) {
  /* MOBILE NAVIGATION */
  .btn-mobile-nav {
    display: block;
    z-index: 9999;
  }

  .main-nav {
    background-color: rgba(255, 255, 255, 0.9);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(10px);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    transform: translateX(100%);

    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s ease-in;

    /* Hide navigation */
    /* Allows NO transitions at all */
    /* display: none; */

    /* 1) Hide it visually */
    opacity: 0;

    /* 2) Make it unaccessible to mouse and keyboard */
    pointer-events: none;

    /* 3) Hide it from screen readers */
    visibility: hidden;
  }

  .nav-open .main-nav {
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
    transform: translateX(0);
  }

  .nav-open .icon-mobile-nav[name="close-outline"] {
    display: block;
  }

  .nav-open .icon-mobile-nav[name="menu-outline"] {
    display: none;
  }

  .main-nav-list {
    flex-direction: column;
    gap: 4.8rem;
  }

  .main-nav-link:link,
  .main-nav-link:visited {
    font-size: 3rem;
  }
  .techniques-container {
    width: 70%;
    margin: 0 auto;
  }
  .cta-content {
    display: grid;
    grid-template-columns: 65fr 35fr;
  }
}

/**************************/
/* BELOW 944px (Tablets) */
/**************************/

@media (max-width: 59em) {
  html {
    /* 8px / 16px = 0.5 = 50% */
    font-size: 50%;
  }
}
/* BELOW  864px*/
@media (max-width: 54em) {
  .grid-services {
    gap: 2.4rem;
  }
  .service-content {
    padding: 1.6rem 2.4rem 1.6rem 2.4rem;
  }

  .cta-content {
    display: grid;
    grid-template-columns: 60fr 40fr;
  }
}
/* BELOW 816px */
@media (max-width: 51em) {
  .hero {
    grid-template-columns: 1fr;
    padding: 0 6.4rem;
    gap: 6.4rem;
  }

  .hero-text-box,
  .hero-img-box {
    text-align: center;
  }
  .hero-img {
    width: 57%;
  }

  .carousel {
    text-align: start;
  }
  .grid-services {
    grid-template-columns: 1fr 1fr;
  }

  .service-name {
    font-size: 1.8rem;
  }
  .step-number {
    font-size: 8rem;
  }
  .service:hover {
    transform: none;
    box-shadow: 0 3.2rem 6.4rem rgba(0, 0, 0, 0.045);
  }
  .doctor-container {
    display: flex;
    flex-direction: column;
    gap: 3.6rem;
  }

  .doctor-img {
    width: 40rem;
    height: 40rem;
  }

  .doctor-text {
    width: 80%;
    text-align: start;
    padding: 0 auto;
  }
  .disclaimer-text {
    text-align: start;
  }

  .heading-secondary {
    margin-bottom: 4.8rem;
  }
  .faq-container {
    max-width: 100%;
    margin: auto;
  }
  .techniques-container {
    display: grid;
    width: 80%;
    margin: 0 auto;
  }
  .section-testimonials .subheading {
    text-align: start;
  }
  .section-testimonials .heading-secondary {
    text-align: start;
  }

  .meet-the-doctor-section .subheading {
    text-align: start;
  }
  .meet-the-doctor-section .heading-secondary {
    text-align: start;
  }
  .meet-the-doctor-section .heading-tertiary {
    text-align: start;
  }
}
/* BELOW 768px */

@media (max-width: 51em) {
  .cta-content {
    display: grid;
    grid-template-columns: 55fr 45fr;
  }
  .techniques-container {
    display: grid;
    width: 90%;
    margin: 0 auto;
  }
}
/**************************/
/* BELOW 704px (Smaller tablets) */
/**************************/
@media (max-width: 44em) {
  .grid--2-cols {
    grid-template-columns: 1fr;
  }
  .step-img-box {
    display: none;
  }

  .heading-secondary {
    margin-bottom: 4.8rem;
  }
  .cta-content {
    grid-template-columns: 1fr;
    width: auto;
    background-color: #7fcd8d;
  }
  .cta-info {
    margin: 0 auto;
    max-width: 40rem;
  }
  .cta-map {
    height: 50rem;
  }
  .techniques-container {
    display: grid;
    width: 100%;
    margin: 0 auto;
  }
}

/* BELOW 640px  */
/**************************/
@media (max-width: 40em) {
  .grid-services {
    grid-template-columns: 1fr;
    justify-content: center;
  }
  .service {
    justify-content: center;
  }
}
/*  BELOW  624px*/
@media (max-width: 39em) {
  .techniques-container {
    grid-template-columns: 1fr;
  }
  .extra-techniques-break {
    display: none;
  }
}

/**************************/
/* BELOW 592px (Phones) */
/**************************/

@media (max-width: 37em) {
  .grid {
    row-gap: 6.4rem;
  }
  .quote-name {
    display: none;
  }
  .quote {
    margin-bottom: 0;
  }
  .grid--2-cols,
  .grid--3-cols,
  .grid--4-cols {
    grid-template-columns: 1fr;
  }

  .btn,
  .btn:link,
  .btn:visited {
    padding: 2.4rem 1.6rem;
  }

  .section-hero {
    padding: 2.4rem 0 6.4rem 0;
  }

  .hero {
    padding: 0 3.2rem;
  }

  .hero-img {
    width: 90%;
  }
  .hero-text-box {
    text-align: start;
  }
  .section-hero .btn--full,
  .section-hero .btn--outline {
    padding: 1.6rem 3rem;
  }

  .faq-section .subheading {
    text-align: start;
  }
  .faq-section .heading-secondary {
    text-align: start;
  }
  .faq-text {
    text-align: start;
  }
}
/* BELOW 448px */
@media (max-width: 27em) {
  .btn-container {
    display: flex;
    flex-direction: column;
    gap: 1.6rem;
    text-align: center;
  }

  .btn-cta {
    margin-right: 0;
  }
  .break-footer {
    display: inline;
  }
  .doctor-text {
    width: 100%;
  }
  .doctor-img {
    width: 100%;
    height: 100%;
  }
  .cta-map {
    height: 30rem;
  }
}
/* BELOW 400px */
@media (max-width: 25em) {
  .google-logo {
    display: none;
  }
}
@media (max-width: 21em) {
  .break-footer {
    display: none;
  }
  .break-cta {
    display: none;
  }
}
/* 
- Font sizes (px)
10 / 12 / 14 / 16 / 18 / 20 / 24 / 30 / 36 / 44 / 52 / 62 / 74 / 86 / 98

- Spacing system (px)
2 / 4 / 8 / 12 / 16 / 24 / 32 / 48 / 64 / 80 / 96 / 128
*/

/**************************/
/* Fixing Safari flexbox gap */
/**************************/

.no-flexbox-gap .main-nav-list li:not(:last-child) {
  margin-right: 4.8rem;
}

.no-flexbox-gap .list-item:not(:last-child) {
  margin-bottom: 1.6rem;
}

.no-flexbox-gap .list-icon:not(:last-child) {
  margin-right: 1.6rem;
}

@media (max-width: 66em) {
  .no-flexbox-gap .main-nav-list li:not(:last-child) {
    margin-right: 3.2rem;
  }
}

@media (max-width: 59em) {
  .no-flexbox-gap .main-nav-list li:not(:last-child) {
    margin-right: 0;
    margin-bottom: 4.8rem;
  }
}
