:root {
  --bg: #0d0e11;
  --bg-top: #17181c;
  --panel: rgba(18, 19, 24, 0.76);
  --panel-soft: rgba(22, 24, 30, 0.62);
  --panel-strong: rgba(11, 12, 16, 0.88);
  --text: #f3f5f9;
  --muted: rgba(217, 223, 233, 0.72);
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.16);
  --icy: #a4d8ff;
  --gunmetal: #35393c;
  --raspberry: #ee005a;
  --space: #012641;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.48);
  --shadow-soft: 0 18px 42px rgba(0, 0, 0, 0.28);
  --highlight: linear-gradient(135deg, rgba(255, 255, 255, 0.12), transparent 38%);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(8, 9, 12, 0.76)),
    url("media/darkbg.jpg") center / cover fixed no-repeat,
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg) 36%, #08090b 100%);
  color: var(--text);
  font-family: "Inter", Arial, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

body.nav-open {
  overflow: hidden;
}

a {
  color: inherit;
}

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

.site-header {
  position: sticky;
  top: 14px;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: min(1240px, calc(100% - 36px));
  margin: 0 auto 20px;
  padding: 14px 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(18, 19, 24, 0.74);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.14) inset,
    var(--shadow-soft);
  backdrop-filter: blur(14px) saturate(135%);
  -webkit-backdrop-filter: blur(14px) saturate(135%);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  text-decoration: none;
  letter-spacing: 0;
}

.brand-mark {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid var(--line);
  background:
    linear-gradient(145deg, rgba(14, 17, 24, 0.96), rgba(43, 47, 58, 0.78)),
    var(--panel-strong);
  color: var(--icy);
  border-radius: 10px;
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.34),
    0 1px 0 rgba(255, 255, 255, 0.08) inset;
  font-family: "JetBrains Mono", monospace;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-nav a {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.07);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.12) inset;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(18, 19, 24, 0.8);
  border-radius: 12px;
  backdrop-filter: blur(10px) saturate(130%);
  -webkit-backdrop-filter: blur(10px) saturate(130%);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: var(--text);
}

.section {
  width: min(1180px, calc(100% - 36px));
  max-width: calc(100% - 36px);
  margin: 0 auto 28px;
  padding: 0;
}

.window-panel {
  position: relative;
  padding: 88px clamp(22px, 4vw, 34px) 34px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015)),
    linear-gradient(180deg, rgba(22, 23, 29, 0.88), rgba(11, 12, 16, 0.82));
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.12) inset,
    var(--shadow);
  backdrop-filter: blur(1px) saturate(1%);
  -webkit-backdrop-filter: blur(1px) saturate(125%);
  overflow: hidden;
}

.window-panel > * {
  position: relative;
  z-index: 1;
}

.window-panel::before {
  content: "";
  position: absolute;
  top: 22px;
  left: 20px;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #ff5f57;
  box-shadow:
    18px 0 0 #febc2e,
    36px 0 0 #28c840;
}

.window-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, transparent 0 51px, rgba(255, 255, 255, 0.08) 52px, transparent 53px),
    radial-gradient(circle at 70% 78%, rgba(164, 216, 255, 0.05), transparent 0 18%),
    radial-gradient(circle at 22% 22%, rgba(164, 216, 255, 0.06), transparent 0 20%),
    radial-gradient(circle at 84% 28%, rgba(255, 255, 255, 0.03), transparent 0 14%);
  pointer-events: none;
  z-index: 0;
}

.hero {
  min-height: min(820px, calc(100vh - 96px));
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  align-items: center;
  gap: clamp(32px, 7vw, 88px);
}

.hero-copy,
.hero-panel,
.project-card,
.service-card,
.contact-card {
  min-width: 0;
}

.eyebrow {
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.88);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  letter-spacing: 0;
  line-height: 1.04;
}

h1 {
  max-width: 860px;
  font-size: clamp(48px, 7vw, 86px);
  overflow-wrap: break-word;
}

h2 {
  max-width: 100%;
  font-size: clamp(36px, 5vw, 58px);
  overflow-wrap: break-word;
}

h3 {
  font-size: 24px;
}

.hero-text,
.section-lead {
  max-width: 720px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 12px;
  font-weight: 800;
  text-decoration: none;
  box-shadow:
    0 14px 28px rgba(0, 0, 0, 0.22),
    0 1px 0 rgba(255, 255, 255, 0.1) inset;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
  box-shadow:
    0 18px 34px rgba(0, 0, 0, 0.28),
    0 1px 0 rgba(255, 255, 255, 0.14) inset;
}

.button.primary {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.03)),
    linear-gradient(135deg, rgba(238, 0, 90, 0.9), rgba(120, 18, 58, 0.82));
  color: #ffffff;
  backdrop-filter: blur(10px) saturate(135%);
  -webkit-backdrop-filter: blur(10px) saturate(135%);
}

.button.secondary {
  border: 1px solid var(--line);
  color: var(--text);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
    rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(10px) saturate(120%);
  -webkit-backdrop-filter: blur(10px) saturate(120%);
}

.hero-panel,
.service-card,
.project-card,
.contact-card,
.stack-grid span,
.status-card,
.metric-grid div,
.project-meta span,
.contact-card a {
  position: relative;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03)),
    rgba(255, 255, 255, 0.035);
  border: 1px solid var(--line);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.08) inset,
    var(--shadow-soft);
  backdrop-filter: blur(12px) saturate(118%);
  -webkit-backdrop-filter: blur(12px) saturate(118%);
}

.hero-panel::before,
.service-card::before,
.project-card::before,
.contact-card::before,
.stack-grid span::before,
.status-card::before,
.metric-grid div::before,
.project-meta span::before,
.contact-card a::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--highlight);
  pointer-events: none;
}

.hero-panel {
  padding: 18px;
  border-radius: 18px;
}

.profile-photo {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 14px;
  filter: saturate(0.92) contrast(0.95) brightness(0.92);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
}

.status-card {
  margin-top: 16px;
  padding: 16px;
  border-radius: 14px;
}

.status-label {
  display: block;
  color: rgba(255, 255, 255, 0.86);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  margin-bottom: 6px;
  text-transform: uppercase;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 10px;
}

.metric-grid div {
  padding: 14px 10px;
  border-radius: 14px;
}

.metric-grid strong,
.metric-grid span {
  display: block;
}

.metric-grid strong {
  font-size: 24px;
  line-height: 1;
}

.metric-grid span {
  color: var(--muted);
  font-size: 12px;
}

.split {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 36px;
  align-items: start;
}

.service-grid,
.project-list,
.stack-grid {
  display: grid;
  gap: 16px;
}

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

.service-card,
.project-card {
  border-radius: 18px;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.service-card:hover,
.project-card:hover {
  border-color: var(--line-strong);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.1) inset,
    var(--shadow);
  transform: translateY(-2px);
}

.service-card {
  padding: 22px;
}

.service-card span {
  color: rgba(255, 255, 255, 0.8);
  font-family: "JetBrains Mono", monospace;
  font-size: 13px;
  font-weight: 800;
}

.service-card h3 {
  margin-top: 16px;
}

.service-card p,
.project-card p {
  color: var(--muted);
}

.section-heading {
  margin-bottom: 34px;
}

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

.project-card {
  overflow: hidden;
}

.project-card.featured {
  display: grid;
  grid-template-rows: auto 1fr;
}

.project-media {
  position: relative;
  background:
    linear-gradient(135deg, rgba(164, 216, 255, 0.08), rgba(255, 255, 255, 0.03)),
    var(--panel-strong);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.project-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), transparent 44%);
  pointer-events: none;
}

.image-cover img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  filter: saturate(0.92) contrast(0.96) brightness(0.88);
}

.image-contain {
  display: grid;
  place-items: center;
  padding: 12px;
  background:
    linear-gradient(135deg, rgba(164, 216, 255, 0.12), rgba(238, 0, 90, 0.06)),
    var(--panel-strong);
}

.image-contain img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  filter: drop-shadow(0 12px 24px rgba(0, 0, 0, 0.35));
}

.project-preview {
  display: grid;
  min-height: 0;
  aspect-ratio: 16 / 9;
  align-content: end;
  gap: 6px;
  padding: 18px;
  color: #ffffff;
  overflow: hidden;
  isolation: isolate;
}

.project-preview::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
}

.project-preview::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, transparent 18%, rgba(6, 8, 12, 0.84));
}

.project-preview strong {
  max-width: 100%;
  font-size: 24px;
  line-height: 1.05;
  overflow-wrap: break-word;
}

.project-preview span {
  color: rgba(243, 245, 247, 0.78);
  font-size: 12px;
  font-weight: 800;
}

.project-preview .preview-bar {
  position: absolute;
  top: 14px;
  left: 14px;
  width: 72px;
  height: 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow:
    92px 0 0 rgba(255, 255, 255, 0.26),
    138px 0 0 rgba(164, 216, 255, 0.24);
}

.villa-preview::before {
  background:
    linear-gradient(135deg, rgba(5, 42, 44, 0.18), rgba(255, 255, 255, 0)),
    url("media/project1image.PNG") center / cover;
}

.foundation-preview::before {
  background:
    linear-gradient(135deg, rgba(164, 216, 255, 0.36), rgba(1, 38, 65, 0.46) 48%, rgba(238, 0, 90, 0.34)),
    var(--panel-strong);
}

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

.project-body {
  padding: 22px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.project-meta span {
  padding: 5px 8px;
  border-radius: 999px;
  color: rgba(243, 245, 249, 0.88);
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
}

.project-card a {
  display: inline-flex;
  margin-top: 8px;
  color: #ffffff;
  font-weight: 800;
  text-decoration: none;
}

.stack-section {
  padding-top: 88px;
}

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

.stack-grid span {
  display: grid;
  min-height: 56px;
  place-items: center;
  padding: 10px;
  border-radius: 14px;
  color: var(--text);
  font-weight: 800;
  text-align: center;
}

.contact-section {
  display: grid;
  grid-template-columns: 1fr minmax(320px, 420px);
  gap: 36px;
  align-items: start;
}

.contact-card {
  display: grid;
  gap: 12px;
  padding: 22px;
  border-radius: 18px;
}

.contact-card a {
  border-radius: 12px;
  color: var(--text);
  font-weight: 700;
  text-decoration: none;
  word-break: break-word;
  padding: 12px;
}

.contact-card a:last-child {
  border-bottom: 0;
}

.contact-card a:hover,
.project-card a:hover {
  color: var(--icy);
}

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

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

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

@media (max-width: 720px) {
  body {
    min-width: 0;
  }

  .site-header {
    top: 10px;
    width: calc(100% - 28px);
    padding: 12px 16px;
    border-radius: 18px;
  }

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

  .site-nav {
    position: fixed;
    inset: 74px 14px auto 14px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03)),
      rgba(18, 19, 24, 0.88);
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(14px) saturate(130%);
    -webkit-backdrop-filter: blur(14px) saturate(130%);
  }

  .site-nav.is-open {
    display: flex;
  }

  .site-nav a {
    padding: 14px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
  }

  .section {
    width: min(100% - 28px, 1180px);
    max-width: calc(100% - 28px);
    margin-bottom: 20px;
    overflow: hidden;
  }

  .window-panel {
    padding: 82px 18px 22px;
    border-radius: 22px;
  }

  .hero {
    min-height: auto;
  }

  .hero-actions,
  .featured-grid,
  .service-grid,
  .project-list {
    grid-template-columns: 1fr;
  }

  .featured-grid,
  .project-list,
  .service-grid {
    display: grid;
  }

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

  h1 {
    max-width: 100%;
    font-size: 34px;
    line-height: 1.1;
  }

  h2 {
    font-size: 32px;
    line-height: 1.12;
  }

  .hero-text,
  .section-lead {
    font-size: 16px;
  }

  .service-card,
  .project-body,
  .contact-card {
    padding: 18px;
  }
}
