:root {
  --color-bg: #0a0a0a;
  --color-surface: #111111;
  --color-card: #161616;
  --color-fg: #ffffff;
  --color-accent: #00d4ff;
  --color-accent-dark: #0099cc;
  --color-muted: #888888;
  --color-border: #333333;
  --color-success: #00ff88;
  --color-warning: #ffaa00;
  --color-gradient-primary: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
  --color-gradient-surface: linear-gradient(135deg, #161616 0%, #1a1a1a 100%);

  --font-main:
    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", "Fira Code", Consolas, monospace;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow: 0 4px 20px rgba(0, 212, 255, 0.1);
  --shadow-lg: 0 8px 32px rgba(0, 212, 255, 0.15);
  --shadow-hover: 0 12px 40px rgba(0, 212, 255, 0.2);
  --border-glow: 0 0 20px rgba(0, 212, 255, 0.3);
  --touch-target: 44px;
  --header-height: 64px;
}

/* === Responsive Hardening Layer === */

/* Fluid media: prevent overflow on small screens */
:is(img, video, canvas, svg, iframe) {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Ensure <picture> elements remain fluid via their <img> */
picture > img {
  max-width: 100%;
}

/* Responsive iframe wrapper */
.iframe-container {
  position: relative;
  width: 100%;
  aspect-ratio: var(--iframe-aspect, 16/9);
  overflow: clip;
}
.iframe-container > iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.iframe-skeleton {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font:
    500 14px/1.2 system-ui,
    sans-serif;
  opacity: 0.8;
}

/* Prevent horizontal scroll with wide code/tables */
pre,
code {
  white-space: pre-wrap;
  word-break: break-word;
}

/* Keep tables responsive without breaking semantics.
   Wrap tables in a .table-wrapper to enable horizontal scrolling. */
.table-wrapper {
  overflow-x: auto;
}

table {
  width: 100%;
}

/* Respect user font scaling and keep consistent sizing */
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* Make in-page anchor jumps clear the sticky header */
h1,
h2,
h3,
h4,
h5,
h6,
[id] {
  scroll-margin-top: calc(var(--header-height) + 16px);
}

/* Visible keyboard focus, also useful on touch+keyboard hybrids */
:focus-visible {
  outline: 2px dashed var(--color-accent, #00d0ff);
  outline-offset: 4px;
  border-radius: 4px;
}

/* Safe area support for phones with notches */
body,
header {
  padding-top: env(safe-area-inset-top, 0);
}

body {
  background: var(--color-bg);
  color: var(--color-fg);
  font-family: var(--font-main);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  overflow-x: hidden;
  font-size: 1rem;
  line-height: 1.6;
  font-weight: 300;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 1rem 0;
  letter-spacing: -0.025em;
}

h1 {
  font-size: 3rem;
  font-weight: 300;
  background: var(--color-gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

h2 {
  font-size: 2rem;
  font-weight: 500;
  color: var(--color-fg);
}

h3 {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--color-accent);
}

p {
  margin: 0 0 1rem 0;
  font-weight: 300;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--color-muted);
  font-weight: 400;
  margin: 1rem 0;
}

.card-subtitle {
  font-style: italic;
  color: var(--color-muted);
}

.hero-location {
  font-size: 1rem;
  color: var(--color-accent);
  font-weight: 500;
  font-family: var(--font-mono);
}

/* Header & Navigation */
header {
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--color-border);
  position: sticky;
  top: 0;
  z-index: 100;
  transition: transform 0.3s ease;
  overflow: visible;
  min-height: var(--header-height);
  box-sizing: border-box;
}

.skip-link {
  position: absolute;
  top: 0;
  left: 0;
  transform: translateY(-100%);
  background: var(--color-accent);
  color: var(--color-bg);
  padding: 0.5rem 1rem;
  z-index: 1000;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.brand {
  text-decoration: none;
}

.brand span {
  /* Fallback solid color for browsers that do not support background-clip: text */
  color: var(--color-accent);
  font-size: 1.5rem;
  font-weight: 600;
  background: var(--color-gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text; /* Not supported in Firefox as of 2024 */
  /* If background-clip: text is not supported, the fallback color will be used */
}

/* Desktop navigation */
.desktop-nav {
  display: flex;
  align-items: center;
  margin-top: 0;
}

.mobile-nav nav {
  display: flex;
  flex-direction: column;
  margin: 0;
  width: 100%;
}

/* Fallback spacing for browsers without flexbox gap */
.desktop-nav a + a {
  margin-left: 2rem;
}

.mobile-nav nav a + a {
  margin-top: 0.75rem;
}

@supports (gap: 1rem) {
  .desktop-nav {
    gap: 2rem;
  }
  .mobile-nav nav {
    gap: 0.75rem;
  }
  .desktop-nav a + a,
  .mobile-nav nav a + a {
    margin: 0;
  }
}

.mobile-nav nav a {
  display: block;
  padding: 1rem;
  text-align: center;
  border-radius: var(--radius);
  background: var(--color-card);
  transition: all 0.3s ease;
  font-weight: 500;
  text-decoration: none;
  color: var(--color-fg);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  min-height: var(--touch-target);
}

.mobile-nav nav a:hover,
.mobile-nav nav a:focus,
.mobile-nav nav a:focus-visible,
.mobile-nav nav a.active {
  background: var(--color-accent);
  color: var(--color-bg);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.mobile-nav nav a:focus,
.mobile-nav nav a:focus-visible {
  outline-color: var(--color-bg);
}

.mobile-nav nav a:active {
  transform: scale(0.98);
}

.desktop-nav a {
  color: var(--color-muted);
  text-decoration: none;
  font-weight: 400;
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  transition: color 0.3s ease, background 0.3s ease;
  font-family: var(--font-mono);
  font-size: 0.9rem;
}

.desktop-nav a:hover,
.desktop-nav a:focus,
.desktop-nav a:focus-visible {
  color: var(--color-accent);
  background: rgba(0, 212, 255, 0.1);
}

.desktop-nav a:focus,
.desktop-nav a:focus-visible {
  outline: 2px dashed var(--color-accent);
  outline-offset: 4px;
}

.desktop-nav a.active {
  color: var(--color-accent);
  background: rgba(0, 212, 255, 0.15);
  box-shadow: var(--border-glow);
}

.hamburger {
  appearance: none;
  border: none;
  background: transparent;
  padding: 8px;
  margin: 0;
  width: 44px;
  height: 44px; /* 44x44 Apple HIG */
  display: grid;
  place-items: center;
  line-height: 1;
  cursor: pointer;
  z-index: 60; /* above header & panel */
}

/* Mobile dropdown panel */
.mobile-nav {
  position: absolute;
  top: calc(var(--header-height) + 0.5rem);
  right: 1rem;
  width: min(260px, calc(100% - 2rem));
  z-index: 100;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: calc(env(safe-area-inset-top, 0) + 1rem)
    calc(env(safe-area-inset-right, 0) + 1rem)
    calc(env(safe-area-inset-bottom, 0) + 1rem)
    calc(env(safe-area-inset-left, 0) + 1rem);
}

.mobile-nav .close-nav {
  align-self: flex-end;
  background: transparent;
  border: none;
  color: var(--color-fg);
  width: 44px;
  height: 44px;
  margin-bottom: 0.5rem;
  cursor: pointer;
}

html.nav-open,
html.nav-open body {
  overflow: hidden;
}

/* Avatar sizing & containment */
.avatar,
.avatar img {
  display: block;
  width: clamp(160px, 40vw, 320px);
  height: auto;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  object-fit: contain;
}

/* Placeholder styling to stabilize layout during scaffolding */
/* Layout */
.section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 4rem 2rem;
  background: none;
}

.hero-section {
  text-align: center;
  padding: 6rem 2rem;
  background: var(--color-surface);
  border-radius: var(--radius-lg);
  margin-bottom: 4rem;
  border: 1px solid var(--color-border);
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--color-gradient-primary);
}

.hero-image {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  border: 2px solid var(--color-accent);
  margin: 0 auto 2rem;
  box-shadow: var(--border-glow);
  display: block;
  object-fit: contain;
}

.hero-image--cover {
  object-fit: cover;
}

.cta-group {
  margin-top: 2rem;
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Expertise Grid */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.expertise-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  transition: all 0.3s ease;
  position: relative;
}

.expertise-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--color-accent);
}

.expertise-icon {
  width: 60px;
  height: 60px;
  background: var(--color-gradient-surface);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: var(--color-accent);
  border: 1px solid var(--color-border);
  transition: all 0.3s ease;
}

.expertise-icon svg {
  width: 48px;
  height: 48px;
  stroke: currentColor;
}

/* Current Role Card */
.current-role {
  background: var(--color-card);
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.current-role::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--color-gradient-primary);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.role-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.role-duration {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--color-accent);
  background: rgba(0, 212, 255, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius);
}

.company {
  color: var(--color-muted);
  font-weight: 400;
  margin-bottom: 1rem;
}

.role-description {
  font-size: 1.1rem;
  line-height: 1.7;
  margin: 1rem 0 2rem;
}

.achievement-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.metric {
  text-align: center;
  padding: 1rem;
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
}

.metric-number {
  display: block;
  font-size: 2rem;
  font-weight: 600;
  color: var(--color-accent);
  font-family: var(--font-mono);
}

.metric-label {
  font-size: 0.8rem;
  color: var(--color-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Technical Stack Styling */
.tech-stack-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.tech-category {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}

.tech-category h3 {
  margin-bottom: 1rem;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-fg);
}

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

.tech-tag {
  background: var(--color-surface);
  color: var(--color-muted);
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius);
  font-size: 0.8rem;
  font-weight: 400;
  border: 1px solid var(--color-border);
  font-family: var(--font-mono);
  transition: all 0.3s ease;
}

.tech-tag.primary {
  background: rgba(0, 212, 255, 0.1);
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.tech-tag:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 212, 255, 0.2);
}

/* Certifications Grid */
.certifications-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin: 2rem 0;
}

.cert-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s ease;
}

.cert-card.featured {
  border-color: var(--color-accent);
  background: var(--color-gradient-surface);
}

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

.cert-badge {
  width: 50px;
  height: 50px;
  margin: 0 auto 1rem;
  background: var(--color-gradient-primary);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-bg);
  transition: all 0.3s ease;
}

.cert-badge svg {
  width: 32px;
  height: 32px;
  stroke: currentColor;
  stroke-width: 2;
}

.cert-card h4 {
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  color: var(--color-fg);
}

.cert-card p {
  font-size: 0.8rem;
  color: var(--color-muted);
  margin: 0;
}

/* Career Narrative */
.career-narrative {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  border-left: 4px solid var(--color-accent);
}

.narrative-text {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--color-fg);
  margin-bottom: 1.5rem;
}

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

/* Cards & Components */
.card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin: 0 auto;
  color: var(--color-fg);
  transition: all 0.3s ease;
}

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

.cta-button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  border: 1px solid var(--color-accent);
  background: var(--color-gradient-primary);
  color: var(--color-bg);
  font-weight: 500;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  min-width: var(--touch-target);
  min-height: var(--touch-target);
  text-align: center;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  color: var(--color-bg);
}

.cta-button.secondary {
  background: transparent;
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.cta-button.secondary:hover {
  background: rgba(0, 212, 255, 0.1);
  color: var(--color-accent);
}

/* Footer */
footer {
  background: var(--color-surface);
  color: var(--color-muted);
  text-align: center;
  padding: 3rem 0;
  margin-top: 4rem;
  border-top: 1px solid var(--color-border);
}

.footer-location {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--color-accent);
  margin-top: 0.5rem;
}

/* Utility Classes */
.grid {
  display: grid;
  gap: 2rem;
  margin-top: 2rem;
}

.grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.section-spacing {
  margin-top: 4rem;
  margin-bottom: 4rem;
}

.centered-flex {
  display: flex;
  align-items: center;
  justify-content: center;
}

.flex-column {
  flex-direction: column;
}

/* Responsive Design */

/* Tablet and smaller navigation */
@media (max-width: 1023px) {
  .desktop-nav {
    display: none;
  }
  .hamburger {
    display: grid;
  }
}

/* Mobile-First Responsive Design */
@media (max-width: 480px) {
  body {
    font-size: 0.9rem;
  }

  .section {
    padding: 1.5rem 1rem;
  }

  header .section {
    padding: 1rem;
  }

  .brand span {
    font-size: 1.5rem;
    margin-bottom: 0;
  }

  .desktop-nav {
    display: none;
  }
  .hamburger {
    display: grid;
  }

  .hero-section {
    padding: 3rem 1rem;
    text-align: center;
  }

  h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
  }

  h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
  }

  h3 {
    font-size: 1.1rem;
  }

  .hero-subtitle {
    font-size: 1rem;
    margin: 0.75rem 0;
  }

  .hero-location {
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
  }

  .cta-group {
    flex-direction: column;
    gap: 0.75rem;
    align-items: stretch;
  }

  .cta-button {
    display: flex;
    width: 100%;
    margin: 0;
    padding: 0.875rem 1.5rem;
    font-size: 0.9rem;
    justify-content: center;
    align-items: center;
    text-align: center;
    box-sizing: border-box;
  }

  .cta-button.secondary {
    width: 100%;
  }

  .expertise-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .expertise-card {
    padding: 1.5rem;
  }

  .expertise-icon {
    width: 40px;
    height: 40px;
    font-size: 0.75rem;
    margin-bottom: 1rem;
  }

  .current-role {
    padding: 1.5rem;
  }

  .role-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 1rem;
  }

  .role-duration {
    font-size: 0.8rem;
  }

  .achievement-metrics {
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-top: 1.5rem;
  }

  .metric {
    padding: 1rem;
    text-align: center;
  }

  .metric-number {
    font-size: 1.75rem;
  }

  .tech-stack-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .tech-category {
    text-align: center;
  }

  .tech-tags {
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .tech-tag {
    font-size: 0.8rem;
    padding: 0.375rem 0.75rem;
  }

  .certifications-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }

  .cert-card {
    padding: 1rem;
    text-align: center;
  }

  .cert-badge {
    width: 40px;
    height: 40px;
    font-size: 0.7rem;
    margin: 0 auto 0.75rem;
  }

  .cert-card h4 {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
  }

  .cert-card p {
    font-size: 0.8rem;
  }

  .career-narrative {
    padding: 1.5rem;
  }

  .narrative-text {
    font-size: 0.95rem;
    line-height: 1.7;
  }

  footer {
    text-align: center;
    padding: 2rem 1rem;
  }

  footer p {
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
  }
}

@media (min-width: 481px) and (max-width: 767px) {
  .section {
    padding: 2rem 1.5rem;
  }

  .desktop-nav {
    display: none;
  }
  .hamburger {
    display: grid;
  }

  .hero-section {
    padding: 4rem 2rem;
  }

  h1 {
    font-size: 2.5rem;
  }

  h2 {
    font-size: 1.75rem;
  }

  .expertise-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .tech-stack-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }

  .certifications-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }

  .achievement-metrics {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }

  .cta-group {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }

  .cta-button {
    width: 200px;
  }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .section {
    padding: 3rem 2rem;
  }

  /* navigation visibility handled in global queries */

  .expertise-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .tech-stack-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .certifications-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .hamburger {
    display: none;
  }
  .desktop-nav {
    display: flex;
  }
}

/* Touch-friendly interactions */
@media (hover: none) and (pointer: coarse) {
  .cta-button,
  .card,
  nav a,
  .cert-card,
  .expertise-card {
    transition:
      transform 0.2s ease,
      box-shadow 0.2s ease;
  }

  .cta-button:active {
    transform: scale(0.98);
  }

  .card:active,
  .cert-card:active,
  .expertise-card:active {
    transform: translateY(2px);
  }

  nav a:active {
    transform: scale(0.95);
  }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .hero-image,
  .expertise-icon,
  .cert-badge {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* Skeleton loader for Wix HTML injection */
.loader {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 6px solid var(--color-border);
  border-top: 6px solid var(--color-accent);
  animation: spin 1s linear infinite;
  font-family:
    var(--font-main),
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Arial,
    sans-serif;
  font-size: 1rem;
  z-index: 1000;
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Contact Page Styles */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.contact-card {
  height: fit-content;
}

.contact-method {
  margin: 1.5rem 0;
  padding: 1rem 0;
  border-bottom: 1px solid var(--color-border);
}

.contact-method:last-child {
  border-bottom: none;
}

.contact-method h3 {
  margin: 0 0 0.5rem 0;
  color: var(--color-accent);
  font-size: 1rem;
  font-weight: 600;
}

.contact-method p {
  margin: 0;
  font-size: 1.1rem;
}

.contact-method a {
  color: var(--color-fg);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

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

.location-note {
  font-size: 0.9rem !important;
  color: var(--color-muted) !important;
  margin-top: 0.25rem !important;
}

.expertise-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.expertise-list li {
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--color-border);
  font-size: 1rem;
  line-height: 1.5;
}

.expertise-list li:last-child {
  border-bottom: none;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.service-item {
  padding: 1.5rem;
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  transition: all 0.3s ease;
}

.service-item:hover {
  background: var(--color-card);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.service-item h3 {
  margin: 0 0 0.75rem 0;
  font-size: 1.1rem;
  color: var(--color-accent);
}

.service-item p {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--color-muted);
}

/* Resume Page Styles */
.job-entry {
  margin: 2rem 0;
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--color-border);
}

.job-entry:last-child {
  border-bottom: none;
}

.job-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.job-title-company h3 {
  margin: 0 0 0.25rem 0;
  font-size: 1.25rem;
  color: var(--color-fg);
}

.job-title-company .company {
  margin: 0;
  font-size: 1rem;
  color: var(--color-accent);
  font-weight: 500;
}

.job-duration {
  font-size: 0.9rem;
  color: var(--color-muted);
  font-family: var(--font-mono);
  background: var(--color-surface);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius);
  white-space: nowrap;
}

.job-responsibilities {
  list-style: none;
  padding: 0;
  margin: 0;
}

.job-responsibilities li {
  padding: 0.5rem 0;
  position: relative;
  padding-left: 1.5rem;
  line-height: 1.6;
}

.job-responsibilities li::before {
  content: "▶";
  position: absolute;
  left: 0;
  color: var(--color-accent);
  font-size: 0.75rem;
  top: 0.6rem;
}

.education-entry {
  padding: 1.5rem 0;
}

.degree-info h3 {
  margin: 0 0 0.5rem 0;
  color: var(--color-fg);
}

.degree-info .school {
  margin: 0 0 0.25rem 0;
  color: var(--color-accent);
  font-weight: 500;
}

.degree-info .graduation {
  margin: 0;
  color: var(--color-muted);
  font-size: 0.9rem;
}

.certifications-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.cert-item {
  padding: 1rem;
  background: var(--color-surface);
  border-radius: var(--radius);
  border: 1px solid var(--color-border);
  text-align: center;
  transition: all 0.3s ease;
}

.cert-item:hover {
  background: var(--color-card);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.cert-item h4 {
  margin: 0 0 0.5rem 0;
  font-size: 1rem;
  color: var(--color-fg);
}

.cert-item p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--color-accent);
  font-weight: 500;
}

.achievement-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.achievement-list li {
  padding: 1rem 0;
  border-bottom: 1px solid var(--color-border);
  line-height: 1.6;
}

.achievement-list li:last-child {
  border-bottom: none;
}

/* Mobile Optimizations for Contact and Resume */
@media (max-width: 767px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .services-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .job-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .certifications-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
}

@media (max-width: 480px) {
  .contact-method {
    margin: 1rem 0;
    padding: 0.75rem 0;
  }

  .service-item {
    padding: 1rem;
  }

  .job-responsibilities li {
    padding-left: 1rem;
    font-size: 0.95rem;
  }
}

/* === Global Navigation & Typography Upgrades === */
:root {
  --container-max: 1200px;
  --header-bg: rgba(11, 11, 16, 0.6);
  --header-bg-scrolled: rgba(11, 11, 16, 0.85);
}

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(8px);
  background: var(--header-bg);
  border-bottom: 1px solid var(--color-border);
  transition:
    background 0.3s ease,
    transform 0.3s ease;
}

.site-header.scrolled {
  background: var(--header-bg-scrolled);
}

.site-header.hide {
  transform: translateY(-100%);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.brand {
  font-weight: 600;
  color: var(--color-fg);
  text-decoration: none;
}

.nav-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: var(--touch-target);
  height: var(--touch-target);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--color-fg);
  transition:
    transform 0.3s ease,
    opacity 0.3s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav {
  padding: 2rem 1rem;
  background: var(--header-bg-scrolled);
}

.nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1rem;
}

.nav a {
  color: var(--color-fg);
  text-decoration: none;
  padding: 0.5rem 1rem;
  display: block;
  transition: color 0.2s ease;
}

.nav a:hover,
.nav a:focus {
  color: var(--color-accent);
}

#primary-nav[hidden] {
  display: none;
}

body.scroll-lock {
  overflow: hidden;
}

[data-menu-overlay] {
  position: fixed;
  inset: 0;
  padding-top: calc(var(--header-height) + env(safe-area-inset-top));
  padding-bottom: env(safe-area-inset-bottom);
  background: var(--header-bg-scrolled);
  overflow-y: auto;
  z-index: 100;
}

[data-menu-overlay][hidden] {
  display: none;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  width: auto;
  height: auto;
  clip: auto;
  padding: 0.5rem 1rem;
  background: var(--color-accent);
  color: #000;
  border-radius: var(--radius);
}

@media (max-width: 899px) {
  #primary-nav {
    display: none;
  }

  .nav a {
    padding: 0.75rem 1.25rem;
  }
}

@media (min-width: 900px) {
  .nav {
    padding: 0;
    background: none;
    margin-left: auto;
  }

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

  .nav-toggle {
    display: none;
  }

  #primary-nav[hidden] {
    display: flex;
  }
}

/* Typography */
h1 {
  font-size: clamp(2rem, 6vw, 3.5rem);
}

h2 {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
}

p {
  line-height: 1.7;
}
