:root {
  --bg: #0a0d12;
  --bg-soft: #10151d;
  --surface: rgba(16, 21, 29, 0.72);
  --surface-strong: rgba(20, 26, 35, 0.9);
  --text: #f4efe7;
  --muted: #b1b7c2;
  --line: rgba(255, 255, 255, 0.09);
  --shadow: 0 28px 90px rgba(0, 0, 0, 0.38);
  --accent: #d6a26e;
  --accent-deep: #7a1f2b;
  --accent-soft: #18212c;
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --container: 1160px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Manrope", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(122, 31, 43, 0.28), transparent 28%),
    radial-gradient(circle at 80% 12%, rgba(214, 162, 110, 0.18), transparent 24%),
    linear-gradient(180deg, #090c11 0%, #0d1219 45%, #0a0d12 100%);
}

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

ul {
  margin: 0;
  padding-left: 1rem;
}

.page-glow {
  position: fixed;
  width: 26rem;
  height: 26rem;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}

.page-glow-left {
  top: -8rem;
  left: -8rem;
  background: rgba(122, 31, 43, 0.34);
}

.page-glow-right {
  right: -10rem;
  top: 18rem;
  background: rgba(214, 162, 110, 0.2);
}

.site-header,
main {
  position: relative;
  z-index: 1;
}

.site-header {
  width: min(calc(100% - 32px), var(--container));
  margin: 20px auto 0;
  padding: 16px 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(20px);
  background: rgba(9, 12, 17, 0.66);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), #7e4d2c);
  color: #fff;
}

.site-nav {
  display: flex;
  gap: 24px;
  color: var(--muted);
}

.site-nav a:hover,
.contact-links a:hover {
  color: var(--accent);
}

main {
  width: min(calc(100% - 32px), var(--container));
  margin: 0 auto;
  padding: 32px 0 80px;
}

.section {
  margin-top: 28px;
}

.hero {
  display: grid;
  grid-template-columns: 1.45fr 0.85fr;
  gap: 24px;
  min-height: calc(100vh - 140px);
  align-items: end;
}

.hero-copy,
.hero-panel,
.project-card,
.service-card,
.contact-card,
.stack-card,
.gallery-card {
  border: 1px solid var(--line);
  background: var(--surface);
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}

.hero-copy {
  padding: clamp(28px, 4vw, 56px);
  border-radius: var(--radius-xl);
  background:
    linear-gradient(180deg, rgba(16, 21, 29, 0.72), rgba(16, 21, 29, 0.9)),
    radial-gradient(circle at top left, rgba(214, 162, 110, 0.12), transparent 40%);
}

.hero h1,
.section-heading h2,
.contact-card h2 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.hero h1 {
  max-width: 11ch;
  font-size: clamp(3rem, 9vw, 7rem);
}

.hero-text,
.project-card p,
.service-card p,
.about-copy p,
.contact-card p {
  color: var(--muted);
  line-height: 1.7;
}

.hero-text {
  max-width: 38rem;
  margin: 28px 0 0;
  font-size: 1.05rem;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.hero-tags span {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: #d8dde6;
  font-size: 0.92rem;
}

.eyebrow {
  margin: 0 0 18px;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  font-weight: 800;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 54px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 700;
}

.button-primary {
  background: linear-gradient(135deg, var(--accent), #8d5534);
  color: #111;
}

.button-secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.hero-panel {
  padding: 24px;
  border-radius: var(--radius-xl);
  min-height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 20px;
}

.status-card {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(214, 162, 110, 0.12);
  color: #f2c797;
  font-weight: 700;
}

.hero-showcase {
  display: grid;
  gap: 14px;
}

.hero-carousel {
  display: grid;
  gap: 14px;
}

.hero-carousel-track {
  position: relative;
  min-height: 240px;
  border-radius: 22px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.04);
}

.hero-carousel-item,
.hero-carousel-placeholder {
  position: absolute;
  inset: 0;
  border: 0;
  background-size: cover;
  background-position: center;
}

.hero-carousel-item {
  opacity: 0;
  transform: scale(1.03);
  transition: opacity 0.6s ease, transform 0.8s ease;
  cursor: pointer;
}

.hero-carousel-item.is-active {
  opacity: 1;
  transform: scale(1);
}

.hero-carousel-placeholder {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
}

.hero-carousel-footer {
  display: grid;
  gap: 12px;
}

.hero-carousel-label {
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
}

.hero-carousel-footer strong {
  display: block;
  margin-top: 10px;
  font-size: 1.1rem;
  line-height: 1.45;
}

.hero-carousel-footer p {
  margin: 10px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.hero-carousel-dots {
  display: flex;
  gap: 8px;
}

.hero-carousel-dot {
  width: 10px;
  height: 10px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  cursor: pointer;
}

.hero-carousel-dot.is-active {
  background: var(--accent);
}

.hero-showcase-image {
  min-height: 220px;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(11, 16, 24, 0.08), rgba(11, 16, 24, 0.42)),
    url("https://images.unsplash.com/photo-1494526585095-c41746248156?auto=format&fit=crop&w=1200&q=80") center/cover;
}

.hero-showcase-copy span {
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
}

.hero-showcase-copy strong {
  display: block;
  margin-top: 10px;
  font-size: 1.05rem;
  line-height: 1.55;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #20b76d;
  box-shadow: 0 0 0 8px rgba(32, 183, 109, 0.15);
}

.metric-grid {
  display: grid;
  gap: 14px;
}

.metric-grid article {
  padding: 20px;
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.06));
}

.metric-grid strong {
  display: block;
  margin-bottom: 8px;
  font-size: 2rem;
  font-family: "Space Grotesk", sans-serif;
}

.metric-grid span,
.project-label,
.stack-card span {
  color: var(--muted);
}

.section-heading {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 20px;
}

.section-heading h2,
.contact-card h2 {
  font-size: clamp(2rem, 5vw, 4rem);
}

.projects-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 18px;
}

.projects-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.projects-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.filter-button {
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  cursor: pointer;
}

.filter-button.is-active,
.filter-button:hover {
  border-color: rgba(214, 162, 110, 0.35);
  background: rgba(214, 162, 110, 0.12);
}

.project-card,
.service-card {
  border-radius: var(--radius-lg);
  padding: 24px;
}

.project-card h3,
.service-card h3 {
  margin: 10px 0;
  font-size: 1.5rem;
}

.project-card {
  position: relative;
  overflow: hidden;
  min-height: 340px;
  display: flex;
  align-items: flex-end;
  transition: transform 0.35s ease, border-color 0.35s ease;
  background: linear-gradient(180deg, rgba(13, 18, 25, 0.7), rgba(13, 18, 25, 0.92));
}

.project-card-backdrop,
.gallery-card::after {
  position: absolute;
  inset: 0;
}

.project-card-backdrop {
  background-size: cover;
  background-position: center;
  transform: scale(1.03);
  transition: transform 0.5s ease;
  z-index: 0;
}

.project-card-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.project-card::after,
.gallery-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(5, 8, 12, 0.03), rgba(5, 8, 12, 0.68));
  pointer-events: none;
  z-index: 1;
}

.project-card > *,
.gallery-overlay {
  position: relative;
  z-index: 2;
}

.project-card-content {
  width: 100%;
}

.project-card:hover,
.gallery-card:hover,
.service-card:hover {
  transform: translateY(-6px);
  transition: transform 0.35s ease, border-color 0.35s ease;
  border-color: rgba(214, 162, 110, 0.35);
}

.project-card {
  cursor: pointer;
}

.project-cta {
  margin-top: 18px;
  color: var(--accent);
  font-weight: 700;
}

.project-card:hover .project-card-backdrop {
  transform: scale(1.06);
}

.project-card:hover .project-card-video {
  transform: scale(1.04);
}

.project-description {
  max-width: 42ch;
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.project-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #d8dde6;
  font-size: 0.88rem;
}

.empty-state {
  padding: 28px;
  border: 1px dashed rgba(214, 162, 110, 0.25);
  border-radius: var(--radius-lg);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.gallery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 18px;
  grid-auto-rows: 220px;
}

.gallery-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background-size: cover;
  background-position: center;
  transition: transform 0.5s ease, border-color 0.35s ease;
  cursor: pointer;
}

.gallery-tall {
  grid-row: span 2;
}

.gallery-wide {
  grid-column: span 2;
}

.gallery-overlay {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 100%;
  padding: 24px;
}

.gallery-overlay span {
  color: #d4b18d;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
}

.gallery-overlay strong {
  margin-top: 10px;
  font-size: 1.2rem;
  line-height: 1.3;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.service-card {
  background: linear-gradient(180deg, rgba(17, 22, 31, 0.75), rgba(17, 22, 31, 0.9));
}

.service-card-gold {
  background: linear-gradient(180deg, rgba(76, 49, 26, 0.55), rgba(17, 22, 31, 0.92));
}

.service-card-crimson {
  background: linear-gradient(180deg, rgba(78, 19, 30, 0.55), rgba(17, 22, 31, 0.92));
}

.service-card-graphite {
  background: linear-gradient(180deg, rgba(30, 38, 52, 0.6), rgba(17, 22, 31, 0.92));
}

.about-layout {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 18px;
  align-items: start;
}

.about-copy {
  padding: 10px 0;
}

.stack-card {
  border-radius: var(--radius-lg);
  padding: 28px;
}

.specialization-card {
  display: grid;
  gap: 18px;
}

.specialization-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.specialization-preview {
  min-height: 220px;
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(11, 16, 24, 0.12), rgba(11, 16, 24, 0.48)),
    url("https://images.unsplash.com/photo-1494526585095-c41746248156?auto=format&fit=crop&w=1200&q=80") center/cover;
}

.stack-card strong {
  display: block;
  margin-top: 12px;
  font-size: 1.6rem;
  line-height: 1.35;
  font-family: "Space Grotesk", sans-serif;
}

.contact-card {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  padding: clamp(24px, 4vw, 40px);
  border-radius: var(--radius-xl);
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 14px;
  justify-content: center;
  align-items: flex-start;
}

.contact-links a {
  font-size: 1.05rem;
  font-weight: 700;
}

.project-page {
  width: min(calc(100% - 32px), var(--container));
  margin: 0 auto;
  padding: 32px 0 80px;
}

.detail-header {
  margin-bottom: 12px;
}

.detail-layout {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 24px;
  align-items: stretch;
}

.detail-media-shell,
.detail-main-shot,
.detail-copy,
.detail-gallery-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.detail-media-shell {
  min-height: 560px;
  position: relative;
}

.detail-main-shot,
.detail-main-video {
  width: 100%;
  min-height: 560px;
  background-size: cover;
  background-position: center;
  display: block;
}

.detail-main-shot {
  cursor: pointer;
}

.detail-main-video {
  height: 100%;
  object-fit: cover;
  background: #05080c;
}

.detail-media-shell video::-webkit-media-controls-panel,
.detail-gallery-card video::-webkit-media-controls-panel,
.lightbox-media-shell video::-webkit-media-controls-panel {
  background: rgba(10, 13, 18, 0.82);
}

.detail-copy {
  padding: 32px;
}

.detail-back {
  display: inline-flex;
  margin-bottom: 28px;
  color: var(--accent);
  font-weight: 700;
}

.detail-copy h1 {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.detail-description,
.detail-extra {
  color: var(--muted);
  line-height: 1.75;
}

.detail-description {
  margin: 24px 0 0;
  font-size: 1.06rem;
}

.detail-extra {
  margin: 16px 0 0;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 24px;
}

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: #d8dde6;
  font-size: 0.88rem;
}

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

.detail-gallery-card {
  cursor: pointer;
}

.detail-gallery-card img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
}

.detail-gallery-card video {
  display: block;
  width: 100%;
  min-height: 320px;
  background: #05080c;
  object-fit: cover;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 8, 12, 0.82);
  backdrop-filter: blur(14px);
}

.lightbox-dialog {
  position: relative;
  z-index: 1;
  width: min(92vw, 1180px);
  height: min(86vh, 820px);
  margin: 7vh auto;
  display: grid;
  place-items: center;
}

.lightbox-media-shell {
  width: 100%;
  height: 100%;
  border-radius: 28px;
  overflow: hidden;
  background: rgba(10, 13, 18, 0.95);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.lightbox-media-shell img,
.lightbox-media-shell video {
  display: block;
  width: 100%;
  height: calc(100% - 56px);
  object-fit: contain;
  background: #05080c;
}

.lightbox-caption {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 0 20px;
  color: var(--text);
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 24px;
  z-index: 2;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
}

body.lightbox-open {
  overflow: hidden;
}

.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.reveal-delay-1 { transition-delay: 0.08s; }
.reveal-delay-2 { transition-delay: 0.16s; }
.reveal-delay-3 { transition-delay: 0.24s; }

@media (max-width: 980px) {
  .site-header,
  .hero,
  .projects-grid,
  .gallery-grid,
  .services-grid,
  .about-layout,
  .contact-card,
  .detail-layout,
  .project-gallery {
    grid-template-columns: 1fr;
  }

  .gallery-wide,
  .gallery-tall {
    grid-column: auto;
    grid-row: auto;
  }

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

  .site-header {
    border-radius: 28px;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .site-nav {
    flex-wrap: wrap;
    gap: 12px 18px;
  }

  .hero {
    min-height: auto;
  }

  .hero h1 {
    max-width: none;
  }

  .detail-media-shell,
  .detail-main-shot,
  .detail-main-video {
    min-height: 380px;
  }
}

@media (max-width: 640px) {
  main,
  .site-header {
    width: min(calc(100% - 20px), var(--container));
  }

  .hero-copy,
  .hero-panel,
  .project-card,
  .service-card,
  .contact-card,
  .stack-card {
    padding: 20px;
  }

  .hero-actions {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .lightbox-dialog {
    width: min(94vw, 1180px);
    height: min(78vh, 720px);
    margin: 11vh auto;
  }
}
