:root {
  --paper: #f0f4f8;
  --ink: #000;
  --image-text: #f0f4f8;

  --section-dark: #1c1c1c;
  --section-dark-text: #e6e6e6;

  --sidebar-width: 30vw;
  --sidebar-min: 280px;
  --sidebar-max: 390px;
  --sidebar-size: clamp(var(--sidebar-min), var(--sidebar-width), var(--sidebar-max));

  --font-heading: "Big Shoulders Display", sans-serif;
  --font-body: "Inter", Arial, sans-serif;
}

body.is-dark {
  --paper: #0e0e0e;
  --ink: #f5f5f5;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-y: auto;
}

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

button {
  font: inherit;
  color: inherit;
}

.page-shell {
  min-height: 100dvh;
  background: var(--paper);
}

.site-sidebar {
  position: fixed;
  z-index: 20;
  left: 0;
  top: 0;
  width: var(--sidebar-size);
  height: 100dvh;
  padding: 50px 0 50px 50px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  background: var(--paper);
}

.logo {
  font-family: var(--font-heading);
  font-size: 16px;
  line-height: 1;
  font-weight: 1000;
  letter-spacing: 0.045em;
  transform: scaleY(1.08);
  transform-origin: left center;
}

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

.logo-main {
  font-family: var(--font-heading);
  font-size: 16px;
  line-height: 1;
  font-weight: 1000;
  letter-spacing: 0.045em;
  transform: scaleY(1.08);
  transform-origin: left center;
  margin-top: 10px;
}

.logo-sub {
  margin-top: 10px;
  max-width: 240px;
  font-size: 11px;
  line-height: 1.4;
  letter-spacing: 0.04em;
  font-weight: 500;
  opacity: 0.4;
}

.sidebar-positioning {
  position: absolute;
  left: 50px;
  top: calc(50% + 105px);
  margin: 0;
  max-width: 220px;

  font-size: 11px;
  line-height: 1.35;
  font-weight: 500;
  letter-spacing: 0.04em;
  opacity: 0.48;
}

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

.logo-sub {
  margin-top: 14px;
  max-width: 280px;

  font-family: var(--font-body);
  font-size: 10px;
  line-height: 1.45;
  font-weight: 500;
  letter-spacing: 0.04em;

  opacity: 0;
  filter: blur(8px);
  transform: translateY(14px) scale(0.98);

  transition:
    opacity 420ms ease,
    filter 520ms ease,
    transform 620ms cubic-bezier(0.16, 1, 0.3, 1);
}

.logo:hover .logo-sub {
  opacity: 0.5;
  filter: blur(0);
  transform: translateY(0) scale(1);
}

.logo-main {
  transition:
    filter 420ms ease,
    transform 520ms cubic-bezier(0.16, 1, 0.3, 1);
}

.logo:hover .logo-main {
  filter: blur(0.4px);
  transform: scaleY(1.08) translateY(-1px);
}

.desktop-nav {
  position: absolute;
  left: 50px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.desktop-nav a {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  transition:
    filter 220ms ease,
    opacity 220ms ease,
    transform 220ms ease,
    letter-spacing 220ms ease;
}

.desktop-nav a:hover {
  filter: blur(1.2px);
  opacity: 0.65;
  transform: translateX(3px);
  letter-spacing: 0.08em;
}

.sidebar-bottom {
  display: flex;
  align-items: center;
  gap: 14px;
}

.social-links {
  display: flex;
  gap: 14px;
  align-items: center;
}

.social-link {
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  color: var(--ink);
  border: 1.5px solid currentColor;
  border-radius: 50%;
  font-family: var(--font-body);
  font-size: 9px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.04em;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.social-link:hover {
  opacity: 0.65;
  transform: translateY(-1px);
}

.social-behance {
  width: auto;
  min-width: 22px;
  border-radius: 9px;
  padding: 0 4px;
  letter-spacing: -0.06em;
}

.theme-toggle {
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  color: currentColor;
}

.toggle-track {
  width: 28px;
  height: 18px;
  border-radius: 999px;
  border: 1.5px solid currentColor;
  display: block;
  position: relative;
  transition:
    background 0.25s ease,
    border 0.25s ease;
}

.toggle-dot {
  position: absolute;
  top: 50%;
  left: 3px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  transform: translateY(-50%);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

body.is-dark .toggle-dot {
  transform: translate(12px, -50%);
}

body.is-dark .toggle-track {
  background: currentColor;
}

.theme-toggle-mobile {
  margin-top: 12px;
}

body.is-dark .toggle-track {

  background: currentColor;

}

body.is-dark .toggle-dot {

  transform: translate(12px, -50%);

  background: var(--paper);

}

.theme-toggle {

  cursor: none;

}

.theme-toggle * {

  cursor: none;

}

.home-stage {
  position: relative;
  margin-left: var(--sidebar-size);
  width: calc(100vw - var(--sidebar-size));
  height: 100dvh;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  overflow: hidden;
  background: #111;
}

.carousel-frame {
  position: relative;
  width: 100%;
  height: 100dvh;
  min-height: 560px;
  overflow: hidden;
  background: #111;
}

.project-image-wrap:hover .project-image {
  transform: scale(1.045);
}

.project-image-wrap {
  position: absolute;
  inset: 0;
  margin: 0;
  overflow: hidden;
  background: #111;
}

.project-image-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.5);
}

.project-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 1;
  transform: scale(1);
  transition:
    opacity 0.55s ease,
    transform 0.55s ease;
}

.image-noise {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background-image: url("../img/grain-texture-strong.png");
  background-repeat: repeat;
  background-size: 180px;
  opacity: 0.14;
  mix-blend-mode: overlay;
  transition: opacity 0.45s ease;
}

.project-image-wrap:hover .image-noise {
  opacity: 0.05;
}

.svg-filters {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.cursor-distort {
  position: absolute;
  top: 0;
  left: 0;
  width: 420px;
  height: 420px;
  pointer-events: none;
  z-index: 5;
  transform: translate(-50%, -50%);
  opacity: 0;
  background: transparent;
  filter: url("#noise-distort");
  mix-blend-mode: normal;
  -webkit-mask-image: radial-gradient(
    circle,
    rgba(0,0,0,0.7) 0%,
    rgba(0,0,0,0.4) 40%,
    rgba(0,0,0,0.15) 65%,
    transparent 85%
  );
  mask-image: radial-gradient(
    circle,
    rgba(0,0,0,0.7) 0%,
    rgba(0,0,0,0.4) 40%,
    rgba(0,0,0,0.15) 65%,
    transparent 85%
  );
  transition: opacity 0.25s ease;
}

.carousel-frame:hover .cursor-distort {
  opacity: 1;
}

.project-copy {
  position: absolute;
  z-index: 10;
  left: 32px;
  right: 32px;
  bottom: 50px;

  display: flex;
  flex-direction: column;
  align-items: flex-start;

  color: var(--image-text);
  pointer-events: none;
}

.copy-inner {
  width: 60%;
  max-width: 540px;
  min-width: 270px;
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.55s ease,
    transform 0.55s ease;
}

.project-copy h1 {
  margin: 0 0 12px;
  color: var(--image-text);
  font-family: var(--font-heading);
  font-size: 34px;
  line-height: 0.95;
  font-weight: 400;
  letter-spacing: 0.04em;
  transform: scaleY(1.06);
  transform-origin: left center;
}

.project-copy p {
  margin: 0;
  max-width: 520px;
  color: var(--image-text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.4;
  font-weight: 400;
}

.view-project {
  pointer-events: auto;
  position: relative;
  z-index: 11;
  margin-top: 46px;
  display: inline-flex;
  min-height: 28px;
  overflow: hidden;
  color: var(--image-text);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 2;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.view-project {

  transition:
    filter 220ms ease,
    opacity 220ms ease,
    transform 220ms ease,
    letter-spacing 220ms ease;
}

.view-project:hover {
  filter: blur(1.2px);
  opacity: 0.65;
  transform: translateX(3px);
  letter-spacing: 0.08em;
}

.view-project span {
  display: block;
}

.project-progress {
  margin-top: 24px;
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
  border-radius: 0;
  opacity: 0.8;
  transition: opacity 180ms ease;
}

.project-progress span {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: rgba(255, 255, 255, 0.42);
  border-radius: 0;
  will-change: transform;
}

.project-progress.is-boosted {
  opacity: 1;
}

.carousel-frame.is-transitioning .project-image {
  opacity: 0;
  transform: scale(0.985) translateY(10px);
}

.carousel-frame.is-transitioning .copy-inner {
  opacity: 0;
  transform: translateY(12px);
}

.home-content {
  margin-left: var(--sidebar-size);
  min-height: 100dvh;
  background: linear-gradient(
    to bottom,
    #1c1c1c 0%,
    #181818 100%
  );
  color: var(--section-dark-text);
  padding: 80px 32px;
}

.home-content-inner {
  max-width: 760px;
}

.section-label {
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.5);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.home-content h2 {
  margin: 0 0 24px;
  color: #fff;
  font-family: var(--font-heading);
  font-size: clamp(48px, 7vw, 112px);
  line-height: 0.82;
  letter-spacing: 0.035em;
  font-weight: 400;
  transform: scaleY(1.06);
  transform-origin: left center;
}

.home-content p {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.75);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.4;
  font-weight: 400;
  letter-spacing: 0.01em;
}

@media (pointer: fine) {
  body,
  a,
  button {
    cursor: none;
  }

  .custom-cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #000;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition:
      width 180ms ease,
      height 180ms ease,
      background 180ms ease,
      border 180ms ease,
      opacity 180ms ease;
  }

  .custom-cursor.is-dark {
    background: #fff;
  }

  .custom-cursor.is-link {
    width: 15px;
    height: 15px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
  }

  .custom-cursor.is-dark.is-link {
    width: 15px;
    height: 15px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
  }

  .custom-cursor.is-image {
    width: 30px;
    height: 30px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
  }

  .custom-cursor.is-hidden {
    opacity: 0;
  }
}

@media (min-width: 1600px) {
  .project-copy {
    bottom: 50px;
  }

  .copy-inner {
    max-width: 560px;
  }
}

.mobile-header {
  display: none;
}

@media (max-width: 1199.98px) {
  .page-shell {
    min-height: 100dvh;
  }

  .site-sidebar {
    display: none;
  }

  .mobile-header {
    position: fixed;
    z-index: 20;
    top: 0;
    left: 0;
    right: 0;
    height: 84px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 25px;
    pointer-events: none;
  }

  .mobile-header .logo,
  .menu-toggle,
  .mobile-menu {
    pointer-events: auto;
  }

  .mobile-header .logo {
    font-size: 14px;
  }

  .menu-toggle {
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    position: relative;
    cursor: pointer;
  }

  .menu-toggle span {
    position: absolute;
    left: 13px;
    right: 13px;
    height: 2px;
    border-radius: 10px;
    background: var(--ink);
    transition: transform 220ms ease;
  }

  .menu-toggle span:first-child {
    top: 18px;
  }

  .menu-toggle span:last-child {
    top: 25px;
  }

  .menu-toggle[aria-expanded="true"] span:first-child {
    transform: translateY(3.5px) rotate(45deg);
  }

  .menu-toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-3.5px) rotate(-45deg);
  }

  .mobile-menu {
    position: absolute;
    top: 72px;
    right: 25px;
    display: none;
    flex-direction: column;
    gap: 8px;
    padding: 16px;
    background: rgba(240,244,248,.92);
    border-radius: 20px;
  }

  body.is-dark .mobile-menu {
    background: rgba(20,20,20,0.9);
  }

  .mobile-menu.is-open {
    display: flex;
  }

  .mobile-menu a {
    display: inline-block;
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0;
    transition:
      filter 220ms ease,
      opacity 220ms ease,
      transform 220ms ease,
      letter-spacing 220ms ease;
  }

  .mobile-menu a:hover {
    filter: blur(1.2px);
    opacity: 0.65;
    transform: translateX(3px);
    letter-spacing: 0.08em;
  }

  .home-stage {
    margin-left: 0;
    width: 100vw;
    height: 100dvh;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
  }

  .carousel-frame {
    width: 100vw;
    height: 100dvh;
    min-height: 0;
  }

  .project-copy {
    left: 25px;
    right: 25px;
    bottom: 40px;
    min-height: 0;
    max-width: 560px;
  }

  .copy-inner {
    width: 100%;
    min-width: 0;
  }

  .project-copy h1 {
    font-size: 20px;
  }

  .project-copy p {
    font-size: 16px;
    line-height: 1.4;
  }

.view-project {
  margin-top: 24px;
  padding: 0;
  min-height: 28px;
  align-items: flex-start;
  color: var(--image-text);
  background: transparent;
  border-radius: 0;
  text-transform: none;
  font-size: 14px;
}

  .project-progress {
    margin-top: 22px;
  }

  .home-content {
    margin-left: 0;
    padding: 96px 25px 80px;
  }
}

@media (max-width: 809.98px) {
  .mobile-header {
    height: 76px;
    padding: 20px;
  }

  .mobile-header .logo {
    font-size: 14px;
  }

  .project-copy {
    left: 20px;
    right: 20px;
    bottom: 32px;
  }

  .project-copy h1 {
    font-size: 20px;
  }

  .project-copy p {
    font-size: 14px;
    line-height: 1.45;
  }

  .view-project {
    font-size: 12px;
  }
}
