:root {
  --ink: #111827;
  --paper: #f8f4e8;
  --paper-strong: #fffaf0;
  --muted: #667085;
  --line: rgba(17, 24, 39, 0.16);
  --green: #27c46b;
  --green-dark: #118848;
  --amber: #f5b84b;
  --blue: #6bb7ff;
  --shadow: 0 28px 70px rgba(17, 24, 39, 0.18);
  --radius-lg: 34px;
  --radius-md: 22px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  font-family: "Space Grotesk", "Trebuchet MS", sans-serif;
  background:
    radial-gradient(circle at 14% 18%, rgba(39, 196, 107, 0.35), transparent 24rem),
    radial-gradient(circle at 86% 8%, rgba(107, 183, 255, 0.28), transparent 22rem),
    radial-gradient(circle at 68% 78%, rgba(245, 184, 75, 0.16), transparent 24rem),
    linear-gradient(135deg, #06110f 0%, #0a1420 48%, #111827 100%);
}

body::before {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  content: "";
  background:
    radial-gradient(circle, rgba(39, 196, 107, 0.7) 0 2px, transparent 2.5px) 18px 18px / 96px 96px,
    linear-gradient(90deg, rgba(39, 196, 107, 0.22) 1px, transparent 1px) 0 0 / 96px 96px,
    linear-gradient(rgba(107, 183, 255, 0.18) 1px, transparent 1px) 0 0 / 96px 96px,
    linear-gradient(90deg, transparent 0 22px, rgba(39, 196, 107, 0.22) 22px 24px, transparent 24px 96px) 0 0 / 192px 192px,
    linear-gradient(transparent 0 70px, rgba(107, 183, 255, 0.2) 70px 72px, transparent 72px 192px) 0 0 / 192px 192px;
  opacity: 0.56;
  mask-image: linear-gradient(to bottom, #000 0%, rgba(0, 0, 0, 0.86) 62%, transparent 100%);
}

body::after {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  content: "";
  background:
    linear-gradient(rgba(255, 250, 240, 0.045) 50%, transparent 50%) 0 0 / 100% 6px,
    linear-gradient(135deg, rgba(39, 196, 107, 0.13) 0 10px, transparent 10px 32px) 0 0 / 32px 32px,
    linear-gradient(45deg, transparent 0 22px, rgba(107, 183, 255, 0.11) 22px 24px, transparent 24px 48px) 0 0 / 48px 48px;
  opacity: 0.5;
}

a {
  color: inherit;
}

.page-shell {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 56px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 72px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.72);
  backdrop-filter: blur(18px);
  box-shadow: 0 18px 60px rgba(17, 24, 39, 0.08);
}

.brand,
.nav-links,
.hero-actions,
.project-topline,
.social-grid {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 700;
  text-decoration: none;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 4px 4px 0 var(--green);
}

.nav-links {
  gap: 4px;
  font-size: 0.94rem;
}

.nav-links a {
  padding: 10px 14px;
  border-radius: 999px;
  color: rgba(17, 24, 39, 0.76);
  text-decoration: none;
}

.nav-links a:hover {
  background: rgba(17, 24, 39, 0.08);
  color: var(--ink);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 34px;
  align-items: stretch;
}

.hero-copy,
.stats-strip,
.links-panel,
.project-hero-card {
  border: 1px solid var(--line);
  background: rgba(255, 250, 240, 0.82);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-copy {
  min-height: 520px;
  padding: clamp(32px, 7vw, 82px);
  border-radius: var(--radius-lg);
  background:
    linear-gradient(145deg, rgba(255, 250, 240, 0.92), rgba(255, 250, 240, 0.58)),
    linear-gradient(110deg, transparent 0 62%, rgba(245, 184, 75, 0.4) 62% 72%, transparent 72%);
}

.eyebrow,
.project-topline,
.stats-strip p,
.social-grid small {
  font-family: "IBM Plex Mono", "Courier New", monospace;
  letter-spacing: 0.04em;
}

.eyebrow {
  margin: 0 0 16px;
  color: var(--green-dark);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 22px;
  font-size: clamp(3.6rem, 10vw, 8.8rem);
  line-height: 0.86;
  letter-spacing: -0.09em;
}

.hero-text {
  max-width: 600px;
  margin-bottom: 34px;
  color: rgba(17, 24, 39, 0.78);
  font-size: clamp(1.08rem, 2vw, 1.35rem);
  line-height: 1.55;
}

.hero-actions {
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

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

.button.primary {
  color: var(--paper-strong);
  background: var(--ink);
  box-shadow: 5px 5px 0 var(--green);
}

.button.ghost {
  background: var(--paper-strong);
}

.stats-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 26px 0 72px;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--line);
}

.stats-strip div {
  padding: 22px;
  background: rgba(255, 250, 240, 0.78);
}

.stats-strip span {
  display: block;
  margin-bottom: 6px;
  font-size: clamp(1.6rem, 3vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.06em;
}

.stats-strip p {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.section-heading {
  max-width: 860px;
  margin-bottom: 24px;
}

.section-heading h2,
.links-panel h2 {
  margin-bottom: 0;
  font-size: clamp(2.2rem, 5vw, 4.8rem);
  line-height: 0.95;
  letter-spacing: -0.08em;
}

.section-heading h2 {
  color: var(--paper-strong);
  text-shadow: 0 8px 32px rgba(0, 0, 0, 0.36);
}

.section-copy {
  max-width: 690px;
  margin: 18px 0 0;
  color: rgba(255, 250, 240, 0.76);
  font-size: 1.12rem;
  line-height: 1.6;
}

.project-showcase {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 72px;
}

.project-hero-card {
  display: grid;
  min-height: 390px;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 0.78fr);
  gap: 28px;
  align-items: stretch;
  padding: 28px;
  overflow: hidden;
  border: 1px solid rgba(255, 250, 240, 0.24);
  border-radius: var(--radius-lg);
  color: var(--paper-strong);
  background: var(--ink);
  box-shadow: var(--shadow);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.project-hero-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 30px 80px rgba(17, 24, 39, 0.22);
}

.project-hero-card.bubblecraft {
  grid-column: 1 / -1;
  min-height: 460px;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 1fr);
  background:
    radial-gradient(circle at 78% 18%, rgba(39, 196, 107, 0.58), transparent 22rem),
    linear-gradient(120deg, rgba(17, 24, 39, 0.98), rgba(17, 24, 39, 0.82));
}

.project-hero-card.recycling {
  min-height: 360px;
  grid-template-columns: minmax(0, 0.95fr) minmax(170px, 0.62fr);
  gap: 18px;
  background:
    radial-gradient(circle at 78% 20%, rgba(245, 184, 75, 0.45), transparent 19rem),
    linear-gradient(145deg, rgba(19, 92, 58, 0.98), rgba(17, 24, 39, 0.9));
}

.project-hero-card.weather {
  min-height: 360px;
  grid-template-columns: minmax(0, 0.95fr) minmax(170px, 0.62fr);
  gap: 18px;
  background:
    radial-gradient(circle at 72% 18%, rgba(107, 183, 255, 0.46), transparent 20rem),
    linear-gradient(145deg, rgba(27, 53, 94, 0.98), rgba(17, 24, 39, 0.9));
}

.project-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: space-between;
}

.project-topline {
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 58px;
  color: rgba(255, 250, 240, 0.7);
  font-size: 0.78rem;
  text-transform: uppercase;
}

.project-tag {
  padding: 8px 10px;
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.14);
  color: var(--paper-strong);
}

.project-hero-card h3 {
  margin-bottom: 12px;
  font-size: clamp(2.3rem, 6vw, 5.4rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
  overflow-wrap: anywhere;
}

.project-hero-card:not(.bubblecraft) h3 {
  font-size: clamp(2.2rem, 4.2vw, 3.9rem);
  line-height: 0.9;
}

.project-hero-card p {
  max-width: 640px;
  margin-bottom: 28px;
  color: rgba(255, 250, 240, 0.74);
  font-size: 1.04rem;
  line-height: 1.55;
}

.project-hero-card a {
  align-self: flex-start;
  color: var(--paper-strong);
  font-weight: 700;
  text-decoration-thickness: 0.14em;
  text-underline-offset: 0.24em;
}

.project-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.project-actions a {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 250, 240, 0.34);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.1);
  text-decoration: none;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.project-actions a:hover {
  border-color: rgba(255, 250, 240, 0.68);
  background: rgba(255, 250, 240, 0.17);
  transform: translateY(-2px);
}

.project-actions .app-button {
  padding: 0 18px;
  color: var(--ink);
  background: var(--paper-strong) !important;
  box-shadow: 4px 4px 0 rgba(39, 196, 107, 0.84);
}

.project-actions .app-button:hover {
  color: var(--ink);
  background: #ffffff !important;
}

.github-icon-link {
  width: 48px;
  color: var(--paper-strong);
}

.github-icon-link svg {
  display: block;
  fill: currentColor;
}

.project-visual,
.project-screenshot,
.project-logo {
  position: relative;
  display: grid;
  min-height: 270px;
  align-content: end;
  gap: 12px;
  padding: 22px;
  overflow: hidden;
  border: 2px solid rgba(255, 250, 240, 0.6);
  border-radius: 26px;
  background:
    linear-gradient(90deg, rgba(255, 250, 240, 0.12) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(rgba(255, 250, 240, 0.12) 1px, transparent 1px) 0 0 / 28px 28px,
    rgba(255, 250, 240, 0.08);
  box-shadow: inset 0 -42px 80px rgba(17, 24, 39, 0.22);
}

.project-visual::before,
.project-screenshot::before,
.project-logo::before {
  position: absolute;
  inset: 24px;
  border-radius: 20px;
  content: "";
  background: linear-gradient(135deg, rgba(255, 250, 240, 0.22), transparent);
}

.project-screenshot {
  margin: 0;
  padding: 14px;
  align-content: stretch;
  background:
    linear-gradient(90deg, rgba(255, 250, 240, 0.09) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(rgba(255, 250, 240, 0.09) 1px, transparent 1px) 0 0 / 28px 28px,
    rgba(255, 250, 240, 0.08);
}

.project-screenshot::before {
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 250, 240, 0.18), transparent 42%),
    radial-gradient(circle at 76% 24%, rgba(39, 196, 107, 0.22), transparent 18rem);
}

.project-screenshot img {
  position: relative;
  z-index: 0;
  width: 100%;
  height: 100%;
  min-height: 270px;
  object-fit: cover;
  object-position: center;
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
}

.project-logo {
  margin: 0;
  place-items: center;
  align-content: center;
  background:
    radial-gradient(circle at 50% 44%, rgba(255, 250, 240, 0.22), transparent 8rem),
    linear-gradient(90deg, rgba(255, 250, 240, 0.11) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(rgba(255, 250, 240, 0.11) 1px, transparent 1px) 0 0 / 28px 28px,
    rgba(255, 250, 240, 0.08);
}

.project-logo::before {
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 250, 240, 0.18), transparent 42%),
    radial-gradient(circle at 52% 46%, rgba(39, 196, 107, 0.2), transparent 10rem);
}

.project-logo img {
  position: relative;
  z-index: 2;
  width: min(96%, 220px);
  height: auto;
  filter: drop-shadow(0 24px 36px rgba(0, 0, 0, 0.28));
}

.weather-visual {
  align-content: center;
}

.weather-visual span {
  display: flex;
  min-height: 54px;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  border: 1px solid rgba(255, 250, 240, 0.34);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.14);
  font-family: "IBM Plex Mono", "Courier New", monospace;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.weather-visual span::after {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  content: "";
  background: var(--green);
  box-shadow: 0 0 28px rgba(39, 196, 107, 0.88);
}

.weather-visual span::after {
  background: var(--blue);
  box-shadow: 0 0 28px rgba(107, 183, 255, 0.88);
}

.links-panel {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(280px, 1.1fr);
  gap: 28px;
  align-items: center;
  padding: 28px;
  border-radius: var(--radius-lg);
}

.social-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
}

.social-grid a {
  min-height: 128px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--paper-strong);
  text-decoration: none;
  transition: transform 180ms ease, border-color 180ms ease;
}

.social-grid a:hover {
  border-color: var(--green-dark);
  transform: translateY(-4px);
}

.social-grid span,
.social-grid small {
  display: block;
}

.social-grid span {
  margin-bottom: 10px;
  font-size: 1.3rem;
  font-weight: 700;
}

.social-grid small {
  color: var(--muted);
  font-size: 0.76rem;
}

.reveal {
  animation: rise-in 720ms ease both;
}

.reveal:nth-child(2) {
  animation-delay: 80ms;
}

.reveal:nth-child(3) {
  animation-delay: 140ms;
}

.reveal:nth-child(4) {
  animation-delay: 200ms;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(22px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .site-header,
  .hero-actions {
    align-items: flex-start;
  }

  .site-header,
  .hero,
  .links-panel,
  .project-showcase,
  .project-hero-card,
  .project-hero-card.bubblecraft,
  .project-hero-card.recycling,
  .project-hero-card.weather {
    grid-template-columns: 1fr;
  }

  .site-header {
    flex-direction: column;
    border-radius: 28px;
  }

  .nav-links {
    width: 100%;
    flex-wrap: wrap;
  }

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

  .stats-strip,
  .social-grid {
    grid-template-columns: 1fr;
  }

  .project-hero-card,
  .project-hero-card.bubblecraft,
  .project-hero-card.recycling,
  .project-hero-card.weather {
    min-height: auto;
  }
}

@media (max-width: 560px) {
  .page-shell {
    width: min(100% - 22px, 1120px);
    padding-top: 14px;
  }

  .site-header {
    margin-bottom: 34px;
  }

  .hero-copy,
  .links-panel,
  .project-hero-card {
    padding: 20px;
    border-radius: 24px;
  }

  .button {
    width: 100%;
  }

  .project-showcase {
    gap: 12px;
  }
}

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