/**
 * Emanuele Sabbadini - Solutions Architect & Technical Lead
 * High-End Industrial OT & Enterprise IT Convergence Design System
 */

:root {
  /* Core Color Palette */
  --bg-primary: #080c14;
  --bg-secondary: #0d1424;
  --bg-card: rgba(16, 24, 40, 0.75);
  --bg-card-hover: rgba(24, 36, 60, 0.85);
  --bg-card-elevated: #162035;
  
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-medium: rgba(255, 255, 255, 0.14);
  --border-focus: #38bdf8;
  --border-glow: rgba(56, 189, 248, 0.35);

  /* Accents */
  --cyan: #06b6d4;
  --cyan-bright: #22d3ee;
  --blue: #38bdf8;
  --emerald: #10b981;
  --amber: #f59e0b;
  --indigo: #6366f1;

  /* Typography */
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-highlight: #e2e8f0;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --font-mono: "JetBrains Mono", "Fira Code", ui-monospace, Menlo, Monaco, Consolas, monospace;

  /* Transitions & Radii */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-full: 9999px;
  --transition-fast: 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-normal: 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  color-scheme: dark;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
}

/* Background Ambient Lighting */
.bg-ambient-glow {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 0;
  background: 
    radial-gradient(circle at 15% 15%, rgba(6, 182, 212, 0.07) 0%, transparent 45%),
    radial-gradient(circle at 85% 25%, rgba(99, 102, 241, 0.06) 0%, transparent 50%),
    radial-gradient(circle at 50% 80%, rgba(16, 185, 129, 0.05) 0%, transparent 45%);
}

.bg-grid-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 40px 40px;
}

.main-content-wrap {
  position: relative;
  z-index: 1;
}

/* Utilities */
.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
}

.glass-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-medium);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.6);
}

.text-gradient {
  background: linear-gradient(135deg, #38bdf8 0%, #22d3ee 50%, #818cf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-cyan { color: var(--cyan); }
.text-emerald { color: var(--emerald); }
.text-amber { color: var(--amber); }
.text-indigo { color: var(--indigo); }

/* Header & Navigation */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
  padding: 20px 0;
  transition: all var(--transition-normal);
  box-sizing: border-box;
}

.site-header .container {
  width: 100%;
  max-width: 1380px;
  padding: 0 28px;
  box-sizing: border-box;
}

.site-header.scrolled {
  background: rgba(8, 12, 20, 0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 12px 0;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(16px, 2.5vw, 40px);
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.brand-monogram {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--text-primary);
  flex-shrink: 0;
  min-width: 0;
}

.monogram-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.2), rgba(99, 102, 241, 0.2));
  border: 1px solid rgba(56, 189, 248, 0.4);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 15px;
  color: var(--cyan-bright);
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.2);
  flex-shrink: 0;
}

.brand-name {
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand-role {
  display: block;
  font-size: 11.5px;
  color: var(--text-secondary);
  font-weight: 400;
  margin-top: 1px;
  white-space: nowrap;
}

.desktop-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 1.6vw, 28px);
  flex-grow: 1;
  min-width: 0;
}

.desktop-nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  transition: color var(--transition-fast);
  position: relative;
  padding: 6px 2px;
  white-space: nowrap;
}

.desktop-nav-link:hover,
.desktop-nav-link.active {
  color: var(--text-primary);
}

.desktop-nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--cyan-bright);
  border-radius: var(--radius-full);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.4vw, 18px);
  flex-shrink: 0;
  min-width: 0;
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 3px;
  gap: 2px;
  flex-shrink: 0;
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.lang-btn:hover {
  color: var(--text-primary);
}

.lang-btn.active {
  background: var(--bg-surface-elevated);
  color: var(--cyan-bright);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.btn-header-cv {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: var(--cyan-bright);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  transition: all var(--transition-fast);
  white-space: nowrap;
  flex-shrink: 0;
}

.btn-header-cv:hover {
  background: rgba(56, 189, 248, 0.2);
  border-color: var(--cyan-bright);
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.3);
}

/* Mobile Toggle */
.mobile-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 6px;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
}

/* Hero Section */
.hero-section {
  padding: 160px 0 80px 0;
  position: relative;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 60px;
  align-items: center;
}

.hero-main {
  max-width: 720px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 13px;
  font-weight: 500;
  color: #34d399;
  margin-bottom: 24px;
}

.status-pulse-dot {
  width: 8px;
  height: 8px;
  background: var(--emerald);
  border-radius: 50%;
  position: relative;
}

.status-pulse-dot::after {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  border: 2px solid var(--emerald);
  border-radius: 50%;
  animation: pulse-ring 2s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(0.6); opacity: 0.8; }
  100% { transform: scale(2.2); opacity: 0; }
}

.hero-title {
  font-size: 48px;
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.025em;
  margin-bottom: 20px;
  color: var(--text-primary);
}

.hero-subtitle {
  font-size: 18px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #0284c7, #06b6d4);
  color: #ffffff;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all var(--transition-fast);
  box-shadow: 0 4px 20px rgba(6, 182, 212, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #0369a1, #0891b2);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(6, 182, 212, 0.45);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--text-secondary);
  transform: translateY(-1px);
}

.hero-location {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
}

/* Hero Profile Card */
.hero-profile-card {
  text-align: center;
  padding: 32px 24px;
  position: relative;
  overflow: hidden;
}

.hero-profile-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--cyan), var(--blue), var(--indigo));
}

.profile-avatar-box {
  width: 175px;
  height: 175px;
  margin: 0 auto 20px auto;
  border-radius: 50%;
  padding: 4px;
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.5), rgba(99, 102, 241, 0.3));
  box-shadow: 0 0 30px rgba(6, 182, 212, 0.25);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal);
  overflow: hidden;
}

.profile-avatar-box:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 0 35px rgba(6, 182, 212, 0.4);
}

.profile-avatar-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: #111827;
  display: block;
}

.profile-card-name {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 4px;
}

.profile-card-role {
  font-size: 13px;
  color: var(--cyan-bright);
  font-weight: 500;
  margin-bottom: 16px;
}

.profile-social-links {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}

.social-icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.social-icon-btn:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: var(--cyan-bright);
  color: var(--cyan-bright);
  transform: translateY(-2px);
}

/* Stats Counter Bar */
.stats-bar {
  margin-top: 50px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.stat-item {
  padding: 20px 16px;
  text-align: center;
}

.stat-num {
  font-size: 28px;
  font-weight: 800;
  color: var(--cyan-bright);
  font-family: var(--font-mono);
  line-height: 1.1;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.35;
}

/* Sections Common */
.section {
  padding: 90px 0;
  position: relative;
}

.section-header {
  margin-bottom: 48px;
  text-align: center;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.section-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cyan);
  margin-bottom: 12px;
}

.section-title {
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--text-secondary);
}

/* Summary Section */
.summary-lead {
  font-size: 18px;
  line-height: 1.7;
  color: var(--text-highlight);
  margin-bottom: 18px;
}

.summary-paragraphs {
  margin-bottom: 40px;
}

.summary-paragraphs p {
  color: var(--text-secondary);
  margin-bottom: 14px;
}

.pillars-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.pillar-card {
  padding: 28px;
}

.pillar-icon-box {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}

.pillar-title {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.pillar-desc {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* IT/OT Convergence Stack */
.convergence-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 960px;
  margin: 0 auto;
}

.convergence-tier {
  padding: 24px 28px;
  position: relative;
  transition: all var(--transition-normal);
  border-left: 4px solid var(--border-subtle);
}

.convergence-tier[data-tier="0"] { border-left-color: #818cf8; }
.convergence-tier[data-tier="1"] { border-left-color: #38bdf8; }
.convergence-tier[data-tier="2"] { border-left-color: #22d3ee; }
.convergence-tier[data-tier="3"] { border-left-color: #10b981; }

.convergence-tier.highlighted,
.convergence-tier:hover {
  transform: translateX(6px);
  border-left-width: 6px;
}

.tier-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.tier-badge {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.tier-badge-1 { background: rgba(129, 140, 248, 0.15); color: #a5b4fc; }
.tier-badge-2 { background: rgba(56, 189, 248, 0.15); color: #7dd3fc; }
.tier-badge-3 { background: rgba(34, 211, 238, 0.15); color: #67e8f9; }
.tier-badge-4 { background: rgba(16, 185, 129, 0.15); color: #6ee7b7; }

.tier-title {
  font-size: 18px;
  font-weight: 700;
}

.tier-tech {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--cyan-bright);
  margin-bottom: 8px;
}

.tier-desc {
  font-size: 14px;
  color: var(--text-secondary);
}

/* Experience Timeline */
.timeline-container {
  position: relative;
  max-width: 960px;
  margin: 0 auto;
}

.timeline-container::before {
  content: '';
  position: absolute;
  top: 20px;
  bottom: 20px;
  left: 20px;
  width: 2px;
  background: linear-gradient(180deg, var(--cyan) 0%, var(--indigo) 60%, rgba(255,255,255,0.05) 100%);
}

.timeline-item {
  position: relative;
  padding-left: 56px;
  margin-bottom: 40px;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-node {
  position: absolute;
  top: 24px;
  left: 12px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 3px solid var(--cyan-bright);
  box-shadow: 0 0 12px rgba(6, 182, 212, 0.5);
}

.timeline-content {
  padding: 32px;
}

.timeline-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 8px;
}

.timeline-period {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--cyan-bright);
  background: rgba(6, 182, 212, 0.1);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
}

.timeline-location {
  font-size: 13px;
  color: var(--text-muted);
}

.timeline-title {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 4px;
  color: var(--text-primary);
}

.timeline-company {
  font-size: 16px;
  font-weight: 600;
  color: #a5b4fc;
  margin-bottom: 16px;
}

.timeline-env {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.timeline-env strong {
  color: var(--text-highlight);
}

.timeline-highlights {
  list-style: none;
}

.timeline-highlights li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 12px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}

.timeline-highlights li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--cyan-bright);
  font-size: 14px;
}

.timeline-highlights li strong {
  color: var(--text-primary);
}

/* Case Studies / Projects Grid */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.case-study-card {
  padding: 30px;
  display: flex;
  flex-direction: column;
}

.case-study-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.case-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--cyan-bright);
  background: rgba(6, 182, 212, 0.12);
  padding: 4px 10px;
  border-radius: var(--radius-full);
}

.case-org {
  font-size: 12px;
  color: var(--text-muted);
}

.case-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-primary);
}

.case-desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 20px;
  flex-grow: 1;
}

.case-tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.tech-pill {
  font-family: var(--font-mono);
  font-size: 12px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.tech-pill:hover {
  background: rgba(56, 189, 248, 0.15);
  border-color: rgba(56, 189, 248, 0.4);
  color: var(--cyan-bright);
}

/* Skills Hub */
.skills-filter-nav {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}

.skill-filter-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.skill-filter-btn:hover {
  color: var(--text-primary);
  border-color: var(--border-medium);
}

.skill-filter-btn.active {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.2), rgba(99, 102, 241, 0.2));
  border-color: var(--cyan-bright);
  color: var(--cyan-bright);
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.25);
}

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

.skills-category {
  padding: 28px;
  transition: opacity 0.3s ease;
}

.skills-category-header {
  margin-bottom: 18px;
}

.skills-category-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-primary);
}

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

.skill-badge {
  font-size: 13px;
  font-weight: 500;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-highlight);
  transition: all var(--transition-fast);
}

.skill-badge:hover {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--cyan-bright);
  color: #ffffff;
  transform: translateY(-2px);
}

/* Education & Languages */
.education-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.education-card {
  padding: 28px;
  display: flex;
  flex-direction: column;
}

.education-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}

.education-degree {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}

.education-year {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--cyan-bright);
  background: rgba(6, 182, 212, 0.1);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.education-institution {
  font-size: 14px;
  color: #a5b4fc;
  font-weight: 500;
  margin-bottom: 12px;
}

.education-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.languages-card {
  grid-column: span 1;
}

.language-items-wrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 14px;
}

.lang-row {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.lang-name {
  font-size: 15px;
  color: var(--text-primary);
}

.lang-level {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Contact Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 32px;
}

.contact-info-card {
  padding: 36px;
  display: flex;
  flex-direction: column;
}

.contact-card-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 12px;
}

.contact-card-text {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 30px;
}

.contact-meta-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 30px;
}

.contact-meta-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.contact-meta-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--cyan-bright);
  flex-shrink: 0;
}

.contact-meta-label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-family: var(--font-mono);
}

.contact-meta-value {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
}

.contact-meta-value a {
  color: var(--cyan-bright);
  text-decoration: none;
}

.contact-meta-value a:hover {
  text-decoration: underline;
}

.contact-action-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: auto;
}

.btn-copy-email {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-copy-email:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--cyan-bright);
}

.copy-feedback {
  font-size: 12px;
  color: var(--emerald);
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s ease;
  align-self: center;
}

.copy-feedback.visible {
  opacity: 1;
}

/* Contact Form */
.contact-form-card {
  padding: 36px;
}

.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-input,
.form-textarea {
  width: 100%;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  transition: all var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--cyan-bright);
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.25);
  background: rgba(0, 0, 0, 0.45);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

.form-note {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 10px;
}

.form-status-box {
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  line-height: 1.5;
  transition: all var(--transition-normal);
}

.form-status-box.success {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #6ee7b7;
}

.form-status-box.error {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fde68a;
}

.form-status-actions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.form-status-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  text-decoration: none;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-primary);
  transition: all var(--transition-fast);
}

.form-status-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: var(--cyan-bright);
  color: var(--cyan-bright);
}

.btn-primary:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none !important;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 40px 0;
  background: rgba(8, 12, 20, 0.95);
  position: relative;
  z-index: 10;
}

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

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

.footer-privacy {
  font-size: 12px;
  color: var(--text-muted);
  font-style: italic;
  max-width: 600px;
}

.footer-domain {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--cyan);
}

/* Mobile Navigation Overlay Drawer */
.mobile-nav-drawer {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(8, 12, 20, 0.98);
  backdrop-filter: blur(20px);
  z-index: 200;
  display: flex;
  flex-direction: column;
  padding: 30px;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.mobile-nav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 40px;
}

.mobile-nav-close {
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 24px;
  cursor: pointer;
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.mobile-nav-link {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.mobile-nav-link:hover {
  color: var(--cyan-bright);
}

/* Responsive Media Queries */
/* Screens between 1180px and 1320px */
@media (max-width: 1320px) {
  .site-header .container {
    padding: 0 20px;
  }
  .header-inner {
    gap: 20px;
  }
  .desktop-nav {
    gap: 14px;
  }
  .desktop-nav-link {
    font-size: 13px;
  }
  .btn-header-cv {
    padding: 7px 12px;
    font-size: 12px;
  }
}

/* Below 1180px: Switch to mobile toggle drawer so the right side NEVER overflows */
@media (max-width: 1180px) {
  .desktop-nav {
    display: none;
  }
  .mobile-toggle {
    display: flex;
  }
}

@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .hero-profile-card {
    max-width: 440px;
    margin: 0 auto;
  }
  .education-container {
    grid-template-columns: 1fr;
  }
}

/* Tablet & Mobile down to 860px */
@media (max-width: 860px) {
  .site-header {
    padding: 12px 0;
  }
  .site-header .container {
    padding: 0 16px;
  }
  .header-inner {
    gap: 12px;
  }
  /* Hide the large CV download button in top bar on mobile/tablet (available in drawer & hero card) */
  .site-header .btn-header-cv {
    display: none;
  }
  .brand-role {
    display: none;
  }
  .brand-name {
    font-size: 16px;
  }
  .monogram-badge {
    width: 36px;
    height: 36px;
    font-size: 14px;
  }
  .hero-title {
    font-size: 36px;
  }
  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
  }
  .pillars-grid,
  .projects-grid,
  .skills-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }
}

/* Extra small mobile (< 420px) */
@media (max-width: 420px) {
  .profile-avatar-box {
    width: 150px;
    height: 150px;
  }
  .site-header .header-actions .lang-switcher {
    display: none; /* Clean & accessible inside the mobile drawer */
  }
  .brand-name {
    font-size: 15px;
  }
  .brand-monogram {
    gap: 8px;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 60px 0;
  }
  .hero-section {
    padding: 120px 0 50px 0;
  }
  .hero-title {
    font-size: 30px;
  }
  .stats-bar {
    grid-template-columns: 1fr;
  }
  .timeline-container::before {
    left: 10px;
  }
  .timeline-node {
    left: 2px;
  }
  .timeline-item {
    padding-left: 36px;
  }
  .timeline-content {
    padding: 20px;
  }
}

/* ==========================================================================
   Print Stylesheet (Pristine Executive CV for PDF/Printing)
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #111827 !important;
    font-size: 11pt !important;
    line-height: 1.4 !important;
  }

  .bg-ambient-glow,
  .bg-grid-overlay,
  .site-header,
  .hero-cta-group,
  .status-badge,
  .stats-bar,
  .skills-filter-nav,
  .contact-form-card,
  .btn-copy-email,
  .copy-feedback,
  .site-footer,
  .mobile-nav-drawer,
  .mobile-toggle,
  .profile-social-links,
  .trigger-print-cv {
    display: none !important;
  }

  .container {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .section {
    padding: 16px 0 !important;
    page-break-inside: avoid;
  }

  .glass-card {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }

  .hero-section {
    padding: 0 0 20px 0 !important;
  }

  .hero-content {
    display: block !important;
  }

  .hero-profile-card {
    display: none !important;
  }

  .hero-title {
    font-size: 22pt !important;
    color: #0f172a !important;
    margin-bottom: 4px !important;
  }

  .text-gradient {
    background: none !important;
    -webkit-text-fill-color: #0f172a !important;
    color: #0f172a !important;
  }

  .hero-subtitle {
    font-size: 11pt !important;
    color: #334155 !important;
    margin-bottom: 8px !important;
  }

  .section-title {
    font-size: 14pt !important;
    color: #0f172a !important;
    border-bottom: 1.5pt solid #cbd5e1 !important;
    padding-bottom: 4px !important;
    margin-bottom: 10px !important;
    text-transform: uppercase;
  }

  .section-tag,
  .section-subtitle {
    display: none !important;
  }

  .timeline-container::before {
    display: none !important;
  }

  .timeline-node {
    display: none !important;
  }

  .timeline-item {
    padding-left: 0 !important;
    margin-bottom: 16px !important;
    page-break-inside: avoid;
  }

  .timeline-title {
    font-size: 12pt !important;
    color: #0f172a !important;
  }

  .timeline-company {
    font-size: 11pt !important;
    color: #2563eb !important;
  }

  .timeline-period {
    background: none !important;
    color: #475569 !important;
    padding: 0 !important;
  }

  .timeline-env {
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    color: #334155 !important;
    padding: 4px 8px !important;
    margin-bottom: 8px !important;
  }

  .timeline-highlights li {
    color: #1e293b !important;
    margin-bottom: 4px !important;
  }

  .timeline-highlights li::before {
    color: #2563eb !important;
  }

  .skill-badge {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border: 1px solid #cbd5e1 !important;
  }

  .projects-grid,
  .pillars-grid,
  .education-container {
    grid-template-columns: 1fr 1fr !important;
    gap: 12px !important;
  }

  .case-study-card {
    border: 1px solid #e2e8f0 !important;
    padding: 12px !important;
  }

  .case-title {
    font-size: 11pt !important;
    color: #0f172a !important;
  }

  .case-desc {
    font-size: 9.5pt !important;
    color: #334155 !important;
  }

  .tech-pill {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border: 1px solid #e2e8f0 !important;
  }
}
