/* Reset some default styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* Root variables for easy theme control */
:root {
  --primary-color: #007b5e;
  --secondary-color: #f9f9f9;
  --accent-color: #25d366; /* WhatsApp green */
  --text-color: #333;
  --header-bg: #fff;
  --footer-bg: #222;
  --footer-text: #ccc;
  --faq-border: #ddd;
  --transition-speed: 0.3s;
  --max-width: 1200px;
}

/* Body styling */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text-color);
  background-color: var(--secondary-color);
  line-height: 1.6;
  scroll-behavior: smooth;
}

/* Preloader Styles */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

#preloader img {
  width: 120px;
  height: auto;
  animation: fadeInZoom 1s ease-in-out infinite alternate;
}

@keyframes fadeInZoom {
  0% {
    opacity: 0.5;
    transform: scale(0.95);
  }
  100% {
    opacity: 1;
    transform: scale(1.05);
  }
}

/* Hide preloader when loaded */
body.loaded #preloader {
  opacity: 0;
  visibility: hidden;
}


/* Navbar and header */
.header {
  background: var(--header-bg);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.navbar {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
}

.logo {
  width: 150px;
  height: 50px;
  background: url('../image/Black_White_Creative_Modern_Letter_F_Design_Logo-removebg-preview.png') no-repeat center/contain;
  cursor: pointer;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.75rem;
}

.nav-links li a {
  text-decoration: none;
  color: var(--text-color);
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  transition: color var(--transition-speed);
}

.nav-links li a:hover,
.nav-links li a:focus {
  color: var(--primary-color);
}

/* Hamburger menu (hidden on desktop) */
.hamburger {
  display: none;
  width: 30px;
  height: 25px;
  cursor: pointer;
}

/* Nav links active state for mobile */
.nav-links.active {
  position: absolute;
  top: 60px;
  right: 1rem;
  background: var(--header-bg);
  flex-direction: column;
  width: 180px;
  border-radius: 5px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  padding: 1rem;
}

.nav-links.active li {
  margin-bottom: 0.75rem;
}

/* WhatsApp Floating Button */
.whatsapp-float {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 40px;
  right: 40px;
  background-color: var(--accent-color);
  color: white;
  border-radius: 50%;
  text-align: center;
  box-shadow: 2px 2px 10px rgba(0,0,0,0.3);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s ease;
}

.whatsapp-float img {
  width: 30px;
  height: 30px;
  filter: brightness(0) invert(1);
}

.whatsapp-float:hover {
  background-color: #128c7e;
}

/* Hero Section Slide View */
.hero-section {
  position: relative;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  overflow: hidden;
  height: 400px; /* adjust as needed */
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0,0,0,0.1);
}

/* Slider container */
.slider {
  display: flex;
  width: 300%; /* 3 slides */
  height: 100%;
  transition: transform 0.5s ease-in-out;
}

/* Each slide */
.slide {
  width: 100%;
  flex: 0 0 100%; /* Fixed width per slide */
  height: 100%;
  background-size: cover;
  background-position: center;
}

/* Optional: navigation dots */
.slider-dots {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.slider-dots button {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: none;
  background-color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.slider-dots button.active {
  background-color: var(--primary-color);
}




.front, .back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  backface-visibility: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Front side style */
.front {
  background: url('../image/front-image.jpg') no-repeat center/cover;
}

/* Back side style */
.back {
  background: url('../image/back-image.jpg') no-repeat center/cover;
  transform: rotateY(180deg);
}

/* Section 2 - About Us */
.section-2 {
  max-width: var(--max-width);
  margin: 2rem auto;
  padding: 0 1rem;
}

.section-2 h2 {
  color: var(--primary-color);
  margin-bottom: 1rem;
  text-align: center;
  font-size: 2rem;
}

.text-area p {
  margin-bottom: 1rem;
  font-size: 1.1rem;
  color: #444;
}

/* FAQ Container */
.faq-container {
  margin-top: 2rem;
  border-top: 1px solid var(--faq-border);
}

.faq-item {
  border-bottom: 1px solid var(--faq-border);
  padding: 1rem 0;
}

.faq-question {
  cursor: pointer;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--primary-color);
  position: relative;
  user-select: none;
  padding-right: 25px;
  transition: color var(--transition-speed);
}

.faq-question::after {
  content: '+';
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--primary-color);
  transition: transform var(--transition-speed);
}

.faq-question.active::after {
  content: '-';
  transform: translateY(-50%) rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s ease, padding 0.5s ease;
  padding-left: 1rem;
  color: #555;
  font-weight: 400;
}

.faq-answer.open {
  max-height: 1000px; /* large enough */
  padding-top: 0.5rem;
}

/* Text area expanded/collapsed */
.text-area.collapsed {
  max-height: 350px;
  overflow: hidden;
  transition: max-height 0.5s ease;
}

.text-area.expanded {
  max-height: 2000px; /* or auto but not animatable */
}

.toggle-button {
  width: 150px;
  height: 40px;
  background: var(--primary-color);
  border: none;
  border-radius: 30px;
  color: white;
  cursor: pointer;
  perspective: 800px; /* Needed for 3D flip */
  overflow: hidden;
  position: relative;
  user-select: none;
  font-weight: 600;
  font-family: inherit;
  transition: background-color 0.3s ease;
  margin-top: 10px;
}

.toggle-button:hover {
  background: #00573f;
}

.button-inner {
  width: 100%;
  height: 100%;
  position: relative;
  transition: transform 0.6s ease;
  transform-style: preserve-3d;
}

.toggle-button.flipped .button-inner {
  transform: rotateX(180deg);
}

.front-1, .back-1 {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1rem;
  top: 0;
  left: 0;
  padding: 0 1rem;
  box-sizing: border-box;
}

.front-1 {
  /* Front side visible initially */
}

.back-1 {
  transform: rotateX(180deg);
  background: var(--primary-color);
  /* Optional: different background on back */
}


.section-3 {
  max-width: var(--max-width);
  margin: 3rem auto;
  padding: 0 1rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

.material-item {
  perspective: 1000px;
  cursor: pointer;
}

.material-inner {
  position: relative;
  width: 100%;
  padding-top: 140%; /* aspect ratio */
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
  transition: transform 0.6s ease;
  transform-style: preserve-3d;
}

.material-item:hover .material-inner {
  transform: rotateY(180deg);
}

.material-front, .material-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 10px;
  top: 0;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
  font-size: 1rem;
  color: #fff;
  text-align: center;
}

.material-front {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.material-back {
  background-color: var(--primary-color);
  transform: rotateY(180deg);
  color: white;
  font-weight: 600;
}




/* Footer */
.footer {
  background-color: var(--footer-bg);
  color: var(--footer-text);
  padding: 2rem 1rem 1rem 1rem;
  font-size: 0.9rem;
}

.footer-container {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2rem;
}

.footer-section {
  flex: 1 1 250px;
  min-width: 200px;
}

.footer-section h3 {
  margin-bottom: 1rem;
  color: var(--accent-color);
  font-weight: 700;
}

.footer-section p, 
.footer-section ul, 
.footer-section li {
  color: var(--footer-text);
}

.footer-section ul {
  list-style: none;
  padding-left: 0;
}

.footer-section ul li {
  margin-bottom: 0.5rem;
}

.footer-section ul li a {
  color: var(--footer-text);
  text-decoration: none;
  transition: color var(--transition-speed);
}

.footer-section ul li a:hover {
  color: var(--accent-color);
}

.footer-bottom {
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid #444;
  font-size: 0.8rem;
}

/* Responsive styles */
@media (max-width: 768px) {
  .navbar {
    padding: 0.75rem 1rem;
  }

  .nav-links {
    display: none;
    flex-direction: column;
  }

  .hamburger {
    display: block;
  }

  .footer-container {
    flex-direction: column;
    gap: 1.5rem;
  }

  @media (max-width: 768px) {
  .nav-links {
    display: none; /* hide by default on small screens */
    flex-direction: column;
    background: var(--header-bg);
    position: absolute;
    top: 60px;
    right: 1rem;
    width: 180px;
    border-radius: 5px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    padding: 1rem;
  }

  /* Show nav-links when active */
  .nav-links.active {
    display: flex; /* important: make it visible */
  }

  .nav-links li {
    margin-bottom: 0.75rem;
  }

  .hamburger {
    display: block;
    cursor: pointer;
  }
}


  .section-3 {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
}

@media (max-width: 400px) {
  .toggle-button {
    width: 120px;
    height: 35px;
    font-size: 0.9rem;
  }
}
