:root {
  /* Light Theme (default) */
  --primary: #2257aa;
  --primary-light: #3a6edb;
  --text: #1a2636;
  --text-light: #4a5568;
  --bg: #eaf2fb;
  --white: #ffffff;
  --card-bg: #ffffff;
  --gradient: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  --shadow: 0 8px 32px rgba(34, 87, 170, 0.10);
  --transition: all 0.3s ease;
  --border-color: rgba(34, 87, 170, 0.1);
}

[data-theme="dark"] {
  --primary: #4a90e2;
  --primary-light: #6ba7ff;
  --text: #e2e8f0;
  --text-light: #a0aec0;
  --bg: #1a202c;
  --white: #2d3748;
  --card-bg: #2d3748;
  --gradient: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  --border-color: rgba(255, 255, 255, 0.1);
}

/* Theme Toggle Button */
.theme-toggle {
  display: none;
}

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

body {
  font-family: 'Nunito', sans-serif;
  color: var(--text);
  line-height: 1.6;
  background: var(--bg);
  transition: var(--transition);
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(var(--card-bg), 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  padding: 1.2rem 0;
  box-shadow: var(--shadow);
  border-bottom: 2px solid var(--border-color);
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
}

.mobile-menu-btn span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--text);
  margin: 5px 0;
  transition: var(--transition);
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition);
}

.logo:hover {
  color: var(--primary-light);
}

.nav-links {
  display: flex;
  gap: 3rem;
  list-style: none;
  margin-right: 2rem;
  align-items: center;
}

.nav-links a {
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.1rem;
  transition: var(--transition);
  position: relative;
  padding: 0.5rem 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient);
  transition: width 0.3s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-links a:hover::after {
  width: 100%;
}

.resume-btn {
  background: var(--primary);
  color: var(--white) !important;
  padding: 0.5rem 1rem !important;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.resume-btn:hover {
  background: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

.resume-btn i {
  font-size: 1rem;
}

/* Main Content */
main {
  padding-top: 100px;
}

.section-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 4rem 2rem;
}

/* Hero Section */
.hero {
  min-height: calc(100vh - 80px);
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  scroll-margin-top: 100px;
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.hero-image {
  margin-bottom: 2rem;
}

.hero-image img {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: var(--shadow);
  border: 4px solid var(--primary);
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

/* Role Animation */
.role-container {
  height: 12rem;
  margin: 1rem auto 2rem;
  position: relative;
  width: 100%;
  max-width: 1200px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.network-nodes {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  z-index: 2;
  padding: 2rem;
}

.node {
  position: relative;
  cursor: pointer;
  transition: all 0.3s ease;
  animation: nodeFloat 3s ease-in-out infinite;
}

.node:nth-child(1) { animation-delay: 0s; }
.node:nth-child(2) { animation-delay: 0.6s; }
.node:nth-child(3) { animation-delay: 1.2s; }
.node:nth-child(4) { animation-delay: 1.8s; }
.node:nth-child(5) { animation-delay: 2.4s; }

.node:hover {
  transform: scale(1.1);
  z-index: 10;
}

.node-content {
  /* background: var(--card-bg); */
  /* border: 2px solid var(--primary); */
  border-radius: 12px;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  min-width: unset;
  box-shadow: none;
  transition: all 0.3s ease;
  position: relative;
  overflow: visible;
}

.node-content::before {
  display: none;
}

.node-content i {
  font-size: 2rem;
  color: var(--primary);
  transition: all 0.3s ease;
}

.node-content span {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  text-align: center;
  line-height: 1.2;
  transition: color 0.3s ease;
  background: none;
  border: none;
  box-shadow: none;
  padding: 0;
}

.node:hover .node-content::before {
  left: 100%;
}

.node:hover .node-content i {
  transform: scale(1.2);
  color: var(--primary-light);
}

.node:hover .node-content span {
  color: var(--primary);
}

.network-connections {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.connections-svg {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
}

.connection-line {
  stroke: url(#connectionGradient);
  stroke-width: 2;
  fill: none;
  filter: url(#glow);
  opacity: 0.6;
  animation: pulseConnection 2s ease-in-out infinite;
}

.connection-line:nth-child(1) { animation-delay: 0s; }
.connection-line:nth-child(2) { animation-delay: 0.4s; }
.connection-line:nth-child(3) { animation-delay: 0.8s; }
.connection-line:nth-child(4) { animation-delay: 1.2s; }
.connection-line:nth-child(5) { animation-delay: 1.6s; }

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

@keyframes pulseConnection {
  0%, 100% {
    opacity: 0.3;
    stroke-width: 1;
  }
  50% {
    opacity: 0.8;
    stroke-width: 3;
  }
}

.hero h2 {
  font-size: 2rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
}

.hero p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  color: var(--text-light);
}

.hero-buttons {
  display: none;
}

/* About Section */
.about {
  background: var(--white);
}

.about h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 2rem;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: 3rem;
}

.about-card {
  background: var(--bg);
  padding: 2rem;
  border-radius: 12px;
  text-align: center;
  transition: var(--transition);
}

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

.about-card h3 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

/* Experience Section */
.experience h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 3rem;
}

.timeline {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 0;
}

.timeline::after {
  content: '';
  position: absolute;
  width: 2px;
  background-color: var(--border-color);
  top: 0;
  bottom: 0;
  left: 50%;
  margin-left: -1px;
}

.timeline-item {
  padding: 10px 40px;
  position: relative;
  width: 50%;
  box-sizing: border-box;
}

.timeline-item:nth-child(odd) {
  left: 0;
}

.timeline-item:nth-child(even) {
  left: 50%;
}

.timeline-dot {
  position: absolute;
  width: 16px;
  height: 16px;
  right: -8px;
  background-color: var(--primary);
  border: 4px solid var(--card-bg);
  border-radius: 50%;
  top: 15px;
  z-index: 1;
}

.timeline-item:nth-child(even) .timeline-dot {
  left: -8px;
}

.timeline-content {
  padding: 20px;
  background-color: var(--card-bg);
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.timeline-date {
  color: var(--primary);
  font-weight: 600;
  margin-bottom: 10px;
}

.timeline-content h3 {
  margin: 0 0 10px 0;
  color: var(--text);
}

.timeline-content .company {
  color: var(--text-light);
  margin-bottom: 15px;
}

.timeline-content ul {
  margin: 0;
  padding-left: 20px;
}

.timeline-content li {
  margin-bottom: 8px;
  color: var(--text);
  position: relative;
}

.timeline-content li::before {
  content: "•";
  color: var(--primary);
  font-weight: bold;
  position: absolute;
  left: -15px;
}

/* Skills Section */
.skills {
  background: var(--white);
}

.skills h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 3rem;
}

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

.skill-category {
  background: var(--bg);
  padding: 2rem;
  border-radius: 12px;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.skill-category:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.skill-category h3 {
  color: var(--primary);
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.skill-category ul {
  list-style: none;
  margin-bottom: 1.5rem;
}

.skill-category li {
  margin-bottom: 0.5rem;
  color: var(--text-light);
}

.skill-icons {
  display: flex;
  justify-content: space-around;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.skill-icons i {
  font-size: 1.8rem;
  color: var(--primary);
  transition: var(--transition);
}

.skill-icons i:hover {
  transform: scale(1.2);
  color: var(--primary-light);
}

/* Contact Section */
.contact h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 3rem;
}

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

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem;
  background: var(--card-bg);
  border-radius: 12px;
  transition: var(--transition);
}

.contact-item:hover {
  transform: translateX(10px);
  box-shadow: var(--shadow);
}

.contact-item svg {
  color: var(--primary);
}

.contact-item h3 {
  color: var(--primary);
  margin-bottom: 0.25rem;
}

.contact-item p {
  color: var(--text-light);
}

/* Social Links */
.social-links {
  display: flex;
  gap: 1.5rem;
  margin-top: 2rem;
}

.social-icon {
  color: var(--text-light);
  text-decoration: none;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg);
  padding: 0.5rem;
}

.social-icon:hover {
  color: var(--primary);
  transform: translateY(-2px);
  background: var(--white);
  box-shadow: var(--shadow);
}

.social-icon i {
  font-size: 1.5rem;
  line-height: 1;
}

/* Footer */
footer {
  background: var(--card-bg);
  padding: 2rem 0;
  margin-top: 4rem;
  border-top: 1px solid var(--border-color);
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.contact-line {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 3rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-light);
  transition: var(--transition);
}

.contact-item i {
  font-size: 1.25rem;
  color: var(--primary);
}

.contact-item span {
  font-size: 0.9rem;
}

.contact-item:hover {
  color: var(--primary);
  transform: translateY(-2px);
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 1rem 0;
}

.social-icon {
  color: var(--text-light);
  text-decoration: none;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg);
  padding: 0.5rem;
}

.social-icon:hover {
  color: var(--primary);
  transform: translateY(-2px);
  background: var(--white);
  box-shadow: var(--shadow);
}

.social-icon i {
  font-size: 1.5rem;
  line-height: 1;
}

.copyright {
  text-align: center;
  color: var(--text-light);
  font-size: 0.9rem;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.hero, .about, .experience, .skills, .contact {
  animation: fadeIn 1s ease-out;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .hero {
    flex-direction: column;
    text-align: center;
    padding-top: 2rem;
  }

  .hero-content {
    padding-right: 0;
    margin-bottom: 3rem;
  }

  .social-links {
    justify-content: center;
  }

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

@media (max-width: 768px) {
  .mobile-menu-btn {
    display: block;
  }

  .mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

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

  .mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }

  .nav-content {
    justify-content: space-between;
    padding: 0 1rem;
  }

  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 300px;
    height: 100vh;
    background: var(--card-bg);
    flex-direction: column;
    justify-content: center;
    gap: 2rem;
    margin: 0;
    padding: 2rem;
    transition: right 0.3s ease;
    box-shadow: var(--shadow);
  }

  .nav-links.active {
    right: 0;
  }

  .nav-links li {
    width: 100%;
    text-align: center;
  }

  .nav-links a {
    font-size: 1.1rem;
    display: block;
    padding: 0.5rem;
  }

  .resume-btn {
    width: 100%;
    justify-content: center;
    padding: 0.8rem !important;
  }

  .section-content {
    padding: 3rem 1.5rem;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .skills-grid {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .hero h2 {
    font-size: 1.5rem;
  }

  .hero-image img {
    max-width: 300px;
  }

  .role-container {
    height: 16rem;
  }

  .network-nodes {
    gap: 1rem;
    padding: 1rem;
  }

  .node-content {
    min-width: 120px;
    padding: 0.8rem 1rem;
  }

  .node-content i {
    font-size: 1.5rem;
  }

  .node-content span {
    font-size: 0.8rem;
  }

  .timeline::after {
    left: 31px;
  }
  
  .timeline-item {
    width: 100%;
    padding-left: 70px;
    padding-right: 25px;
  }
  
  .timeline-item:nth-child(even) {
    left: 0;
  }
  
  .timeline-dot {
    left: 23px;
  }
  
  .timeline-item:nth-child(even) .timeline-dot {
    left: 23px;
  }

  footer {
    padding: 1.5rem 0;
  }

  .contact-line {
    gap: 2rem;
  }

  .contact-item i {
    font-size: 1.1rem;
  }

  .contact-item span {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .nav-links {
    width: 100%;
    max-width: none;
  }

  .role-container {
    height: 20rem;
  }

  .network-nodes {
    gap: 0.8rem;
    padding: 0.5rem;
  }

  .node-content {
    min-width: 100px;
    padding: 0.6rem 0.8rem;
  }

  .node-content i {
    font-size: 1.2rem;
  }

  .node-content span {
    font-size: 0.7rem;
  }

  footer {
    padding: 1rem 0;
  }

  .contact-line {
    gap: 0.75rem;
    flex-direction: column;
    align-items: center;
    background: var(--bg);
    padding: 1rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
  }

  .contact-item {
    width: 100%;
    padding: 0.5rem;
    border-radius: 8px;
    background: var(--card-bg);
    transition: all 0.3s ease;
  }

  .contact-item:hover {
    transform: translateX(5px);
    background: var(--white);
  }

  .contact-item i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
  }

  .contact-item span {
    font-size: 0.85rem;
    font-weight: 500;
  }

  .social-links {
    gap: 1rem;
    margin-top: 1rem;
  }

  .social-icon {
    width: 35px;
    height: 35px;
  }

  .social-icon i {
    font-size: 1.25rem;
  }

  .copyright {
    font-size: 0.8rem;
    margin-top: 0.5rem;
  }

  .resume-btn {
    padding: 0.3rem 0.5rem !important;
    font-size: 0.8rem;
  }
}

/* Tools Section */
.tools {
  background: var(--white);
}

.tools h2 {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 3rem;
  text-align: center;
}

.tools-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
}

.tool-item {
  background-color: var(--bg);
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  gap: 0.5rem;
  min-height: 100px;
  width: 100%;
}

.tool-item img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.tool-item i {
  font-size: 40px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tool-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.tool-name {
  font-size: 12px;
  color: var(--text-light);
  text-align: center;
  margin-top: 0.5rem;
  word-wrap: break-word;
  width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* Responsive adjustments for tools section */
@media (max-width: 768px) {
  .tools-grid {
    grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
    gap: 1rem;
    padding: 1rem;
  }

  .tool-item {
    min-height: 90px;
    padding: 0.75rem;
  }

  .tool-item img {
    width: 35px;
    height: 35px;
  }

  .tool-item i {
    font-size: 35px;
    width: 35px;
    height: 35px;
  }

  .tool-name {
    font-size: 10px;
    margin-top: 0.25rem;
  }
}

@media (max-width: 480px) {
  .tools-grid {
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 0.75rem;
    padding: 0.75rem;
  }

  .tool-item {
    min-height: 80px;
    padding: 0.5rem;
  }

  .tool-item img {
    width: 30px;
    height: 30px;
  }

  .tool-item i {
    font-size: 30px;
    width: 30px;
    height: 30px;
  }

  .tool-name {
    font-size: 9px;
    margin-top: 0.25rem;
  }
}

/* Floating Menu */
.floating-menu {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 1000;
  display: none;
}

.menu-toggle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--primary);
  border: none;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 1001;
}

.menu-toggle:hover {
  transform: scale(1.1);
  background: var(--primary-light);
}

.menu-toggle.active {
  transform: rotate(45deg);
  background: var(--primary-light);
}

.fan-menu {
  position: absolute;
  bottom: 70px;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1rem;
  opacity: 0;
  visibility: hidden;
  transform-origin: bottom right;
  transition: all 0.3s ease;
  padding: 1rem;
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.fan-menu.active {
  opacity: 1;
  visibility: visible;
}

.fan-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bg);
  padding: 0.75rem 1.25rem;
  border-radius: 25px;
  color: var(--text);
  text-decoration: none;
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.3s ease;
  box-shadow: var(--shadow);
  white-space: nowrap;
}

.fan-menu.active .fan-item {
  transform: translateX(0);
  opacity: 1;
}

.fan-menu.active .fan-item:nth-child(1) { transition-delay: 0.1s; }
.fan-menu.active .fan-item:nth-child(2) { transition-delay: 0.2s; }
.fan-menu.active .fan-item:nth-child(3) { transition-delay: 0.3s; }
.fan-menu.active .fan-item:nth-child(4) { transition-delay: 0.4s; }
.fan-menu.active .fan-item:nth-child(5) { transition-delay: 0.5s; }
.fan-menu.active .fan-item:nth-child(6) { transition-delay: 0.6s; }
.fan-menu.active .fan-item:nth-child(7) { transition-delay: 0.7s; }

.fan-item i {
  font-size: 1.25rem;
  color: var(--primary);
  width: 24px;
  text-align: center;
}

.fan-item span {
  font-size: 0.9rem;
  font-weight: 500;
}

.fan-item:hover {
  background: var(--primary);
  color: white;
  transform: translateX(-5px);
}

.fan-item:hover i {
  color: white;
}

.fan-item.resume {
  background: var(--primary);
  color: white;
}

.fan-item.resume i {
  color: white;
}

.fan-item.resume:hover {
  background: var(--primary-light);
}

@media (max-width: 768px) {
  .navbar {
    display: none;
  }

  .floating-menu {
    display: block;
  }
}

@media (max-width: 480px) {
  .floating-menu {
    bottom: 1.5rem;
    right: 1.5rem;
  }

  .menu-toggle {
    width: 50px;
    height: 50px;
    font-size: 1.25rem;
  }

  .fan-menu {
    bottom: 60px;
    padding: 0.75rem;
  }

  .fan-item {
    padding: 0.5rem 1rem;
  }

  .fan-item i {
    font-size: 1.1rem;
    width: 20px;
  }

  .fan-item span {
    font-size: 0.85rem;
  }
}

.packet-anim {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: 3;
}

.packet {
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--primary-light);
  box-shadow: 0 0 12px 2px var(--primary-light);
  opacity: 0.85;
  animation-timing-function: linear;
}

.packet-1 {
  animation: packet-move-1 2.5s infinite;
}
.packet-2 {
  animation: packet-move-2 3.2s infinite;
}
.packet-3 {
  animation: packet-move-3 2.8s infinite;
}

@keyframes packet-move-1 {
  0%   { left: 12%; top: 60%; opacity: 0; }
  10%  { opacity: 1; }
  40%  { left: 38%; top: 30%; }
  70%  { left: 65%; top: 30%; }
  100% { left: 85%; top: 60%; opacity: 0; }
}
@keyframes packet-move-2 {
  0%   { left: 85%; top: 60%; opacity: 0; }
  10%  { opacity: 1; }
  40%  { left: 65%; top: 30%; }
  70%  { left: 38%; top: 30%; }
  100% { left: 12%; top: 60%; opacity: 0; }
}
@keyframes packet-move-3 {
  0%   { left: 50%; top: 10%; opacity: 0; }
  10%  { opacity: 1; }
  50%  { left: 38%; top: 30%; }
  80%  { left: 65%; top: 30%; }
  100% { left: 50%; top: 80%; opacity: 0; }
}

.binary-anim {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none;
  z-index: 3;
}

.binary-packet {
  position: absolute;
  font-size: 1.5rem;
  font-family: 'Fira Mono', 'Consolas', monospace;
  color: var(--primary-light);
  opacity: 0.85;
  font-weight: bold;
  text-shadow: 0 0 8px var(--primary-light), 0 0 2px #fff;
  animation-timing-function: linear;
}

.binary-1 {
  animation: binary-move-1 2.5s infinite;
}
.binary-2 {
  animation: binary-move-2 3.1s infinite;
}
.binary-3 {
  animation: binary-move-3 2.7s infinite;
}
.binary-4 {
  animation: binary-move-4 3.3s infinite;
}
.binary-5 {
  animation: binary-move-5 2.9s infinite;
}

@keyframes binary-move-1 {
  0%   { left: 10%; top: 70%; opacity: 0; }
  10%  { opacity: 1; }
  40%  { left: 35%; top: 35%; }
  70%  { left: 60%; top: 35%; }
  100% { left: 85%; top: 70%; opacity: 0; }
}
@keyframes binary-move-2 {
  0%   { left: 85%; top: 70%; opacity: 0; }
  10%  { opacity: 1; }
  40%  { left: 60%; top: 35%; }
  70%  { left: 35%; top: 35%; }
  100% { left: 10%; top: 70%; opacity: 0; }
}
@keyframes binary-move-3 {
  0%   { left: 50%; top: 10%; opacity: 0; }
  10%  { opacity: 1; }
  50%  { left: 35%; top: 35%; }
  80%  { left: 60%; top: 35%; }
  100% { left: 50%; top: 80%; opacity: 0; }
}
@keyframes binary-move-4 {
  0%   { left: 35%; top: 35%; opacity: 0; }
  10%  { opacity: 1; }
  50%  { left: 60%; top: 35%; }
  80%  { left: 85%; top: 70%; }
  100% { left: 10%; top: 70%; opacity: 0; }
}
@keyframes binary-move-5 {
  0%   { left: 60%; top: 35%; opacity: 0; }
  10%  { opacity: 1; }
  50%  { left: 35%; top: 35%; }
  80%  { left: 10%; top: 70%; }
  100% { left: 85%; top: 70%; opacity: 0; }
}

.terminal-container {
  background: linear-gradient(135deg, #181c2f 0%, #23243a 60%, #1a1830 100%);
  border-radius: 16px;
  box-shadow: 0 8px 32px #0008;
  max-width: 700px;
  margin: 2rem auto;
  overflow: hidden;
  border: 1.5px solid #23243a;
}
.terminal-header {
  display: flex;
  align-items: center;
  height: 44px;
  background: linear-gradient(90deg, #23243a 80%, #181c2f 100%);
  border-bottom: 1.5px solid #3a3a4d;
  position: relative;
  padding: 0 1.2rem;
}
.traffic-lights {
  display: flex;
  align-items: center;
  gap: 0.5em;
  margin-right: 1.2em;
}
.traffic-light { width: 13px; height: 13px; border-radius: 50%; margin-right: 0.3em; margin-top: 2px; box-shadow: 0 0 2px #0008; }
.traffic-light.red { background: #ff5f56; border: 1px solid #e0443e; }
.traffic-light.yellow { background: #ffbd2e; border: 1px solid #dea123; }
.traffic-light.green { background: #27c93f; border: 1px solid #13a10e; }
.terminal-title { color: #bfc7d5; font-size: 1.05rem; font-family: 'Fira Mono', 'Consolas', monospace; opacity: 0.7; margin-left: auto; }
.terminal-screen {
  position: relative;
  width: 100%;
  min-height: 320px;
  background: transparent;
  overflow: hidden;
}
.terminal-codeblock {
  margin: 1;
  width: 100%;
  text-align: left;
  padding: 2.8rem 1.5rem 0.7rem 2.8rem;
  line-height: 1;
}
.line { display: block; position: relative; }
.linenumber {
  color: #444a6d;
  user-select: none;
  width: 2.2em;
  text-align: right;
  font-size: 0.98em;
  opacity: 0.7;
  display: inline-block;
  margin-right: 1em;
}
.token.keyword { color: #d946ef; font-weight: 700; }
.token.variable { color: #60a5fa; }
.token.operator, .token.brace { color: #a3e635; font-weight: 700; }
.token.property { color: #f472b6; }
.token.string { color: #38bdf8; }
.terminal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #444a6d;
  font-size: 0.95em;
  padding: 0.7em 1.5em 0.7em 2.8em;
  border-top: 1px solid #23243a;
  background: transparent;
  font-family: 'Fira Mono', 'Consolas', monospace;
  opacity: 0.8;
}

@media (max-width: 600px) {
  .terminal-container {
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    margin-left: 0;
    margin-right: 0;
  }
  .terminal-screen {
    overflow-x: auto;
  }
  .terminal-codeblock {
    padding-left: 0.7rem;
    padding-right: 0.5rem;
  }
}

@media (min-width: 900px) {
  .hero-content {
    flex-direction: row;
    align-items: stretch;
    justify-content: center;
    gap: 3.5rem;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
  }
  .hero-left {
    flex: 0 0 340px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-width: 260px;
    max-width: 360px;
    background: linear-gradient(135deg, #181c2f 0%, #23243a 60%, #1a1830 100%);
    border-radius: 16px;
    box-shadow: 0 8px 32px #0008;
    padding: 1.2rem 1.5rem 1.2rem 1.5rem;
    height: auto;
  }
  .hero-right {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
  }
  .hero-image {
    margin-bottom: 1.2rem;
  }
  .hero-left h1 {
    margin-top: 0;
    font-size: 2.5rem;
    text-align: center;
    line-height: 1.1;
  }
  .hero-special {
    margin-top: 1.2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
  }
  .hero-specialization {
    color: #7ec3ff;
    font-size: 1.15rem;
    text-align: center;
    margin: 0 0 1.1rem 0;
    font-weight: 500;
    line-height: 1.3;
    letter-spacing: 0.01em;
    max-width: 320px;
  }
  .hero-social-links {
    display: flex;
    flex-direction: row;
    gap: 1.2rem;
    justify-content: center;
    align-items: center;
    margin-top: 1.2rem;
  }
  .hero-social-links .social-icon {
    font-size: 1.6rem;
    color: #7ec3ff;
    background: none;
    box-shadow: none;
    padding: 0.2em;
    border-radius: 50%;
    transition: color 0.2s, background 0.2s;
  }
  .hero-social-links .social-icon:hover {
    color: #fff;
    background: #3a6edb;
  }
  .terminal-container {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    box-shadow: 0 8px 32px #0008;
    flex: 1 1 0;
  }
  .terminal-screen {
    flex: 1 1 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }
  .terminal-footer {
    margin-top: auto;
  }
}

@media (max-width: 600px) {
  .hero-social-links {
    display: flex;
    flex-direction: row;
    gap: 1.2rem;
    justify-content: center;
    align-items: center;
    margin-top: 1.2rem;
  }
  .hero-left {
    border: none !important;
    background: transparent !important;
  }
}

.code-cursor-selected {
  background: #3a6edb;
  color: #fff !important;
  border-radius: 4px;
  padding: 0 2px;
}
.blinking-cursor {
  display: inline-block;
  width: 1ch;
  color: #fff;
  background: #3a6edb;
  border-radius: 2px;
  margin-left: 1px;
  animation: blink-cursor 1s steps(1) infinite;
}
@keyframes blink-cursor {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

[data-theme="light"] .terminal-container {
  background: linear-gradient(135deg, #f7fafc 0%, #e3e9f3 60%, #f1f5fa 100%);
  border: 1.5px solid #a4b9da;
  box-shadow: 0 8px 32px #b0c4de33;
}
[data-theme="light"] .hero-left {
  background: linear-gradient(135deg, #f7fafc 0%, #e3e9f3 60%, #f1f5fa 100%);
  border: 1.5px solid #a4b9da;
  box-shadow: 0 8px 32px #b0c4de33;
}
[data-theme="light"] .terminal-header {
  background: linear-gradient(90deg, #e3e9f3 100%, #9dbae9 100%);
  border-bottom: 1.5px solid #a4b9da;
}
[data-theme="light"] .terminal-title {
  color: #4b5563;
  opacity: 0.8;
}
[data-theme="light"] .terminal-footer {
  color: #6b7280;
  border-top: 1px solid #e3e9f3;
  background: transparent;
  opacity: 0.8;
}

[data-theme="light"] .terminal-codeblock,
[data-theme="light"] .terminal-codeblock .token {
  color: #222b3a;
}
[data-theme="light"] .terminal-codeblock .token.keyword { color: #b400b4; }
[data-theme="light"] .terminal-codeblock .token.variable { color: #0074d9; }
[data-theme="light"] .terminal-codeblock .token.operator,
[data-theme="light"] .terminal-codeblock .token.brace { color: #049786; }
[data-theme="light"] .terminal-codeblock .token.property { color: #d72660; }
[data-theme="light"] .terminal-codeblock .token.string { color: #3904e6; }
[data-theme="light"] .terminal-codeblock .token.array { color: #0074d9; }
[data-theme="light"] .terminal-codeblock .linenumber { color: #b0b6c3; }
[data-theme="light"] .code-cursor-selected {
  background: #0074d9;
  color: #fff !important;
}
[data-theme="light"] .blinking-cursor {
  background: #0074d9;
  color: #fff;
}

@media (max-width: 600px) {
  [data-theme="light"] .hero-left {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0 !important;
  }
} 