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

:root {
  --bg: #050507;
  --surface: #0e0f12;
  --surface-strong: #14161a;
  --text: #ffffff;
  --muted: #a1a1aa;
  --primary: #8b5cf6;
  --primary-soft: rgba(139, 92, 246, 0.12);
  --border: rgba(255, 255, 255, 0.08);
  --radius: 24px;
}

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

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background:
    radial-gradient(circle at top center, var(--primary-soft), transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Film Grain Overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: url("https://grainy-gradients.vercel.app/noise.svg");
  opacity: 0.04;
  pointer-events: none;
  z-index: 9999;
}

h1,
h2,
h3,
.brand-label {
  font-family: "Outfit", sans-serif;
  font-weight: 800;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

/* --- Navigation & Topbar --- */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 60px;
  background: transparent;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.topbar.scrolled {
  padding: 16px 60px;
  background: rgba(10, 10, 13, 0.94);
  backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 1002;
  transition: transform 0.3s ease;
}

.brand:hover {
  transform: scale(1.02);
}

.brand img {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  object-fit: cover;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.brand-info {
  display: flex;
  flex-direction: column;
}

.brand-label {
  font-size: 1.1rem;
  letter-spacing: 0.05em;
  line-height: 1.1;
}

.brand-tag {
  font-size: 0.8rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.2em;
}

.navigation {
  display: flex;
  align-items: center;
  gap: 32px;
}

.navigation a {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 500;
  position: relative;
  padding-bottom: 4px;
}

.navigation a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
}

.navigation a:hover {
  color: var(--text);
}

.navigation a:hover::after {
  width: 100%;
}

.menu-toggle {
  display: none;
  background: transparent;
  border: none;
  color: var(--text);
  font-size: 1.6rem;
  cursor: pointer;
  z-index: 1002;
}

/* --- Hero Section --- */
.hero {
  height: 100vh;
  height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 120px 24px 60px;
  overflow: hidden;
}

.hero-video-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero-video-bg video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.4) contrast(1.1);
}

.hero-content {
  text-align: center;
  max-width: 900px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 50px;
  color: var(--primary);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin-bottom: 32px;
}

.hero h1 {
  font-size: clamp(2.8rem, 6vw, 5.5rem);
  line-height: 1.05;
  margin-bottom: 24px;
  text-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.hero p {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--muted);
  max-width: 600px;
  margin-bottom: 40px;
}

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

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 16px 32px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  color: #fff;
  box-shadow: 0 8px 24px rgba(139, 92, 246, 0.4);
}

.btn-primary:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(139, 92, 246, 0.6);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
  border-color: var(--border);
  color: var(--text);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-4px);
}

/* --- Layout & Sections --- */
main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 40px;
}

.section {
  padding: 80px 0;
  position: relative;
  z-index: 1;
}

.section-heading {
  margin-bottom: 40px;
  text-align: left;
}

.section-heading.center {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.section-heading span {
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-weight: 600;
  font-size: 0.85rem;
  display: block;
  margin-bottom: 12px;
}

.section-heading h2 {
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  line-height: 1.1;
}

/* --- Bento Grids --- */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.bento-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  transition: all 0.4s ease;
  display: flex;
  flex-direction: column;
}

.bento-item:hover {
  background: var(--surface-strong);
  border-color: rgba(139, 92, 246, 0.3);
  transform: translateY(-6px);
}

.bento-item h3 {
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.bento-item p {
  color: var(--muted);
  font-size: 0.95rem;
}

.bento-item > i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 68px;
  height: 68px;
  margin-bottom: 22px;
  border-radius: 16px;
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.2),
    rgba(139, 92, 246, 0.05)
  );
  color: var(--primary);
  font-size: 2rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.main-concept {
  grid-column: span 2;
  background: linear-gradient(145deg, rgba(139, 92, 246, 0.12), transparent);
  justify-content: center;
}

.main-concept h3 {
  font-size: 1.8rem;
}

/* --- Work & Portfolio --- */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

.ig-card {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition:
    transform 0.4s ease,
    border-color 0.4s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ig-card:hover {
  transform: scale(1.02);
  border-color: rgba(139, 92, 246, 0.4);
}

.ig-card .instagram-media {
  margin: 0 !important;
  min-width: 100% !important;
  max-width: 100% !important;
  width: 100% !important;
}

.project-domain {
  margin-bottom: 80px;
  padding: 40px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  border-radius: 32px;
}

.domain-header {
  margin-bottom: 32px;
  text-align: center;
}

.domain-header h3 {
  font-size: 2.2rem;
  color: var(--primary);
  margin-bottom: 12px;
}

.projects-grid-dynamic {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 32px;
}

.projects-grid-dynamic .ig-card {
  width: 100%;
  max-width: 340px;
  flex: 0 0 auto;
}

/* --- Contact Section --- */
.contact-card.immersive {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 40px;
  padding: 80px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 60px;
  position: relative;
  overflow: hidden;
}

.contact-card.immersive::after {
  content: "";
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(
    circle,
    rgba(139, 92, 246, 0.15),
    transparent 70%
  );
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
}

.contact-info,
.contact-actions {
  position: relative;
  z-index: 1;
}

.contact-info {
  flex: 1;
  max-width: 500px;
}

.contact-info h2 {
  font-size: clamp(2.4rem, 4vw, 3.5rem);
  margin-bottom: 16px;
  line-height: 1.1;
}

.contact-info p {
  color: var(--muted);
  font-size: 1.1rem;
}

.contact-actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 320px;
}

.contact-actions .btn {
  width: 100%;
  justify-content: flex-start;
  padding: 20px 32px;
}

.contact-actions .btn i {
  font-size: 1.2rem;
  width: 24px;
  text-align: center;
}

/* --- Footer --- */
.footer {
  padding: 80px 40px 40px;
  border-top: 1px solid var(--border);
  background: #000;
  position: relative;
  overflow: hidden;
}

.footer-bg-text {
  position: absolute;
  top: 55%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 16vw;
  font-family: "Outfit", sans-serif;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.03);
  z-index: 0;
  pointer-events: none;
  white-space: nowrap;
}

.footer-content,
.footer-bottom {
  position: relative;
  z-index: 1;
}

.footer-content {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 40px;
}

.footer-brand {
  max-width: 340px;
}

.footer-brand .brand {
  margin-bottom: 24px;
}

.footer-brand p {
  color: var(--muted);
  font-size: 0.95rem;
}

.footer-links-group {
  display: flex;
  gap: 60px;
  flex-wrap: wrap;
}

.footer-col h4 {
  color: var(--text);
  font-family: "Outfit", sans-serif;
  font-size: 1.1rem;
  margin-bottom: 20px;
}

.footer-col nav {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-col a {
  color: var(--muted);
  font-size: 0.95rem;
}

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

.footer-bottom {
  max-width: 1400px;
  margin: 60px auto 0;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 0.85rem;
}

.social-links {
  display: flex;
  gap: 16px;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  transition: all 0.3s ease;
}

.social-links a:hover {
  background: var(--primary);
  transform: translateY(-3px);
}

/* --- Lightbox --- */
.lightbox {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.85);
  padding: 24px;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.lightbox.visible {
  opacity: 1;
  visibility: visible;
}

.lightbox-inner {
  width: min(100%, 960px);
  background: rgba(12, 12, 16, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 28px;
  overflow: hidden;
  position: relative;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.lightbox.visible .lightbox-inner {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  right: 24px;
  top: 24px;
  border: none;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  color: var(--text);
  font-size: 1.5rem;
  cursor: pointer;
  z-index: 10;
  backdrop-filter: blur(4px);
  transition: background 0.3s ease;
}

.lightbox-close:hover {
  background: var(--primary);
}

.lightbox-content {
  display: grid;
  grid-template-columns: 1fr;
  min-height: 420px;
}

.lightbox-content video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-height: 70vh;
}

.lightbox-copy {
  padding: 32px;
  text-align: center;
}

.lightbox-copy h3 {
  font-size: 1.8rem;
  margin-bottom: 12px;
}

.lightbox-copy p {
  color: var(--muted);
}

/* --- Utilities --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition:
    opacity 0.8s ease,
    transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

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

/* --- Mobile Responsiveness --- */
@media (max-width: 980px) {
  main {
    padding: 0 24px;
  }

  .topbar {
    padding: 24px;
    background: transparent;
    border: none;
    backdrop-filter: none;
    box-shadow: none;
  }

  .topbar.scrolled {
    padding: 16px 24px;
    background: rgba(10, 10, 13, 0.96);
    backdrop-filter: blur(20px);
  }

  .brand-info {
    display: none;
    /* Hide text on mobile for cleaner look */
  }

  .menu-toggle {
    display: block;
    margin-left: auto;
  }

  .navigation {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    background: rgba(10, 10, 13, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 32px;
    transform: translateY(-100%);
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
  }

  .navigation.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .navigation a {
    font-size: 2rem;
    font-family: "Outfit", sans-serif;
  }

  .navigation a::after {
    display: none;
  }

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

  .hero-actions .btn {
    width: 100%;
  }

  .bento-grid,
  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .main-concept {
    grid-column: span 1;
  }

  .project-domain {
    padding: 0;
    margin-bottom: 60px;
    background: transparent;
    border: none;
    border-radius: 0;
  }

  .contact-card.immersive {
    flex-direction: column;
    padding: 60px 32px;
    text-align: center;
    gap: 40px;
  }

  .contact-actions {
    width: 100%;
    min-width: unset;
  }

  .footer-content {
    flex-direction: column;
    gap: 40px;
  }

  .footer-links-group {
    flex-direction: column;
    gap: 40px;
  }

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

  /* Target dynamic carousels specifically on mobile */
  .projects-grid-dynamic .ig-card {
    max-width: 100%;
    flex: 1 1 100%;
  }

  .has-carousel {
    display: flex;
    flex-wrap: nowrap !important;
    justify-content: flex-start;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 16px;
    padding-bottom: 20px;
    margin: 0 -24px;
    /* bleed out of main padding */
    padding-inline: 24px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .has-carousel::-webkit-scrollbar {
    display: none;
  }

  .has-carousel .ig-card {
    flex: 0 0 90% !important;
    max-width: none !important;
    scroll-snap-align: start;
  }
}
