*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --cream: #f4f6f1;
  --white: #ffffff;
  --dark: #1a1a1a;
  --mid: #555;
  --light: #888;
  --border: #e0d8d0;
  --accent: #6b8a6a;
  --accent-rgb: 107, 138, 106;
  --accent-light: #e9f3ea;
  --progress: #6b8a6a;
  --progress-light: #cfe2cf;
  --content-max: 1120px;
  --page-gutter: clamp(1rem, 4vw, 3.25rem);
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  overflow-x: clip;
  max-width: 100%;
  overscroll-behavior-x: none;
}

html.js {
  scroll-behavior: smooth;
  overflow-x: hidden;
  overflow-x: clip;
  max-width: 100%;
  overscroll-behavior-x: none;
}

body {
  width: 100%;
  max-width: 100%;
  margin: 0;
  position: relative;
  overflow-x: hidden;
  overflow-x: clip;
  background: var(--cream);
  color: var(--dark);
  font-family: 'Manrope', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  overflow-anchor: none;
  overscroll-behavior-x: none;
  touch-action: pan-y;
}

/* Prevent wide images and hero pseudo-elements from causing horizontal scroll */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

svg,
video,
canvas {
  max-width: 100%;
}

.hero {
  overflow: hidden;
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  z-index: 220;
  background: rgba(var(--accent-rgb), 0.12);
}

.scroll-progress span {
  display: block;
  width: 100%;
  height: 100%;
  transform-origin: left center;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--progress), var(--progress-light));
}

.back-to-top {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 210;
  width: 48px;
  height: 48px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--dark);
  font-size: 1rem;
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(12px);
  opacity: 0;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 0.25s ease, transform 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

.back-to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Nav */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid var(--border);
  padding: 1rem var(--page-gutter);
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(14px);
  transition: box-shadow 0.25s ease, background 0.25s ease;
  width: 100%;
}

nav.is-scrolled {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.logo {
  font-family: 'Manrope', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--dark);
  letter-spacing: 0.02em;
}

.logo-link {
  text-decoration: none;
}

.logo-link:hover {
  color: var(--accent);
}

nav ul {
  list-style: none;
  display: flex;
  gap: 2.5rem;
}

nav a {
  text-decoration: none;
  color: var(--mid);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}

nav a:hover {
  color: var(--accent);
}

nav a.is-active {
  color: var(--accent);
}

/* Hamburger menu button */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 0.4rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 101;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--dark);
  border-radius: 1px;
  transition: all 0.3s ease;
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

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

.nav-menu {
  display: flex;
  gap: 2.5rem;
}

/* Hero */
.hero {
  background: linear-gradient(180deg, #fff 0%, #faf7f3 100%);
  padding: clamp(3rem, 7vh, 5.5rem) 0 clamp(3.5rem, 7vh, 5.25rem);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
  contain: layout;
  display: flex;
  align-items: center;
}

.hero::before,
.hero::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.hero::before {
  width: 13rem;
  height: 13rem;
  right: -5rem;
  top: -5rem;
  background: rgba(var(--accent-rgb), 0.06);
  filter: blur(10px);
}

.hero::after {
  width: 15rem;
  height: 15rem;
  left: -6rem;
  bottom: -7rem;
  background: rgba(var(--accent-rgb), 0.05);
  filter: blur(10px);
}

.hero-inner {
  inline-size: min(860px, calc(100% - (var(--page-gutter) * 2)));
  margin: 0 auto;
  display: flex;
  justify-content: center;
  position: relative;
  z-index: 1;
  min-width: 0;
  width: 100%;
}

.hero-copy {
  max-width: 760px;
  text-align: center;
  min-width: 0;
  width: 100%;
}

.hero-lead {
  max-width: 620px;
  margin: 0 auto;
}

.hero-eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.2rem;
}

.hero h1 {
  font-family: 'Manrope', sans-serif;
  font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 700;
  line-height: 1.15;
  color: var(--dark);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.hero h1 em {
  display: flex;
  justify-content: center;
  width: 100%;
  font-style: italic;
  color: var(--accent);
  overflow-anchor: none;
}

.hero-typing-line {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  position: relative;
  min-height: 1.2em;
  white-space: nowrap;
  overflow-anchor: none;
  max-width: 100%;
  min-width: 0;
}

.hero-typing-suffix {
  display: block;
  margin-top: 0.12em;
  font-style: italic;
  white-space: nowrap;
  line-height: 1;
}

.hero-typing-word {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: inline-block;
  font-style: normal;
  font-size: 0.95em;
  font-weight: 800;
  letter-spacing: -0.015em;
  white-space: nowrap;
  line-height: 1;
}

.contact-item-sub,
.legal-section p,
.legal-section li,
.legal-section a,
footer p {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hero-typing-spacer {
  visibility: hidden;
  pointer-events: none;
  white-space: nowrap;
  font: inherit;
  letter-spacing: inherit;
  line-height: 1;
}

.hero-typing-cursor {
  position: absolute;
  top: 50%;
  width: 0.09em;
  height: 0.95em;
  background: currentColor;
  animation: typingBlink 0.9s steps(1) infinite;
  transform: translateY(-50%);
  left: 50%;
  margin-left: var(--cursor-offset, 0);
}

.hero-typing-cursor.is-hidden {
  opacity: 0;
}

@keyframes typingBlink {
  0%, 49% {
    opacity: 1;
  }
  50%, 100% {
    opacity: 0;
  }
}

.hero-copy .hero-lead {
  margin: 0 auto 2.2rem;
  color: var(--mid);
  font-size: 1rem;
  line-height: 1.8;
}

.hero-note {
  margin-top: 1rem;
  color: var(--light);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 1.1rem;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  width: 1.1rem;
  height: 1.8rem;
  color: var(--light);
  text-decoration: none;
  opacity: 0.85;
  z-index: 2;
}

.hero-scroll-hint span {
  display: block;
  width: 0.45rem;
  height: 0.45rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  animation: scrollHint 1.4s ease-in-out infinite;
}

.hero-scroll-hint span:last-child {
  animation-delay: 0.14s;
}

.hero-scroll-hint:hover {
  color: var(--accent);
}

.section-divider {
  width: min(88px, calc(100% - (var(--page-gutter) * 2)));
  height: 2px;
  margin: 0 auto;
  background: linear-gradient(90deg, transparent, var(--border), transparent);
  border-radius: 999px;
}

.hero-btns {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  text-decoration: none;
  font-size: 0.84rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
  font-family: 'Manrope', sans-serif;
  border-radius: 999px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn-primary {
  background: var(--accent);
  color: var(--white);
  border: 1.5px solid var(--accent);
  box-shadow: 0 12px 24px rgba(var(--accent-rgb), 0.18);
}

.btn-primary:hover {
  background: #59755a;
  border-color: #59755a;
  transform: translateY(-2px);
  box-shadow: 0 16px 28px rgba(var(--accent-rgb), 0.24);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.78);
  color: var(--dark);
  border: 1.5px solid rgba(17, 24, 39, 0.12);
  box-shadow: 0 10px 22px rgba(17, 24, 39, 0.06);
}

.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 14px 26px rgba(17, 24, 39, 0.1);
}

.hero-btn-primary::after,
.hero-btn-secondary::after {
  content: '';
  display: inline-block;
  width: 0.45rem;
  height: 0.45rem;
  margin-left: 0.55rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg) translateY(-1px);
}

.hero-cta-note {
  margin-top: 0.25rem;
  color: var(--light);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

/* Sections */
section {
  padding: 4.25rem 0;
  overflow-x: hidden;
}

section > * {
  inline-size: min(var(--content-max), calc(100% - (var(--page-gutter) * 2)));
  margin-inline: auto;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.8rem;
}

h2 {
  font-family: 'Manrope', sans-serif;
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 700;
  color: var(--dark);
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.section-header p {
  margin-top: 1rem;
  color: var(--mid);
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

/* About */
.about-bg {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
  max-width: 1000px;
  margin: 0 auto;
}

.about-grid > *,
.skills-grid > *,
.projects-grid > * {
  min-width: 0;
}

.about-img-wrap {
  background: var(--accent-light);
  border: 1px solid var(--border);
  aspect-ratio: 4/5;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.about-headshot {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.about-img-wrap::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 60%;
  height: 60%;
  border-right: 3px solid var(--accent);
  border-bottom: 3px solid var(--accent);
}

.about-text h2 {
  text-align: left;
  margin-bottom: 1.2rem;
}

.about-text p {
  color: var(--mid);
  margin-bottom: 1rem;
}

.about-facts {
  margin-top: 1.8rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.fact {
  border-left: 2px solid var(--accent);
  padding-left: 0.8rem;
}

.fact-val {
  font-family: 'Manrope', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.1;
}

.fact-label {
  font-size: 0.75rem;
  color: var(--light);
  letter-spacing: 0.05em;
  overflow-wrap: anywhere;
  hyphens: auto;
}

/* Skills */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.1rem;
  max-width: 1040px;
  margin: 0 auto;
  padding: 0;
}

.skill-card {
  background: var(--white);
  padding: 1.35rem 1.25rem 1.25rem;
  text-align: left;
  transition: transform 0.18s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 10px 28px rgba(17, 24, 39, 0.05);
}

.skill-card:hover {
  transform: translateY(-3px);
  border-color: rgba(17, 24, 39, 0.16);
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.08);
}

.skill-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.skill-index {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #6b7280;
}

.skill-icon-wrap {
  width: 44px;
  height: 44px;
  background: #f8fafc;
  border: 1px solid #d7dee7;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-size: 1.15rem;
  color: var(--dark);
}

.skill-name {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  margin-bottom: 0.45rem;
  color: var(--dark);
}

.skill-sub {
  font-size: 0.92rem;
  color: var(--mid);
  line-height: 1.65;
}

/* Projects */
.projects-bg {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  max-width: 1040px;
  margin: 0 auto;
}

.project-card {
  border: 1px solid var(--border);
  background: linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(17, 24, 39, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  display: flex;
  flex-direction: column;
}

.project-card:hover {
  transform: translateY(-4px);
  border-color: rgba(17, 24, 39, 0.14);
  box-shadow: 0 18px 42px rgba(17, 24, 39, 0.1);
}

.project-thumb {
  height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  border-bottom: 1px solid var(--border);
  background: linear-gradient(135deg, #f8fafc 0%, #eef2f7 100%);
}

.project-thumb-image {
  padding: 0;
  overflow: hidden;
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.project-body {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.project-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
  flex-wrap: wrap;
}

.project-badge {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #4b5563;
  background: #f1f5f9;
  border: 1px solid #dbe3ee;
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
}

.project-meta {
  font-size: 0.78rem;
  color: var(--light);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.project-title {
  font-family: 'Manrope', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--dark);
}

.project-desc {
  color: var(--mid);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 1rem;
}

.project-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.2rem;
}

.project-tag {
  background: var(--white);
  border: 1px solid var(--border);
  color: var(--mid);
  font-size: 0.72rem;
  padding: 0.2rem 0.6rem;
  letter-spacing: 0.05em;
}

.project-link {
  display: inline-block;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid var(--accent);
  padding-bottom: 1px;
  transition: color 0.2s;
  margin-top: auto;
}

.project-link:hover {
  color: #59755a;
}

/* Pricing */
.pricing-bg {
  background: var(--white);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.pricing-highlight {
  padding: 0 0 1.75rem;
  margin: 0 auto 2.5rem;
  max-width: 640px;
  text-align: center;
  font-size: 0.95rem;
  color: var(--dark);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
}

.pricing-highlight-kicker {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #6b7280;
}

.pricing-highlight-title {
  font-family: 'Manrope', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #111827;
}

.pricing-highlight-free {
  color: #16a34a;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.pricing-highlight-text {
  color: #4b5563;
  font-size: 0.91rem;
  line-height: 1.5;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  max-width: 920px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  position: relative;
}

.pricing-card:hover {
  border-color: var(--accent);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.pricing-card-featured {
  border-color: var(--accent);
  box-shadow: 0 15px 40px rgba(var(--accent-rgb), 0.15);
}

.pricing-card-featured:hover {
  box-shadow: 0 20px 50px rgba(var(--accent-rgb), 0.2);
}

.pricing-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(var(--accent-rgb), 0.08);
  border: 1px solid rgba(var(--accent-rgb), 0.2);
  padding: 0.4rem 0.85rem;
  border-radius: 20px;
  box-shadow: none;
}

.pricing-title {
  font-family: 'Manrope', sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--dark);
}

.pricing-price {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
}

.pricing-period {
  font-size: 1rem;
  font-weight: 400;
  color: var(--mid);
  display: block;
  margin-top: 0.25rem;
}

.pricing-description {
  font-size: 0.95rem;
  color: var(--light);
  margin-top: 0.5rem;
  line-height: 1.6;
}

.pricing-features {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin: 1.5rem 0;
  flex-grow: 1;
}

.pricing-feature {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.95rem;
  color: var(--mid);
  line-height: 1.5;
}

.pricing-feature-highlight {
  background: rgba(var(--accent-rgb), 0.05);
  padding: 0.45rem 0.7rem;
  border-radius: 6px;
  font-weight: 500;
  color: var(--dark);
}

.pricing-feature-highlight strong {
  font-weight: 700;
}

.check {
  color: var(--accent);
  font-weight: 700;
  flex-shrink: 0;
}

.pricing-btn {
  margin-top: auto;
}

.pricing-disclaimer {
  text-align: center;
  margin-top: 2.5rem;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  font-size: 0.9rem;
  color: var(--light);
  letter-spacing: 0.02em;
  line-height: 1.7;
}

/* Contact */
.contact-inner {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.contact-inner h2 {
  margin-bottom: 1rem;
}

.contact-inner p {
  color: var(--mid);
  margin-bottom: 2.5rem;
}

.contact-form {
  max-width: 700px;
  margin: 0 auto 1.4rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group-full {
  grid-column: 1 / -1;
}

.form-group label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--dark);
  letter-spacing: 0.05em;
}

.form-group input,
.form-group textarea {
  padding: 0.72rem 0.8rem;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-family: 'Manrope', sans-serif;
  font-size: 0.95rem;
  color: var(--dark);
  background: var(--white);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb), 0.1);
}

.form-group textarea {
  resize: none;
  overflow: hidden;
  font-size: 0.95rem;
  line-height: 1.6;
}

.contact-submit {
  width: auto;
  max-width: 100%;
  align-self: center;
  grid-column: 1 / -1;
  justify-self: center;
  padding-left: 1.6rem;
  padding-right: 1.6rem;
  margin-top: 0.35rem;
}

.contact-list {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.contact-list-compact {
  margin-top: 1.4rem;
}

.contact-item {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;
  --contact-icon-size: 40px;
  border: 1px solid rgba(17, 24, 39, 0.1);
  background: linear-gradient(180deg, #ffffff 0%, #fbfbfb 100%);
  color: var(--dark);
  padding: 0.85rem 1rem;
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 400;
  border-radius: 16px;
  min-width: 0;
  width: 100%;
  max-width: 360px;
  box-shadow: 0 10px 26px rgba(17, 24, 39, 0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.contact-item::after {
  content: '';
  display: block;
  width: var(--contact-icon-size);
  height: 1px;
  flex-shrink: 0;
}

.contact-item:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(17, 24, 39, 0.08);
}

.contact-icon {
  width: var(--contact-icon-size);
  height: var(--contact-icon-size);
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #d7dee7;
  color: #111827;
  font-size: 1rem;
  font-weight: 700;
}

.contact-icon-github {
  color: #111827;
}

.contact-content {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  min-width: 0;
  flex: 1;
  text-align: center;
}

.contact-item-title {
  font-family: 'Manrope', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.1;
}

.contact-item-sub {
  font-size: 0.78rem;
  color: var(--light);
  line-height: 1.2;
}

/* Footer */
footer {
  background: linear-gradient(180deg, #232323 0%, #1a1a1a 100%);
  color: rgba(255, 255, 255, 0.72);
  text-align: center;
  padding: 2.1rem 0 1.8rem;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

footer p {
  inline-size: min(var(--content-max), calc(100% - (var(--page-gutter) * 2)));
  margin-inline: auto;
  line-height: 1.6;
}

.footer-links {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  flex-wrap: nowrap;
  margin-top: 0.35rem;
  white-space: nowrap;
}

.footer-links span {
  color: rgba(255, 255, 255, 0.42);
  user-select: none;
}

footer a {
  color: rgba(255, 255, 255, 0.86);
  text-decoration: none;
  transition: color 0.2s ease;
}

footer a:hover {
  color: var(--white);
}

footer p:last-child {
  margin-top: 0.45rem;
  font-size: 0.7rem;
  opacity: 0.58;
  letter-spacing: 0.03em;
}

footer .footer-links a {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

/* Legal pages */
.legal-page {
  background: var(--cream);
}

.legal-main {
  padding: 2.75rem 0 4.25rem;
}

.legal-main > * {
  inline-size: min(var(--content-max), calc(100% - (var(--page-gutter) * 2)));
  margin-inline: auto;
}

.legal-card {
  max-width: 860px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 2.2rem 2.35rem;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.05);
}

.legal-header {
  margin-bottom: 1.5rem;
}

.legal-title {
  margin-bottom: 0.75rem;
  font-family: 'Manrope', sans-serif;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.15;
  color: var(--dark);
}

.legal-intro {
  color: var(--mid);
  max-width: 60ch;
  line-height: 1.8;
}

.legal-section {
  margin-top: 1.55rem;
}

.legal-section h2 {
  font-size: 1.28rem;
  margin-bottom: 0.7rem;
}

.legal-section p,
.legal-section li {
  color: var(--mid);
  line-height: 1.8;
}

.legal-section a {
  color: var(--accent);
  text-decoration: none;
}

.legal-section a:hover {
  color: #59755a;
  text-decoration: underline;
}

.legal-section ul {
  padding-left: 1.2rem;
  display: grid;
  gap: 0.5rem;
}

.legal-back {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: 1.8rem;
  color: var(--accent);
  text-decoration: none;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.legal-back:hover {
  color: #59755a;
}

/* Animations */
.js .reveal {
  opacity: 0;
  transition: opacity 0.85s ease;
  will-change: opacity;
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

.js .reveal[data-reveal-delay] {
  transition-delay: var(--reveal-delay, 0s);
}

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

  .hero-scroll-hint span {
    animation: none;
  }

  .hero-typing-word {
    border-right-color: transparent;
  }

  .hero-typing-cursor {
    animation: none;
  }

  .js .reveal,
  .js .reveal.is-visible {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

@media (max-width: 900px) {
  .hero {
    padding-top: clamp(2.5rem, 6vh, 4.75rem);
    padding-bottom: clamp(3rem, 6vh, 4.75rem);
  }

  .section-header {
    margin-bottom: 2.5rem;
  }

  .about-grid {
    gap: 3rem;
  }

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

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

  .pricing-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .pricing-highlight {
    margin: 0 auto 2rem;
    font-size: 0.92rem;
    padding: 1rem;
  }
}

@media (max-width: 700px) {
  .hero {
    padding-top: clamp(2.25rem, 5vh, 4rem);
    padding-bottom: clamp(2.75rem, 5vh, 4rem);
  }

  .hero::before {
    width: 10rem;
    height: 10rem;
    right: -3rem;
    top: -3rem;
  }

  .hero::after {
    width: 11rem;
    height: 11rem;
    left: -3.5rem;
    bottom: -4rem;
  }

  .hero-copy {
    text-align: center;
  }

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

  .hero-typing-line {
    gap: 0.06em;
  }

  .hero-typing-word {
    font-size: 0.92em;
  }

  .hero-typing-suffix {
    white-space: normal;
  }

  .hero-copy .hero-lead {
    font-size: 0.95rem;
    margin-bottom: 1.8rem;
  }

  .section-divider {
    width: min(72px, calc(100% - (var(--page-gutter) * 2)));
  }

  .hero-btns {
    justify-content: center;
    flex-direction: column;
    align-items: stretch;
    gap: 0.8rem;
    margin-bottom: 0.8rem;
  }

  .btn {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }

  .hero-cta-note {
    font-size: 0.72rem;
  }

  .hero-scroll-hint {
    bottom: 0.9rem;
    width: 1rem;
    height: 1.6rem;
  }

  section {
    padding: 1.5rem 0;
  }

  .about-grid {
    grid-template-columns: clamp(84px, 24vw, 108px) minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
  }

  .about-img-wrap {
    width: 100%;
    max-width: none;
    margin: 0;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
  }

  .about-img-wrap::after {
    display: none;
  }

  .about-text h2 {
    text-align: left;
    margin-bottom: 0.9rem;
  }

  .about-text p {
    margin-bottom: 0.85rem;
  }

  .about-facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
  }

  .skills-grid {
    grid-template-columns: 1fr;
    max-width: 520px;
  }

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

  .project-card-featured {
    grid-template-columns: 1fr;
  }

  .project-card-featured .project-thumb {
    min-height: 220px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .contact-list {
    flex-direction: column;
    align-items: center;
  }

  .contact-item {
    width: min(100%, 360px);
    justify-content: flex-start;
    min-width: 0;
    margin-inline: auto;
    --contact-icon-size: 38px;
  }

  .contact-icon {
    width: var(--contact-icon-size);
    height: var(--contact-icon-size);
  }

  .contact-content {
    gap: 0;
  }

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

  .form-group-full,
  .contact-submit {
    grid-column: auto;
  }

  .legal-main {
    padding: 1.5rem 0 3rem;
  }

  .legal-card {
    padding: 1.6rem 1.2rem;
    border-radius: 16px;
  }

  .legal-header {
    margin-bottom: 1.2rem;
  }

  .legal-title {
    font-size: clamp(1.8rem, 8vw, 2.3rem);
  }

  .legal-intro {
    font-size: 0.95rem;
  }

  .legal-section {
    margin-top: 1.25rem;
  }

  .legal-section h2 {
    font-size: 1.15rem;
  }

  .legal-section ul {
    padding-left: 1rem;
  }

  .legal-back {
    margin-top: 1.4rem;
    font-size: 0.78rem;
  }

  footer {
    padding: 1.5rem 0;
    font-size: 0.72rem;
  }

  nav ul {
    display: none;
  }

  .logo {
    font-size: 1.15rem;
  }

  .back-to-top {
    right: 1rem;
    bottom: 1rem;
  }

  nav {
    inline-size: 100%;
    margin: 0;
    padding: 1rem var(--page-gutter);
  }

  .nav-toggle {
    display: flex;
  }

  .nav-menu {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid var(--border);
    padding: 0;
    display: none;
    z-index: 99;
    max-height: none;
    overflow-y: visible;
    backdrop-filter: blur(14px);
  }

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

  .nav-menu li {
    list-style: none;
  }

  .nav-menu a {
    display: block;
    padding: 0.85rem var(--page-gutter);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    color: var(--mid);
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    transition: background 0.2s, color 0.2s;
  }

  .nav-menu a:hover,
  .nav-menu a.is-active {
    background: rgba(107, 138, 106, 0.05);
    color: var(--accent);
  }
}


@media (max-width: 480px) {
  .hero h1 {
    font-size: clamp(2rem, 10vw, 2.8rem);
  }

  .hero-typing-line {
    white-space: normal;
    flex-wrap: wrap;
    gap: 0.12em;
  }

  .hero-typing-word {
    white-space: nowrap;
    word-break: normal;
  }

  .hero-typing-suffix {
    white-space: normal;
  }

  .hero-copy .hero-lead {
    font-size: 0.92rem;
  }

  .about-grid {
    grid-template-columns: clamp(72px, 22vw, 92px) minmax(0, 1fr);
    gap: 0.8rem;
  }

  .about-text h2 {
    font-size: clamp(1.55rem, 7vw, 2rem);
  }

  .about-text p {
    font-size: 0.92rem;
    line-height: 1.65;
  }

  .about-facts {
    gap: 0.55rem;
  }

  .fact {
    padding-left: 0.65rem;
  }

  .fact-val {
    font-size: 1.2rem;
  }

  .fact-label {
    font-size: 0.68rem;
    line-height: 1.25;
  }

  .legal-main {
    padding: 1.1rem 0 2.4rem;
  }

  .legal-card {
    padding: 1.35rem 1rem;
  }

  .legal-title {
    font-size: clamp(1.6rem, 9vw, 2rem);
  }

  .legal-section h2 {
    font-size: 1.05rem;
  }

  .legal-section p,
  .legal-section li {
    font-size: 0.92rem;
  }
}

@keyframes scrollHint {
  0%, 100% {
    transform: translateY(0) rotate(45deg);
    opacity: 0.55;
  }
  50% {
    transform: translateY(3px) rotate(45deg);
    opacity: 1;
  }
}
