/* ============================================
   AA / STUDIO — Sterile Light Design System
   Japanese Pharmacy / Apple Store Aesthetic
   ============================================ */

/* Fonts loaded via <link> in head.php — no @import needed */

:root {
  --white: #FFFFFF;
  --snow: #FAFAFA;
  --frost: #F5F5F7;
  --mist: #E8E8ED;
  --silver: #D2D2D7;
  --graphite: #86868B;
  --ink: #1D1D1F;
  --deep: #0A0A0A;
  --accent: #1D1D1F;
  --accent-warm: #C7A17A;
  --glass-bg: rgba(255, 255, 255, 0.72);
  --glass-border: rgba(0, 0, 0, 0.06);
  --card-shadow: 0 2px 20px rgba(0, 0, 0, 0.04), 0 0 0 1px rgba(0, 0, 0, 0.03);
  --card-shadow-hover: 0 8px 40px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(0, 0, 0, 0.05);
  --diffusion-shadow: 0 20px 60px -15px rgba(0, 0, 0, 0.06);
}

.font-script {
  font-family: 'JetBrains Mono', monospace !important;
  font-style: normal;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase !important;
  color: var(--accent-warm);
}

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

html {
  font-size: 18.4px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--white);
  color: var(--ink);
  overflow-x: hidden;
  line-height: 1.6;
  background-image:
    linear-gradient(rgba(0,0,0,0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.018) 1px, transparent 1px);
  background-size: 120px 120px;
}

::selection {
  background: var(--ink);
  color: var(--white);
}

/* ---- Typography ---- */
.font-display {
  font-family: 'JetBrains Mono', monospace;
}

.font-mono {
  font-family: 'JetBrains Mono', monospace;
}

.font-outfit {
  font-family: 'Outfit', sans-serif;
}

/* ---- Reveal Animation Classes ---- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
}

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

.reveal-word {
  opacity: 0;
  transform: translateY(16px);
  display: inline-block;
}

.reveal-word.revealed {
  opacity: 1;
  transform: translateY(0);
}

.reveal-card {
  opacity: 0;
  transform: translateY(40px) scale(0.98);
}

.reveal-card.revealed {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* ---- Magnetic Button ---- */
.magnetic-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  background: var(--ink);
  color: var(--white);
  font-family: 'Outfit', sans-serif;
  font-weight: 500;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  border: none;
  border-radius: 2rem;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              box-shadow 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94),
              background 0.3s ease;
}

.magnetic-btn:hover {
  transform: scale(1.03);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
  background: var(--deep);
}

.magnetic-btn:active {
  transform: scale(0.98);
}

.magnetic-btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--mist);
}

.magnetic-btn-outline:hover {
  border-color: var(--ink);
  color: var(--ink);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
  background: transparent;
}

/* ---- Magnetic Link ---- */
.magnetic-link {
  text-decoration: none;
  color: var(--ink);
  transition: color 0.3s ease, transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  position: relative;
}

.magnetic-link:hover {
  color: var(--graphite);
  transform: translateY(-1px);
}

.magnetic-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--ink);
  transition: width 0.3s ease;
}

.magnetic-link:hover::after {
  width: 100%;
}

/* ---- Floating Navbar (arch-duo.com style) ---- */
.navbar {
  position: fixed;
  top: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0.625rem 1rem;
  border-radius: 2px;
  background: transparent;
  border: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease, box-shadow 0.3s ease;
  max-width: 64rem;
  width: calc(100% - 2rem);
}

.navbar.scrolled {
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-color: rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.04);
}

.navbar-logo {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  color: var(--white);
  text-decoration: none;
  white-space: nowrap;
  padding-right: 0.5rem;
  text-shadow: 1px 1px 0 transparent;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.navbar-logo span {
  color: rgba(255, 255, 255, 0.7);
  font-weight: 400;
  transition: color 0.3s ease;
}

.navbar.scrolled .navbar-logo {
  color: var(--ink);
  text-shadow: 1px 1px 0 #FFFFFF;
}

.navbar.scrolled .navbar-logo span {
  color: var(--graphite);
}

.navbar-links {
  display: flex;
  align-items: center;
  gap: 0;
  list-style: none;
  margin-left: auto;
}

.navbar-links a {
  display: block;
  padding: 0.1875rem 0.5rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--white);
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), background 0.3s ease;
  white-space: nowrap;
  position: relative;
  background: rgba(0, 0, 0, 0.12);
  border-radius: 2px;
  line-height: 1.3;
}

.navbar.scrolled .navbar-links a {
  background: rgba(0, 0, 0, 0.04);
  color: var(--ink);
}

.navbar-links a::after {
  content: '';
  position: absolute;
  bottom: 0px;
  left: 0.5rem;
  right: 0.5rem;
  height: 1.5px;
  background: var(--white);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease, background 0.3s ease;
}

.navbar.scrolled .navbar-links a::after {
  background: var(--ink);
}

#preloader {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 1s cubic-bezier(0.65, 0, 0.35, 1), 
              visibility 1s cubic-bezier(0.65, 0, 0.35, 1);
}

#preloader.is-light {
    background-color: var(--white);
}

#preloader.is-dark {
    background-color: #000;
}

#preloader.loaded {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-content {
  text-align: center;
}

.preloader-logo {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: -0.04em;
  color: var(--ink);
  text-transform: uppercase;
  margin-bottom: 2.5rem;
}

.preloader-logo span {
  color: var(--graphite);
  font-weight: 400;
}

.preloader-tracker {
  width: 200px;
  height: 1.5px;
  background: var(--mist);
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.preloader-bar {
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background: var(--ink);
}

/* Global Content Fade-In */
body.is-loading #hero-stage,
body.is-loading .philosophy,
body.is-loading .section,
body.is-loading .cta-section,
body.is-loading section,
body.is-loading footer,
body.is-loading header,
body.is-loading main {
  opacity: 0;
}

section, footer, header, main, .philosophy, .section, #hero-stage, .cta-section {
  transition: opacity 1.5s cubic-bezier(0.22, 1, 0.36, 1);
  opacity: 1;
}

.navbar-links a:hover,
.navbar-links a.forced-hover,
.navbar-links a.active {
  color: var(--white);
  transform: translateY(-1px);
}

.navbar.scrolled .navbar-links a:hover,
.navbar.scrolled .navbar-links a.forced-hover,
.navbar.scrolled .navbar-links a.active {
  color: var(--ink);
}

.navbar-links a:hover::after,
.navbar-links a.active::after {
  transform: scaleX(1) !important;
  animation: none !important;
}

/* Slide Highlight Flash (only for non-active links) */
.navbar-links a.forced-flash:not(.active)::after {
  animation: flashUnderline 1.2s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes flashUnderline {
  0% { transform: scaleX(0); transform-origin: left; }
  50% { transform: scaleX(1); transform-origin: left; }
  51% { transform: scaleX(1); transform-origin: right; }
  100% { transform: scaleX(0); transform-origin: right; }
}

.navbar-divider {
  width: 1px;
  height: 1.25rem;
  background: rgba(255, 255, 255, 0.2);
  margin: 0 0.75rem;
  flex-shrink: 0;
  transition: background 0.3s ease;
}

.navbar.scrolled .navbar-divider {
  background: rgba(0, 0, 0, 0.1);
}

.navbar-login-btn {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.5rem 0.75rem;
  background: transparent;
  color: var(--white);
  transition: color 0.3s ease, opacity 0.3s ease;
  white-space: nowrap;
  flex-shrink: 0;
  opacity: 0.7;
}

.navbar.scrolled .navbar-login-btn {
  color: var(--ink);
  opacity: 1;
}

.navbar.scrolled .navbar-login-btn:hover {
  opacity: 0.7;
}

.navbar-cta {
  padding: 0.5rem 1.25rem;
  font-size: 0.75rem;
  border-radius: 2rem;
}

.navbar-mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  margin-left: 0.5rem;
}

.navbar-mobile-toggle span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--white);
  transition: transform 0.3s ease, opacity 0.3s ease, background 0.3s ease;
  border-radius: 2px;
}

.navbar.scrolled .navbar-mobile-toggle span {
  background: var(--ink);
}

.navbar-mobile-toggle.open span:nth-child(1) {
  transform: rotate(45deg) translate(4px, 5px);
}

.navbar-mobile-toggle.open span:nth-child(2) {
  opacity: 0;
}

.navbar-mobile-toggle.open span:nth-child(3) {
  transform: rotate(-45deg) translate(4px, -5px);
}

/* ---- Mobile Menu ---- */
.mobile-menu {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100dvh;
  background: var(--white);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.mobile-menu.open {
  display: flex;
  opacity: 1;
  pointer-events: all;
}

.mobile-menu a {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  padding: 0.5rem;
  transition: color 0.3s ease;
  letter-spacing: -0.04em;
  text-transform: uppercase;
}

.mobile-menu a:hover {
  color: var(--graphite);
}

@media (max-width: 900px) {
  .navbar-links {
    display: none;
  }
  .navbar-cta-desktop {
    display: none;
  }
  .navbar-divider {
    display: none;
  }
  .navbar-login-btn {
    display: none;
  }
  .navbar-mobile-toggle {
    display: flex;
  }
}

/* ---- Hero Section ---- */
.hero {
  position: relative;
  width: 100%;
  height: 100dvh;
  overflow: hidden;
  background: var(--frost);
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 10%;
  width: 1px;
  height: 30%;
  background: linear-gradient(to top, var(--mist), transparent);
  z-index: 2;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(245, 245, 247, 0.95) 0%,
    rgba(245, 245, 247, 0.7) 45%,
    rgba(245, 245, 247, 0.2) 80%,
    transparent 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 6rem 4rem;
  max-width: 720px;
}

.hero-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--graphite);
  margin-bottom: 1.5rem;
}

.hero-title-line {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: clamp(2.75rem, 5.5vw, 4.5rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: var(--ink);
}

.hero-title-line .serif-accent {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-weight: 300;
  color: var(--graphite);
}

.hero-subtitle {
  margin-top: 1.75rem;
  font-size: 1.0625rem;
  font-weight: 300;
  color: var(--graphite);
  max-width: 480px;
  line-height: 1.7;
}

.hero-cta-group {
  margin-top: 2.5rem;
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 2rem;
  right: 4rem;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.hero-scroll-indicator span {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.5625rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--silver);
  writing-mode: vertical-rl;
}

.scroll-line {
  width: 1px;
  height: 48px;
  background: var(--mist);
  position: relative;
  overflow: hidden;
}

.scroll-line::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--ink);
  animation: scrollLineAnim 2.5s ease-in-out infinite;
}

@keyframes scrollLineAnim {
  0% { top: -100%; }
  50% { top: 100%; }
  100% { top: 100%; }
}

@media (max-width: 768px) {
  .hero-content {
    padding: 6rem 1.5rem 4rem;
  }
  .hero-overlay {
    background: linear-gradient(
      to top,
      rgba(245, 245, 247, 0.97) 0%,
      rgba(245, 245, 247, 0.6) 50%,
      rgba(245, 245, 247, 0.3) 100%
    );
  }
  .hero-content {
    justify-content: flex-end;
  }
  .hero-scroll-indicator {
    right: 1.5rem;
  }
}

/* ---- Sections ---- */
.section {
  padding: 7rem 4rem;
  position: relative;
}

.section-frost {
  background: var(--frost);
  position: relative;
}

.section-light {
  background: var(--white);
}



.section-projects-bg {
  background-image: 
    linear-gradient(rgba(10, 10, 12, 0.5), rgba(10, 10, 12, 0.5)),
    url('newsite/footerbg.webp');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  position: relative;
  z-index: 1;
}

@media (max-width: 768px) {
  .section-projects-bg {
    background-attachment: scroll;
  }
}

.section-projects-bg .section-heading .italic {
  color: var(--white) !important;
}

.section-projects-bg::before,
.section-projects-bg::after {
  display: none !important;
}

.section-snow {
  background: var(--snow);
}

.section-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--graphite);
  margin-bottom: 1rem;
}

.section-heading {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  line-height: 1.15;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: var(--ink);
}

.section-heading .italic {
  font-family: 'JetBrains Mono', monospace;
  font-style: normal;
  font-weight: 400;
  color: var(--graphite);
}

/* Feature Work Inverse Selection Effect */
.inverse-section-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 3rem;
  gap: 0; /* Keep them vertically snapped together like text selection */
}

.inverse-section-header .inverse-label {
  background-color: var(--ink);
  color: var(--white);
  padding: 0.15rem 0.5rem;
  margin-bottom: 0;
  display: inline-block;
  line-height: 1.2;
}

.inverse-section-header .inverse-heading {
  background-color: var(--ink);
  color: var(--white);
  padding: 0.2rem 0.5rem;
  margin-bottom: 0 !important;
  display: inline-block;
  line-height: 1.15;
}

@media (max-width: 768px) {
  .section {
    padding: 4rem 1.5rem;
  }
}

/* ---- Philosophy Section ---- */
.philosophy {
  background: var(--white);
  padding: 8rem 4rem;
  overflow: hidden;
  position: relative;
}

.philosophy-inner {
  max-width: 900px;
  margin: 0 auto;
}

.philosophy-line {
  font-size: clamp(1.0625rem, 2vw, 1.375rem);
  font-weight: 300;
  color: var(--graphite);
  line-height: 1.7;
  margin-bottom: 2.5rem;
  max-width: 65ch;
}

.philosophy-accent {
  font-family: 'JetBrains Mono', monospace;
  font-style: normal;
  font-size: clamp(2rem, 4.5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.25;
  color: var(--ink);
  letter-spacing: -0.04em;
  text-transform: uppercase;
}

.philosophy-accent .highlight {
  font-weight: 600;
  font-style: normal;
}

@media (max-width: 768px) {
  .philosophy {
    padding: 5rem 1.5rem;
  }
}

/* ---- Projects Grid Carousel ---- */
.projects-grid {
  width: 100%;
  overflow: hidden;
  padding: 2rem 0 5rem 0;
  margin: 15px 0 0 0;
}

.projects-track {
  display: flex;
  gap: 3rem;
  width: max-content;
  will-change: transform;
}

/* Desktop Auto-Scroll Loop (Handled by GSAP) */
@media (min-width: 901px) {
}

.project-card {
  position: relative;
  flex: 0 0 320px;
  cursor: pointer;
  background: var(--white);
  padding: 0.5rem 0.5rem 0.8rem 0.5rem;
  box-shadow: 0 8px 30px -10px rgba(0,0,0,0.06);
  transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1), 
              box-shadow 0.6s cubic-bezier(0.23, 1, 0.32, 1);
  border-radius: 1px;
  user-select: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.project-card:nth-child(even) { transform: rotate(1deg); }
.project-card:nth-child(odd) { transform: rotate(-1.2deg); }

.project-card:hover {
  transform: translateY(-8px) rotate(0deg) scale(1.02);
  box-shadow: 0 30px 60px -15px rgba(0,0,0,0.1);
  z-index: 10;
}

@media (max-width: 900px) {
  .projects-grid {
    margin: 0;
    padding: 0;
    overflow: visible;
  }
  .projects-track {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 3.5rem;
    padding: 0 1.5rem;
    animation: none !important;
  }
  .project-card {
    flex: 0 0 auto;
    width: 100%;
    transform: none !important;
  }
}

.project-card-img-wrap {
  width: 100%;
  aspect-ratio: 1/1 !important;
  overflow: hidden;
  margin-bottom: 0;
  background: var(--frost);
  position: relative;
}

.project-card img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 1.2s cubic-bezier(0.23, 1, 0.32, 1);
}

.project-card:hover img {
  transform: scale(1.04);
}

.project-card-info {
  display: flex;
  flex-direction: column;
  background: var(--white);
  padding: 0 0.5rem;
}

.project-card-title {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 0.125rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.project-card-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--graphite);
  opacity: 0.6;
}

@media (max-width: 768px) {
  .projects-grid {
    grid-template-columns: 1fr;
  }
}

/* ---- Services Grid ---- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--mist);
  border-radius: 0.375rem;
  overflow: hidden;
  box-shadow: var(--card-shadow);
}

.service-card {
  background: var(--white);
  padding: 2.5rem 2rem;
  transition: background 0.4s ease;
}

.service-card:hover {
  background: var(--snow);
}

.service-card-number {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  color: var(--silver);
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
}

.service-card-title {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--ink);
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.service-card-desc {
  font-size: 0.8125rem;
  font-weight: 300;
  color: var(--graphite);
  line-height: 1.7;
}

@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .services-grid {
    grid-template-columns: 1fr;
  }
}

/* ---- Team Section ---- */
.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.team-card {
  background: var(--white);
  border-radius: 0.375rem;
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: box-shadow 0.5s ease, transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.team-card:hover {
  box-shadow: var(--card-shadow-hover);
  transform: translateY(-3px);
}

.team-card-image {
  width: 100%;
  aspect-ratio: 5/6;
  overflow: hidden;
  background: var(--frost);
}

.team-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(20%) brightness(1.02);
  transition: filter 0.5s ease, transform 0.6s ease;
}

.team-card:hover .team-card-image img {
  filter: grayscale(0%) brightness(1);
  transform: scale(1.03);
}

.team-card-info {
  padding: 1.5rem;
}

.team-card-name {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 1.125rem;
  color: var(--ink);
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

.team-card-role {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6875rem;
  color: var(--graphite);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: 0.375rem;
}

.team-card-bio {
  font-size: 0.9375rem;
  font-weight: 300;
  color: var(--graphite);
  line-height: 1.7;
  margin-top: 0.75rem;
}

@media (max-width: 900px) {
  .team-grid {
    grid-template-columns: 1fr;
    max-width: 400px;
    margin: 0 auto;
  }
}

/* ---- Contact Form ---- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  max-width: 1100px;
  margin: 0 auto;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--graphite);
}

.form-group input,
.form-group textarea {
  background: var(--frost);
  border: 1px solid var(--mist);
  border-radius: 0.375rem;
  padding: 1rem 1.25rem;
  font-family: 'Outfit', sans-serif;
  font-size: 0.9375rem;
  color: var(--ink);
  outline: none;
  transition: border-color 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--ink);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(29, 29, 31, 0.06);
}

.form-group textarea {
  resize: vertical;
  min-height: 140px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--silver);
}

.contact-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2.5rem;
}

.contact-info-item {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.contact-info-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--graphite);
}

.contact-info-value {
  font-size: 1.0625rem;
  font-weight: 400;
  color: var(--ink);
}

.contact-info-value a {
  color: var(--ink);
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact-info-value a:hover {
  color: var(--graphite);
}

@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

/* ---- Footer ---- */
.footer {
  background-image: 
    linear-gradient(rgba(10, 10, 12, 0.3), rgba(10, 10, 12, 0.3)),
    url('newsite/footerbg.webp');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  border-radius: 0;
  padding: 5rem 4rem 2.5rem;
  margin-top: 4rem;
}

@media (max-width: 768px) {
  .footer {
    background-attachment: scroll;
  }
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

.footer-brand {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 1rem;
  color: var(--white);
  letter-spacing: -0.02em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.footer-brand span {
  color: rgba(255, 255, 255, 0.4);
  font-weight: 400;
}

.footer-tagline {
  font-size: 0.8125rem;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.4);
  max-width: 280px;
  line-height: 1.7;
}

.footer-col-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.5625rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.3);
  margin-bottom: 1.25rem;
}

.footer-col-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-col-links a {
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.5);
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s ease;
  display: inline-block;
}

.footer-col-links a:hover {
  color: var(--white);
  transform: translateY(-1px);
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-copyright {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.25);
}

.footer-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 0.05em;
}

.footer-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #34C759;
  animation: pulse 2.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(52, 199, 89, 0.3); }
  50% { opacity: 0.6; box-shadow: 0 0 0 6px rgba(52, 199, 89, 0); }
}

@media (max-width: 768px) {
  .footer {
    padding: 3rem 1.5rem 2rem;
    border-radius: 0;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  .footer-bottom {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }
}

/* ---- Divider ---- */
.divider {
  display: none;
}

/* ---- Page Header (for inner pages) ---- */
.page-header {
  padding-top: 8rem;
  padding-bottom: 3rem;
  text-align: center;
  background: var(--white);
  position: relative;
}

.page-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  width: 1px;
  height: 100%;
  background: var(--mist);
  opacity: 0.4;
}

.page-header .section-label {
  margin-bottom: 1rem;
}

.page-header h1 {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: var(--ink);
  line-height: 1.1;
}

.page-header h1 .italic {
  font-family: 'JetBrains Mono', monospace;
  font-style: normal;
  font-weight: 400;
  color: var(--graphite);
}

.page-header p {
  max-width: 520px;
  margin: 1.25rem auto 0;
  font-size: 0.9375rem;
  font-weight: 300;
  color: var(--graphite);
  line-height: 1.7;
}

/* ---- Texture Overlay ---- */
.noise-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.015;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px;
}

/* ---- CTA Section ---- */
.cta-section {
  text-align: center;
  padding: 7rem 2rem;
  position: relative;
}

.cta-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  width: 1px;
  height: 60px;
  background: var(--mist);
}

.cta-section h2 {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  letter-spacing: -0.04em;
  text-transform: uppercase;
  color: var(--ink);
  margin-bottom: 1rem;
}

.cta-section h2 .italic {
  font-family: 'JetBrains Mono', monospace;
  font-style: normal;
  font-weight: 400;
  color: var(--graphite);
}

.cta-section p {
  font-size: 0.9375rem;
  font-weight: 300;
  color: var(--graphite);
  margin-bottom: 2rem;
}

/* ---- Stat Row ---- */
.stat-row {
  display: flex;
  gap: 3rem;
  margin-top: 3rem;
}

.stat-item {
  display: flex;
  flex-direction: column;
}

.stat-number {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.75rem;
  font-weight: 500;
  color: var(--ink);
  letter-spacing: -0.02em;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--graphite);
  margin-top: 0.25rem;
}

@media (max-width: 768px) {
  .stat-row {
    gap: 2rem;
    flex-wrap: wrap;
  }
}

/* ---- Horeca Project Full Width Cards ---- */
.horeca-project {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
  margin-bottom: 4rem;
  padding-bottom: 4rem;
  border-bottom: 1px solid var(--mist);
}

.horeca-project:nth-child(even) {
  direction: rtl;
}

.horeca-project:nth-child(even) > * {
  direction: ltr;
}

.horeca-project-image {
  border-radius: 0.375rem;
  overflow: hidden;
  aspect-ratio: 16/10;
  box-shadow: var(--card-shadow);
}

.horeca-project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.horeca-project:hover .horeca-project-image img {
  transform: scale(1.03);
}

.horeca-project-info {
  padding: 1rem;
}

.horeca-project-number {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.625rem;
  color: var(--silver);
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

.horeca-project-name {
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--ink);
  letter-spacing: -0.04em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.horeca-project-size {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: var(--graphite);
  margin-bottom: 1rem;
}

.horeca-project-desc {
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--graphite);
  line-height: 1.7;
}

@media (max-width: 768px) {
  .horeca-project {
    grid-template-columns: 1fr;
  }
  .horeca-project:nth-child(even) {
    direction: ltr;
  }
}

/* ============================================
   SVG Mask Scroll Transition
   ============================================ */
.stage {
  height: 100vh;
  position: relative;
}

.layers {
  position: sticky;
  top: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background: var(--ink);
}

.layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.layer image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: none;
}

/* scroll-txt visibility handled by JS — first child starts hidden */
.scroll-txt:first-child {
  opacity: 0;
}

.scroll-txt span {
  display: block;
  font-family: 'Outfit', sans-serif;
  font-size: clamp(0.9rem, 1.1vw, 1.2rem);
  font-weight: 300;
  margin-bottom: 1rem;
  line-height: normal;
  color: rgba(255, 255, 255, 0.85);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  white-space: nowrap;
}

.scroll-txt h2 {
  display: block;
  margin-top: 1rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: clamp(1.2rem, 1.6vw, 2rem);
  letter-spacing: 0.15em;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.9);
  text-transform: uppercase;
  white-space: nowrap;
}

.scroll-txt h1 {
  font-family: 'JetBrains Mono', monospace;
  font-style: normal;
  font-size: clamp(3rem, 7vw, 8.5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 0.9;
  text-transform: uppercase;
  color: var(--white);
  text-shadow: none;
  margin-top: 0.75rem;
  margin-bottom: 0;
}
.progress-bar {
  position: absolute;
  bottom: 0;
  width: 100%;
  padding: 3.5rem 3vw 1.2rem 3vw;
  display: flex;
  gap: 0.5rem;
  z-index: 20;
}

.progress-bar .segment {
  flex: 1;
  height: 3px;
  background: rgba(255, 255, 255, 0.15);
  position: relative;
  cursor: pointer;
  transition: height 0.2s ease, background 0.2s ease;
}

.progress-bar .segment::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: -5px;
  bottom: -5px;
  z-index: 1;
}

.progress-bar .segment:hover {
  height: 6px;
  background: rgba(255, 255, 255, 0.3);
}

.progress-bar .fill {
  position: absolute;
  top: 0;
  left: 0;
  width: 0%;
  height: 100%;
  background: var(--white);
  pointer-events: none;
}

@media screen and (max-width: 900px) {
  .scroll-txt span,
  .scroll-txt h2 {
    white-space: normal;
  }
}

/* Osnova slajdera */
#hero-stage { position: relative; width: 100%; height: 100vh; overflow: hidden; background: #000; }
.layers { width: 100%; height: 100%; position: relative; }
.hero-slide { position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden; }
.hero-img { width: 100%; height: 100%; object-fit: cover; transform-origin: center center; will-change: transform; }

/* Klase za privremenu Grid Mrežu (koja se kreira iz JS-a) */
.transition-grid { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 10; pointer-events: none; }
.t-cell { position: absolute; overflow: hidden; opacity: 0; will-change: opacity; }
.t-img-wrapper { position: absolute; width: 100vw; height: 100vh; transform-origin: center center; will-change: transform; }
.t-img { width: 100%; height: 100%; object-fit: cover; }

/* Osiguraj da tekst na Hero slajderu bude iznad slika */
.scroll-texts {
  position: absolute;
  bottom: 2.2rem;
  left: 3vw;
  width: calc(100% - 6vw);
  z-index: 25;
  pointer-events: none;
  text-align: left;
}

.scroll-txt {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
}

@media screen and (max-width: 900px) {
  .scroll-texts {
    left: 2rem;
    bottom: 3rem;
    width: calc(100% - 4rem);
  }
}
