:root {
  --bg: #f4f7fb;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-solid: #ffffff;
  --surface-soft: #eaf0f8;
  --surface-tint: #f0f4fa;

  --text: #26313f;
  --text-muted: #66758a;
  --heading: #34445a;

  --accent: #7c9cc6;
  --accent-hover: #688bb8;
  --accent-soft: #dce7f5;

  --border: rgba(86, 110, 145, 0.15);
  --shadow: 0 10px 30px rgba(84, 102, 132, 0.11);
  --shadow-hover: 0 18px 38px rgba(84, 102, 132, 0.17);

  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --max-width: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

body {
  margin: 0;
  font-family: "DM Sans", sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top left, #ffffff 0%, #f4f7fb 42%, #e8eff8 100%);
  line-height: 1.6;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(100% - 2rem, var(--max-width));
  margin: 0 auto;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  background: white;
  color: var(--heading);
  padding: 0.75rem 1rem;
  border-radius: 12px;
  z-index: 999;
  box-shadow: var(--shadow);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  padding-top: 1rem;
}

.nav-shell {
  width: min(100% - 2rem, 860px);
  margin: 0 auto;
  padding: 0.85rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: var(--surface);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(92, 112, 145, 0.12);
}

.brand {
  font-weight: 800;
  color: var(--heading);
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.nav-links {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.nav-links a {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--heading);
  padding: 0.7rem 1rem;
  border-radius: 999px;
  transition: 0.2s ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background: var(--surface-soft);
  color: var(--heading);
}

.hero {
  min-height: 82vh;
  display: grid;
  align-items: center;
  padding: 4.5rem 0 3rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 1rem;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--border);
  color: var(--heading);
  font-size: 0.9rem;
  font-weight: 700;
}

h1 {
  margin: 0 0 1rem;
  font-family: "Playfair Display", serif;
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  line-height: 0.95;
  color: var(--heading);
}

.hero p {
  margin: 0 0 1.1rem;
  font-size: 1.08rem;
  color: var(--text-muted);
  max-width: 58ch;
}

.accent {
  color: var(--accent);
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.9rem 1.25rem;
  border-radius: 999px;
  font-weight: 700;
  transition: 0.2s ease;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--accent);
  color: white;
  box-shadow: 0 10px 22px rgba(124, 156, 198, 0.28);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.92);
  color: var(--heading);
  border-color: var(--border);
}

.btn-secondary:hover {
  background: var(--surface-soft);
}

.hero-card {
  background: linear-gradient(180deg, #ffffff, var(--surface-tint));
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
}

.hero-card h2 {
  margin-top: 0;
  margin-bottom: 0.75rem;
  color: var(--heading);
  font-size: 1.2rem;
}

.hero-card p {
  font-size: 0.98rem;
  margin-bottom: 1rem;
}

.mini-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 0.9rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid var(--border);
  color: var(--heading);
  font-size: 0.88rem;
  font-weight: 700;
}

.chip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

section {
  padding: 2rem 0 4rem;
}

.section-card {
  background: var(--surface-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 2rem;
}

.section-heading {
  margin-bottom: 1.75rem;
}

.section-title {
  margin: 0 0 0.65rem;
  color: var(--heading);
  font-size: clamp(1.5rem, 2vw, 2rem);
}

.section-sub {
  margin: 0;
  color: var(--text-muted);
  max-width: 60ch;
}

.about-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 1.5rem;
}

.stack-block + .stack-block {
  margin-top: 1.5rem;
}

.stack-block h3 {
  margin: 0 0 0.6rem;
  color: var(--heading);
  font-size: 1.05rem;
}

.stack-block p {
  margin: 0;
  color: var(--text-muted);
}

.stack-block .tech-list {
  list-style: disc;
  padding-left: 1.2rem;
  margin: 0;
}

.stack-block .tech-list li {
  margin-bottom: 0.4rem; 
  line-height: 1.5; 
  color: var(--text-muted)     
}

.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  padding: 0;
  margin: 0;
  list-style: none;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.25rem;
  align-items: stretch;
}

.project-card {
  background: linear-gradient(180deg, #fcfdff, var(--surface-tint));
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 8px 20px rgba(84, 102, 132, 0.10);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  height: 100%;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(124, 156, 198, 0.32);
}

.project-card a {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.project-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.project-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1.15rem 1.15rem 1.3rem;
  flex: 1;
}

.project-kicker {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-hover);
}

.project-content h3 {
  margin: 0;
  color: var(--heading);
  font-size: 1.15rem;
}

.project-tech {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 600;
}

.project-desc {
  margin: 0.15rem 0 0;
  color: var(--text-muted);
  font-size: 0.96rem;
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 1.5rem;
}

.contact-list p {
  margin: 0 0 0.85rem;
  color: var(--text-muted);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1.25rem;
}

.social-btn {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid var(--border);
  box-shadow: 0 8px 20px rgba(84, 102, 132, 0.10);
  transition: 0.2s ease;
}

.social-btn:hover {
  transform: translateY(-4px);
  background: var(--surface-soft);
}

.social-btn img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.contact-form {
  display: grid;
  gap: 1rem;
}

.contact-form label {
  font-weight: 700;
  color: var(--heading);
  font-size: 0.95rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  margin-top: 0.4rem;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 0.95rem 1rem;
  background: #f8fbff;
  color: var(--text);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: #8b98aa;
}

.contact-form textarea {
  min-height: 140px;
  resize: vertical;
}

footer {
  padding: 0 0 3rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
}

@media (max-width: 900px) {
  .hero-grid,
  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 3.5rem;
  }

  .nav-shell {
    border-radius: 24px;
  }

  .brand {
    display: none;
  }

  .nav-shell,
  .nav-links {
    justify-content: center;
  }
}

@media (max-width: 560px) {
  body {
    overflow-x: hidden;
  }

  .nav-links a {
    padding: 0.65rem 0.8rem;
    font-size: 0.88rem;
  }

  .section-card {
    padding: 1.3rem;
  }

  .hero-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

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

/* THANK YOU MESSAGE */
#thank-you-message {
  opacity: 0;
  pointer-events: none; /* prevents clicks when hidden */
  transition: opacity 0.4s ease;
  margin-top: 1rem;
  padding: 0.95rem 1rem;
  border-radius: 16px;
  border: 1px solid rgba(84, 132, 98, 0.22);
  background: #edf8f0;
  color: #2f5d3a;
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.5;
  box-shadow: 0 8px 20px rgba(84, 132, 98, 0.08);
}

#thank-you-message.show {
  opacity: 1;
  pointer-events: auto;
  animation: fadeSlideIn 0.28s ease;
}

.screenshot-card {
  cursor: zoom-in;
  position: relative;
}

/* Lightbox container */
.lightbox {
  position: fixed;
  inset: 0; /* top, right, bottom, left */
  background: rgba(0, 0, 0, 0.85);
  display: grid;
  place-items: center;
  z-index: 9999;
  padding: 2rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.lightbox.active {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
}

.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: transparent;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
}