/* ===== Shubham Sunny: clean professional portfolio ===== */
@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap");

:root {
  --header-height: 3.25rem;
  --font: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
  --text: #0f172a;
  --text-muted: #64748b;
  --bg: #fbfdfc;
  --bg-subtle: #f3f8f6;
  --bg-muted: #f1f5f9;
  --border: #e2e8f0;
  --accent: #0f766e;
  --accent-hover: #0d9488;
  --accent-soft: rgba(15, 118, 110, 0.08);
  --glass-bg: rgba(251, 253, 252, 0.84);
  --glass-border: rgba(226, 232, 240, 0.55);
  --glass-blur: 28px;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 10px 40px -12px rgba(15, 23, 42, 0.12);
  --radius: 10px;
  --radius-lg: 16px;
  --max: 1080px;
  --z-header: 100;
  --z-fab: 50;

  /* Legacy tokens (components / JS hooks) */
  --body-font: var(--font);
  --first-color: var(--accent);
  --first-color-dark: #134e4a;
  --text-color: var(--text);
  --first-color-light: var(--text-muted);
  --first-color-lighten: #f8fafc;
  --h1-font-size: 1.5rem;
  --h2-font-size: 1.2rem;
  --h3-font-size: 1.05rem;
  --normal-font-size: 0.9375rem;
  --small-font-size: 0.8125rem;
  --smaller-font-size: 0.75rem;
  --biggest-font-size: 2.25rem;
  --font-medium: 500;
  --font-semi-bold: 600;
  --font-bold: 700;
  --mb-1: 0.5rem;
  --mb-2: 1rem;
  --mb-3: 1.5rem;
  --mb-4: 2rem;
  --mb-5: 2.5rem;
  --mb-6: 3rem;
  --z-fixed: 100;
  --z-tootip: 50;
}

@media (min-width: 768px) {
  :root {
    --header-height: 4rem;
    --biggest-font-size: 3rem;
    --h1-font-size: 1.875rem;
    --h2-font-size: 1.35rem;
    --h3-font-size: 1.125rem;
    --normal-font-size: 1rem;
  }
}

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

html {
  scroll-behavior: auto;
}

section[id] {
  scroll-margin-top: calc(var(--header-height) + 0.75rem);
}

/* ----- Section wrappers (no snap / no card stack / no forced viewport height) ----- */
.page-snap {
  position: relative;
}

.page-snap > section {
  position: relative;
  overflow: visible;
}

.page-snap > section.section-band--hero {
  background-color: #e8f5f0;
}

.page-snap > section.section-band--tone-b {
  background-color: #e5efe9;
}

.page-snap > section.section-band--tone-a {
  background-color: #f1f7f4;
}

.page-snap > section.testimonial--bleed {
  background-color: #e8faf4;
  overflow-x: visible;
}

.page-snap.ps-layer-1 > section#home {
  display: block;
}

.page-snap > section .section__inner,
.page-snap > section .bd-container,
.page-snap > section .home__container {
  position: relative;
  z-index: 1;
}

@media (max-width: 991.98px) {
  .page-snap > section .home__container {
    z-index: 0;
  }
}

.page-snap .section-band {
  width: 100%;
  max-width: none;
  margin-left: 0;
  margin-right: 0;
}

.page-snap .testimonial--bleed {
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
}

.services__cta {
  margin-top: 2.5rem;
}

@media (prefers-reduced-motion: reduce) {
  .page-snap > section {
    isolation: auto;
  }
}

html {
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  margin: 0;
  padding-top: var(--header-height);
  font-family: var(--font);
  font-size: var(--normal-font-size);
  color: var(--text);
  background: linear-gradient(168deg, #fbfdfc 0%, #f5faf8 38%, #f0f7f4 72%, #f5f8f6 100%);
  background-attachment: scroll;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-x: clip;
}

/* Stop page scroll-behind while mobile nav drawer is open */
@media (max-width: 991.98px) {
  body.nav-menu-open {
    overflow: hidden;
  }
}

@media (prefers-reduced-motion: reduce) {
  body {
    background: var(--bg);
  }
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 9999;
  padding: 0.65rem 1rem;
  background: var(--accent);
  color: #fff;
  font-weight: 600;
  border-radius: var(--radius);
  transition: top 0.2s;
}

.skip-link:focus {
  top: 1rem;
  outline: 2px solid var(--text);
  outline-offset: 2px;
}

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

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

a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

/* ----- Layout ----- */
.bd-container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.bd-grid {
  display: grid;
  gap: 1.5rem;
  min-width: 0;
}

/* ----- Header ----- */
.l-header,
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-header);
  background: rgba(251, 253, 252, 0.9);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.scroll-header {
  box-shadow: var(--shadow);
}

.nav {
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.nav__logo {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  max-width: min(52vw, 220px);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  letter-spacing: -0.02em;
  text-decoration: none;
}

.nav__logo-icon {
  flex-shrink: 0;
  width: 1.65rem;
  height: 1.65rem;
  object-fit: contain;
  border-radius: 6px;
}

.nav__logo-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (min-width: 768px) {
  .nav__logo {
    max-width: none;
  }

  .nav__logo-text {
    overflow: visible;
    text-overflow: unset;
    white-space: nowrap;
  }
}

.nav__logo:hover {
  color: var(--accent);
  text-decoration: none;
}

.nav__list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.nav__link {
  display: block;
  padding: 0.5rem 0.75rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: 6px;
  text-decoration: none;
}

.nav__link:hover {
  color: var(--text);
  background: var(--bg-muted);
  text-decoration: none;
}

.nav__link.active-link {
  color: var(--accent);
  background: var(--accent-soft);
}

.active-link::after {
  display: none;
}

.nav__toggle {
  font-size: 1.5rem;
  color: var(--text);
  cursor: pointer;
  padding: 0.35rem;
  border: none;
  background: transparent;
  border-radius: var(--radius);
  line-height: 1;
}

.nav__toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.nav__toggle-icon--close {
  display: none;
}

.nav__toggle.is-open .nav__toggle-icon--open {
  display: none;
}

.nav__toggle.is-open .nav__toggle-icon--close {
  display: block;
}

.nav__item {
  margin: 0;
}

/* Large screens: links in the bar (no hamburger) */
@media (min-width: 992px) {
  .nav {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: 0.65rem 0.85rem;
    height: calc(var(--header-height) + 0.25rem);
  }

  .nav__logo {
    grid-column: 1;
  }

  .nav__menu {
    grid-column: 2;
    justify-self: end;
    min-width: 0;
  }

  .nav__toggle {
    display: none !important;
  }

  .nav__menu {
    position: static;
    transform: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    height: auto;
    max-height: none;
    padding: 0;
    margin: 0;
    border: none;
    box-shadow: none;
    background: transparent;
    overflow: visible;
    z-index: auto;
  }

  .nav__list {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-end;
    align-items: center;
    gap: 0.1rem;
  }

  .nav__link {
    padding: 0.4rem 0.55rem;
    font-size: 0.75rem;
  }
}

/* Phones & tablets: logo + name + menu icon; links slide down below the bar */
@media (max-width: 991.98px) {
  .site-header,
  .l-header {
    z-index: 200;
  }

  .nav {
    gap: 0.5rem;
  }

  .nav__logo {
    flex: 1;
    min-width: 0;
    max-width: none;
    z-index: 210;
    position: relative;
  }

  .nav__toggle {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 2.6rem;
    height: 2.6rem;
    z-index: 210;
    position: relative;
  }

  .nav__menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    height: calc(100dvh - var(--header-height));
    max-height: calc(100dvh - var(--header-height));
    padding: 0.65rem 1.15rem calc(1.1rem + env(safe-area-inset-bottom, 0px));
    margin: 0;
    background: var(--glass-bg);
    border-top: 1px solid var(--glass-border);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    box-shadow: 0 22px 60px rgba(15, 23, 42, 0.16);
    z-index: 150;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
      transform 0.28s cubic-bezier(0.22, 1, 0.36, 1),
      opacity 0.22s ease,
      visibility 0.28s;
  }

  .nav__menu.show-menu {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav__list {
    gap: 0.2rem;
  }

  .nav__link {
    padding: 0.65rem 0.85rem;
    font-size: 0.9375rem;
  }
}

@media (max-width: 991.98px) and (prefers-reduced-motion: reduce) {
  .nav__menu {
    transition: none;
  }
}

/* ----- Scroll top ----- */
.scrolltop {
  position: fixed;
  right: 1rem;
  bottom: -4rem;
  width: 2.75rem;
  height: 2.75rem;
  display: grid;
  place-items: center;
  background: var(--text);
  color: #fff;
  border-radius: 50%;
  z-index: var(--z-fab);
  box-shadow: var(--shadow-md);
  transition: bottom 0.3s, transform 0.2s;
  text-decoration: none;
}

.scrolltop:hover {
  transform: translateY(-2px);
  text-decoration: none;
  background: var(--accent);
}

.scrolltop__icon {
  font-size: 1.5rem;
}

.show-scroll {
  bottom: 1.25rem;
}

/* ----- Hero ----- */
.home.section-band--hero {
  padding: 2rem 0 2.75rem;
  border-bottom: none;
  box-shadow: none;
  background: linear-gradient(165deg, #e8f5f0 0%, #f4fbf8 38%, #fafefc 100%);
}

.home__container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  position: relative;
  z-index: 1;
}

.hero__grid {
  display: grid;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 900px) {
  .hero__grid {
    grid-template-columns: minmax(0, 1fr) minmax(220px, 32%);
    gap: 2.5rem 3rem;
    align-items: start;
  }
}

.home__greeting {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.home__name {
  font-size: var(--biggest-font-size);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--text);
  margin-bottom: 0.5rem;
}

/* Hero focus areas: same order as portfolio filters */
.home__focus-chips {
  list-style: none;
  margin: 0 0 1.1rem;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.5rem;
  max-width: 42rem;
}

.home__focus-chip {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 0.38rem 0.72rem;
  font-size: clamp(0.7rem, 1.35vw, 0.8125rem);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: 0.02em;
  color: var(--accent);
  background: rgba(15, 118, 110, 0.09);
  border: 1px solid rgba(15, 118, 110, 0.2);
  border-radius: 999px;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease;
}

.home__focus-chip:hover {
  background: rgba(15, 118, 110, 0.14);
  border-color: rgba(15, 118, 110, 0.32);
}

@media (prefers-reduced-motion: reduce) {
  .home__focus-chip {
    transition: none;
  }
}

.home__tagline {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 36rem;
  line-height: 1.65;
  margin-bottom: 1.5rem;
}

.home__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.home__connect {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(15, 118, 110, 0.1);
  max-width: 36rem;
}

.home__connect-label {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-muted);
  margin: 0 0 0.65rem;
}

.home__connect-email {
  margin: 0.75rem 0 0;
  font-size: 0.8125rem;
}

.home__connect-email a {
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  word-break: break-word;
}

.home__connect-email a:hover {
  text-decoration: underline;
}

.hero__photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}

@media (min-width: 900px) {
  .hero__photo {
    align-items: flex-end;
  }
}

.hero__connect-chip {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  max-width: min(100%, 300px);
  padding: 0.55rem 0.75rem;
  border-radius: var(--radius);
  font-size: 0.6875rem;
  line-height: 1.25;
  color: var(--text-muted);
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);
}

@media (min-width: 900px) {
  .hero__connect-chip {
    max-width: min(100%, 340px);
  }
}

.hero__connect-chip:hover {
  color: var(--text);
  background: var(--bg-muted);
  border-color: rgba(15, 118, 110, 0.25);
  text-decoration: none;
  box-shadow: var(--shadow-md);
}

.hero__connect-chip-icon {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  line-height: 0;
}

.hero__connect-chip-copy {
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
  min-width: 0;
  text-align: left;
}

.hero__connect-chip-lead {
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.hero__connect-chip-address {
  font-size: 0.625rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1.3;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.hero__connect-chip-hint {
  font-weight: 500;
  font-size: 0.5625rem;
  color: var(--text-muted);
  white-space: nowrap;
}

.home__img {
  margin: 0;
  width: 100%;
  max-width: min(100%, 300px);
}

@media (min-width: 900px) {
  .home__img {
    max-width: min(100%, 340px);
  }
}

.home__photo {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.home__social {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 0.65rem;
}

@media (max-width: 899px) {
  .home__connect {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
  }

  .home__social {
    justify-content: center;
  }
}

.home__social-icon {
  display: grid;
  place-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 1.2rem;
  text-decoration: none;
  transition:
    color 0.2s,
    border-color 0.2s,
    background 0.2s;
}

.home__social-icon:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-soft);
  text-decoration: none;
}

.home__social-icon img {
  width: 1.1rem;
  height: auto;
  opacity: 0.7;
}

.home__social-icon--gmail {
  color: #c5221f;
}

.home__social-icon--gmail:hover {
  color: #a50e0e;
}

.hero__trust {
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-align: center;
  max-width: 44rem;
  margin: 1.5rem auto 0;
  padding-top: 0;
  border-top: none;
}

@media (min-width: 900px) {
  .hero__trust {
    text-align: left;
    margin: 1.75rem 0 0;
    max-width: none;
  }
}

/* ----- Buttons ----- */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.25rem;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s,
    box-shadow 0.2s;
}

.button:hover {
  text-decoration: none;
}

.button--primary {
  background: var(--accent);
  color: #fff;
}

.button--primary:hover {
  background: var(--accent-hover);
}

.button--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.button--ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}

.button--small {
  padding: 0.5rem 0.9rem;
  font-size: 0.8125rem;
}

.button-light {
  background: var(--accent);
  color: #fff;
}

.button-white {
  background: #fff;
  color: var(--accent);
  border-color: rgba(255, 255, 255, 0.5);
}

.button-link {
  background: none;
  border: none;
  padding: 0;
  font-weight: 600;
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

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

/* ----- Sections ----- */
.section {
  padding: 3.5rem 0;
}

.section-header {
  text-align: center;
  max-width: 40rem;
  margin: 0 auto 2.5rem;
}

.section-subtitle {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.section-title {
  font-size: var(--h1-font-size);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
  line-height: 1.2;
  margin-bottom: 0.75rem;
}

.section-title::after {
  display: none;
}

.section-lead {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ----- Full-bleed alternating section bands ----- */
.section-band {
  width: 100vw;
  max-width: 100%;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  position: relative;
  overflow-x: clip;
}

.section-band--tone-a {
  background: linear-gradient(180deg, #f8fcfa 0%, #f1f7f4 45%, #f5faf8 100%);
  border-block: 1px solid rgba(15, 118, 110, 0.07);
}

.section-band--tone-b {
  background: linear-gradient(178deg, #edf4f0 0%, #e5efe9 40%, #eef6f2 100%);
  border-block: 1px solid rgba(15, 118, 110, 0.078);
}

.section-band--tone-a::after,
.section-band--tone-b::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(ellipse 58% 42% at 96% 4%, rgba(15, 118, 110, 0.07), transparent 58%),
    radial-gradient(ellipse 50% 38% at 3% 96%, rgba(13, 148, 136, 0.06), transparent 55%);
  animation: band-mesh-shift 18s ease-in-out infinite alternate;
}

.section-band--hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(ellipse 60% 50% at 85% 15%, rgba(15, 118, 110, 0.08), transparent 52%),
    radial-gradient(ellipse 45% 40% at 12% 88%, rgba(20, 184, 166, 0.06), transparent 48%);
  animation: band-mesh-shift 20s ease-in-out infinite alternate-reverse;
}

.section__inner {
  position: relative;
  z-index: 1;
  min-width: 0;
}

@keyframes band-mesh-shift {
  from {
    opacity: 0.55;
    transform: scale(1);
  }
  to {
    opacity: 0.85;
    transform: scale(1.02);
  }
}

@media (prefers-reduced-motion: reduce) {
  .section-band--tone-a::after,
  .section-band--tone-b::after,
  .section-band--hero::after {
    animation: none;
    opacity: 0.65;
    transform: none;
  }
}

/* ----- About ----- */
.about {
  background: transparent;
}

.about__collab {
  margin: 0 auto 2.5rem;
  max-width: 920px;
  text-align: center;
  padding: 1.35rem 1rem 1.5rem;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.about__collab-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  margin: 0 0 1rem;
  line-height: 1.45;
}

.about__logo-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0.55rem 0.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.about__logo-item {
  display: grid;
  place-items: center;
  min-height: 2.6rem;
  min-width: 2.6rem;
  padding: 0.35rem 0.6rem;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}

.about__logo-item:hover {
  transform: translateY(-2px);
  border-color: rgba(15, 118, 110, 0.25);
  box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
}

.about__logo-item img {
  width: 26px;
  height: 26px;
  opacity: 0.88;
  filter: grayscale(1) contrast(0.92);
  transition:
    filter 0.2s ease,
    opacity 0.2s ease;
}

.about__logo-item:hover img {
  filter: grayscale(0) contrast(1);
  opacity: 1;
}

.about__logo-item--text span {
  display: block;
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-muted);
  white-space: nowrap;
}

.about__collab-note {
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin: 1rem auto 0;
  max-width: 40rem;
}

@media (max-width: 480px) {
  .about__logo-item--text span {
    font-size: 0.58rem;
    letter-spacing: 0.05em;
  }

  .about__logo-item {
    padding: 0.3rem 0.5rem;
    min-height: 2.35rem;
  }
}

.about__container {
  align-items: start;
}

@media (min-width: 768px) {
  .about__container {
    grid-template-columns: minmax(200px, 320px) 1fr;
    gap: 2.5rem;
    align-items: start;
  }
}

.about__img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  width: 100%;
  max-width: 320px;
  margin-inline: auto;
}

@media (min-width: 768px) {
  .about__img {
    margin-inline: 0;
  }
}

.about__highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.highlight {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.85rem 0.65rem;
  text-align: center;
}

.highlight__value {
  display: block;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
}

.highlight__label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.prose,
.about__description {
  color: var(--text-muted);
  font-size: 0.975rem;
  line-height: 1.75;
}

.about__description span {
  color: var(--text);
  font-weight: 600;
}

.about__panels {
  display: grid;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}

@media (min-width: 768px) {
  .about__panels {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }
}

.about__panel {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
}

.about__panel-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 0.65rem;
  letter-spacing: -0.01em;
}

.about__list {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.65;
}

.about__list li + li {
  margin-top: 0.5rem;
}

.about__kicker {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.65;
  color: var(--text-muted);
}

/* ----- Timeline (experience & education) ----- */
.qualification {
  background: transparent;
}

.timeline {
  position: relative;
  display: grid;
  gap: 2.5rem;
  max-width: 920px;
  margin: 0 auto;
  padding-left: 0.5rem;
}

@media (min-width: 768px) {
  .timeline {
    grid-template-columns: 1fr 1fr;
    gap: 2rem 3.5rem;
    padding-left: 0;
  }
}

.timeline__rail {
  display: none;
}

.timeline__block {
  position: relative;
}

.timeline__label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 1.25rem;
  padding: 0.35rem 0.75rem;
  background: var(--accent-soft);
  border-radius: 999px;
  border: 1px solid rgba(15, 118, 110, 0.15);
}

.timeline__label i {
  font-size: 1.1rem;
}

.timeline__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.timeline__item {
  position: relative;
  padding-left: 1.5rem;
  padding-bottom: 1.5rem;
  margin: 0;
}

.timeline__item:last-child {
  padding-bottom: 0;
}

.timeline__item::before {
  content: "";
  position: absolute;
  left: 0.3rem;
  top: 0.35rem;
  bottom: -0.35rem;
  width: 2px;
  background: var(--border);
}

.timeline__item:last-child::before {
  bottom: 0.5rem;
}

.timeline__dot {
  position: absolute;
  left: 0;
  top: 0.45rem;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  box-shadow: 0 0 0 2px var(--accent-soft);
  z-index: 1;
}

.timeline__card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.15rem;
  box-shadow: var(--shadow);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.timeline__card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.timeline__time {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.35rem;
}

.timeline__heading {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.35rem;
  line-height: 1.3;
}

.timeline__detail {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

/* ----- Portfolio ----- */
.portfolio {
  background: transparent;
}

/* Horizontal scroll on phones; wrap on tablet/desktop */
.portfolio__nav-wrap {
  margin-bottom: 2rem;
  padding-bottom: 0.35rem;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
}

@media (max-width: 767px) {
  .portfolio__nav-wrap {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding-inline: 1rem;
  }
}

.portfolio__nav-wrap::-webkit-scrollbar {
  height: 5px;
}

.portfolio__nav-wrap::-webkit-scrollbar-thumb {
  background: rgba(15, 118, 110, 0.25);
  border-radius: 999px;
}

.portfolio__nav {
  display: flex;
  flex-wrap: nowrap;
  justify-content: flex-start;
  align-items: center;
  gap: 0.4rem;
  width: max-content;
  min-width: 100%;
  padding: 0.15rem 0;
}

.portfolio__item {
  flex-shrink: 0;
  padding: 0.4rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(6px);
  cursor: pointer;
  white-space: nowrap;
  transition:
    color 0.22s ease,
    border-color 0.22s ease,
    background 0.22s ease,
    box-shadow 0.22s ease;
}

.portfolio__item:hover {
  color: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 4px 14px rgba(15, 118, 110, 0.12);
}

@media (min-width: 768px) {
  .portfolio__nav-wrap {
    width: auto;
    max-width: none;
    margin-left: 0;
    margin-right: 0;
    padding-inline: 0;
    overflow-x: visible;
    padding-bottom: 0;
  }

  .portfolio__nav {
    flex-wrap: wrap;
    justify-content: center;
    width: auto;
    min-width: 0;
  }
}

.portfolio__item.active-portfolio {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.portfolio__filter-empty {
  text-align: center;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0 0 1.5rem;
  padding: 1rem;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.7);
  border: 1px dashed var(--border);
}

.portfolio__filter-empty[hidden] {
  display: none;
}

button.portfolio__item {
  font-family: inherit;
  appearance: none;
  -webkit-appearance: none;
}

.portfolio__container {
  gap: 1.75rem;
  align-items: start;
}

.portfolio__load-error {
  grid-column: 1 / -1;
  margin: 0;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-lg);
  background: rgba(185, 28, 28, 0.08);
  border: 1px solid rgba(185, 28, 28, 0.25);
  color: #7f1d1d;
}

@media (min-width: 576px) {
  .portfolio__container:not(.projects-bento) {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .portfolio__container:not(.projects-bento) {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* No transform transition: MixItUp animates transform on filter; hover translate fights it and looks janky */
.portfolio__content {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(15, 118, 110, 0.1);
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition:
    box-shadow 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    border-color 0.3s ease;
}

.portfolio__content:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.portfolio__content .button-link {
  cursor: pointer;
  position: relative;
  z-index: 1;
}

.portfolio__content:hover {
  box-shadow: 0 16px 40px -12px rgba(15, 23, 42, 0.14), 0 0 0 1px rgba(15, 118, 110, 0.08);
  border-color: rgba(15, 118, 110, 0.22);
}

/* Full screenshot visible inside a fixed frame (wide Play Store shots were cropped with cover) */
.portfolio__content .swiper-slide > a.glightbox {
  display: block;
  line-height: 0;
  background: var(--bg-subtle);
}

.portfolio__img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: contain;
  object-position: center center;
  background-color: var(--bg-subtle);
  transition: opacity 0.3s ease;
}

.portfolio__content:hover .portfolio__img {
  opacity: 0.97;
}

.portfolio__data {
  padding: 1.15rem 1.2rem 1.25rem;
  border-top: 1px solid var(--border);
}

.portfolio__subtitle {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent);
}

.portfolio__title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin: 0.4rem 0 0.5rem;
  line-height: 1.35;
}

.portfolio__data p {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ----- Reviews (marquee + modal) ----- */
.testimonial {
  overflow: hidden;
}

.testimonial--bleed {
  --testimonial-fade: #e8f8f4;
  width: 100vw;
  max-width: 100%;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  position: relative;
  isolation: isolate;
  background: linear-gradient(
    155deg,
    #dff8f0 0%,
    #e8faf5 28%,
    #f0fdfa 58%,
    #eff6f4 100%
  );
  border-block: 1px solid rgba(15, 118, 110, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.testimonial--bleed::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(ellipse 70% 55% at 15% 10%, rgba(15, 118, 110, 0.09), transparent 55%),
    radial-gradient(ellipse 55% 50% at 92% 88%, rgba(13, 148, 136, 0.08), transparent 50%);
  animation: testimonial-glow 14s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes testimonial-glow {
  from {
    opacity: 0.85;
    transform: scale(1);
  }
  to {
    opacity: 1;
    transform: scale(1.03);
  }
}

@media (prefers-reduced-motion: reduce) {
  .testimonial--bleed::before {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

.testimonial--bleed .section-header {
  animation: testimonial-header-in 0.85s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

@keyframes testimonial-header-in {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .testimonial--bleed .section-header {
    animation: none;
  }
}

.testimonial--bleed > .bd-container,
.testimonial--bleed > .reviews-marquee-wrap {
  position: relative;
  z-index: 1;
}

.reviews-source {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.reviews-marquee-wrap {
  position: relative;
  margin: 0;
  padding: 0.75rem 0 0.5rem;
}

.reviews-marquee__edge {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 3rem;
  z-index: 2;
  pointer-events: none;
}

.reviews-marquee__edge--left {
  left: 0;
  background: linear-gradient(90deg, var(--testimonial-fade, var(--bg-subtle)), transparent);
}

.reviews-marquee__edge--right {
  right: 0;
  background: linear-gradient(270deg, var(--testimonial-fade, var(--bg-subtle)), transparent);
}

.reviews-marquee {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, black 4%, black 96%, transparent);
}

.reviews-marquee__viewport {
  overflow: hidden;
}

.reviews-marquee__track {
  display: flex;
  gap: 1.25rem;
  width: max-content;
  padding: 0.25rem 0;
  animation: reviews-marquee-scroll 85s linear infinite;
}

.reviews-marquee__track.is-paused {
  animation-play-state: paused;
}

@keyframes reviews-marquee-scroll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .reviews-marquee__track {
    animation: none;
    flex-wrap: wrap;
    width: 100%;
    justify-content: center;
  }

  .reviews-marquee .review-card {
    animation: none;
  }
}

.reviews-marquee .review-card {
  flex: 0 0 300px;
  max-width: 300px;
  background: var(--bg);
  border: 1px solid rgba(15, 118, 110, 0.14);
  border-radius: var(--radius-lg);
  padding: 1.15rem 1.1rem;
  box-shadow: var(--shadow);
  animation: review-card-float-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

.reviews-marquee .review-card:nth-child(odd) {
  animation-delay: 0.08s;
}

@keyframes review-card-float-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.review-card__avatar-wrap {
  position: relative;
  width: 48px;
  height: 48px;
  margin: 0 auto 0.65rem;
}

.review-card__avatar {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  margin: 0;
  border: 2px solid rgba(15, 118, 110, 0.2);
}

.review-card__avatar--hidden {
  display: none !important;
}

.review-card__avatar-fallback {
  display: none;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  place-items: center;
  font-size: 1.4rem;
  line-height: 1;
  background: linear-gradient(145deg, #ccfbf1, var(--accent-soft));
  border: 2px solid rgba(15, 118, 110, 0.22);
  box-shadow: 0 2px 10px rgba(15, 118, 110, 0.12);
}

.review-card__avatar-fallback.is-visible {
  display: grid;
}

.review-card__name {
  font-size: 0.95rem;
  font-weight: 700;
  text-align: center;
  color: var(--text);
  margin: 0;
}

.review-card__loc {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin: 0.35rem 0 0.4rem;
}

.review-card__stars {
  text-align: center;
  font-size: 0.8rem;
  margin-bottom: 0.45rem;
}

.star-rating {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.12rem;
  font-size: 0;
  line-height: 1;
  vertical-align: middle;
}

.star-rating__star {
  font-size: 1.05rem;
  line-height: 1;
  letter-spacing: 0;
  transition: transform 0.2s ease;
}

.star-rating__star--full {
  color: #e79712;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
}

.star-rating__star--empty {
  color: #cbd5e1;
  font-size: 1rem;
}

.reviews-marquee .review-card:hover .star-rating__star--full {
  transform: scale(1.08);
}

.review-card__text {
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.5;
  text-align: center;
  margin: 0 0 0.6rem;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.review-card__link {
  display: block;
  text-align: center;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}

.review-card__link:hover {
  text-decoration: underline;
}

.reviews-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 1.5rem;
}

.reviews-actions__hint {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* Reviews modal */
.reviews-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 1rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.reviews-modal.is-open {
  pointer-events: auto;
  opacity: 1;
}

.reviews-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(6px);
}

.reviews-modal__dialog {
  position: relative;
  max-width: min(1180px, 96vw);
  width: 100%;
  max-height: min(90vh, 920px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.25);
  transform: translateY(28px) scale(0.94);
  opacity: 0;
  transition:
    transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.38s ease;
}

.reviews-modal.is-open .reviews-modal__dialog {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.reviews-modal__close {
  position: absolute;
  top: 0.85rem;
  right: 0.85rem;
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 50%;
  background: var(--bg-muted);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  transition:
    background 0.2s,
    transform 0.2s;
}

.reviews-modal__close:hover {
  background: var(--border);
  transform: rotate(90deg);
}

.reviews-modal__title {
  padding: 1.5rem 3rem 0.35rem 1.5rem;
  font-size: 1.35rem;
  font-weight: 700;
}

.reviews-modal__subtitle {
  padding: 0 1.5rem 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0;
  border-bottom: 1px solid var(--border);
}

.reviews-modal__grid {
  overflow-y: auto;
  overflow-x: hidden;
  padding: 1rem 1.25rem 1.5rem;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1rem;
  align-items: stretch;
}

@media (min-width: 1100px) {
  .reviews-modal__grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.reviews-modal__item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.05rem 1.1rem;
  min-height: 100%;
  cursor: pointer;
  animation: reviews-modal-item-in 0.55s cubic-bezier(0.22, 1, 0.36, 1) backwards;
  transition:
    transform 0.25s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.25s ease,
    border-color 0.2s ease;
  height: max-content;
  
}

.reviews-modal__item:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(15, 118, 110, 0.28);
}

.reviews-modal__item:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.reviews-modal__item:nth-child(1) {
  animation-delay: 0.03s;
}
.reviews-modal__item:nth-child(2) {
  animation-delay: 0.06s;
}
.reviews-modal__item:nth-child(3) {
  animation-delay: 0.09s;
}
.reviews-modal__item:nth-child(4) {
  animation-delay: 0.12s;
}
.reviews-modal__item:nth-child(5) {
  animation-delay: 0.15s;
}
.reviews-modal__item:nth-child(n + 6) {
  animation-delay: 0.18s;
}

@keyframes reviews-modal-item-in {
  from {
    opacity: 0;
    transform: translateX(-12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.reviews-modal__item .review-card__avatar-wrap {
  margin: 0 0 0.25rem;
}

.reviews-modal__item .review-card__avatar {
  margin: 0;
}

.reviews-modal__item .review-card__name,
.reviews-modal__item .review-card__loc,
.reviews-modal__item .review-card__stars,
.reviews-modal__item .review-card__text,
.reviews-modal__item .review-card__link {
  text-align: left;
  align-self: stretch;
}

.reviews-modal__item .review-card__loc {
  justify-content: flex-start;
}

.reviews-modal__item .review-card__text {
  -webkit-line-clamp: unset;
  display: block;
  margin: 0.25rem 0 0.35rem;
}

@media (prefers-reduced-motion: reduce) {
  .reviews-modal__dialog,
  .reviews-modal__item {
    animation: none;
    transition: none;
    transform: none;
  }

  .reviews-modal__item:hover {
    transform: none;
    box-shadow: none;
  }
}

/* Projects modal (all projects — full viewport) */
.projects-modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  padding: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
  overscroll-behavior: none;
}

.projects-modal.is-open {
  pointer-events: auto;
  opacity: 1;
}

.projects-modal__backdrop {
  position: absolute;
  inset: 0;
  background: var(--bg);
}

.projects-modal__dialog {
  position: relative;
  width: 100%;
  height: 100%;
  height: 100dvh;
  max-width: none;
  max-height: none;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-radius: 0;
  border: none;
  box-shadow: none;
  transform: none;
  opacity: 1;
  transition: opacity 0.35s ease;
}

.projects-modal.is-open .projects-modal__dialog {
  transform: none;
  opacity: 1;
}

.projects-modal__close {
  position: absolute;
  top: max(0.85rem, env(safe-area-inset-top, 0px));
  right: max(0.85rem, env(safe-area-inset-right, 0px));
  width: 2.75rem;
  height: 2.75rem;
  border: none;
  border-radius: 50%;
  background: var(--bg-muted);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  transition:
    background 0.2s,
    transform 0.2s;
}

.projects-modal__close:hover {
  background: var(--border);
  transform: rotate(90deg);
}

.projects-modal__title {
  padding: max(1.25rem, env(safe-area-inset-top, 0px) + 0.75rem) 3.5rem 0.35rem 1rem;
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0;
  flex-shrink: 0;
}

.projects-modal__subtitle {
  padding: 0 1rem 0.85rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin: 0;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.projects-modal__filters-wrap {
  padding: 0.75rem 1rem 0;
  flex-shrink: 0;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
}

.projects-modal__filters {
  margin: 0;
}

.projects-modal__filter-empty {
  padding: 0.5rem 1rem 0;
  margin: 0;
  flex-shrink: 0;
}

.projects-modal__body {
  overflow-x: hidden;
  overflow-y: auto;
  flex: 1;
  min-width: 0;
  min-height: 0;
  padding: 0.75rem 1rem max(1rem, env(safe-area-inset-bottom, 0px) + 0.5rem);
  -webkit-overflow-scrolling: touch;
  scroll-behavior: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
}

.projects-modal__grid.projects-bento {
  width: 100%;
  max-width: none;
  margin: 0;
  gap: 1.75rem;
  contain: layout style;
}

.projects-modal__grid .project-card {
  content-visibility: auto;
  contain-intrinsic-size: auto 420px;
  contain: layout style paint;
  border-radius: 1.1rem;
  border-width: 1.5px;
  max-width: 100%;
  overflow: hidden;
}

.projects-modal__grid .project-card__accent-bar {
  height: 4px;
}

.projects-modal__grid .project-card__preview,
.projects-modal__grid .project-card__preview--image {
  min-height: 130px;
}

.projects-modal__grid .project-card__iframe-wrap,
.projects-modal__grid .project-card__iframe,
.projects-modal__grid .project-card__preview-link,
.projects-modal__grid .project-card__preview-img {
  min-height: 140px;
}

.projects-modal__grid .project-card__preview--placeholder {
  min-height: 140px;
  padding: 1rem;
}

.projects-modal__grid .project-card__preview--placeholder p {
  font-size: 0.8125rem;
}

.projects-modal__grid .project-card__body {
  padding: 0.65rem 0.8rem 0.8rem;
  gap: 0.35rem;
}

.projects-modal__grid .project-card__title {
  font-size: 0.875rem;
  line-height: 1.3;
}

.projects-modal__grid .project-card__highlights {
  font-size: 0.71875rem;
  line-height: 1.45;
  padding-left: 0.85rem;
  margin: 0;
}

.projects-modal__grid .project-card__highlights li + li {
  margin-top: 0.2rem;
}

.projects-modal__grid .project-card__tag {
  font-size: 0.5625rem;
  padding: 0.15rem 0.38rem;
}

.projects-modal__grid .project-card__cta {
  padding: 0.5rem 0.75rem !important;
  font-size: 0.71875rem !important;
  gap: 0.35rem;
}

.projects-modal__grid .project-card__cta .bx {
  font-size: 1rem;
}

@media (min-width: 768px) {
  .projects-modal__grid .project-card__iframe-wrap,
  .projects-modal__grid .project-card__iframe,
  .projects-modal__grid .project-card__preview-link,
  .projects-modal__grid .project-card__preview-img {
    min-height: 165px;
  }

  .projects-modal__grid .project-card--wide .project-card__iframe-wrap,
  .projects-modal__grid .project-card--wide .project-card__iframe {
    min-height: 175px;
  }
}

@media (min-width: 992px) {
  .projects-modal__grid.projects-bento {
    gap: 2rem;
  }

  .projects-modal__grid .project-card--feature .project-card__iframe-wrap,
  .projects-modal__grid .project-card--feature .project-card__iframe,
  .projects-modal__grid .project-card--feature .project-card__preview--image {
    min-height: 200px;
  }

  .projects-modal__grid .project-card--tall .project-card__iframe-wrap,
  .projects-modal__grid .project-card--tall .project-card__iframe {
    min-height: 185px;
  }

  .projects-modal__grid .project-card--wide .project-card__iframe-wrap,
  .projects-modal__grid .project-card--wide .project-card__iframe {
    min-height: 180px;
  }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .projects-modal__grid.projects-bento {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .projects-modal__grid .project-card--feature,
  .projects-modal__grid .project-card--wide {
    grid-column: 1 / -1;
  }

  .projects-modal__grid .project-card--tall,
  .projects-modal__grid .project-card--standard,
  .projects-modal__grid .project-card--half {
    grid-column: auto;
  }
}

@media (max-width: 767px) {
  .projects-modal__title {
    font-size: 1.125rem;
    padding: max(1rem, env(safe-area-inset-top, 0px) + 0.5rem) 3.25rem 0.25rem
      max(0.85rem, env(safe-area-inset-left, 0px) + 0.25rem);
  }

  .projects-modal__subtitle {
    font-size: 0.8125rem;
    padding: 0 max(0.85rem, env(safe-area-inset-right, 0px) + 0.25rem) 0.7rem
      max(0.85rem, env(safe-area-inset-left, 0px) + 0.25rem);
  }

  .projects-modal__close {
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.35rem;
    top: max(0.65rem, env(safe-area-inset-top, 0px));
    right: max(0.65rem, env(safe-area-inset-right, 0px));
  }

  .projects-modal__filters-wrap {
    padding: 0.5rem max(0.85rem, env(safe-area-inset-right, 0px) + 0.25rem) 0
      max(0.85rem, env(safe-area-inset-left, 0px) + 0.25rem);
  }

  .projects-modal__filters .portfolio__item {
    font-size: 0.6875rem;
    padding: 0.38rem 0.65rem;
    min-height: 2.25rem;
  }

  .projects-modal__body {
    padding: 0.5rem max(0.85rem, env(safe-area-inset-right, 0px) + 0.25rem)
      max(0.85rem, env(safe-area-inset-bottom, 0px) + 0.5rem)
      max(0.85rem, env(safe-area-inset-left, 0px) + 0.25rem);
  }

  .projects-modal__grid.projects-bento {
    grid-template-columns: 1fr !important;
    gap: 1.15rem;
  }

  .projects-modal__grid .project-card--feature,
  .projects-modal__grid .project-card--tall,
  .projects-modal__grid .project-card--wide,
  .projects-modal__grid .project-card--standard,
  .projects-modal__grid .project-card--half {
    grid-column: 1 / -1 !important;
  }

  .projects-modal__grid .project-card__iframe-wrap,
  .projects-modal__grid .project-card__iframe,
  .projects-modal__grid .project-card__preview-link,
  .projects-modal__grid .project-card__preview-img {
    min-height: 155px;
  }

  .projects-modal__grid .project-card__preview--placeholder {
    min-height: 155px;
    padding: 0.85rem;
  }

  .projects-modal__grid .project-card__body {
    padding: 0.6rem 0.75rem 0.75rem;
  }

  .projects-modal__grid .project-card__title {
    font-size: 0.8375rem;
  }

  .projects-modal__grid .project-card__highlights {
    font-size: 0.6875rem;
  }

  .projects-modal__grid .project-card__cta {
    min-height: 2.5rem;
    padding: 0.55rem 0.7rem !important;
    font-size: 0.6875rem !important;
  }

  .projects-modal__grid .project-card__preview-badge {
    font-size: 0.5625rem;
    bottom: 0.45rem;
    right: 0.45rem;
    padding: 0.22rem 0.45rem;
  }
}

@media (max-width: 380px) {
  .projects-modal__title {
    font-size: 1.05rem;
  }

  .projects-modal__grid .project-card__iframe-wrap,
  .projects-modal__grid .project-card__iframe,
  .projects-modal__grid .project-card__preview-link,
  .projects-modal__grid .project-card__preview-img {
    min-height: 135px;
  }

  .projects-modal__grid .project-card__highlights {
    font-size: 0.6625rem;
  }
}

html.projects-modal-open,
body.projects-modal-open {
  overflow: hidden !important;
  overscroll-behavior: none;
}

body.projects-modal-open {
  position: fixed;
  width: 100%;
  left: 0;
  right: 0;
}

.portfolio__more-wrap {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
  padding-bottom: 0.25rem;
}

.portfolio__more-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.portfolio__more-count {
  font-weight: 500;
  opacity: 0.88;
}

@media (prefers-reduced-motion: reduce) {
  .projects-modal__dialog {
    animation: none;
    transition: none;
    transform: none;
  }
}

/* Single-review detail (opens above grid modal) */
.review-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 2100;
  display: grid;
  place-items: center;
  padding: 1rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.review-detail-modal.is-open {
  pointer-events: auto;
  opacity: 1;
  perspective: 1200px;
  perspective-origin: 50% 35%;
}

.review-detail-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(8px);
}

.review-detail-modal__dialog {
  position: relative;
  width: 100%;
  max-width: min(420px, 94vw);
  max-height: min(88vh, 720px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--bg) 0%, #f8fdfb 100%);
  border-radius: calc(var(--radius-lg) + 4px);
  border: 1px solid rgba(15, 118, 110, 0.18);
  box-shadow: 0 28px 90px rgba(15, 23, 42, 0.35);
  transform: translateY(40px) scale(0.88) rotateX(4deg);
  opacity: 0;
  transition:
    transform 0.55s cubic-bezier(0.34, 1.3, 0.64, 1),
    opacity 0.4s ease;
}

.review-detail-modal.is-open .review-detail-modal__dialog {
  transform: translateY(0) scale(1) rotateX(0);
  opacity: 1;
}

.review-detail-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 2.65rem;
  height: 2.65rem;
  border: none;
  border-radius: 50%;
  background: var(--bg-muted);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  z-index: 2;
  transition:
    background 0.2s,
    transform 0.35s cubic-bezier(0.34, 1.3, 0.64, 1);
}

.review-detail-modal__close:hover {
  background: var(--border);
  transform: rotate(90deg) scale(1.05);
}

.review-detail-modal__body {
  overflow-y: auto;
  padding: 2.5rem 1.75rem 2rem;
  text-align: center;
}

.review-detail-modal__body .review-card__avatar-wrap {
  width: 92px;
  height: 92px;
  margin: 0 auto 1rem;
}

.review-detail-modal__body .review-card__avatar-fallback {
  font-size: 2.35rem;
}

.review-detail-modal__body .review-card__name {
  font-size: 1.2rem;
  margin-bottom: 0.15rem;
}

.review-detail-modal__body .review-card__loc {
  justify-content: center;
  font-size: 0.8rem;
}

.review-detail-modal__body .star-rating {
  margin: 0.35rem auto 0.75rem;
}

.review-detail-modal__body .star-rating__star {
  font-size: 1.35rem;
}

.review-detail-modal__body .star-rating__star--empty {
  font-size: 1.28rem;
}

.review-detail-modal__body .review-card__text {
  font-size: 0.975rem;
  line-height: 1.65;
  color: var(--text-muted);
  text-align: center;
  margin: 0 0 1.25rem;
  display: block;
  -webkit-line-clamp: unset;
  overflow: visible;
}

.review-detail-modal__body .review-card__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid rgba(15, 118, 110, 0.2);
  font-size: 0.82rem;
}

.review-detail-modal__body .review-card__link:hover {
  background: rgba(15, 118, 110, 0.14);
  text-decoration: none;
}

@media (prefers-reduced-motion: reduce) {
  .review-detail-modal__dialog,
  .review-detail-modal.is-open .review-detail-modal__dialog {
    transition: none;
    transform: none;
  }

  .review-detail-modal__close:hover {
    transform: none;
  }
}

/* ----- Project detail (full-screen from portfolio card) ----- */
body.project-detail-open {
  overflow: hidden;
}

.project-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 2200;
  display: grid;
  place-items: stretch;
  padding: 0;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.35s ease,
    visibility 0.35s ease;
}

.project-detail-modal.is-open {
  pointer-events: auto;
  opacity: 1;
  visibility: visible;
}

.project-detail-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
  backdrop-filter: blur(6px);
}

.project-detail-modal__close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.project-detail-modal__dialog {
  position: relative;
  width: 100%;
  height: 100%;
  max-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  overflow: hidden;
  border: none;
  box-shadow: 0 -8px 60px rgba(15, 23, 42, 0.12);
  transform: translateY(100%);
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.project-detail-modal.is-open .project-detail-modal__dialog {
  transform: translateY(0);
}

.project-detail-modal__close {
  position: absolute;
  top: max(1rem, env(safe-area-inset-top, 0px));
  right: max(1rem, env(safe-area-inset-right, 0px));
  width: 2.75rem;
  height: 2.75rem;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  color: var(--text);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  z-index: 15;
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.15);
  transition:
    background 0.2s ease,
    transform 0.25s ease;
}

.project-detail-modal__close:hover {
  background: #fff;
  transform: scale(1.05);
}

.project-detail__split {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(240px, 42%) minmax(0, 1fr);
  align-items: stretch;
}

@media (max-width: 900px) {
  .project-detail__split {
    grid-template-columns: 1fr;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
}

.project-detail__media {
  background: #0f172a;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  min-height: 0;
}

@media (max-width: 900px) {
  .project-detail__media {
    border-right: none;
    border-bottom: 1px solid var(--border);
    min-height: 220px;
    max-height: 45vh;
  }
}

.project-detail__main-photo {
  flex: 1;
  min-height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem;
}

.project-detail__main-photo img {
  max-width: 100%;
  max-height: min(70vh, 760px);
  width: auto;
  height: auto;
  object-fit: contain;
}

.project-detail__thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.65rem 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 23, 42, 0.92);
  align-content: flex-start;
  max-height: 7.5rem;
  overflow-y: auto;
}

.project-detail__thumbs:empty {
  display: none;
}

.project-detail__thumb {
  flex: 0 0 auto;
  width: 4.25rem;
  height: 3rem;
  padding: 0;
  border: 2px solid transparent;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  background: #1e293b;
  opacity: 0.85;
  transition:
    opacity 0.15s ease,
    border-color 0.15s ease,
    transform 0.15s ease;
}

.project-detail__thumb:hover,
.project-detail__thumb:focus-visible {
  opacity: 1;
  outline: none;
}

.project-detail__thumb:focus-visible {
  box-shadow: 0 0 0 2px var(--accent);
}

.project-detail__thumb.is-active {
  border-color: #5eead4;
  opacity: 1;
}

.project-detail__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-detail__pane {
  overflow-y: auto;
  overflow-x: hidden;
  padding: 1.25rem 1.15rem 2rem 1.35rem;
  -webkit-overflow-scrolling: touch;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  min-height: 0;
}

@media (min-width: 901px) {
  .project-detail__pane {
    padding: 1.5rem 1.75rem 2.25rem 2rem;
  }
}

.project-detail__pane-body {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 1rem 1.15rem;
  flex: 1;
  min-width: 0;
  min-height: 0;
}

.project-detail__main {
  flex: 1;
  min-width: 0;
}

.project-detail__sticky-rail {
  flex: 0 0 auto;
  width: 8.75rem;
  min-width: 8.75rem;
  position: sticky;
  top: 0.65rem;
  align-self: flex-start;
  padding: 0.65rem 0.6rem;
  background: rgba(243, 248, 246, 0.84);
  border: 1px solid rgba(226, 232, 240, 0.6);
  backdrop-filter: blur(26px);
  -webkit-backdrop-filter: blur(26px);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  z-index: 2;
}

.project-detail__sticky-rail[hidden] {
  display: none !important;
}

.project-detail__sticky-heading {
  font-size: 0.58rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin: 0 0 0.5rem;
  text-align: center;
  line-height: 1.2;
}

.project-detail__sticky-actions {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.project-detail__sticky-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.22rem;
  padding: 0.55rem 0.45rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.2;
  color: #fff;
  background: var(--accent);
  border-radius: var(--radius);
  text-decoration: none;
  transition:
    background 0.2s ease,
    transform 0.2s ease;
  word-break: break-word;
  hyphens: auto;
}

.project-detail__sticky-btn:hover {
  background: var(--accent-hover);
  color: #fff;
  text-decoration: none;
  transform: translateY(-1px);
}

.project-detail__sticky-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.project-detail__sticky-btn--github {
  background: #0f172a;
  color: #f1f5f9;
}

.project-detail__sticky-btn--github:hover {
  background: #1e293b;
  color: #fff;
}

.project-detail__sticky-btn .bx {
  font-size: 1.2rem;
  line-height: 1;
}

@media (max-width: 900px) {
  .project-detail__pane-body {
    flex-direction: column-reverse;
  }

  .project-detail__sticky-rail {
    position: static;
    width: 100%;
    top: auto;
    z-index: 1;
  }

  .project-detail__sticky-actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .project-detail__sticky-btn {
    flex-direction: row;
    padding: 0.4rem 0.65rem;
    font-size: 0.75rem;
    gap: 0.45rem;
  }

  .project-detail__sticky-heading {
    text-align: left;
    margin-bottom: 0.4rem;
  }
}

.project-detail__kicker {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin: 0 0 0.45rem;
}

.project-detail__title {
  font-size: clamp(1.2rem, 2.4vw, 1.55rem);
  font-weight: 800;
  color: var(--text);
  margin: 0 0 1.15rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.project-detail__overview {
  max-width: 42rem;
  margin: 0 0 1.75rem;
}

.project-detail__overview p {
  margin: 0 0 1rem;
  font-size: 0.9375rem;
  line-height: 1.72;
  color: var(--text-muted);
}

.project-detail__overview p:last-child {
  margin-bottom: 0;
}

.project-detail__timeline-section {
  max-width: 42rem;
  margin: 0 0 1.75rem;
}

.project-detail__section-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 1.25rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--border);
}

.project-detail__timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}

.project-detail__timeline-item {
  position: relative;
  padding-left: 1.65rem;
  padding-bottom: 1.35rem;
  margin: 0;
}

.project-detail__timeline-item:last-child {
  padding-bottom: 0;
}

.project-detail__timeline-item::before {
  content: "";
  position: absolute;
  left: 0.35rem;
  top: 0.5rem;
  bottom: -0.25rem;
  width: 2px;
  background: linear-gradient(
    180deg,
    rgba(15, 118, 110, 0.45),
    var(--border)
  );
}

.project-detail__timeline-item:last-child::before {
  bottom: 0.75rem;
}

.project-detail__timeline-dot {
  position: absolute;
  left: 0;
  top: 0.55rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  box-shadow: 0 0 0 2px var(--accent-soft);
  z-index: 1;
}

.project-detail__timeline-card {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1rem 1.1rem;
  box-shadow: var(--shadow);
}

.project-detail__timeline-phase {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  margin-bottom: 0.35rem;
}

.project-detail__timeline-label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  margin-bottom: 0.35rem;
}

.project-detail__timeline-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin: 0;
}

.project-detail__actions {
  max-width: 42rem;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: flex-start;
}

.project-detail__action {
  text-decoration: none;
}

@media (prefers-reduced-motion: reduce) {
  .project-detail-modal__dialog,
  .project-detail-modal.is-open .project-detail-modal__dialog {
    transition: none;
    transform: none;
  }

  .project-detail-modal__close:hover {
    transform: none;
  }

  .project-detail__sticky-btn:hover {
    transform: none;
  }
}

.flag {
  border-radius: 2px;
}

.swiper-pagination {
  position: relative;
  margin-top: 1.25rem;
}

.swiper-pagination-bullet {
  background: var(--text-muted);
  opacity: 0.35;
}

.swiper-pagination-bullet-active {
  background: var(--accent);
  opacity: 1;
}

/* ----- Services ----- */
.services {
  background: transparent;
}

.services__container {
  gap: 1.25rem;
}

@media (min-width: 576px) {
  .services__container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .services__container {
    grid-template-columns: repeat(3, 1fr);
  }
}

.services__data {
  padding: 1.5rem 1.25rem;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(15, 118, 110, 0.1);
  border-radius: var(--radius-lg);
  text-align: left;
  transition:
    border-color 0.28s ease,
    box-shadow 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.services__data:hover {
  border-color: rgba(15, 118, 110, 0.28);
  box-shadow: 0 14px 36px -14px rgba(15, 23, 42, 0.12);
  transform: translateY(-4px);
}

.services__icon {
  font-size: 1.75rem;
  color: var(--accent);
  margin-bottom: 0.75rem;
  display: inline-block;
  transition: transform 0.4s cubic-bezier(0.34, 1.3, 0.64, 1);
}

.services__data:hover .services__icon {
  transform: scale(1.08) translateY(-3px);
}

.services__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.services__description {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 1rem;
}

.services__data .button {
  width: fit-content;
}

/* ----- CTA strip ----- */
.project {
  padding: 2.5rem 0;
}

.project__container {
  background: linear-gradient(135deg, #134e4a 0%, #0f766e 50%, #115e59 100%);
  border-radius: var(--radius-lg);
  padding: 2rem 1.5rem;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
  transition:
    transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.45s ease;
}

.project__container::after {
  content: "";
  position: absolute;
  inset: -40%;
  background: radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.12), transparent 45%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.project__container:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 50px -12px rgba(15, 23, 42, 0.28);
}

.project__container:hover::after {
  opacity: 1;
}

.project__data {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25rem;
  text-align: left;
  position: relative;
  z-index: 1;
}

@media (min-width: 768px) {
  .project__data {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
  }

  .project__data > div {
    flex: 1;
  }
}

.project__icon {
  font-size: 2.5rem;
  color: rgba(255, 255, 255, 0.9);
}

.project__title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.35rem;
}

.project__description {
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.85);
  margin: 0;
  line-height: 1.5;
}

.project__data .button--primary {
  background: #fff;
  color: var(--accent);
  flex-shrink: 0;
}

.project__data .button--primary:hover {
  background: var(--bg-subtle);
}

/* ----- Contact ----- */
.contact {
  background: transparent;
}

.contact__layout {
  display: grid;
  gap: 2rem;
  align-items: start;
  max-width: 960px;
  margin: 0 auto;
}

.contact__aside,
.contact__form-card {
  min-width: 0;
}

@media (min-width: 900px) {
  .contact__layout {
    grid-template-columns: 1fr 1.05fr;
    gap: 2.5rem;
    align-items: stretch;
  }
}

.contact__intro {
  font-size: 0.9375rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0 0 1.25rem;
}

.contact__channels {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.contact-channel {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.85rem 1rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: inherit;
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    transform 0.2s;
}

.contact-channel:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
  transform: translateY(-1px);
  text-decoration: none;
}

.contact-channel__icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius);
  background: var(--accent-soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.contact-channel__body {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.contact-channel__label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}

.contact-channel__value {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  word-break: break-word;
}

.contact__microcopy {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin: 1.25rem 0 0;
}

.contact__form-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.25rem 1.5rem;
  box-shadow: var(--shadow-md);
}

@media (min-width: 900px) {
  .contact__form-card {
    padding: 1.5rem 1.5rem 1.65rem;
  }
}

.contact__form {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.contact__field {
  margin-bottom: 1rem;
}

.contact__label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.contact__input,
.contact__textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  font-family: inherit;
  font-size: 0.9375rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-subtle);
  color: var(--text);
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}

.contact__textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.5;
}

.contact__input:focus,
.contact__textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  background: var(--bg);
}

.contact__input::placeholder,
.contact__textarea::placeholder {
  color: #94a3b8;
}

.contact__submit {
  width: 100%;
  margin-top: 0.25rem;
  padding: 0.8rem 1.25rem;
}

/* ----- Footer ----- */
.footer {
  background: linear-gradient(170deg, #0f766e 0%, #0d5d56 42%, #0a4f4a 100%);
  color: rgba(248, 250, 252, 0.92);
  padding: 0;
  position: relative;
  z-index: 70;
  overflow: hidden;
}

.footer::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 60% at 20% 0%, rgba(255, 255, 255, 0.12), transparent 55%);
  pointer-events: none;
}

.footer__container {
  position: relative;
  padding: 2.75rem 0 2rem;
  text-align: center;
}

.footer__title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.footer__social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.footer__link {
  display: grid;
  place-items: center;
  width: 2.85rem;
  height: 2.85rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #f8fafc;
  font-size: 1.25rem;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.18);
  transition:
    background 0.2s,
    transform 0.2s,
    border-color 0.2s;
}

.footer__link:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.35);
  transform: translateY(-3px);
  color: #fff;
  text-decoration: none;
}

.footer__link img {
  width: 1.1rem;
  filter: brightness(0) invert(1);
  opacity: 0.9;
}

.footer__copy {
  font-size: 0.75rem;
  color: rgba(226, 232, 240, 0.75);
  margin: 0;
}

.portfolio .swiper-pagination-bullet-active {
  background: var(--accent);
}

/* Scroll reveal + light motion */
.js-reveal {
  opacity: 0;
  transform: translateY(28px) scale(0.985);
  filter: blur(4px);
  transition:
    opacity 0.65s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.65s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.6s ease;
}

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

/* Staggered reveal for section inner columns (premium) */
.section__inner.js-reveal {
  opacity: 1;
  transform: none;
  filter: none;
}

.section__inner.js-reveal > * {
  opacity: 0;
  transform: translateY(32px) scale(0.98);
  filter: blur(5px);
  transition:
    opacity 0.62s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.62s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.52s ease;
}

.section__inner.js-reveal--visible > * {
  opacity: 1;
  transform: none;
  filter: none;
}

.section__inner.js-reveal--visible > *:nth-child(1) {
  transition-delay: 0.04s;
}

.section__inner.js-reveal--visible > *:nth-child(2) {
  transition-delay: 0.1s;
}

.section__inner.js-reveal--visible > *:nth-child(3) {
  transition-delay: 0.16s;
}

.section__inner.js-reveal--visible > *:nth-child(4) {
  transition-delay: 0.22s;
}

.section__inner.js-reveal--visible > *:nth-child(5) {
  transition-delay: 0.28s;
}

.section__inner.js-reveal--visible > *:nth-child(6) {
  transition-delay: 0.34s;
}

.section__inner.js-reveal--visible > *:nth-child(n + 7) {
  transition-delay: 0.4s;
}

.section__inner.js-reveal--visible .section-subtitle {
  animation: subtitle-line 0.65s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

@keyframes subtitle-line {
  from {
    opacity: 0;
    letter-spacing: 0.2em;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    letter-spacing: 0.14em;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .js-reveal {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }

  .section__inner.js-reveal > * {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }

  .section__inner.js-reveal--visible .section-subtitle {
    animation: none;
  }

  .portfolio__content:hover .portfolio__img {
    transform: none;
    opacity: 1;
  }

  .portfolio__content:hover,
  .services__data:hover {
    transform: none;
  }

  .portfolio__item:hover {
    transform: none;
    box-shadow: none;
  }

  .project__container:hover {
    transform: none;
  }

  .project__container::after {
    display: none;
  }

  .services__data:hover .services__icon {
    transform: none;
  }
}

/* Small screens */
@media (max-width: 360px) {
  .about__highlights {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 576px) {
  .services__container,
  .portfolio__container:not(.projects-bento) {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .section {
    padding: 4.5rem 0;
  }
}

@media (min-width: 992px) {
  .services__container,
  .portfolio__container:not(.projects-bento) {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .bd-container {
    width: min(100% - 3rem, var(--max));
  }
}

/* ----- Section visibility toggles (site.json sections.*) ----- */
.section--hidden,
.section--hidden[hidden] {
  display: none !important;
}

/* ----- Hero secondary tagline ----- */
.home__tagline--secondary {
  margin-top: 0.75rem;
  font-size: 0.95rem;
  opacity: 0.92;
}

/* ----- Timeline body copy ----- */
.timeline__body {
  margin: 0.65rem 0 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ----- Skills (matches engagements card style) ----- */
.skills__container {
  gap: 1.25rem;
}

@media (min-width: 576px) {
  .skills__container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 992px) {
  .skills__container {
    grid-template-columns: repeat(3, 1fr);
  }
}

.skills__data {
  padding: 1.5rem 1.25rem;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(15, 118, 110, 0.1);
  border-radius: var(--radius-lg);
  text-align: left;
  transition:
    border-color 0.28s ease,
    box-shadow 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.skills__data:hover {
  border-color: rgba(15, 118, 110, 0.28);
  box-shadow: 0 14px 36px -14px rgba(15, 23, 42, 0.12);
  transform: translateY(-4px);
}

.skills__icon {
  font-size: 1.75rem;
  line-height: 1;
  margin-bottom: 0.75rem;
  display: inline-block;
  transition: transform 0.4s cubic-bezier(0.34, 1.3, 0.64, 1);
}

.skills__data:hover .skills__icon {
  transform: scale(1.12) translateY(-3px);
}

.skills__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.skills__description {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 1rem;
}

.skills__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.skills__tag {
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid rgba(15, 118, 110, 0.15);
}

/* ----- Projects bento grid ----- */
.projects-bento {
  display: grid;
  grid-template-columns: 1fr;
  grid-auto-flow: dense;
  gap: 2rem;
  width: 100%;
  min-width: 0;
}

@media (min-width: 992px) {
  .projects-bento {
    grid-template-columns: repeat(12, 1fr);
    gap: 2.35rem;
    align-items: stretch;
  }

  .project-card--feature {
    grid-column: span 8;
  }

  .project-card--tall {
    grid-column: span 4;
  }

  .project-card--wide {
    grid-column: span 7;
  }

  .project-card--standard {
    grid-column: span 5;
  }

  .project-card--half {
    grid-column: span 6;
  }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .projects-bento {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.85rem;
  }

  .project-card--feature,
  .project-card--wide {
    grid-column: 1 / -1;
  }

  .project-card--tall,
  .project-card--standard,
  .project-card--half {
    grid-column: auto;
  }
}

@media (max-width: 767px) {
  .project-card--feature,
  .project-card--tall,
  .project-card--wide,
  .project-card--standard,
  .project-card--half {
    grid-column: 1 / -1;
  }
}

.project-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1.5px solid var(--card-accent, var(--accent));
  border-radius: 1.35rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 100%;
  min-width: 0;
  position: relative;
  box-shadow: 0 2px 10px -2px color-mix(in srgb, var(--card-accent, var(--accent)) 14%, transparent);
  transition:
    box-shadow 0.3s ease,
    border-color 0.3s ease,
    transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.project-card__accent-bar {
  height: 5px;
  width: 100%;
  background: linear-gradient(
    90deg,
    var(--card-accent, var(--accent)),
    color-mix(in srgb, var(--card-accent, var(--accent)) 55%, #fff)
  );
  flex-shrink: 0;
}

.project-card--filtered-out {
  opacity: 0;
  transform: scale(0.98);
  pointer-events: none;
}

.project-card[hidden] {
  display: none !important;
}

.project-card:hover {
  box-shadow: 0 4px 14px -3px color-mix(in srgb, var(--card-accent, var(--accent)) 20%, transparent);
  transform: translateY(-2px);
}

.project-card__preview {
  position: relative;
  flex: 1 1 auto;
  min-height: 165px;
  background: linear-gradient(145deg, #f0fdfa 0%, #ecfdf5 45%, #f8fafc 100%);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.project-card__iframe-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 180px;
  overflow: hidden;
  background: #fff;
}

.project-card__iframe-wrap--idle {
  background:
    linear-gradient(
      110deg,
      rgba(15, 118, 110, 0.06) 0%,
      rgba(15, 118, 110, 0.02) 45%,
      rgba(15, 118, 110, 0.06) 90%
    ),
    #f8fafc;
  background-size: 200% 100%;
  animation: project-preview-shimmer 1.4s ease-in-out infinite;
}

.project-card__iframe-wrap:has(.project-card__iframe--idle) {
  background:
    linear-gradient(
      110deg,
      rgba(15, 118, 110, 0.06) 0%,
      rgba(15, 118, 110, 0.02) 45%,
      rgba(15, 118, 110, 0.06) 90%
    ),
    #f8fafc;
  background-size: 200% 100%;
  animation: project-preview-shimmer 1.4s ease-in-out infinite;
}

.project-card__iframe-loading {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  background: rgba(248, 250, 252, 0.94);
  pointer-events: none;
}

.project-card__iframe-loading[hidden] {
  display: none !important;
}

.project-card__iframe-spinner {
  width: 1.75rem;
  height: 1.75rem;
  border: 2.5px solid rgba(15, 118, 110, 0.18);
  border-top-color: var(--accent, #0f766e);
  border-radius: 50%;
  animation: project-iframe-spin 0.75s linear infinite;
}

.project-card__iframe-loading-text {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--accent, #0f766e);
  letter-spacing: 0.02em;
}

@keyframes project-iframe-spin {
  to {
    transform: rotate(360deg);
  }
}

.project-card__iframe-wrap--loading .project-card__iframe {
  opacity: 0;
  pointer-events: none;
}

.project-card__iframe--idle {
  opacity: 0;
  pointer-events: none;
}

@keyframes project-preview-shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .project-card__iframe-wrap--idle,
  .project-card__iframe-wrap:has(.project-card__iframe--idle) {
    animation: none;
    background: #f8fafc;
  }

  .project-card__iframe-spinner {
    animation: none;
    border-top-color: rgba(15, 118, 110, 0.18);
  }
}

.project-card__iframe-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(15, 118, 110, 0.06);
  border-radius: inherit;
}

.project-card__iframe {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 180px;
  border: none;
  background: #fff;
  transform: scale(1);
  transform-origin: top center;
}

@media (min-width: 768px) {
  .project-card__iframe-wrap,
  .project-card__iframe {
    min-height: 210px;
  }

  .project-card--wide .project-card__iframe-wrap,
  .project-card--wide .project-card__iframe {
    min-height: 225px;
  }
}

@media (min-width: 992px) {
  .project-card--feature .project-card__iframe-wrap,
  .project-card--feature .project-card__iframe,
  .project-card--feature .project-card__preview--image {
    min-height: 260px;
  }

  .project-card--tall .project-card__iframe-wrap,
  .project-card--tall .project-card__iframe {
    min-height: 235px;
  }
}

@media (min-width: 768px) and (max-width: 991.98px) {
  .project-card__preview--image,
  .project-card__preview-link,
  .project-card__preview-img {
    min-height: 240px;
  }
}

.project-card__preview--image {
  min-height: 165px;
}

.project-card__preview--placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  min-height: 165px;
  padding: 1.15rem;
  text-align: center;
  background: linear-gradient(145deg, #f0fdfa 0%, #ecfdf5 45%, #f8fafc 100%);
}

.project-card__preview--placeholder p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 28rem;
}

.project-card__preview--placeholder .project-card__cta {
  width: auto;
  min-width: min(100%, 220px);
}

.project-card__preview-link {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 165px;
  line-height: 0;
  text-decoration: none;
}

.project-card__preview-img {
  width: 100%;
  height: 100%;
  min-height: 165px;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.45s ease, opacity 0.3s ease;
}

.project-card:hover .project-card__preview-img {
  transform: scale(1.03);
}

.project-card__preview-badge {
  position: absolute;
  bottom: 0.75rem;
  right: 0.75rem;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--accent);
  border: 1px solid rgba(15, 118, 110, 0.2);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
}

.project-card__preview-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.5rem;
  text-align: center;
  background: var(--bg-subtle);
}

.project-card__preview-fallback[hidden] {
  display: none;
}

.project-card__body {
  padding: 0.9rem 1rem 1.05rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-shrink: 0;
}

.project-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.project-card__tag {
  font-size: 0.625rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  color: var(--card-accent, var(--accent));
  background: color-mix(in srgb, var(--card-accent, var(--accent)) 12%, #fff);
  border: 1px solid color-mix(in srgb, var(--card-accent, var(--accent)) 28%, transparent);
}

.project-card__cta {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  margin-top: auto;
  padding: 0.65rem 1rem !important;
  font-size: 0.8125rem !important;
  font-weight: 700 !important;
  text-decoration: none !important;
  border-radius: var(--radius) !important;
  box-shadow: 0 3px 10px -3px color-mix(in srgb, var(--card-accent, var(--accent)) 30%, transparent);
  background: linear-gradient(
    135deg,
    var(--card-accent, var(--accent)),
    color-mix(in srgb, var(--card-accent, var(--accent)) 78%, #000)
  ) !important;
  border: none !important;
  color: #fff !important;
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    filter 0.25s ease;
}

.project-card__cta:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px -3px color-mix(in srgb, var(--card-accent, var(--accent)) 32%, transparent);
  color: #fff !important;
  text-decoration: none !important;
}

.project-card__cta .bx {
  font-size: 1.15rem;
  line-height: 1;
}

.project-card__title {
  font-size: 0.9875rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
  line-height: 1.35;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.project-card__highlights {
  margin: 0;
  padding-left: 1.1rem;
  font-size: 0.8125rem;
  color: var(--text-muted);
  line-height: 1.55;
}

.project-card__highlights li + li {
  margin-top: 0.35rem;
}

@media (prefers-reduced-motion: reduce) {
  .project-card:hover,
  .skills__data:hover {
    transform: none;
  }

  .project-card:hover .project-card__preview-img {
    transform: none;
  }

  .project-card__cta:hover {
    transform: none;
  }
}

/* ----- Resume preview ----- */
.resume__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.resume__preview {
  border: 1px solid rgba(15, 118, 110, 0.12);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: #fff;
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.06);
}

.resume__iframe {
  display: block;
  width: 100%;
  height: min(80vh, 900px);
  min-height: 420px;
  border: none;
}

@media (max-width: 767px) {
  .resume__iframe {
    min-height: 360px;
    height: 70vh;
  }

  .project-card__iframe-wrap,
  .project-card__iframe {
    min-height: 200px;
  }

  .nav__menu .nav__list {
    max-height: calc(100dvh - 4.5rem);
    overflow-y: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .skills__data:hover .skills__icon {
    transform: none;
  }
}

/* ===== Responsive polish (all screen sizes) ===== */
html {
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  overflow-x: clip;
  min-width: 280px;
}

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

.contact__input,
.contact__textarea {
  width: 100%;
  max-width: 100%;
}

/* Notched phones & home indicator */
@supports (padding: max(0px)) {
  .site-header .nav.bd-container {
    padding-left: max(0px, env(safe-area-inset-left));
    padding-right: max(0px, env(safe-area-inset-right));
  }

  .scrolltop {
    right: max(1rem, env(safe-area-inset-right));
    bottom: max(1.25rem, env(safe-area-inset-bottom));
  }

  .nav__menu {
    padding-bottom: max(0.75rem, env(safe-area-inset-bottom));
  }

  .projects-modal {
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
  }
}

/* Extra-small phones (320–479px) */
@media (max-width: 479px) {
  :root {
    --header-height: 3rem;
  }

  .bd-container {
    width: min(100% - 1.25rem, var(--max));
  }

  .section {
    padding: 2.5rem 0;
  }

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

  .section-title {
    font-size: clamp(1.35rem, 6.5vw, 1.75rem);
  }

  .section-lead {
    font-size: 0.9375rem;
  }

  .home.section-band--hero {
    padding: 1.35rem 0 1.75rem;
  }

  .home__name {
    font-size: clamp(1.65rem, 9vw, 2.1rem);
  }

  .home__greeting {
    font-size: 0.6875rem;
    letter-spacing: 0.08em;
  }

  .home__tagline,
  .home__tagline--secondary {
    font-size: 0.9375rem;
    line-height: 1.6;
  }

  .home__actions {
    flex-direction: column;
  }

  .home__actions .button {
    width: 100%;
  }

  .home__focus-chip {
    font-size: 0.6875rem;
    padding: 0.32rem 0.6rem;
  }

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

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

  .about__panel {
    padding: 0.9rem;
  }

  .nav__logo {
    max-width: min(46vw, 170px);
  }

  .nav__logo-text {
    font-size: 0.8125rem;
  }

  .nav__toggle {
    width: 2.45rem;
    height: 2.45rem;
  }

  .timeline__card {
    padding: 1rem;
  }

  .timeline__heading {
    font-size: 0.9375rem;
  }

  .skills__data,
  .services__data {
    padding: 1.15rem 1rem;
  }

  .skills__title,
  .services__title {
    font-size: 0.975rem;
  }

  .project-card__body {
    padding: 1rem 0.95rem 1.1rem;
  }

  .project-card__title {
    font-size: 0.975rem;
  }

  .project-card__highlights {
    font-size: 0.8125rem;
    padding-left: 1rem;
  }

  .project-card__cta {
    padding: 0.65rem 0.85rem !important;
    font-size: 0.8125rem !important;
    gap: 0.35rem;
  }

  .portfolio__item {
    font-size: 0.6875rem;
    padding: 0.32rem 0.6rem;
  }

  .resume__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .resume__actions .button {
    width: 100%;
  }

  .resume__iframe {
    min-height: 300px;
    height: 65vh;
  }

  .project__data {
    align-items: stretch;
    text-align: center;
  }

  .project__data .button--primary {
    width: 100%;
  }

  .footer__container {
    padding-inline: 1rem;
  }
}

/* Phones: hero connect chip stacks under photo */
@media (max-width: 767px) {
  .hero__connect-chip-hint {
    display: none;
  }
}

/* Phones & small tablets (480–767px) */
@media (max-width: 767px) {
  .projects-bento {
    grid-template-columns: 1fr !important;
    gap: 1.75rem;
  }

  .portfolio__nav-wrap {
    margin-bottom: 1.35rem;
  }

  .hero__grid {
    gap: 1.35rem;
  }

  .home__img {
    max-width: min(100%, 260px);
  }

  .contact__layout {
    gap: 1.35rem;
  }

  .contact-channel__value {
    word-break: break-word;
    overflow-wrap: anywhere;
  }

  .contact__form-card {
    padding: 1.15rem;
  }

  .project-card__iframe-wrap,
  .project-card__iframe,
  .project-card__preview-link,
  .project-card__preview-img {
    min-height: 200px;
  }

  .project-card__preview-badge {
    font-size: 0.625rem;
    bottom: 0.5rem;
    right: 0.5rem;
  }

  .reviews-marquee-wrap {
    margin-inline: calc(-1 * (100vw - 100%) / 2);
  }

  .nav__menu .nav__list {
    max-height: calc(100dvh - var(--header-height) - env(safe-area-inset-bottom, 0px));
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav__link {
    padding: 0.65rem 0.85rem;
    font-size: 0.9375rem;
  }
}

/* Tablet landscape & small laptop nav (768–991px) */
@media (min-width: 768px) and (max-width: 991.98px) {
  .hero__grid {
    grid-template-columns: 1fr minmax(180px, 34%);
    gap: 1.75rem 2rem;
  }

  .about__container {
    grid-template-columns: minmax(160px, 260px) 1fr;
    gap: 1.75rem;
  }

  .timeline {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

/* Desktop nav — many links (992–1199px) */
@media (min-width: 992px) and (max-width: 1199px) {
  .nav__list {
    flex-wrap: wrap;
    justify-content: flex-end;
    max-width: min(72vw, 680px);
    gap: 0.08rem;
  }

  .nav__link {
    padding: 0.32rem 0.42rem;
    font-size: 0.6875rem;
  }
}

/* Large desktop */
@media (min-width: 1200px) {
  .nav__link {
    padding: 0.42rem 0.58rem;
    font-size: 0.8125rem;
  }

  .bd-container {
    width: min(100% - 3rem, var(--max));
  }
}

/* Ultra-wide screens */
@media (min-width: 1400px) {
  :root {
    --max: 1140px;
  }

  .projects-bento {
    gap: 2.5rem;
  }
}

/* Landscape phones — reduce vertical iframe height */
@media (max-height: 500px) and (orientation: landscape) {
  .resume__iframe {
    min-height: 240px;
    height: 75vh;
  }

  .project-card__iframe-wrap,
  .project-card__iframe {
    min-height: 160px;
  }

  .projects-modal__title {
    font-size: 1rem;
    padding-top: max(0.65rem, env(safe-area-inset-top, 0px) + 0.25rem);
  }

  .projects-modal__subtitle {
    padding-bottom: 0.5rem;
    font-size: 0.75rem;
  }

  .projects-modal__grid .project-card__iframe-wrap,
  .projects-modal__grid .project-card__iframe,
  .projects-modal__grid .project-card__preview-link,
  .projects-modal__grid .project-card__preview-img {
    min-height: 120px;
  }

  .projects-modal__grid .project-card__body {
    padding: 0.5rem 0.65rem 0.6rem;
  }

  .projects-modal__grid .project-card__highlights {
    display: none;
  }

  .nav__menu {
    max-height: calc(100dvh - var(--header-height));
    overflow-y: auto;
  }
}

/* Touch devices — larger tap targets */
@media (hover: none) and (pointer: coarse) {
  .nav__link,
  .portfolio__item,
  .button,
  .project-card__cta {
    min-height: 44px;
  }

  .portfolio__item {
    display: inline-flex;
    align-items: center;
  }

  .projects-modal__close {
    min-width: 44px;
    min-height: 44px;
  }

  .projects-modal__filters .portfolio__item {
    min-height: 2.35rem;
  }

  .home__social-icon {
    width: 2.75rem;
    height: 2.75rem;
  }

  .project-card:hover {
    transform: none;
  }

  .skills__data:hover,
  .services__data:hover {
    transform: none;
  }
}
