@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;700&display=swap');

body {
  background-color: #000;
  color: #fff;
  font-family: 'Roboto', sans-serif;
  margin: 0;
  padding: 0;
  overflow-x: hidden;

}

/* Navigation bar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #000; /* Black background */
  padding: 1rem 2rem;
  color: #fff;
}

.navbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  color: white;
  text-decoration: none; /* Remove underline from links */
}

.logo {
  width: 40px; /* adjust logo size */
  height: 40px;
  margin-right: 10px;
}

.business-name {
  font-size: 1.5rem;
  font-weight: bold;
}

.navbar-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.navbar-right a {
  color: #fff;
  text-decoration: none;
  padding: 0.5rem;
}

.navbar-right a:hover {
  background-color: #333;
  border-radius: 4px;
}

/* Dropdown styling */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropbtn {
  background-color: #000;
  color: white;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  border: none;
  cursor: pointer;
}

.dropdown-content {
  position: absolute;
  right: 0;
  background-color: #fff;
  min-width: 160px;
  box-shadow: 0 8px 16px rgba(0,0,0,0.2);
  border-radius: 4px;
  overflow: hidden;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none; /* Prevent hover-trigger until visible */
  z-index: 1;
}

.dropdown-content a {
  color: #000;
  padding: 8px 12px;
  text-decoration: none;
  display: block;
  white-space: nowrap; /* Keep dropdown items on a single line */
  font-size: 0.9rem;
}

.dropdown-content a:hover {
  background-color: #ddd;
}

.dropdown:hover .dropdown-content {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto; /* Enable interaction once visible */
}

/* Hamburger styling */
.hamburger {
  display: none;
  cursor: pointer;
  z-index: 1001; /* Make sure it's clickable */
}

.bar {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px auto;
  transition: all 0.3s ease-in-out;
  background-color: #fff;
}

/* Hamburger animation */
.hamburger.active .bar:nth-child(2) {
  opacity: 0;
}

.hamburger.active .bar:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.hamburger.active .bar:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

@media (max-width: 768px) {
  .hamburger {
    display: block;
  }

  .navbar-right {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    background-color: #000;
    flex-direction: column;
    gap: 0;
    text-align: center;
    transition: left 0.3s ease-in-out;
    z-index: 1000; /* On top */
  }

  .navbar-right.active {
    left: 0;
  }

  .nav-item {
    margin: 16px 0;
  }
}

/* Content */
header {
  text-align: center;
  padding: 4rem 1rem;
  background: #000;
  color: #fff;
  margin-left: 20%;
  margin-right: 20%;
}

header .title {
  font-size: 4.5rem;
  margin: 0;
  margin-top: 5%;
  animation: fadeDown 1s ease-out forwards;
}

h2 {
  text-align: center;
  font-size: 2rem;
  margin-bottom: 2rem;
}

footer {
  background: #000;
  color: #fff;
  text-align: center;
  padding: 0.5rem 1rem 1rem 1rem;
}

footer ul {
  list-style: none;
  padding: 0;
}

footer li {
  margin: 2rem 0;
}

/* Header animation */
@keyframes fadeDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#typewriter::after {
  content: "|";
  animation: blink 1s infinite;
}

@keyframes blink {
  0%, 50% {
    opacity: 1;
  }
  51%, 100% {
    opacity: 0;
  }
}

/* Section 1 styling */
.hero-section {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 100px;
  background-color: black;
  color: white;
  font-family: sans-serif;
  gap: 10%;
}

.logo-container {
  position: relative;
  width: 300px; /* increased from 120px */
  height: 300px;
  flex-shrink: 0;
}

.circle-encompass {
  position: absolute;
  width: 300px; 
  height: 300px;
  top: 0;
  left: 0;
  z-index: 2;
  animation: spin 10s linear;
  animation-timeline: view();
}

.logo-without-text {
  position: absolute;
  width: 200px;  
  height: 200px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
}

.text-content {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 32px;
  font-weight: 600;
  animation: fadeInTopAnimation 1s;
}

.text-content p {
  margin: 0px;
  text-align: center;
}

.yt-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
  animation: fadeInTopAnimation 1s;
}

.yt-button {
  padding: 10px 20px;
  border: 2px solid white;
  border-radius: 999px;
  color: white;
  text-decoration: none;
  font-weight: bold;
  background-color: transparent;
  transition: background-color 0.3s, color 0.3s;
  position: relative;
  z-index: 1;
}

.line {
  height: 1px;
  background-color: white;
  opacity: 0.5;
  transition: width 0.5s ease;
}

.left-line, .right-line {
  width: 100%; /* default line length */
}

.yt-container:hover .left-line {
  width: 0;
}

.yt-container:hover .right-line {
  width: 0;
}

.yt-button:hover {
  background-color: white;
  color: black;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes fadeInTopAnimation {
  from {
    opacity: 0%;
    transform: translateY(-100%);
  }

  to {
    opacity: 100%;
    transform: translateY(0%);
  }
}

/* Section 2 - Something big is coming your way */
.section-2 {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  gap: 20px;
}

.section-2 a{
  background-color: #ffffff;
  text-decoration: none;
  color: black;
  padding: 8px 16px;
  border-radius: 25px;
  font-size: 30px;
  font-weight: 700;
  animation: fadeInTopAnimation 0.2s;
  animation-timeline: view();
  margin-top: 20px;
}

.section-2 h1 {
  width: 60%;
  font-size: 60px;
  margin: 0;
  padding: 0;
}

.section-2 h1:nth-child(1) {
  text-align: left;
  animation: fadeInLeftAnimation 0.2s;
  animation-timeline: view();
}

.section-2 h1:nth-child(2) {
  text-align: right;
  animation: fadeInRightAnimation 0.1s;
  animation-timeline: view();
}

@keyframes fadeInRightAnimation {
  from {
    opacity: 0;
    transform: translateX(100%);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInLeftAnimation {
  from {
    opacity: 0;
    transform: translateX(-100%);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Section 3 - Check them out */
.section-3 {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  justify-content: center;
  margin-top: 150px;
}

.section-3 h1 {
  font-size: 40px;
  background: linear-gradient(45deg, rgb(18, 132, 177), grey);
  padding: 10px 16px;
  border-radius: 10px;
  animation: fadeInTopAnimation 0.2s;
  animation-timeline: view();
}

.section-3-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
}

.section-3-row p {
  margin: 0;
  padding: 0;
  text-align: center;
  font-size: 25px;
  font-weight: 600;
}

.card-section-3 img {
  width: 150px;
  height: 150px;
  animation: osscilate 1.2s infinite;
}

.card-section-3 {
  display: flex;
  flex-direction: column;
  gap: 30px;
  background: linear-gradient(45deg, rgb(18, 132, 177), grey);
  color: white;
  padding: 60px;
  align-items: center;
  text-decoration: none;
}

.card-section-3:nth-child(1) {
  animation: miniFadeInLeftAnimation both;
  animation-timeline: view(40% 10%);
}

.card-section-3:nth-child(2) {
  animation: miniFadeInRightAnimation both;
  animation-timeline: view(40% 10%);
}

@keyframes miniFadeInLeftAnimation {
  from {
    opacity: 0;
    transform: translateX(-50%);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes miniFadeInRightAnimation {
  from {
    opacity: 0;
    transform: translateX(50%);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes osscilate {
  0% {
    transform: translateY(15px);
  }

  50% {
    transform: translateY(0px);
  }

  100% {
    transform: translateY(15px);
  }
}

/* Section 4 - Past Paper Library */
.section-4 {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  margin-top: 150px;
  gap: 20px;
}

.section-5 h2, .section-4 h2 {
  font-size: 40px;
  background-color: grey;
  padding: 10px 16px;
  border-radius: 10px;
  animation: fadeInTopAnimation both;
  animation-timeline: view();
}

.pp_links {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
}

.subject_card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 30px;
  opacity: 0;
  animation: slideInLeftfade both;
  animation-timeline: view(50% 0%);
}

.subject_card:nth-child(1) {
  animation-range: entry 0% cover 20%;
}

.subject_card:nth-child(2) {
  animation-range: entry 20% cover 40%;
}

.subject_card:nth-child(3) {
  animation-range: entry 60% cover 80%;
}

.subject_card:nth-child(4) {
  animation-range: entry 80% cover 100%;
}

@keyframes slideInLeftfade {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.subject_card img {
  width: 130px;
  height: 130px;
  animation: osscilate 1.2s infinite;
}

.button_link {
  text-decoration: none;
  color: white;
  font-weight: 600;
  padding: 10px 16px;
  font-size: 25px;
  width: 165px;
  text-align: center;
  border-radius: 10px;
}

/* Section 5 - Meet the team */
.section-5 {
  margin: 150px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  justify-content: center;
  align-items: center;
}

.team-members {
  display: flex;
  gap: 40px;
}

.member {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  animation: slideInLeftfade both;
  animation-timeline: view(50% 0%);
}

.member:nth-child(1) {
  animation-range: entry 0% cover 20%;
}

.member:nth-child(2) {
  animation-range: entry 20% cover 40%;
}

.member:nth-child(3) {
  animation-range: entry 40% cover 60%;
}

.member img {
  width: 200px;
  border-radius: 100px;
}

.member h3 {
  font-size: 25px;
}

/* Footer */
footer {
  background-color: rgb(40, 40, 40);
  animation: fadeDown both;
}

.social {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
}

.social-link {
  text-decoration: none;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 4rem;
  aspect-ratio: 1;
  font-size: 1.5rem;
  color: #7a7a7a;
  background-color: #373737;
  border-radius: 50%;
  transition: color 0.5s ease-in-out;
}

@property --fill {
  syntax: "<percentage>";
  inherits: true;
  initial-value: 0%;
}

.social-link:hover {
  color: greenyellow;
  --fill: 100%;
}

.social-link::after {
  position: absolute;
  z-index: -1;
  content: "";
  inset: -3px;
  border-radius: inherit;

  background: conic-gradient(greenyellow var(--fill), transparent var(--fill));
  transition: --fill 0.6s ease-in-out;
}

/* Responsiveness */
@media (max-width: 1175px) {
  .title-header { display: none; }

  .hero-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 50px;
    margin-bottom: 10%;
  }
}

@media (max-width: 935px) {
  .pp_links {
    flex-wrap: wrap;
    justify-content: center;
  }

  .subject_card {
    flex: 1 0 calc(50% - 20px); /* Two per row with spacing */
    margin-bottom: 20px;
  }
}

@media (max-width: 725px) {
  .team-members {
    flex-wrap: wrap;
    justify-content: center;
  }

  .member {
    margin-bottom: 10px;
  }
}

@media (max-width: 980px) {
  .section-2 h1 { font-size: 50px; }
}

@media (max-width: 780px) {
  .section-2 h1 { font-size: 45px; }
}

@media (max-width: 565px) {
  .section-2 h1 { font-size: 30px; }
}

@media (max-width: 450px) {
  .text-content p { font-size: 20px; }

  .card-section-3 {
    padding: 20px;
  }

  .card-section-3 img {
    width: 70px;
    height: 70px;
  }

  .card-section-3 p {
    font-size: 20px;
  }

  .section-2 h1:nth-child(1) { font-size: 29px; }
  .section-2 h1:nth-child(2) { font-size: 27px; }

  .section-4 img { width: 110px; height: 110px; }
  .button_link { padding-right: 4px; padding-left: 4px; }

  .subject_card {
    flex: 1 0 calc(40% - 0px); 
    margin-bottom: 20px;
  }

  .section-5 h2 { width: 300px; }
}

@media (max-width: 501px) {
  .text-content p:nth-child(1) { font-size: 21px }
  .text-content p:nth-child(2) { font-size: 23px }
}

