/* ===== Reset & Base ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  color: #333;
  background: #f0f2f5;
  transition: background 0.3s, color 0.3s;
}

body.dark-mode {
  background: #0d0d1a;
  color: #e0e0e0;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== Header ===== */
header {
  background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
  color: #fff;
  padding: 18px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo {
  font-size: 28px;
  font-weight: 800;
  background: linear-gradient(45deg, #f093fb, #f5576c, #4facfe);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: 1px;
  text-shadow: 0 0 20px rgba(245, 87, 108, 0.3);
}

nav ul {
  list-style: none;
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
}

nav a {
  color: #fff;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  transition: color 0.3s, transform 0.2s;
  position: relative;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #f5576c;
  transition: width 0.3s;
}

nav a:hover {
  color: #f5576c;
  transform: translateY(-2px);
}

nav a:hover::after {
  width: 100%;
}

.dark-toggle {
  background: linear-gradient(135deg, #f5576c, #f093fb);
  border: none;
  color: #fff;
  padding: 8px 20px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: transform 0.3s, box-shadow 0.3s;
  box-shadow: 0 4px 15px rgba(245, 87, 108, 0.4);
}

.dark-toggle:hover {
  transform: scale(1.05);
  box-shadow: 0 6px 25px rgba(245, 87, 108, 0.6);
}

/* ===== Hero ===== */
.hero {
  background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
  color: #fff;
  padding: 120px 0 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(240, 147, 251, 0.08), transparent 60%),
              radial-gradient(circle at 70% 50%, rgba(79, 172, 254, 0.08), transparent 60%);
  animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  0% { transform: translate(0, 0); }
  100% { transform: translate(20px, -20px); }
}

.hero h1 {
  font-size: 52px;
  margin-bottom: 20px;
  background: linear-gradient(45deg, #f093fb, #f5576c, #4facfe, #43e97b);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: textShimmer 4s ease-in-out infinite;
  background-size: 300% 300%;
}

@keyframes textShimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.hero p {
  font-size: 20px;
  max-width: 700px;
  margin: 0 auto 30px;
  opacity: 0.9;
  line-height: 1.8;
}

.hero .btn {
  background: linear-gradient(135deg, #f5576c, #f093fb);
  color: #fff;
  padding: 16px 48px;
  border-radius: 50px;
  text-decoration: none;
  font-size: 18px;
  font-weight: 600;
  transition: transform 0.3s, box-shadow 0.3s;
  display: inline-block;
  box-shadow: 0 8px 30px rgba(245, 87, 108, 0.4);
  position: relative;
  z-index: 1;
}

.hero .btn:hover {
  transform: translateY(-4px) scale(1.02);
  box-shadow: 0 12px 40px rgba(245, 87, 108, 0.6);
}

.hero .btn:active {
  transform: translateY(-2px);
}

/* ===== Banner Slider ===== */
.banner-slider {
  display: flex;
  overflow: hidden;
  position: relative;
  height: 80px;
  margin-top: 50px;
  border-radius: 16px;
}

.banner-slide {
  min-width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  padding: 20px;
  font-weight: 500;
  letter-spacing: 1px;
}

/* ===== Sections ===== */
section {
  padding: 80px 0;
  opacity: 0;
  transform: translateY(30px);
  animation: sectionFadeIn 0.8s ease forwards;
}

@keyframes sectionFadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

section:nth-child(2) { animation-delay: 0.1s; }
section:nth-child(3) { animation-delay: 0.2s; }
section:nth-child(4) { animation-delay: 0.3s; }
section:nth-child(5) { animation-delay: 0.4s; }
section:nth-child(6) { animation-delay: 0.5s; }
section:nth-child(7) { animation-delay: 0.6s; }
section:nth-child(8) { animation-delay: 0.7s; }
section:nth-child(9) { animation-delay: 0.8s; }
section:nth-child(10) { animation-delay: 0.9s; }
section:nth-child(11) { animation-delay: 1s; }
section:nth-child(12) { animation-delay: 1.1s; }
section:nth-child(13) { animation-delay: 1.2s; }
section:nth-child(14) { animation-delay: 1.3s; }
section:nth-child(15) { animation-delay: 1.4s; }
section:nth-child(16) { animation-delay: 1.5s; }
section:nth-child(17) { animation-delay: 1.6s; }

h2 {
  font-size: 36px;
  text-align: center;
  margin-bottom: 50px;
  position: relative;
  color: inherit;
}

h2::after {
  content: '';
  display: block;
  width: 80px;
  height: 4px;
  background: linear-gradient(90deg, #f5576c, #f093fb);
  margin: 18px auto 0;
  border-radius: 4px;
  box-shadow: 0 0 20px rgba(245, 87, 108, 0.3);
}

/* ===== Grid & Cards ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(16px);
  border-radius: 20px;
  padding: 35px 30px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.06);
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
              box-shadow 0.4s ease,
              background 0.3s;
  border: 1px solid rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(245, 87, 108, 0.05), transparent);
  transition: left 0.6s;
}

.card:hover::before {
  left: 100%;
}

.dark-mode .card {
  background: rgba(22, 33, 62, 0.7);
  backdrop-filter: blur(16px);
  border-color: rgba(255, 255, 255, 0.05);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.card:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

.dark-mode .card:hover {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
}

.card h3 {
  font-size: 22px;
  margin-bottom: 15px;
  background: linear-gradient(135deg, #f5576c, #4facfe);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.card p {
  color: #555;
  line-height: 1.7;
}

.dark-mode .card p {
  color: #bbb;
}

/* ===== Statistics ===== */
.stat-grid {
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
  gap: 30px;
  text-align: center;
  padding: 20px 0;
}

.stat-item {
  flex: 1;
  min-width: 150px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(8px);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: transform 0.3s;
}

.stat-item:hover {
  transform: scale(1.05);
}

.stat-number {
  font-size: 52px;
  font-weight: 800;
  background: linear-gradient(135deg, #f5576c, #f093fb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.stat-label {
  font-size: 18px;
  margin-top: 10px;
  color: inherit;
  font-weight: 500;
}

/* ===== Testimonials ===== */
.testimonial {
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(12px);
  border-radius: 20px;
  padding: 30px;
  font-style: italic;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: transform 0.3s, box-shadow 0.3s;
  position: relative;
}

.testimonial::before {
  content: '"';
  position: absolute;
  top: -10px;
  left: 20px;
  font-size: 60px;
  color: #f5576c;
  opacity: 0.3;
  font-family: Georgia, serif;
}

.dark-mode .testimonial {
  background: rgba(15, 52, 96, 0.6);
  border-color: rgba(255, 255, 255, 0.05);
}

.testimonial:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
}

.testimonial p {
  font-size: 16px;
  line-height: 1.8;
}

/* ===== FAQ ===== */
.faq-item {
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  padding: 20px 0;
  cursor: pointer;
  transition: background 0.3s;
  border-radius: 8px;
  padding-left: 15px;
  padding-right: 15px;
}

.dark-mode .faq-item {
  border-color: rgba(255, 255, 255, 0.1);
}

.faq-item:hover {
  background: rgba(245, 87, 108, 0.03);
}

.dark-mode .faq-item:hover {
  background: rgba(245, 87, 108, 0.08);
}

.faq-question {
  font-weight: 600;
  font-size: 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: inherit;
}

.faq-question span {
  font-size: 24px;
  transition: transform 0.3s;
  color: #f5576c;
}

.faq-item.active .faq-question span {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
              margin 0.3s, 
              opacity 0.3s;
  margin-top: 0;
  opacity: 0;
  color: #666;
  line-height: 1.7;
}

.dark-mode .faq-answer {
  color: #bbb;
}

.faq-item.active .faq-answer {
  max-height: 300px;
  margin-top: 15px;
  opacity: 1;
}

/* ===== Contact ===== */
.contact-info {
  background: linear-gradient(135deg, #0f0c29, #302b63, #24243e);
  color: #fff;
  padding: 60px 40px;
  border-radius: 28px;
  margin: 40px 0;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
}

.contact-info::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(240, 147, 251, 0.06), transparent 60%),
              radial-gradient(circle at 70% 50%, rgba(79, 172, 254, 0.06), transparent 60%);
  animation: contactGlow 6s ease-in-out infinite alternate;
}

@keyframes contactGlow {
  0% { transform: translate(0, 0); }
  100% { transform: translate(10px, -10px); }
}

.contact-info h2 {
  color: #fff;
  position: relative;
  z-index: 1;
}

.contact-info h2::after {
  background: linear-gradient(90deg, #f5576c, #f093fb);
}

.contact-info p {
  position: relative;
  z-index: 1;
  font-size: 18px;
  line-height: 2;
  opacity: 0.95;
}

/* ===== Footer ===== */
footer {
  background: #0d0d1a;
  color: #fff;
  padding: 50px 0 40px;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

footer a {
  color: #f5576c;
  text-decoration: none;
  transition: color 0.3s;
}

footer a:hover {
  color: #f093fb;
  text-decoration: underline;
}

footer .links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 25px;
}

footer .links a {
  font-size: 15px;
  padding: 5px 0;
}

footer p {
  font-size: 14px;
  opacity: 0.8;
  line-height: 1.8;
}

/* ===== Back to Top ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: linear-gradient(135deg, #f5576c, #f093fb);
  color: #fff;
  border: none;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  font-size: 26px;
  cursor: pointer;
  display: none;
  z-index: 999;
  transition: opacity 0.3s, transform 0.3s, box-shadow 0.3s;
  box-shadow: 0 6px 25px rgba(245, 87, 108, 0.4);
}

.back-to-top.show {
  display: block;
  animation: fadeInUp 0.4s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.back-to-top:hover {
  transform: scale(1.1) translateY(-3px);
  box-shadow: 0 10px 35px rgba(245, 87, 108, 0.6);
}

.back-to-top:active {
  transform: scale(0.95);
}

/* ===== Search Bar ===== */
.search-bar {
  display: flex;
  justify-content: center;
  margin: 20px 0;
}

.search-bar input {
  padding: 14px 24px;
  border-radius: 30px 0 0 30px;
  border: 2px solid transparent;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  width: 320px;
  font-size: 16px;
  color: inherit;
  transition: border-color 0.3s, background 0.3s;
  outline: none;
}

.search-bar input:focus {
  border-color: #f5576c;
  background: rgba(255, 255, 255, 0.15);
}

.dark-mode .search-bar input {
  background: rgba(255, 255, 255, 0.05);
  color: #e0e0e0;
}

.search-bar input::placeholder {
  color: #999;
}

.dark-mode .search-bar input::placeholder {
  color: #666;
}

.search-bar button {
  padding: 14px 24px;
  border-radius: 0 30px 30px 0;
  border: none;
  background: linear-gradient(135deg, #f5576c, #f093fb);
  color: #fff;
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  transition: transform 0.3s, box-shadow 0.3s;
}

.search-bar button:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 20px rgba(245, 87, 108, 0.4);
}

/* ===== Lazy Loading ===== */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.6s ease;
}

img[loading="lazy"].loaded {
  opacity: 1;
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .hero h1 {
    font-size: 42px;
  }
  
  .stat-number {
    font-size: 44px;
  }
}

@media (max-width: 768px) {
  .header-inner {
    flex-direction: column;
    gap: 15px;
  }

  nav ul {
    justify-content: center;
    gap: 18px;
  }

  nav a {
    font-size: 14px;
  }

  .hero {
    padding: 80px 0 60px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .hero p {
    font-size: 17px;
  }

  .hero .btn {
    padding: 14px 36px;
    font-size: 16px;
  }

  .banner-slider {
    height: 60px;
  }

  .banner-slide {
    font-size: 15px;
    padding: 15px;
  }

  h2 {
    font-size: 28px;
    margin-bottom: 35px;
  }

  .grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .card {
    padding: 25px 20px;
  }

  .stat-grid {
    gap: 20px;
  }

  .stat-number {
    font-size: 36px;
  }

  .stat-item {
    min-width: 120px;
    padding: 15px;
  }

  .contact-info {
    padding: 40px 20px;
    border-radius: 20px;
  }

  .contact-info p {
    font-size: 16px;
  }

  .search-bar input {
    width: 200px;
    padding: 12px 16px;
  }

  .search-bar button {
    padding: 12px 16px;
  }

  footer .links {
    gap: 16px;
  }

  .back-to-top {
    width: 44px;
    height: 44px;
    font-size: 22px;
    bottom: 20px;
    right: 20px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 26px;
  }

  .hero p {
    font-size: 15px;
  }

  .hero .btn {
    padding: 12px 28px;
    font-size: 15px;
  }

  .banner-slide {
    font-size: 13px;
  }

  h2 {
    font-size: 24px;
  }

  .stat-number {
    font-size: 28px;
  }

  .faq-question {
    font-size: 16px;
  }
}

/* ===== Selection ===== */
::selection {
  background: #f5576c;
  color: #fff;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.dark-mode ::-webkit-scrollbar-track {
  background: #1a1a2e;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #f5576c, #f093fb);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #f093fb, #f5576c);
}

/* ===== Additional Animations ===== */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.stat-item:nth-child(1) { animation: float 4s ease-in-out infinite; }
.stat-item:nth-child(3) { animation: float 4s ease-in-out infinite 1s; }

/* ===== Utility ===== */
.text-gradient {
  background: linear-gradient(135deg, #f5576c, #f093fb);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ===== Dark Mode Toggle Animation ===== */
body.dark-mode .dark-toggle {
  background: linear-gradient(135deg, #4facfe, #43e97b);
  box-shadow: 0 4px 15px rgba(79, 172, 254, 0.4);
}

body.dark-mode .dark-toggle:hover {
  box-shadow: 0 6px 25px rgba(79, 172, 254, 0.6);
}