* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: #0a0a0a;
  color: #e0e0e0;
  min-height: 100vh;
  line-height: 1.6;
}

.floating-glass {
  background: rgba(18, 18, 18, 0.75);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
}

.navbar {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  border-radius: 20px;
  padding: 8px 24px;
  width: calc(100% - 36px);
  max-width: 1100px;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.nav-logo {
  font-size: 1.6rem;
  font-weight: 700;
  color: #ffffff;
  text-decoration: none;
  letter-spacing: 1px;
  transition: text-shadow 0.3s;
}

.nav-logo:hover {
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.4);
}

.nav-right {
  display: flex;
  align-items: center;
}

.menu-toggle {
  background: none;
  border: none;
  color: #ffffff;
  font-size: 1.3rem;
  cursor: pointer;
  display: block;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-links li {
  position: relative;
}

.nav-links a {
  text-decoration: none;
  color: #b0b0b0;
  font-weight: 500;
  font-size: 1rem;
  padding-bottom: 4px;
  transition: color 0.3s;
  display: inline;
  position: relative;
}

.nav-links a.active-link {
  color: #ffffff;
}

.nav-links a.active-link::after {
  transform: scaleX(1);
}

.nav-links a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background-color: #ffffff;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.nav-links a:hover {
  color: #ffffff;
  text-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
}

.nav-links a:hover::after {
  transform: scaleX(1);
}

main {
  padding-top: 100px;
}

.content-section {
  padding: 5rem 20px;
  max-width: 1100px;
  margin: 0 auto;
}

.section-heading {
  font-size: 2rem;
  font-weight: 700;
  color: #ffffff;
  text-align: center;
  margin-bottom: 3rem;
  letter-spacing: -0.5px;
  position: relative;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
  transition: text-shadow 0.3s ease;
}

.section-heading::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -12px;
  transform: translateX(-50%);
  width: 100px;
  height: 2px;
  background-color: #ffffff;
  opacity: 0.6;
  transition: width 0.3s ease, opacity 0.3s ease;
}

.section-heading:hover {
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.6);
}

.section-heading:hover::after {
  width: 140px;
  opacity: 1;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 1rem;
}

.cert-card {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
  position: relative;
  cursor: pointer;
}

.cert-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  border-color: rgba(255, 255, 255, 0.2);
}

.card-image {
  height: 180px;
  background-size: cover;
  background-position: center;
  background-color: #1a1a1a;
}

.card-image.placeholder {
  background: linear-gradient(135deg, #1a1a1a, #2a2a2a);
}

.card-title {
  padding: 1rem 1rem 0 1rem;
  font-weight: 600;
  font-size: clamp(1rem, 2.5vw, 1.1rem);
  color: #ffffff;
  text-align: center;
  margin: 0 1rem;
  text-shadow: 0 0 8px rgba(255,255,255,0.3);
}

.card-desc {
  padding: 0.5rem 1rem 1rem 1rem;
  color: #cccccc;
  font-weight: 400;
  text-align: center;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-line-clamp: 2;
  line-clamp: 2;
}

.empty-message {
  text-align: center;
  color: #888888;
  grid-column: 1 / -1;
  padding: 2rem;
}

.footer {
  background: rgba(18, 18, 18, 0.9);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding: 16px 24px;
  text-align: center;
  font-size: 0.9rem;
  color: #888888;
  margin-top: 3rem;
}

.reveal-line {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  transition-delay: var(--delay, 0s);
}

.reveal-line.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 768px) {
  .nav-links {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(25px);
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 1rem;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.08);
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
    transition: opacity 0.3s, transform 0.3s;
  }

  .nav-links.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .card-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .section-heading {
    font-size: 1.7rem;
  }

  .content-section {
    padding: 4rem 16px;
  }
}

@media (min-width: 769px) {
  .menu-toggle {
    display: none;
  }

  .nav-links {
    position: static;
    flex-direction: row;
    background: transparent;
    backdrop-filter: none;
    border: none;
    padding: 0;
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  }
