/* ==========================================================================
   GLOBAL CUSTOM DESIGN SYSTEM & EXTENSIONS — WALEED AAMIR
   Matches existing visual identity: Gallient Serif & Inter-Variable typography,
   #101010 dark background, #F5F2EB text, signature button & link animations.
   ========================================================================== */

:root {
  --bg-primary: #101010;
  --bg-card: #151517;
  --bg-card-hover: #1c1c20;
  --text-primary: #F5F2EB;
  --text-muted: rgba(245, 242, 235, 0.65);
  --border-subtle: rgba(245, 242, 235, 0.1);
  --border-hover: rgba(245, 242, 235, 0.22);
  --accent-purple: #8D51E7;
  --accent-purple-glow: rgba(141, 81, 231, 0.22);
  --accent-green: #00d084;
  --accent-green-glow: rgba(0, 208, 132, 0.18);
}

/* Base resets & layout helper */

/* Header contact indicator circle */
.header__contact-circle {
  display: inline-block;
  width: 7px;
  height: 7px;
  background-color: var(--accent-green);
  border-radius: 50%;
  margin-right: 8px;
  box-shadow: 0 0 8px var(--accent-green-glow);
  vertical-align: middle;
}



/* ==========================================================================
   PROJECTS GALLERY (/all-work)
   ========================================================================== */



.projects-hero__lead {
  font-size: clamp(1.1rem, 1.8vw, 1.35rem);
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 780px;
  margin-bottom: 3rem;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 4rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.5rem;
}

.filter-btn {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  padding: 0.6rem 1.4rem;
  border-radius: 9999px;
  font-family: inherit;
  font-size: 0.9rem;
  font-variation-settings: "wght" 500;
  cursor: pointer;
  transition: all 0.25s ease;
}

.filter-btn:hover {
  border-color: var(--text-primary);
  color: var(--text-primary);
}

.filter-btn.active {
  background: var(--text-primary);
  color: var(--bg-primary);
  border-color: var(--text-primary);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: 2.5rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 3.333vw 10vw;
}

@media only screen and (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.35s ease, box-shadow 0.35s ease;
  position: relative;
}

.project-card:hover {
  transform: translateY(-8px);
  border-color: var(--border-hover);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.project-card__img-wrap,
.project-card__thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #1e1e24;
  position: relative;
}

.project-card__img,
.project-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-card__img,
.project-card:hover .project-card__thumb img {
  transform: scale(1.06);
}

.project-card__content,
.project-card__body {
  padding: 2rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.project-card__category {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-purple);
  margin-bottom: 0.75rem;
  font-variation-settings: "wght" 600;
}

.project-card__title {
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
  font-variation-settings: "wght" 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.project-card__arrow {
  color: var(--text-muted);
  transition: transform 0.2s ease, color 0.2s ease;
}

.project-card:hover .project-card__arrow {
  transform: translate(3px, -3px);
  color: var(--text-primary);
}

.project-card__desc {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  flex: 1;
}

.project-card__stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.stack-tag {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  padding: 0.3rem 0.65rem;
  border-radius: 6px;
  font-size: 0.78rem;
  color: #cfcaca;
}

.empty-state {
  grid-column: 1 / -1;
  color: var(--text-muted);
  text-align: center;
  padding: 5rem 1rem;
  font-size: 1.1rem;
}

/* ==========================================================================
   TECHNICAL CASE STUDY DETAILS (/projects/:slug)
   ========================================================================== */
.case-study-hero,
.project-header-hero {
  padding: 10vw 3.333vw 4vw;
  max-width: 1400px;
  margin: 0 auto;
}

.case-study-back,
.back-nav {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  margin-bottom: 2rem;
  transition: color 0.2s;
}

.case-study-back:hover,
.back-nav:hover {
  color: var(--text-primary);
}

.case-study-meta,
.project-hero__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-purple);
  margin-bottom: 1.25rem;
  font-variation-settings: "wght" 600;
}

.case-study-title,
.project-hero__title {
  font-size: clamp(42px, 7.5vw, 92px);
  line-height: 0.96;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
}

.case-study-subtitle,
.project-hero__subtitle {
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  line-height: 1.5;
  color: var(--text-muted);
  max-width: 820px;
  margin-bottom: 2.5rem;
}

.case-study-actions,
.project-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 4rem;
}

.case-study-banner,
.project-hero__media {
  width: 100%;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  margin-bottom: 6vw;
  background: #18181c;
}

.case-study-banner img,
.project-hero__media img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.case-study-layout,
.project-details-grid {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 5rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 3.333vw 8vw;
}

@media only screen and (max-width: 1024px) {
  .case-study-layout,
  .project-details-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

.case-sidebar,
.project-sidebar {
  position: sticky;
  top: 6rem;
  height: fit-content;
}

.sidebar-block,
.sidebar-widget {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-subtle);
}

.sidebar-label,
.sidebar-widget__label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  font-variation-settings: "wght" 600;
}

.sidebar-val,
.sidebar-widget__value,
.tech-stack-pills {
  font-size: 1.05rem;
  color: var(--text-primary);
  line-height: 1.5;
}

.btn-action {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.85rem 1.75rem;
  border-radius: 9999px;
  font-size: 0.95rem;
  text-decoration: none;
  font-variation-settings: "wght" 600;
  transition: all 0.25s ease;
  font-family: inherit;
}

.btn-action.btn-primary {
  background: var(--text-primary);
  color: var(--bg-primary);
}

.btn-action.btn-primary:hover {
  background: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(255, 255, 255, 0.15);
}

.btn-action.btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
}

.btn-action.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--border-hover);
  transform: translateY(-2px);
}

.case-study-banner {
  width: 100%;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  margin-bottom: 6vw;
  background: #18181c;
}

.case-study-banner img {
  width: 100%;
  max-height: 720px;
  object-fit: cover;
  display: block;
}

.case-study-layout {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 5rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 3.333vw 8vw;
}

@media only screen and (max-width: 1024px) {
  .case-study-layout {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

.case-sidebar {
  position: sticky;
  top: 6rem;
  height: fit-content;
}

.sidebar-block {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--border-subtle);
}

.sidebar-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  font-variation-settings: "wght" 600;
}

.sidebar-val {
  font-size: 1.05rem;
  color: var(--text-primary);
  line-height: 1.5;
}

.tech-pill {
  display: inline-block;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-subtle);
  padding: 0.4rem 0.85rem;
  border-radius: 6px;
  font-size: 0.82rem;
  margin: 0 0.35rem 0.5rem 0;
  color: #ddd;
}

.case-section {
  margin-bottom: 5rem;
}

.case-section__title {
  font-size: clamp(24px, 3.2vw, 36px);
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
  position: relative;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-subtle);
}

.case-section__text {
  font-size: 1.12rem;
  line-height: 1.8;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.case-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 2.25rem;
  margin-bottom: 2rem;
}

.case-card h4 {
  font-size: 1.25rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-variation-settings: "wght" 600;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--text-primary);
}

.feature-check {
  color: var(--accent-green);
  flex-shrink: 0;
  margin-top: 3px;
}

.metrics-banner {
  background: linear-gradient(135deg, rgba(141, 81, 231, 0.12) 0%, rgba(0, 208, 132, 0.08) 100%);
  border: 1px solid rgba(141, 81, 231, 0.3);
  border-radius: 14px;
  padding: 2.5rem;
  margin-bottom: 2rem;
}

.metrics-banner h3 {
  font-size: 1.35rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  font-variation-settings: "wght" 600;
}

.metrics-banner p {
  font-size: 1.1rem;
  line-height: 1.7;
  color: #ddd;
}

.gallery-grid {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.gallery-grid::-webkit-scrollbar {
  display: none;
}
.gallery-btn {
  background: rgba(245, 242, 235, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.25s ease;
}
.gallery-btn:hover {
  background: rgba(245, 242, 235, 0.1);
  border-color: var(--border-hover);
}

.gallery-item {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  background: #18181c;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.project-nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4rem 3.333vw;
  max-width: 1400px;
  margin: 0 auto;
  border-top: 1px solid var(--border-subtle);
}

.case-card.solution-card {
  margin-top: 1rem;
  border-color: rgba(0, 208, 132, 0.3);
}

.nav-next {
  text-align: right;
  margin-left: auto;
}

.nav-project-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease;
}

.nav-project-link:hover {
  transform: translateY(-3px);
}

.nav-project-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.4rem;
}

.nav-project-title {
  font-size: 1.35rem;
  font-variation-settings: "wght" 600;
}

/* ==========================================================================
   PROJECT LIGHTBOX (HOMEPAGE 3D CIRCLE)
   ========================================================================== */
.lightbox-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(16, 16, 16, 0.95);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-content {
  position: relative;
  width: 90%;
  max-width: 1200px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: scale(0.95);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox-overlay.active .lightbox-content {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: -20px;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 8px;
  opacity: 0.7;
  transition: opacity 0.2s, transform 0.2s;
}

@media (max-width: 768px) {
  .lightbox-close {
    top: -40px;
    right: 0;
  }
}

.lightbox-close:hover {
  opacity: 1;
  transform: rotate(90deg);
}

.lightbox-image-container {
  width: 100%;
  max-height: 70vh;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
}

#lightbox-img {
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: contain;
  display: block;
}

.lightbox-info {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  text-align: center;
}

#lightbox-title {
  font-family: 'Gallient', serif;
  font-size: 2.5rem;
  margin: 0;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-muted) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ==========================================================================
   AMBIENT BACKGROUND ANIMATIONS (Replicating about-me.html)
   ========================================================================== */
.background--dark {
  position: relative;
  overflow-x: hidden;
  background-color: #101010;
}

.ambient-glow-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.ambient-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.45;
  animation: floatAmbient 20s infinite ease-in-out alternate;
}

.ambient-glow--teal {
  width: 80vw;
  height: 80vw;
  max-width: 1000px;
  max-height: 1000px;
  top: -20vh;
  left: -20vw;
  background: radial-gradient(circle at center, rgba(14, 188, 190, 0.25) 0%, rgba(61, 0, 255, 0.15) 50%, transparent 80%);
  animation-delay: 0s;
  animation-duration: 25s;
}

.ambient-glow--purple {
  width: 70vw;
  height: 70vw;
  max-width: 900px;
  max-height: 900px;
  bottom: -30vh;
  right: -10vw;
  background: radial-gradient(circle at center, rgba(141, 81, 231, 0.25) 0%, rgba(0, 164, 255, 0.15) 50%, transparent 80%);
  animation-delay: -5s;
  animation-duration: 22s;
}

.ambient-glow--pink {
  width: 60vw;
  height: 60vw;
  max-width: 800px;
  max-height: 800px;
  top: 30vh;
  right: 10vw;
  background: radial-gradient(circle at center, rgba(241, 50, 194, 0.15) 0%, rgba(172, 68, 0, 0.08) 60%, transparent 80%);
  animation-delay: -10s;
  animation-duration: 28s;
}

@keyframes floatAmbient {
  0% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(3vw, 5vh) scale(1.05); }
  66% { transform: translate(-2vw, 8vh) scale(0.95); }
  100% { transform: translate(0, 0) scale(1); }
}

/* Ensure content stays above the ambient glows */
.page-container > * {
  position: relative;
  z-index: 10;
}

.header {
  position: absolute;
  z-index: 100;
}

.admin-content, .admin-sidebar, .auth-container {
  position: relative;
  z-index: 10;
}
/* ==========================================================================
   UI REVAMP (ABOUT, CONTACT, ALL WORK)
   ========================================================================== */

/* Typography & Layout Refinements */
.gallient {
  font-family: 'Gallient', serif !important;
  font-weight: 400;
}

.page-title__text {
  letter-spacing: -0.04em;
}

/* All Work Premium Refinements */



.projects-hero__lead {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 800px;
  margin: 0 auto 4rem;
  font-family: 'Inter-Variable', sans-serif;
}

.filter-bar {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 5rem;
  padding: 0.4rem;
  border: 1px solid rgba(245, 242, 235, 0.12);
  border-radius: 999px;
  background: rgba(245, 242, 235, 0.03);
  backdrop-filter: blur(10px);
}

.filter-btn {
  background: transparent;
  border: 1px solid transparent;
  color: rgba(245, 242, 235, 0.55);
  padding: 0.7rem 1.5rem;
  border-radius: 999px;
  font-family: 'Inter-Variable', sans-serif;
  font-size: 0.9rem;
  font-variation-settings: "wght" 500;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.filter-btn:hover {
  color: var(--color, #F5F2EB);
  background: rgba(245, 242, 235, 0.06);
}

.filter-btn.active {
  background: rgba(245, 242, 235, 0.12);
  color: var(--color, #F5F2EB);
  border-color: rgba(245, 242, 235, 0.25);
}

/* ==========================================================================
   EDITORIAL LUXURY PROJECTS ARCHIVE
   ========================================================================== */
.editorial-projects-section {
  position: relative;
  z-index: 2;
  padding: 0 3.3333333333vw 8rem;
}

.editorial-projects-container {
  width: 100%;
  max-width: 1560px;
  margin: 0 auto;
}

.editorial-projects-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.project-list-row {
  position: relative;
  opacity: 0;
  transform: translateY(45px);
  transition: opacity 0.85s cubic-bezier(0.16, 1, 0.3, 1), transform 0.85s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.3s ease, filter 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
}

.project-list-row::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background-color: rgba(245, 242, 235, 0.14);
  clip-path: inset(0 100% 0 0);
  transition: clip-path 1.1s cubic-bezier(0.17, 0.67, 0, 1), background-color 0.3s ease, filter 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-list-row.is-inview {
  opacity: 1;
  transform: translateY(0);
}

.project-list-row.is-inview::before {
  clip-path: inset(0);
}

.project-list-row:last-child {
  border-bottom: 1px solid rgba(245, 242, 235, 0.12);
}

.project-list-row:hover {
  background-color: rgba(245, 242, 235, 0.04);
}

.project-list-row:hover::before {
  background-color: rgba(245, 242, 235, 0.45);
}

.project-list-row__inner {
  display: grid;
  grid-template-columns: 80px 1.4fr 1.8fr auto;
  align-items: center;
  gap: 2.5rem;
  padding: 3rem 2.5vw;
  text-decoration: none;
  color: inherit;
  position: relative;
}

.project-list-row__hitbox {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
}

.project-list-row__col-idx {
  font-family: 'Inter-Variable', monospace, sans-serif;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  color: rgba(245, 242, 235, 0.35);
  font-variation-settings: "wght" 500;
}

.project-list-row__col-main {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.project-list-row__title {
  font-family: 'Gallient', serif !important;
  font-size: clamp(2rem, 3.2vw, 3.4rem) !important;
  font-weight: 400 !important;
  letter-spacing: -0.02em !important;
  line-height: 1.15 !important;
  margin: 0 !important;
  color: var(--color, #F5F2EB) !important;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), color 0.3s ease;
}

.project-list-row:hover .project-list-row__title {
  transform: translateX(12px);
  color: #ffffff !important;
  text-shadow: 0 4px 24px rgba(255,255,255,0.25);
}

.project-list-row__category {
  font-family: 'Inter-Variable', sans-serif;
  font-size: 0.76rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(245, 242, 235, 0.52);
  font-variation-settings: "wght" 500;
}

.project-list-row__col-desc {
  max-width: 650px;
}

.project-list-row__synopsis {
  font-family: 'Inter-Variable', sans-serif;
  font-size: 1.05rem;
  line-height: 1.65;
  color: rgba(245, 242, 235, 0.65);
  margin: 0;
}

.project-list-row__col-action {
  text-align: right;
  white-space: nowrap;
}

.project-list-row__link {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-family: 'Inter-Variable', sans-serif;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color, #F5F2EB);
  font-variation-settings: "wght" 600;
  text-decoration: none;
  position: relative;
  transition: color 0.3s ease;
}

.project-list-row__arrow {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  margin-bottom: 3px;
}

.project-list-row:hover .project-list-row__arrow {
  transform: translate(6px, -2px);
}

.project-list-row__mobile-thumb {
  display: none;
}

/* Floating interactive cursor hover image */
.project-hover-preview {
  display: none !important;
  position: fixed;
  top: 0;
  left: 0;
  width: 380px;
  height: 250px;
  border-radius: 18px;
  overflow: hidden;
  pointer-events: none;
  z-index: 999;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.95) rotate(-2deg);
  transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1), transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.85);
  border: 1px solid rgba(245, 242, 235, 0.14);
  background: #101010;
}

.project-hover-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.project-hover-preview.is-active {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.05) rotate(0deg);
}

/* Mobile & Tablet responsiveness */
@media (max-width: 1024px) {
  .project-list-row__inner {
    grid-template-columns: 1fr;
    gap: 1.25rem;
    padding: 2.5rem 5vw;
  }
  .project-list-row:hover .project-list-row__title {
    transform: none;
  }
  .project-list-row__col-action {
    text-align: left;
    margin-top: 0.5rem;
  }
  .project-hover-preview {
    display: none !important;
  }
  .project-list-row__mobile-thumb {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 14px;
    overflow: hidden;
    margin: 0.75rem 0 1rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
  }
  .project-list-row__mobile-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
  }
}

/* Fix header overlap */

/* Fix footer background for pages where it sits outside main */
.footer {
  background: var(--background, #101010);
  color: var(--color, #F5F2EB);
}

/* Force project hero below header */



/* Override case-grid__link default opacity from 9mrr5.css */
.projects-grid .case-grid__link {
  opacity: 1 !important;
  pointer-events: auto !important;
}



/* Restored & refined base classes for layout */
.page-container {
  padding-top: 0 !important; /* Let specific page heroes handle their own padding */
}

.projects-hero {
  padding: 100px 5vw 4rem; /* Tightened from 16vw */
  max-width: 1600px;
  margin: 0 auto;
  text-align: center;
}

.editorial-projects-list:hover .project-list-row:not(:hover) {
  opacity: 0.3 !important;
  transform: translateY(0) scale(0.98) !important;
  filter: grayscale(100%) blur(2px);
}

/* ==========================================================================
   DEFINITIVE MOBILE RESPONSIVENESS FIXES
   ========================================================================== */
@media only screen and (max-width: 768px) {
  /* Prevent horizontal overflow completely */
  html, body {
    overflow-x: hidden !important;
    width: 100vw !important;
    max-width: 100vw !important;
  }
  
  .page-wrapper, main {
    overflow-x: hidden !important;
    width: 100vw !important;
  }

  /* Scale down massive headings so they don't break the viewport */
  body:not(.home) .xlarge-heading {
    font-size: clamp(3rem, 16vw, 5rem) !important;
    word-break: break-word;
    hyphens: auto;
  }
  
  body:not(.home) .large-heading {
    font-size: clamp(2.5rem, 12vw, 4rem) !important;
  }
  
  /* Fix Projects Grid and Hero on Mobile */
  .gallery-item {
    flex: 0 0 100% !important;
  }
  .project-header-hero {
    padding-top: 120px !important;
    padding-left: 6vw !important;
    padding-right: 6vw !important;
  }
  
  .project-details-grid {
    padding-left: 6vw !important;
    padding-right: 6vw !important;
    flex-direction: column !important;
    display: flex !important;
  }
  .page-title {
    padding-left: 6vw !important;
    padding-right: 6vw !important;
  }
  .filter-bar {
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    border-radius: 1.5rem !important;
    padding: 1rem 0.5rem !important;
    justify-content: center;
  }
  .projects-grid {
    padding: 2rem 6vw !important;
    gap: 1.5rem !important;
    grid-template-columns: 1fr !important;
  }

  /* Fix Project Row mobile */
  .project-list-row {
    padding: 1.5rem 0 !important;
  }
  
  .project-list-row__inner {
    grid-template-columns: 1fr !important;
    padding: 1.5rem 6vw !important;
  }
  
  /* Fix About Page text blocks bleeding out */
  .about-content, .contact-content {
    padding: 0 6vw !important;
  }
}

/* Fix short pages having a white background at the bottom */
html, body {
  background-color: #101010 !important;
  min-height: 100vh;
}
