/* ============================================
   MOLLER & MIELE — Design System
   Apple-inspired, minimal, professional
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --color-black: #1d1d1f;
  --color-dark: #2c2c2e;
  --color-gray: #86868b;
  --color-light-gray: #d2d2d7;
  --color-off-white: #f5f5f7;
  --color-white: #ffffff;
  --color-accent: #6e6e73;
  --color-warm: #b8860b;

  --font-display: 'Quattrocento Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  --font-text: 'Quattrocento Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;

  --max-width: 1200px;
  --max-width-narrow: 900px;
  --section-padding: 120px;
  --header-height: 72px;

  --ease-out: cubic-bezier(0.25, 0.46, 0.45, 0.94);
  --ease-in-out: cubic-bezier(0.645, 0.045, 0.355, 1);
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body {
  font-family: var(--font-text);
  color: var(--color-black);
  background: var(--color-white);
  line-height: 1.5;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
  transition: opacity 0.3s var(--ease-out);
}

a:hover {
  opacity: 0.7;
}

/* --- Typography --- */
.headline-hero {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 5rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--color-white);
}

.headline-section {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.headline-card {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.subhead {
  font-family: var(--font-display);
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 400;
  line-height: 1.4;
  color: var(--color-gray);
  letter-spacing: -0.01em;
}

.body-large {
  font-size: 1.25rem;
  line-height: 1.6;
  color: var(--color-dark);
  letter-spacing: -0.005em;
}

.body-text {
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--color-dark);
}

.label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-gray);
}

/* --- Layout --- */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.container-narrow {
  max-width: var(--max-width-narrow);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: var(--section-padding) 0;
  overflow: hidden;
}

.section-dark {
  background: var(--color-black);
  color: var(--color-white);
}

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

/* --- Header / Navigation --- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--header-height);
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  transition: background 0.4s var(--ease-out), border-color 0.4s var(--ease-out);
}

.site-header.header-dark {
  background: rgba(29, 29, 31, 0.82);
  border-bottom-color: rgba(255, 255, 255, 0.08);
}

.site-header.header-dark .nav-link {
  color: rgba(255, 255, 255, 0.8);
}

.site-header.header-dark .nav-link:hover {
  color: var(--color-white);
}

.site-header.header-dark .logo-text {
  color: var(--color-white);
}

.logo-img {
  height: 52px;
  width: auto;
  transition: filter 0.4s var(--ease-out), mix-blend-mode 0.4s;
}

.site-header.header-dark .logo-img {
  filter: invert(1);
  mix-blend-mode: screen;
}

.site-header:not(.header-dark) .logo-img {
  filter: none;
  mix-blend-mode: multiply;
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-mark {
  width: 36px;
  height: 36px;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--color-black);
  transition: color 0.4s var(--ease-out);
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--color-dark);
  transition: color 0.3s var(--ease-out), opacity 0.3s var(--ease-out);
  letter-spacing: -0.01em;
}

.nav-link:hover {
  color: var(--color-black);
  opacity: 1;
}

.nav-link.active {
  font-weight: 500;
}

/* Mobile nav */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  position: relative;
  width: 36px;
  height: 36px;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--color-black);
  position: absolute;
  left: 8px;
  transition: all 0.3s var(--ease-in-out);
}

.header-dark .nav-toggle span {
  background: var(--color-white);
}

.nav-toggle span:nth-child(1) { top: 12px; }
.nav-toggle span:nth-child(2) { top: 17px; }
.nav-toggle span:nth-child(3) { top: 22px; }

.nav-toggle.open span:nth-child(1) {
  top: 17px;
  transform: rotate(45deg);
}
.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.open span:nth-child(3) {
  top: 17px;
  transform: rotate(-45deg);
}

.nav-mobile {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 999;
  padding: 48px 24px;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out);
  pointer-events: none;
}

.nav-mobile.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.nav-mobile a {
  display: block;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 600;
  padding: 16px 0;
  color: var(--color-black);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

/* --- Hero --- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
  padding: 0 24px;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.hero-content .subhead {
  color: rgba(255, 255, 255, 0.75);
  margin-top: 20px;
}

.hero-scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0.6;
  animation: floatDown 2s ease-in-out infinite;
}

.hero-scroll-indicator span {
  font-size: 0.75rem;
  color: var(--color-white);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.hero-scroll-indicator svg {
  width: 20px;
  height: 20px;
  stroke: var(--color-white);
}

@keyframes floatDown {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* --- Page Hero (for inner pages) --- */
.page-hero {
  position: relative;
  height: 70vh;
  min-height: 500px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.page-hero .hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}

.page-hero .hero-overlay {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.1) 0%,
    rgba(0, 0, 0, 0.65) 100%
  );
}

.page-hero-content {
  position: relative;
  z-index: 2;
  padding: 0 24px 80px;
  max-width: var(--max-width);
  margin: 0 auto;
  width: 100%;
}

.page-hero-content .label {
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 16px;
}

.page-hero-content .headline-hero {
  font-size: clamp(2rem, 5vw, 4rem);
}

/* --- Services & Industries Grid --- */
.grid-section-header {
  text-align: center;
  margin-bottom: 64px;
}

.grid-section-header .label {
  margin-bottom: 12px;
  display: block;
}

.card-grid {
  display: grid;
  gap: 20px;
}

.card-grid-5 {
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: auto auto;
}

.card-grid-5 .card-item:nth-child(4),
.card-grid-5 .card-item:nth-child(5) {
  /* last two span more */
}

.card-item {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: pointer;
  background: var(--color-black);
}

.card-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s var(--ease-out), filter 0.6s var(--ease-out);
  filter: brightness(0.75);
}

.card-item:hover img {
  transform: scale(1.04);
  filter: brightness(0.6);
}

.card-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 32px;
  background: linear-gradient(
    180deg,
    transparent 40%,
    rgba(0, 0, 0, 0.6) 100%
  );
  z-index: 1;
}

.card-overlay .label {
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 8px;
}

.card-overlay .headline-card {
  color: var(--color-white);
}

.card-arrow {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  opacity: 0;
  transform: translate(-8px, 8px);
  transition: all 0.4s var(--ease-out);
}

.card-item:hover .card-arrow {
  opacity: 1;
  transform: translate(0, 0);
}

.card-arrow svg {
  width: 16px;
  height: 16px;
  stroke: var(--color-white);
  stroke-width: 2;
}

/* --- Image Telling Sections (inner pages) --- */
.imagetell {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  min-height: 600px;
  overflow: hidden;
}

.imagetell-reverse {
  direction: rtl;
}

.imagetell-reverse > * {
  direction: ltr;
}

.imagetell-img {
  position: relative;
  overflow: hidden;
}

.imagetell-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.8s var(--ease-out);
}

.imagetell-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px 80px;
  overflow: hidden;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.imagetell-text .label {
  margin-bottom: 16px;
}

.imagetell-text .headline-section {
  margin-bottom: 24px;
}

.imagetell-text .body-large {
  margin-bottom: 32px;
}

/* --- Intro Block (used on inner pages) --- */
.intro-block {
  padding: 100px 0 80px;
  text-align: center;
  overflow: hidden;
}

.intro-block .body-large {
  max-width: 700px;
  margin: 24px auto 0;
}

/* --- Statement / Quote --- */
.statement {
  padding: 120px 0;
  text-align: center;
  overflow: hidden;
}

.statement .headline-section {
  max-width: 900px;
  margin: 0 auto;
}

.statement .subhead {
  max-width: 600px;
  margin: 24px auto 0;
}

/* --- Network / Locations --- */
.locations-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 40px;
  margin-top: 64px;
}

.location-item {
  text-align: center;
  padding: 40px 24px;
}

.location-city {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.location-country {
  font-size: 0.9375rem;
  color: var(--color-gray);
}

/* --- CTA Section --- */
.cta-section {
  text-align: center;
  padding: 120px 0;
}

.cta-section .headline-section {
  margin-bottom: 24px;
}

.cta-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--color-black);
  border-bottom: 1.5px solid var(--color-black);
  padding-bottom: 4px;
  transition: gap 0.3s var(--ease-out), opacity 0.3s var(--ease-out);
}

.cta-link:hover {
  gap: 14px;
  opacity: 1;
}

.cta-link svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
}

.section-dark .cta-link {
  color: var(--color-white);
  border-bottom-color: var(--color-white);
}

/* --- Footer --- */
.site-footer {
  background: var(--color-black);
  color: rgba(255, 255, 255, 0.6);
  padding: 64px 0 40px;
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-brand .logo-text {
  color: var(--color-white);
  font-size: 1.25rem;
  margin-bottom: 16px;
  display: block;
}

.footer-brand p {
  font-size: 0.875rem;
  line-height: 1.6;
  max-width: 300px;
}

.footer-col h4 {
  color: var(--color-white);
  font-size: 0.8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 20px;
}

.footer-col a {
  display: block;
  font-size: 0.875rem;
  padding: 6px 0;
  color: rgba(255, 255, 255, 0.5);
  transition: color 0.3s var(--ease-out);
}

.footer-col a:hover {
  color: var(--color-white);
  opacity: 1;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 32px;
  font-size: 0.8125rem;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.4);
}

/* --- Scroll Animations --- */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.fade-in-delay-1 { transition-delay: 0.1s; }
.fade-in-delay-2 { transition-delay: 0.2s; }
.fade-in-delay-3 { transition-delay: 0.3s; }
.fade-in-delay-4 { transition-delay: 0.4s; }
.fade-in-delay-5 { transition-delay: 0.5s; }

.slide-in-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.slide-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.slide-in-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

.slide-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* --- Parallax Image --- */
.parallax-img {
  will-change: transform;
}

/* --- Divider --- */
.divider {
  height: 1px;
  background: rgba(0, 0, 0, 0.08);
  max-width: var(--max-width);
  margin: 0 auto;
}

.section-dark .divider {
  background: rgba(255, 255, 255, 0.08);
}

/* --- Full Width Image Banner --- */
.full-image-banner {
  position: relative;
  height: 60vh;
  min-height: 400px;
  overflow: hidden;
}

.full-image-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.full-image-banner .overlay-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.35);
  z-index: 1;
}

/* --- Key Points List --- */
.key-points {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
  margin-top: 64px;
}

.key-point {
  text-align: center;
}

.key-point-number {
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 700;
  color: var(--color-black);
  line-height: 1;
  margin-bottom: 12px;
  letter-spacing: -0.03em;
}

.section-dark .key-point-number {
  color: var(--color-white);
}

.key-point h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.key-point p {
  font-size: 0.9375rem;
  color: var(--color-gray);
  line-height: 1.6;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  :root {
    --section-padding: 80px;
  }

  .card-grid-5 {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-top {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }

  .imagetell {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .imagetell-img {
    aspect-ratio: 16/9;
  }

  .imagetell-text {
    padding: 60px 40px;
  }

  .imagetell-reverse {
    direction: ltr;
  }

  .key-points {
    grid-template-columns: repeat(2, 1fr);
    gap: 36px;
  }
}

@media (max-width: 768px) {
  :root {
    --section-padding: 64px;
    --header-height: 60px;
  }

  .nav-desktop {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .card-grid-5 {
    grid-template-columns: 1fr;
  }

  .card-item {
    aspect-ratio: 16/10;
  }

  .page-hero {
    height: 50vh;
    min-height: 320px;
  }

  .page-hero-content {
    padding-bottom: 40px;
  }

  .page-hero-content .headline-hero {
    font-size: clamp(1.75rem, 8vw, 2.5rem);
  }

  .hero-content h1 {
    font-size: clamp(2.2rem, 10vw, 3.5rem) !important;
  }

  .hero-content .headline-hero {
    font-size: clamp(1.2rem, 5vw, 1.8rem) !important;
  }

  .intro-block {
    padding: 60px 0 48px;
  }

  .statement {
    padding: 64px 0;
  }

  .full-image-banner {
    height: 40vh;
    min-height: 250px;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .imagetell-img {
    aspect-ratio: 4/3;
  }

  .imagetell-text {
    padding: 40px 20px;
  }

  .imagetell-text .headline-section {
    font-size: clamp(1.5rem, 6vw, 2rem);
  }

  .imagetell-text .body-large {
    font-size: 1rem;
  }

  .imagetell-text .body-text {
    font-size: 0.9375rem;
  }

  .slide-in-left,
  .slide-in-right {
    transform: translateY(30px);
  }

  .slide-in-left.visible,
  .slide-in-right.visible {
    transform: translateY(0);
  }

  .locations-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-top: 40px;
  }

  .key-points {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

@media (max-width: 480px) {
  .locations-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .location-item {
    padding: 24px 16px;
  }

  .location-city {
    font-size: 1.25rem;
  }

  .cta-link {
    font-size: 0.875rem;
    word-break: break-all;
  }

  .cta-section .headline-section {
    font-size: clamp(1.5rem, 7vw, 2rem);
  }

  .grid-section-header .headline-section {
    font-size: clamp(1.5rem, 7vw, 2rem);
  }

  .logo-img {
    height: 38px;
  }
}
