:root {
  --primary: #fff;
  --accent: #48dbfb;
  --accent-dark: #0652DD;
  --accent-light: #56CCF2;
  --bg: #141e30;
  --bg-card: rgba(20, 34, 49, 0.85);
  --glass: rgba(36, 55, 99, 0.43);
  --glass-border: rgba(255,255,255,0.13);
  --gray: #232946;
  --gray-light: #2d334a;
  --shadow: 0 8px 32px 0 rgba(32,102,255,0.13);
  --transition: all 0.4s cubic-bezier(0.4,0,0.2,1);
  --radius: 18px;
}

html, body {
  min-height: 100%;
  background: linear-gradient(135deg, #141e30 0%, #243B55 100%);
  color: var(--primary);
  font-family: 'Segoe UI', Arial, sans-serif;
  transition: var(--transition);
  scroll-behavior: smooth;
}

#loading {
  position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999;
}
.spinner {
  border: 8px solid #252a41;
  border-top: 8px solid var(--accent);
  border-radius: 50%;
  width: 64px; height: 64px;
  animation: spin 1.1s linear infinite;
}
@keyframes spin { 0% { transform: rotate(0deg);} 100% { transform: rotate(360deg);} }

nav.glass-nav {
  background: var(--glass);
  color: var(--primary);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(6, 82, 221, 0.09);
  backdrop-filter: blur(12px);
  border-bottom: 1.5px solid var(--glass-border);
  transition: var(--transition);
}
nav .container {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 1200px; margin: 0 auto;
}
nav .brand {
  display: flex; align-items: center; gap: 14px;
  font-size: 1.23rem; font-weight: bold; color: var(--accent);
}
.logo {
  width: 40px; height: 40px; border-radius: 50%; object-fit: cover;
  border: 2px solid var(--accent);
  box-shadow: 0 2px 8px var(--glass-border);
}
nav .nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin: 0; padding: 0;
}
nav .nav-links a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  letter-spacing: 0.5px;
  padding: 0.45rem 1rem;
  border-radius: 6px;
  background: transparent;
  transition: var(--transition);
  display: flex; align-items: center; gap: 6px;
}
nav .nav-links a.active,
nav .nav-links a:hover {
  color: var(--accent-light);
  background: var(--gray-light);
}

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: transparent;
  position: relative;
  padding: 0;
}
.home-wide {
  width: 94vw; max-width: 1300px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5rem;
  box-sizing: border-box;
  padding: 0.5rem 2vw;
}
.home-text {
  flex: 1 1 0;
  min-width: 300px; max-width: 700px;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.home-text h1 {
  font-size: 2.8rem;
  margin-bottom: 1.3rem;
  color: var(--accent);
  font-weight: 700;
  letter-spacing: 2px;
  min-height: 64px;
}
.home-text .subheading {
  font-size: 1.19rem;
  color: #c6e2ff;
  margin-bottom: 2.1rem;
  font-weight: 500;
  text-shadow: 0 1px 4px #23294630;
}
.home-text .btn {
  margin-bottom: 1.5rem;
}
.home-socials {
  display: flex; gap: 2rem; margin-top: 8px;
}
.home-socials a {
  color: var(--accent); font-size: 2.1rem; transition: 0.2s;
}
.home-socials a:hover { color: var(--accent-light); transform: scale(1.1) rotate(-8deg);}
.profile-circle {
  width: 230px; height: 230px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  position: relative;
  background: var(--glass);
  border: 2.7px solid var(--accent);
  box-shadow: var(--shadow);
  overflow: visible;
}
.profile-inner-circle {
  width: 160px; height: 160px;
  background: var(--bg-card);
  border-radius: 50%;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(6, 82, 221, 0.10);
  z-index: 2;
}
.profile-inner-circle img {
  width: 100%; height: 100%;
  object-fit: cover;
  border-radius: 50%;
  box-shadow: 0 2px 12px #0652DD22;
}
.circle-bg {
  position: absolute; width: 100%; height: 100%;
  border-radius: 50%;
  z-index: 1;
  pointer-events: none;
  animation: glowSpin 8s linear infinite;
  background: radial-gradient(circle at 70% 30%, #56CCF250 0%, transparent 70%);
}
@keyframes glowSpin { to {transform: rotate(360deg);} }
.scroll-down {
  position: absolute;
  left: 50%; bottom: 30px; transform: translateX(-50%);
  font-size: 2.2rem; color: var(--accent-light);
  opacity: 0.7; animation: bounce 1.6s infinite;
}
@keyframes bounce {
  0%, 100% { transform: translate(-50%,0);}
  50% { transform: translate(-50%,18px);}
}

.glass-section {
  background: var(--glass);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin: 2.5rem 1vw;
  padding: 3.5rem 0 2.5rem 0;
  backdrop-filter: blur(16px);
  border: 1.5px solid var(--glass-border);
}
.about h2, .services h2, .projects h2, .contact h2 {
  text-align: center;
  margin-bottom: 2.3rem;
  color: var(--accent-light);
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: 1px;
}
.highlight {
  color: var(--accent);
  font-style: italic;
  letter-spacing: 1px;
}

.about-content {
  max-width: 870px;
  margin: 0 auto;
  padding: 2.8rem 2.2rem 2.3rem 2.2rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: var(--transition);
}
.tabs ul {
  display: flex;
  justify-content: center;
  gap: 2.1rem;
  padding: 0;
  margin: 0 0 2rem 0;
  list-style: none;
}
.tabs ul li a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  padding: 0.55rem 1.4rem;
  border-radius: 10px;
  background: transparent;
  transition: var(--transition);
  position: relative;
  display: flex; align-items: center; gap: 7px;
}
.tabs ul li a.active, .tabs ul li a:focus, .tabs ul li a:hover {
  color: var(--accent);
  background: var(--gray-light);
}
.tab-content { text-align: left; }
.tab-pane { display: none; }
.tab-pane.active { display: block; animation: fadeInUp 0.8s;}
@keyframes fadeInUp { 0% {opacity: 0; transform: translateY(40px);} 100% {opacity: 1; transform: translateY(0);} }

.skills-badges {
  display: flex; flex-wrap: wrap; gap: 1.1rem;
  justify-content: center; margin-top: 2.1rem; list-style: none; padding: 0;
}
.skills-badges li {
  background: linear-gradient(90deg, var(--accent), var(--accent-dark));
  color: var(--bg);
  padding: 0.7rem 1.6rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.09rem;
  letter-spacing: 0.7px;
  box-shadow: 0 2px 8px rgba(6, 82, 221, 0.08);
  display: flex; align-items: center; gap: 8px;
  opacity: 0; transform: translateY(30px);
  animation: badgeFadeIn 0.65s forwards;
}
.skills-badges li:nth-child(1) { animation-delay: 0.1s;}
.skills-badges li:nth-child(2) { animation-delay: 0.2s;}
.skills-badges li:nth-child(3) { animation-delay: 0.3s;}
.skills-badges li:nth-child(4) { animation-delay: 0.4s;}
.skills-badges li:nth-child(5) { animation-delay: 0.5s;}
.skills-badges li:nth-child(6) { animation-delay: 0.6s;}
.skills-badges li:nth-child(7) { animation-delay: 0.7s;}
.skills-badges li:nth-child(8) { animation-delay: 0.8s;}
.skills-badges li:nth-child(9) { animation-delay: 0.9s;}
@keyframes badgeFadeIn { to { opacity: 1; transform: translateY(0);}}

.timeline {
  position: relative;
  margin-left: 32px;
  padding-left: 22px;
  border-left: 3px solid var(--accent-light);
  margin-top: 1.7rem;
}
.timeline-item {
  position: relative;
  margin-bottom: 2.8rem;
  opacity: 0; transform: translateY(38px);
  animation: fadeInUp 1s forwards;
}
.timeline-item:nth-child(1) { animation-delay: 0.2s; }
.timeline-item:nth-child(2) { animation-delay: 0.4s; }
.timeline-item:nth-child(3) { animation-delay: 0.6s; }
.timeline-dot {
  position: absolute;
  left: -33px; top: 11px;
  width: 20px; height: 20px;
  background: var(--accent);
  border: 5px solid var(--bg-card);
  border-radius: 50%;
  box-shadow: 0 0 0 2px var(--gray);
  z-index: 2;
}
.timeline-content {
  background: var(--glass);
  border-radius: 12px;
  padding: 1.07rem 1.5rem;
  box-shadow: 0 2px 8px rgba(6, 82, 221, 0.07);
  color: var(--primary);
}
.timeline-content h3 { margin: 0 0 0.2rem 0; color: var(--accent); font-size: 1.18rem; font-weight: 700;}
.timeline-content span { font-size: 1.02rem; color: var(--accent-light); font-weight: 600;}
.timeline-content p, .timeline-content ul { margin: 0.5rem 0 0 0; color: var(--primary);}
.timeline-content ul { padding-left: 1.1rem;}

.glass-card {
  background: var(--glass);
  border-radius: 15px;
  border: 1.2px solid var(--glass-border);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  transition: 0.35s;
}
.glass-card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 14px 32px rgba(86,204,242,0.17);
}

.services { padding: 3.5rem 0 2.3rem 0;}
.service-cards {
  display: flex; justify-content: space-around; gap: 2rem; flex-wrap: wrap;
}
.card {
  min-width: 250px; max-width: 340px;
  text-align: center; color: var(--primary);
  margin-bottom: 1.7rem; position: relative; overflow: hidden;
  padding: 2.1rem 1.3rem;
}
.card:before {
  content: '';
  position: absolute;
  left: 0; top: 0; width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--accent) 0%, transparent 100%);
  opacity: 0.07; z-index: 0; pointer-events: none;
}
.card i { font-size: 2.4rem; margin-bottom: 1rem; color: var(--accent-light); z-index: 2; position: relative;}
.card h3 { font-size: 1.29rem; margin-bottom: 0.5rem; font-weight: 700;}
.card p { font-size: 1.09rem;}

.projects { padding: 3.5rem 0 2.2rem 0;}
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(310px, 1fr));
  gap: 2.1rem;
}
.project-card {
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  box-shadow: var(--shadow);
  transition: var(--transition);
  min-height: 280px;
  background: var(--glass);
}
.project-card img {
  width: 100%; height: 190px;
  object-fit: cover;
  background: var(--gray);
}
.project-info {
  position: absolute;
  bottom: -110%;
  left: 0; right: 0;
  background: linear-gradient(0deg, var(--accent) 80%, transparent 100%);
  padding: 1.2rem 1rem 1rem 1.2rem;
  transition: bottom 0.42s cubic-bezier(.21,1.02,.73,1);
  color: var(--primary); z-index: 2;
  border-bottom-left-radius: 14px; border-bottom-right-radius: 14px;
  box-shadow: 0 4px 22px #0652DD30;
}
.project-card:hover .project-info {
  bottom: 0;
}
.project-info h3 { margin-bottom: 0.39rem;}
.project-link {
  color: var(--primary);
  background: var(--accent-dark);
  font-size: 1.1rem;
  margin: 0.35rem 0.7rem 0 0;
  padding: 0.4rem 1rem;
  border-radius: 7px;
  text-decoration: none;
  display: inline-flex; align-items: center; gap: 6px;
  transition: background 0.2s, color 0.2s;
}
.project-link i { font-size: 1.13rem;}
.project-link:hover { background: var(--accent-light); color: var(--gray); }
.tag {
  background: var(--accent-light);
  color: var(--gray);
  font-size: 0.89rem;
  padding: 0.13em 0.7em;
  border-radius: 8px;
  margin-left: 3px;
  font-weight: 600;
}

.contact-content {
  display: flex; justify-content: center; align-items: flex-start;
  gap: 3.5rem; flex-wrap: wrap;
}
.contact-form {
  display: flex; flex-direction: column; gap: 1.05rem;
  padding: 2rem 2.2rem 1.7rem 2.2rem;
  min-width: 290px; max-width: 410px;
}
.contact-form input, .contact-form textarea {
  border: none;
  background: var(--glass);
  color: var(--primary);
  border-radius: 7px;
  padding: 0.9rem 1rem;
  font-size: 1rem;
  margin-bottom: 0.7rem;
  box-shadow: 0 1px 8px #222a3227;
  border: 1px solid var(--glass-border);
  transition: border 0.2s;
}
.contact-form input:focus, .contact-form textarea:focus {
  border: 1.5px solid var(--accent);
  outline: none;
}
.contact-form button {
  align-self: flex-end;
}
.contact-info { display: flex; flex-direction: column; align-items: center; gap: 22px;}
.social-links {
  display: flex; justify-content: center; gap: 44px;
}
.social-links a {
  color: var(--accent); font-size: 2.2rem;
  transition: color 0.3s, transform 0.3s;
}
.social-links a:hover {
  color: var(--accent-light);
  transform: scale(1.13) rotate(-10deg);
}

.btn, .glass-btn {
  background: var(--accent);
  color: var(--bg);
  padding: 0.93rem 2.2rem;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
  transition: var(--transition);
  font-size: 1.09rem;
  box-shadow: 0 2px 12px #0652DD15;
}
.btn:hover, .glass-btn:hover {
  background: var(--accent-light);
  color: var(--gray);
}

footer.glass-footer {
  background: var(--glass);
  color: var(--primary);
  text-align: center;
  padding: 1.2rem 0;
  font-size: 1.08rem;
  letter-spacing: 0.6px;
  border-top: 1.2px solid var(--glass-border);
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: 0 2px 18px #0652DD13;
}

#back-to-top {
  display: none;
  position: fixed;
  bottom: 24px; right: 24px;
  background: var(--accent);
  color: var(--bg);
  border: none;
  border-radius: 50%;
  padding: 12px 16px;
  font-size: 1.3rem;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(6, 82, 221, 0.14);
  transition: var(--transition);
  z-index: 1200;
}
#back-to-top:hover {
  background: var(--accent-light); color: var(--bg);
}

@media (max-width: 1200px) {
  .home-wide { gap: 2.5rem; }
}
@media (max-width: 900px) {
  nav .container { flex-direction: column; gap: 1rem;}
  .home-wide { flex-direction: column; gap: 2rem; width: 98vw; }
  .home-text { text-align: center; align-items: center; }
  .profile-circle { margin: 0 auto;}
  .about-content { padding: 1.7rem 0.7rem;}
}
@media (max-width: 600px) {
  .home-wide { padding: 0.5rem 0.5rem;}
  .profile-circle { width: 120px; height: 120px;}
  .profile-inner-circle { width: 80px; height: 80px;}
  .services { padding: 2rem 0;}
  .glass-section { padding: 2rem 0;}
  .about-content { padding: 1.1rem 0.2rem;}
  .contact-form { padding: 1rem;}
}
