.case .title>div span:first-child {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
}

.case {
  color: white;
  position: relative;
  overflow: hidden;
  min-height: 150px;
  aspect-ratio: 2/1;
}

.title-row {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 16px;
}

.case-blur {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: rgba(30, 30, 30, 0.7);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  mask-image: linear-gradient(to bottom, black 0%, transparent 30%);
  -webkit-mask-image: linear-gradient(to bottom, black 0%, transparent 30%);
}

.case-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1);
  z-index: 0;
  pointer-events: none;
}

.case .title,
.case .title>div,
.case .title svg {
  position: relative;
  z-index: 2;
}

.case .title>div {
  display: block;
}

.case .title>div span {
  display: block;
  line-height: 1.4;
}


@media (min-width: 1536px) {
  .cases-grid {
    grid-template-columns: 1fr 1fr 1fr !important;
  }
}

@media (min-width: 600px) {
  .cases-grid {
    grid-template-columns: 1fr 1fr;
  }
}

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

html,
body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  background: black;
  color: rgb(179, 179, 179);
  color-scheme: dark;
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  min-height: 100vh;
  overscroll-behavior: contain;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Big Shoulders Display', 'Big Shoulders', cursive, sans-serif;
  color: rgb(247, 255, 247);
}

/* Case page typography improvements */
main.content h1 {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 2rem;
  letter-spacing: -0.02em;
}

main.content h2 {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  margin-top: 3rem;
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}

main.content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  line-height: 1.3;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

main.content p {
  font-size: 1.1rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
  color: rgba(255, 255, 255, 0.85);
}

main.content ul {
  margin-bottom: 2rem;
}

main.content li {
  font-size: 1.05rem;
  line-height: 1.6;
  margin-bottom: 0.75rem;
  color: rgba(255, 255, 255, 0.8);
}

main.content li strong {
  color: rgb(247, 255, 247);
  font-weight: 600;
}

/* Case page layout improvements */
.content-flex.content-flex-wrap {
  gap: 3rem;
  margin-bottom: 3rem;
}

.right-column {
  flex: 1;
  min-width: 300px;
}

.left-column {
  flex: 1;
  min-width: 300px;
}

/* Video container improvements */
.video-container {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: transparent;
}

.video-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease, filter 0.3s ease;
  filter: grayscale(1);
}

.video-container:hover .video-thumb {
  transform: scale(1.05);
  filter: grayscale(0);
}

/* Ensure consistent behavior for all video thumbnails */
.cases-grid .video-thumb,
.content .video-thumb {
  cursor: pointer;
  transition: transform 0.4s ease, filter 0.3s ease;
  filter: grayscale(1);
  display: block;
}

.cases-grid .video-container:hover .video-thumb,
.content .video-container:hover .video-thumb {
  filter: grayscale(0);
  transform: scale(1.05);
}

/* Play button improvements */
.play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.play-button:hover {
  background: white;
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.play-button .play-icon {
  margin-left: 3px;
}

.right-column :first-child {
  margin-top: 0;
}

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

a:hover {
  text-decoration: line-through;
}

.case-link:hover {
  text-decoration: none;
}

.active {
  text-decoration: line-through;
}

.display {
  font-family: 'Big Shoulders', cursive;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-right: 24px;
  z-index: 24;
}

.page {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 96px);
  padding: 48px;
}
@media (max-width: 1024px) {
  .page {
    padding: 16px;
  }
}

.footer {
  z-index: 0;
  margin-top: 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 24px;
}

.home-page {
  display: flex;
  flex-direction: row;
  padding: 0;
  height: 100vh;
  overflow: hidden;
}

.sidebar {
  display: flex;
  flex-direction: column;
  padding: 48px;
  width: 50%;
  overflow: hidden;
}

.content {
  width: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.home-page .content {
  width: 50%;
}

.home-page .sidebar-content {
  align-items: center;
  justify-content: center;
  padding-top: 5vh;
  flex-grow: 1;
}

@media (max-width: 1024px) {
  .home-page .sidebar-content {
    padding-top: 0;
  }
}

.home-page .sidebar {
  position: relative;
}

.home-page .footer {
  position: absolute;
  bottom: 48px;
  left: 48px;
  right: 48px;
}

@media (max-width: 600px) {
  .home-page .footer-row {
    display: flex;
    flex-direction: column;
    gap: 12px;
    font-size: 20px;
  }

  .home-page .footer-row:nth-child(2) {
    display: flex;
    flex-direction: column-reverse;
  }
}


.globe-canvas {
  /* position: fixed; */
  width: 500px;
  height: 500px;
  object-fit: cover;
  bottom: 0;
  flex-shrink: 0;
  /* transform: translateY(min(50vh, 25vw)) scale(1); */
  transform: translateY(-6.5vw) scale(1.2);
  z-index: 0;
}

@media (min-width: 1536px) {
  .globe-canvas {
    transform: translateY(-5.5vw) scale(1.4);
  }
}

@media (max-width: 1024px) {
  .globe-canvas {
    position: fixed;
    transform: translateY(50vh) scale(3);
    filter: blur(1px);
    z-index: 0;
  }
}

@media (min-width: 600px) {
  .cases-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 1024px) {
  .home-page .content {
    position: absolute;
    z-index: 0;
    width: 100%;
    inset: 0px;
    filter: blur(10px);
    opacity: 0.25;
    transform: none;
  }

  .home-page .video {
    transform: scale(1.2);
  }

  .home-page .sidebar {
    width: 100%;
    z-index: 1;
  }
}

.home-page .sidebar {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.video {
  display: block;
  overflow: hidden;
  width: 120vw;
  height: 100vh;
  object-fit: cover;
  object-position: center;
  transform: translateX(-30%) scale(1.2);
  filter: grayscale(1);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  text-align: left;
}

tr {
  border-bottom: 1px solid rgb(47, 47, 47);
  line-height: 3rem;
  width: calc(100% - 16px);
  padding-inline: 8px;
}

th {
  font-size: 18px;
}

td:first-child {
  color: white;
}

@media (max-width: 1024px) {
  tr {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: space-between;
    font-size: 14px;
  }

  td:first-child {
    font-size: 1.2rem;
    width: 100%;
  }
}

@keyframes fadein {
  from {
    opacity: 0;
    transform: translateY(-15px);
  }

  to {
    opacity: 1;
  }
}

/* Staggered fade-in animations for hvem page */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.stagger-1 {
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.stagger-2 {
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

.stagger-3 {
  animation: fadeInUp 0.8s ease-out 0.6s both;
}

.stagger-4 {
  animation: fadeInUp 0.8s ease-out 0.8s both;
}

.stagger-5 {
  animation: fadeInUp 0.8s ease-out 1.0s both;
}

.stagger-6 {
  animation: fadeInUp 0.8s ease-out 1.2s both;
}

.case {
  overflow: hidden;
  padding: 24px;
  cursor: pointer;
}

.case .title {
  display: flex;
  align-items: center;
  transform: translate(-48px);
  transition: all 0.2s ease-in-out;
  gap: 24px;
}

.case .title h3 {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
  margin-bottom: 4px;
}

@media (max-width: 1024px) {
  .case .title h3 {
    font-size: 1.75rem;
  }
}

.case svg {
  transform: translateX(-42px) rotate(-240deg);
  transition: all 0.2s ease-in-out;
}

.case:hover svg {
  transform: translateX(0px) rotate(0deg);
}

.case:hover .title {
  transform: translateX(0px);
}

.fade-in {
  animation: fadein 1s ease-in-out;
}

.display-title {
  display: flex;
  flex-direction: row;
  gap: 0;
  text-align: center;
  font-size: 5.5vw;
  letter-spacing: 0.05em;
  line-height: 1em;
  transform: scaleY(2.25) scaleX(1.6);
  font-weight: 500;
  margin-inline: auto;
  z-index: 1;
}

@media (max-width: 1024px) {
  .display-title {
    flex-direction: column;
    transform: scaleY(1.7) scaleX(1.6);
    font-size: min(20vw, 140px);
    letter-spacing: -0.04em;
    font-weight: 600;
  }
}

@keyframes blurin {
  from {
    opacity: 0;
    transform: scaleY(1.6) scaleX(1.6) skewX(-5deg);
    backdrop-filter: blur(99999px);
    -webkit-backdrop-filter: blur(99999px);
  }

  to {
    opacity: 1;
    transform: scaleY(1.6) scaleX(1.6) skewX(0deg);
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
  }
}

.gradient-overlay {
  inset: 0;
  width: 100vw;
  height: 100vh;
  position: fixed;
  z-index: 9999;
  pointer-events: none;
}

.grain-effect {
  background: url('grain.png');
  opacity: 0.015;
  position: absolute;
  inset: 0;
  width: 130vw;
  height: 130vh;
  left: -15vw;
  top: -15vh;
  z-index: 9999;
}

@media
only screen and (-webkit-min-device-pixel-ratio: 2),
only screen and (   min--moz-device-pixel-ratio: 2),
only screen and (     -o-min-device-pixel-ratio: 2/1),
only screen and (        min-device-pixel-ratio: 2),
only screen and (                min-resolution: 192dpi),
only screen and (                min-resolution: 2dppx) { 
  .grain-effect {
    opacity: 0.1;
  }
}

.sidebar-content {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.content-flex {
  display: flex;
  column-gap: 48px;
  line-height: 2rem;
}

@media (max-width: 1024px) {
  .content-flex {
    flex-direction: column;
  }
}

.table-margin-top {
  margin-top: 48px;
}

.footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.footer-row-margin {
  margin-top: 12px;
}

.case-link {
  display: block;
  text-decoration: none;
  color: inherit;
}

.case-animated {
  opacity: 0;
  transform: translateY(24px);
}

.video-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.85);
  align-items: center;
  justify-content: center;
  transition: opacity 0.3s;
  opacity: 0;

}

.modal-content {
  position: relative;
  width: 60vw;
  max-width: 100vw;
  aspect-ratio: 16/9;
  margin: 0 20vw;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Responsive modal for mobile and vertical videos */
@media (max-width: 768px) {
  .modal-content {
    width: 90vw;
    margin: 0 5vw;
    max-height: 90vh;
  }
}

/* Special handling for vertical aspect ratios */
.modal-content[style*="aspect-ratio: 9/16"],
.modal-content[style*="aspect-ratio: 3/4"],
.modal-content[style*="aspect-ratio: 4/5"] {
  width: 40vw;
  margin: 0 30vw;
  max-height: 85vh;
}

@media (max-width: 768px) {
  .modal-content[style*="aspect-ratio: 9/16"],
  .modal-content[style*="aspect-ratio: 3/4"],
  .modal-content[style*="aspect-ratio: 4/5"] {
    width: 60vw;
    margin: 0 20vw;
    max-height: 80vh;
  }
}

.close-button {
  position: absolute;
  top: -45px;
  right: 0;
  font-size: 2rem;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  z-index: 10;
}

.modal-video {
  width: 100%;
  height: 100%;
  border: none;
  background: black;
  aspect-ratio: 16/9;
  object-fit: contain;
  max-width: 100%;
  max-height: 100%;
}

.content-flex-wrap {
  flex-wrap: wrap;
}

.left-column {
  flex: 1 1 300px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

/* Cases page specific video styles - consolidated above */

.play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: white;
  border: none;
  border-radius: 50%;
  padding: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
  cursor: pointer;
  z-index: 2;
}

.play-icon {
  display: block;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
  transform: translateX(2px);
}

.right-column {
  flex: 2 1 400px;
  min-width: 300px;
}

/* Hover Thumbnail */
.hover-thumbnail {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 1000;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.8);
  transition: opacity 0.3s ease, transform 0.3s ease;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  max-width: 400px;
  max-height: 280px;
}

@media (max-width: 600px) {
  .hover-thumbnail {
    display: none;
  }
}

.hover-thumbnail.visible {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.hover-thumbnail img {
  width: 100%;
  height: auto;
  display: block;
}

.project-row {
  cursor: none;
  transition: background-color 0.2s ease;
}

tbody tr:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

/* BTS (Behind The Scenes) Section Styles */
.bts-section {
  margin-top: 4rem;
  padding-top: 3rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.bts-section h2 {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 1rem;
  color: white;
  letter-spacing: -0.02em;
}

.bts-intro {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.8);
  margin-bottom: 2.5rem;
  max-width: 600px;
  line-height: 1.6;
}

.bts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  grid-auto-rows: 200px;
  gap: 8px;
  margin-top: 2rem;
  width: 100%;
  grid-auto-flow: dense;
}

.bts-item {
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  height: 100%;
}

/* Utility span classes */
.span-1 { grid-column: span 1; }
.span-2 { grid-column: span 2; }
.span-3 { grid-column: span 3; }
.span-4 { grid-column: span 4; }

.row-span-1 { grid-row: span 1; }
.row-span-2 { grid-row: span 2; }
.row-span-3 { grid-row: span 3; }

/* Add visual interest with varied transitions */
.bts-item:nth-child(odd) {
  transition: transform 0.5s ease, box-shadow 0.3s ease;
}

.bts-item:nth-child(even) {
  transition: transform 0.3s ease, box-shadow 0.5s ease;
}

/* Desktop breakpoints */
@media (min-width: 1200px) {
  .bts-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    grid-auto-rows: 250px;
    gap: 12px;
  }
}

.bts-item:hover {
  transform: scale(1.05) !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  z-index: 100;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.bts-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease, filter 0.3s ease;
  filter: grayscale(0.3);
  display: block;
}

.bts-item:hover .bts-image {
  transform: scale(1.05);
  filter: grayscale(0);
}

/* BTS Video specific styling */
.bts-video .video-container {
  position: relative;
  width: 100%;
  height: 100%;
}

.bts-video-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(0.3);
  transition: transform 0.4s ease, filter 0.3s ease;
}

.bts-video:hover .bts-video-thumb {
  transform: scale(1.05);
  filter: grayscale(0);
}

.bts-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.bts-play-btn:hover {
  background: white;
  transform: translate(-50%, -50%) scale(1.1);
}

.bts-play-btn .play-icon {
  width: 20px;
  height: 20px;
  margin-left: 2px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .bts-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 150px;
    gap: 4px;
  }
  
  /* Simplify spans on mobile */
  .span-3, .span-4 { grid-column: span 2; }
  
  .bts-section {
    margin-top: 3rem;
    padding-top: 2rem;
  }
  
  .bts-section h2 {
    font-size: 2rem;
  }
  
  .bts-play-btn {
    width: 40px;
    height: 40px;
  }
  
  .bts-play-btn .play-icon {
    width: 16px;
    height: 16px;
  }
  
  /* Mobile typography adjustments */
  main.content h1 {
    font-size: 2.5rem;
  }
  
  main.content h2 {
    font-size: 1.75rem;
    margin-top: 2rem;
  }
  
  .bts-section h2 {
    font-size: 2.25rem;
  }
  
  main.content p {
    font-size: 1rem;
  }
  
  main.content li {
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .bts-grid {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 140px;
    gap: 2px;
  }
}
