:root {
  --black: #080808;
  --ink: #111111;
  --ink2: #161616;
  --white: #F0ECE4;
  --cream: #C8C0B0;
  --muted: #5A5A5A;
  --border: rgba(240, 236, 228, 0.08);
  --purple: #7C3AED;
  --purple-dim: rgba(124, 58, 237, 0.12);
  --purple-glow: rgba(124, 58, 237, 0.06);
  --mono: 'IBM Plex Mono', monospace;
  --serif: 'DM Serif Display', serif;
  --sans: 'Instrument Sans', sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
}

a, button, input, textarea, select, [tabindex] {
  outline: none;
}

a:focus, button:focus, input:focus, textarea:focus, select:focus {
  outline: none;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--black);
  color: var(--white);
  font-family: var(--sans);
  overflow-x: hidden;
  
}

body.no-scroll {
  overflow: hidden;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 200;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 56px;
  transition: background 0.4s, border-color 0.4s, padding 0.3s;
  border-bottom: 1px solid transparent;
}

nav.scrolled {
  padding: 18px 56px;
  background: rgba(8, 8, 8, 0.92);
  backdrop-filter: blur(16px);
  border-color: var(--border);
}

.nav-logo {
  font-family: var(--mono);
  font-size: 15px;
  letter-spacing: 4px;
  color: var(--purple);
  text-decoration: none;
  font-weight: 500;
}

.nav-links {
  display: flex;
  gap: 40px;
  align-items: center;
}

.nav-links a {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
  
}

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

.nav-resume {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  border: 1px solid rgba(124, 58, 237, 0.4);
  color: var(--purple);
  padding: 9px 18px;
  text-decoration: none;
  
  transition: background 0.2s, color 0.2s;
}

.nav-links .nav-resume:hover {
  background: var(--purple) !important;
  color: var(--white) !important;
  border-color: var(--purple) !important;
}

/* ── NAV DROPDOWN ── */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-btn {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--muted);
  background: none;
  border: none;
  padding: 0;
  
  transition: color 0.2s;
}

.nav-dropdown-btn:hover {
  color: var(--purple);
}

.nav-dropdown-content {
  position: absolute;
  top: 100%;
  right: 0;
  background: var(--ink2);
  border: 1px solid var(--border);
  min-width: 180px;
  padding: 12px 0;
  margin-top: 15px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.35s cubic-bezier(0.23, 1, 0.32, 1);
  z-index: 300;
}

.nav-dropdown.active .nav-dropdown-content {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-dropdown-content a {
  display: block;
  padding: 14px 24px;
  color: var(--muted) !important;
  font-size: 9px !important;
  letter-spacing: 2px;
  transition: all 0.2s;
  white-space: nowrap;
}

.nav-dropdown-content a:hover {
  color: var(--purple) !important;
  background: var(--purple-dim);
  padding-left: 28px;
}

/* Mobile Toggle */
.nav-mobile-toggle {
  display: none;
  background: none;
  border: none;
  
  flex-direction: column;
  gap: 6px;
  padding: 4px;
  z-index: 211;
  position: relative;
}

.nav-mobile-toggle span {
  display: block;
  width: 22px;
  height: 1px;
  background: var(--white);
  transition: all 0.35s ease;
}

nav.drawer-open .nav-mobile-toggle span:nth-child(1) { transform: translateY(3.5px) rotate(45deg); }
nav.drawer-open .nav-mobile-toggle span:nth-child(2) { transform: translateY(-3.5px) rotate(-45deg); }

/* ── MOBILE DRAWER ── */
.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 210;
  pointer-events: none;
}

.mobile-drawer.open { pointer-events: all; }

.mobile-drawer-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.4s ease;
}

.mobile-drawer.open .mobile-drawer-overlay {
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.mobile-drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(80vw, 320px);
  height: 100%;
  background: #0e0e0e;
  border-left: 1px solid var(--border);
  padding: 100px 32px 48px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transform: translateX(100%);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.mobile-drawer.open .mobile-drawer-panel { transform: translateX(0); }

.mobile-drawer-close {
  position: absolute;
  top: 24px;
  right: 28px;
  font-size: 32px;
  background: none;
  border: none;
  color: var(--muted);
  
  line-height: 1;
  transition: color 0.2s;
}

.mobile-drawer-close:hover { color: var(--purple); }

.mobile-drawer a.drawer-link {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 24px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  text-decoration: none !important;
  transition: color 0.2s, padding-left 0.2s;
  display: block;
}

.mobile-drawer a.drawer-link:hover { color: var(--purple); padding-left: 8px; }

/* Mobile Dropdowns */
.mobile-dropdown-btn {
  width: 100%;
  text-align: left;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  background: none;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  
  padding: 24px 0;
  display: flex;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
}

.mobile-dropdown-btn .dropdown-arrow { transition: transform 0.35s ease; display: inline-block; }
.mobile-dropdown.active .mobile-dropdown-btn .dropdown-arrow { transform: rotate(180deg); }
.mobile-dropdown-btn:hover { color: var(--purple); padding-left: 8px; }

.mobile-dropdown-content {
  height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: height 0.35s cubic-bezier(0.23, 1, 0.32, 1);
}

.mobile-dropdown.active .mobile-dropdown-content { height: auto; padding-bottom: 10px; }

.mobile-dropdown-content a {
  font-size: 10px !important;
  color: var(--muted) !important;
  font-family: var(--mono) !important;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 12px 16px !important;
  text-decoration: none !important;
}

.mobile-dropdown-content a:hover { color: var(--purple) !important; }

/* ── SECTION BASE ── */
section { padding: 130px 56px; }

.section-tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--purple);
  margin-bottom: 56px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.section-tag::before {
  content: '';
  width: 28px;
  height: 1px;
  background: var(--purple);
}

/* ── CONTACT ── */
#contact {
  background: var(--ink);
  padding: 80px 56px 140px;
}

.contact-heading {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(40px, 6vw, 86px);
  color: var(--white);
  margin-bottom: 64px;
  line-height: 1.1;
  max-width: 700px;
}

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

.contact-link {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 24px 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  
  transition: padding-left 0.3s;
}

.contact-link:hover { padding-left: 12px; }

.contact-link:first-child { border-top: 1px solid var(--border); }

.contact-arrow {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--purple);
  flex-shrink: 0;
}

.contact-label {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--muted);
  width: 80px;
  flex-shrink: 0;
}

.contact-value {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--cream);
  letter-spacing: 0.5px;
}

/* ── FOOTER (home page) ── */
footer {
  padding: 48px 56px;
  background: var(--black);
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

footer p {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.5px;
  color: var(--muted);
}

footer span { color: var(--purple); }

/* ── REVEAL ── */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1); }
.reveal.active { opacity: 1; transform: translateY(0); }

/* ── TOUCH ── */
@media (hover: none) and (pointer: coarse) {
  
  body { cursor: auto; }
  a, button, input, textarea, .nav-btn, .filter-btn, .topic-btn, .project-card, .article-row, .btn-call, .btn-resume { cursor: auto !important; }
}

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

/* ── RESPONSIVE ── */
@media (max-width: 960px) {
  .nav-links { display: none; }
  .nav-mobile-toggle { display: flex; }
}

