
:root {
  --primary-color: #f92524;
  --primary-color-dark: #e91a1a;
  --secondary-color: #f7f7f7;
  --text-dark: #0f172a;
  --text-light: #64748b;
  --white: #ffffff;
  --primary-bg:#F6A3A3;
  --fw-normal: 400;
  --fw-medium: 500;
  --fw-bold: 600;
  --fw-bolder: 700;
  --header-font:'Dancing Script', cursive;
  --body-font: 'Lato', sans-serif;
  --max-width: 1200px;
  --border-radius: 5px;
}

/* UNIVERSAL STYLES START*/
* {
  padding: 0;
  margin: 0;
  -webkit-box-sizing: border-box; /* Webkit */
  -moz-box-sizing: border-box; /* Mozilla */
  box-sizing: border-box;
}

/* Remove all animations, transitions and smooth scroll for people that prefer not to see them */
@media (prefers-reduced-motion: reduce) {
  html:focus-within {
    -webkit-scroll-behavior: auto; /* Webkit prefix */
    -ms-scroll-behavior: auto; /* IE prefix */
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    -webkit-animation: none !important; /* Webkit prefix */
    -webkit-transition: none !important; /* Webkit prefix */
    animation: none !important;
    transition: none !important;
  }
}

/* Remove default button styles */
button {
  border: none;
  background: none;
  padding: 0;
  margin: 0;
  font: inherit;
  cursor: pointer;
}

a {
  text-decoration: none;
  color: inherit;
}

ul li {
  list-style: none;
}

/* Remove default settings */
a,
button,
form,
input {
  border: none;
  outline: none;
  -webkit-user-select: none;
  user-select: none;
  background: none;
  box-shadow: none;
  font: inherit;
}

html,
body {
  scroll-behavior: smooth;
}
/* UNIVERSAL STYLES END*/

/* REUSABLE START */
.section__container {
  max-width: var(--max-width);
  margin: auto;
  padding: 5rem 1rem;
}

.section__header {
  position: relative;
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
  font-size: 2.25rem;
  font-weight: var(--fw-bolder);
  color: var(--text-dark);
  font-family: var(--header-font);
}

.section__header::after {
  position: absolute;
  content: "";
  left: 0;
  bottom: 0;
  width: 50px;
  height: 3px;
  background-color: var(--primary-color);
}

.section__description {
  max-width: 900px;
  color: var(--text-light);
}

.btn {
  padding: 0.75em 1.5em;
  outline: none;
  border: none;
  font-size: 1rem;
  white-space: nowrap;
  color: var(--white);
  background-color: var(--primary-color);
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: 0.3s;
}

.btn:hover {
  background-color: var(--primary-bg);
  color: var(--text-dark);
  font-weight: var(--fw-bolder);
}

img {
  display: flex;
  width: 100%;
}

a {
  white-space: nowrap;
}

/* REUSABLE END */

body {
  font-family: var(--body-font);
  line-height: 1.5;
  font-size: 1rem;
}

/* ====== HEADER START ======= */
nav {
  position: fixed;
  isolation: isolate;
  width: 100%;
  z-index: 9;
}

.nav__header {
  padding: 1em;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: var(--secondary-color);
}

.nav__logo a {
  display: flex;
  align-items: center;
  gap: 0.5em;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-dark);
}

.nav__logo img {
  max-width: 40px;
}

.nav__links {
  position: absolute;
  top: 68px;
  left: 0;
  width: 100%;
  padding: 2em;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 2em;
  background-color: var(--secondary-color);
  transition: 0.5s;
  z-index: -1;
  transform: translateY(-100%);
}

.nav__links.open {
  transform: translateY(0);
}

.link a {
  color: var(--text-dark);
  transition: color 0.3s;
}

.link a:hover {
  color: var(--primary-color);
}

.link .btn {
  color: var(--white);
  transition: background-color 0.3s ease-in-out;
}

.link .btn:hover {
  background-color: var(--primary-bg);
  color: var(--text-dark);
}

.nav__menu__btn {
  font-size: 1.5rem;
  color: var(--text-dark);
}

.header__container {
  display: grid;
  gap: 2em;
}

.header__image img {
  max-width: 500px;
  margin: auto;
}

.header__content h4 {
  font-size: 2.5rem;
  font-weight: var(--fw-normal);
  color: var(--text-dark);
}

.header__content .section__header {
  font-size: 4rem;
  font-weight: 700;
}

.header__content p {
  margin-bottom: 2em;
  color: var(--text-light);
}
/* ======= HEADER END ========= */

/* =======ABOUT START ========= */
.about__container {
  display: grid;
  gap: 2em;
}

.about__image {
  position: relative;
  isolation: isolate;
}

.about__image img {
  max-width: 500px;
  margin: auto;
}

.about__image .about__bg {
  position: absolute;
  right: 2em;
  top: 3em;
  max-width: 250px;
  z-index: -1;
}

.about__grid {
  margin-top: 2em;
  display: grid;
  gap: 2em;
}

.about__card {
  display: flex;
  align-items: center;
  gap: 1em;
}

.about__card span {
  padding: 11px 19px;
  font-size: 2rem;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
  border-radius: 100%;
}

.about__card h4 {
  margin-bottom: 0.5em;
  font-size: 1.2rem;
  font-weight: var(--fw-bold);
  color: var(--text-dark);
}

.about__card p {
  color: var(--text-light);
}
/* =======ABOUT END ========= */

/* ========= CLASS START ============ */
.class__grid {
  margin-top: 4rem;
  display: grid;
  gap: 2rem;
}

.class__card {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  transition: 0.3s;
}

.class__card .class__bg {
  position: absolute;
  max-width: 175px;
  top: -3rem;
  right: -1rem;
  z-index: -1;
  opacity: 0;
  transition: 0.3s;
}

.class__card:hover .class__bg {
  opacity: 0.5;
}

.class__content {
  flex: 1;
  padding: 1rem;
  background-color: var(--primary-color);
  color: var(--white);
}

.class__content:hover {
  background-color: var(--primary-bg);
  color: var(--text-dark);
}

.class__content h4 {
  margin-bottom: 5px;
  font-size: 1.2rem;
  font-weight: 500;
}
/* ========= CLASS END ============ */

/* ========INSTRUCTOR START ========= */
.instructor__container :is(.section__header, .section__description) {
  width: fit-content;
  margin-inline: auto;
  text-align: center;
}

.instructor__container .section__header::after {
  left: 50%;
  transform: translateX(-50%);
}

.instructor__grid {
  margin-top: 4rem;
  display: grid;
  align-items: center;
}

.instructor__card {
  height: 100%;
  display: grid;
  align-items: center;
}

.instructor__card img {
  height: 100%;
  object-fit: cover;
}

.instructor__content {
  padding: 2rem 1rem;
}

.instructor__content h4 {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
}

.instructor__content h5 {
  margin-bottom: 1rem;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-light);
}

.instructor__content p {
  margin-block: 1rem;
  color: var(--text-light);
}

.instructor__socials {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.instructor__socials a {
  font-size: 1.2rem;
  color: var(--text-light);
}

.instructor__socials a:hover {
  color: var(--primary-color);
}
/* ========INSTRUCTOR END ========= */

/* ========SCHEDULE START ========= */
.schedule__table table {
  width: 100%;
  border-collapse: collapse;
}

.schedule__table th,
.schedule__table td {
  padding: 8em;
  border: 1px solid var(--secondary-color);
  text-align: center;
}

.schedule__container .section__header::after{
    left: 50%;
    transform: translateX(-50%);
}

.schedule__container {
  text-align: center;
}

.schedule__container .section__description {
 margin-block: 2em;
 text-align: center;
 max-width: unset;
}

.schedule__table tbody tr:nth-child(odd) {
  background-color: var(--secondary-color);
}

.schedule__table {
  margin: 0 auto;
  width: 80%;
  background-color: var(--white);
  box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
  border-radius: 10px;
}

.schedule__table table {
  width: 100%;
  border-collapse: collapse;
}

.schedule__table th, .schedule__table td {
  padding: 15px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

.schedule__table th {
  background-color: var(--primary-color);
  font-weight: var(--fw-normal);
  color: var(--white);
}

.schedule__table td {
  color: var(--text-light);
}

.schedule__table th,
.schedule__table td {
  padding: 8px;
  border: 1px solid #ddd;
  text-align: center;
}
/* ========SCHEDULE END ========= */

/* ========GALLERY START ========= */
.section__gallery {
  /* padding: 50px 0; */
  text-align: center;
  display: grid;
  justify-content: center;
  row-gap: 1.8em;
}

.section__gallery h2 {
  justify-self: center;
}

.section__gallery h2::after {
  left: 50%;
  transform: translateX(-50%);
}

.section__gallery .section__description {
 max-width: unset;
}

.gallery__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 20px;
  margin-top: 20px;
}

.gallery__item {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  height: 300px;
}

.gallery__item img {
  max-width: 100%;
  width: 100%;
  height: 100%;
  /* Maintain aspect ratio and fill the container */
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery__item:hover {
  transform: scale(1.05);
}

.gallery__content {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  background-color: var(--primary-color);
  color: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: 10px;
}

.gallery__item:hover .gallery__content {
  opacity: 1;
}

.gallery__content h4 {
  font-size: 1.4rem;
  margin-bottom: 10px;
}

.gallery__content p {
  font-size: 1rem;
  text-align: center;
  max-width: 80%;
}
/* ========GALLERY END ========= */

/*==== PRICE START ====*/
.price__container :is(.section__header, .section__description) {
  width: fit-content;
  margin-inline: auto;
  text-align: center;
}

.price__container .section__header::after {
  left: 50%;
  transform: translateX(-50%);
}

.price__grid {
  margin-top: 4rem;
  display: grid;
  gap: 2rem;
}

.price__card {
  padding: 2rem 1rem;
  display: flex;
  flex-direction: column;
  text-align: center;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
}

.price__content {
  flex: 1;
  margin-bottom: 2rem;
}

.price__content img {
  max-width: 70px;
  margin-inline: auto;
  margin-bottom: 1rem;
}

.price__content h4 {
  margin-bottom: 1rem;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
}

.price__content p {
  margin-bottom: 1rem;
  color: var(--text-light);
}

.price__content hr {
  margin-bottom: 1rem;
}
/*==== PRICE END ====*/

/*==== TESTIMONIAL START ====*/
.wrapper__container {
  margin-block: 14em;
  position: relative;
}

.client__container {
  margin-bottom: 9em;
}

.client__container .btn__link {
  margin-block-end: 2em;
}

.client__header {
  display: flex;
  flex-direction: column;
  gap: 2em;
}

.wrapper {
  position: absolute;
  width: 80vw;
  max-width: 30em;
  min-height: 25em;
  border-radius: 0.6em;
  transform: translate(-50%, -50%);
  left: 50%;
  top: 50%;
  color: var(--text-dark);
  box-shadow: var(--box-shadow);
  display: flex;
}

.testimonial-container {
  width: 85%;
  height: 100%;
  position: relative;
  margin: auto;
  padding: 1.8em 1.2em;
}

.wrapper button {
  font-size: 1.8em;
  height: 2.2em;
  width: 2.2em;
  background-color: var(--white);
  position: absolute;
  margin: auto;
  top: 0;
  bottom: 0;
  color: var(--primary-color);
  /* box-shadow: 0 0 1em rgba(1, 17, 39, 0.25); */
  cursor: pointer;
  border-radius: 50%;
}

button#next {
  right: -1.1em;
}

button#prev {
  left: -1.1em;
}

#next::after,
#prev::after {
  content: none;
}

.testimonial-container p {
  color: var(--text-light);
  text-align: center;
  font-size: 0.9em;
  line-height: 2em;
  letter-spacing: 0.05em;
}

.testimonial-container img {
  margin: 1.8em auto 1.25em auto;
  border-radius: 50%;
  width: 4.4em;
}

.testimonial-container h3 {
  color: var(--text-dark);
  text-align: center;
}

.testimonial-container h6 {
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  font-weight: var(--fw-normal);
  text-align: center;
  color: var(--text-light);
}

.testimonial-container i {
  color: var(--primary-color);
}
/*==== TESTIMONIAL END ====*/

/* ====CONTACT START ========= */
.section__contact {
  text-align: center;
}

.section__contact .section__header::after {
  left: 50%;
  transform: translateX(-50%);
}

.section__contact .section__description {
  max-width: unset;
  margin-block: 2em;
}

.contact__form {
  max-width: 600px;
  margin: 0 auto;
}

.contact__form form {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.form-group {
  width: 100%;
  margin-bottom: 20px;
}

.form-group label {
  color: var(--text-light);
  display: block;
  margin-bottom: 5px;
  text-align: left;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 15px;
  border: 1px solid #ccc;
  border-radius: var(--border-radius);
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--primary-color);
}

button[type="submit"] {
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: var(--border-radius);
  padding: 15px 40px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button[type="submit"]:hover {
  background-color: var(--primary-bg);
  color: var(--text-dark);
  font-weight: var(--fw-medium);
}
/* ====CONTACT END ========= */

/* ====FOOTER START ========= */
.footer {
  background-color: var(--secondary-color);
}

.footer__container {
  display: grid;
  gap: 2rem;
}

.footer__logo a {
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-dark);
}

.footer__logo img {
  max-width: 40px;
}

.footer__col p {
  margin-bottom: 2rem;
  color: var(--text-light);
}

.footer__socials {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.footer__socials a {
  padding: 5px 10px;
  font-size: 1.2rem;
  color: var(--primary-color);
  border-radius: 100%;
  border: 1px solid var(--primary-color);
}

.footer__socials a:hover {
  color: var(--text-light);
  border: 1px solid var(--text-light);
}

.footer__col h4 {
  margin-bottom: 1.5rem;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--text-dark);
}

.footer__links a {
  display: block;
  margin-bottom: 1rem;
  color: var(--text-light);
}

.footer__links a:hover {
  color: var(--primary-color);
}

.footer__bar {
  padding: 1rem;
  font-size: 0.8rem;
  color: var(--text-light);
  text-align: center;
}
/* ====FOOTER END ========= */

/* ====Media Queries */

@media screen and (max-width: 600px) {
  .gallery__grid {
    grid-template-columns: repeat(2, 1fr);
  }

 .gallery__item {
    height: auto; /* Adjust the height for small screens */
  }

  .schedule__container {
      overflow-x: auto;
  }
}

@media screen and (min-width: 480px) {
  .class__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem 1rem;
  }

  .instructor__grid {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .instructor__card:nth-child(3) {
    grid-area: 2/2/3/3;
  }

  .price__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem 1rem;
  }

  .footer__container {
    grid-template-columns: 2fr 1fr;
  }
}

@media screen and (min-width: 768px) {
  body {
    font-size: 1.2rem;
  }

  nav {
    position: static;
    padding: 2rem 1rem;
    max-width: var(--max-width);
    margin-inline: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
  }

  .nav__header {
    padding: 0;
    background-color: transparent;
  }

  .nav__menu__btn {
    display: none;
  }

  .nav__links {
    position: static;
    padding: 0;
    flex-direction: row;
    background-color: transparent;
    transform: none;
  }

  .header__container {
    padding-block: 0;
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .header__content {
    padding-block: 5rem;
    grid-area: 1/1/2/2;
  }

  .about__container {
    grid-template-columns: repeat(2, 1fr);
    align-items: center;
  }

  .about__grid {
    gap: 3rem;
  }

  .class__grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .instructor__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .instructor__card:nth-child(3) {
    grid-area: unset;
  }

  .instructor__content {
    padding: 2rem;
  }

  .price__grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .footer__container {
    grid-template-columns: repeat(5, 1fr);
  }

  .footer__col:first-child {
    grid-column: 1/3;
  }
}

@media screen and (min-width: 1024px) {
  .class__grid {
    gap: 2rem;
  }

  .price__grid {
    gap: 2rem;
  }

  .price__card {
    padding: 2rem;
  }
}
