/* ============================================================
   PORTFOLIO — style.css
   ============================================================ */

/* ── Custom Properties ─────────────────────────────────────── */
:root {
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,
          Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;

  /* Light mode palette */
  --bg:           #ffffff;
  --bg-surface:   #f8f9fa;
  --bg-card:      #ffffff;
  --text:         #111827;
  --text-muted:   #6b7280;
  --accent:       #2563eb;
  --accent-hover: #1d4ed8;
  --accent-light: #eff6ff;
  --border:       #e5e7eb;

  --header-bg:    rgba(255, 255, 255, 0.88);
  --card-shadow:        0 1px 3px rgba(0,0,0,0.07), 0 1px 2px rgba(0,0,0,0.04);
  --card-shadow-hover:  0 6px 18px rgba(0,0,0,0.11);

  /* Layout */
  --section-pad:    2.5rem 1.5rem;
  --max-w:          1100px;
  --radius:         0.5rem;
  --radius-pill:    9999px;

  /* Single global transition */
  --t: color 0.2s ease, background-color 0.2s ease,
       border-color 0.2s ease, box-shadow 0.2s ease;
}

/* Dark mode overrides */
[data-theme="dark"] {
  --bg:           #000000;
  --bg-surface:   #0a0a0a;
  --bg-card:      #0a0a0a;
  --text:         #ffffff;
  --text-muted:   #cccccc;
  --accent:       #00b4d8;
  --accent-hover: #48cae4;
  --accent-light: #003045;
  --border:       #ffffff;

  --header-bg:   rgba(0, 0, 0, 0.98);
  --card-shadow:       0 0 0 1px #ffffff22;
  --card-shadow-hover: 0 0 0 1px #00b4d8;
}

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

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  transition: var(--t);
}

a { color: var(--accent); text-decoration: none; transition: var(--t); }
a:hover { color: var(--accent-hover); }
ul { list-style: none; }
img { display: block; max-width: 100%; }
button { font-family: inherit; }
svg { display: block; flex-shrink: 0; }

/* ── Utilities ─────────────────────────────────────────────── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (max-width: 400px) {
  .container { padding: 0 1.25rem; }
}

.section-eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.section-title {
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.025em;
  line-height: 1.15;
  margin-bottom: 0.75rem;
}

.section-sub {
  color: var(--text-muted);
  font-size: 1.05rem;
  max-width: 720px;
  line-height: 1.75;
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.4rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: var(--t), transform 0.15s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }

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

.btn-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-outline:hover {
  background: var(--bg-surface);
  border-color: var(--text-muted);
  color: var(--text);
}

/* ── Header ────────────────────────────────────────────────── */
#site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  transition: var(--t);
}

#site-header.scrolled {
  box-shadow: 0 1px 10px rgba(0,0,0,0.15);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: 1rem;
}

.logo {
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--text);
  letter-spacing: -0.03em;
  flex-shrink: 0;
}
.logo span { color: var(--accent); }

/* Desktop nav */
#main-nav {
  display: flex;
  align-items: center;
  gap: 0.1rem;
}

#main-nav a {
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 500;
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius);
  transition: var(--t);
}
#main-nav a:hover,
#main-nav a.active {
  color: var(--text);
  background: var(--bg-surface);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

/* Icon button base */
.icon-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--t);
}
.icon-btn:hover {
  color: var(--text);
  background: var(--bg-surface);
}

/* Hamburger */
#hamburger { display: none; }

/* ── Mobile nav ────────────────────────────────────────────── */
@media (max-width: 767px) {
  #hamburger { display: flex; }

  #main-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0.2rem;
    padding: 0.75rem 1.25rem 1.25rem;
    background: var(--header-bg);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
  }

  #site-header.nav-open #main-nav { display: flex; }

  #main-nav a {
    padding: 0.65rem 0.75rem;
    font-size: 0.95rem;
  }
}

/* ── Scroll offset for sticky header ──────────────────────── */
section[id] {
  scroll-margin-top: 64px;
}

/* ── Hero ──────────────────────────────────────────────────── */
#hero {
  display: flex;
  align-items: center;
  padding: 3rem 1.5rem 2.5rem;
  background: var(--bg);
}

.hero-content { max-width: 700px; }

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--accent-light);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.3rem 0.85rem;
  border-radius: var(--radius-pill);
  margin-bottom: 1.75rem;
  border: 1px solid color-mix(in srgb, var(--accent) 20%, transparent);
}

.hero-badge svg { color: #22c55e; }

.hero-name {
  font-size: clamp(2.6rem, 8vw, 4.25rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 0.6rem;
}

.hero-title {
  font-size: clamp(1.05rem, 2.5vw, 1.35rem);
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1.25rem;
  letter-spacing: -0.01em;
}

.hero-tagline {
  font-size: 1.08rem;
  color: var(--text-muted);
  max-width: 500px;
  margin-bottom: 2.5rem;
  line-height: 1.75;
}

.hero-ctas {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ── Scroll cue ────────────────────────────────────────────── */
.scroll-cue {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--text-muted);
  margin-top: 3rem;
  animation: bounce 2s ease-in-out infinite;
  transition: var(--t);
}
.scroll-cue:hover {
  color: var(--accent);
  border-color: var(--accent);
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(6px); }
}

/* ── What's in the Name ────────────────────────────────────── */
#brand {
  padding: var(--section-pad);
  background: var(--bg-surface);
}

#brand .section-title { margin-bottom: 2rem; }

.brand-split {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.brand-half {
  flex: 1;
  min-width: 180px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--card-shadow);
}

.brand-word {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 1rem;
}

.brand-word img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.brand-jalebi { color: var(--accent); }

.brand-traits {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.brand-traits li {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0.2rem 0.65rem;
}

.brand-plus {
  font-size: 2rem;
  font-weight: 300;
  color: var(--text-muted);
  align-self: center;
  flex-shrink: 0;
  padding: 0 0.25rem;
}

@media (max-width: 500px) {
  .brand-plus { align-self: flex-start; padding: 0.5rem 0; }
}

.brand-tagline {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.brand-quote {
  background: var(--accent-light);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.25rem 1.5rem;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.8;
}

.brand-quote strong { color: var(--accent); }
.brand-quote em { color: var(--text); font-style: normal; font-weight: 600; }

/* ── Hobby project links ────────────────────────────────────── */
.hobby-links {
  list-style: none;
  margin-top: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.hobby-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--accent);
  transition: var(--t);
  align-self: flex-start;
}

.hobby-links a:hover {
  background: var(--accent);
  color: #fff;
}

/* ── About ─────────────────────────────────────────────────── */
#about {
  padding: var(--section-pad);
  background: var(--bg);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: start;
}

@media (min-width: 768px) {
  .about-grid { grid-template-columns: 1.3fr 1fr; align-items: center; }
}

.about-text { padding-top: 0.25rem; }
.about-intro { margin-bottom: 1rem; }
.about-text p {
  color: var(--text-muted);
  line-height: 1.8;
  margin-bottom: 0.9rem;
}
.about-text p:last-child { margin-bottom: 0; }

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.9rem;
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.35rem 0.75rem;
  text-align: center;
  box-shadow: var(--card-shadow);
  transition: var(--t);
}
.stat-card:hover {
  box-shadow: var(--card-shadow-hover);
  border-color: var(--accent);
}

.stat-number {
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 0.35rem;
  letter-spacing: -0.04em;
}

.stat-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

/* Cert badges row (below stats) */
.cert-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.cert-badge {
  background: var(--accent-light);
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-radius: var(--radius-pill);
  padding: 0.25rem 0.75rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ── Skills ────────────────────────────────────────────────── */
#skills {
  padding: var(--section-pad);
  background: var(--bg);
}

.skills-header { margin-bottom: 2.5rem; }

.skills-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 640px) {
  .skills-grid { grid-template-columns: 1fr 1fr; }
}

.skill-group-title {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 1rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  background: var(--bg-surface);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0.35rem 0.9rem;
  font-size: 0.83rem;
  font-weight: 500;
  transition: var(--t);
  cursor: default;
}
.tag:hover {
  background: var(--accent-light);
  border-color: var(--accent);
  color: var(--accent);
}

/* ── Experience ────────────────────────────────────────────── */
#experience {
  padding: var(--section-pad);
  background: var(--bg-surface);
}

.exp-header { margin-bottom: 2.5rem; }

.timeline {
  position: relative;
  padding-left: 1.75rem;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 3px;
  top: 10px;
  bottom: 10px;
  width: 2px;
  background: var(--border);
  border-radius: 2px;
}

.tl-item {
  position: relative;
  margin-bottom: 2.5rem;
}
.tl-item:last-child { margin-bottom: 0; }

.tl-item::before {
  content: '';
  position: absolute;
  left: -1.9rem;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--bg-surface);
  border: 2px solid var(--accent);
  box-shadow: 0 0 0 3px var(--bg-surface);
  transition: var(--t);
}
.tl-item:hover::before { background: var(--accent); }

.tl-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.75rem;
  margin-bottom: 0.15rem;
}

.tl-role {
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--text);
}

.tl-company {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent);
}

.tl-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-left: auto;
  white-space: nowrap;
}

@media (max-width: 500px) {
  .tl-date { margin-left: 0; width: 100%; }
}

.tl-bullets {
  margin-top: 0.55rem;
}
.tl-bullets li {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.7;
  padding-left: 1rem;
  position: relative;
  margin-bottom: 0.15rem;
}
.tl-bullets li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 600;
}

/* ── Awards ────────────────────────────────────────────────── */
.awards-row {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.awards-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.awards-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.award-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 0.3rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
}

.award-chip::before {
  content: '★';
  color: var(--accent);
  font-size: 0.7rem;
}

/* ── Projects ──────────────────────────────────────────────── */
#projects {
  padding: var(--section-pad);
  background: var(--bg);
}

.projects-header { margin-bottom: 2.5rem; }

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.1rem;
}

@media (min-width: 600px) {
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 960px) {
  .projects-grid { grid-template-columns: repeat(3, 1fr); }
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--card-shadow);
  transition: var(--t), transform 0.2s ease;
  display: flex;
  flex-direction: column;
}
.project-card:hover {
  box-shadow: var(--card-shadow-hover);
  transform: translateY(-3px);
  border-color: var(--accent);
}

.project-icon {
  width: 42px;
  height: 42px;
  background: var(--accent-light);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  margin-bottom: 1.1rem;
  flex-shrink: 0;
}

.project-title {
  font-weight: 700;
  font-size: 1.02rem;
  color: var(--text);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.project-desc {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.75;
  flex: 1;
  margin-bottom: 1.25rem;
}

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

.project-tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  background: var(--accent-light);
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ── GenAI section background ──────────────────────────────── */
#genai {
  padding: var(--section-pad);
  background: var(--bg-surface);
}

/* ── Contact ───────────────────────────────────────────────── */
#contact {
  padding: var(--section-pad);
  background: var(--bg-surface);
  text-align: center;
}

.contact-inner {
  max-width: 500px;
  margin: 0 auto;
}

.contact-inner .section-title { margin-bottom: 0.75rem; }

.contact-inner p {
  color: var(--text-muted);
  line-height: 1.75;
  margin-bottom: 2rem;
}

.contact-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.social-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.5rem;
}

.social-btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  color: var(--text-muted);
  transition: var(--t);
}

.social-btn:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-light);
}

/* Community Contributions strip */
.community-strip {
  margin: 1.5rem auto;
  max-width: 420px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
}

.community-label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.community-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.community-platform {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  padding-right: 0.6rem;
  border-right: 1px solid var(--border);
}
.community-platform:hover { color: var(--accent); }

.community-stat {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  padding: 0.15rem 0.5rem;
  background: var(--bg-surface);
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
}

.badge-silver { color: #9ea3a8; line-height: 1; }
.badge-bronze { color: #ad7c59; line-height: 1; }

/* ── Footer ────────────────────────────────────────────────── */
footer {
  padding: 1.5rem;
  text-align: center;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.83rem;
  background: var(--bg);
  transition: var(--t);
}

footer a { color: var(--text-muted); }
footer a:hover { color: var(--accent); }
