@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=Outfit:wght@500;700&display=swap');

:root {
  /* Color Palette */
  --bg-color: #0f172a;
  /* Slate 900 */
  --surface-color: #1e293b;
  /* Slate 800 */
  --primary-color: #38bdf8;
  /* Sky 400 */
  --secondary-color: #818cf8;
  /* Indigo 400 */
  --text-primary: #f8fafc;
  /* Slate 50 */
  --text-secondary: #94a3b8;
  /* Slate 400 */
  --accent-glow: rgba(56, 189, 248, 0.15);

  /* Spacing & Layout */
  --header-height: 70px;
  --border-radius: 12px;
  --container-width: 1200px;
  /* Increased width */
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  line-height: 1.7;
  color: var(--text-primary);
  background-color: var(--bg-color);
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Outfit', sans-serif;
  color: var(--text-primary);
  margin-top: 0;
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--bg-color);
}

::-webkit-scrollbar-thumb {
  background: var(--surface-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}

/* Header & Navigation (Glassmorphism) */
header {
  background: rgba(15, 23, 42, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  height: var(--header-height);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 5%;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.header-title {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.header-title h1 {
  font-size: 1.5rem;
  margin: 0;
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-weight: 700;
}

.header-title small {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: block;
  display: block;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

nav {
  display: flex;
  align-items: center;
  gap: 20px;
}

nav ul {
  display: flex;
  gap: 30px;
  list-style: none;
  align-items: center;
  margin: 0;
  padding: 0;
}

nav a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  transition: color 0.3s ease;
  font-size: 0.95rem;
  position: relative;
  padding: 5px 0;
}

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

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

nav a:hover::after,
nav a.active::after {
  width: 100%;
}

/* Language Toggle Button */
.lang-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--text-primary);
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  height: fit-content;
}

.lang-btn:hover {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
}

.award-link {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.3s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.award-link:hover {
  color: var(--primary-color);
  text-decoration: none;
}

.external-icon {
  transition: transform 0.3s ease;
  opacity: 0.7;
}

.award-link:hover .external-icon {
  transform: translate(2px, -2px);
  opacity: 1;
}

/* Sections Global */
section {
  padding: 120px 40px;
  max-width: 1200px;
  margin: 0 auto;
  scroll-margin-top: var(--header-height);
}

h2 {
  font-size: 2.5rem;
  margin-bottom: 80px;
  text-align: center;
  position: relative;
  display: inline-block;
  left: 50%;
  transform: translateX(-50%);
}

h2::after {
  content: '';
  position: absolute;
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--primary-color);
  border-radius: 2px;
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-top: 140px;
}

.hero-content {
  max-width: 800px;
}

.profile-wrapper {
  position: relative;
  display: inline-block;
  margin-bottom: 40px;
}

.hero-profile-img {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid rgba(56, 189, 248, 0.3);
  box-shadow: 0 0 50px rgba(56, 189, 248, 0.2);
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 20px;
  line-height: 1.2;
}

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

.hero-subtitle {
  font-size: 1.5rem;
  color: var(--text-primary);
  font-weight: 500;
  margin-bottom: 20px;
}

.hero-desc {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 50px;
  line-height: 1.8;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  display: flex;
  gap: 20px;
  justify-content: center;
}

.btn {
  padding: 16px 32px;
  border-radius: 30px;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
  background: var(--primary-color);
  color: #fff;
  box-shadow: 0 10px 20px rgba(56, 189, 248, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(56, 189, 248, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

/* About Section */
.profile-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 80px;
  /* Increased gap */
  background: linear-gradient(145deg, var(--surface-color), rgba(30, 41, 59, 0.5));
  padding: 60px;
  /* Increased padding */
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  max-width: 1000px;
  margin: 0 auto;
}

.profile-photo {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--surface-color);
  box-shadow: 0 0 20px var(--accent-glow);
  transition: transform 0.3s ease;
}

.profile-photo:hover {
  transform: scale(1.05);
}

.profile-text {
  flex: 1;
  font-size: 1.05rem;
  color: var(--text-secondary);
}

.profile-text p {
  margin-bottom: 20px;
}

/* Skills Section */
.skills-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 60px;
  margin-top: 50px;
  padding: 0 20px;
}

.skill-category h3 {
  font-size: 1.5rem;
  margin-bottom: 30px;
  color: var(--text-primary);
  border-left: 4px solid var(--primary-color);
  padding-left: 15px;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
}

.skill-tags span {
  background: rgba(30, 41, 59, 0.6);
  padding: 10px 20px;
  border-radius: 12px;
  font-size: 0.95rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.3s ease;
}

.skill-tags span:hover {
  background: rgba(56, 189, 248, 0.1);
  border-color: var(--primary-color);
  transform: translateY(-2px);
}

/* Unified Achievements Grid (Experience, Awards, Activities) */
.achievements-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.left-col {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.right-col {
  display: flex;
  flex-direction: column;
}

.card {
  background: rgba(30, 41, 59, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 20px;
  padding: 40px;
  transition: transform 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  background: rgba(30, 41, 59, 0.6);
}

.card h3 {
  font-size: 1.5rem;
  margin-bottom: 30px;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.clean-list {
  list-style: none;
  padding: 0;
}

.clean-list li {
  margin-bottom: 25px;
  padding-bottom: 25px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.clean-list li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.clean-list strong {
  color: var(--text-primary);
  font-size: 1.1rem;
  display: block;
  margin-bottom: 5px;
}

.clean-list small {
  color: var(--text-secondary);
  display: block;
  margin-bottom: 8px;
}

.clean-list p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-top: 10px;
}

/* Bento Grid (Projects) */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 60px;
}

.bento-item {
  background: var(--surface-color);
  border-radius: 24px;
  padding: 40px;
  position: relative;
  overflow: hidden;
  min-height: 320px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all 0.4s ease;
}

.bento-item.large {
  grid-column: span 2;
}

.bento-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
  border-color: rgba(56, 189, 248, 0.3);
}

.bento-content {
  position: relative;
  z-index: 2;
}

.bento-content h3 {
  font-size: 1.8rem;
  margin-bottom: 15px;
}

.tech-stack {
  color: var(--primary-color);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.link-arrow {
  display: inline-block;
  margin-top: 20px;
  color: var(--text-primary);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 2px;
}

/* Footer */
footer {
  background: var(--surface-color);
  padding: 40px 0;
  text-align: center;
  color: var(--text-secondary);
  margin-top: 60px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* Scroll Reveal Animation Classes */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    height: auto;
    padding: 15px;
  }

  header nav ul {
    margin-top: 15px;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
  }

  .profile-container {
    flex-direction: column;
    text-align: center;
    padding: 30px;
  }

  #projects ul {
    grid-template-columns: 1fr;
  }

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

  .bento-item.large {
    grid-column: span 1;
  }

  .grid-2-col {
    grid-template-columns: 1fr;
  }

  .timeline {
    margin-left: 10px;
    padding-left: 20px;
  }
}