/* ============================================================
   nurain.css — Nur Ain Syuhada Profile Page
   ============================================================ */

/* ---------- CSS Variables & Reset ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg-primary: #0a0a0f;
  --bg-secondary: #12121a;
  --bg-card: rgba(255, 255, 255, 0.03);
  --text-primary: #ffffff;
  --text-secondary: #a0a0b0;
  --accent-cyan: #00f5ff;
  --accent-blue: #0066ff;
  --accent-purple: #8b5cf6;
  --accent-pink: #ff6b9d;
  --glow-cyan: 0 0 40px rgba(0, 245, 255, 0.3);
  --glow-blue: 0 0 40px rgba(0, 102, 255, 0.3);
  --border-glass: rgba(255, 255, 255, 0.08);
  --gradient-1: linear-gradient(135deg, #00f5ff 0%, #0066ff 100%);
  --gradient-2: linear-gradient(135deg, #8b5cf6 0%, #ff6b9d 100%);
}

[data-theme="light"] {
  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;
  --bg-card: rgba(0, 0, 0, 0.03);
  --text-primary: #0a0a0f;
  --text-secondary: #64748b;
  --border-glass: rgba(0, 0, 0, 0.08);
}

[data-theme="night"] {
  --text-primary: #d4af37;
  --text-secondary: #b8860b;
  --bg-primary: #0d1117;
  --bg-secondary: #161b22;
  --bg-card: rgba(30, 40, 45, 0.9);
  --accent-cyan: #b8860b;
  --accent-blue: #a57c00;
  --accent-purple: #8b7500;
  --border-glass: rgba(56, 73, 91, 0.12);
}

[data-theme="night"] .article-card,
[data-theme="night"] .stat-card,
[data-theme="night"] .edu-card,
[data-theme="night"] .skill-tag,
[data-theme="night"] .tech-icon {
  background: var(--bg-card);
  border-color: var(--border-glass);
  color: var(--text-primary);
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  overflow-x: hidden;
  transition: all 0.5s ease;
}

/* ---------- Theme Toggle Button ---------- */
.theme-toggle-masli {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 2147483640;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid var(--border-glass);
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: var(--glow-cyan);
  transition: all 0.3s ease;
}

.theme-toggle-masli:hover {
  background: var(--gradient-1);
  border-color: transparent;
  transform: scale(1.08) rotate(15deg);
  color: #fff;
}

[data-theme="night"] .theme-toggle-masli {
  border-color: rgba(184, 134, 11, 0.3);
  box-shadow: 0 0 20px rgba(184, 134, 11, 0.4);
}

[data-theme="night"] .theme-toggle-masli:hover {
  background: linear-gradient(135deg, #b8860b 0%, #d4af37 100%);
  border-color: transparent;
  transform: scale(1.08) rotate(15deg);
  box-shadow: 0 0 30px rgba(184, 134, 11, 0.6);
}

/* ---------- Hero Section ---------- */
/* Hero — aligned to Masli/Fatin people concept */
.hero {
  position: relative;
  min-height: 90vh;
  min-height: 90dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 96px 20px 48px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,0.45) 0%, rgba(0,0,0,0.75) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  width: 100%;
  padding: 20px;
  text-align: center;
  margin: 0 auto;
}

.hero-avatar {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent-cyan);
  margin: 0 auto 24px;
  box-shadow: var(--glow-cyan);
  background: var(--bg-card);
}

.hero-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

/* keep legacy avatar selectors if any remaining markup */
.avatar-container {
  position: relative;
  width: 180px;
  height: 180px;
  margin: 0 auto 24px;
}
.avatar {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--accent-cyan);
  box-shadow: var(--glow-cyan);
  background: var(--bg-card);
}
.avatar img,
.avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}
.avatar-ring {
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border: 2px solid var(--accent-cyan);
  border-radius: 50%;
  pointer-events: none;
}

.hero h1,
h1 {
  font-size: 42px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 8px;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -1px;
}

.hero .title,
.title {
  font-size: 18px;
  font-weight: 600;
  color: var(--accent-cyan);
  margin-bottom: 12px;
}

.hero .tagline,
.tagline {
  font-size: 16px;
  color: var(--text-secondary);
  line-height: 1.7;
  max-width: 600px;
  margin: 0 auto 24px;
}

.hero-info {
  display: flex;
  gap: 24px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.hero-info span,
.hero-info a {
  font-size: 14px;
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-decoration: none;
}

/* legacy contact row (Fatin-style) still ok if present */
.contact-info {
  display: flex;
  justify-content: center;
  gap: 24px;
  flex-wrap: wrap;
  margin: 0 0 32px;
  font-size: 14px;
  color: var(--text-secondary);
}
.contact-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.tech-stack {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 50px;
}

.tech-icon {
  width: 60px;
  height: 60px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.tech-icon:hover {
  transform: translateY(-5px);
  background: var(--gradient-1);
  box-shadow: var(--glow-cyan);
  border-color: transparent;
}

/* ---------- Stats Section ---------- */
.stats {
  padding: 100px 20px;
  background: var(--bg-secondary);
}

.stats-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 24px;
  padding: 30px;
  text-align: center;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.stat-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}

.stat-number {
  font-size: 48px;
  font-weight: 800;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ---------- Experience Timeline ---------- */
.experience {
  padding: 100px 20px;
}

.section-title {
  text-align: center;
  font-size: 42px;
  font-weight: 800;
  margin-bottom: 60px;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.timeline {
  max-width: 1000px;
  margin: 0 auto;
  position: relative;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 100%;
  background: var(--gradient-1);
}

.timeline-item {
  display: flex;
  justify-content: flex-end;
  padding-right: 50px;
  margin-bottom: 40px;
  position: relative;
  width: 50%;
}

.timeline-item:nth-child(even) {
  justify-content: flex-start;
  padding-right: 0;
  padding-left: 50px;
  margin-left: 50%;
}

.timeline-content {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 24px;
  max-width: 400px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.timeline-content:hover {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
  transform: scale(1.02);
}

.timeline-dot {
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: var(--glow-cyan);
}

.timeline-item:nth-child(even) .timeline-dot {
  right: auto;
  left: -8px;
}

.timeline-year {
  font-size: 14px;
  color: var(--accent-cyan);
  font-weight: 700;
  margin-bottom: 8px;
}

.timeline-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.timeline-company {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-weight: 500;
}

.timeline-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---------- Education Section ---------- */
.education {
  padding: 100px 20px;
  background: var(--bg-secondary);
}

.edu-grid {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.edu-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  padding: 30px;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.edu-card:hover {
  border-color: var(--accent-purple);
  box-shadow: 0 0 40px rgba(139, 92, 246, 0.3);
  transform: translateY(-5px);
}

.edu-year {
  font-size: 14px;
  color: var(--accent-purple);
  font-weight: 700;
  margin-bottom: 8px;
}

.edu-degree {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.edu-school {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.edu-grade {
  display: inline-block;
  padding: 6px 16px;
  background: var(--gradient-2);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  color: white;
}

/* ---------- Skills Section ---------- */
.skills {
  padding: 100px 20px;
}

.skills-container {
  max-width: 1000px;
  margin: 0 auto;
}

.skill-category {
  margin-bottom: 40px;
}

.skill-category-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text-primary);
}

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

.skill-tag {
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 25px;
  font-size: 14px;
  color: var(--text-secondary);
  transition: all 0.3s ease;
  cursor: pointer;
}

.skill-tag:hover {
  background: var(--gradient-1);
  border-color: transparent;
  color: white;
  box-shadow: var(--glow-cyan);
  transform: translateY(-2px);
}

/* ---------- Explorer Section ---------- */
.explore-section {
  padding: 100px 10%;
  position: relative;
}

.explore-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 25px;
  margin-top: 50px;
}

.explore-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 40px 30px;
  text-align: center;
  transition: all 0.3s ease;
}

.explore-card:hover {
  transform: translateY(-10px);
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}

.explore-icon {
  font-size: 48px;
  margin-bottom: 20px;
}

.explore-number {
  font-size: 48px;
  font-weight: 800;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 10px;
  white-space: nowrap;
}

.explore-label {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 15px;
}

.explore-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---------- Article Cards ---------- */
.articles-section {
  padding: 100px 10%;
  background: var(--bg-secondary);
}

.articles-grid {
  max-width: 1200px;
  margin: 0 auto;
}

.articles-row-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 24px;
}

.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
}

.article-card:hover {
  transform: translateY(-4px);
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}

.article-card-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.article-card-body {
  padding: 20px;
}

.article-card-date {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.article-card-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-excerpt {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  border-top: 1px solid var(--border-glass);
  font-size: 12px;
  color: var(--accent-cyan);
}

.article-compact-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
}

.article-compact-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}

.article-compact-body {
  display: flex;
  gap: 12px;
  padding: 12px;
  align-items: center;
}

.article-small-img {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}

.article-compact-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.article-title-row:hover {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}

.article-title-row-text {
  font-size: 14px;
  color: var(--text-primary);
  font-weight: 500;
}

.article-title-row-arrow {
  color: var(--accent-cyan);
  font-weight: 700;
}

/* ---------- Pagination ---------- */
.articles-actions {
  max-width: 1200px;
  margin: 0 auto 24px;
  text-align: right;
}

.add-article-btn {
  padding: 10px 24px;
  background: var(--gradient-1);
  border: none;
  border-radius: 12px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.add-article-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--glow-cyan);
}

.articles-readmore-wrap {
  max-width: 1200px;
  margin: 30px auto;
  text-align: center;
}

.articles-readmore-btn {
  padding: 14px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 12px;
  color: var(--text-primary);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 15px;
}

.articles-readmore-btn:hover {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
  transform: translateY(-2px);
}

.articles-pagination {
  max-width: 1200px;
  margin: 30px auto;
  text-align: center;
}

.pagination-status {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.pagination-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.pagination-btn {
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 13px;
}

.pagination-btn:hover:not(:disabled) {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}

.pagination-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.pagination-pages {
  display: flex;
  gap: 4px;
}

.pagination-page-btn {
  width: 36px;
  height: 36px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 13px;
}

.pagination-page-btn.active {
  background: var(--gradient-1);
  color: white;
  border-color: transparent;
}

.pagination-page-btn:hover:not(.active) {
  border-color: var(--accent-cyan);
  color: var(--text-primary);
}

.pagination-per-page {
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-secondary);
}

.pagination-per-page select {
  padding: 6px 12px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  color: var(--text-primary);
  font-size: 13px;
  margin-left: 8px;
}

/* ---------- Article Detail Page ---------- */
.article-page .container {
  max-width: 800px;
  margin: 0 auto;
  padding: 100px 20px;
}

.article-page .back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
  margin-bottom: 30px;
}

.article-page .back:hover {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
  color: var(--text-primary);
  transform: translateX(-3px);
}

.edit-btn {
  padding: 8px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 8px;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 13px;
}

.edit-btn:hover {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
  color: var(--text-primary);
}

.article-header {
  margin-bottom: 30px;
}

.article-meta {
  font-size: 13px;
  color: var(--text-secondary);
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 16px;
}

.article-title {
  font-size: 42px;
  font-weight: 800;
  line-height: 1.2;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.article-image {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  border-radius: 16px;
  margin-bottom: 30px;
}

.video-wrapper {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 16px;
  margin-bottom: 30px;
}

.video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.article-byline {
  font-size: 14px;
  color: var(--accent-cyan);
  margin-bottom: 24px;
}

.article-byline a {
  color: inherit;
  text-decoration: none;
}

.article-content {
  font-size: 16px;
  line-height: 1.8;
  color: var(--text-primary);
}

.article-content p {
  margin-bottom: 20px;
}

.article-content h2, .article-content h3 {
  margin-top: 40px;
  margin-bottom: 16px;
}

.article-content img {
  max-width: 100%;
  border-radius: 12px;
  margin: 20px 0;
}

.article-content ul, .article-content ol {
  margin: 16px 0;
  padding-left: 24px;
}

.article-content li {
  margin-bottom: 8px;
}

/* ---------- Summary Box ---------- */
.masli-summary-box {
  margin: 50px 0;
  padding: 30px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  backdrop-filter: blur(10px);
}

.masli-summary-box h2 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text-primary);
  text-align: center;
}

.masli-summary-inner {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.masli-summary-photo {
  flex-shrink: 0;
  width: 150px;
  height: 150px;
  border-radius: 16px;
  overflow: hidden;
  border: 2px solid var(--border-glass);
}

.masli-summary-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.masli-summary-text p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 12px;
}

.masli-summary-text a {
  color: var(--accent-cyan);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}

.masli-summary-text a:hover {
  text-decoration: underline;
}

/* ---------- Share Buttons ---------- */
.share-section {
  margin: 50px 0;
  text-align: center;
}

.share-label {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 16px;
  font-weight: 600;
}

.share-buttons {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.share-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

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

.share-btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--glow-cyan);
}

.share-fb:hover { background: #1877f2; color: white; border-color: #1877f2; }
.share-x:hover { background: #000; color: white; border-color: #000; }
.share-linkedin:hover { background: #0a66c2; color: white; border-color: #0a66c2; }
.share-wa:hover { background: #25d366; color: white; border-color: #25d366; }
.share-copy:hover { background: var(--gradient-1); color: white; border-color: transparent; }
.share-btn.copied svg { stroke: #22c55e; }

/* ---------- Image Modal ---------- */
.img-modal {
  display: none;
  position: fixed;
  z-index: 999999;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.9);
  padding: 40px;
  cursor: pointer;
}

.img-modal.active { display: flex; align-items: center; justify-content: center; }

.img-modal img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  border-radius: 12px;
}

/* ---------- Article Edit Modal ---------- */
.modal-overlay {
  display: none;
  position: fixed;
  z-index: 2147483647;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.85);
  padding: 20px;
  overflow-y: auto;
}

.modal-overlay.active { display: flex; align-items: flex-start; justify-content: center; }

.modal-box {
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  padding: 30px;
  max-width: 700px;
  width: 100%;
  margin-top: 40px;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 28px;
  cursor: pointer;
}

.password-prompt {
  text-align: center;
  padding: 40px 20px;
}

.password-prompt input[type="password"] {
  padding: 12px 20px;
  width: 240px;
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 14px;
  margin: 16px 0;
}

.password-prompt button {
  padding: 12px 28px;
  background: var(--gradient-1);
  border: none;
  border-radius: 10px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  margin-left: 8px;
}

/* ---------- WYSIWYG Editor ---------- */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.form-group input[type="text"],
.form-group input[type="url"],
.form-group input[type="file"] {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 10px;
  color: var(--text-primary);
  font-size: 14px;
}

.form-hint {
  font-size: 12px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.wysiwyg-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 8px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
}

.wysiwyg-toolbar button {
  padding: 6px 12px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 13px;
  transition: all 0.2s;
}

.wysiwyg-toolbar button:hover {
  background: var(--bg-card);
  border-color: var(--border-glass);
  color: var(--text-primary);
}

.wysiwyg-editor {
  min-height: 300px;
  padding: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 0 0 10px 10px;
  color: var(--text-primary);
  font-size: 14px;
  line-height: 1.7;
  outline: none;
}

.wysiwyg-editor:focus {
  border-color: var(--accent-cyan);
}

.modal-delete {
  padding: 10px 24px;
  background: #ef4444;
  border: none;
  border-radius: 10px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-delete:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.modal-submit {
  padding: 10px 28px;
  background: var(--gradient-1);
  border: none;
  border-radius: 10px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.modal-submit:hover {
  transform: translateY(-2px);
  box-shadow: var(--glow-cyan);
}

/* ---------- YouTube Badge ---------- */
.article-youtube-badge {
  display: inline-block;
  padding: 2px 8px;
  background: #ff0000;
  color: white;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  margin-left: 6px;
}

/* ---------- Mobile Responsive ---------- */
@media (max-width: 768px) {
  .hero {
    min-height: auto;
    padding: 88px 16px 36px;
  }
  .hero h1,
  h1 { font-size: 28px; }
  .hero-avatar,
  .avatar-container,
  .avatar {
    width: 140px;
    height: 140px;
  }
  .hero .tagline,
  .tagline {
    font-size: 15px;
    margin-bottom: 18px;
  }
  .hero-info {
    gap: 12px 16px;
    margin-bottom: 24px;
  }
  .tech-stack {
    margin-top: 28px;
    gap: 12px;
  }
  .tech-icon {
    width: 52px;
    height: 52px;
    font-size: 24px;
  }

  h1 { font-size: 42px; }
  .title { font-size: 18px; }
  .section-title { font-size: 32px; }
  .timeline::before { left: 20px; }
  .timeline-item,
  .timeline-item:nth-child(even) {
    width: 100%;
    margin-left: 0;
    padding-left: 50px;
    padding-right: 0;
    justify-content: flex-start;
  }
  .timeline-dot,
  .timeline-item:nth-child(even) .timeline-dot {
    left: 12px;
    right: auto;
  }
  .articles-row-3 {
    grid-template-columns: 1fr;
  }
  .explore-section {
    padding: 60px 5%;
  }
  .explore-number {
    font-size: 32px;
  }
  .explore-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .masli-summary-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .article-title {
    font-size: 28px;
  }
}

/* Hero image pan + zoom */
.hero-bg,
.hero-avatar,
.avatar {
  overflow: hidden;
}
.hero-bg img {
  animation: HakamHeroBgPanZoom 24s ease-in-out infinite alternate;
  transform-origin: center;
  will-change: transform;
}
.hero-avatar img,
.avatar img,
.avatar-img {
  animation: HakamHeroPortraitPanZoom 16s ease-in-out infinite alternate;
  transform-origin: center;
  will-change: transform;
}
@keyframes HakamHeroBgPanZoom {
  0% { transform: scale(1) translate3d(0,0,0); }
  50% { transform: scale(1.10) translate3d(-1.5%, 1%, 0); }
  100% { transform: scale(1.16) translate3d(1.5%, -1%, 0); }
}
@keyframes HakamHeroPortraitPanZoom {
  0% { transform: scale(1) translate3d(0,0,0); }
  100% { transform: scale(1.08) translate3d(0,-1.5%,0); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-bg img,
  .hero-avatar img,
  .avatar img,
  .avatar-img { animation: none !important; transform: none !important; }
}



/* === People layout polish (Masli/Fatin concept) === */
.experience {
  padding: 100px 20px;
}
.timeline {
  max-width: 1000px;
  margin: 0 auto;
  position: relative;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 100%;
  background: var(--gradient-1);
}
.timeline-item {
  display: flex;
  justify-content: flex-end;
  padding-right: 50px;
  margin-bottom: 40px;
  position: relative;
  width: 50%;
}
.timeline-item:nth-child(even) {
  justify-content: flex-start;
  padding-right: 0;
  padding-left: 50px;
  margin-left: 50%;
}
.timeline-content {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 24px;
  max-width: 400px;
  transition: all .3s ease;
  position: relative;
}
.timeline-content:hover {
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
  transform: scale(1.02);
}
.timeline-dot {
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: var(--glow-cyan);
}
.timeline-item:nth-child(even) .timeline-dot {
  right: auto;
  left: -8px;
}
/* when dot is INSIDE content (Masli pattern), pin to card edge */
.timeline-content > .timeline-dot {
  right: -58px;
  left: auto;
}
.timeline-item:nth-child(even) .timeline-content > .timeline-dot {
  right: auto;
  left: -58px;
}
.timeline-year {
  font-size: 14px;
  color: var(--accent-cyan);
  font-weight: 700;
  margin-bottom: 8px;
}
.timeline-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}
.timeline-company {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-weight: 500;
}
.timeline-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
}
.education { padding: 100px 20px; background: var(--bg-secondary); }
.edu-grid {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}
.edu-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 20px;
  padding: 30px;
  transition: all .3s ease;
}
.edu-card:hover {
  border-color: var(--accent-purple, var(--accent-cyan));
  transform: translateY(-5px);
}
.edu-year { font-size: 14px; color: var(--accent-purple, var(--accent-cyan)); font-weight: 700; margin-bottom: 8px; }
.edu-degree { font-size: 18px; font-weight: 700; margin-bottom: 8px; color: var(--text-primary); }
.edu-school { font-size: 14px; color: var(--text-secondary); margin-bottom: 12px; }
.edu-grade {
  display: inline-block;
  padding: 6px 16px;
  background: var(--gradient-2, var(--gradient-1));
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
}
.skills { padding: 100px 20px; }
.skills-container,
.skills-grid {
  max-width: 1000px;
  margin: 0 auto;
}
.skill-category { margin-bottom: 40px; }
.skill-category-title,
.skill-category h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text-primary);
}
.skill-tags { display: flex; flex-wrap: wrap; gap: 12px; }
.skill-tag {
  padding: 10px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 25px;
  font-size: 14px;
  color: var(--text-secondary);
  transition: all .3s ease;
  cursor: default;
}
.skill-tag:hover {
  background: var(--gradient-1);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--glow-cyan);
  transform: translateY(-2px);
}
.stats { padding: 100px 20px; background: var(--bg-secondary); }
.stats-grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
}
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 24px;
  padding: 30px;
  text-align: center;
  transition: all .3s ease;
}
.stat-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}
.stat-number {
  font-size: 48px;
  font-weight: 800;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}
.stat-label { font-size: 14px; color: var(--text-secondary); font-weight: 500; }
.explore-section { padding: 100px 20px; }
.explore-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 25px;
  margin-top: 50px;
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
}
.explore-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  border-radius: 16px;
  padding: 40px 30px;
  text-align: center;
  transition: all .3s ease;
}
.explore-card:hover {
  transform: translateY(-8px);
  border-color: var(--accent-cyan);
  box-shadow: var(--glow-cyan);
}
.section-title {
  text-align: center;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 800;
  margin-bottom: 60px;
  background: var(--gradient-1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
/* light mode: keep hero text readable over dark bg/overlay */
[data-theme="light"] .hero .tagline,
[data-theme="light"] .hero-info span,
[data-theme="light"] .hero-info a {
  color: #cbd5e1;
}
[data-theme="light"] .hero .title {
  color: #a5b4fc;
}
@media (max-width: 768px) {
  .timeline::before { left: 20px; }
  .timeline-item,
  .timeline-item:nth-child(even) {
    width: 100%;
    margin-left: 0;
    padding-left: 50px;
    padding-right: 0;
    justify-content: flex-start;
  }
  .timeline-dot,
  .timeline-item:nth-child(even) .timeline-dot,
  .timeline-content > .timeline-dot,
  .timeline-item:nth-child(even) .timeline-content > .timeline-dot {
    left: 12px;
    right: auto;
  }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .stat-card { padding: 20px 14px; }
  .stat-number { font-size: 32px; }
  .explore-grid { grid-template-columns: 1fr; }
  .experience, .education, .skills, .stats, .explore-section { padding: 60px 16px; }
  .section-title { margin-bottom: 36px; }
}
