/* ===== Modern Portfolio - Sang Patil ===== */

:root {
  --bg-primary: #07070a;
  --bg-secondary: #0f0f14;
  --bg-card: #151520;
  --bg-card-hover: #1c1c2a;
  --border: #252535;
  --border-subtle: #1a1a28;
  --text-primary: #eeeef5;
  --text-secondary: #9090a8;
  --text-muted: #55556a;
  --accent: #7c6af7;
  --accent-light: #a395fa;
  --accent-dim: rgba(124, 106, 247, 0.12);
  --accent-glow: 0 0 40px rgba(124, 106, 247, 0.2);
  --cyan: #22d3ee;
  --cyan-dim: rgba(34, 211, 238, 0.1);
  --green: #34d399;
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
  --shadow-card: 0 2px 16px rgba(0, 0, 0, 0.4);
  --transition: 0.2s ease;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
}

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

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

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--accent-dim);
  color: var(--accent-light);
}

/* ===== Typography ===== */
h1, h2, h3, h4 { line-height: 1.2; font-weight: 600; }

h1 { font-size: clamp(2.4rem, 6vw, 4rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.6rem, 4vw, 2.2rem); letter-spacing: -0.01em; }
h3 { font-size: 1.2rem; }

a {
  color: var(--accent-light);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--text-primary); }

/* ===== Layout ===== */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

section {
  padding: 100px 0;
}

/* ===== Navigation ===== */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(7, 7, 10, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition);
}

nav.scrolled {
  border-bottom-color: var(--border-subtle);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.nav-logo {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--accent-light);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.nav-logo span { color: var(--text-muted); }

.nav-links {
  display: flex;
  gap: 8px;
  list-style: none;
  align-items: center;
}

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 6px;
  transition: all var(--transition);
}

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

.nav-links .views-link {
  color: var(--accent-light);
  border: 1px solid var(--accent-dim);
  background: var(--accent-dim);
}

.nav-links .views-link:hover {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text-primary);
  font-size: 1.5rem;
}

/* ===== Hero ===== */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
  position: relative;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent-light);
  margin-bottom: 16px;
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 32px;
  height: 1px;
  background: var(--accent);
}

.hero-name {
  font-size: clamp(3rem, 8vw, 5.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.hero-title {
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  color: var(--text-secondary);
  font-weight: 400;
  margin-bottom: 24px;
}

.hero-title .highlight {
  color: var(--accent-light);
  font-weight: 500;
}

.hero-bio {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 36px;
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition);
  cursor: pointer;
  border: none;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 4px 16px rgba(124, 106, 247, 0.3);
}

.btn-primary:hover {
  background: var(--accent-light);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(124, 106, 247, 0.4);
}

.btn-ghost {
  background: var(--bg-card);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--accent);
}

.hero-social {
  display: flex;
  gap: 12px;
}

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

.social-link:hover {
  background: var(--accent-dim);
  border-color: var(--accent);
  color: var(--accent-light);
  transform: translateY(-2px);
}

/* Hero background decoration */
.hero-bg {
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  pointer-events: none;
  overflow: hidden;
}

.hero-bg::before {
  content: '';
  position: absolute;
  top: 20%;
  right: -10%;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 106, 247, 0.06) 0%, transparent 70%);
}

.hero-bg::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-subtle), transparent);
}

/* ===== Section Headers ===== */
.section-header {
  margin-bottom: 60px;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent-light);
  background: var(--accent-dim);
  padding: 4px 12px;
  border-radius: 100px;
  border: 1px solid rgba(124, 106, 247, 0.2);
  margin-bottom: 16px;
}

.section-title {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.section-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 500px;
  line-height: 1.6;
}

/* ===== About ===== */
#about {
  border-top: 1px solid var(--border-subtle);
}

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

.about-text p {
  color: var(--text-secondary);
  margin-bottom: 16px;
  line-height: 1.8;
}

.about-text p:last-child { margin-bottom: 0; }

.about-highlights {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.highlight-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  transition: all var(--transition);
}

.highlight-card:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
}

.highlight-icon {
  font-size: 1.4rem;
  margin-bottom: 8px;
}

.highlight-card h4 {
  font-size: 0.95rem;
  color: var(--text-primary);
  margin-bottom: 4px;
  font-weight: 600;
}

.highlight-card p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ===== Experience ===== */
#experience {
  border-top: 1px solid var(--border-subtle);
}

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 150px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--border) 10%, var(--border) 90%, transparent);
}

.timeline-item {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 32px;
  padding: 32px 0;
  position: relative;
  animation: fadeInUp 0.5s ease forwards;
  opacity: 0;
}

.timeline-item.visible { opacity: 1; }

.timeline-date {
  text-align: right;
  padding-top: 4px;
}

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

.timeline-dot {
  position: absolute;
  left: 144px;
  top: 38px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 2px solid var(--accent);
  z-index: 1;
}

.timeline-dot.current {
  background: var(--accent);
  box-shadow: var(--accent-glow);
}

.timeline-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  transition: all var(--transition);
}

.timeline-content:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
}

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

.timeline-role {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.timeline-company {
  font-size: 0.9rem;
  color: var(--accent-light);
  margin-bottom: 12px;
  font-weight: 500;
}

.timeline-desc {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.7;
}

.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 16px;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  background: var(--bg-secondary);
  padding: 3px 10px;
  border-radius: 100px;
  border: 1px solid var(--border-subtle);
}

.tag.accent {
  color: var(--accent-light);
  background: var(--accent-dim);
  border-color: rgba(124, 106, 247, 0.2);
}

/* ===== Skills ===== */
#skills {
  border-top: 1px solid var(--border-subtle);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.skills-category {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color var(--transition);
}

.skills-category:hover {
  border-color: var(--accent);
}

.skills-cat-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.skills-cat-icon {
  font-size: 1.2rem;
}

.skills-cat-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.skills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-chip {
  font-size: 0.82rem;
  padding: 5px 12px;
  border-radius: 6px;
  border: 1px solid var(--border);
  color: var(--text-secondary);
  background: var(--bg-secondary);
  transition: all var(--transition);
}

.skill-chip:hover {
  color: var(--accent-light);
  border-color: var(--accent);
  background: var(--accent-dim);
}

/* ===== Projects ===== */
#projects {
  border-top: 1px solid var(--border-subtle);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.project-card:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

.project-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.project-icon {
  font-size: 1.5rem;
}

.project-links {
  display: flex;
  gap: 8px;
}

.project-link {
  color: var(--text-muted);
  font-size: 0.9rem;
  padding: 4px;
  border-radius: 4px;
  transition: color var(--transition);
}

.project-link:hover {
  color: var(--accent-light);
}

.project-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.project-desc {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.65;
  flex: 1;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

/* ===== Claude Views Promo ===== */
.views-promo {
  margin-top: 80px;
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(124, 106, 247, 0.05) 100%);
  border: 1px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 48px;
  display: flex;
  gap: 32px;
  align-items: center;
  justify-content: space-between;
}

.views-promo-text h3 {
  font-size: 1.5rem;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.views-promo-text p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 480px;
}

.views-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  background: var(--accent-dim);
  color: var(--accent-light);
  padding: 4px 10px;
  border-radius: 100px;
  border: 1px solid rgba(124, 106, 247, 0.2);
  margin-bottom: 12px;
  font-family: var(--font-mono);
}

/* ===== Footer ===== */
footer {
  border-top: 1px solid var(--border-subtle);
  padding: 40px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-copy {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 16px;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--text-secondary);
}

/* ===== Scroll Animations ===== */
.fade-up {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-up:nth-child(2) { transition-delay: 0.1s; }
.fade-up:nth-child(3) { transition-delay: 0.2s; }
.fade-up:nth-child(4) { transition-delay: 0.3s; }

/* ===== Views Page Specific ===== */
.views-header {
  padding: 100px 0 60px;
  border-bottom: 1px solid var(--border-subtle);
}

.views-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 48px;
  padding: 60px 0;
  align-items: start;
}

.posts-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 32px;
  transition: all var(--transition);
  cursor: pointer;
}

.post-card:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
}

.post-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

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

.post-tag {
  font-size: 0.75rem;
  padding: 2px 10px;
  border-radius: 100px;
  color: var(--accent-light);
  background: var(--accent-dim);
  border: 1px solid rgba(124, 106, 247, 0.2);
}

.post-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 10px;
  line-height: 1.4;
}

.post-summary {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.post-read-more {
  color: var(--accent-light);
  font-size: 0.85rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
}

/* Views Sidebar */
.views-sidebar {
  position: sticky;
  top: 84px;
}

.sidebar-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
}

.sidebar-card h4 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 16px;
}

.claude-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--accent-dim);
  border: 1px solid rgba(124, 106, 247, 0.25);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-bottom: 12px;
}

.claude-badge .icon {
  font-size: 1.4rem;
}

.claude-badge p {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.sidebar-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.step {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.step-num {
  width: 20px;
  height: 20px;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  font-size: 0.7rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.step p {
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Post Modal */
.post-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(7, 7, 10, 0.9);
  backdrop-filter: blur(8px);
  padding: 24px;
  overflow-y: auto;
}

.post-modal.open { display: flex; align-items: flex-start; justify-content: center; }

.post-modal-inner {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 48px;
  max-width: 760px;
  width: 100%;
  margin: auto;
  position: relative;
}

.post-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: var(--bg-secondary);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition);
}

.post-modal-close:hover {
  color: var(--text-primary);
  border-color: var(--accent);
}

.post-modal-content h3 {
  font-size: 1.8rem;
  color: var(--text-primary);
  margin-bottom: 8px;
  line-height: 1.3;
}

.post-modal-content .post-date-full {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 32px;
  display: block;
}

.post-body {
  color: var(--text-secondary);
  line-height: 1.85;
  font-size: 0.95rem;
}

.post-body p { margin-bottom: 16px; }
.post-body h3 { color: var(--text-primary); margin: 28px 0 12px; font-size: 1.1rem; }
.post-body ul, .post-body ol { padding-left: 20px; margin-bottom: 16px; }
.post-body li { margin-bottom: 6px; }
.post-body strong { color: var(--text-primary); }

/* ===== Empty state ===== */
.empty-state {
  text-align: center;
  padding: 80px 24px;
  color: var(--text-muted);
}

.empty-state .icon { font-size: 3rem; margin-bottom: 16px; }
.empty-state h3 { color: var(--text-secondary); margin-bottom: 8px; }
.empty-state p { font-size: 0.9rem; }

/* ===== Mobile nav ===== */
.mobile-menu {
  display: none;
  position: fixed;
  top: 64px;
  left: 0;
  right: 0;
  background: rgba(7, 7, 10, 0.97);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  padding: 16px 24px;
  z-index: 99;
}

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

.mobile-menu ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.mobile-menu a {
  display: block;
  padding: 10px 12px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  border-radius: 6px;
}

.mobile-menu a:hover {
  background: var(--border-subtle);
  color: var(--text-primary);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  section { padding: 70px 0; }

  .nav-links { display: none; }
  .nav-toggle { display: block; }

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

  .timeline::before { left: 0; display: none; }
  .timeline-item { grid-template-columns: 1fr; gap: 12px; }
  .timeline-date { text-align: left; padding-top: 0; }
  .timeline-dot { display: none; }

  .views-grid { grid-template-columns: 1fr; }
  .views-sidebar { position: static; }

  .views-promo {
    flex-direction: column;
    text-align: center;
    padding: 32px 24px;
  }

  .post-modal-inner { padding: 28px 20px; }

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

@media (max-width: 480px) {
  .hero-cta { flex-direction: column; }
  .btn { justify-content: center; }
  .projects-grid { grid-template-columns: 1fr; }
}

/* ===== Loading animation ===== */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.loading-dot {
  display: inline-block;
  animation: pulse 1.5s ease-in-out infinite;
}

/* ===== Cursor blink ===== */
.cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: var(--accent);
  margin-left: 2px;
  animation: blink 1s step-end infinite;
  vertical-align: text-bottom;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}
