* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scrollbar-gutter: stable;
}

:root {
  --primary: #ff1d43;
  --secondary: #1a1a1a;
  --accent: #00d4ff;
  --bg-dark: #00041a;
  --bg-light: #1a1a1a;
  --text-primary: #ffffff;
  --text-secondary: #b0b0b0;
  --text-tertiary: #000000;
  --color-hy: #ff0038;
  --color-lmp2: #355789;
  --color-gt3: #00a255;
  --color-gte: #006233;
  --modal-bg: #080c21;
  --modal-header: #0e0f10;
  --modal-footer: #0e0f10;
  --gradient: linear-gradient(135deg, #ff1d43 0%, #f95772 100%);
  --gradient-hy: linear-gradient(135deg, #e21e19 0%, #ff4f6e 100%);
  --gradient-lmp2: linear-gradient(135deg, #005096 0%, #5f7fa6 100%);
  --gradient-lmp3: linear-gradient(135deg, #ff5f00 0%, #ff914d 100%);
  --gradient-gt3: linear-gradient(135deg, #009439 0%, #33c47d 100%);
  --gradient-gte: linear-gradient(135deg, #f08c00 0%, #ae864e 100%);
  --glass: rgba(255, 255, 255, 0.1);
}

body {
  font-family: "Bai Jamjuree", sans-serif;
  background: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(15, 15, 15, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 1000;
  transition: all 0.3s ease;
}

.header-categories {
  position: fixed;
  top: 0;
  width: 100%;
  background: rgba(15, 15, 15, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 1000;
  transition: all 0.3s ease;
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.logo {
  max-width: 200px;
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
}

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

.nav-links a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient);
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: radial-gradient(
      circle at 20% 50%,
      rgba(255, 107, 53, 0.1) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 20%,
      rgba(0, 212, 255, 0.1) 0%,
      transparent 50%
    ),
    var(--bg-dark);
}

.hero-content {
  text-align: center;
  max-width: 800px;
  padding: 0 2rem;
  animation: fadeInUp 1s ease-out;
}

.logo-section {
  max-width: 100%;
}

.hero h1 {
  font-size: clamp(2.5rem, 8vw, 4rem);
  font-weight: 800;
  margin-bottom: 1rem;
  background: linear-gradient(135deg, #ffffff 0%, #ff1d43 50%, #00d4ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero p {
  font-size: 1.2rem;
  color: var(--text-primary);
  margin-bottom: 2rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.cta-button {
  display: inline-block;
  padding: 1rem 2rem;
  background: var(--gradient);
  color: white;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 20px 40px #ce0b2c3a;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 40px #ff1d4355;
}

/* Categories Grid */
.categories {
  padding: 4rem 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 3rem;
  color: var(--text-primary);
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

.category-card {
  height: 450px;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-blend-mode: overlay;
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 20px;
  padding: 2rem;
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.3s ease;
  overflow: hidden;
  text-align: center;
}

.category-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  transition: background-color 0.3s ease;
  pointer-events: none;
  z-index: 1;
}

.category-card:hover::before {
  background-color: rgba(0, 0, 0, 0.4);
}

.category-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
  box-shadow: 0 10px 30px #ff1d4336;
}

.category-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-image: inherit;
  transition: transform 0.5s ease;
  z-index: 0;
}

.category-card:hover::after {
  transform: scale(1.1);
}

.category-card h2 {
  font-size: 2.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  z-index: 2;
  position: relative;
}

/* Stats Section */
.stats {
  background: var(--bg-light);
  padding: 4rem 2rem;
  margin: 4rem 0;
}

.stats-container {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.stat-item {
  text-align: center;
  padding: 2rem;
}

.stat-number {
  font-size: 3rem;
  font-weight: 800;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Footer */
.footer {
  background: var(--primary);
  padding: 3rem 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  max-width: 1200px;
  margin: 0 auto;
  gap: 3rem;
  flex-wrap: wrap; /* ✅ responsive fallback */
}

.footer-left {
  flex: 1;
  min-width: 250px;
}

.footer-right {
  flex: 1.5;
  min-width: 300px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.footer a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}

.footer a:hover {
  color: #00f0ff;
  text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.footer-logo img {
  height: 35px;
  width: auto;
  margin-bottom: 1rem;
}

/* Mobile Menu */
.mobile-menu {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 5px;
}

.mobile-menu span {
  width: 25px;
  height: 3px;
  background: var(--text-primary);
  transition: all 0.3s ease;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive */
@media (max-width: 1200px) {
  .categories-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(15, 15, 15, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1rem;
    gap: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-links a:hover {
    color: var(--text-primary);
  }

  .nav-links.active {
    display: flex;
  }

  .nav-links a:hover::after {
    width: 0;
  }

  .mobile-menu {
    display: flex;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .nav {
    padding: 1rem;
  }

  .plugin-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }

  .categories-grid {
    grid-template-columns: 1fr;
  }

  .footer-content {
    flex-direction: column;
    gap: 2rem;
    align-items: center;
    text-align: center;
  }

  .footer-left,
  .footer-right {
    flex: unset;
    min-width: auto;
  }
}

@media (max-width: 379px) {
  .nav-categories-link img {
    width: 150px;
  }
}

@media (max-width: 340px) {
  .breadcrumb-category {
    display: none;
  }
}
