:root {
  color-scheme: dark;
  --bg: #06101d;
  --bg-deep: #030a13;
  --surface: #0d1b2d;
  --surface-soft: rgba(15, 31, 51, 0.72);
  --surface-light: #13243a;
  --line: rgba(148, 163, 184, 0.16);
  --line-strong: rgba(148, 163, 184, 0.28);
  --text: #f7f9fc;
  --muted: #9bacbf;
  --blue: #55a8ff;
  --blue-strong: #268cff;
  --green: #3ee0b3;
  --violet: #a58cff;
  --danger: #ff7d8e;
  --container: 1200px;
  --header-height: 76px;
  --radius-large: 28px;
  --radius-medium: 20px;
  --radius-small: 12px;
  --shadow: 0 32px 90px rgba(0, 0, 0, 0.34);
  --font-sans: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "Fira Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 24px);
}

body {
  min-width: 320px;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 10% 5%, rgba(38, 140, 255, 0.08), transparent 32rem),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-deep) 100%);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

::selection {
  background: rgba(85, 168, 255, 0.34);
  color: white;
}

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

button,
input,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

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

[hidden] {
  display: none !important;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 28px;
}

.section {
  position: relative;
  padding-block: 118px;
}

.skip-link {
  position: fixed;
  z-index: 300;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  transform: translateY(-140%);
  border-radius: 8px;
  background: var(--text);
  color: var(--bg);
  font-weight: 800;
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: fixed;
  z-index: 100;
  inset: 0 0 auto;
  height: var(--header-height);
  border-bottom: 1px solid transparent;
  transition:
    border-color 220ms ease,
    background-color 220ms ease,
    backdrop-filter 220ms ease;
}

.site-header.is-scrolled {
  border-color: var(--line);
  background: rgba(3, 10, 19, 0.78);
  backdrop-filter: blur(18px);
}

.header-inner {
  display: flex;
  height: 100%;
  align-items: center;
  justify-content: space-between;
}

.brand {
  position: relative;
  z-index: 102;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.brand-symbol {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(85, 168, 255, 0.48);
  border-radius: 11px;
  background: linear-gradient(145deg, rgba(85, 168, 255, 0.22), rgba(62, 224, 179, 0.07));
  box-shadow: inset 0 0 22px rgba(85, 168, 255, 0.08);
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 0.92rem;
}

.brand-name {
  font-size: 1.02rem;
}

.brand-name span {
  color: var(--blue);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 34px;
}

.main-nav a {
  position: relative;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
  transition: color 180ms ease;
}

.main-nav a:not(.nav-contact)::after {
  position: absolute;
  right: 0;
  bottom: -8px;
  left: 0;
  height: 1px;
  content: "";
  transform: scaleX(0);
  background: var(--blue);
  transition: transform 180ms ease;
}

.main-nav a:hover,
.main-nav a.is-active {
  color: var(--text);
}

.main-nav a:hover::after,
.main-nav a.is-active::after {
  transform: scaleX(1);
}

.main-nav .nav-contact {
  padding: 9px 17px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--text);
}

.main-nav .nav-contact:hover {
  border-color: rgba(85, 168, 255, 0.5);
  background: rgba(85, 168, 255, 0.08);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: transparent;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 1px;
  margin: 5px auto;
  background: var(--text);
  transition: transform 180ms ease;
}

.hero {
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  padding-top: calc(var(--header-height) + 76px);
  padding-bottom: 48px;
  isolation: isolate;
}

.hero-grid-pattern {
  position: absolute;
  z-index: -3;
  inset: 0;
  background-image:
    linear-gradient(rgba(148, 163, 184, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: linear-gradient(to bottom, black 5%, transparent 92%);
}

.hero-orb {
  position: absolute;
  z-index: -2;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  filter: blur(115px);
  opacity: 0.16;
  pointer-events: none;
}

.hero-orb-blue {
  top: 12%;
  right: -140px;
  background: var(--blue);
}

.hero-orb-green {
  bottom: 2%;
  left: -190px;
  background: var(--green);
}

.hero-container {
  display: flex;
  min-height: calc(100svh - var(--header-height) - 124px);
  flex-direction: column;
  justify-content: center;
}

.hero-grid {
  display: grid;
  width: 100%;
  grid-template-columns: minmax(0, 1.05fr) minmax(430px, 0.95fr);
  gap: clamp(52px, 6vw, 86px);
  align-items: center;
}

.hero-copy,
.hero-visual {
  min-width: 0;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  margin: 0 0 24px;
  color: #bdd0e7;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.045em;
}

.eyebrow > span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(62, 224, 179, 0.1);
}

.hero h1 {
  max-width: 700px;
  margin: 0;
  font-size: clamp(3.5rem, 5.7vw, 5.85rem);
  font-weight: 780;
  line-height: 0.98;
  letter-spacing: -0.072em;
}

.hero h1 strong {
  color: var(--blue);
  font-weight: inherit;
}

.hero h1 > span {
  display: block;
  margin-top: 16px;
  background: linear-gradient(110deg, #d9eaff 0%, var(--blue) 48%, var(--green) 100%);
  background-clip: text;
  color: transparent;
  font-size: 0.54em;
  line-height: 1.14;
  letter-spacing: -0.05em;
}

.hero-intro {
  max-width: 620px;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  gap: 13px;
  padding: 12px 21px;
  border: 1px solid transparent;
  border-radius: 12px;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 800;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  background: var(--blue-strong);
  box-shadow: 0 13px 34px rgba(38, 140, 255, 0.26);
  color: white;
}

.button-primary:hover {
  box-shadow: 0 16px 42px rgba(38, 140, 255, 0.36);
}

.button-ghost {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.025);
}

.button-ghost:hover {
  border-color: rgba(85, 168, 255, 0.48);
  background: rgba(85, 168, 255, 0.07);
}

.button:focus-visible,
.filter-button:focus-visible,
.menu-toggle:focus-visible,
input:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}

.hero-capabilities {
  display: grid;
  max-width: 590px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 50px 0 0;
  padding: 0;
  list-style: none;
}

.hero-capabilities li {
  display: grid;
  gap: 1px;
  padding-right: 24px;
}

.hero-capabilities li + li {
  padding-left: 24px;
  border-left: 1px solid var(--line);
}

.hero-capabilities li > span {
  margin-bottom: 6px;
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 0.62rem;
}

.hero-capabilities strong {
  font-size: 0.91rem;
}

.hero-capabilities small {
  color: var(--muted);
  font-size: 0.71rem;
}

.hero-visual {
  position: relative;
}

.code-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.23);
  border-radius: var(--radius-large);
  background: rgba(6, 16, 29, 0.78);
  box-shadow:
    var(--shadow),
    inset 0 1px rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(18px);
  transform: perspective(1200px) rotateY(-3deg) rotateX(1deg);
  transition: transform 350ms ease;
}

.hero-visual:hover .code-card {
  transform: perspective(1200px) rotateY(0) rotateX(0) translateY(-4px);
}

.code-header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.022);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 0.64rem;
}

.window-dots {
  display: flex;
  gap: 6px;
}

.window-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ff6e7e;
}

.window-dots span:nth-child(2) {
  background: #ffc65b;
}

.window-dots span:nth-child(3) {
  background: #4cdda2;
}

.code-status {
  justify-self: end;
  color: var(--green);
}

.code-content {
  display: grid;
  min-height: 345px;
  align-content: center;
  padding: 38px;
  color: #c9d5e4;
  font-family: var(--font-mono);
  font-size: clamp(0.73rem, 1vw, 0.87rem);
  line-height: 2;
}

.code-content i {
  color: #c9a7ff;
  font-style: normal;
}

.code-content b {
  color: #75baff;
  font-weight: 600;
}

.code-content em {
  color: #63e8bd;
  font-style: normal;
}

.code-content .indent {
  padding-left: 24px;
}

.code-content .indent-two {
  padding-left: 48px;
}

.code-comment {
  margin-top: 12px;
  color: #607289;
}

.terminal {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 20px;
  border-top: 1px solid var(--line);
  background: rgba(2, 8, 15, 0.74);
  color: #8fa2b9;
  font-family: var(--font-mono);
  font-size: 0.67rem;
}

.terminal > span {
  color: var(--green);
}

.terminal p {
  margin: 0;
}

.terminal i {
  width: 7px;
  height: 13px;
  background: var(--blue);
  animation: blink 1s step-end infinite;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

.floating-label {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 10px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  background: rgba(13, 27, 45, 0.95);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.3);
  color: #d5dfec;
  font-family: var(--font-mono);
  font-size: 0.64rem;
}

.floating-label span {
  color: var(--blue);
}

.label-discover {
  top: -20px;
  right: -16px;
}

.label-deliver {
  bottom: 52px;
  left: -28px;
}

.tech-strip {
  display: flex;
  width: 100%;
  justify-content: space-between;
  margin-top: 68px;
  padding-top: 23px;
  border-top: 1px solid var(--line);
  color: #63758c;
  font-family: var(--font-mono);
  font-size: 0.67rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.about {
  background: rgba(255, 255, 255, 0.014);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  gap: 64px;
  align-items: end;
  margin-bottom: 60px;
}

.section-label {
  margin: 0 0 16px;
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.085em;
  text-transform: uppercase;
}

.section-heading h2,
.contact-copy h2 {
  margin: 0;
  font-size: clamp(2.5rem, 4.2vw, 4.15rem);
  line-height: 1.06;
  letter-spacing: -0.055em;
}

.section-heading > p,
.contact-copy > p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.about-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(0, 0.96fr);
  gap: 18px;
}

.story-card {
  position: relative;
  display: flex;
  min-height: 510px;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: clamp(34px, 5vw, 58px);
  border: 1px solid var(--line);
  border-radius: var(--radius-medium);
  background: linear-gradient(145deg, rgba(19, 36, 58, 0.7), rgba(8, 19, 33, 0.7));
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025);
}

.story-card::after {
  position: absolute;
  right: -110px;
  bottom: -110px;
  width: 290px;
  height: 290px;
  border: 1px solid rgba(85, 168, 255, 0.13);
  border-radius: 50%;
  box-shadow:
    0 0 0 36px rgba(85, 168, 255, 0.025),
    0 0 0 72px rgba(85, 168, 255, 0.018);
  content: "";
}

.card-index {
  position: absolute;
  top: 27px;
  right: 29px;
  color: rgba(148, 163, 184, 0.28);
  font-family: var(--font-mono);
  font-size: 0.68rem;
}

.story-kicker {
  position: relative;
  z-index: 1;
  margin: 0 0 12px !important;
  color: var(--blue) !important;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
}

.story-card h3 {
  position: relative;
  z-index: 1;
  margin: 0 0 23px;
  font-size: clamp(1.9rem, 3vw, 2.65rem);
  line-height: 1.1;
  letter-spacing: -0.042em;
}

.story-card > p:not(.story-kicker) {
  position: relative;
  z-index: 1;
  max-width: 590px;
  margin: 0 0 17px;
  color: var(--muted);
}

.principles {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}

.principles span,
.tech-badge {
  padding: 6px 10px;
  border: 1px solid rgba(85, 168, 255, 0.2);
  border-radius: 999px;
  background: rgba(85, 168, 255, 0.065);
  color: #bfdafb;
  font-family: var(--font-mono);
  font-size: 0.62rem;
}

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

.skill-card {
  position: relative;
  min-height: 158px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-medium);
  background: rgba(13, 27, 45, 0.6);
  transition:
    transform 200ms ease,
    border-color 200ms ease,
    background-color 200ms ease;
}

.skill-card:hover {
  transform: translateY(-3px);
  border-color: rgba(85, 168, 255, 0.32);
  background: rgba(19, 36, 58, 0.76);
}

.skill-card:last-child {
  grid-column: 1 / -1;
}

.skill-icon {
  display: grid;
  width: 38px;
  height: 38px;
  margin-bottom: 21px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 0.65rem;
}

.skill-card h3 {
  margin: 0 0 7px;
  font-size: 0.93rem;
}

.skill-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.77rem;
  line-height: 1.65;
}

.projects {
  overflow: hidden;
}

.project-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 32px;
}

.filter-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-button {
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 0.76rem;
  font-weight: 700;
  transition:
    border-color 180ms ease,
    background-color 180ms ease,
    color 180ms ease;
}

.filter-button:hover {
  border-color: var(--line-strong);
  color: var(--text);
}

.filter-button.is-active {
  border-color: rgba(85, 168, 255, 0.36);
  background: rgba(85, 168, 255, 0.1);
  color: var(--blue);
}

.project-count {
  flex: 0 0 auto;
  color: #63758c;
  font-family: var(--font-mono);
  font-size: 0.66rem;
}

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

.project-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-large);
  background: rgba(13, 27, 45, 0.6);
  transition:
    transform 220ms ease,
    border-color 220ms ease,
    box-shadow 220ms ease;
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: rgba(85, 168, 255, 0.3);
  box-shadow: 0 28px 64px rgba(0, 0, 0, 0.26);
}

.project-visual {
  position: relative;
  min-height: 340px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background:
    radial-gradient(circle at 80% 6%, var(--visual-accent-soft), transparent 48%),
    linear-gradient(145deg, #12243b, #081321);
}

.project-visual::before {
  position: absolute;
  z-index: 2;
  inset: 0;
  background: linear-gradient(to bottom, transparent 68%, rgba(3, 10, 19, 0.2));
  content: "";
  pointer-events: none;
}

.project-preview-shell {
  position: absolute;
  z-index: 1;
  top: 28px;
  right: 24px;
  bottom: -1px;
  left: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 15px 15px 0 0;
  background: #07111f;
  box-shadow: 0 24px 52px rgba(0, 0, 0, 0.42);
  transition:
    transform 320ms ease,
    box-shadow 320ms ease;
}

.project-card:hover .project-preview-shell {
  transform: translateY(-5px);
  box-shadow: 0 30px 62px rgba(0, 0, 0, 0.5);
}

.project-preview-bar {
  display: grid;
  height: 34px;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 0 12px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  background: rgba(6, 16, 29, 0.98);
}

.project-preview-dots {
  display: flex;
  gap: 5px;
}

.project-preview-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ff7180;
}

.project-preview-dots span:nth-child(2) {
  background: #ffc960;
}

.project-preview-dots span:nth-child(3) {
  background: #4cdfa6;
}

.project-preview-domain {
  color: #8091a8;
  font-family: var(--font-mono);
  font-size: 0.57rem;
}

.project-preview-image {
  width: 100%;
  height: calc(100% - 34px);
  object-fit: cover;
  object-position: top center;
  transition:
    transform 500ms cubic-bezier(0.2, 0.65, 0.3, 1),
    filter 300ms ease;
}

.project-card:hover .project-preview-image {
  transform: scale(1.025);
  filter: saturate(1.06);
}

.project-content {
  padding: 29px;
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.project-category {
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 0.63rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.project-index {
  color: #607189;
  font-family: var(--font-mono);
  font-size: 0.64rem;
}

.project-content h3 {
  margin: 0 0 10px;
  font-size: 1.42rem;
  letter-spacing: -0.035em;
}

.project-content > p {
  min-height: 72px;
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.72;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 20px;
}

.project-links {
  display: flex;
  gap: 18px;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.project-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #d7e1ed;
  font-size: 0.76rem;
  font-weight: 800;
  transition: color 180ms ease;
}

.project-link:hover {
  color: var(--blue);
}

.empty-state {
  padding: 40px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-medium);
  color: var(--muted);
  text-align: center;
}

.contact {
  padding-top: 68px;
}

.contact-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(430px, 1.1fr);
  gap: clamp(48px, 6vw, 78px);
  overflow: hidden;
  padding: clamp(38px, 6vw, 72px);
  border: 1px solid rgba(85, 168, 255, 0.22);
  border-radius: 32px;
  background:
    radial-gradient(circle at 8% 8%, rgba(85, 168, 255, 0.12), transparent 36%),
    linear-gradient(145deg, rgba(17, 34, 55, 0.97), rgba(7, 17, 30, 0.96));
  box-shadow: var(--shadow);
}

.contact-panel::before {
  position: absolute;
  top: -190px;
  right: -190px;
  width: 470px;
  height: 470px;
  border: 1px solid rgba(62, 224, 179, 0.1);
  border-radius: 50%;
  box-shadow:
    0 0 0 56px rgba(62, 224, 179, 0.018),
    0 0 0 112px rgba(62, 224, 179, 0.012);
  content: "";
}

.contact-copy,
.contact-form {
  position: relative;
  z-index: 1;
}

.contact-copy h2 span {
  color: var(--blue);
}

.contact-copy > p {
  max-width: 500px;
  margin-top: 24px;
}

.contact-details {
  display: grid;
  gap: 8px;
  margin-top: 38px;
}

.contact-details a {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 13px;
  align-items: center;
  padding: 10px 0;
}

.contact-icon {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 800;
}

.contact-details small,
.contact-details strong {
  display: block;
}

.contact-details small {
  color: var(--muted);
  font-size: 0.64rem;
}

.contact-details strong {
  margin-top: 1px;
  font-size: 0.82rem;
}

.contact-details i {
  color: #61738a;
  font-style: normal;
  transition:
    transform 180ms ease,
    color 180ms ease;
}

.contact-details a:hover i {
  transform: translate(2px, -2px);
  color: var(--blue);
}

.contact-form {
  display: grid;
  gap: 18px;
  padding: clamp(25px, 4vw, 38px);
  border: 1px solid var(--line);
  border-radius: var(--radius-medium);
  background: rgba(3, 10, 19, 0.48);
  backdrop-filter: blur(14px);
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.contact-form label {
  display: grid;
  gap: 8px;
}

.contact-form label > span {
  color: #c7d3e2;
  font-size: 0.7rem;
  font-weight: 700;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 10px;
  outline: none;
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  transition:
    border-color 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease;
}

.contact-form input {
  height: 48px;
  padding: 0 14px;
}

.contact-form textarea {
  min-height: 145px;
  padding: 13px 14px;
  resize: vertical;
}

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

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: rgba(85, 168, 255, 0.55);
  background: rgba(85, 168, 255, 0.045);
  box-shadow: 0 0 0 3px rgba(85, 168, 255, 0.08);
}

.contact-form .is-invalid {
  border-color: var(--danger);
}

.form-submit {
  width: 100%;
}

.form-note {
  margin: -6px 0 0;
  color: #63758c;
  font-size: 0.66rem;
  text-align: center;
}

.site-footer {
  padding: 28px 0 42px;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.footer-inner p,
.footer-inner > a:last-child {
  color: #6a7c93;
  font-size: 0.71rem;
}

.footer-inner > a:last-child {
  transition: color 180ms ease;
}

.footer-inner > a:last-child:hover {
  color: var(--text);
}

.toast {
  position: fixed;
  z-index: 200;
  right: 20px;
  bottom: 20px;
  max-width: min(380px, calc(100vw - 40px));
  padding: 13px 16px;
  transform: translateY(24px);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: #15243a;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  color: #d9e5f3;
  font-size: 0.77rem;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 200ms ease,
    transform 200ms ease;
}

.toast.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.reveal {
  transform: translateY(20px);
  opacity: 0;
  transition:
    opacity 650ms cubic-bezier(0.2, 0.65, 0.3, 1),
    transform 650ms cubic-bezier(0.2, 0.65, 0.3, 1);
}

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

@media (max-width: 1040px) {
  .hero {
    padding-top: calc(var(--header-height) + 74px);
  }

  .hero-container {
    min-height: auto;
  }

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

  .hero-copy {
    max-width: 790px;
  }

  .hero-visual {
    width: min(100%, 650px);
    margin-inline: auto;
  }

  .hero h1 {
    max-width: 820px;
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .section-heading > p {
    max-width: 650px;
  }

  .about-layout,
  .contact-panel {
    grid-template-columns: 1fr;
  }

  .story-card {
    min-height: 430px;
  }

  .contact-panel {
    gap: 48px;
  }
}

@media (max-width: 760px) {
  :root {
    --header-height: 68px;
  }

  .container {
    padding-inline: 20px;
  }

  .section {
    padding-block: 84px;
  }

  .menu-toggle {
    position: relative;
    z-index: 102;
    display: block;
  }

  .menu-toggle[aria-expanded="true"] span:first-child {
    transform: translateY(3px) rotate(45deg);
  }

  .menu-toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-3px) rotate(-45deg);
  }

  .main-nav {
    position: fixed;
    z-index: 101;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 26px;
    padding: 88px 32px 42px;
    transform: translateY(-100%);
    background: rgba(3, 10, 19, 0.985);
    opacity: 0;
    pointer-events: none;
    transition:
      transform 260ms ease,
      opacity 220ms ease;
  }

  .main-nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .main-nav a {
    font-size: 1.5rem;
  }

  .main-nav .nav-contact {
    margin-top: 8px;
    padding: 10px 18px;
    font-size: 1rem;
  }

  .hero {
    min-height: auto;
    padding-top: calc(var(--header-height) + 64px);
  }

  .hero-grid {
    gap: 62px;
  }

  .hero h1 {
    font-size: clamp(3.1rem, 14vw, 4.8rem);
  }

  .hero-capabilities {
    margin-top: 42px;
  }

  .hero-capabilities li {
    padding-right: 12px;
  }

  .hero-capabilities li + li {
    padding-left: 12px;
  }

  .code-card {
    transform: none;
  }

  .code-content {
    min-height: 290px;
    padding: 29px 23px;
    font-size: 0.72rem;
  }

  .floating-label {
    display: none;
  }

  .tech-strip {
    gap: 26px;
    justify-content: flex-start;
    overflow: hidden;
    white-space: nowrap;
  }

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

  .project-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .project-visual {
    min-height: 310px;
  }

  .project-content > p {
    min-height: 0;
  }

  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 540px) {
  .hero-actions,
  .hero-actions .button {
    width: 100%;
  }

  .hero-capabilities {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .hero-capabilities li,
  .hero-capabilities li + li {
    padding: 0 0 14px;
    border-bottom: 1px solid var(--line);
    border-left: 0;
  }

  .hero-capabilities li:last-child {
    border-bottom: 0;
  }

  .code-header {
    grid-template-columns: 1fr auto;
  }

  .code-header > span:nth-child(2) {
    display: none;
  }

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

  .skill-card:last-child {
    grid-column: auto;
  }

  .project-visual {
    min-height: 250px;
  }

  .project-preview-shell {
    top: 18px;
    right: 14px;
    left: 14px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .contact-panel {
    padding: 31px 20px;
    border-radius: 24px;
  }

  .contact-form {
    padding: 23px 16px;
  }

  .contact-details strong {
    overflow-wrap: anywhere;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    transform: none;
    opacity: 1;
  }
}
