/* ============================================================
   PORTFOLIO — Main Stylesheet
   Author: Keshav Prasad Subedi
   ============================================================ */

/* ── Google Fonts ─────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Fira+Code:wght@400;500&family=Playfair+Display:wght@700;800&display=swap');

/* ── CSS Custom Properties (Tokens) ──────────────────────── */
:root {
  /* Palette – Charcoal & Linen (Dark Mode default) */
  --bg-primary: #141414;
  /* deep charcoal */
  --bg-secondary: #1c1c1c;
  /* rich charcoal */
  --bg-card: #242424;
  /* elevated card surface */
  --bg-glass: rgba(36, 36, 36, 0.82);
  --border-color: rgba(245, 240, 232, 0.10);
  /* linen border */

  --accent: #c9a96e;
  /* warm sand gold – primary */
  --accent-light: #e0c48a;
  /* bright linen gold */
  --accent-2: #a07c4a;
  /* deep amber complement */
  --accent-glow: rgba(201, 169, 110, 0.25);

  --text-primary: #f5f0e8;
  /* warm linen white */
  --text-secondary: #b8a898;
  /* muted warm grey */
  --text-muted: #6e5f4f;
  /* dark warm muted */

  --gradient-hero: linear-gradient(140deg, #0e0e0e 0%, #1a1a1a 45%, #141414 100%);
  --gradient-card: linear-gradient(135deg, rgba(201, 169, 110, 0.07) 0%, rgba(160, 124, 74, 0.04) 100%);
  --gradient-btn:  linear-gradient(135deg, #c9a96e 0%, #a07c4a 100%);
  /* Dynamic hero accent gradient — Dark mode */
  --gradient-accent: linear-gradient(90deg, #90CAF9, #BBDEFB);

  /* Minimal & Realistic Shadows — layered near + far, neutral dark */
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.28), 0 4px 14px rgba(0, 0, 0, 0.22);
  --shadow-hover: 0 2px 6px rgba(0, 0, 0, 0.26), 0 10px 28px rgba(0, 0, 0, 0.20);
  --shadow-glow: 0 1px 4px rgba(0, 0, 0, 0.20), 0 4px 12px rgba(201, 169, 110, 0.10);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-xl: 32px;

  --transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --font-main: 'Inter', system-ui, sans-serif;
  --font-code: 'Fira Code', monospace;
  --font-display: 'Playfair Display', Georgia, serif;
}

/* Light mode — Warm Linen / Parchment */
[data-theme="light"] {
  --bg-primary: #f5f0e8;
  /* warm linen */
  --bg-secondary: #ede8de;
  /* deeper linen */
  --bg-card: #fdfaf5;
  /* near-white warm card */
  --bg-glass: rgba(245, 240, 232, 0.90);
  --border-color: rgba(140, 100, 50, 0.15);

  --accent: #8b6230;
  /* deep amber for light bg */
  --accent-light: #a07c4a;
  /* warm mid-amber */
  --accent-2: #6b4a1e;
  /* dark amber */
  --accent-glow: rgba(139, 98, 48, 0.20);

  --text-primary: #1a1410;
  /* deep charcoal ink */
  --text-secondary: #5c4a30;
  /* warm dark brown */
  --text-muted: #9e8a6e;
  /* muted tan */

  --gradient-hero: linear-gradient(140deg, #ede8de 0%, #f5f0e8 50%, #e8e0d4 100%);
  --gradient-card: linear-gradient(135deg, rgba(201, 169, 110, 0.09) 0%, rgba(160, 124, 74, 0.05) 100%);
  /* Dynamic hero accent gradient — Light mode */
  --gradient-accent: linear-gradient(90deg, #1E88E5, #4FC3F7);
  /* Minimal & Realistic Shadows — light mode, neutral warm-dark */
  --shadow-card: 0 1px 2px rgba(20, 16, 10, 0.08), 0 3px 10px rgba(20, 16, 10, 0.07);
  --shadow-hover: 0 2px 5px rgba(20, 16, 10, 0.10), 0 8px 22px rgba(20, 16, 10, 0.09);
  --shadow-glow: 0 1px 3px rgba(20, 16, 10, 0.08), 0 4px 10px rgba(139, 98, 48, 0.08);
  --bg-glass: rgba(245, 240, 232, 0.85);
}

/* ── Reset & Base ─────────────────────────────────────────── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-main);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  min-height: 100vh;
  transition: background 0.4s ease, color 0.4s ease;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

ul {
  list-style: none;
}

button {
  cursor: pointer;
  border: none;
  outline: none;
}

/* ── Preloader ────────────────────────────────────────────── */
#preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 1.5rem;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

#preloader.hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-ring {
  width: 60px;
  height: 60px;
  border: 3px solid var(--border-color);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

.loader-text {
  font-family: var(--font-code);
  font-size: 0.85rem;
  color: var(--accent);
  letter-spacing: 0.15em;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ── Scrollbar ────────────────────────────────────────────── */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 3px;
}

/* ── Navigation ───────────────────────────────────────────── */
#navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0 2rem;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  transition: var(--transition);
}

#navbar.scrolled {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.18), 0 4px 12px rgba(0, 0, 0, 0.12);
}

.nav-logo {
  font-size: 1.4rem;
  font-weight: 800;
  background: var(--gradient-btn);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-btn);
  transform: scaleX(0);
  transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  transform: scaleX(1);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

#theme-toggle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: var(--transition);
}

#theme-toggle:hover {
  background: var(--accent);
  box-shadow: var(--shadow-glow);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── Buttons ──────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: var(--radius-lg);
  font-size: 0.95rem;
  font-weight: 600;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.1);
  transform: translateX(-100%);
  transition: transform 0.4s ease;
}

.btn:hover::before {
  transform: translateX(0);
}

.btn-primary {
  background: var(--gradient-btn);
  color: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.22), 0 4px 12px rgba(0, 0, 0, 0.16);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.22), 0 8px 22px rgba(0, 0, 0, 0.16);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--border-color);
}

.btn-outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* ── Section Utilities ────────────────────────────────────── */
section {
  padding: 6rem 0;
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--border-color);
  border-radius: 999px;
  padding: 0.35rem 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  background: rgba(201, 169, 110, 0.08);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin-bottom: 3rem;
}

.highlight {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-alt {
  background: var(--bg-secondary);
}

/* ── Card Base ────────────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-card);
  opacity: 0;
  transition: var(--transition);
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(201, 169, 110, 0.35);
}

.card:hover::before {
  opacity: 1;
}

/* ── Hero Section ─────────────────────────────────────────── */
#hero {
  min-height: 100vh;
  background: var(--gradient-hero);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 0;
}

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

.particle {
  position: absolute;
  width: 3px;
  height: 3px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.3;
  animation: float-particle linear infinite;
}

@keyframes float-particle {
  0% {
    transform: translateY(100vh) translateX(0);
    opacity: 0;
  }

  10% {
    opacity: 0.4;
  }

  90% {
    opacity: 0.4;
  }

  100% {
    transform: translateY(-100px) translateX(var(--drift, 20px));
    opacity: 0;
  }
}

.hero-glow {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 169, 110, 0.14) 0%, transparent 70%);
  top: -100px;
  right: -100px;
  pointer-events: none;
}

.hero-glow-2 {
  position: absolute;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(224, 196, 138, 0.10) 0%, transparent 70%);
  bottom: -50px;
  left: 5%;
  pointer-events: none;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 3rem;
  align-items: center;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: rgba(201, 169, 110, 0.10);
  border: 1px solid rgba(201, 169, 110, 0.28);
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--accent);
  margin-bottom: 1.25rem;
  animation: fadeInDown 0.8s ease both;
}

.hero-name {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-bottom: 1rem;
  animation: fadeInUp 0.8s ease 0.2s both;
}

.hero-tagline {
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  height: 2em;
  animation: fadeInUp 0.8s ease 0.4s both;
}

#typed-text {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 520px;
  margin-bottom: 2.5rem;
  animation: fadeInUp 0.8s ease 0.6s both;
}

.hero-btns {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  animation: fadeInUp 0.8s ease 0.8s both;
}

.hero-image-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeInRight 1s ease 0.3s both;
}

.profile-ring {
  position: relative;
  width: 340px;
  height: 340px;
}

.profile-ring::before {
  content: '';
  position: absolute;
  inset: -8px;
  background: conic-gradient(#90CAF9, #BBDEFB, #c9a96e, #90CAF9);
  border-radius: 50%;
  animation: rotate-ring 6s linear infinite;
}

.profile-ring::after {
  content: '';
  position: absolute;
  inset: -4px;
  background: var(--gradient-hero);
  border-radius: 50%;
}

.profile-img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--bg-primary);
}

@keyframes rotate-ring {
  to {
    transform: rotate(360deg);
  }
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  animation: fadeIn 1s 1.5s both;
}

.scroll-mouse {
  width: 24px;
  height: 38px;
  border: 2px solid var(--text-muted);
  border-radius: 12px;
  position: relative;
}

.scroll-mouse::before {
  content: '';
  position: absolute;
  top: 5px;
  left: 50%;
  transform: translateX(-50%);
  width: 3px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  animation: scroll-mouse 1.6s ease infinite;
}

@keyframes scroll-mouse {
  50% {
    top: 12px;
    opacity: 0;
  }
}

.scroll-text {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  text-transform: uppercase;
}

/* ── About Section ────────────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-image-wrap {
  position: relative;
}

.about-img {
  width: 100%;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-card);
}

.about-experience-badge {
  position: absolute;
  bottom: -1.5rem;
  right: -1.5rem;
  background: var(--gradient-btn);
  color: #fff;
  padding: 1.2rem;
  border-radius: var(--radius-md);
  text-align: center;
  box-shadow: var(--shadow-hover);
}

.about-experience-badge .num {
  font-size: 2rem;
  font-weight: 800;
  display: block;
}

.about-experience-badge .lbl {
  font-size: 0.75rem;
  opacity: 0.9;
}

.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.tag {
  padding: 0.35rem 0.9rem;
  background: rgba(201, 169, 110, 0.10);
  border: 1px solid rgba(201, 169, 110, 0.22);
  border-radius: 999px;
  font-size: 0.82rem;
  color: var(--accent-light);
  font-family: var(--font-code);
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 1.5rem 0;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.info-item span {
  font-weight: 600;
  color: var(--text-primary);
}

.info-icon {
  font-size: 1.1rem;
}

/* ── Education Section ────────────────────────────────────── */
.timeline {
  position: relative;
  padding-left: 2rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), var(--accent-2), transparent);
}

.timeline-item {
  position: relative;
  margin-bottom: 2.5rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -2.5rem;
  top: 0.35rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--bg-primary);
  box-shadow: 0 0 0 2px rgba(201, 169, 110, 0.22), 0 2px 6px rgba(0, 0, 0, 0.22);
}

.timeline-period {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  font-family: var(--font-code);
  letter-spacing: 0.06em;
  margin-bottom: 0.3rem;
}

.timeline-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  transition: var(--transition);
}

.timeline-card:hover {
  border-color: rgba(201, 169, 110, 0.35);
  box-shadow: var(--shadow-hover);
  transform: translateX(6px);
}

.timeline-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.timeline-card .inst {
  font-size: 0.9rem;
  color: var(--accent-light);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.timeline-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

/* ── Skills Section ───────────────────────────────────────── */
.skills-tabs {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.skill-tab-btn {
  padding: 0.45rem 1.1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  transition: var(--transition);
}

.skill-tab-btn.active,
.skill-tab-btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.skills-tab-panel {
  display: none;
}

.skills-tab-panel.active {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.skill-item {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.skill-info {
  display: flex;
  justify-content: space-between;
  font-size: 0.92rem;
  font-weight: 600;
}

.skill-pct {
  color: var(--accent);
}

.skill-bar-bg {
  height: 8px;
  background: var(--border-color);
  border-radius: 999px;
  overflow: hidden;
}

.skill-bar {
  height: 100%;
  background: var(--gradient-btn);
  border-radius: 999px;
  width: 0;
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Projects Section ─────────────────────────────────────── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.75rem;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--transition);
  cursor: pointer;
}

.project-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(201, 169, 110, 0.35);
}

.project-img-wrap {
  position: relative;
  overflow: hidden;
  height: 200px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
}

.project-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-card:hover .project-img-wrap img {
  transform: scale(1.08);
}

.project-img-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  background: var(--gradient-card);
}

.project-overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 15, 30, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  opacity: 0;
  transition: var(--transition);
}

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

.project-overlay a {
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-md);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  transition: var(--transition);
  backdrop-filter: blur(8px);
}

.project-overlay a:hover {
  background: var(--accent);
  border-color: var(--accent);
}

.project-body {
  padding: 1.5rem;
}

.project-category {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.project-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
}

.project-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.tech-badge {
  padding: 0.25rem 0.65rem;
  background: rgba(201, 169, 110, 0.10);
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-light);
  font-family: var(--font-code);
  border: 1px solid rgba(201, 169, 110, 0.20);
}

/* ── Experience Section ───────────────────────────────────── */
.experience-grid {
  display: grid;
  gap: 1.5rem;
}

.exp-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: var(--transition);
}

.exp-card:hover {
  transform: translateX(6px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(201, 169, 110, 0.35);
}

.exp-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--gradient-btn);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.exp-role {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.exp-company {
  color: var(--accent-light);
  font-weight: 600;
  font-size: 0.92rem;
}

.exp-meta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0.5rem 0;
  font-family: var(--font-code);
}

.exp-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* ── Achievements Section ─────────────────────────────────── */
.achievements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}

.achievement-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  text-align: center;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.achievement-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient-btn);
  transform: scaleX(0);
  transition: var(--transition);
}

.achievement-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

.achievement-card:hover::after {
  transform: scaleX(1);
}

.achievement-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.achievement-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.achievement-issuer {
  font-size: 0.85rem;
  color: var(--accent-light);
  margin-bottom: 0.5rem;
}

.achievement-date {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--font-code);
  margin-bottom: 0.75rem;
}

.achievement-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ── Hobbies Section ──────────────────────────────────────── */
.hobbies-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1.5rem;
  margin-top: 1rem;
}

.hobby-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem 1.25rem 1.5rem;
  text-align: center;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
  cursor: default;
}

.hobby-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--gradient-card);
  opacity: 0;
  transition: var(--transition);
}

.hobby-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(201, 169, 110, 0.38);
}

.hobby-card:hover::before {
  opacity: 1;
}

.hobby-icon-wrap {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-md);
  background: var(--gradient-btn);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-size: 1.5rem;
  color: #fff;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.24), 0 5px 14px rgba(0, 0, 0, 0.18);
  transition: var(--transition);
}

.hobby-card:hover .hobby-icon-wrap {
  transform: scale(1.1) rotate(-5deg);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.26), 0 8px 20px rgba(0, 0, 0, 0.18);
}

.hobby-name {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
}

.hobby-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ── Contact Section ──────────────────────────────────────── */

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 4rem;
}

.contact-info h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.contact-info p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: var(--transition);
  color: inherit;
}

.contact-link:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-glow);
  transform: translateX(4px);
}

.contact-link-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--gradient-btn);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}

.contact-link-text small {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.contact-link-text span {
  font-size: 0.9rem;
  font-weight: 600;
}

/* Contact Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.form-control {
  padding: 0.85rem 1rem;
  background: var(--bg-card);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-main);
  font-size: 0.95rem;
  transition: var(--transition);
  width: 100%;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.18);
}

.form-control::placeholder {
  color: var(--text-muted);
}

textarea.form-control {
  resize: vertical;
  min-height: 130px;
}

#form-feedback {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 500;
  display: none;
}

#form-feedback.success {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
  border: 1px solid rgba(74, 222, 128, 0.3);
}

#form-feedback.error {
  background: rgba(239, 68, 68, 0.15);
  color: #f87171;
  border: 1px solid rgba(248, 113, 113, 0.3);
}

/* ── Footer ───────────────────────────────────────────────── */
#footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 3rem 0 1.5rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.footer-logo {
  font-size: 1.3rem;
  font-weight: 800;
  background: var(--gradient-btn);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.footer-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
}

.social-links {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: var(--transition);
  color: var(--text-secondary);
}

.social-link:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.footer-bottom {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-bottom span {
  color: #f87171;
}

/* ── Scroll-To-Top Button ─────────────────────────────────── */
#scroll-top {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  z-index: 900;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--gradient-btn);
  color: #fff;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.26), 0 5px 16px rgba(0, 0, 0, 0.20);
  transition: var(--transition);
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px);
}

#scroll-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

#scroll-top:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

/* ── Mobile Nav ───────────────────────────────────────────── */
.mobile-menu {
  display: none;
  position: fixed;
  top: 72px;
  left: 0;
  right: 0;
  z-index: 998;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  padding: 1.5rem;
  flex-direction: column;
  gap: 1.25rem;
}

.mobile-menu.open {
  display: flex;
}

.mobile-menu a {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: var(--transition);
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-color);
}

.mobile-menu a:hover {
  color: var(--accent);
}

/* ── Keyframes ────────────────────────────────────────────── */
@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(40px);
  }

  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* ── AOS Custom ────────────────────────────────────────────── */
[data-aos] {
  transition-duration: 0.7s !important;
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-image-wrap {
    order: -1;
  }

  .profile-ring {
    width: 260px;
    height: 260px;
    margin: 0 auto;
  }

  .hero-btns {
    justify-content: center;
  }

  .hero-desc {
    margin: 0 auto 2rem;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .contact-wrapper {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  section {
    padding: 4rem 0;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .exp-card {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

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

  .achievements-grid {
    grid-template-columns: 1fr;
  }

  .info-grid {
    grid-template-columns: 1fr;
  }
}