:root {
  --canvas: #f4f1fa;
  --card: rgba(255, 255, 255, 0.68);
  --foreground: #332f3a;
  --muted: #635f69;
  --accent: #7c3aed;
  --accent-light: #a78bfa;
  --pink: #db2777;
  --blue: #0ea5e9;
  --green: #10b981;
  --amber: #f59e0b;
  --shadow-surface: 30px 30px 60px #cdc6d9, -30px -30px 60px #ffffff,
    inset 10px 10px 20px rgba(139, 92, 246, 0.05),
    inset -10px -10px 20px rgba(255, 255, 255, 0.8);
  --shadow-card: 16px 16px 32px rgba(160, 150, 180, 0.2),
    -10px -10px 24px rgba(255, 255, 255, 0.9),
    inset 6px 6px 12px rgba(139, 92, 246, 0.03),
    inset -6px -6px 12px rgba(255, 255, 255, 1);
  --shadow-button: 12px 12px 24px rgba(139, 92, 246, 0.3),
    -8px -8px 16px rgba(255, 255, 255, 0.4),
    inset 4px 4px 8px rgba(255, 255, 255, 0.4),
    inset -4px -4px 8px rgba(0, 0, 0, 0.1);
  --shadow-pressed: inset 10px 10px 20px #d9d4e3, inset -10px -10px 20px #ffffff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--canvas);
  color: var(--foreground);
  font-family: "DM Sans", system-ui, sans-serif;
}

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

button {
  font: inherit;
}

h1,
h2,
h3,
.brand,
.eyebrow,
.stat-orb strong,
.floating-stat strong,
.tag {
  font-family: "Nunito", system-ui, sans-serif;
}

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

.ambient {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.blob {
  position: absolute;
  width: 58vh;
  height: 58vh;
  border-radius: 999px;
  filter: blur(70px);
  opacity: 0.16;
  animation: clay-float 9s ease-in-out infinite;
}

.blob-violet {
  top: -16%;
  left: -12%;
  background: var(--accent);
}

.blob-pink {
  top: 16%;
  right: -14%;
  background: var(--pink);
  animation-name: clay-float-delayed;
  animation-delay: 2s;
}

.blob-blue {
  bottom: 0;
  left: 24%;
  background: var(--blue);
  animation-delay: 4s;
}

.blob-green {
  right: 14%;
  bottom: -18%;
  background: var(--green);
  animation-name: clay-float-delayed;
}

.site-header {
  position: sticky;
  top: 18px;
  z-index: 20;
  width: min(1120px, calc(100% - 32px));
  min-height: 72px;
  margin: 18px auto 0;
  padding: 12px 14px 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 36px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(22px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 900;
  font-size: 1.08rem;
}

.brand-mark {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 18px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  box-shadow: var(--shadow-button);
}

.nav-links {
  display: flex;
  gap: 8px;
}

.nav-links a {
  min-height: 44px;
  padding: 12px 18px;
  border-radius: 20px;
  color: var(--muted);
  font-weight: 700;
  transition: transform 200ms ease, background 200ms ease, color 200ms ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background: rgba(124, 58, 237, 0.1);
  color: var(--accent);
  transform: translateY(-2px);
  outline: none;
}

.section {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.hero {
  min-height: calc(100vh - 98px);
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(330px, 0.95fr);
  align-items: center;
  gap: 44px;
  padding: 64px 0 46px;
}

.eyebrow {
  color: var(--accent);
  font-size: 0.84rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-copy {
  display: grid;
  gap: 24px;
}

.hero h1 {
  max-width: 780px;
  font-size: clamp(3.5rem, 9vw, 6.8rem);
  line-height: 1.05;
  letter-spacing: 0;
  font-weight: 900;
  background: linear-gradient(120deg, var(--foreground) 22%, var(--accent) 62%, var(--pink));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-text,
.section-heading p,
.contact p {
  max-width: 690px;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  font-weight: 500;
  line-height: 1.75;
}

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

.button {
  display: inline-flex;
  min-height: 56px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 20px;
  padding: 0 24px;
  font-weight: 900;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 200ms ease, box-shadow 200ms ease, filter 200ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-4px);
  outline: none;
}

.button:active {
  transform: scale(0.92);
  box-shadow: var(--shadow-pressed);
}

.button-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  box-shadow: var(--shadow-button);
}

.button-secondary {
  color: var(--foreground);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-card);
}

.hero-showcase {
  position: relative;
  min-height: 560px;
}

.showreel-card {
  position: absolute;
  inset: 34px 0 28px;
  overflow: hidden;
  border-radius: 52px;
  animation: clay-breathe 6s ease-in-out infinite;
}

.showreel-video {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 498px;
  object-fit: cover;
  background: #0f172a;
}

.showreel-caption {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-radius: 24px;
  color: #fff;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: inset 4px 4px 12px rgba(255, 255, 255, 0.12),
    inset -4px -4px 12px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.showreel-caption span,
.showreel-caption strong {
  font-family: "Nunito", system-ui, sans-serif;
  font-weight: 900;
}

.showreel-caption span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.86rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.showreel-caption strong {
  font-size: clamp(1rem, 2vw, 1.35rem);
}

.clay-card,
.work-card,
.clay-panel,
.stat-orb,
.filter-bar {
  background: var(--card);
  box-shadow: var(--shadow-card);
  backdrop-filter: blur(22px);
}

.phone-card {
  position: absolute;
  inset: 34px 36px 28px 10px;
  display: grid;
  gap: 18px;
  align-content: start;
  padding: 28px;
  border-radius: 52px;
  animation: clay-breathe 6s ease-in-out infinite;
}

.mock-window {
  display: flex;
  gap: 8px;
}

.mock-window span {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  background: var(--accent-light);
  box-shadow: var(--shadow-pressed);
}

.mock-window span:nth-child(2) {
  background: var(--pink);
}

.mock-window span:nth-child(3) {
  background: var(--green);
}

.mock-visual,
.work-media {
  min-height: 270px;
  border-radius: 32px;
  box-shadow: var(--shadow-surface);
}

.visual-one {
  background:
    radial-gradient(circle at 28% 28%, rgba(255, 255, 255, 0.86) 0 8%, transparent 9%),
    radial-gradient(circle at 72% 30%, rgba(16, 185, 129, 0.86) 0 10%, transparent 11%),
    radial-gradient(circle at 38% 70%, rgba(219, 39, 119, 0.82) 0 15%, transparent 16%),
    linear-gradient(135deg, #c4b5fd, #7dd3fc 48%, #f9a8d4);
}

.mock-lines {
  display: grid;
  gap: 13px;
}

.mock-lines i {
  display: block;
  height: 22px;
  border-radius: 18px;
  background: rgba(124, 58, 237, 0.12);
  box-shadow: var(--shadow-pressed);
}

.mock-lines i:nth-child(2) {
  width: 76%;
}

.mock-lines i:nth-child(3) {
  width: 58%;
}

.floating-stat {
  position: absolute;
  display: grid;
  min-width: 138px;
  gap: 4px;
  padding: 18px;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: var(--shadow-button);
  animation: clay-float-slow 10s ease-in-out infinite;
}

.floating-stat strong {
  font-size: 2rem;
  line-height: 1;
}

.floating-stat span {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.stat-a {
  top: 0;
  right: 4px;
}

.stat-b {
  left: 0;
  bottom: 32px;
  animation-delay: 2s;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
  padding: 24px 0 84px;
}

.stat-orb {
  display: grid;
  min-height: 156px;
  place-items: center;
  align-content: center;
  gap: 6px;
  border-radius: 999px;
  transition: transform 300ms ease, box-shadow 300ms ease;
}

.stat-orb:hover {
  transform: scale(1.08) translateY(-4px);
  box-shadow: var(--shadow-button);
}

.stat-orb strong {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  color: var(--accent);
}

.stat-orb span {
  color: var(--muted);
  font-weight: 800;
}

.section-heading {
  display: grid;
  gap: 14px;
  margin-bottom: 26px;
}

.section-heading h2,
.contact h2 {
  font-size: clamp(2.4rem, 5vw, 4rem);
  line-height: 1.1;
  font-weight: 900;
}

.compact {
  max-width: 720px;
  margin-inline: auto;
  text-align: center;
}

.filter-bar {
  display: inline-flex;
  gap: 8px;
  margin-bottom: 28px;
  padding: 8px;
  border-radius: 28px;
}

.filter-pill {
  min-height: 46px;
  border: 0;
  border-radius: 20px;
  padding: 0 18px;
  color: var(--muted);
  background: transparent;
  font-weight: 900;
  cursor: pointer;
  transition: transform 200ms ease, background 200ms ease, color 200ms ease, box-shadow 200ms ease;
}

.filter-pill:hover,
.filter-pill:focus-visible {
  transform: translateY(-2px);
  color: var(--accent);
  outline: none;
}

.filter-pill.active {
  color: #fff;
  background: linear-gradient(135deg, var(--accent-light), var(--accent));
  box-shadow: var(--shadow-button);
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.work-card {
  display: grid;
  overflow: hidden;
  border-radius: 32px;
  transition: transform 450ms ease, box-shadow 450ms ease, opacity 250ms ease;
}

.work-card:hover {
  transform: translateY(-8px);
  box-shadow: 22px 24px 44px rgba(124, 58, 237, 0.18), -12px -12px 26px rgba(255, 255, 255, 0.95),
    inset 6px 6px 12px rgba(139, 92, 246, 0.04), inset -6px -6px 12px rgba(255, 255, 255, 1);
}

.work-card.hidden {
  display: none;
}

.featured {
  grid-column: span 2;
}

.work-media {
  min-height: 235px;
  margin: 18px 18px 0;
}

.media-dashboard {
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.82) 0 18%, transparent 18%),
    radial-gradient(circle at 72% 34%, #10b981 0 9%, transparent 10%),
    radial-gradient(circle at 46% 58%, #db2777 0 13%, transparent 14%),
    linear-gradient(135deg, #bfdbfe, #c4b5fd 55%, #fbcfe8);
}

.media-dreame {
  background-image: linear-gradient(rgba(10, 16, 30, 0.04), rgba(10, 16, 30, 0.18)),
    url("assets/dreame-h40/hero-living-room.png");
  background-position: center;
  background-size: cover;
}

.media-moon {
  background-image: url("assets/dreame-h40/moon-scene.png");
  background-position: center;
  background-size: cover;
}

.media-roller {
  background-image: url("assets/dreame-h40/roller-detail.png");
  background-position: center;
  background-size: cover;
}

.media-water {
  background-image: url("assets/dreame-h40/water-detail.png");
  background-position: center;
  background-size: cover;
}

.media-logo {
  background-image: url("assets/dreame-h40/dreame-logo.png");
  background-position: center;
  background-size: cover;
}

.media-l40-hero {
  background-image: linear-gradient(rgba(255, 255, 255, 0.08), rgba(124, 58, 237, 0.08)),
    url("assets/dreame-l40/product-hero.png");
  background-position: center;
  background-size: cover;
}

.media-brand {
  background:
    radial-gradient(circle at 34% 42%, rgba(255, 255, 255, 0.9) 0 16%, transparent 17%),
    radial-gradient(circle at 68% 62%, #f59e0b 0 12%, transparent 13%),
    linear-gradient(135deg, #f9a8d4, #a78bfa);
}

.media-poster {
  background:
    linear-gradient(135deg, transparent 0 35%, rgba(255, 255, 255, 0.88) 35% 48%, transparent 48%),
    radial-gradient(circle at 70% 26%, #0ea5e9 0 13%, transparent 14%),
    linear-gradient(135deg, #fde68a, #f0abfc);
}

.media-app {
  background:
    radial-gradient(circle at 32% 34%, #7c3aed 0 11%, transparent 12%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.86) 0 24%, transparent 24%),
    linear-gradient(135deg, #99f6e4, #d8b4fe);
}

.media-pack {
  background:
    radial-gradient(circle at 45% 34%, rgba(255, 255, 255, 0.92) 0 15%, transparent 16%),
    radial-gradient(circle at 72% 70%, #10b981 0 12%, transparent 13%),
    linear-gradient(135deg, #fed7aa, #f9a8d4 55%, #93c5fd);
}

.work-content {
  display: grid;
  gap: 12px;
  padding: 24px;
}

.tag {
  width: fit-content;
  border-radius: 999px;
  padding: 8px 12px;
  color: var(--accent);
  background: rgba(124, 58, 237, 0.11);
  font-size: 0.78rem;
  font-weight: 900;
}

.tag.pink {
  color: var(--pink);
  background: rgba(219, 39, 119, 0.12);
}

.tag.blue {
  color: #0369a1;
  background: rgba(14, 165, 233, 0.14);
}

.tag.green {
  color: #047857;
  background: rgba(16, 185, 129, 0.14);
}

.tag.amber {
  color: #b45309;
  background: rgba(245, 158, 11, 0.16);
}

.work-card h3 {
  font-size: clamp(1.4rem, 2.3vw, 2rem);
  line-height: 1.14;
  font-weight: 900;
}

.work-card p {
  color: var(--muted);
  font-weight: 500;
  line-height: 1.65;
}

.text-link {
  width: fit-content;
  color: var(--accent);
  font-weight: 900;
}

.about {
  padding: 94px 0 84px;
}

.case-study {
  padding: 96px 0 0;
}

.case-intro {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
  padding: clamp(26px, 5vw, 48px);
  border-radius: 48px;
}

.case-intro h2 {
  margin: 10px 0 14px;
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1.08;
  font-weight: 900;
}

.case-intro p {
  max-width: 720px;
  color: var(--muted);
  font-size: clamp(1rem, 1.8vw, 1.16rem);
  font-weight: 500;
  line-height: 1.75;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 22px;
}

.gallery-item {
  position: relative;
  grid-column: span 2;
  min-height: 290px;
  margin: 0;
  overflow: hidden;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-card);
  transition: transform 450ms ease, box-shadow 450ms ease;
}

.gallery-item.wide {
  grid-column: span 3;
  min-height: 340px;
}

.gallery-item:hover {
  transform: translateY(-8px);
  box-shadow: 22px 24px 44px rgba(14, 165, 233, 0.18), -12px -12px 26px rgba(255, 255, 255, 0.95),
    inset 6px 6px 12px rgba(139, 92, 246, 0.04), inset -6px -6px 12px rgba(255, 255, 255, 1);
}

.gallery-item img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: inherit;
  object-fit: cover;
}

.gallery-item figcaption {
  position: absolute;
  left: 16px;
  bottom: 16px;
  max-width: calc(100% - 32px);
  padding: 10px 14px;
  border-radius: 18px;
  color: #fff;
  background: rgba(15, 23, 42, 0.64);
  backdrop-filter: blur(16px);
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 0.92rem;
  font-weight: 900;
}

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

.skill-grid span {
  display: grid;
  min-height: 78px;
  place-items: center;
  border-radius: 28px;
  color: var(--foreground);
  background: rgba(255, 255, 255, 0.68);
  box-shadow: var(--shadow-card);
  font-weight: 900;
  transition: transform 250ms ease, box-shadow 250ms ease;
}

.skill-grid span:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-button);
}

.contact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 42px;
  padding: clamp(26px, 5vw, 48px);
  border-radius: 48px;
}

@keyframes clay-float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-20px) rotate(2deg);
  }
}

@keyframes clay-float-delayed {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-15px) rotate(-2deg);
  }
}

@keyframes clay-float-slow {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-30px) rotate(5deg);
  }
}

@keyframes clay-breathe {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.02);
  }
}

@media (max-width: 880px) {
  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
    padding-top: 48px;
  }

  .hero-showcase {
    min-height: 460px;
  }

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

  .featured {
    grid-column: span 2;
  }

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

  .case-intro {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .gallery-item,
  .gallery-item.wide {
    grid-column: span 1;
  }
}

@media (max-width: 620px) {
  .site-header {
    top: 10px;
    width: min(100% - 20px, 1120px);
    min-height: 64px;
    border-radius: 30px;
  }

  .brand span:last-child {
    display: none;
  }

  .nav-links a {
    padding-inline: 12px;
  }

  .hero h1 {
    font-size: clamp(3.25rem, 16vw, 4.8rem);
  }

  .hero-actions,
  .button {
    width: 100%;
  }

  .phone-card {
    inset: 38px 0 22px;
    border-radius: 38px;
    padding: 20px;
  }

  .showreel-card {
    inset: 38px 0 22px;
    border-radius: 38px;
  }

  .showreel-video {
    min-height: 400px;
  }

  .showreel-caption {
    left: 16px;
    right: 16px;
    bottom: 16px;
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .floating-stat {
    min-width: 118px;
    padding: 14px;
  }

  .stats-grid,
  .work-grid,
  .skill-grid {
    grid-template-columns: 1fr;
  }

  .featured {
    grid-column: span 1;
  }

  .filter-bar {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .stat-orb {
    min-height: 130px;
    border-radius: 36px;
  }

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

  .gallery-item,
  .gallery-item.wide {
    min-height: 245px;
  }
}

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