/* ============================================
   PORTFOLIO — Premium Dark Design System
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

/* --- Custom Properties --- */
:root {
  --bg-primary: #06060f;
  --bg-secondary: #0d0d1a;
  --bg-card: rgba(255, 255, 255, 0.03);
  --bg-card-hover: rgba(255, 255, 255, 0.06);
  --border-subtle: rgba(255, 255, 255, 0.06);
  --border-accent: rgba(124, 58, 237, 0.3);

  --text-primary: #f0f0f5;
  --text-secondary: rgba(240, 240, 245, 0.6);
  --text-muted: rgba(240, 240, 245, 0.35);

  --accent-purple: #7c3aed;
  --accent-blue: #2563eb;
  --accent-violet: #8b5cf6;
  --gradient-primary: linear-gradient(135deg, #7c3aed, #2563eb);
  --gradient-text: linear-gradient(135deg, #a78bfa, #60a5fa);
  --gradient-glow: linear-gradient(135deg, rgba(124, 58, 237, 0.15), rgba(37, 99, 235, 0.15));

  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;

  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-spring: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  overflow-x: hidden;
  position: relative;
  width: 100%;
}

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-primary);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
}

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

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

ul,
ol {
  list-style: none;
}

/* --- Utility --- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.section-padding {
  padding: 120px 0;
}

.gradient-text {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Scroll Animations --- */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

.reveal-delay-1 {
  transition-delay: 0.1s;
}

.reveal-delay-2 {
  transition-delay: 0.2s;
}

.reveal-delay-3 {
  transition-delay: 0.3s;
}

/* ============================================
   NAVBAR
   ============================================ */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: 20px 0;
  transition: var(--transition-smooth);
}

.navbar.scrolled {
  padding: 12px 0;
  background: rgba(6, 6, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-subtle);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.nav-logo span {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast);
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-primary);
  border-radius: 2px;
  transition: width var(--transition-smooth);
}

.nav-links a:hover {
  color: var(--text-primary);
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-cta {
  padding: 10px 24px;
  background: var(--gradient-primary);
  border-radius: var(--radius-xl);
  font-size: 0.88rem;
  font-weight: 600;
  color: white !important;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  border: none;
  cursor: pointer;
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(124, 58, 237, 0.35);
}

.nav-cta::after {
  display: none !important;
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
  z-index: 1001;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition-fast);
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 100px;
  position: relative;
  overflow: visible;
}

/* Subtle gradient orbs in background — behind the 3D */
.hero::before {
  content: '';
  position: absolute;
  top: -20%;
  left: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -10%;
  right: -5%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

/* ============================================
   UNICORN STUDIO BACKGROUND (Desktop & Mobile)
   ============================================ */
.hero-unicorn-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.6;
  /* Apply opacity directly to the wrapper */

  /* Softly fade the top AND bottom of the animation into the background to avoid hard line separations */
  mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
}

/* 
 * Instead of squishing or using CSS scale transforms which can fail or leave black bezels,
 * we force the Unicorn Studio container to act like an 'object-fit: cover' video.
 * It maintains a perfect 16:10 (1440x900) aspect ratio with absolute screen-covering limits.
 */
.hero-unicorn-bg>div {
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  width: 100vw !important;
  height: 62.5vw !important; /* 100vw * (900/1440) = 62.5vw */
  min-height: 100vh !important;
  min-width: 160vh !important; /* 100vh * (1440/900) = 160vh */
  transform: translate(-50%, -50%) !important;
}

/* Hide Unicorn Studio Watermark Technique 1: CSS Override */
a[href*="unicorn.studio?utm_source=public-url"],
a[href*="unicorn.studio"],
a[href*="unicorn"] {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
}

/* Hide Unicorn Studio Watermark Technique 2: Gradient Mask Block & Interactive Scroll Badge */
.hero-unicorn-watermark-cover {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 150px;
  z-index: 2;
  /* Sits directly over the video/bg */
  /* Replaces the ugly solid block with a smooth gradient fade into the background color */
  background: linear-gradient(to top, var(--bg-primary) 20%, transparent 100%);
  /* Flex layout to center the scroll button securely above the unicorn studio logo's typical location */
  display: flex;
  justify-content: center;
  align-items: flex-end;
  padding-bottom: 26px;
  /* Lifted up slightly to guarantee it sits dead-center on the logo even when canvas scales on mobile */
  pointer-events: none;
  /* Let clicks pass through the general area */
}

/* Glassmorphism scroll badge */
.scroll-down-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 44px;
  /* Increased vertical height to cast a wider coverage net over the logo */
  min-width: 250px;
  /* Guarantees it's wider than the Unicorn logo */
  /* Stealth glassmorphism: blur the text underneath without popping visually */
  background: rgba(10, 10, 20, 0.5);
  backdrop-filter: blur(24px) saturate(120%);
  -webkit-backdrop-filter: blur(24px) saturate(120%);
  border: none;
  /* Removed border */
  border-radius: 100px;
  color: rgba(255, 255, 255, 0.4);
  /* Make the text very subtle */
  font-size: 0.85rem;
  font-weight: 400;
  text-decoration: none;
  transition: all 0.3s ease;
  pointer-events: auto;
  /* Re-enable clicks so the link works */
  box-shadow: none;
  /* Removed shadow */
}

.scroll-down-badge:hover {
  background: rgba(10, 10, 20, 0.7);
  color: rgba(255, 255, 255, 0.7);
  /* Slightly brighter on hover */
  transform: none;
  /* Removed hover pop */
  box-shadow: none;
  /* Removed hover shadow */
}

.scroll-arrow {
  font-size: 1.2rem;
  display: inline-block;
  animation: bounce-y 2s infinite ease-in-out;
}

@keyframes bounce-y {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(4px);
  }
}

.hero-unicorn-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse 100% 100% at 100% 0%, #000 10%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 100% 100% at 100% 0%, #000 10%, transparent 80%);
}

/* Hero content grid — sits on top of the 3D */
.hero-grid {
  position: relative;
  z-index: 2;
  max-width: none;
  margin-left: 0;
  margin-right: auto;
  padding-left: 80px;
}

.hero-content {
  max-width: 580px;
  text-align: left;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: rgba(6, 6, 15, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 28px;
}

.hero-badge .dot {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(0.85);
  }
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -1.5px;
  margin-bottom: 24px;
  text-shadow: 0 2px 30px rgba(6, 6, 15, 0.5);
}

.hero-title .highlight {
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 40px;
  max-width: 480px;
  text-shadow: 0 1px 10px rgba(6, 6, 15, 0.6);
}

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

.hero-subtext {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 16px;
  letter-spacing: 0.5px;
  text-align: left;
  width: 100%;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: var(--gradient-primary);
  border-radius: var(--radius-xl);
  font-size: 0.95rem;
  font-weight: 600;
  color: white;
  border: none;
  cursor: pointer;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
  position: relative;
  z-index: 5;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(124, 58, 237, 0.4);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: rgba(6, 6, 15, 0.5);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition-fast);
  position: relative;
  z-index: 5;
}

.btn-secondary:hover {
  border-color: var(--accent-purple);
  color: var(--text-primary);
  background: rgba(124, 58, 237, 0.1);
}

.hero-stats {
  display: flex;
  gap: 40px;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.stat h3 {
  font-size: 1.8rem;
  font-weight: 800;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat p {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-top: 4px;
}

/* ============================================
   LOGOS / SOCIAL PROOF
   ============================================ */
.logos-section {
  padding: 60px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.logos-label {
  text-align: center;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 32px;
}

.logos-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}

.logo-item {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-muted);
  opacity: 0.5;
  transition: opacity var(--transition-fast);
  letter-spacing: -0.5px;
}

.logo-item:hover {
  opacity: 0.8;
}

/* ============================================
   TOOLS SECTION
   ============================================ */
.tools-section {
  padding: 60px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.tools-label {
  text-align: center;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 32px;
}

.tools-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}

.tool-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: transform var(--transition-fast), opacity var(--transition-fast);
  opacity: 0.7;
}

.tool-item:hover {
  opacity: 1;
  transform: translateY(-4px);
}

.tool-item svg {
  display: block;
  filter: drop-shadow(0 4px 12px rgba(124, 58, 237, 0.1));
  transition: filter var(--transition-fast);
}

.tool-item:hover svg {
  filter: drop-shadow(0 8px 20px rgba(124, 58, 237, 0.2));
}

.tool-item p {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-align: center;
}

.tool-logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
  display: block;
  filter: grayscale(100%);
  opacity: 0.6;
  transition: filter var(--transition-fast), opacity var(--transition-fast);
}

.tool-item:hover .tool-logo {
  filter: grayscale(100%);
  opacity: 0.9;
}

/* ============================================
   SECTION HEADERS
   ============================================ */
.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 64px;
}

.section-tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent-violet);
  margin-bottom: 16px;
}

.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ============================================
   SERVICES SECTION
   ============================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 40px 32px;
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity var(--transition-smooth);
}

.service-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-accent);
  transform: translateY(-4px);
}

.service-card:hover::before {
  opacity: 1;
}

.service-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--gradient-glow);
  border: 1px solid var(--border-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
  font-size: 1.4rem;
}

.service-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.3px;
}

.service-card p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

.service-features {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.service-features li {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.service-features li::before {
  content: '✓';
  color: var(--accent-violet);
  font-weight: 700;
  font-size: 0.75rem;
}

/* ============================================
   PORTFOLIO / WORK SECTION
   ============================================ */
#work {
  position: relative;
  background: var(--bg-secondary);
}

#work::before {
  content: '';
  position: absolute;
  top: 0;
  left: -20%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

#work::after {
  content: '';
  position: absolute;
  bottom: 10%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  position: relative;
  z-index: 1;
}

.portfolio-cards-wrapper {
  display: contents;
}

.portfolio-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  transition: var(--transition-smooth);
  cursor: pointer;
}

.portfolio-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-accent);
  box-shadow: 0 20px 60px rgba(124, 58, 237, 0.1);
}

.portfolio-card-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.15), rgba(37, 99, 235, 0.1));
}

.portfolio-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-smooth);
}

.portfolio-card:hover .portfolio-card-image img {
  transform: scale(1.05);
}

.portfolio-card-info {
  padding: 24px;
}

.portfolio-card-info h3 {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 6px;
  letter-spacing: -0.2px;
}

.portfolio-card-info p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.65;
}

.portfolio-card-tags {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.tag {
  padding: 4px 12px;
  background: rgba(124, 58, 237, 0.08);
  border: 1px solid rgba(124, 58, 237, 0.15);
  border-radius: var(--radius-xl);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--accent-violet);
}

/* ============================================
   ABOUT ME SECTION
   ============================================ */
#about {
  background: var(--bg-secondary);
}

.about-content {
  max-width: 1000px;
  margin: 0 auto;
}

.about-grid {
  display: grid;
  grid-template-columns: 400px 1fr;
  gap: 60px;
  align-items: center;
}

.about-image-wrap {
  position: relative;
}

.about-image-wrap img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  display: block;
  box-shadow: 0 20px 60px rgba(124, 58, 237, 0.2);
  transition: transform var(--transition-smooth);
}

.about-image-wrap:hover img {
  transform: translateY(-8px);
}

.about-header {
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent-violet);
  margin-bottom: 12px;
  display: inline-block;
}

.about-title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
  margin-bottom: 40px;
}

.about-text {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.about-text p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.8;
}

.about-text p:first-letter {
  font-size: 1.2rem;
}

.emoji {
  color: var(--text-secondary);
}

/* Responsive */
@media (max-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-image-wrap {
    max-width: 300px;
    margin: 0 auto;
  }
}

/* ============================================
   TESTIMONIALS SECTION
   ============================================ */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.testimonial-card {
  background: transparent;
  border: none;
  padding: 0;
  transition: none;
}

.testimonial-card:hover {
  border-color: transparent;
  background: transparent;
  transform: none;
}

.testimonial-card--image {
  padding: 0;
}

.testimonial-image-wrap {
  width: 100%;
  height: 400px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.testimonial-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.testimonial-source {
  font-size: 0.78rem;
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 12px 6px 6px;
}

.testimonial-stars {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  color: #fbbf24;
  font-size: 0.9rem;
}

.testimonial-text {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 24px;
  font-style: italic;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 14px;
}

.testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gradient-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  color: white;
  flex-shrink: 0;
}

.testimonial-author-info h4 {
  font-size: 0.92rem;
  font-weight: 600;
}

.testimonial-author-info p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ============================================
   CTA SECTION
   ============================================ */
.cta-section {
  padding: 100px 0;
}

.cta-box {
  text-align: center;
  padding: 80px 40px;
  background: var(--gradient-glow);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-xl);
  position: relative;
  overflow: hidden;
}

.cta-box::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 40%, rgba(124, 58, 237, 0.06) 0%, transparent 50%),
    radial-gradient(circle at 70% 60%, rgba(37, 99, 235, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

.cta-box>* {
  position: relative;
  z-index: 1;
}

.cta-box h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -1px;
  margin-bottom: 16px;
}

.cta-box p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto 36px;
  line-height: 1.6;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  padding: 60px 0 32px;
  border-top: 1px solid var(--border-subtle);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}

.footer-brand p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.65;
  margin-top: 12px;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.footer-col a {
  display: block;
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-bottom: 10px;
  transition: color var(--transition-fast);
}

.footer-col a:hover {
  color: var(--text-primary);
}

.footer-ig-link {
  display: inline-flex !important;
  align-items: center;
  gap: 8px;
}

.footer-ig-link svg {
  flex-shrink: 0;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 32px;
  border-top: 1px solid var(--border-subtle);
}

.footer-bottom p {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.footer-socials {
  display: flex;
  gap: 16px;
}

.footer-socials a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  color: var(--text-secondary);
  transition: var(--transition-fast);
}

.footer-socials a:hover {
  border-color: var(--accent-purple);
  color: var(--accent-violet);
  background: rgba(124, 58, 237, 0.08);
}

/* ============================================
   MOBILE RESPONSIVE
   ============================================ */

/* --- Tablet Landscape (≤ 1024px) --- */
@media (max-width: 1024px) {
  .hero-grid {
    padding-left: 48px;
  }

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

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

}

/* --- Tablet Portrait / Small Screens (≤ 768px) --- */
@media (max-width: 768px) {
  .section-padding {
    padding: 80px 0;
  }

  /* Mobile Navigation */
  .nav-links {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    height: 100dvh;
    background: rgba(13, 13, 26, 0.95);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    flex-direction: column;
    justify-content: center;
    gap: 28px;
    padding: 40px;
    border-left: 1px solid var(--border-subtle);
    transition: right var(--transition-smooth);
    z-index: 999;
  }

  .nav-links.open {
    right: 0;
  }

  .nav-links a {
    font-size: 1.1rem;
    font-weight: 500;
  }

  .nav-cta {
    margin-top: 8px;
    text-align: center;
    width: 100%;
    justify-content: center;
  }

  .hamburger {
    display: flex;
  }

  /* Hero — mobile layout: centered, no 3D */
  .hero {
    min-height: 100vh;
    padding: 100px 0 48px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
  }

  /* Completely hide Unicorn Studio and watermark cover on mobile */
  .hero-unicorn-bg,
  .hero-unicorn-watermark-cover,
  .hero-unicorn-overlay {
    display: none !important;
  }

  /* Subtle native CSS animated gradient mesh for mobile — more depth */
  .hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 30%, rgba(124, 58, 237, 0.08) 0%, transparent 50%),
                radial-gradient(circle at 70% 60%, rgba(37, 99, 235, 0.06) 0%, transparent 45%),
                radial-gradient(circle at 50% 80%, rgba(200, 80, 255, 0.04) 0%, transparent 40%),
                radial-gradient(circle at 80% 15%, rgba(100, 200, 255, 0.03) 0%, transparent 30%);
    pointer-events: none;
    z-index: 0;
    animation: mobileGradientMesh 16s ease-in-out infinite alternate;
  }

  .hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 50% 0%, rgba(124, 58, 237, 0.05) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
    animation: mobileGlowPulse 8s ease-in-out infinite alternate;
  }

  @keyframes mobileGradientMesh {
    0% { transform: scale(1) translate(0, 0) rotate(0deg); }
    25% { transform: scale(1.03) translate(-1.5%, 1%) rotate(0.5deg); }
    50% { transform: scale(0.97) translate(1%, -1.5%) rotate(-0.3deg); }
    75% { transform: scale(1.02) translate(0.5%, 1.5%) rotate(0.2deg); }
    100% { transform: scale(1) translate(-0.5%, -0.5%) rotate(0deg); }
  }

  @keyframes mobileGlowPulse {
    0% { opacity: 0.6; }
    100% { opacity: 1; }
  }

  /* ---- Mobile Hero Intro Animations ---- */
  /* All hero children start invisible; JS adds .hero-intro-ready to trigger the cascade */
  .hero-badge,
  .hero-title,
  .hero-description,
  .hero-actions,
  .hero-subtext,
  .hero-stats {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s ease-out, transform 0.7s ease-out;
  }

  /* Staggered fade-in once JS adds the trigger class */
  .hero-content.hero-intro-ready .hero-badge {
    opacity: 1; transform: translateY(0);
    transition-delay: 0s;
  }
  .hero-content.hero-intro-ready .hero-title {
    opacity: 1; transform: translateY(0);
    transition-delay: 0.15s;
  }
  .hero-content.hero-intro-ready .hero-description {
    opacity: 1; transform: translateY(0);
    transition-delay: 1.8s; /* After typewriter finishes */
  }
  .hero-content.hero-intro-ready .hero-actions {
    opacity: 1; transform: translateY(0);
    transition-delay: 2.2s;
  }
  .hero-content.hero-intro-ready .hero-subtext {
    opacity: 1; transform: translateY(0);
    transition-delay: 2.5s;
  }
  .hero-content.hero-intro-ready .hero-stats {
    opacity: 1; transform: translateY(0);
    transition-delay: 2.8s;
  }

  /* Typewriter cursor */
  .typewriter-cursor {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: var(--accent-purple);
    margin-left: 3px;
    vertical-align: text-bottom;
    animation: cursorBlink 0.7s step-end infinite;
  }

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

  /* Text content — centered on mobile */
  .hero-grid {
    padding-left: 24px;
    padding-right: 24px;
    padding-top: 0;
    max-width: none;
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .hero-content {
    max-width: 100%;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .hero-actions {
    justify-content: center;
  }

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

  /* Smaller hero title on mobile */
  .hero-title {
    font-size: clamp(1.6rem, 6.5vw, 2.2rem);
    letter-spacing: -0.8px;
    line-height: 1.15;
  }

  .hero-description {
    font-size: 0.88rem;
    max-width: 90%;
    margin-bottom: 28px;
    line-height: 1.6;
  }

  .hero-badge {
    margin-bottom: 16px;
    font-size: 0.75rem;
  }

  /* Glowing stats container on mobile */
  .hero-stats {
    flex-direction: row;
    flex-wrap: wrap; /* allow wrapping to avoid overlap */
    justify-content: center;
    gap: 16px 12px; /* proper spacing between stats */
    margin-top: 36px;
    padding: 24px 16px;
    border-top: none;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(124, 58, 237, 0.2);
    border-radius: var(--radius-lg);
    box-shadow:
      0 0 40px rgba(124, 58, 237, 0.12),
      0 0 80px rgba(124, 58, 237, 0.06),
      inset 0 1px 0 rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    width: 100%;
    position: relative;
    overflow: clip; /* Clips shimmer pseudo-element but doesn't create a scroll container */
  }

  /* Subtle light reflection sweep */
  .hero-stats::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(105deg,
        transparent 40%,
        rgba(255, 255, 255, 0.03) 45%,
        rgba(255, 255, 255, 0.05) 50%,
        rgba(255, 255, 255, 0.03) 55%,
        transparent 60%);
    pointer-events: none;
    animation: shimmer 4s ease-in-out infinite;
  }

  @keyframes shimmer {

    0%,
    100% {
      transform: translateX(-30%) rotate(0deg);
    }

    50% {
      transform: translateX(30%) rotate(0deg);
    }
  }

  .stat {
    flex: 1 1 auto; /* Allow wrapping and sizing based on content */
    min-width: 0; 
    text-align: center;
    padding: 8px 4px;
  }

  .stat h3 {
    font-size: clamp(0.95rem, 3.8vw, 1.25rem); /* Slightly smaller to help fit 3 in a row */
    letter-spacing: -0.3px; /* Condense horizontally */
  }

  .stat p {
    font-size: 0.65rem;
  }

  /* Sections */
  .section-header {
    margin: 0 auto 48px;
  }

  .section-title {
    font-size: clamp(1.5rem, 6vw, 2rem);
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
    gap: 16px;
    position: relative;
  }

  .portfolio-cards-wrapper {
    display: contents;
  }

  .services-grid,
  .testimonials-grid {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .service-card {
    padding: 32px 24px;
  }

  #testimonials {
    padding: 24px 0 32px;
  }

  #testimonials .section-header {
    margin: 0 auto 16px;
  }

  /* Testimonials — tight spacing on mobile */
  .testimonial-card {
    padding: 0;
  }

  .testimonial-card--image {
    padding: 0;
  }

  .testimonial-image-wrap {
    height: auto;
    border-radius: var(--radius-md);
  }

  .testimonial-image-wrap img {
    width: 100%;
    height: auto;
    object-fit: contain;
  }

  .testimonial-text {
    font-size: 0.95rem;
  }

  /* Logos */
  .logos-section {
    padding: 40px 0;
  }

  .logos-grid {
    gap: 20px 28px;
  }

  .logo-item {
    font-size: 1.1rem;
  }

  /* Portfolio cards */
  .portfolio-card-info {
    padding: 20px;
  }

  /* CTA */
  .cta-section {
    padding: 60px 0;
  }

  .cta-box {
    padding: 56px 24px;
    border-radius: var(--radius-lg);
  }

  .cta-box h2 {
    font-size: clamp(1.5rem, 6vw, 2rem);
  }

  .cta-box p {
    font-size: 0.95rem;
  }

  /* Footer */
  .footer {
    padding: 48px 0 24px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-brand p {
    max-width: 100%;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}

/* --- Small Phones (≤ 480px) --- */
@media (max-width: 480px) {
  .hero {
    padding: 80px 0 40px;
  }

  .hero-grid {
    padding-left: 20px;
    padding-right: 20px;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero-title {
    font-size: clamp(1.5rem, 6vw, 1.9rem);
    letter-spacing: -0.6px;
  }

  .hero-description {
    font-size: 0.84rem;
    line-height: 1.6;
    margin-bottom: 24px;
  }

  .hero-actions {
    flex-direction: column;
    gap: 12px;
    width: 100%;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
    justify-content: center;
    padding: 14px 24px;
  }

  .hero-stats {
    padding: 20px 16px;
    margin-top: 28px;
  }

  .stat {
    text-align: center;
    padding: 6px 4px;
  }

  .stat h3 {
    font-size: 1.2rem;
  }

  .stat p {
    font-size: 0.65rem;
    margin-top: 2px;
  }

  .container {
    padding: 0 16px;
  }

  .section-padding {
    padding: 60px 0;
  }

  .section-header {
    margin: 0 auto 36px;
  }

  .section-title {
    font-size: clamp(1.4rem, 6vw, 1.8rem);
  }

  .section-subtitle {
    font-size: 0.92rem;
  }

  .logos-label {
    font-size: 0.72rem;
    letter-spacing: 1px;
  }

  .logos-grid {
    gap: 16px 24px;
  }

  .logo-item {
    font-size: 0.95rem;
  }

  .nav-links {
    width: 100%;
    padding: 40px 32px;
    border-left: none;
  }

  .cta-box {
    padding: 44px 20px;
  }

  .cta-box h2 {
    font-size: clamp(1.3rem, 5.5vw, 1.7rem);
  }
}

/* Mobile nav overlay */
.nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 998;
}

.nav-overlay.active {
  display: block;
}

/* ============================================
   CONTACT MODAL
   ============================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(6, 6, 15, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-box {
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  max-width: 520px;
  width: 100%;
  position: relative;
  transform: translateY(24px) scale(0.97);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(124, 58, 237, 0.08);
}

.modal-overlay.active .modal-box {
  transform: translateY(0) scale(1);
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition-fast);
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  border-color: var(--border-accent);
}

.modal-title {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}

.modal-subtitle {
  font-size: 0.92rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.5;
}

/* Form Inputs */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
  letter-spacing: 0.3px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-primary);
  font-size: 0.95rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  outline: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent-purple);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.15);
}

.form-group textarea {
  resize: vertical;
  min-height: 100px;
}

/* Submit Button */
.form-submit {
  width: 100%;
  justify-content: center;
  margin-top: 8px;
  padding: 16px 32px;
  font-size: 1rem;
}

.form-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.form-submit.loading {
  pointer-events: none;
}

.form-submit.loading svg {
  animation: spin 0.8s linear infinite;
}

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

/* Feedback Message */
.form-feedback {
  margin-top: 16px;
  padding: 0;
  font-size: 0.88rem;
  text-align: center;
  border-radius: var(--radius-sm);
  transition: all 0.3s ease;
}

.form-feedback.success {
  padding: 14px;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.25);
  color: #22c55e;
}

.form-feedback.error {
  padding: 14px;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #ef4444;
}

/* Thank You Page */
.thank-you-page {
  text-align: center;
  padding: 20px 0;
}

.thank-you-icon {
  font-size: 3.5rem;
  margin-bottom: 20px;
  animation: thankYouPop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes thankYouPop {
  0% {
    transform: scale(0);
    opacity: 0;
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.thank-you-page .modal-title {
  margin-bottom: 12px;
}

.thank-you-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 24px;
  animation: fadeInHint 1s ease 1s both;
}

@keyframes fadeInHint {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* Modal Responsive */
@media (max-width: 768px) {
  .modal-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .modal-box {
    max-width: 100%;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    padding: 28px 20px 32px;
    max-height: 92vh;
    overflow-y: auto;
    transform: translateY(100%);
  }

  .modal-overlay.active .modal-box {
    transform: translateY(0);
  }

  .modal-title {
    font-size: 1.3rem;
    margin-bottom: 4px;
  }

  .modal-subtitle {
    font-size: 0.85rem;
    margin-bottom: 20px;
  }

  .form-group {
    margin-bottom: 14px;
  }

  .form-group label {
    font-size: 0.78rem;
    margin-bottom: 6px;
  }

  .form-group input,
  .form-group textarea {
    padding: 12px 14px;
    font-size: 0.9rem;
  }

  .form-group textarea {
    min-height: 80px;
  }

  .form-submit {
    padding: 14px 24px;
    font-size: 0.92rem;
    margin-top: 4px;
  }

  .modal-close {
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
  }

  .thank-you-icon {
    font-size: 2.8rem;
    margin-bottom: 14px;
  }
}

@media (max-width: 480px) {
  .modal-box {
    padding: 24px 16px 28px;
    max-height: 95vh;
  }

  .modal-title {
    font-size: 1.2rem;
  }

  .modal-subtitle {
    font-size: 0.82rem;
    margin-bottom: 16px;
  }

  .form-group {
    margin-bottom: 12px;
  }

  .form-group input,
  .form-group textarea {
    padding: 11px 12px;
    font-size: 0.88rem;
  }

  .form-group textarea {
    min-height: 70px;
  }

  .form-submit {
    padding: 13px 20px;
    font-size: 0.88rem;
  }
}