/* =========================================================
   SIDDHANT GAIKWAD PORTFOLIO — GLOBAL STYLES
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;1,9..40,300&family=DM+Mono:wght@300;400;500&display=swap');

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

:root {
  /* DARK THEME (default) */
  --bg: #0a0a0f;
  --bg2: #0f0f18;
  --surface: #131320;
  --surface2: #1a1a2e;
  --border: rgba(255,255,255,0.07);
  --border2: rgba(255,255,255,0.13);
  --text: #f0f0f5;
  --text-muted: #7a7a9a;
  --text-dim: #4a4a6a;
  --accent: #6c63ff;
  --accent2: #ff6b9d;
  --accent3: #00d4aa;
  --accent-glow: rgba(108,99,255,0.3);

  --nav-bg: rgba(10,10,15,0.85);
  --card-shadow: 0 24px 80px rgba(0,0,0,0.4);
  --body-cursor: none;

  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --font-mono: 'DM Mono', monospace;
}

/* LIGHT THEME */
body.light-mode {
  --bg: #f7f8fc;
  --bg2: #eef1f7;
  --surface: #ffffff;
  --surface2: #f4f6fb;
  --border: rgba(20,20,40,0.08);
  --border2: rgba(20,20,40,0.14);
  --text: #111827;
  --text-muted: #5f6b7a;
  --text-dim: #94a3b8;
  --accent: #5b52ff;
  --accent2: #ff4f8b;
  --accent3: #00b894;
  --accent-glow: rgba(91,82,255,0.22);

  --nav-bg: rgba(255,255,255,0.82);
  --card-shadow: 0 18px 50px rgba(15,23,42,0.08);
}

html { 
  scroll-behavior: smooth; 
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  cursor: var(--body-cursor);
  transition: background 0.35s ease, color 0.35s ease;
}

/* SCROLLBAR */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--accent); border-radius: 2px; }

/* NOISE OVERLAY */
body::before {
  content: '';
  position: fixed; 
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none; 
  z-index: 9998; 
  opacity: 0.4;
}

/* CUSTOM CURSOR */
.cursor {
  width: 10px; 
  height: 10px;
  background: var(--accent); 
  border-radius: 50%;
  position: fixed; 
  pointer-events: none; 
  z-index: 10000;
  transform: translate(-50%,-50%);
  transition: background 0.2s, transform 0.15s;
}

.cursor-ring {
  width: 36px; 
  height: 36px;
  border: 1.5px solid rgba(108,99,255,0.5); 
  border-radius: 50%;
  position: fixed; 
  pointer-events: none; 
  z-index: 9999;
  transform: translate(-50%,-50%);
  transition: width 0.3s, height 0.3s, border-color 0.3s;
}

/* NAV */
nav {
  position: fixed; 
  top: 0; 
  left: 0; 
  right: 0; 
  z-index: 1000;
  padding: 20px 60px;
  display: flex; 
  align-items: center; 
  justify-content: space-between;
  backdrop-filter: blur(20px);
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border);
  transition: padding 0.3s, background 0.35s ease, border-color 0.35s ease;
}

.nav-logo {
  font-family: var(--font-display); 
  font-size: 20px; 
  font-weight: 800;
  letter-spacing: -0.5px; 
  color: var(--text); 
  text-decoration: none;
  flex-shrink: 0;
}

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

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

.nav-links a {
  color: var(--text-muted); 
  text-decoration: none; 
  font-size: 14px;
  font-weight: 500; 
  letter-spacing: 0.3px; 
  transition: color 0.2s; 
  position: relative;
}

.nav-links a::after {
  content: ''; 
  position: absolute; 
  bottom: -3px; 
  left: 0; 
  right: 0;
  height: 1px; 
  background: var(--accent);
  transform: scaleX(0); 
  transform-origin: left; 
  transition: transform 0.3s;
}

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

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

.nav-cta {
  background: var(--accent) !important; 
  color: #fff !important;
  padding: 9px 22px; 
  border-radius: 100px; 
  font-size: 13px !important;
  font-weight: 600 !important; 
  transition: all 0.2s !important;
  white-space: nowrap;
}

.nav-cta:hover { 
  background: #7d76ff !important; 
  box-shadow: 0 0 24px var(--accent-glow); 
}

.nav-cta::after { 
  display: none !important; 
}

/* SECTION BASE */
section { 
  padding: 120px 60px; 
}

.section-tag {
  display: inline-flex; 
  align-items: center; 
  gap: 8px;
  font-family: var(--font-mono); 
  font-size: 11px;
  color: var(--accent); 
  letter-spacing: 2px; 
  text-transform: uppercase; 
  margin-bottom: 20px;
}

.section-tag::before { 
  content: '//'; 
  color: var(--text-dim); 
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(38px, 5vw, 64px); 
  font-weight: 800;
  letter-spacing: -2px; 
  line-height: 1.05; 
  color: var(--text); 
  margin-bottom: 20px;
}

.section-title span { 
  color: transparent; 
  -webkit-text-stroke: 1.5px var(--accent); 
}

.section-sub {
  color: var(--text-muted); 
  font-size: 17px; 
  font-weight: 300;
  max-width: 520px; 
  line-height: 1.7; 
  margin-bottom: 70px;
}

/* BUTTONS */
.btn-primary {
  display: inline-flex; 
  align-items: center; 
  gap: 10px;
  background: var(--accent); 
  color: #fff; 
  padding: 14px 32px;
  border-radius: 100px; 
  font-size: 15px; 
  font-weight: 600;
  text-decoration: none; 
  transition: all 0.3s;
  white-space: nowrap;
}

.btn-primary:hover { 
  background: #7d76ff; 
  box-shadow: 0 8px 40px var(--accent-glow); 
  transform: translateY(-2px); 
}

.btn-secondary {
  display: inline-flex; 
  align-items: center; 
  gap: 8px;
  background: transparent; 
  color: var(--text); 
  border: 1px solid var(--border2);
  padding: 14px 32px; 
  border-radius: 100px; 
  font-size: 15px;
  font-weight: 500; 
  text-decoration: none; 
  transition: all 0.3s;
  white-space: nowrap;
}

.btn-secondary:hover { 
  background: var(--surface); 
  border-color: var(--accent); 
  color: var(--accent); 
}

/* REVEAL ANIMATION */
.reveal {
  opacity: 0; 
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible { 
  opacity: 1; 
  transform: translateY(0); 
}

.reveal-d1 { transition-delay: 0.1s; }
.reveal-d2 { transition-delay: 0.2s; }
.reveal-d3 { transition-delay: 0.3s; }

/* ANIMATIONS */
@keyframes fadeSlideUp { 
  from { opacity:0; transform:translateY(28px); } 
  to { opacity:1; transform:translateY(0); } 
}

@keyframes pulse { 
  0%,100%{opacity:1;transform:scale(1)} 
  50%{opacity:.5;transform:scale(1.3)} 
}

@keyframes floatAnim { 
  0%,100%{transform:translateY(-50%)} 
  50%{transform:translateY(calc(-50% - 12px))} 
}

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

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

/* PAGE HEADER (for inner pages) */
.page-header {
  padding: 160px 60px 80px;
  position: relative; 
  overflow: hidden;
}

.page-header-bg {
  position: absolute; 
  inset: 0;
  background: radial-gradient(ellipse 70% 60% at 60% 50%, rgba(108,99,255,0.1) 0%, transparent 60%),
    radial-gradient(ellipse 40% 40% at 10% 80%, rgba(255,107,157,0.07) 0%, transparent 50%);
  pointer-events: none;
}

.page-header-grid {
  position: absolute; 
  inset: 0;
  background-image: linear-gradient(var(--border) 1px, transparent 1px), linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px; 
  opacity: 0.35; 
  pointer-events: none;
}

.breadcrumb {
  display: flex; 
  align-items: center; 
  gap: 8px;
  font-family: var(--font-mono); 
  font-size: 11px;
  color: var(--text-dim); 
  letter-spacing: 1px; 
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.breadcrumb a { 
  color: var(--text-dim); 
  text-decoration: none; 
  transition: color 0.2s; 
}

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

.breadcrumb span { 
  color: var(--text-dim); 
}

/* FOOTER */
footer {
  border-top: 1px solid var(--border);
  padding: 32px 60px;
  display: flex; 
  justify-content: space-between; 
  align-items: center;
}

.footer-copy { 
  font-size: 13px; 
  color: var(--text-dim); 
  font-family: var(--font-mono); 
}

.footer-copy span { 
  color: var(--accent); 
}

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

.footer-links a { 
  font-size: 13px; 
  color: var(--text-dim); 
  text-decoration: none; 
  transition: color 0.2s; 
}

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

/* =========================
   THEME TOGGLE
========================= */
.nav-right {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}

.theme-toggle {
  width: 54px;
  height: 30px;
  border-radius: 100px;
  border: 1px solid var(--border2);
  background: var(--surface);
  position: relative;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  padding: 3px;
  transition: all 0.3s ease;
  box-shadow: var(--card-shadow);
  flex-shrink: 0;
}

.theme-toggle:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.theme-toggle::before {
  content: '🌙';
  position: absolute;
  left: 5px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  transition: all 0.3s ease;
  color: white;
}

body.light-mode .theme-toggle::before {
  transform: translateX(24px);
  content: '☀️';
}

/* =========================
   HAMBURGER MENU
========================= */
.menu-toggle {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  border: 1px solid var(--border2);
  background: var(--surface);
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
  flex-shrink: 0;
  box-shadow: var(--card-shadow);
}

.menu-toggle:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.menu-toggle span {
  width: 20px;
  height: 2.5px;
  background: #ffffff;
  border-radius: 100px;
  transition: all 0.3s ease;
  display: block;
}

body.light-mode .menu-toggle span {
  background: #111827;
}

/* Active Hamburger Animation */
.menu-toggle.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

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

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

/* =========================
   MOBILE MENU OVERLAY
========================= */
.mobile-menu {
  position: fixed;
  top: 78px;
  left: 0;
  right: 0;
  background: var(--nav-bg);
  backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-16px);
  transition: all 0.35s ease;
  padding: 0 20px 24px;
}

.mobile-menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-menu-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 16px;
}

.mobile-link {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 14px 18px;
  border-radius: 16px;
  text-decoration: none;
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: all 0.25s ease;
}

.mobile-link:hover,
.mobile-link.active {
  border-color: var(--accent);
  background: rgba(108,99,255,0.08);
  color: var(--accent);
}

.mobile-cta {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
}

.mobile-cta:hover {
  background: #7d76ff;
  color: #fff;
}

/* Prevent scroll when menu open */
body.menu-open {
  overflow: hidden;
}

body.light-mode .hero-tag,
body.light-mode .exp-period,
body.light-mode .tl-period {
  background: rgba(91,82,255,0.08);
  border-color: rgba(91,82,255,0.18);
}

body.light-mode .tool-chip,
body.light-mode .skill-tag,
body.light-mode .bpc-tag,
body.light-mode .sb-tag,
body.light-mode .cs-tag-item {
  background: rgba(15,23,42,0.03);
}

body.light-mode .float-card,
body.light-mode .exp-card,
body.light-mode .skill-card,
body.light-mode .proj-preview-card,
body.light-mode .big-proj-card,
body.light-mode .timeline-card,
body.light-mode .edu-card,
body.light-mode .cert-card,
body.light-mode .skill-block,
body.light-mode .tool-item,
body.light-mode .soft-card,
body.light-mode .learn-card,
body.light-mode .contact-form-card,
body.light-mode .location-card,
body.light-mode .profile-card,
body.light-mode .ch-item {
  box-shadow: var(--card-shadow);
}

body.light-mode .hero-name .outline-word,
body.light-mode .section-title span,
body.light-mode .cs-title span {
  -webkit-text-stroke: 1.5px var(--accent);
}

body.light-mode .cs-overlay {
  background: rgba(245,247,252,0.96);
}

/* =========================================================
   RESPONSIVE IMPROVEMENTS ONLY
   ========================================================= */

/* Large tablets / small laptops */
@media (max-width: 1200px) {
  nav {
    padding: 18px 36px;
  }

  section {
    padding: 100px 36px;
  }

  .page-header {
    padding: 150px 36px 72px;
  }

  footer {
    padding: 28px 36px;
  }

  .nav-links {
    gap: 24px;
  }
}

/* Tablets */
@media (max-width: 900px) {
  html, body {
    overflow-x: hidden;
  }

  nav {
    padding: 16px 20px;
    gap: 14px;
  }

  .nav-logo {
    font-size: 18px;
  }

  .nav-links {
    display: none;
  }

  .nav-right {
    gap: 10px;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .theme-toggle {
    width: 50px;
    height: 28px;
  }

  .theme-toggle::before {
    width: 20px;
    height: 20px;
    font-size: 11px;
  }

  body.light-mode .theme-toggle::before {
    transform: translateX(22px);
  }

  section {
    padding: 80px 20px;
  }

  .page-header {
    padding: 125px 20px 60px;
  }

  .section-title {
    font-size: clamp(34px, 9vw, 52px);
    line-height: 1.05;
    letter-spacing: -1.3px;
  }

  .section-sub {
    font-size: 15px;
    line-height: 1.8;
    max-width: 100%;
    margin-bottom: 48px;
  }

  .section-tag {
    font-size: 10px;
    letter-spacing: 1.5px;
    margin-bottom: 16px;
  }

  .breadcrumb {
    font-size: 10px;
    gap: 6px;
    margin-bottom: 24px;
  }

  .btn-primary,
  .btn-secondary {
    padding: 13px 22px;
    font-size: 14px;
  }

  footer {
    padding: 24px 20px;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .footer-links {
    gap: 16px;
  }

  .cursor,
  .cursor-ring {
    display: none !important;
  }

  body {
    cursor: auto;
  }

  .reveal {
    transform: translateY(20px);
  }
}

/* Mobile phones */
@media (max-width: 600px) {
  nav {
    padding: 14px 16px;
  }

  .nav-logo {
    font-size: 17px;
  }

  .nav-right {
    gap: 8px;
  }

  .theme-toggle {
    width: 46px;
    height: 26px;
  }

  .theme-toggle::before {
    width: 18px;
    height: 18px;
    left: 4px;
    font-size: 10px;
  }

  body.light-mode .theme-toggle::before {
    transform: translateX(20px);
  }

  .menu-toggle {
    width: 44px;
    height: 44px;
    border-radius: 12px;
  }

  .menu-toggle span {
    width: 17px;
  }

  .mobile-menu {
    top: 72px;
    padding: 0 16px 20px;
  }

  .mobile-link {
    min-height: 50px;
    font-size: 14px;
    border-radius: 14px;
  }

  section {
    padding: 70px 16px;
  }

  .page-header {
    padding: 115px 16px 50px;
  }

  .section-title {
    font-size: clamp(30px, 10vw, 42px);
    line-height: 1.03;
    letter-spacing: -1px;
  }

  .section-sub {
    font-size: 14.5px;
    line-height: 1.8;
    margin-bottom: 40px;
  }

  .section-tag {
    font-size: 9.5px;
    letter-spacing: 1.4px;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
    justify-content: center;
    padding: 13px 18px;
    font-size: 14px;
  }

  footer {
    padding: 22px 16px;
    text-align: center;
    align-items: center;
  }

  .footer-copy {
    font-size: 12px;
    line-height: 1.7;
  }

  .footer-links {
    justify-content: center;
    gap: 14px;
  }

  .breadcrumb {
    font-size: 9.5px;
    margin-bottom: 20px;
  }

  .page-header-grid {
    background-size: 42px 42px;
  }
}

/* Very small devices */
@media (max-width: 380px) {
  nav {
    padding: 12px 12px;
  }

  .theme-toggle {
    width: 42px;
    height: 24px;
  }

  .theme-toggle::before {
    width: 16px;
    height: 16px;
    font-size: 9px;
  }

  body.light-mode .theme-toggle::before {
    transform: translateX(18px);
  }

  .menu-toggle {
    width: 40px;
    height: 40px;
    border-radius: 11px;
  }

  .menu-toggle span {
    width: 16px;
  }

  .mobile-menu {
    top: 68px;
    padding: 0 12px 18px;
  }

  .mobile-link {
    min-height: 48px;
    font-size: 13.5px;
    padding: 12px 14px;
  }

  section {
    padding: 64px 12px;
  }

  .page-header {
    padding: 108px 12px 46px;
  }

  .section-title {
    font-size: clamp(28px, 10vw, 36px);
  }

  .section-sub {
    font-size: 14px;
  }

  .btn-primary,
  .btn-secondary {
    font-size: 13.5px;
    padding: 12px 16px;
  }

  footer {
    padding: 20px 12px;
  }
}

/* =========================================
   FIX NAVBAR SPACING SHIFT ON MOBILE
   ========================================= */

nav {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px; /* consistent spacing between toggle + menu */
}

/* Mobile specific fix */
@media (max-width: 768px) {
  nav {
    padding-left: 16px !important;
    padding-right: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .nav-logo {
    margin-right: auto; /* push everything to right cleanly */
  }

  .nav-right {
    gap: 10px;
  }

  .theme-toggle {
    margin-right: 0;
  }

  .menu-toggle {
    margin-left: 0;
  }
}