:root {
  --bg: #f7f2e8;
  --bg-alt: #e8f1ec;
  --surface: rgba(255, 255, 255, 0.72);
  --surface-strong: rgba(255, 255, 255, 0.9);
  --surface-soft: rgba(255, 255, 255, 0.58);
  --text: #162338;
  --text-dim: #4d5d72;
  --line: rgba(22, 35, 56, 0.14);
  --line-strong: rgba(22, 35, 56, 0.24);
  --primary: #0f5f53;
  --primary-strong: #0a4a40;
  --accent: #d96d2d;
  --accent-soft: #f7c36d;
  --accent-mix: rgba(217, 109, 45, 0.2);
  --shadow-lg: 0 28px 70px rgba(8, 20, 33, 0.16);
  --shadow-md: 0 14px 34px rgba(10, 22, 35, 0.11);
  --radius-lg: 26px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --text-base: clamp(0.98rem, 0.28vw + 0.92rem, 1.06rem);
  --leading-base: 1.7;
  --leading-tight: 1.14;
  --section-pad: clamp(3.8rem, 7.8vw, 5.2rem);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

::selection {
  background: rgba(15, 95, 83, 0.2);
  color: var(--text);
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 14% -8%, #ffe7b8 0%, rgba(255, 231, 184, 0) 40%),
    radial-gradient(circle at 92% 14%, #d7efe6 0%, rgba(215, 239, 230, 0) 43%),
    linear-gradient(145deg, var(--bg) 0%, #f2efe6 52%, var(--bg-alt) 100%);
  font-family: "Manrope", "Segoe UI", sans-serif;
  font-size: var(--text-base);
  line-height: var(--leading-base);
  overflow-x: hidden;
}

main {
  position: relative;
}

main > section.section:not(.hero) {
  position: relative;
  isolation: isolate;
  --section-ink: var(--primary);
  --section-accent: var(--accent);
  --section-glow-a: rgba(15, 95, 83, 0.14);
  --section-glow-b: rgba(217, 109, 45, 0.12);
}

main > section.section:not(.hero)::before {
  content: "";
  position: absolute;
  inset: 1.2rem -0.35rem;
  border-radius: 24px;
  border: 1px solid rgba(22, 35, 56, 0.1);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.44), rgba(255, 255, 255, 0.12)),
    radial-gradient(circle at 12% 0%, var(--section-glow-a), rgba(15, 95, 83, 0) 52%),
    radial-gradient(circle at 100% 0%, var(--section-glow-b), rgba(217, 109, 45, 0) 56%);
  box-shadow: 0 12px 30px rgba(7, 18, 30, 0.07);
  z-index: -1;
}

main > section.section:not(.hero)::after {
  content: "";
  position: absolute;
  left: 1.1rem;
  top: 1.2rem;
  width: min(160px, 36%);
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--section-ink), var(--section-accent));
  opacity: 0.85;
  z-index: -1;
}

#about {
  --section-ink: #0f5f53;
  --section-accent: #d96d2d;
  --section-glow-a: rgba(15, 95, 83, 0.16);
  --section-glow-b: rgba(217, 109, 45, 0.14);
}

#skills {
  --section-ink: #0b5679;
  --section-accent: #0f7f75;
  --section-glow-a: rgba(11, 86, 121, 0.15);
  --section-glow-b: rgba(15, 127, 117, 0.12);
}

#experience {
  --section-ink: #80521c;
  --section-accent: #0f5f53;
  --section-glow-a: rgba(128, 82, 28, 0.15);
  --section-glow-b: rgba(15, 95, 83, 0.12);
}

#projects {
  --section-ink: #214276;
  --section-accent: #d96d2d;
  --section-glow-a: rgba(33, 66, 118, 0.15);
  --section-glow-b: rgba(217, 109, 45, 0.12);
}

#education {
  --section-ink: #48408b;
  --section-accent: #0f5f53;
  --section-glow-a: rgba(72, 64, 139, 0.14);
  --section-glow-b: rgba(15, 95, 83, 0.12);
}

#contact {
  --section-ink: #7a3f52;
  --section-accent: #0f5f53;
  --section-glow-a: rgba(122, 63, 82, 0.15);
  --section-glow-b: rgba(15, 95, 83, 0.12);
}

body::before {
  content: "";
  pointer-events: none;
  position: fixed;
  inset: 0;
  background-image: radial-gradient(rgba(22, 35, 56, 0.07) 0.7px, transparent 0.7px);
  background-size: 3px 3px;
  opacity: 0.18;
  z-index: -2;
}

h1,
h2,
h3,
.brand {
  font-family: "Sora", "Trebuchet MS", sans-serif;
  line-height: var(--leading-tight);
  margin: 0;
  letter-spacing: -0.012em;
}

p {
  margin: 0;
}

a {
  color: inherit;
}

.page-bg {
  pointer-events: none;
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: -1;
}

.orb {
  --parallax-x: 0px;
  --parallax-y: 0px;
  position: absolute;
  border-radius: 999px;
  filter: blur(46px);
  opacity: 0.4;
  animation: drift 12s ease-in-out infinite;
  will-change: transform;
}

.orb-one {
  width: 360px;
  height: 360px;
  top: -120px;
  left: -70px;
  background: #ffc08a;
}

.orb-two {
  width: 390px;
  height: 390px;
  right: -110px;
  top: 16%;
  background: #7dc5b1;
  animation-delay: 2.2s;
}

.orb-three {
  width: 430px;
  height: 430px;
  left: 23%;
  bottom: -220px;
  background: #f1a27b;
  animation-delay: 4.6s;
}

@keyframes drift {
  0%,
  100% {
    transform: translate3d(var(--parallax-x), var(--parallax-y), 0);
  }

  50% {
    transform: translate3d(calc(var(--parallax-x) + 26px), calc(var(--parallax-y) - 20px), 0);
  }
}

.container {
  width: min(1120px, calc(100% - clamp(1rem, 4vw, 2.4rem)));
  margin-inline: auto;
}

.section {
  padding: var(--section-pad) 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(12px);
  background: linear-gradient(180deg, rgba(247, 242, 232, 0.94), rgba(247, 242, 232, 0.76));
  border-bottom: 1px solid var(--line);
}

.site-header::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: var(--scroll-progress, 0%);
  background: linear-gradient(90deg, var(--primary), var(--accent));
  box-shadow: 0 0 10px rgba(15, 95, 83, 0.35);
}

.site-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(217, 109, 45, 0.55) 50%, transparent 100%);
}

.nav-wrap {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.2rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.48rem;
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.brand::before {
  content: "";
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 0 0 4px rgba(15, 95, 83, 0.14);
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.95rem;
}

.nav a {
  text-decoration: none;
  font-weight: 600;
  color: var(--text-dim);
  padding: 0.46rem 0.82rem;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 0.2s ease, color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.nav a.is-active {
  color: var(--text);
  background: linear-gradient(130deg, rgba(15, 95, 83, 0.16), rgba(217, 109, 45, 0.14));
  border-color: rgba(15, 95, 83, 0.24);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.4);
}

.nav a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.72);
  border-color: var(--line);
  transform: translateY(-1px);
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.45rem 0.7rem;
  background: rgba(255, 255, 255, 0.86);
  color: var(--text);
  font-family: "Manrope", sans-serif;
  font-weight: 600;
  cursor: pointer;
}

.hero {
  display: grid;
  grid-template-columns: 1.16fr 0.84fr;
  gap: clamp(1.25rem, 2.2vw, 1.7rem);
  align-items: stretch;
}

.hero-content,
.hero-card {
  --spot-x: 50%;
  --spot-y: 50%;
  position: relative;
  border: 1px solid var(--line);
  background: linear-gradient(165deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.6));
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: clamp(1.35rem, 2.3vw, 2.05rem);
  overflow: hidden;
  min-width: 0;
}

.hero-content::before,
.hero-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(130deg, rgba(255, 255, 255, 0.38), rgba(255, 255, 255, 0));
  pointer-events: none;
}

.hero-content::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle at var(--spot-x) var(--spot-y), rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0) 48%);
  opacity: 0.92;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.87rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--primary);
}

.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: currentColor;
}

.hero h1 {
  margin-top: 0.9rem;
  font-size: clamp(2rem, 4.2vw, 3.42rem);
  max-width: 15ch;
  color: var(--text);
  background: linear-gradient(120deg, #14253b 10%, #0f5f53 62%, #b25729 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-text {
  margin-top: 1.08rem;
  line-height: 1.75;
  color: var(--text-dim);
  max-width: 56ch;
}

.hero-meta {
  margin-top: 1.45rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.62rem;
}

.hero-meta span,
.hero-meta a {
  border: 1px solid rgba(15, 95, 83, 0.18);
  background: rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  padding: 0.35rem 0.68rem;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
}

.hero-meta a {
  color: var(--primary-strong);
  overflow-wrap: anywhere;
}

.hero-actions {
  margin-top: 1.55rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-weight: 700;
  border-radius: 999px;
  padding: 0.7rem 1.18rem;
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn::after {
  content: "";
  position: absolute;
  width: 44%;
  height: 320%;
  left: -120%;
  top: -115%;
  transform: rotate(24deg);
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0));
  pointer-events: none;
  transition: left 0.58s ease;
}

.btn:hover::after {
  left: 145%;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, #18806f 100%);
  color: #fff;
  box-shadow: 0 12px 24px rgba(15, 95, 83, 0.24);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 26px rgba(15, 95, 83, 0.3);
}

.btn-outline {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.76);
}

.btn-outline:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
}

.hero-card h2 {
  font-size: 1.34rem;
  line-height: 1.22;
}

.hero-card ul {
  list-style: none;
  margin: 1.05rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.8rem;
}

.hero-card li {
  position: relative;
  border: 1px solid rgba(15, 95, 83, 0.18);
  background: rgba(255, 255, 255, 0.62);
  border-radius: var(--radius-sm);
  padding: 0.72rem 0.8rem 0.72rem 2rem;
  line-height: 1.58;
  color: var(--text-dim);
}

.hero-card li::before {
  content: "";
  position: absolute;
  left: 0.74rem;
  top: 50%;
  width: 0.72rem;
  height: 0.72rem;
  border-radius: 50%;
  transform: translateY(-50%);
  background: linear-gradient(135deg, var(--accent-soft), var(--accent));
  box-shadow: 0 0 0 4px rgba(217, 109, 45, 0.16);
}

.hero-card strong {
  color: var(--text);
  display: inline-flex;
  align-items: center;
  font-variant-numeric: tabular-nums;
}

.hero-card strong[data-count-to] {
  min-width: 7.5ch;
}

.section-title {
  position: relative;
}

.section-title p {
  margin: 0;
  color: var(--section-ink, var(--primary));
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.8rem;
}

.section-title h2 {
  margin-top: 0.5rem;
  font-size: clamp(1.56rem, 3.8vw, 2.46rem);
  line-height: 1.2;
  max-width: 22ch;
}

.section-title::after {
  content: "";
  display: block;
  width: 92px;
  height: 3px;
  margin-top: 0.94rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--section-ink, var(--primary)), var(--section-accent, var(--accent)));
}

.lead {
  margin-top: 1.2rem;
  max-width: 72ch;
  line-height: 1.78;
  color: var(--text-dim);
}

.social-grid {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.05rem;
}

.social-grid a {
  text-decoration: none;
  padding: 1.05rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: var(--surface);
  font-weight: 700;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.social-grid a::after {
  content: ">";
  font-size: 0.95rem;
  color: var(--text-dim);
}

.social-grid a:hover {
  transform: translateY(-4px);
  border-color: rgba(15, 95, 83, 0.34);
  box-shadow: var(--shadow-md);
}

.skills-grid,
.projects-grid,
.education-grid,
.contact-grid {
  margin-top: 1.5rem;
  display: grid;
  gap: 1.05rem;
}

.skills-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.tile,
.project-card,
.edu-card,
.contact-card,
.timeline-item {
  position: relative;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  min-width: 0;
}

.tile,
.project-card,
.edu-card,
.contact-card {
  padding: 1.28rem;
}

.tile::before,
.project-card::before,
.edu-card::before,
.contact-card::before,
.timeline-item::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  border: 1px solid transparent;
  background: linear-gradient(130deg, rgba(255, 255, 255, 0.48), rgba(255, 255, 255, 0)) border-box;
  pointer-events: none;
}

.tile h3,
.project-card h3,
.edu-card h3,
.contact-card h3 {
  font-size: 1.1rem;
  line-height: 1.3;
}

.skills-grid .tile h3 {
  display: flex;
  align-items: center;
  gap: 0.52rem;
}

.skills-grid .tile h3::before {
  content: "";
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  flex: 0 0 auto;
  background: linear-gradient(135deg, var(--section-ink, var(--primary)), var(--section-accent, var(--accent)));
  box-shadow: 0 0 0 4px rgba(15, 95, 83, 0.14);
}

.skills-grid .tile:nth-child(2n) h3::before {
  background: linear-gradient(135deg, #0b5679, #0f7f75);
}

.skills-grid .tile:nth-child(3n) h3::before {
  background: linear-gradient(135deg, #214276, #7a3f52);
}

.tile p,
.project-card p,
.edu-card p,
.contact-card p {
  margin-top: 0.58rem;
  line-height: 1.68;
  color: var(--text-dim);
}

.tile,
.edu-card,
.contact-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tile:hover,
.edu-card:hover,
.contact-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 34px rgba(10, 22, 35, 0.14);
}

.timeline {
  margin-top: 1.5rem;
  display: grid;
  gap: 1.05rem;
  position: relative;
  padding-left: 1rem;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 0.6rem;
  bottom: 0.6rem;
  left: 0.22rem;
  width: 2px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--accent), rgba(15, 95, 83, 0.5));
}

.timeline-item {
  padding: 1.3rem 1.28rem 1.28rem 1.45rem;
}

.timeline-item::after {
  content: "";
  position: absolute;
  left: -0.88rem;
  top: 1.36rem;
  width: 0.8rem;
  height: 0.8rem;
  border-radius: 50%;
  background: var(--surface-strong);
  border: 2px solid var(--primary);
  box-shadow: 0 0 0 4px rgba(15, 95, 83, 0.14);
}

.timeline-item header h3 {
  font-size: 1.15rem;
}

.timeline-item header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.34rem 0.8rem;
  align-items: start;
}

.timeline-item header p {
  grid-column: 1 / 2;
  margin-top: 0.26rem;
  font-weight: 700;
}

.timeline-item header span {
  grid-column: 2 / 3;
  grid-row: 1 / 3;
  align-self: start;
  color: var(--text-dim);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.36rem 0.55rem;
  border-radius: 999px;
  border: 1px solid rgba(22, 35, 56, 0.14);
  background: rgba(255, 255, 255, 0.68);
}

.timeline-item ul {
  margin: 0.86rem 0 0;
  padding-left: 1.05rem;
  color: var(--text-dim);
}

.timeline-item li + li {
  margin-top: 0.56rem;
}

.timeline-item li {
  line-height: 1.66;
}

.project-card h3,
.project-card p,
.contact-card a,
.timeline-item li {
  overflow-wrap: anywhere;
}

.project-card h3 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
}

.project-card[data-url] h3::after {
  content: "->";
  color: var(--accent);
  font-weight: 800;
  transform: translateY(1px);
  transition: transform 0.18s ease;
}

.projects-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.projects-grid .project-card[data-url] {
  cursor: pointer;
  overflow: hidden;
  transform-style: preserve-3d;
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  --glare-x: 50%;
  --glare-y: 50%;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.projects-grid .project-card[data-url]::before {
  z-index: 1;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.46), rgba(255, 255, 255, 0)) border-box;
}

.projects-grid .project-card[data-url]::after {
  content: "";
  position: absolute;
  inset: -35%;
  background: radial-gradient(
    circle at var(--glare-x) var(--glare-y),
    rgba(255, 255, 255, 0.52) 0%,
    rgba(255, 255, 255, 0) 58%
  );
  opacity: 0;
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.22s ease;
}

.projects-grid .project-card[data-url] .project-preview {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-color: rgba(17, 34, 56, 0.92);
  background-position: top center;
  background-size: cover;
  background-repeat: no-repeat;
  opacity: 0;
  transform: scale(1.08);
  filter: saturate(1.05) contrast(1.05);
  transition: opacity 0.28s ease, transform 0.42s ease;
}

.projects-grid .project-card[data-url] .project-preview::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 18, 32, 0.34), rgba(10, 18, 32, 0.88)),
    linear-gradient(130deg, rgba(10, 18, 32, 0.2), rgba(10, 18, 32, 0));
}

.projects-grid .project-card[data-url] h3,
.projects-grid .project-card[data-url] p,
.projects-grid .project-card[data-url] .tags {
  position: relative;
  z-index: 2;
  transition: color 0.2s ease, text-shadow 0.2s ease;
}

.projects-grid .project-card[data-url] .project-cta {
  position: absolute;
  right: 0.86rem;
  bottom: 0.82rem;
  z-index: 3;
  pointer-events: none;
  font-size: 0.73rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 800;
  color: #f7fbff;
  background: rgba(8, 18, 31, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 999px;
  padding: 0.34rem 0.58rem;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.projects-grid .project-card[data-url]:hover {
  transform: perspective(960px) translateY(-8px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  box-shadow: 0 20px 38px rgba(16, 25, 37, 0.15);
  border-color: rgba(15, 95, 83, 0.3);
}

.projects-grid .project-card[data-url]:hover .project-preview,
.projects-grid .project-card[data-url]:focus-visible .project-preview {
  opacity: 1;
  transform: scale(1);
}

.projects-grid .project-card[data-url]:hover .project-cta,
.projects-grid .project-card[data-url]:focus-visible .project-cta {
  opacity: 1;
  transform: translateY(0);
}

.projects-grid .project-card[data-url]:hover h3,
.projects-grid .project-card[data-url]:hover p,
.projects-grid .project-card[data-url]:focus-visible h3,
.projects-grid .project-card[data-url]:focus-visible p {
  color: #f7fbff;
  text-shadow: 0 2px 12px rgba(6, 10, 18, 0.38);
}

.projects-grid .project-card[data-url]:hover .tags span,
.projects-grid .project-card[data-url]:focus-visible .tags span {
  color: #eff7ff;
  border-color: rgba(255, 255, 255, 0.42);
  background: rgba(10, 18, 32, 0.56);
}

.projects-grid .project-card[data-url]:hover h3::after,
.projects-grid .project-card[data-url]:focus-visible h3::after {
  color: #ffd9b7;
}

.projects-grid .project-card[data-url]:hover h3::after {
  transform: translate(4px, 1px);
}

.projects-grid .project-card[data-url]:hover::after {
  opacity: 1;
}

.projects-grid .project-card[data-url]:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.tags {
  margin-top: 0.92rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tags span {
  font-size: 0.77rem;
  font-weight: 700;
  border: 1px solid rgba(10, 74, 64, 0.24);
  color: var(--primary-strong);
  background: linear-gradient(180deg, rgba(15, 95, 83, 0.12), rgba(15, 95, 83, 0.08));
  border-radius: 999px;
  padding: 0.25rem 0.62rem;
}

.education-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.edu-card span,
.edu-card strong {
  display: block;
  margin-top: 0.4rem;
}

.contact-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.contact-card a {
  color: var(--primary-strong);
  display: block;
  margin-top: 0.5rem;
  font-weight: 700;
  text-decoration: none;
}

.contact-card a:hover {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(247, 242, 232, 0.8), rgba(232, 241, 236, 0.7));
  padding: 1.45rem 0;
  color: var(--text-dim);
}

.site-footer p {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(22, 35, 56, 0.1);
  background: rgba(255, 255, 255, 0.5);
}

.floating-actions {
  position: fixed;
  right: 1rem;
  bottom: 1.1rem;
  z-index: 80;
  display: grid;
  gap: 0.64rem;
}

.floating-actions .float-btn {
  position: relative;
  width: 3.35rem;
  height: 3.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #ffffff;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  padding: 0;
  box-shadow: 0 12px 24px rgba(6, 14, 24, 0.24);
  backdrop-filter: blur(7px);
  isolation: isolate;
  overflow: visible;
  animation: float-breathe 2.4s ease-in-out infinite;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.floating-actions .float-btn::before {
  content: "";
  position: absolute;
  inset: -0.5rem;
  border-radius: inherit;
  border: 2px solid currentColor;
  opacity: 0.34;
  z-index: -2;
  animation: float-pulse 2s ease-out infinite;
}

.floating-actions .float-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(130deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0));
  z-index: -1;
}

.floating-actions .float-btn:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 14px 30px rgba(6, 14, 24, 0.3);
}

.floating-actions .float-icon {
  width: 1.38rem;
  height: 1.38rem;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.95;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.floating-actions .float-label {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.floating-actions .float-btn:focus-visible {
  outline: 3px solid rgba(255, 255, 255, 0.9);
  outline-offset: 2px;
}

.floating-actions .float-call {
  color: #d8f4ff;
  background: linear-gradient(135deg, #1d4f8f, #173864);
}

.floating-actions .float-whatsapp {
  color: #d9ffe8;
  background: linear-gradient(135deg, #158a4f, #0f6d3f);
  animation-delay: 0.35s;
}

.floating-actions .float-whatsapp::before {
  animation-delay: 0.7s;
}

.floating-actions .float-call::before {
  animation-delay: 0.1s;
}

@keyframes float-pulse {
  0% {
    transform: scale(0.86);
    opacity: 0.42;
  }

  75% {
    transform: scale(1.24);
    opacity: 0;
  }

  100% {
    transform: scale(1.24);
    opacity: 0;
  }
}

@keyframes float-breathe {
  0%,
  100% {
    box-shadow: 0 10px 22px rgba(6, 14, 24, 0.22);
    transform: translateY(0);
  }

  50% {
    box-shadow: 0 16px 30px rgba(6, 14, 24, 0.3);
    transform: translateY(-1px);
  }
}

[data-reveal] {
  opacity: 0;
  transform: translateY(18px) scale(0.992);
  transition: opacity 0.55s ease, transform 0.55s ease;
  transition-delay: var(--delay, 0ms);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

@media (max-width: 980px) {
  .section {
    padding: 4.2rem 0;
  }

  .hero-content,
  .hero-card {
    padding: 1.68rem;
  }

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

  .hero-text {
    max-width: 60ch;
  }

  .lead {
    max-width: 74ch;
  }

  .skills-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  body {
    line-height: 1.66;
  }

  main > section.section:not(.hero)::before {
    inset: 0.9rem -0.1rem;
  }

  main > section.section:not(.hero)::after {
    left: 0.8rem;
    top: 0.95rem;
    width: min(140px, 42%);
  }

  .nav-wrap {
    position: relative;
  }

  .brand {
    font-size: clamp(1rem, 4.5vw, 1.2rem);
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav {
    position: absolute;
    left: 0.68rem;
    right: 0.68rem;
    top: calc(100% + 0.45rem);
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    padding: 0.55rem;
    display: none;
    flex-direction: column;
    align-items: stretch;
    box-shadow: var(--shadow-lg);
  }

  .nav a {
    text-align: center;
    font-size: 0.95rem;
  }

  .nav-wrap.open .nav {
    display: flex;
  }

  .hero-actions .btn {
    flex: 1 1 100%;
  }

  .hero-actions {
    gap: 0.68rem;
  }

  .hero-meta span,
  .hero-meta a {
    padding: 0.32rem 0.62rem;
  }

  .timeline {
    padding-left: 0;
  }

  .timeline::before,
  .timeline-item::after {
    display: none;
  }

  .timeline-item {
    padding: 1.1rem;
  }

  .timeline-item header {
    grid-template-columns: 1fr;
    gap: 0.28rem;
  }

  .timeline-item header span {
    grid-column: 1 / 2;
    grid-row: auto;
    justify-self: start;
    margin-top: 0.28rem;
    font-size: 0.76rem;
  }

  .social-grid,
  .skills-grid,
  .projects-grid,
  .education-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 3.7rem 0;
  }

  .projects-grid .project-card[data-url] .project-cta {
    right: 0.75rem;
    bottom: 0.72rem;
    font-size: 0.68rem;
    padding: 0.3rem 0.54rem;
  }

  .floating-actions {
    right: 0.8rem;
    bottom: 0.9rem;
    gap: 0.58rem;
  }

  .floating-actions .float-btn {
    width: 3rem;
    height: 3rem;
  }

  .floating-actions .float-icon {
    width: 1.22rem;
    height: 1.22rem;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 0.97rem;
    line-height: 1.64;
  }

  main > section.section:not(.hero)::before {
    inset: 0.65rem 0;
  }

  main > section.section:not(.hero)::after {
    left: 0.7rem;
    top: 0.78rem;
    width: min(120px, 44%);
  }

  .brand {
    max-width: calc(100% - 6.5rem);
    letter-spacing: 0.005em;
  }

  .brand::before {
    width: 0.54rem;
    height: 0.54rem;
    box-shadow: 0 0 0 3px rgba(15, 95, 83, 0.14);
  }

  .nav-toggle {
    padding: 0.4rem 0.65rem;
    font-size: 0.9rem;
  }

  .nav {
    left: 0;
    right: 0;
  }

  .hero-content,
  .hero-card,
  .tile,
  .project-card,
  .edu-card,
  .contact-card,
  .timeline-item {
    padding: 0.96rem;
  }

  .hero-meta {
    gap: 0.55rem;
    font-size: 0.95rem;
  }

  .hero-meta span,
  .hero-meta a {
    font-size: 0.86rem;
    padding: 0.3rem 0.58rem;
  }

  .hero h1 {
    font-size: clamp(1.64rem, 8vw, 2rem);
  }

  .hero-text {
    line-height: 1.7;
  }

  .section-title p {
    letter-spacing: 0.09em;
    font-size: 0.75rem;
  }

  .section-title h2 {
    max-width: 20ch;
  }

  .section {
    padding: 3rem 0;
  }

  .tags span {
    font-size: 0.74rem;
  }

  .projects-grid .project-card[data-url] .project-cta {
    right: 0.7rem;
    bottom: 0.66rem;
    font-size: 0.64rem;
  }

  .floating-actions {
    right: 0.65rem;
    bottom: 0.78rem;
    gap: 0.48rem;
  }

  .floating-actions .float-btn {
    width: 2.76rem;
    height: 2.76rem;
  }

  .floating-actions .float-icon {
    width: 1.12rem;
    height: 1.12rem;
  }
}

@media (hover: none) {
  .projects-grid .project-card[data-url]::after {
    display: none;
  }

  .projects-grid .project-card[data-url]:hover {
    transform: translateY(-4px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
