:root {
  --bg: #ff4d6d;
  --card: #fff2cc;
  --head: #fff2cc;
  --text: #2b0000;
}

.dark {
  --bg: #8b0020;
  --card: #6b0018;
  --head: #ffe96b;
  --text: #ffe96b;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, Helvetica, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  transition: .3s;
}

/* ================= HEADER ================= */

header {
  position: fixed;
  top: 0;
  width: 100%;
  background: var(--card);
  padding: 14px 60px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
}

nav a {
  margin: 0 14px;
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: 20px;
}

.toggle {
  background: var(--bg);
  color: white;
  padding: 8px 18px;
  border-radius: 25px;
  cursor: pointer;
  font-size: 18px;
}

section {
  scroll-margin-top: 120px;
  padding: 140px 60px 80px;
  min-height: 100vh;
}

section+section { margin-top: 60px; }

h1 {
  color: var(--head);
  font-size: 56px;
}

h2 {
  color: var(--head);
  font-size: 42px;
  text-align: center;
  margin-bottom: 40px;
}

/* ================= HOME ================= */

.home {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 70px;
}

.home img {
  width: 460px;
  height: 460px;
  object-fit: cover;
  border-radius: 18px;
  border: 6px solid var(--card);
}

.hero-text { max-width: 650px; }

.intro-line {
  color: var(--head);
  font-size: 28px;
}

.summary {
  text-align: justify;
  background: var(--card);
  padding: 36px;
  border-radius: 24px;
  font-size: 25px;
  line-height: 1.7;
}

/* ================= GRID (Projects, Activities, etc) ================= */

.flex {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: auto;
}

.card {
  text-align: center;
  background: var(--card);
  padding: 30px;
  border-radius: 22px;
  font-size: 25px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .2);
  transition: .3s;
}

.card:hover { transform: translateY(-8px) scale(1.02); }

/* ================= EDUCATION TIMELINE ================= */

.timeline {
  position: relative;
  max-width: 900px;
  margin: auto;
  display: flex;
  flex-direction: column;
  gap: 50px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--card);
  border-radius: 10px;
}

.timeline-item {
  display: flex;
  gap: 40px;
  align-items: flex-start;
}

.timeline-dot {
  width: 18px;
  height: 18px;
  background: var(--head);
  border-radius: 50%;
  margin-top: 30px;
  flex-shrink: 0;
}

.timeline .card {
  font-size: 24.5px;
  margin-left: 20px;
}

/* ================= SKILLS ================= */

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: auto;
}

.skill-card {
  background: var(--card);
  padding: 30px;
  border-radius: 22px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .2);
  transition: .3s;
}

.skill-card:hover { transform: translateY(-8px) scale(1.02); }

.skill-card h3 {
  margin-bottom: 20px;
  font-size: 24px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.chips span {
  background: var(--bg);
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 16px;
}

/* ================= BUTTON ================= */

button {
  margin-top: 20px;
  padding: 10px 22px;
  border: none;
  background: var(--bg);
  color: white;
  border-radius: 12px;
  cursor: pointer;
  font-size: 16px;
}

/* ================= LINKS ================= */

.card a {
  text-decoration: underline;
  color: var(--text);
  font-weight: 600;
  font-size: 22px;
}

/* ================= FOOTER ================= */

footer {
  padding: 30px;
  background: var(--card);
  text-align: center;
  font-size: 18px;
}

/* ================= RESPONSIVE MEDIA QUERIES ================= */

/* Large Tablets & Small Laptops */
@media (max-width: 1024px) {

  header { padding: 14px 40px;}

  nav a {
    font-size: 18px;
    margin: 0 10px;
  }

  section { padding: 120px 40px 70px; }

  h1 { font-size: 48px; }

  h2 { font-size: 36px; }

  .home img {
    width: 380px;
    height: 380px;
  }

  .summary { font-size: 22px; }

  .card { font-size: 22px; }

}

/* Tablets & Large Phones */
@media (max-width: 768px) {

  header {
    flex-direction: column;
    gap: 10px;
    padding: 14px 30px;
  }

  nav a {
    font-size: 16px;
    margin: 0 8px;
  }

  section { padding: 120px 25px 60px; }

  h1 { font-size: 36px; }

  h2 { font-size: 30px; }

  .home {
    flex-direction: column;
    gap: 40px;
    text-align: center;
  }

  .home img {
    width: 260px;
    height: 260px;
  }

  .summary { font-size: 20px; }

  .card { font-size: 20px; }

  .timeline-item { gap: 20px; }

}

/* Small Phones */
@media (max-width: 480px) {

  h1 { font-size: 30px; }

  h2 { font-size: 26px; }

  .summary { font-size: 18px; }

  .card { font-size: 18px; }

  .chips span {
    font-size: 14px;
    padding: 6px 12px;
  }

}