/* GLOBAL */
body {
  font-family: din-condensed, sans-serif;
  color: #111;
}

.case-study {
  max-width: 1200px;
  margin: 80px auto;
  padding: 40px 80px;
}

/* BACK BUTTON */
.back-button {
  display: inline-block;
  margin-top: 50px;
  padding: 20px 48px;
  background: #111;
  color: #fff;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  letter-spacing: 1px;
  transition: 0.3s ease;
}

.back-button:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

/* HERO */
.cs-hero {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  align-items: center;
  gap: 80px;
  padding-bottom: 6rem
}

.cs-hero h1 {
  font-size: clamp(3rem, 6vw, 5.5rem);
  line-height: 0.95;
}

.hero-sub {
  font-family: "bebas-neue-pro", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-size: 1.5rem;
  max-width: 500px;
  line-height: 1.6;
}

.hero-meta {
  margin-top: 30px;
  font-size: 2rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  display: flex;
  gap: 20px;
}

.hero-content img {
  margin-top: 30px;
  margin-bottom: 30px;
  width: 75px;
  height: 75px;
  padding-right: 40px;
  object-fit: contain;
}

.hero-image img {
  position: relative;
  left: -150px;
  width: 150%;
  animation: float 6s ease-in-out infinite;
filter: drop-shadow(0 50px 40px rgba(0, 0, 0, 0.5));
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}

/* HEADINGS */
h2 {
  font-size: 2rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 20px;
}

/* BODY COPY */
p {
  font-family: "bebas-neue-pro", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-size: 1.5rem;
  line-height: 1.8;
  max-width: 650px;
}

/* TWO COLUMN */
.cs-two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 100px;
}

/* BRAND GRID */
.brand-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  align-items: center;
  justify-content: space-evenly;
}

.brand-grid img {
  width: 100%;
  margin: 0 auto;
}

/* WIREFRAMES */
.cs-wireframes img {
  width: 100%;
  max-width: 1100px;
  margin: 40px auto 0 auto;
  display: block;
}


.cs-wireframes .cta-button {
  float: right;
}

/* CTA */
.cta-button {
  display: inline-block;
  margin-top: 50px;
  padding: 20px 48px;
  background: #111;
  color: #fff;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  letter-spacing: 1px;
  transition: 0.3s ease;
}

.cta-button2 {
  display: inline-block;
  margin-top: 50px;
  padding: 20px 48px;
  background: #111;
  color: #fff;
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  letter-spacing: 1px;
  transition: 0.3s ease;
}

.cta-button:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.cta-button2:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.site-header {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 1300px;
  padding: 1.25rem 2.5rem;
  background-color: #ffffff;
  border-bottom: 2px solid black;
  z-index: 1000;
}


/* GRID LAYOUT */
.nav-container {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  column-gap: 3rem;
}

/* LOGO */
.nav-logo {
  font-size: 1.75rem;       /* if text logo */
  font-weight: 700;
  letter-spacing: -0.02em;
}

.nav-logo img {
  height: 25px;             /* slightly smaller */
}

/* NAV LINKS */
.nav-links {
  display: flex;
  justify-content: center;
  gap: 2.25rem;
  list-style: none;
  margin: 0;
  padding: 0;

  /* optical centering tweak */
  transform: translateX(-1rem);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  padding: 0;
  margin: 0;
}

.nav-links a {
  position: relative;
  overflow: hidden;
  z-index: 1;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  color: black;
  padding: 0.5rem 0.75rem;
}

/* Border animation */
.nav-links a::before {
  content: '';
  position: absolute;
  inset: 0;
  border-top: 2px solid #262626;
  border-bottom: 2px solid #262626;
  transform: scaleY(2);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  z-index: 2;
}

/* Background fill */
.nav-links a::after {
  content: '';
  position: absolute;
  inset: 2px 0;
  background-color: #262626;
  transform: scale(0);
  opacity: 0;
  transition: transform 0.3s ease 0.05s, opacity 0.3s ease 0.05s;
  z-index: -1;
}

/* Hover */
.nav-links a:hover {
  color: #fff;
}

.nav-links a:hover::before {
  transform: scaleY(1);
  opacity: 1;
}

.nav-links a:hover::after {
  transform: scale(1);
  opacity: 1;
}



/* EXTRA TEXT */
.nav-extra {
  font-size: 0.95rem;
  font-weight: 500;
  color: black;
  white-space: nowrap;
  text-align: right;
}


.design-block {
  margin-top: 60px;
}

.design-block h3 {
  font-size: 2rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 30px;
}

/* COLOR GRID */
.color-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
}

.color-card {
  text-align: center;
}

.color-swatch {
  width: 100%;
  height: 100px;
  border-radius: 8px;
  margin-bottom: 12px;
}

.color-card p {
  font-size: 0.9rem;
  line-height: 1.4;
}

.color-card span {
  font-size: 0.8rem;
  opacity: 0.6;
}

/* TYPOGRAPHY */
.type-showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  margin-top: 40px;
}

.display-font {
  font-family: din-condensed, sans-serif;
  font-size: 1rem;
  opacity: 0.6;
}

.display-sample {
  font-family: din-condensed, sans-serif;
  font-size: 3rem;
  margin-top: 10px;
}

.body-font {
  font-size: 1rem;
  opacity: 0.6;
}

.body-sample {
  margin-top: 10px;
  max-width: 400px;
}

/* UI ELEMENTS */
.ui-section {
  background: #ffffff;
}

.ui-container {
  max-width: 1200px;
  margin: 0 auto;
}

.section-title {
  font-size: 2rem;
  margin-bottom: 80px;
}

.ui-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  margin-bottom: 100px;
}

.ui-row.reverse {
  direction: rtl;
}

.ui-row.reverse .ui-text,
.ui-row.reverse .ui-visual {
  direction: ltr;
}

.ui-text h4 {
  font-size: 1.5rem;
}

.ui-text p {
  font-size: 1.5rem;
  line-height: 1.6;
  max-width: 500px;
}

.ui-visual {
  display: flex;
  justify-content: center;
}

/* Components */
.ui-btn-primary {
  background: #ff9d00;
  color: white;
  border: none;
  padding: 16px 40px;
  border-radius: 40px;
  font-weight: 600;
  scale: 150%;
}

.ui-card-preview {
  border-radius: 25px;
  text-align: center;
}

.ui-card-preview  img{
  width: 150%;
  transform: translateX(-80px);
}

.ui-nav-preview span {
  margin: 0 15px;
  font-weight: 600;
  opacity: 0.6;
  font-size: 2rem;
}

.ui-nav-preview .active {
  color: #ff9d00;
  opacity: 1;
}


.tone-description {
  max-width: 600px;
  line-height: 1.6;
  opacity: 0.85;
}

.cs-process {
  padding-bottom: 4rem;
}

.type-brand  h4{
  font-family: "bebas-neue-pro", sans-serif;
  font-weight: 400;
  font-style: normal;
  font-size: 2rem;
}

.vines-layout {
  display: flex;
  gap: 80px;
  align-items: flex-start;
  margin-top: 40px;
}

/* TEXT SIDE */
.vines-text {
  flex: 1;
}

/* VIDEO SIDE */
#screen-recording {
  flex: 0 0 380px;   /* keeps video width stable */
  display: flex;
  justify-content: flex-end;
}

#screen-recording video {
  width: 90%;
  max-width: 380px;
  border-radius: 50px;
}

.motion-video {
  flex: 0 0 380px;
  display: flex;
  justify-content: flex-end;
  position: relative; /* THIS is what you're missing */
  left: -100px;
}


.motion-layout {
  display: flex;
  align-items: center;
  gap: 80px;
  margin-top: 30px;
}

/* Text side */
.motion-text {
  flex: 1;
}

.motion-tech {
  margin-top: 40px;
}

.motion-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  margin-bottom: 80px;
}

/* flip layout every other row */
.motion-row.reverse {
  direction: rtl;
}

.motion-row.reverse .motion-text,
.motion-row.reverse .motion-visual {
  direction: ltr;
}

.motion-text h4 {
  font-size: 1.5rem;
  margin-bottom: 10px;
}

.motion-text p {
  max-width: 500px;
}

.motion-visual {
  display: flex;
  justify-content: center;
}

.motion-visual img {
  width: 100%;
  max-width: 450px;
  border-radius: 20px;
  box-shadow: 0 25px 50px rgba(0,0,0,0.15);
}

.view-button {
  float: right;
  margin-top: 60px;
  margin-left: 20px;
  padding: 20px 48px;
  background: #111;
  color: #fff;
  text-decoration: none;
  font-family: din-condensed, sans-serif;
  transition: 0.3s ease;
    border-radius: 50px;
}


.view-button:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.button-row {
  display: flex;
  gap: 20px;
  align-items: center;
  margin-top: 40px;
}

/* ================================
   MOBILE / TABLET VIEWPORT
   ================================ */
@media screen and (max-width: 768px) {
.cs-hero,
.ui-row,
.motion-row,
.cs-two-column,
.brand-grid,
.type-showcase {
  text-align: center;
}
  html, body {
    overflow-x: hidden;
  }

  .case-study {
    padding: 32px 20px;
    margin: 40px auto;
  }

  /* ================= HERO ================= */
  .cs-hero {
    grid-template-columns: 1fr;
    gap: 32px;

  }

  .hero-image img {
    width: 100%;
    height: auto;
  }

  .hero-meta {
    flex-wrap: wrap;
    font-size: 1rem;
    gap: 8px;
  }

  .hero-content img {
    width: 48px;
    height: 48px;
  }

  /* ================= TWO COLUMN ================= */
  .cs-two-column {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  /* ================= BRAND ================= */
  .brand-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* ================= TYPE / COLOR ================= */
  .type-showcase {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .color-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* ================= UI ROW ================= */
  .ui-row {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .ui-row.reverse {
    direction: ltr;
  }

  /* ================= MOTION ================= */
  .motion-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .motion-layout {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
  }

  .motion-text,
  .motion-visual {
    width: 100%;
  }

  .motion-visual img {
    width: 100%;
    height: auto;
  }

  .motion-video,
  .motion-visual {
    position: static;
    left: 0 !important;
    justify-content: center;
  }

  /* ================= BUTTONS ================= */
  .view-button,
  .cta-button,
  .cta-button2,
  .back-button {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 20px auto 0;
    text-align: center;
  }

  /* ================= NAV ================= */
  .nav-container {
    grid-template-columns: 1fr;
    gap: 16px;
    text-align: center;
  }

  .nav-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
  }

  .nav-extra {
    text-align: center;
  }

}