/* ================================================
   About Page - Editorial / Cyber Aesthetic
   ================================================ */

.about-page {
  background: var(--bg-base);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

/* Controls */
.back-btn {
  position: fixed;
  top: 24px;
  left: 24px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(12px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.back-btn svg {
  width: 16px;
  height: 16px;
  transition: transform 0.3s ease;
}

.back-btn:hover {
  color: var(--text-primary);
  border-color: var(--border-strong);
  box-shadow: var(--glow);
}

.back-btn:hover svg {
  transform: translateX(-4px);
}

.theme-toggle-btn {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 100;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  cursor: pointer;
  backdrop-filter: blur(12px);
  transition: all 0.3s ease;
}

.theme-toggle-btn:hover {
  color: var(--accent);
  border-color: var(--border-strong);
  box-shadow: var(--glow);
}

.theme-toggle-btn svg {
  width: 20px;
  height: 20px;
}

[data-theme="dark"] .sun-icon { display: block; }
[data-theme="dark"] .moon-icon { display: none; }
[data-theme="light"] .sun-icon { display: none; }
[data-theme="light"] .moon-icon { display: block; }

/* Layout */
.about-layout {
  display: flex;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
  z-index: 10;
}

/* Left Sidebar */
.profile-sidebar {
  width: 380px;
  flex-shrink: 0;
  border-right: 1px solid var(--border);
  position: relative;
  background: linear-gradient(to right, transparent, rgba(0,0,0,0.02));
}

[data-theme="dark"] .profile-sidebar {
  background: linear-gradient(to right, transparent, rgba(255,255,255,0.01));
}

.profile-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 100px 40px 40px;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

/* Avatar overrides for About page */
.about-page .avatar-3d {
  width: 140px;
  height: 140px;
  margin-bottom: 32px;
}

.about-page .avatar {
  width: 116px;
  height: 116px;
}

.profile-name {
  font-family: var(--font-display);
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.profile-title {
  font-family: var(--font-body);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 16px;
  letter-spacing: 0.1em;
}

.profile-tagline {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 6px 12px;
  background: var(--tag-bg);
  border: 1px solid var(--tag-border);
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 40px;
}

.profile-contacts {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 40px;
}

.contact-link {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-decoration: none;
  transition: transform 0.2s ease;
}

a.contact-link:hover {
  transform: translateX(4px);
}

.contact-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.1em;
}

.contact-value {
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 500;
  transition: color 0.2s ease;
}

a.contact-link:hover .contact-value {
  color: var(--accent);
}

.profile-socials {
  display: flex;
  gap: 16px;
  margin-top: auto;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition:
    color 0.25s ease,
    border-color 0.25s ease,
    background-color 0.25s ease,
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.social-icon__glyph {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  display: block;
}

.social-icon__glyph--bilibili,
.social-icon__glyph--reddit {
  background-color: currentColor;
  -webkit-mask: center / contain no-repeat;
  mask: center / contain no-repeat;
}

.social-icon__glyph--bilibili {
  -webkit-mask-image: url("../../../assets/icons/bilibili.svg");
  mask-image: url("../../../assets/icons/bilibili.svg");
}

.social-icon__glyph--reddit {
  -webkit-mask-image: url("../../../assets/icons/reddit.svg");
  mask-image: url("../../../assets/icons/reddit.svg");
}

.social-icon:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--tag-bg);
  transform: translateY(-4px);
  box-shadow: var(--glow);
}

.social-icon:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Right Content */
.content-scroll {
  flex: 1;
  padding: 100px 80px 60px;
  max-width: 900px;
}

.about-section {
  margin-bottom: 80px;
  opacity: 0;
  animation: fadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.about-section:nth-child(1) { animation-delay: 0.1s; }
.about-section:nth-child(2) { animation-delay: 0.2s; }
.about-section:nth-child(3) { animation-delay: 0.3s; }
.about-section:nth-child(4) { animation-delay: 0.4s; }

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

.section-heading {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 32px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.section-heading::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* Intro Text */
.intro-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 28px;
}

.intro-text p {
  font-family: var(--font-display);
  font-size: 1.4rem;
  line-height: 1.6;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

/* Timeline */
.timeline-item {
  position: relative;
  padding-left: 32px;
}

.timeline-marker {
  position: absolute;
  left: 0;
  top: 8px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-base);
  border: 3px solid var(--accent);
  box-shadow: 0 0 0 4px var(--tag-bg);
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 24px;
  bottom: -40px;
  width: 2px;
  background: var(--border);
}

.timeline-item:last-child::before {
  display: none;
}

.timeline-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 8px;
}

.timeline-header h4 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
}

.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.timeline-sub {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.timeline-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Certifications */
.cert-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.cert-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.cert-card:hover {
  transform: translateY(-8px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-lg);
}

.cert-img {
  width: 100%;
  height: 180px;
  position: relative;
  overflow: hidden;
  background: var(--bg-secondary);
}

.cert-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.cert-card:hover .cert-img img {
  transform: scale(1.05);
}

.cert-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(4px);
}

.cert-overlay span {
  background: var(--accent);
  color: #fff;
  padding: 8px 16px;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  transform: translateY(10px);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.cert-card:hover .cert-overlay {
  opacity: 1;
}

.cert-card:hover .cert-overlay span {
  transform: translateY(0);
}

.cert-info {
  padding: 20px;
}

.cert-info h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.cert-info p {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Skills */
.skill-category {
  margin-bottom: 32px;
}

.skill-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 16px;
  letter-spacing: 0.05em;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.skill-tag {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  padding: 6px 14px;
  border-radius: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.skill-tag img,
.skill-tag svg {
  width: 14px;
  height: 14px;
  object-fit: contain;
  flex-shrink: 0;
}

.skill-tag:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
  border-color: var(--border-strong);
  transform: translateY(-2px);
}

.skill-tag.primary {
  background: var(--text-primary);
  color: var(--bg-base);
  border-color: var(--text-primary);
}

.skill-tag.primary:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.skill-tag.highlight {
  background: var(--tag-bg);
  color: var(--accent);
  border-color: var(--tag-border);
  font-weight: 600;
}

.skill-tag.ai-tool {
  border-color: var(--accent);
  color: var(--accent);
}

.about-footer {
  margin-top: 80px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Responsive */
@media (max-width: 1024px) {
  .profile-sidebar {
    width: 320px;
  }
  .profile-sticky {
    padding: 80px 32px 32px;
  }
  .content-scroll {
    padding: 80px 40px 60px;
  }
}

@media (max-width: 768px) {
  .about-layout {
    flex-direction: column;
  }
  .profile-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .profile-sticky {
    position: relative;
    height: auto;
    padding: 100px 24px 40px;
    align-items: center;
    text-align: center;
  }
  .about-page .avatar-3d {
    width: 120px;
    height: 120px;
    margin-bottom: 24px;
  }
  .about-page .avatar {
    width: 100px;
    height: 100px;
  }
  .profile-contacts {
    align-items: center;
  }
  .content-scroll {
    padding: 60px 24px;
  }
  .intro-text p {
    font-size: 1.2rem;
  }
  .intro-title {
    font-size: 1.75rem;
    margin-bottom: 20px;
  }
}

@media (max-width: 480px) {
  .about-page .avatar-3d {
    width: 100px;
    height: 100px;
  }
  .about-page .avatar {
    width: 80px;
    height: 80px;
  }
  .profile-name {
    font-size: 2rem;
  }
  .profile-title {
    font-size: 1.1rem;
  }
  .content-scroll {
    padding: 40px 16px;
  }
  .cert-grid {
    grid-template-columns: 1fr;
  }
}
