:root {
  --bg: #090f1f;
  --bg-soft: #131c34;
  --surface: rgba(11, 18, 35, 0.82);
  --text: #e7f2ff;
  --muted: #9bb2cf;
  --accent: #2de2b0;
  --accent-2: #ffb84d;
  --line: rgba(157, 183, 213, 0.32);
  --shadow: 0 12px 35px rgba(4, 8, 16, 0.45);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  font-family: "Barlow", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 15% -15%, #1a2b57 0%, transparent 42%),
    radial-gradient(circle at 90% 0%, #224977 0%, transparent 40%),
    linear-gradient(140deg, #090f1f 0%, #101a31 52%, #131926 100%);
  overflow-x: hidden;
}

.fx-grid {
  position: fixed;
  inset: 0;
  z-index: -3;
  background-image:
    linear-gradient(rgba(63, 97, 140, 0.2) 1px, transparent 1px),
    linear-gradient(90deg, rgba(63, 97, 140, 0.2) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: radial-gradient(circle at center, black 50%, transparent 95%);
  pointer-events: none;
}

.fx-glow {
  position: fixed;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  filter: blur(85px);
  z-index: -2;
  opacity: 0.38;
  pointer-events: none;
}

.fx-left {
  top: -120px;
  left: -100px;
  background: #2de2b0;
}

.fx-right {
  bottom: -130px;
  right: -90px;
  background: #2d93e2;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  max-width: 1120px;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(157, 183, 213, 0.23);
  background: rgba(8, 13, 27, 0.72);
  backdrop-filter: blur(10px);
}

.logo {
  font-family: "Audiowide", sans-serif;
  letter-spacing: 0.07em;
  text-decoration: none;
  color: var(--text);
  font-size: 1.1rem;
}

.logo span {
  color: var(--accent);
}

.site-nav {
  display: flex;
  gap: 1rem;
}

.site-nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.site-nav a:hover {
  color: var(--accent);
}

.menu-toggle {
  display: none;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(14, 26, 50, 0.92);
  color: var(--text);
  padding: 0.42rem 0.8rem;
}

main {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.4rem 1rem 4rem;
}

section {
  margin: 4.2rem 0;
}

h1,
h2,
h3 {
  margin-top: 0;
}

h1,
h2 {
  font-family: "Audiowide", sans-serif;
  letter-spacing: 0.02em;
}

h1 {
  font-size: clamp(2.15rem, 5.5vw, 4.2rem);
  line-height: 1.08;
  max-width: 14ch;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2.35rem);
}

.hero {
  min-height: 76vh;
  display: grid;
  align-content: center;
  gap: 0.9rem;
}

.profile-banner {
  border: 1px solid rgba(215, 196, 166, 0.35);
  border-radius: 24px;
  background: radial-gradient(circle at 8% 8%, rgba(255, 230, 196, 0.08), transparent 40%),
    linear-gradient(140deg, rgba(12, 17, 28, 0.98) 0%, rgba(8, 13, 24, 0.98) 100%);
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.4);
  padding: 1.4rem;
  display: grid;
  grid-template-columns: 1.9fr 1fr;
  gap: 1rem;
  align-items: center;
}

.profile-banner__text h1 {
  margin: 0.32rem 0 0.72rem;
  max-width: 30ch;
  font-family: "Barlow", "Segoe UI", sans-serif;
  font-size: clamp(1.35rem, 2.15vw, 1.95rem);
  line-height: 1.22;
  letter-spacing: 0.01em;
  font-weight: 650;
}

.profile-banner .eyebrow {
  color: #dac29e;
  font-size: 1.32rem;
  letter-spacing: 0.08em;
  font-weight: 700;
}

.profile-banner .hero-text {
  font-size: 0.95rem;
  line-height: 1.6;
  max-width: 64ch;
}

.profile-banner__meta {
  margin-top: 1.05rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.profile-banner__meta span {
  border: 1px solid rgba(215, 196, 166, 0.32);
  border-radius: 999px;
  padding: 0.25rem 0.62rem;
  font-size: 0.82rem;
  color: #d6e8ff;
  background: rgba(26, 34, 51, 0.72);
}

.profile-banner__photo-wrap {
  justify-self: end;
  width: min(320px, 100%);
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  border: 2px solid rgba(215, 196, 166, 0.45);
  padding: 0.35rem;
  background: radial-gradient(circle at 35% 25%, rgba(33, 47, 77, 0.92), rgba(8, 13, 24, 0.95));
}

.profile-banner__photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
  border-radius: 50%;
}

.eyebrow {
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  color: var(--accent-2);
  margin-bottom: 0;
}

.hero-text,
.about p,
.project-card p,
.timeline li,
.contact p,
.signal-card p,
.arsenal-grid span {
  color: var(--muted);
  line-height: 1.65;
  font-size: 1.04rem;
}

.accent {
  color: var(--accent);
  font-weight: 700;
}

.hero-actions,
.contact-grid {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  margin-top: 0.6rem;
}

.btn {
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 0.7rem 1.15rem;
  border: 1px solid transparent;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(26, 52, 92, 0.3);
}

.btn-primary {
  background: linear-gradient(120deg, #1ec896, #23b9d8);
  color: #021319;
}

.btn-ghost {
  border-color: var(--line);
  color: var(--text);
  background: rgba(17, 26, 46, 0.84);
}

.mission-stats {
  margin: 1.6rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.8rem;
}

.mission-stats li {
  background: rgba(16, 29, 54, 0.74);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.9rem;
}

.mission-stats strong {
  display: block;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 0.3rem;
}

.mission-stats span {
  color: var(--text);
}

.panel {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--surface);
  box-shadow: var(--shadow);
  padding: 1.5rem;
}

.about {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1.1rem;
}

.signal-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(20, 32, 58, 0.85);
  padding: 1rem;
}

.signal-card h3 {
  font-size: 1.03rem;
  margin-bottom: 0.35rem;
  color: var(--accent-2);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.9rem;
  flex-wrap: wrap;
}

.filters {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.filter {
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(14, 24, 43, 0.9);
  color: var(--muted);
  padding: 0.42rem 0.8rem;
  font-weight: 600;
  cursor: pointer;
}

.filter.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #04231b;
}

.project-grid {
  margin-top: 1.3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(235px, 1fr));
  gap: 1rem;
}

.project-card {
  position: relative;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(20, 33, 60, 0.92), rgba(13, 21, 38, 0.94));
  padding: 1.05rem 1.05rem 1.65rem;
  box-shadow: var(--shadow);
  transition: transform 0.18s ease, border-color 0.2s ease;
  cursor: pointer;
}

.project-card:hover {
  transform: translateY(-4px);
  border-color: rgba(45, 226, 176, 0.62);
}

.project-card:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.card-label {
  margin: 0 0 0.45rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-size: 0.72rem;
  color: var(--accent-2);
}

.project-card h3 {
  margin-bottom: 0.6rem;
  font-size: 1.18rem;
}

.project-status {
  display: inline-block;
  margin-left: 0.5rem;
  padding: 0.14rem 0.52rem;
  border: 1px solid rgba(255, 184, 77, 0.55);
  border-radius: 999px;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--accent-2);
  vertical-align: middle;
}

.tags {
  margin-top: 0.8rem;
  display: flex;
  gap: 0.42rem;
  flex-wrap: wrap;
}

.tags span {
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: #d5e6ff;
  font-size: 0.82rem;
}

.card-cta {
  position: absolute;
  right: 0.8rem;
  bottom: -0.6rem;
  margin: 0;
  padding: 0.18rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(10, 18, 33, 0.95);
  font-size: 0.68rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
}

.arsenal-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 0.8rem;
}

.arsenal-grid li {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(17, 28, 51, 0.8);
  padding: 0.85rem;
}

.arsenal-grid strong {
  display: block;
  margin-bottom: 0.3rem;
  color: var(--accent);
  text-transform: uppercase;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
}

.timeline ol {
  margin: 1rem 0 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.7rem;
}

.timeline li strong {
  color: var(--accent-2);
}

.site-footer {
  text-align: center;
  padding: 1.4rem 1rem 2rem;
  color: var(--muted);
  border-top: 1px solid rgba(157, 183, 213, 0.2);
}

.project-modal {
  position: fixed;
  inset: 0;
  display: none;
  z-index: 70;
}

.project-modal.open {
  display: block;
}

.project-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 8, 16, 0.78);
  backdrop-filter: blur(5px);
}

.project-modal__panel {
  position: relative;
  width: min(900px, calc(100% - 1.2rem));
  max-height: 88vh;
  overflow: auto;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: rgba(45, 226, 176, 0.75) rgba(10, 18, 33, 0.8);
  margin: 5vh auto 0;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(16, 27, 50, 0.98), rgba(9, 16, 31, 0.98));
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.55);
  padding: 3.2rem 1.3rem 1.3rem;
}

.project-modal__panel::-webkit-scrollbar {
  width: 11px;
}

.project-modal__panel::-webkit-scrollbar-track {
  background: rgba(10, 18, 33, 0.8);
  border-left: 1px solid rgba(157, 183, 213, 0.15);
}

.project-modal__panel::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(45, 226, 176, 0.85), rgba(35, 185, 216, 0.8));
  border-radius: 999px;
  border: 2px solid rgba(10, 18, 33, 0.85);
}

.project-modal__panel::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, rgba(45, 226, 176, 1), rgba(35, 185, 216, 0.95));
}

.project-modal__close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  width: 2.25rem;
  height: 2.25rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: radial-gradient(circle at 30% 25%, rgba(33, 56, 97, 0.95), rgba(10, 17, 33, 0.95));
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.38);
  transition: transform 0.16s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.project-modal__close:hover {
  transform: translateY(-1px);
  border-color: rgba(45, 226, 176, 0.65);
  background: radial-gradient(circle at 30% 25%, rgba(38, 65, 114, 1), rgba(13, 22, 42, 1));
}

.project-modal__close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.project-modal__label {
  margin: 0.6rem 0 0.4rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.76rem;
  color: var(--accent-2);
}

.project-modal h3 {
  margin-bottom: 0.5rem;
  font-size: clamp(1.3rem, 2.5vw, 1.9rem);
}

.project-modal p,
.project-modal li {
  color: var(--muted);
}

.project-modal__media {
  margin-top: 1rem;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(20, 32, 58, 0.72);
  padding: 0.8rem;
}

.project-modal__media video {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #040b16;
}

.project-modal__gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.6rem;
  margin-top: 0.7rem;
}

.project-modal__gallery-item {
  margin: 0;
}

.project-modal__gallery-item img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #081326;
}

.project-modal__gallery-item figcaption {
  margin-top: 0.35rem;
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-transform: uppercase;
}

.project-modal__meta {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.7rem;
}

.project-modal__meta article,
.project-modal__skills,
.project-modal__contrib {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(20, 32, 58, 0.72);
  padding: 0.8rem;
}

.project-modal h4 {
  margin: 0 0 0.5rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.82rem;
}

.project-modal__skills {
  margin-top: 0.9rem;
}

.project-modal__skills ul {
  margin: 0;
  padding-left: 1.05rem;
  display: grid;
  gap: 0.25rem;
}

.project-modal__contrib {
  margin-top: 0.9rem;
}

.project-contrib-section + .project-contrib-section {
  margin-top: 0.8rem;
}

.project-contrib-section h5 {
  margin: 0 0 0.4rem;
  font-size: 0.96rem;
  color: #d7e9ff;
}

.project-contrib-section ul {
  margin: 0;
  padding-left: 1.05rem;
  display: grid;
  gap: 0.24rem;
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
}

.reveal-visible {
  animation: riseIn 0.72s ease forwards;
}

@keyframes riseIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 850px) {
  .menu-toggle {
    display: inline-block;
  }

  .site-nav {
    display: none;
    position: absolute;
    right: 1rem;
    top: 4.1rem;
    min-width: 190px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(10, 16, 30, 0.95);
    padding: 0.6rem;
    flex-direction: column;
  }

  .site-nav.open {
    display: flex;
  }

  .about {
    grid-template-columns: 1fr;
  }

  .profile-banner {
    grid-template-columns: 1fr;
  }

  .profile-banner__photo-wrap {
    justify-self: center;
    width: min(270px, 78vw);
  }

  .profile-banner__text h1 {
    font-size: clamp(1.2rem, 4.8vw, 1.6rem);
  }

  .profile-banner .eyebrow {
    font-size: 1.08rem;
  }
}

@media (max-width: 640px) {
  section {
    margin: 3.6rem 0;
  }

  .panel {
    padding: 1.1rem;
  }

  .project-modal__panel {
    margin-top: 3.5vh;
    padding: 2.9rem 1rem 1rem;
  }
}
