/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Ubuntu Mono", "Fira Code", monospace;
  background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
  color: #ffffff;
  overflow-x: hidden;
  min-height: 100vh;
}

/* Loading Screen */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
}

.loading-content {
  text-align: center;
  max-width: 500px;
}

.loading-logo {
  font-size: 4rem;
  color: #00ff41;
  margin-bottom: 2rem;
  animation: pulse 2s infinite;
}

.loading-text {
  margin-bottom: 3rem;
}

.loading-line {
  font-size: 1.1rem;
  color: #00ff41;
  margin-bottom: 0.5rem;
  opacity: 0;
  animation: typewriter 0.8s ease forwards;
}

.loading-line:nth-child(1) {
  animation-delay: 0.5s;
}
.loading-line:nth-child(2) {
  animation-delay: 1.5s;
}
.loading-line:nth-child(3) {
  animation-delay: 2.5s;
}

.loading-progress {
  width: 100%;
  height: 4px;
  background: #333;
  border-radius: 2px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #00ff41, #00cc33);
  width: 0%;
  animation: loading 3s ease-in-out forwards;
  animation-delay: 1s;
}

/* Main Content */
.main-content {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease;
}

.main-content.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Header */
.header {
  background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
  border-bottom: 2px solid #00ff41;
  box-shadow: 0 4px 20px rgba(0, 255, 65, 0.2);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}

.back-btn {
  background: rgba(0, 255, 65, 0.1);
  border: 2px solid #00ff41;
  color: #00ff41;
  padding: 0.75rem 1.5rem;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: inherit;
  font-size: 1rem;
  transition: all 0.3s ease;
  text-decoration: none;
}

.back-btn:hover {
  background: rgba(0, 255, 65, 0.2);
  transform: translateX(-5px);
  box-shadow: 0 0 20px rgba(0, 255, 65, 0.4);
}

.page-title {
  color: #00ff41;
  font-size: 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  text-align: center;
  flex: 1;
}

.header-info {
  text-align: right;
}

.developer-name {
  color: #ffffff;
  font-size: 1.1rem;
  font-weight: bold;
}

/* Certificates Container */
.certificates-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 2rem;
}

.certificates-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 2rem;
  animation: fadeInUp 0.8s ease;
}

/* Certificate Card */
.certificate-card {
  background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
  border: 2px solid rgba(0, 255, 65, 0.3);
  border-radius: 12px;
  padding: 2rem;
  transition: all 0.4s ease;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.certificate-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0, 255, 65, 0.1), transparent);
  transition: left 0.6s ease;
}

.certificate-card:hover::before {
  left: 100%;
}

.certificate-card:hover {
  transform: translateY(-10px) scale(1.02);
  border-color: #00ff41;
  box-shadow: 0 20px 40px rgba(0, 255, 65, 0.3);
}

.certificate-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.certificate-icon {
  font-size: 2.5rem;
  color: #00ff41;
  animation: float 3s ease-in-out infinite;
}

.certificate-title {
  color: #00ff41;
  font-size: 1.4rem;
  font-weight: bold;
  line-height: 1.3;
}

.certificate-info {
  margin-bottom: 1.5rem;
}

.certificate-issuer {
  color: #ffffff;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.certificate-date {
  color: #888;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.certificate-description {
  color: #ccc;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.certificate-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.skill-tag {
  background: rgba(0, 255, 65, 0.2);
  color: #00ff41;
  padding: 0.3rem 0.8rem;
  border-radius: 15px;
  font-size: 0.8rem;
  border: 1px solid rgba(0, 255, 65, 0.3);
  transition: all 0.3s ease;
}

.skill-tag:hover {
  background: rgba(0, 255, 65, 0.3);
  transform: scale(1.05);
}

.certificate-actions {
  display: flex;
  gap: 1rem;
}

.verify-btn,
.details-btn {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 2px solid #00ff41;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  text-decoration: none;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.verify-btn {
  background: rgba(0, 255, 65, 0.1);
  color: #00ff41;
}

.verify-btn:hover {
  background: #00ff41;
  color: #000;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 255, 65, 0.4);
}

.details-btn {
  background: transparent;
  color: #00ff41;
}

.details-btn:hover {
  background: rgba(0, 255, 65, 0.1);
  transform: translateY(-2px);
}

.certificate-body {
  margin-bottom: 1.5rem;
}

.certificate-institution,
.certificate-date,
.certificate-duration {
  color: #ccc;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.certificate-institution i,
.certificate-date i,
.certificate-duration i {
  color: #00ff41;
  width: 16px;
}

.certificate-type {
  background: rgba(0, 255, 65, 0.2);
  color: #00ff41;
  padding: 0.3rem 0.8rem;
  border-radius: 15px;
  font-size: 0.8rem;
  border: 1px solid rgba(0, 255, 65, 0.3);
}

.skill-more {
  background: rgba(255, 255, 255, 0.1);
  color: #ccc;
  padding: 0.3rem 0.8rem;
  border-radius: 15px;
  font-size: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.certificate-footer {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.btn-details,
.btn-verify {
  flex: 1;
  padding: 0.75rem 1rem;
  border: 2px solid #00ff41;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  text-decoration: none;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: rgba(0, 255, 65, 0.1);
  color: #00ff41;
}

.btn-details:hover,
.btn-verify:hover {
  background: #00ff41;
  color: #000;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 255, 65, 0.4);
}

.btn-verify:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 10000;
  animation: fadeIn 0.3s ease;
}

.modal.show {
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
  border: 2px solid #00ff41;
  border-radius: 12px;
  max-width: 600px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  animation: slideInUp 0.4s ease;
}

.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid rgba(0, 255, 65, 0.3);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  color: #00ff41;
  font-size: 1.5rem;
}

.modal-close {
  background: none;
  border: none;
  color: #00ff41;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.modal-close:hover {
  background: rgba(255, 0, 0, 0.2);
  color: #ff0000;
  transform: rotate(90deg);
}

.modal-body {
  padding: 2rem;
  color: #ffffff;
  line-height: 1.6;
}

.modal-cert-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: rgba(0, 255, 65, 0.05);
  border-radius: 8px;
  border: 1px solid rgba(0, 255, 65, 0.2);
}

.modal-cert-icon {
  font-size: 3rem;
  color: #00ff41;
}

.modal-cert-info h4 {
  color: #00ff41;
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
}

.modal-institution {
  color: #ccc;
  font-size: 1rem;
  margin-bottom: 0.3rem;
}

.modal-credential {
  color: #888;
  font-size: 0.9rem;
  font-family: monospace;
}

.modal-cert-details {
  margin-bottom: 2rem;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.detail-label {
  color: #00ff41;
  font-weight: bold;
}

.detail-value {
  color: #fff;
}

.modal-description,
.modal-skills {
  margin-bottom: 2rem;
}

.modal-description h5,
.modal-skills h5 {
  color: #00ff41;
  font-size: 1.1rem;
  margin-bottom: 1rem;
  border-bottom: 2px solid rgba(0, 255, 65, 0.3);
  padding-bottom: 0.5rem;
}

.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.skill-badge {
  background: rgba(0, 255, 65, 0.2);
  color: #00ff41;
  padding: 0.4rem 0.8rem;
  border-radius: 15px;
  font-size: 0.85rem;
  border: 1px solid rgba(0, 255, 65, 0.3);
}

.modal-actions {
  text-align: center;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-verify-modal {
  background: linear-gradient(135deg, #00ff41, #00cc33);
  color: #000;
  border: none;
  padding: 1rem 2rem;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-verify-modal:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 255, 65, 0.4);
}

.btn-verify-modal:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* Animations */
@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }
}

@keyframes typewriter {
  0% {
    opacity: 0;
    transform: translateY(20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes loading {
  0% {
    width: 0%;
  }
  100% {
    width: 100%;
  }
}

@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

@keyframes slideInUp {
  0% {
    transform: translateY(50px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .page-title {
    font-size: 1.5rem;
  }

  .certificates-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .certificate-card {
    padding: 1.5rem;
  }

  .certificate-actions {
    flex-direction: column;
  }

  .modal-content {
    width: 95%;
    margin: 1rem;
  }
}

@media (max-width: 480px) {
  .certificates-container {
    padding: 2rem 1rem;
  }

  .header-content {
    padding: 1rem;
  }

  .certificate-title {
    font-size: 1.2rem;
  }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #1a1a1a;
}

::-webkit-scrollbar-thumb {
  background: #00ff41;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #00cc33;
}
