@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap");

:root {
  --bg-color: #081b29;
  --bg-alt: #112e42;
  --text-color: #ededde;
  --muted-color: #9aa4b3;
  --main-color: #00abf0;
  --accent-color: #28e0ff;

  --radius-lg: 1.6rem;
  --radius-md: 1rem;
  --radius-sm: 0.6rem;

  --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.45);

  --transition-fast: 0.2s ease;
  --transition-med: 0.3s ease;
}

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 62.5%;
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", sans-serif;
  background: radial-gradient(
    circle at top left,
    #0f3147 0,
    #050b16 45%,
    #02040a 100%
  );
  color: var(--text-color);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Ambient background glow */
body::before,
body::after {
  content: "";
  position: fixed;
  inset: -20%;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(circle at 10% 20%, rgba(0, 171, 240, 0.25) 0, transparent 55%),
    radial-gradient(circle at 80% 0%, rgba(40, 224, 255, 0.2) 0, transparent 60%),
    radial-gradient(circle at 20% 80%, rgba(0, 0, 0, 0.55) 0, transparent 55%);
  filter: blur(32px);
  opacity: 0.6;
  mix-blend-mode: screen;
  animation: floatSmoke 40s linear infinite;
}

body::after {
  animation-duration: 65s;
  animation-direction: reverse;
  opacity: 0.45;
}

@keyframes floatSmoke {
  0% {
    transform: translate3d(-6%, 4%, 0) scale(1);
  }
  50% {
    transform: translate3d(8%, -6%, 0) scale(1.08);
  }
  100% {
    transform: translate3d(-6%, 4%, 0) scale(1);
  }
}

/* Light theme */
body.light-theme {
  --bg-color: #f5f7fb;
  --bg-alt: #ffffff;
  --text-color: #16181e;
  --muted-color: #70778a;
  --main-color: #005bff;
  --accent-color: #10b981;
  --shadow-soft: 0 20px 40px rgba(0, 0, 0, 0.08);

  background: radial-gradient(
    circle at top left,
    #e5efff 0,
    #f5f7fb 45%,
    #ffffff 100%
  );
}

body.light-theme::before,
body.light-theme::after {
  background:
    radial-gradient(
      circle at 10% 20%,
      rgba(0, 91, 255, 0.18) 0,
      transparent 55%
    ),
    radial-gradient(
      circle at 80% 0%,
      rgba(16, 185, 129, 0.16) 0,
      transparent 60%
    ),
    radial-gradient(
      circle at 20% 80%,
      rgba(148, 163, 184, 0.12) 0,
      transparent 55%
    );
  filter: blur(40px);
  opacity: 0.35;
  mix-blend-mode: normal;
}

/* Global */
img {
  max-width: 100%;
  display: block;
}

.section {
  padding: 10rem 9% 7rem;
  position: relative;
}

.heading {
  font-size: 3.6rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.heading span {
  color: var(--main-color);
}

.subheading {
  font-size: 1.5rem;
  color: var(--muted-color);
  max-width: 48rem;
}

.section-header {
  text-align: left;
  max-width: 70rem;
  margin: 0 auto 5rem;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1.8rem 9%;
  display: flex;
  align-items: center;
  gap: 3rem;
  z-index: 100;
  backdrop-filter: blur(16px);
  background: linear-gradient(
    to bottom,
    rgba(2, 6, 23, 0.95),
    rgba(2, 6, 23, 0.8),
    transparent
  );
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

body.light-theme .header {
  background: linear-gradient(
    to bottom,
    rgba(248, 250, 252, 0.97),
    rgba(248, 250, 252, 0.9),
    transparent
  );
  border-bottom-color: rgba(15, 23, 42, 0.06);
}

.logo {
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.logo span {
  color: var(--main-color);
}

/* NAVBAR – desktop */
.navbar {
  display: flex;
  align-items: center;
  gap: 2.8rem;
  margin-left: 3rem;
  position: relative;
  flex: 1;
}

.navbar a {
  font-size: 1.5rem;
  color: var(--muted-color);
  position: relative;
  padding-bottom: 0.3rem;
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.navbar a.active,
.navbar a:hover {
  color: var(--text-color);
}

/* Animated active underline bar */
.navbar .active-nav {
  position: absolute;
  bottom: -0.45rem;
  left: 0;
  height: 2px;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--main-color), var(--accent-color));
  transition: transform 0.25s ease, width 0.25s ease, opacity 0.25s ease;
  opacity: 0;
  pointer-events: none;
}

/* Right side (theme + menu) */
.header-right {
  display: flex;
  align-items: center;
  gap: 2.4rem;
  margin-left: auto;
}

.theme-toggle {
  position: relative;
  width: 3.6rem;
  height: 3.6rem;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  border: 1px solid rgba(148, 163, 184, 0.7);
  background: radial-gradient(
    circle at 30% 30%,
    rgba(148, 163, 184, 0.32),
    transparent 60%
  );
  color: #e5e7eb;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.9);
  overflow: hidden;
  transition:
    background 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease,
    transform 0.2s ease;
}

.theme-toggle i {
  font-size: 2rem;
  color: inherit;
  transition: transform 0.35s ease;
}

.theme-toggle::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(
    circle at 20% 0%,
    rgba(0, 171, 240, 0.65),
    transparent 55%
  );
  opacity: 0;
  transform: scale(0.6) translateY(4px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.theme-toggle:hover {
  transform: translateY(-1px) scale(1.03);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.8);
  border-color: var(--accent-color);
}

.theme-toggle:hover::before {
  opacity: 0.9;
  transform: scale(1) translateY(0);
}

.theme-toggle.spin i {
  transform: rotate(180deg);
}

/* Light mode button variant */
body.light-theme .theme-toggle {
  background: radial-gradient(
    circle at 30% 30%,
    rgba(148, 163, 184, 0.18),
    #f8fafc
  );
  border-color: rgba(148, 163, 184, 0.8);
  color: #0f172a;
  box-shadow: 0 0 0 1px rgba(226, 232, 240, 0.9);
}

body.light-theme .theme-toggle::before {
  background: radial-gradient(
    circle at 20% 0%,
    rgba(0, 91, 255, 0.6),
    transparent 55%
  );
}

#menu-icon {
  font-size: 3rem;
  cursor: pointer;
  display: none;
}

/* MOBILE NAV */
@media (max-width: 900px) {
  .header {
    padding-inline: 6%;
  }

  .navbar {
    position: fixed;
    top: 70px;
    right: 6%;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.2rem;
    padding: 1.8rem 1.6rem;
    border-radius: 1.4rem;
    background: rgba(15, 23, 42, 0.98);
    border: 1px solid rgba(148, 163, 184, 0.35);
    box-shadow: var(--shadow-soft);
    transform: translateY(-8px) scale(0.92);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease, transform 0.18s ease;
    width: min(260px, 80vw);
    margin-left: 0;
  }

  body.light-theme .navbar {
    background: #ffffff;
  }

  .navbar.show {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }

  .navbar .active-nav {
    display: none;
  }

  #menu-icon {
    display: block;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  padding: 1.2rem 2.6rem;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition-med);
  font-weight: 500;
  gap: 0.6rem;
}

.btn.primary {
  background: linear-gradient(135deg, var(--main-color), var(--accent-color));
  color: #020617;
  box-shadow: var(--shadow-soft);
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 24px 45px rgba(0, 0, 0, 0.55);
}

.btn.ghost {
  border-color: rgba(255, 255, 255, 0.35);
  background: transparent;
  color: var(--text-color);
}

body.light-theme .btn.ghost {
  border-color: rgba(15, 23, 42, 0.15);
}

.btn.ghost:hover {
  background: rgba(255, 255, 255, 0.06);
}

/* Hero */
.home {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  align-items: center;
  gap: 5rem;
  padding-top: 12rem;
  position: relative;
  overflow: hidden;
}

.eyebrow {
  font-size: 1.3rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted-color);
  margin-bottom: 1.4rem;
}

.home-content h1 {
  font-size: 4.6rem;
  margin-bottom: 1.4rem;
}

.home-content h1 span {
  color: var(--main-color);
}

.typing-wrapper {
  font-size: 2rem;
  margin-bottom: 1.8rem;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.typing-text {
  color: var(--accent-color);
  font-weight: 600;
}

.typing-cursor {
  font-weight: 600;
  animation: blink 0.8s infinite;
}

@keyframes blink {
  0%,
  50% {
    opacity: 1;
  }
  50.01%,
  100% {
    opacity: 0;
  }
}

.home-description {
  font-size: 1.5rem;
  color: var(--muted-color);
  max-width: 50rem;
  margin-bottom: 2.6rem;
}

.home-cta {
  display: flex;
  gap: 1.4rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.home-metrics {
  display: flex;
  gap: 2.6rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.metric h4 {
  font-size: 2.4rem;
  margin-bottom: 0.3rem;
}

.metric p {
  font-size: 1.35rem;
  color: var(--muted-color);
}

.home-sci {
  display: flex;
  gap: 1rem;
}

.home-sci a {
  width: 3.6rem;
  height: 3.6rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: grid;
  place-items: center;
  font-size: 1.8rem;
  transition: var(--transition-med);
}

.home-sci a:hover {
  background: var(--main-color);
  color: #020617;
  transform: translateY(-2px);
}

/* Home visual panels */
.home-visual {
  position: relative;
  min-height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dev-panel {
  position: absolute;
  width: 260px;
  padding: 1.6rem 1.8rem;
  border-radius: 1.6rem;
  background: radial-gradient(circle at top left, #0b1220, #020617);
  border: 1px solid rgba(148, 163, 184, 0.55);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
  font-size: 1.3rem;
  transform-style: preserve-3d;
  animation: floatDev 8s ease-in-out infinite;
}

body.light-theme .dev-panel {
  background: radial-gradient(circle at top left, #ffffff, #f3f4f6);
}

/* Exact neon border effect */
.dev-panel {
  border: 1px solid rgba(0, 200, 255, 0.35);
  backdrop-filter: blur(14px);
}

.dev-panel:hover {
  border: 1px solid rgba(0, 240, 255, 0.9);
  box-shadow: 0 0 18px rgba(0, 240, 255, 0.45);
}


.dev-terminal {
  top: 4%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  animation-delay: 0s;
}

.dev-code {
  bottom: 8%;
  left: 0%;
  animation-delay: 0.7s;
}

.dev-status {
  bottom: 4%;
  right: 0%;
  animation-delay: 1.2s;
}

.dev-panel:hover {
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.9);
}

.terminal-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  font-size: 1.1rem;
  color: var(--muted-color);
}

.terminal-title {
  margin-left: auto;
  opacity: 0.8;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
}

.dot.red {
  background: #f97373;
}

.dot.yellow {
  background: #facc15;
}

.dot.green {
  background: #4ade80;
}

.terminal-body {
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco,
    Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 1.2rem;
  line-height: 1.5;
  color: #a5f3fc;
}

.terminal-line {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.terminal-line.highlight {
  color: #4ade80;
}

.dynamic-line::after {
  content: "▋";
  margin-left: 0.3rem;
  animation: blink 0.9s steps(1) infinite;
}

.card-label {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 1.1rem;
  border-radius: 999px;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted-color);
  border: 1px solid rgba(148, 163, 184, 0.7);
  margin-bottom: 0.8rem;
}

.code-block {
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Monaco,
    Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 1.2rem;
  line-height: 1.5;
  background: rgba(15, 23, 42, 0.9);
  border-radius: 1rem;
  padding: 1rem 1.2rem;
  color: #e5e7eb;
  border: 1px solid rgba(15, 23, 42, 0.9);
  white-space: pre;
}

body.light-theme .code-block {
  background: #0f172a;
  border-color: #020617;
}

.code-keyword {
  color: #38bdf8;
}

.code-string {
  color: #f97316;
}

.status-pill {
  border-color: rgba(52, 211, 153, 0.7);
  color: #bbf7d0;
  background: rgba(22, 163, 74, 0.12);
}

.status-pill .dot {
  margin-right: 0.5rem;
}

.dot-pulse {
  animation: pulseDot 1.8s infinite;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.8);
  background: #22c55e;
}

.status-list {
  list-style: none;
  margin: 1.2rem 0 0;
  padding: 0;
}

.status-list li {
  display: flex;
  justify-content: space-between;
  font-size: 1.25rem;
  color: var(--muted-color);
  margin-bottom: 0.4rem;
}

@keyframes floatDev {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@keyframes pulseDot {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.3);
    opacity: 0.6;
  }
}

/* About */
.about {
  background: radial-gradient(
      circle at top left,
      rgba(0, 171, 240, 0.12),
      transparent 55%
    ),
    var(--bg-color);
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
  gap: 5rem;
  align-items: center;
}

.about-img {
  display: flex;
  justify-content: center;
}

.avatar-ring {
  position: relative;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  display: grid;
  place-items: center;
}

.avatar-ring::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  padding: 4px;
  background: conic-gradient(
    from 180deg,
    var(--main-color),
    transparent,
    var(--accent-color),
    transparent,
    var(--main-color)
  );
  -webkit-mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 6px),
    #000 calc(100% - 4px)
  );
  mask: radial-gradient(
    farthest-side,
    transparent calc(100% - 6px),
    #000 calc(100% - 4px)
  );
  animation: spin 12s linear infinite;
}

.avatar-ring img {
  position: relative;
  width: 82%;
  height: 82%;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-alt);
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.about-content h3 {
  font-size: 2.2rem;
  margin-bottom: 1.6rem;
}

.about-content p {
  font-size: 1.5rem;
  color: var(--muted-color);
  margin-bottom: 1.6rem;
}

.about-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 1.8rem 0 2.4rem;
}

.highlight {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.3rem;
  padding: 0.8rem 1.4rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.4);
}

body.light-theme .highlight {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(148, 163, 184, 0.4);
}

.highlight i {
  color: var(--main-color);
}

/* Skills */
.skills {
  background: var(--bg-alt);
}

.skills-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 4rem;
  align-items: flex-start;
}

.skills-column h3 {
  font-size: 2rem;
  margin-bottom: 2rem;
}

/* Logos row with bouncing icons */
.skills-logo-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1.6rem;
  margin-bottom: 2.8rem;
}

.skill-logo {
  background: rgba(15, 23, 42, 0.9);
  border-radius: 1.4rem;
  padding: 1.4rem 1.2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
  box-shadow: var(--shadow-soft);
  animation: floatIcon 3.2s ease-in-out infinite;
}

.skill-logo:nth-child(2) {
  animation-delay: 0.25s;
}
.skill-logo:nth-child(3) {
  animation-delay: 0.5s;
}
.skill-logo:nth-child(4) {
  animation-delay: 0.75s;
}

.skill-logo img {
  width: 48px;
  height: 48px;
}

.skill-logo span {
  font-size: 1.3rem;
}


/* Single icon per skill (no swap) */
.skill-logo-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
}

.skill-logo-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* keep hover only on the card, not on the image layer */
.skill-logo:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 35px rgba(0, 0, 0, 0.55);
}


/* Make very dark icons visible on dark background */
.skill-logo-icon img[src*="github-original"],
.skill-logo-icon img[src*="github-plain"],
.skill-logo-icon img[src*="wordpress-plain"] {
  filter: invert(1) brightness(1.2);
}

.skill-logo-icon img[src*="wordpress"] {
  filter: invert(1) brightness(1.2);
}


@keyframes floatIcon {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

/* Core progress bars */
.skills-meters {
  margin-top: 1.2rem;
}

.skill-bar {
  margin-bottom: 1.8rem;
}

.skill-top {
  display: flex;
  justify-content: space-between;
  font-size: 1.4rem;
  margin-bottom: 0.6rem;
}

.skill-top span:last-child {
  color: var(--muted-color);
}

.bar {
  width: 100%;
  height: 0.9rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.7);
  overflow: hidden;
}

body.light-theme .bar {
  background: rgba(226, 232, 240, 1);
}

.bar span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--main-color), var(--accent-color));
  transition: width 1.2s ease;
}


/* Right column experience cards */
.skill-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.8rem;
  margin-bottom: 2.4rem;
}

.skill-card {
  background: rgba(15, 23, 42, 0.95);
  border-radius: 1.6rem;
  padding: 2rem 2.2rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: var(--shadow-soft);
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

body.light-theme .skill-card {
  background: #ffffff;
}

.skill-card h4 {
  font-size: 1.7rem;
}

.skill-card p {
  font-size: 1.4rem;
  color: var(--muted-color);
}

/* Experience meters (small bars) */
.experience-meter {
  margin-top: 0.4rem;
}

.meter-label {
  display: flex;
  justify-content: space-between;
  font-size: 1.3rem;
  margin-bottom: 0.4rem;
}

.meter-bar {
  width: 100%;
  height: 0.7rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.6);
  overflow: hidden;
}

body.light-theme .meter-bar {
  background: rgba(226, 232, 240, 1);
}

.meter-bar span {
  display: block;
  height: 100%;
  width: calc(var(--level, 0.8) * 100%);
  background: linear-gradient(90deg, var(--main-color), var(--accent-color));
}

/* Tag list */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.tag {
  font-size: 1.3rem;
  border-radius: 999px;
  padding: 0.7rem 1.3rem;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.5);
}

body.light-theme .tag {
  background: rgba(255, 255, 255, 0.95);
}

/* Projects */
.projects {
  background: var(--bg-color);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 3rem;
}

.project-card {
  background: rgba(15, 23, 42, 0.9);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: var(--shadow-soft);
  transition:
    transform var(--transition-med),
    box-shadow var(--transition-med),
    border-color var(--transition-med);
}

body.light-theme .project-card {
  background: #ffffff;
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: var(--main-color);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.6);
}

.project-image {
  position: relative;
  overflow: hidden;
}

.project-image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.8s ease;
}

.project-card:hover .project-image img {
  transform: scale(1.06);
}

.project-content {
  padding: 2.2rem;
}

.project-content h3 {
  font-size: 1.9rem;
  margin-bottom: 1rem;
}

.project-content p {
  font-size: 1.4rem;
  color: var(--muted-color);
  margin-bottom: 1.6rem;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.8rem;
}

.project-tags span {
  font-size: 1.2rem;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.86);
  border: 1px solid rgba(148, 163, 184, 0.45);
}

body.light-theme .project-tags span {
  background: rgba(241, 245, 249, 1);
}

.project-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.project-link {
  font-size: 1.35rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-color);
  opacity: 0.85;
  transition: var(--transition-fast);
}

.project-link i {
  font-size: 1.6rem;
}

.project-link:hover {
  opacity: 1;
  color: var(--main-color);
}

/* Testimonials */
.testimonials {
  background: var(--bg-alt);
}

.testimonial-slider {
  max-width: 860px;
  margin: 0 auto;
  position: relative;
  padding: 4rem 4rem 3.4rem;
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: var(--shadow-soft);
}

body.light-theme .testimonial-slider {
  background: #ffffff;
}

.testimonial-track {
  position: relative;
  overflow: hidden;
  min-height: 220px;
}

.testimonial {
  opacity: 0;
  transform: translateX(30px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  position: absolute;
  inset: 0;
  padding-right: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

.testimonial.active {
  opacity: 1;
  transform: translateX(0);
  position: relative;
}

.testimonial-header {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}

.testimonial-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(148, 163, 184, 0.7);
  flex-shrink: 0;
}

.testimonial-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.testimonial-meta h3 {
  font-size: 1.7rem;
  margin-bottom: 0.3rem;
}

.testimonial-role {
  font-size: 1.35rem;
  color: var(--muted-color);
}

.testimonial-text {
  font-size: 1.5rem;
  line-height: 1.6;
}

/* Slider buttons */
.slider-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 3.4rem;
  height: 3.4rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  background: rgba(15, 23, 42, 0.9);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: var(--transition-fast);
}

body.light-theme .slider-btn {
  background: #ffffff;
}

.slider-btn i {
  font-size: 2rem;
}

.slider-btn:hover {
  background: var(--main-color);
  color: #020617;
}

.slider-btn.prev {
  left: -1.8rem;
}

.slider-btn.next {
  right: -1.8rem;
}

/* Dots under slider */
.slider-dots {
  margin-top: 2.4rem;
  display: flex;
  justify-content: center;
  gap: 0.8rem;
}

.slider-dot {
  width: 0.9rem;
  height: 0.9rem;
  border-radius: 50%;
  background: rgba(148, 163, 184, 0.6);
  cursor: pointer;
  transition: var(--transition-fast);
}

.slider-dot.active {
  background: var(--main-color);
  transform: scale(1.1);
}

/* Contact */
.contact {
  background: var(--bg-color);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 4rem;
  align-items: flex-start;
}

.contact-info h3 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.contact-info p {
  font-size: 1.4rem;
  color: var(--muted-color);
  margin-bottom: 2rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.2rem;
  font-size: 1.4rem;
  color: var(--muted-color);
}

.contact-item i {
  font-size: 2rem;
  color: var(--main-color);
}

.contact-form {
  background: rgba(15, 23, 42, 0.95);
  padding: 2.8rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: var(--shadow-soft);
}

body.light-theme .contact-form {
  background: #ffffff;
}

/* rows inside the contact form */
.input-row {
  display: flex;
  flex-wrap: wrap;               /* allow wrapping instead of overflowing */
  gap: 1.8rem;
  margin-bottom: 1.8rem;
}

/* individual input columns */
.input-field {
  flex: 1 1 min(260px, 100%);    /* grow, shrink, but never explode past card */
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}


.input-field.full {
  width: 100%;
  margin-bottom: 1.8rem;
}

.input-field label {
  font-size: 1.3rem;
  color: var(--muted-color);
}

.input-field input,
.input-field textarea,
.input-field select {
  border-radius: 0.9rem;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: rgba(15, 23, 42, 0.9);
  color: var(--text-color);
  padding: 1rem 1.2rem;
  font-size: 1.4rem;
  resize: none;
  outline: none;
  transition: var(--transition-fast);
}

body.light-theme .input-field input,
body.light-theme .input-field textarea,
body.light-theme .input-field select {
  background: #f9fafb;
}

.input-field input:focus,
.input-field textarea:focus,
.input-field select:focus {
  border-color: var(--main-color);
  box-shadow: 0 0 0 1px rgba(0, 171, 240, 0.4);
}

/* Phone input group */
.tel-input-group {
  display: flex;
  flex-wrap: wrap;            /* can stack on tiny screens */
  gap: 0.8rem;
}

.tel-input-group select,
.tel-input-group input {
  flex: 1 1 140px;            /* both share space nicely */
  min-width: 0;               /* prevent overflow in very narrow widths */
}

.tel-input-group select {
  cursor: pointer;
}

.btn.full {
  width: 100%;
}

.form-status {
  margin-top: 1rem;
  font-size: 1.3rem;
  color: var(--muted-color);
}

/* Footer */
.footer {
  padding: 2rem 9%;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(2, 6, 23, 0.94);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.3rem;
  color: var(--muted-color);
}

body.light-theme .footer {
  background: #f8fafc;
}

.back-to-top {
  width: 3.2rem;
  height: 3.2rem;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.6);
  display: grid;
  place-items: center;
  color: var(--text-color);
  transition: var(--transition-fast);
}

.back-to-top:hover {
  background: var(--main-color);
  color: #020617;
}

/* Force all sections to be visible */
.reveal {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* Keep this in case some JS adds .visible */
.reveal.visible {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* Responsiveness */
@media (max-width: 1024px) {
  .section {
    padding: 9rem 6% 6rem;
  }

  .home {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 4rem;
  }

  .about-grid,
  .skills-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .avatar-ring {
    width: 220px;
    height: 220px;
  }
}

/* Tablet / small phones – stack hero and fix grids */
@media (max-width: 768px) {
  .header {
    padding-inline: 6%;
  }

  .home {
    grid-template-columns: 1fr;
    padding-top: 10rem;
  }

  .home-visual {
    margin-top: 3rem;
    min-height: auto;
    flex-direction: column;
    gap: 1.6rem;
    justify-content: center;
  }

  /* stop the dev panels from being positioned off-screen */
  .dev-panel {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
    animation: none;
    width: 100%;
    max-width: 320px;
    margin-bottom: 1.4rem;
  }

  .section {
    padding: 8rem 6% 5rem;
  }

  .testimonial-slider {
    padding-inline: 2.4rem;
  }

  .slider-btn.prev {
    left: -0.8rem;
  }

  .slider-btn.next {
    right: -0.8rem;
  }

  .skills-logo-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .skill-cards-grid {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    gap: 3rem;
  }

  /* form: stack inputs instead of 2-column */
  .input-row {
    flex-direction: column;
  }

  .footer {
    flex-direction: column;
    gap: 1.2rem;
    text-align: center;
  }
}

/* Very small phones */
@media (max-width: 480px) {
  .header {
    padding-inline: 4%;
  }

  .logo {
    font-size: 2rem;
  }

  .home-content h1 {
    font-size: 3.4rem;
  }

  .heading {
    font-size: 2.7rem;
  }

  .home-cta {
    flex-direction: column;
    align-items: stretch;
  }

  .home-cta .btn {
    width: 100%;
    justify-content: center;
  }

  .testimonial-slider {
    padding-inline: 1.8rem;
  }

  .slider-btn {
    display: none;
  }
}
