/*-----------------------------------*\
  #GITHUB COMPONENT STYLES
\*-----------------------------------*/

:root {
  --github-accent: var(--orange-yellow-crayola);
  --github-accent-soft: hsla(45, 100%, 72%, 0.1);
  --github-text: var(--light-gray);
  --github-white: var(--white-2);
}

.github { display: none; }
.github.active { display: block; animation: fade 0.5s ease-back; }

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

.github-content {
  display: flex;
  flex-direction: column;
  gap: 25px;
  padding: 20px 0;
}

/* Glassmorphism Utility */
.glassmorphism {
  background: var(--bg-gradient-jet);
  border: 1px solid var(--jet);
  border-radius: 20px;
  padding: 25px;
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  box-shadow: var(--shadow-2);
}

/* --- Modal Detail System --- */
.modal-container#github-detail-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  pointer-events: none;
  visibility: hidden;
}

.modal-container#github-detail-modal.active {
  pointer-events: all;
  visibility: visible;
}

.modal-container#github-detail-modal .overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: hsla(0, 0%, 0%, 0.8);
  backdrop-filter: blur(5px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal-container#github-detail-modal.active .overlay { opacity: 1; }

.github-modal {
  position: relative;
  width: 95%;
  max-width: 650px;
  max-height: 85vh;
  overflow-y: auto;
  z-index: 1001;
  transform: translateY(30px) scale(0.9);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.modal-container#github-detail-modal.active .github-modal {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.github-modal-close-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--onyx);
  color: var(--github-accent);
  font-size: 24px;
  padding: 8px;
  border-radius: 12px;
  transition: var(--transition-1);
}

.github-modal-close-btn:hover {
  background: var(--github-accent);
  color: var(--onyx);
}

/* Modal Content */
.modal-detail-wrapper {
  color: var(--github-white);
}

.modal-header {
  border-bottom: 1px solid var(--jet);
  padding-bottom: 25px;
  margin-bottom: 25px;
}

.repo-main {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
}

.repo-main .main-icon {
  font-size: 40px;
  color: var(--github-accent);
  background: var(--github-accent-soft);
  padding: 10px;
  border-radius: 14px;
}

.repo-full-name {
  color: var(--github-text);
  font-size: 14px;
  font-family: monospace;
  margin-top: 5px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.badge-license {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: hsla(120, 100%, 75%, 0.1);
  color: hsl(120, 100%, 75%);
  padding: 3px 8px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
}

.details-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
}

.details-grid .stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  background: var(--eerie-black-1);
  padding: 12px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  color: var(--white-1);
  box-shadow: inset 0 1px 2px hsla(0, 0%, 100%, 0.05);
}

.details-grid .stat ion-icon {
  font-size: 20px;
  color: var(--github-accent);
}

.tech-metadata-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 15px;
  margin: 25px 0;
}

.meta-item {
  background: var(--eerie-black-2);
  padding: 15px;
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.meta-label {
  font-size: 12px;
  color: var(--light-gray);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.meta-value {
  font-size: 15px;
  color: var(--white-2);
  font-weight: 500;
}

.language-tag {
  align-self: flex-start;
}

@media (max-width: 580px) {
  .details-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.modal-body .description {
  color: var(--github-text);
  line-height: 1.8;
  margin-bottom: 30px;
  font-size: var(--fs-6);
}

.tech-stack h4 {
  color: var(--github-white);
  font-size: var(--fs-7);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.tag {
  display: inline-block;
  background: var(--github-accent-soft);
  color: var(--github-accent);
  padding: 6px 18px;
  border-radius: 20px;
  font-size: var(--fs-8);
  font-weight: var(--fw-600);
  margin-bottom: 5px;
}

.topic-tag {
  background: hsla(200, 100%, 60%, 0.1);
  color: hsl(200, 100%, 70%);
  margin-right: 5px;
  margin-bottom: 8px;
  font-size: 12px;
  padding: 5px 12px;
}

.topics-list {
  margin-bottom: 20px;
}

.topics-list h4 {
  margin-bottom: 10px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.modal-btn {
  flex: 1;
  min-width: 140px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 14px;
  border-radius: 14px;
  font-weight: var(--fw-600);
  font-size: 14px;
  transition: var(--transition-1);
  text-decoration: none;
}

.modal-btn.primary {
  background: var(--github-accent);
  color: var(--onyx);
}

.modal-btn.secondary {
  background: var(--onyx);
  color: var(--github-white);
  border: 1px solid var(--jet);
}

.modal-btn.success {
  background: hsla(120, 80%, 50%, 0.15);
  color: hsl(120, 80%, 70%);
  border: 1px solid hsla(120, 80%, 50%, 0.3);
}

.modal-btn:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); }

/* ===================================================
   PREMIUM GITHUB DASHBOARD
   =================================================== */

/* --- Hero Profile Card --- */
.gh-hero {
  position: relative;
  overflow: hidden;
}

.gh-hero-bg {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 120px;
  background: linear-gradient(135deg, hsla(45, 100%, 72%, 0.15), hsla(280, 100%, 70%, 0.1), hsla(200, 100%, 60%, 0.1));
  border-radius: 20px 20px 0 0;
  z-index: 0;
}

.gh-hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 25px;
  align-items: flex-start;
  padding-top: 30px;
}

.gh-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.gh-avatar {
  width: 110px;
  height: 110px;
  border-radius: 28px;
  border: 3px solid var(--github-accent);
  box-shadow: 0 0 30px var(--github-accent-soft);
  object-fit: cover;
}

.gh-status-dot {
  position: absolute;
  bottom: 5px;
  right: 5px;
  width: 18px;
  height: 18px;
  background: hsl(120, 80%, 50%);
  border: 3px solid var(--eerie-black-1);
  border-radius: 50%;
}

.gh-display-name {
  font-size: 24px;
  font-weight: 700;
  color: var(--white-1);
  margin-bottom: 2px;
}

.gh-handle {
  font-size: 14px;
  color: var(--github-accent);
  font-family: monospace;
  margin-bottom: 8px;
}

.gh-bio {
  font-size: 14px;
  color: var(--light-gray);
  line-height: 1.6;
  margin-bottom: 10px;
}

.gh-meta-line {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--light-gray-70);
  margin-bottom: 4px;
}

.gh-meta-line ion-icon {
  font-size: 16px;
  color: var(--github-accent);
}

.gh-social {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--light-gray);
  margin: 12px 0 16px;
}

.gh-social strong {
  color: var(--white-2);
}

.gh-dot {
  color: var(--jet);
}

.gh-follow-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--github-accent);
  color: var(--eerie-black-1);
  padding: 10px 22px;
  border-radius: 12px;
  font-weight: 600;
  font-size: 14px;
  transition: var(--transition-1);
  text-decoration: none;
}

.gh-follow-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 25px var(--github-accent-soft);
}

@media (max-width: 580px) {
  .gh-hero-content {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .gh-social { justify-content: center; }
}

/* --- Stats Grid --- */
.gh-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 15px;
}

.gh-stat-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 20px;
  border: 1px solid var(--jet);
  border-radius: 18px;
  background: var(--eerie-black-1);
  transition: var(--transition-1);
}

.gh-stat-card:hover {
  transform: translateY(-5px);
  border-color: var(--github-accent);
  box-shadow: 0 0 20px var(--github-accent-soft);
}

.gh-stat-icon {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.gh-stat-icon ion-icon {
  font-size: 24px;
}

.gh-stat-value {
  display: block;
  font-size: 26px;
  font-weight: 700;
  color: var(--white-1);
  line-height: 1.1;
}

.gh-stat-label {
  display: block;
  font-size: 11px;
  color: var(--light-gray-70);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 2px;
}

@media (max-width: 768px) {
  .gh-stats-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 400px) {
  .gh-stats-grid {
    grid-template-columns: 1fr;
  }
}

/* --- Section Cards --- */
.gh-section {
  margin-top: 0;
}

.gh-section-header {
  margin-bottom: 15px;
}

.gh-section-header h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--white-2);
}

.gh-section-header h3 ion-icon {
  color: var(--github-accent);
  font-size: 22px;
}

/* --- Top Repositories --- */
.gh-top-repos {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.gh-top-repo-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 20px;
  background: var(--eerie-black-1);
  border: 1px solid var(--jet);
  border-radius: 16px;
  transition: var(--transition-1);
}

.gh-top-repo-card:hover {
  border-color: var(--github-accent);
  transform: translateX(5px);
  box-shadow: 0 0 15px var(--github-accent-soft);
}

.gh-top-rank {
  font-size: 22px;
  font-weight: 700;
  color: var(--github-accent);
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--github-accent-soft);
  border-radius: 12px;
}

.gh-top-repo-info {
  flex: 1;
  min-width: 0;
}

.gh-top-repo-name {
  font-size: 16px;
  font-weight: 600;
  color: var(--white-2);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gh-top-repo-desc {
  font-size: 13px;
  color: var(--light-gray);
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.gh-top-repo-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--light-gray-70);
}

.gh-top-repo-meta ion-icon {
  font-size: 14px;
  color: var(--github-accent);
  vertical-align: middle;
}

.gh-lang-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 5px;
  vertical-align: middle;
}

.gh-top-repo-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--onyx);
  color: var(--github-accent);
  font-size: 18px;
  transition: var(--transition-1);
  flex-shrink: 0;
}

.gh-top-repo-link:hover {
  background: var(--github-accent);
  color: var(--eerie-black-1);
}

/* --- Activity Feed --- */
.gh-activity-feed {
  position: relative;
  padding-left: 25px;
}

.gh-activity-feed::before {
  content: '';
  position: absolute;
  left: 7px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--jet);
}

.gh-activity-item {
  position: relative;
  padding: 10px 0 15px 0;
  transition: var(--transition-1);
}

.gh-activity-item:last-child { padding-bottom: 0; }

.gh-activity-dot {
  position: absolute;
  left: -22px;
  top: 14px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--github-accent);
  border: 3px solid var(--eerie-black-1);
  z-index: 1;
}

.gh-activity-title {
  font-size: 14px;
  color: var(--white-2);
  margin-bottom: 4px;
}

.gh-activity-title a {
  color: var(--github-accent);
  font-weight: 600;
  text-decoration: none;
}

.gh-activity-title a:hover {
  text-decoration: underline;
}

.gh-activity-desc {
  font-size: 13px;
  color: var(--light-gray);
  line-height: 1.4;
  margin-bottom: 4px;
}

.gh-activity-time {
  font-size: 12px;
  color: var(--light-gray-70);
}

/* --- Tech Stack (Lang Grid enhancements) --- */
.lang-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 15px;
  margin-top: 0;
}

.lang-card {
  background: var(--eerie-black-1);
  padding: 16px;
  border-radius: 14px;
  border: 1px solid transparent;
  transition: var(--transition-1);
}

.lang-card:hover {
  border-color: var(--github-accent);
  box-shadow: 0 0 10px var(--github-accent-soft);
}

.lang-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.lang-name {
  display: flex;
  align-items: center;
  color: var(--white-2);
  font-weight: 500;
  font-size: 14px;
}

.lang-percent {
  color: var(--github-accent);
  font-weight: 600;
  font-size: 14px;
}

.progress-bar {
  height: 6px;
  background: var(--jet);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 1.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}


