    :root {
      --primary-color: #3a86ff;
      --secondary-color: #8338ec;
      --background-color: #f8f9fa;
      --card-background: #ffffff;
      --text-color: #343a40;
      --shadow-color: rgba(0, 0, 0, 0.1);
    }
    
    body {
      font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
      background-color: var(--background-color);
      margin: 0;
      padding: 0;
      color: var(--text-color);
      transition: all 0.3s ease;
    }
    
    .header {
      text-align: center;
      padding: 2rem 0;
      background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
      color: white;
      margin-bottom: 2rem;
      box-shadow: 0 4px 6px var(--shadow-color);
    }
    
    .header h1 {
      margin: 0;
      font-size: 2.5rem;
      font-weight: 700;
    }
    
    .header p {
      margin-top: 0.5rem;
      opacity: 0.9;
    }
    
    .container {
      max-width: 1200px;
      margin: 0 auto;
      padding: 0 20px;
    }
    
    .gallery {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
      gap: 1.5rem;
      padding: 1rem;
    }
    
    .certificate-card {
      background-color: var(--card-background);
      border-radius: 10px;
      overflow: hidden;
      box-shadow: 0 5px 15px var(--shadow-color);
      transition: transform 0.3s ease, box-shadow 0.3s ease;
      cursor: pointer;
      position: relative;
    }
    
    .certificate-card:hover {
      transform: translateY(-5px);
      box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    }
    
    .certificate-img {
      position: relative;
      overflow: hidden;
      padding-top: 65%; /* Aspect ratio */
      background-color: #f0f0f0;
    }
    
    .gallery-item {
      position: absolute;
      top: 0;
      left: 0;
      width: 100%;
      height: 100%;
      object-fit: cover;
      transition: transform 0.5s ease;
    }
    
    .certificate-card:hover .gallery-item {
      transform: scale(1.05);
    }
    
    .certificate-info {
      padding: 1rem;
      text-align: center;
    }
    
    .certificate-title {
      margin: 0;
      font-size: 1.1rem;
      font-weight: 600;
      color: var(--text-color);
    }
    
    .certificate-issuer {
      color: #6c757d;
      font-size: 0.9rem;
      margin-top: 0.5rem;
      display: block;
    }
    
    .pdf-indicator {
      position: absolute;
      top: 10px;
      right: 10px;
      background-color: rgba(255, 255, 255, 0.9);
      color: #dc3545;
      padding: 5px 10px;
      border-radius: 15px;
      font-size: 0.75rem;
      font-weight: 600;
      box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    }
    
    .modal {
      display: none;
      position: fixed;
      z-index: 1000;
      left: 0;
      top: 0;
      width: 100%;
      height: 100%;
      background-color: rgba(0, 0, 0, 0.9);
      opacity: 0;
      transition: opacity 0.3s ease;
    }
    
    .modal.active {
      opacity: 1;
    }
    
    .modal-content-wrapper {
      display: flex;
      flex-direction: column;
      justify-content: center;
      align-items: center;
      height: 100%;
      padding: 2rem;
    }
    
    .modal-content {
      max-width: 90%;
      max-height: 85vh;
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
      border-radius: 5px;
      opacity: 0;
      transform: scale(0.9);
      transition: all 0.3s ease;
    }
    
    .modal.active .modal-content {
      opacity: 1;
      transform: scale(1);
    }
    
    .pdf-viewer {
      width: 200%;
      height: 65vh;
      border: none;
    }
    
    .modal-controls {
      width: 90%;
      display: flex;
      justify-content: space-between;
      color: white;
      margin-top: 1rem;
    }
    
    .modal-title {
      color: white;
      margin-bottom: 1rem;
      font-size: 1.5rem;
      text-align: center;
    }
    
    .nav-button, .close-button {
      background-color: rgba(255, 255, 255, 0.2);
      color: white;
      border: none;
      border-radius: 50%;
      width: 40px;
      height: 40px;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: background-color 0.2s ease;
    }
    
    .nav-button:hover, .close-button:hover {
      background-color: rgba(255, 255, 255, 0.4);
    }
    
    .close-button {
      position: absolute;
      top: 20px;
      right: 20px;
    }
    
    /* Responsive adjustments */
    @media (max-width: 768px) {
      .gallery {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
      }
      
      .modal-content {
        max-width: 95%;
      }
    }
    
    /* Loading animation */
    .loading-spinner {
      display: inline-block;
      width: 50px;
      height: 50px;
      border: 3px solid rgba(255, 255, 255, 0.3);
      border-radius: 50%;
      border-top-color: white;
      animation: spin 1s ease-in-out infinite;
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
    }
    
    @keyframes spin {
      to { transform: translate(-50%, -50%) rotate(360deg); }
    }
    
    /* Dark mode toggle */
    .theme-toggle {
      position: fixed;
      bottom: 20px;
      right: 20px;
      background-color: var(--primary-color);
      color: white;
      border: none;
      border-radius: 50%;
      width: 50px;
      height: 50px;
      font-size: 1.5rem;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
      z-index: 100;
      transition: background-color 0.3s ease;
    }
    
    .theme-toggle:hover {
      background-color: var(--secondary-color);
    }
    
    /* Dark mode colors */
    body.dark-mode {
      --background-color: #121212;
      --card-background: #1e1e1e;
      --text-color: #e0e0e0;
      --shadow-color: rgba(0, 0, 0, 0.4);
    }