/* =========================
   :ROOT VARIABLES
========================= */

/* Light Theme */
:root {
  --primary-font: "Poppins", sans-serif;
  --primary-bg-color: #ffffff;
  --primary-text-color: #000000;
  --secondary-color: #575757;
  --btn-bg-color: #2196f3;
  --cta-hover-color: #167bce;
  --btn-bg-light: #eeeeee;

  /* Dark Theme */
  --dark-primary-bg-color: #222222;
  --dark-primary-text-color: #ffffff;
  --dark-secondary-color: #828282;
  --dark-btn-bg-color: #1e88e5;
  --dark-cta-hover-color: #0d5e8c;
  --dark-btn-bg-light: #333333;
}

/* Dark Theme Overrides */
.dark-theme {
  --primary-bg-color: var(--dark-primary-bg-color);
  --primary-text-color: var(--dark-primary-text-color);
  --secondary-color: var(--dark-secondary-color);
  --btn-bg-color: var(--dark-btn-bg-color);
  --cta-hover-color: var(--dark-cta-hover-color);
  --btn-bg-light: var(--dark-btn-bg-light);
}

/* =========================
   BODY
========================= */
body {
  margin: 0;
  font-family: var(--primary-font);
  background-color: var(--primary-bg-color);
  color: var(--primary-text-color);
}

/* =========================
   HERO SECTION
========================= */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-top: 2rem;
  gap: 1rem;
}

.hero-pic {
  width: 10rem;
  height: 10rem;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
}

.inner-circle {
  position: absolute;
  inset: 0.1rem;
  border-radius: 50%;
  border: 0.2rem solid var(--primary-bg-color);
  z-index: 1;
}

.hero-pic img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* preserve image proportions without cutting */
  transform: scale(1.2);
  border-radius: 50%;
}

.hero-info h1 {
  font-weight: 700;
  margin: 0.5rem 0 0;
}

.hero-info h2 {
  font-weight: 500;
  color: var(--secondary-color);
  margin: 0.3rem 0 1rem;
}

/* Logo container inside hero */
.logo-container {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.logo-container img {
  height: 1.8rem;
  transition: transform 0.2s ease;
}

.logo-container a:hover img {
  transform: scale(1.1);
}

/* =========================
   THEME BUTTON
========================= */
.theme-btn {
  width: 2.2rem;
  height: 2.2rem;
  position: relative; /* inside hero positioning */
  left: 8.5rem;       /* original position */
  cursor: pointer;
  z-index: 10;
}

/* =========================
   CTA / CONTACT BUTTONS
========================= */
.cta {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
}

/* Contact card for logos */
.contact-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.contact-label {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--btn-bg-color);
}

.contact-logos {
  display: flex;
  gap: 2rem;
  justify-content: center;
}

.contact-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
}

.contact-item a img {
  width: 2rem;
  height: 2rem;
  transition: transform 0.2s ease;
}

.contact-item a:hover img {
  transform: scale(1.1);
}

.contact-name {
  font-size: 0.85rem;
  color: var(--secondary-color);
  font-weight: 500;
}

/* =========================
   TOGGLE BUTTONS (Projects / Skills)
========================= */
.portfolio-skills {
  display: flex;
  justify-content: center;
  margin: 2rem 0;
}

.btn-bg {
  display: flex;
  gap: 1rem;
}

.btn-2 {
  padding: 0.6rem 1.2rem;
  border-radius: 0.7rem;
  border: none;
  background-color: var(--btn-bg-light);
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.btn-2:hover {
  transform: scale(0.98);
}

.active-btn {
  background-color: var(--btn-bg-color);
  color: white;
}

/* =========================
   PROJECT CARDS
========================= */
#projects {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  margin: 1rem auto;
}

.project-card {
  background-color: var(--btn-bg-light);
  border-radius: 1rem;
  padding: 1.5rem;
  max-width: 22rem;
  width: 100%;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.project-card h3 {
  margin: 0;
}

.project-card p {
  margin: 0;
  color: var(--secondary-color);
}

.project-links {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.project-links a {
  text-decoration: none;
  color: var(--btn-bg-color);
  font-weight: 600;
  transition: color 0.3s ease;
}

.project-links a:hover {
  color: var(--cta-hover-color);
}

/* =========================
   SKILL CARDS
========================= */
#skills {
  display: flex;
  justify-content: center;
  margin: 1rem auto;
}

.skills-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

.skill-card {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--btn-bg-light);
  padding: 1rem 1.5rem;
  border-radius: 0.7rem;
  font-weight: 600;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.skill-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.skill-logo {
  width: 1.5rem;
  height: 1.5rem;
  object-fit: contain;
}

/* =========================
   FOOTER
========================= */
footer {
  margin: 3rem 0;
  text-align: center;
}

footer a {
  color: var(--btn-bg-color);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.3s ease, transform 0.2s ease;
}

footer a:hover {
  color: var(--cta-hover-color);
  transform: scale(1.05);
}

/* =========================
   MEDIA QUERIES
========================= */
@media screen and (min-width: 768px) {
  #projects,
  #skills {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
  }

  .project-card {
    width: calc(45% - 1rem);
  }

  .skill-card {
    width: calc(30% - 1rem);
    text-align: center;
  }
}

@media screen and (min-width: 1200px) {
  .project-card {
    width: calc(33% - 1rem);
  }

  .skill-card {
    width: calc(20% - 1rem);
  }
}