/*
  Минималистичный стиль 2025: крупная типографика, воздушные отступы,
  адаптивная сетка, акцентные кнопки, плавные анимации, поддержка тем.
*/

:root {
  --bg: #ffffff;
  --fg: #0b0b0c;
  --muted: #6b6f76;
  --card: #f6f7f9;
  --border: #e5e7eb;
  --accent: #3b82f6;
  --accent-contrast: #ffffff;
  --shadow: 0 10px 30px rgba(0,0,0,0.06);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0b0c;
    --fg: #f4f6f8;
    --muted: #9aa0a6;
    --card: #111214;
    --border: #1b1c1f;
    --accent: #60a5fa;
    --accent-contrast: #0b0b0c;
    --shadow: 0 10px 30px rgba(0,0,0,0.35);
  }
}

/* Тема через атрибут data-theme имеет приоритет над системной */
[data-theme="light"] {
  --bg: #ffffff;
  --fg: #0b0b0c;
  --muted: #6b6f76;
  --card: #f6f7f9;
  --border: #e5e7eb;
  --accent: #3b82f6;
  --accent-contrast: #ffffff;
  --shadow: 0 10px 30px rgba(0,0,0,0.06);
}

[data-theme="dark"] {
  --bg: #0b0b0c;
  --fg: #f4f6f8;
  --muted: #9aa0a6;
  --card: #111214;
  --border: #1b1c1f;
  --accent: #60a5fa;
  --accent-contrast: #0b0b0c;
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 16px/1.6 system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial, sans-serif;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color .3s ease, color .3s ease;
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Fade in animation for sections */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero, .details, .portfolio {
  animation: fadeInUp 0.6s ease-out;
}

.portfolio { animation-delay: 0.1s; }

.site-footer {
  max-width: 880px;
  margin: 0 auto;
  padding: 24px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
}

.container {
  max-width: 880px;
  margin: 0 auto;
  padding: 40px 20px 24px;
}

.hero {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 30px;
  align-items: center;
  text-align: left;
  padding: 40px 30px;
  background: linear-gradient(135deg, var(--card) 0%, rgba(59, 130, 246, 0.05) 100%);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 15px 30px rgba(0,0,0,0.1), 0 0 0 1px rgba(255,255,255,0.05);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 20%, rgba(59, 130, 246, 0.1) 0%, transparent 50%),
              radial-gradient(circle at 70% 80%, rgba(139, 92, 246, 0.08) 0%, transparent 50%);
  pointer-events: none;
  z-index: 1;
}

.hero > * {
  position: relative;
  z-index: 2;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  box-shadow: 0 6px 24px rgba(59, 130, 246, 0.3), 0 0 0 3px rgba(59, 130, 246, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  animation: float 6s ease-in-out infinite;
}

.avatar:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 40px rgba(59, 130, 246, 0.4), 0 0 0 6px rgba(59, 130, 246, 0.15);
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

/* Decorative particles */
.particles {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 1;
}

.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.6;
  animation: particleFloat 8s ease-in-out infinite;
}

.particle-1 {
  top: 20%;
  left: 10%;
  animation-delay: 0s;
  animation-duration: 6s;
}

.particle-2 {
  top: 60%;
  right: 15%;
  animation-delay: 2s;
  animation-duration: 8s;
}

.particle-3 {
  top: 30%;
  right: 25%;
  animation-delay: 4s;
  animation-duration: 7s;
}

.particle-4 {
  bottom: 30%;
  left: 20%;
  animation-delay: 1s;
  animation-duration: 9s;
}

.particle-5 {
  top: 80%;
  left: 60%;
  animation-delay: 3s;
  animation-duration: 5s;
}

@keyframes particleFloat {
  0%, 100% { 
    transform: translateY(0px) translateX(0px) scale(1);
    opacity: 0.6;
  }
  25% { 
    transform: translateY(-20px) translateX(10px) scale(1.2);
    opacity: 0.8;
  }
  50% { 
    transform: translateY(-10px) translateX(-5px) scale(0.8);
    opacity: 0.4;
  }
  75% { 
    transform: translateY(-30px) translateX(15px) scale(1.1);
    opacity: 0.7;
  }
}

h1 {
  font-size: clamp(28px, 6vw, 44px);
  line-height: 1.1;
  margin: 0;
  font-weight: 700;
  background: linear-gradient(135deg, var(--fg) 0%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.role { 
  color: var(--accent); 
  margin: 0; 
  font-size: 18px;
  font-weight: 600;
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

.lead {
  max-width: none;
  margin: 0;
  color: var(--fg);
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
  animation: fadeInUp 0.8s ease-out 0.6s both;
}

.links { 
  display: flex; 
  gap: 12px; 
  margin-top: 0; 
  flex-wrap: wrap; 
  justify-content: flex-start;
  animation: fadeInUp 0.8s ease-out 0.8s both;
}

.btn {
  appearance: none;
  border: 1px solid transparent;
  background: linear-gradient(135deg, var(--accent) 0%, #2563eb 100%);
  color: var(--accent-contrast);
  padding: 12px 20px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: all 0.3s ease;
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.3);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left 0.5s ease;
}

.btn:hover::before {
  left: 100%;
}

.btn:hover { 
  transform: translateY(-3px) scale(1.02); 
  box-shadow: 0 12px 35px rgba(59, 130, 246, 0.4);
}
.btn:active { 
  transform: translateY(-1px) scale(0.98); 
}

.btn.outline {
  background: rgba(255, 255, 255, 0.05);
  color: var(--fg);
  border: 2px solid var(--border);
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  backdrop-filter: blur(10px);
}

.btn.outline:hover {
  background: rgba(59, 130, 246, 0.1);
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 8px 25px rgba(59, 130, 246, 0.2);
}

.details {
  margin-top: 20px;
}

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

.detail-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--card);
  transition: transform .15s ease, box-shadow .15s ease;
  font-size: 14px;
  line-height: 1.4;
}

.detail-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0,0,0,0.06);
  border-color: var(--accent);
}

.detail-icon {
  font-size: 18px;
  flex-shrink: 0;
  width: 24px;
  text-align: center;
}

.detail-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.detail-content strong {
  color: var(--accent);
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.detail-content span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.3;
}

/* Controls container for hero section */
.hero .controls {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  gap: 8px;
  z-index: 10;
}

.lang-toggle, .theme-toggle {
  background: var(--bg);
  color: var(--fg);
  border: 1px solid var(--border);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all .2s ease;
  font-size: 16px;
}

.lang-toggle:hover, .theme-toggle:hover { 
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  background: var(--accent);
  color: var(--accent-contrast);
}

.lang-toggle:active, .theme-toggle:active { 
  transform: translateY(0); 
}

/* Portfolio Section */
.portfolio {
  margin-top: 32px;
}

.portfolio h2 {
  font-size: clamp(20px, 4.5vw, 26px);
  margin: 0 0 20px;
  text-align: left;
  color: var(--fg);
  font-weight: 600;
  position: relative;
  display: inline-block;
}

.portfolio h2::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  border-radius: 1px;
}

.projects-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .projects-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  }
}

.project-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  transition: transform .2s ease, box-shadow .2s ease;
  position: relative;
  overflow: hidden;
}

.project-icon {
  width: 48px;
  height: 48px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transition: transform .3s ease;
}

.project-card:hover .project-icon {
  transform: scale(1.1) rotate(5deg);
}

.project-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}

.project-card h3 {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 600;
  color: var(--fg);
}

.project-description {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  margin: 0 0 12px;
}

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

.tech-tag {
  background: var(--bg);
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 3px 6px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 500;
}


/* Scroll progress bar */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--accent), #60a5fa);
  box-shadow: 0 1px 6px rgba(59,130,246,0.45);
  z-index: 1000;
  transition: width 0.15s ease-out;
}

/* Toast (copy feedback) */
.toast {
  position: fixed;
  left: 50%;
  bottom: 20px;
  transform: translateX(-50%) translateY(20px);
  background: var(--fg);
  color: var(--bg);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  z-index: 1000;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}



/* Scroll to top button */
.scroll-to-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 56px;
  height: 56px;
  background: var(--accent);
  color: var(--accent-contrast);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: bold;
  box-shadow: 0 4px 20px rgba(59, 130, 246, 0.3);
  transition: all 0.3s ease;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  z-index: 9999;
  /* Ensure button is clickable */
  pointer-events: auto;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  touch-action: manipulation;
  /* iOS Safari specific fixes */
  -webkit-transform: translateY(20px);
  -webkit-backface-visibility: hidden;
  -webkit-perspective: 1000;
}

.scroll-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  -webkit-transform: translateY(0);
}

.scroll-to-top:hover {
  background: #2563eb;
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 6px 25px rgba(59, 130, 246, 0.4);
}

.scroll-to-top:active {
  background: #1d4ed8;
  transform: translateY(-1px) scale(0.98);
  box-shadow: 0 3px 15px rgba(59, 130, 246, 0.5);
}

.scroll-icon {
  display: block;
  line-height: 1;
}

@media (max-width: 768px) {
  .container {
    padding-top: 10px !important;
  }
  
  .hero {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 30px 20px;
    margin: 0 10px;
    text-align: center;
  }
  
  .hero-content {
    align-items: center;
  }
  
  .links {
    justify-content: center;
  }
  
  .particle {
    display: none; /* Hide particles on mobile for better performance */
  }
  
  .hero .controls {
    top: 12px;
    right: 12px;
    gap: 6px;
  }
  
  .lang-toggle, .theme-toggle {
    width: 32px;
    height: 32px;
    font-size: 12px;
  }
  
  .avatar {
    width: 100px;
    height: 100px;
    justify-self: center;
  }
  
  .scroll-to-top {
    bottom: 16px;
    right: 16px;
    width: 52px;
    height: 52px;
    font-size: 20px;
    /* Better touch target for mobile */
    min-width: 44px;
    min-height: 44px;
  }
  
  .details-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  
  .detail-item {
    padding: 10px 14px;
    gap: 10px;
  }
  
  .detail-icon {
    font-size: 16px;
    width: 20px;
  }
  
  .detail-content strong {
    font-size: 12px;
  }
  
  .detail-content span {
    font-size: 12px;
  }
}

@media (min-width: 720px) {
  .hero { padding: 40px 30px; }
}

/* iOS Safari specific fixes */
@supports (-webkit-touch-callout: none) {
  .scroll-to-top {
    /* Force hardware acceleration on iOS */
    -webkit-transform: translate3d(0, 20px, 0);
    transform: translate3d(0, 20px, 0);
  }
  
  .scroll-to-top.show {
    -webkit-transform: translate3d(0, 0, 0);
    transform: translate3d(0, 0, 0);
  }
  
  .scroll-to-top:hover {
    -webkit-transform: translate3d(0, -2px, 0) scale(1.05);
    transform: translate3d(0, -2px, 0) scale(1.05);
  }
  
  .scroll-to-top:active {
    -webkit-transform: translate3d(0, -1px, 0) scale(0.98);
    transform: translate3d(0, -1px, 0) scale(0.98);
  }
}

/* Back link */
.back-link {
  margin-bottom: 20px;
}

/* Simulator controls section */
.simulator-controls {
  margin-bottom: 20px;
  padding: 16px 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
}

/* Controls group container */
.controls-group {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
}

/* Back button in simulator controls */
.simulator-controls .back-btn {
  font-size: 14px;
  padding: 8px 16px;
}

/* Controls for simulator page */
.simulator-controls .controls {
  display: flex;
  gap: 8px;
}

/* Interactive Section Styles */
.interactive-section {
  margin-top: 40px;
}

.interactive-section h2 {
  font-size: clamp(20px, 4.5vw, 26px);
  margin: 0 0 12px;
  text-align: left;
  color: var(--fg);
  font-weight: 600;
  position: relative;
  display: inline-block;
}

.interactive-section h2::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  border-radius: 1px;
}

.interactive-description {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 24px;
}

.interactive-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  padding: 30px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.interactive-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.1), 0 0 0 1px rgba(255,255,255,0.05);
}

.interactive-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--accent) 0%, #2563eb 100%);
  border-radius: 20px;
  box-shadow: 0 8px 24px rgba(59, 130, 246, 0.3);
}

.interactive-icon .icon {
  font-size: 32px;
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

.interactive-content h3 {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--fg);
}

.interactive-content p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 16px;
}

.interactive-features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.feature-tag {
  background: var(--bg);
  color: var(--accent);
  border: 1px solid var(--border);
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
}

/* PM Simulator Styles */
.pm-simulator {
  margin-top: 0;
  padding: 30px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

/* Simulator Header Styles */
.simulator-header {
  text-align: center;
  margin-bottom: 0;
  padding: 20px 20px 8px 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  position: relative;
}

.simulator-header h1 {
  font-size: clamp(20px, 4vw, 28px);
  font-weight: 600;
  margin: 0;
  color: var(--fg);
  position: relative;
  display: inline-block;
  text-align: center;
}

.simulator-header h1::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  border-radius: 1px;
}

.pm-simulator h2 {
  font-size: clamp(20px, 4.5vw, 26px);
  margin: 0 0 12px;
  text-align: left;
  color: var(--fg);
  font-weight: 600;
  position: relative;
  display: inline-block;
}

.pm-simulator h2::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  border-radius: 1px;
}

.simulator-description {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 24px;
}

.welcome-content .simulator-description {
  margin: -24px 0 24px;
  text-align: center !important;
  display: block;
}

.simulator-container {
  position: relative;
}

.simulator-welcome {
  text-align: center;
  padding: 40px 20px;
}

.welcome-content h3 {
  font-size: 24px;
  margin: 0 0 16px;
  color: var(--fg);
  font-weight: 600;
}

.welcome-content p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
  margin: 0 0 24px;
  max-width: 500px;
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

.simulator-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin: 24px 0;
  padding: 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--card);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.feature-icon {
  font-size: 20px;
  flex-shrink: 0;
}

.feature-item span:last-child {
  font-size: 14px;
  color: var(--fg);
  font-weight: 500;
}

.simulator-game {
  animation: fadeInUp 0.6s ease-out;
}

.scenario-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  padding: 16px 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.scenario-info {
  display: flex;
  gap: 16px;
  align-items: center;
}

.scenario-number {
  font-weight: 600;
  color: var(--accent);
  font-size: 14px;
}

.scenario-difficulty {
  font-size: 12px;
  color: var(--muted);
  padding: 4px 8px;
  background: var(--card);
  border-radius: 6px;
  border: 1px solid var(--border);
}

.progress-bar {
  width: 200px;
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), #60a5fa);
  border-radius: 3px;
  transition: width 0.3s ease;
  width: 20%;
}

.scenario-content {
  margin-bottom: 24px;
}

.scenario-title {
  font-size: 20px;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--fg);
}

.scenario-description {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 20px;
}

.scenario-context {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  padding: 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.context-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.context-label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
}

.context-value {
  font-size: 14px;
  color: var(--fg);
  font-weight: 600;
}

.decision-options {
  display: grid;
  gap: 12px;
  margin-bottom: 24px;
}

.decision-option {
  padding: 16px 20px;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: left;
  position: relative;
  overflow: hidden;
}

.decision-option::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.1), transparent);
  transition: left 0.5s ease;
}

.decision-option:hover::before {
  left: 100%;
}

.decision-option:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(59, 130, 246, 0.2);
}

.decision-option.selected {
  border-color: var(--accent);
  background: rgba(59, 130, 246, 0.05);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.decision-option h4 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--fg);
}

.decision-option p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.5;
}

.decision-feedback {
  animation: fadeInUp 0.6s ease-out;
}

.feedback-content {
  padding: 24px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  text-align: center;
}

.feedback-title {
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--fg);
}

.feedback-description {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 20px;
}

.feedback-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  background: var(--card);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.stat-label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 500;
}

.stat-value {
  font-size: 16px;
  font-weight: 600;
  color: var(--fg);
}

.simulator-results {
  animation: fadeInUp 0.6s ease-out;
}

.results-content {
  text-align: center;
  padding: 40px 20px;
}

.results-title {
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 24px;
  color: var(--fg);
}

.results-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.result-stat {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.result-label {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
}

.result-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--accent);
}

.results-feedback {
  margin-bottom: 24px;
}

.results-feedback p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
  margin: 0;
}

.results-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* Mobile styles for simulator */
@media (max-width: 768px) {
  .pm-simulator {
    margin: 20px 10px 0;
    padding: 20px 16px;
  }
  
  .simulator-controls {
    padding: 12px 16px;
    margin-bottom: 16px;
  }
  
  .controls-group {
    flex-direction: row;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .simulator-header {
    padding: 16px;
    margin-bottom: 16px;
  }
  
  .simulator-header h1 {
    font-size: clamp(18px, 4vw, 24px);
  }
  
  .simulator-controls .back-btn,
  .simulator-controls .restart-game-btn {
    font-size: 12px;
    padding: 6px 12px;
    flex: 1;
    min-width: 0;
  }
  
  .simulator-controls .controls {
    gap: 6px;
  }
  
  .scenario-header {
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
  }
  
  .scenario-info {
    justify-content: space-between;
  }
  
  .progress-bar {
    width: 100%;
  }
  
  .scenario-context {
    grid-template-columns: 1fr;
  }
  
  .feedback-stats {
    grid-template-columns: 1fr;
  }
  
  .results-stats {
    grid-template-columns: 1fr;
  }
  
  .results-actions {
    flex-direction: column;
  }
  
  .simulator-features {
    grid-template-columns: 1fr;
  }
  
  .welcome-content .simulator-description {
    margin: -32px 0 24px !important;
  }
  
  .results-content {
    padding: 20px 20px 40px 20px !important;
  }
  
  .results-title {
    margin: -24px 0 24px !important;
  }
  
  .interactive-card {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
  }
  
  .interactive-icon {
    justify-self: center;
  }
}

/* Simulator About Section */
.simulator-about {
  margin-top: 40px;
  padding: 30px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.simulator-about h2 {
  font-size: clamp(20px, 4.5vw, 26px);
  margin: 0 0 24px;
  text-align: left;
  color: var(--fg);
  font-weight: 600;
  position: relative;
  display: inline-block;
}

.simulator-about h2::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 40px;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  border-radius: 1px;
}

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

.about-text p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
  margin: 0 0 16px;
}

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

.about-author {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 24px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.author-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  margin-bottom: 16px;
  box-shadow: 0 4px 16px rgba(59, 130, 246, 0.2);
}

.author-info h3 {
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 8px;
  color: var(--fg);
}

.author-info p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  margin: 0 0 16px;
}

.author-link {
  color: var(--accent);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.3s ease;
}

.author-link:hover {
  color: #2563eb;
  text-decoration: underline;
}

@media (max-width: 768px) {
  .about-content {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  
  .about-author {
    padding: 20px;
  }
}

/* Reduce motion/accessibility: minimize animations/transitions for users who prefer less motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .hero, .details, .portfolio { animation: none !important; }
  .avatar { animation: none !important; }
  .particle { display: none !important; animation: none !important; }
  .simulator-game, .decision-feedback, .simulator-results { animation: none !important; }
}
