:root {
  --bg: #e2d2bf;
  --surface: rgba(255, 248, 239, 0.68);
  --surface-strong: rgba(255, 250, 243, 0.86);
  --text: #2b211b;
  --text-soft: rgba(43, 33, 27, 0.9);
  --border: rgba(72, 50, 34, 0.13);
  --border-strong: rgba(72, 50, 34, 0.2);
  --shadow: 0 8px 24px rgba(48, 31, 20, 0.08);
  --shadow-soft: 0 14px 40px rgba(48, 31, 20, 0.11);
  --shadow-large: 0 24px 60px rgba(48, 31, 20, 0.16);

  --terra-clay: #9f4f32;
  --terra-clay-soft: #bf7650;
  --terra-copper: #a95e3a;
  --terra-stone: #b49b82;
  --terra-sand: #eadbc8;
  --terra-cream: #f7efe4;
  --terra-espresso: #2f241d;
  --terra-espresso-soft: #4d3829;
  --terra-bronze: #d2ad75;

  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 18px;
  --radius-xl: 28px;
  --radius-pill: 999px;
  --container: 1100px;
  --section-pad: 56px;

  --terra-watermark-mark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='170' viewBox='0 0 240 170'%3E%3Cg transform='translate(120 85) rotate(-28)' fill='%23523a2a' opacity='1' font-family='Arial, Helvetica, sans-serif' font-weight='900' letter-spacing='5'%3E%3Ctext x='0' y='-10' text-anchor='middle' font-size='23'%3ETERRA%3C/text%3E%3Ctext x='0' y='24' text-anchor='middle' font-size='23'%3ESERVICES%3C/text%3E%3C/g%3E%3C/svg%3E");
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  position: relative;
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 8% 10%, rgba(159, 79, 50, 0.26), transparent 28%),
    radial-gradient(circle at 92% 12%, rgba(191, 118, 80, 0.2), transparent 26%),
    radial-gradient(circle at 14% 84%, rgba(77, 56, 41, 0.14), transparent 30%),
    radial-gradient(circle at 86% 88%, rgba(210, 173, 117, 0.16), transparent 28%),
    linear-gradient(180deg, #d6c2ad 0%, #e2d2bf 28%, #efe2d1 58%, #dcc8b3 100%);
  line-height: 1.55;
  overflow-wrap: break-word;
  isolation: isolate;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.45;
  background:
    repeating-linear-gradient(
      115deg,
      rgba(255, 255, 255, 0.06) 0,
      rgba(255, 255, 255, 0.06) 2px,
      transparent 2px,
      transparent 38px
    ),
    repeating-linear-gradient(
      64deg,
      rgba(67, 47, 34, 0.024) 0,
      rgba(67, 47, 34, 0.024) 1px,
      transparent 1px,
      transparent 52px
    ),
    radial-gradient(circle at 50% 20%, rgba(255, 255, 255, 0.12), transparent 34%),
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.08) 0%,
      transparent 24%,
      transparent 64%,
      rgba(68, 48, 34, 0.05) 100%
    );
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.034;
  background-image: var(--terra-watermark-mark);
  background-repeat: repeat;
  background-size: 240px 170px;
  background-position: 18px 14px;
  mix-blend-mode: multiply;
  filter: sepia(0.35) contrast(1.05);
}

.site-header,
main,
.site-footer,
.lightbox {
  position: relative;
  z-index: 1;
}

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

a {
  color: inherit;
}

.container {
  width: min(100%, var(--container));
  margin: 0 auto;
  padding-inline: 18px;
}

.section {
  padding-block: var(--section-pad);
}

.section-intro {
  max-width: 72ch;
  margin-top: 10px;
  opacity: 0.9;
}

.page-title {
  margin: 0;
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -0.4px;
}

/* ===== Header / Nav ===== */
.site-header {
  position: relative;
  z-index: 20;
  overflow: hidden;
  background:
    linear-gradient(
      180deg,
      rgba(75, 55, 40, 0.98) 0%,
      rgba(116, 84, 62, 0.94) 46%,
      rgba(190, 168, 145, 0.9) 100%
    );
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(54, 38, 26, 0.28);
  box-shadow: 0 10px 28px rgba(45, 31, 22, 0.12);
}

.site-header::after {
  content: "TERRA SERVICES ltd.  •  EST. 2026";
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 10px 18px;
  color: rgba(255, 244, 231, 0.96);
  font-size: clamp(13px, 1.55vw, 17px);
  font-weight: 900;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-align: center;
  background:
    radial-gradient(circle at 14% 28%, rgba(255, 235, 205, 0.18), transparent 18%),
    radial-gradient(circle at 78% 72%, rgba(255, 255, 255, 0.11), transparent 22%),
    linear-gradient(
      115deg,
      rgba(54, 37, 26, 0) 0%,
      rgba(255, 244, 229, 0.13) 12%,
      rgba(54, 37, 26, 0) 22%,
      rgba(255, 244, 229, 0.1) 42%,
      rgba(54, 37, 26, 0) 54%,
      rgba(255, 244, 229, 0.14) 78%,
      rgba(54, 37, 26, 0) 100%
    ),
    linear-gradient(
      135deg,
      #4a2d1f 0%,
      #7b3c24 22%,
      #9f4f32 43%,
      #643724 58%,
      #a7653e 76%,
      #3d2a20 100%
    );
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 -1px 0 rgba(0, 0, 0, 0.24),
    0 10px 24px rgba(53, 35, 24, 0.18);
  text-shadow:
    0 1px 0 rgba(0, 0, 0, 0.45),
    0 0 10px rgba(255, 238, 210, 0.1);
}

.site-header .container.header-inner {
  width: 100%;
  max-width: none;
  padding-inline: 0;
}

.header-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0;
  min-height: 0;
  padding-block: 0;
}

.logo {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  flex: 0 0 auto;
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 0;
}

.logo a {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 100%;
  padding-inline: 4px;
  padding-block: 0;
  margin: 0;
  line-height: 0;
}

.logo-image {
  display: block;
  width: min(100%, 1400px);
  height: 420px;
  max-width: 100%;
  object-fit: contain;
  object-position: center;
  transform: none;
}

/* nav row under logo */
.main-nav {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 0;
  margin-top: -58px;
  padding: 4px 10px 6px;
  background:
    linear-gradient(
      180deg,
      rgba(76, 55, 39, 0.18) 0%,
      rgba(193, 169, 145, 0.32) 48%,
      rgba(247, 239, 228, 0.76) 100%
    );
  border-top: 0;
}

.main-nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 7px 14px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
  white-space: nowrap;
  background: rgba(255, 250, 243, 0.38);
  border: 1px solid rgba(75, 52, 35, 0.08);
  box-shadow: 0 4px 10px rgba(54, 37, 25, 0.05);
}

.main-nav a:hover,
.main-nav a:focus-visible {
  background: rgba(255, 250, 243, 0.6);
  color: #221a15;
  transform: translateY(-1px);
  outline: none;
}

.main-nav a[aria-current="page"] {
  background: rgba(255, 250, 243, 0.72);
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 14px;
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  font-weight: 800;
  text-decoration: none;
  text-align: center;
  transition: transform 0.08s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn:focus-visible {
  outline: 2px solid rgba(0, 0, 0, 0.35);
  outline-offset: 2px;
}

.btn-primary {
  color: #fff8ef;
  background:
    linear-gradient(180deg, #604431 0%, #3d2b20 100%);
  border-color: rgba(61, 43, 32, 0.34);
  box-shadow: 0 8px 18px rgba(48, 31, 20, 0.12);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background:
    linear-gradient(180deg, #73513b 0%, #4d3728 100%);
}

.btn-outline {
  background: rgba(255, 250, 243, 0.24);
  border-color: rgba(72, 50, 34, 0.18);
}

.btn-outline:hover,
.btn-outline:focus-visible {
  background: rgba(255, 250, 243, 0.42);
}

/* ===== Hero ===== */
.hero {
  padding: 56px 0 28px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 22px;
  align-items: start;
}

.hero-text h1 {
  margin: 0 0 10px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.1;
  letter-spacing: -0.6px;
}

.hero-tagline,
.hero-sub {
  max-width: 70ch;
}

.hero-tagline {
  margin: 0 0 10px;
  font-size: 16px;
  opacity: 0.92;
}

.hero-sub {
  margin: 0 0 16px;
  opacity: 0.9;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* ===== Hero Gallery ===== */
.hero-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.hero-gallery img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.55);
  box-shadow: var(--shadow);
  transition: opacity 0.45s ease, transform 0.25s ease;
}

.hero-gallery img:hover {
  transform: translateY(-2px);
}

.hero-gallery img.is-fading {
  opacity: 0.15;
}

/* ===== Generic Cards ===== */
.card,
.contact-form,
.contact-info,
.gallery-tile,
.service-panel,
.shop-panel {
  background: rgba(255, 248, 239, 0.66);
  border: 1px solid rgba(72, 50, 34, 0.1);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 24px rgba(48, 31, 20, 0.075);
}

.card-grid,
.services-grid,
.shop-grid {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.card-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.services-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.shop-grid {
  grid-template-columns: 1fr;
}

.card,
.service-panel,
.shop-panel {
  padding: 16px;
}

.card h3,
.service-panel h3,
.shop-panel h3 {
  margin: 0 0 8px;
  font-size: 16px;
}

.card p,
.service-panel p,
.shop-panel p {
  margin: 0;
  opacity: 0.9;
}

/* ===== Services Page ===== */
.services-hero {
  padding-top: 56px;
  padding-bottom: 20px;
}

.services-hero-copy {
  max-width: 76ch;
}

.services-hero-copy p {
  margin: 12px 0 0;
}

.service-panel {
  display: grid;
  gap: 10px;
}

.service-panel ul {
  margin: 0;
  padding-left: 18px;
}

.service-panel li {
  margin-bottom: 8px;
}

.service-panel li:last-child {
  margin-bottom: 0;
}

/* ===== About Section on Home ===== */
.about {
  background:
    linear-gradient(
      180deg,
      rgba(239, 226, 209, 0.68) 0%,
      rgba(226, 210, 191, 0.54) 100%
    );
  color: #2c241e;
}

.about-shell {
  max-width: 1040px;
  margin: 0 auto;
  padding: 2.25rem;
  background: rgba(255, 249, 242, 0.84);
  border: 1px solid rgba(80, 58, 40, 0.13);
  border-radius: 22px;
  box-shadow: 0 16px 38px rgba(48, 31, 20, 0.09);
  backdrop-filter: blur(6px);
}

.about-header {
  max-width: 700px;
  margin-bottom: 2rem;
}

.about-eyebrow {
  display: inline-block;
  margin: 0 0 0.75rem;
  padding: 0.42rem 0.85rem;
  border-radius: var(--radius-pill);
  background: rgba(159, 79, 50, 0.11);
  color: #75432e;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.about-header h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #2b241e;
}

.about-lead {
  margin: 0.9rem 0 0;
  max-width: 680px;
  font-size: 1.06rem;
  line-height: 1.7;
  color: #5f5145;
  font-weight: 500;
}

.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.85fr);
  gap: 1.5rem;
  align-items: start;
}

.about-main p,
.about-values-text p {
  margin: 0 0 1rem;
  font-size: 1rem;
  line-height: 1.75;
  color: #3c352f;
}

.about-main p:last-child,
.about-values-text p:last-child {
  margin-bottom: 0;
}

.about-side {
  display: grid;
  gap: 1rem;
}

.about-card {
  padding: 1.2rem;
  background: #faf6f1;
  border: 1px solid rgba(80, 64, 48, 0.1);
  border-radius: 18px;
  box-shadow: 0 8px 20px rgba(31, 24, 18, 0.05);
}

.about-card h3 {
  margin: 0 0 0.65rem;
  font-size: 1.28rem;
  line-height: 1.25;
  color: #342a23;
}

.about-card h4 {
  margin: 0 0 0.8rem;
  font-size: 0.95rem;
  line-height: 1.35;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #5e4d3e;
}

.about-card p {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.65;
  color: #564a40;
}

.about-card-accent {
  background: linear-gradient(180deg, #5b4635 0%, #49372a 100%);
  color: #f8f2ea;
  border-color: rgba(255, 255, 255, 0.08);
}

.about-card-accent h4 {
  color: #f5eadf;
}

.about-points {
  margin: 0;
  padding-left: 1.1rem;
}

.about-points li {
  margin-bottom: 0.7rem;
  line-height: 1.6;
  color: #f4ede5;
}

.about-points li:last-child {
  margin-bottom: 0;
}

.about-values {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) 220px;
  gap: 1.5rem;
  align-items: center;
  margin-top: 1.75rem;
  padding-top: 1.75rem;
  border-top: 1px solid rgba(80, 64, 48, 0.12);
}

.about-quote {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 150px;
  padding: 1.4rem;
  border-radius: 18px;
  background: linear-gradient(135deg, #6b5442, #4b3a2d);
  box-shadow: 0 12px 28px rgba(31, 24, 18, 0.12);
  text-align: left;
}

.about-quote span {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(248, 242, 234, 0.78);
}

.about-quote strong {
  display: block;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  line-height: 1.05;
  color: #ffffff;
  letter-spacing: -0.03em;
}

/* ===== Shop ===== */
.shop-products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
  align-items: start;
  margin-top: 2rem;
}

.shop-product-item {
  width: 100%;
  min-width: 0;
}

.oversized-row {
  grid-template-columns: 1fr;
  justify-items: center;
  margin-top: 1.9rem;
}

.oversized-product-shell {
  width: 100%;
  max-width: 470px;
}

.oversized-frame {
  position: relative;
  width: 100%;
  padding: 3.25rem 1.1rem;
  border: 4px solid #ff4df3;
  border-radius: 24px;
  background: rgba(255, 77, 243, 0.04);
  box-shadow:
    0 0 6px rgba(255, 77, 243, 0.9),
    0 0 12px rgba(255, 77, 243, 0.85),
    0 0 22px rgba(255, 77, 243, 0.7),
    0 0 40px rgba(255, 77, 243, 0.45),
    inset 0 0 12px rgba(255, 77, 243, 0.18);
  animation: oversized-frame-pulse 2.2s ease-in-out infinite;
}

.oversized-frame::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 2px solid rgba(255, 110, 247, 0.75);
  border-radius: 18px;
  box-shadow:
    0 0 8px rgba(255, 77, 243, 0.45),
    inset 0 0 8px rgba(255, 77, 243, 0.18);
  pointer-events: none;
}

.oversized-frame-label {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: inline-block;
  padding: 0.2rem 1rem;
  background: #ff4df3;
  border: 3px solid #ff4df3;
  border-radius: 999px;
  font-family: "Quantico", "Segoe UI", sans-serif;
  font-size: 0.95rem;
  font-weight: 900;
  letter-spacing: 0.22em;
  color: #050505;
  text-transform: uppercase;
  box-shadow:
    0 0 5px rgba(255, 77, 243, 0.95),
    0 0 12px rgba(255, 77, 243, 0.9),
    0 0 20px rgba(255, 77, 243, 0.65);
  text-shadow:
    0 0 1px rgba(0, 0, 0, 0.95),
    0 0 2px rgba(0, 0, 0, 0.75);
  animation: oversized-text-flicker 3.1s linear infinite;
  z-index: 2;
}

.oversized-frame-label-top {
  top: -1rem;
}

.oversized-frame-label-bottom {
  bottom: -1rem;
}

.oversized-product-card {
  position: relative;
  z-index: 1;
  width: 100%;
  padding: 1rem;
  border-radius: 18px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.96) 0%,
    rgba(255, 255, 255, 0.88) 100%
  );
  box-shadow:
    0 10px 24px rgba(0, 0, 0, 0.12),
    inset 0 0 8px rgba(255, 255, 255, 0.55);
}

@keyframes oversized-frame-pulse {
  0%,
  100% {
    box-shadow:
      0 0 6px rgba(255, 77, 243, 0.9),
      0 0 12px rgba(255, 77, 243, 0.85),
      0 0 22px rgba(255, 77, 243, 0.7),
      0 0 40px rgba(255, 77, 243, 0.45),
      inset 0 0 12px rgba(255, 77, 243, 0.18);
  }

  50% {
    box-shadow:
      0 0 10px rgba(255, 77, 243, 1),
      0 0 18px rgba(255, 77, 243, 0.95),
      0 0 32px rgba(255, 77, 243, 0.82),
      0 0 56px rgba(255, 77, 243, 0.58),
      inset 0 0 16px rgba(255, 77, 243, 0.24);
  }
}

@keyframes oversized-text-flicker {
  0%,
  18%,
  22%,
  36%,
  64%,
  100% {
    opacity: 1;
    box-shadow:
      0 0 5px rgba(255, 77, 243, 0.95),
      0 0 12px rgba(255, 77, 243, 0.9),
      0 0 20px rgba(255, 77, 243, 0.65);
  }

  20% {
    opacity: 0.72;
    box-shadow:
      0 0 3px rgba(255, 77, 243, 0.5),
      0 0 8px rgba(255, 77, 243, 0.4),
      0 0 14px rgba(255, 77, 243, 0.28);
  }

  21% {
    opacity: 0.96;
  }

  37% {
    opacity: 0.82;
  }

  38% {
    opacity: 1;
  }

  65% {
    opacity: 0.75;
  }

  66% {
    opacity: 1;
  }
}

/* ===== ALIEN and SMILEY ===== */
.alien-smiley-section {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 8% 12%, rgba(0, 255, 128, 0.18) 0, rgba(0, 255, 128, 0) 22%),
    radial-gradient(circle at 88% 10%, rgba(0, 217, 255, 0.18) 0, rgba(0, 217, 255, 0) 22%),
    radial-gradient(circle at 22% 78%, rgba(255, 0, 230, 0.16) 0, rgba(255, 0, 230, 0) 24%),
    radial-gradient(circle at 78% 72%, rgba(172, 255, 47, 0.12) 0, rgba(172, 255, 47, 0) 24%),
    linear-gradient(180deg, #0a0914 0%, #0d1020 42%, #11152b 100%);
  border-top: 2px solid rgba(133, 255, 200, 0.22);
  border-bottom: 2px solid rgba(255, 0, 221, 0.22);
  color: #f6fbff;
}

.alien-smiley-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% -8%, rgba(0, 255, 128, 0.22), rgba(0, 255, 128, 0) 28%),
    radial-gradient(circle at 50% 108%, rgba(255, 0, 230, 0.18), rgba(255, 0, 230, 0) 26%);
  pointer-events: none;
  opacity: 0.9;
}

.alien-smiley-section::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0) 18%),
    repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.018) 0,
      rgba(255, 255, 255, 0.018) 1px,
      transparent 1px,
      transparent 90px
    );
  mix-blend-mode: screen;
  pointer-events: none;
  opacity: 0.4;
}

.alien-smiley-shell {
  position: relative;
  padding: clamp(1.5rem, 3vw, 2.25rem);
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(8, 10, 22, 0.94), rgba(10, 12, 26, 0.88)),
    radial-gradient(circle at top, rgba(0, 255, 128, 0.08), rgba(0, 255, 128, 0) 34%);
  border: 2px solid rgba(72, 255, 166, 0.38);
  box-shadow:
    0 0 0 1px rgba(255, 0, 221, 0.18),
    0 0 22px rgba(72, 255, 166, 0.16),
    0 0 44px rgba(0, 174, 255, 0.1),
    0 18px 50px rgba(0, 0, 0, 0.34);
  overflow: hidden;
  z-index: 1;
}

.alien-smiley-shell::before {
  content: "";
  position: absolute;
  inset: -20% -10%;
  background:
    radial-gradient(circle at 50% 42%, rgba(105, 255, 180, 0.12), rgba(105, 255, 180, 0) 24%),
    radial-gradient(circle at 30% 50%, rgba(255, 0, 230, 0.1), rgba(255, 0, 230, 0) 20%),
    radial-gradient(circle at 70% 50%, rgba(0, 217, 255, 0.1), rgba(0, 217, 255, 0) 20%);
  pointer-events: none;
  animation: alien-rift-breathe 6s ease-in-out infinite;
}

.alien-smiley-shell::after {
  content: "";
  position: absolute;
  inset: 14px;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    inset 0 0 18px rgba(0, 255, 128, 0.08),
    inset 0 0 24px rgba(255, 0, 230, 0.05);
  pointer-events: none;
}

.alien-smiley-title {
  position: relative;
  display: inline-block;
  margin: 0;
  padding-right: 6.5rem;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #effff8;
  text-shadow:
    0 0 6px rgba(72, 255, 166, 0.52),
    0 0 14px rgba(0, 217, 255, 0.35),
    0 0 22px rgba(255, 0, 230, 0.22);
}

.alien-smiley-title-word-alien {
  color: #7dff9c;
  text-shadow:
    0 0 6px rgba(125, 255, 156, 0.9),
    0 0 16px rgba(125, 255, 156, 0.52),
    0 0 28px rgba(0, 255, 128, 0.34);
}

.alien-smiley-title-word-smiley {
  color: #ff6cf6;
  text-shadow:
    0 0 6px rgba(255, 108, 246, 0.9),
    0 0 16px rgba(255, 108, 246, 0.52),
    0 0 28px rgba(255, 0, 230, 0.34);
}

.alien-smiley-subtitle {
  position: relative;
  max-width: 70ch;
  margin-top: 0.9rem;
  margin-bottom: 0;
  color: rgba(236, 255, 248, 0.9);
  text-shadow: 0 0 10px rgba(0, 255, 128, 0.1);
}

.alien-smiley-panel {
  position: relative;
  margin-top: 1.4rem;
  background:
    linear-gradient(180deg, rgba(13, 18, 34, 0.78), rgba(9, 13, 27, 0.72));
  border: 1px solid rgba(91, 255, 174, 0.3);
  border-radius: 22px;
  box-shadow:
    0 0 14px rgba(0, 255, 128, 0.12),
    inset 0 0 14px rgba(255, 0, 230, 0.05);
  color: #edfff7;
}

.alien-smiley-panel h3,
.alien-smiley-panel p {
  position: relative;
  z-index: 1;
}

.alien-smiley-panel h3 {
  color: #87ffaf;
  text-shadow: 0 0 10px rgba(135, 255, 175, 0.22);
}

.alien-smiley-panel p {
  opacity: 0.96;
}

.alien-smiley-grid {
  position: relative;
}

.alien-smiley-grid::before {
  content: "";
  position: absolute;
  inset: -16px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 18% 18%, rgba(0, 255, 128, 0.08), rgba(0, 255, 128, 0) 20%),
    radial-gradient(circle at 82% 14%, rgba(0, 217, 255, 0.08), rgba(0, 217, 255, 0) 18%),
    radial-gradient(circle at 50% 100%, rgba(255, 0, 230, 0.07), rgba(255, 0, 230, 0) 30%);
  pointer-events: none;
}

.alien-smiley-item {
  position: relative;
  padding: 1rem;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(9, 12, 25, 0.84), rgba(13, 18, 35, 0.72));
  border: 1px solid rgba(85, 255, 170, 0.26);
  box-shadow:
    0 0 0 1px rgba(255, 0, 230, 0.12),
    0 0 20px rgba(0, 255, 128, 0.09),
    inset 0 0 18px rgba(0, 217, 255, 0.04);
  overflow: hidden;
}

.alien-smiley-item::before {
  content: "";
  position: absolute;
  top: -18%;
  left: 50%;
  width: 220px;
  height: 220px;
  transform: translateX(-50%);
  background:
    radial-gradient(circle at 50% 58%, rgba(0, 255, 128, 0.18), rgba(0, 255, 128, 0) 52%);
  opacity: 0.7;
  pointer-events: none;
}

.alien-smiley-item::after {
  content: "";
  position: absolute;
  top: 0.75rem;
  right: 0.8rem;
  width: 62px;
  height: 28px;
  border-radius: 50% 50% 46% 46%;
  border: 2px solid rgba(120, 255, 175, 0.7);
  box-shadow:
    0 0 8px rgba(120, 255, 175, 0.45),
    0 0 16px rgba(0, 217, 255, 0.18);
  background:
    radial-gradient(circle at 50% 25%, rgba(255, 255, 255, 0.34), rgba(255, 255, 255, 0) 50%),
    linear-gradient(180deg, rgba(70, 255, 180, 0.24), rgba(70, 255, 180, 0.08));
  opacity: 0.9;
  pointer-events: none;
}

.alien-smiley-item .shopify-buy__product {
  position: relative;
  z-index: 1;
}

.alien-smiley-rift-badge {
  position: absolute;
  top: 0.9rem;
  left: 0.9rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  font-family: "Quantico", "Segoe UI", sans-serif;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #07130f;
  background: linear-gradient(90deg, #7dff9c 0%, #00eaff 50%, #ff73f3 100%);
  box-shadow:
    0 0 8px rgba(125, 255, 156, 0.45),
    0 0 18px rgba(255, 115, 243, 0.28);
}

.alien-smiley-ufo {
  position: absolute;
  pointer-events: none;
  z-index: 0;
  opacity: 0.8;
}

.alien-smiley-ufo-left {
  top: 1.6rem;
  left: 1.2rem;
  width: 98px;
  height: 150px;
  animation: alien-ufo-drift-left 8.5s ease-in-out infinite;
}

.alien-smiley-ufo-right {
  top: 2.1rem;
  right: 1.4rem;
  width: 110px;
  height: 162px;
  animation: alien-ufo-drift-right 10s ease-in-out infinite;
}

.alien-smiley-ufo-disc {
  position: absolute;
  left: 50%;
  bottom: 122px;
  width: 100%;
  height: 26px;
  transform: translateX(-50%);
  border-radius: 50%;
  border: 2px solid rgba(128, 255, 175, 0.82);
  background:
    linear-gradient(180deg, rgba(14, 28, 32, 0.9), rgba(9, 18, 24, 0.82)),
    radial-gradient(circle at 50% 40%, rgba(0, 255, 128, 0.32), rgba(0, 255, 128, 0) 58%);
  box-shadow:
    0 0 8px rgba(128, 255, 175, 0.34),
    0 0 18px rgba(0, 217, 255, 0.18);
  z-index: 3;
}

.alien-smiley-ufo-dome {
  position: absolute;
  left: 50%;
  bottom: 136px;
  width: 38%;
  height: 20px;
  transform: translateX(-50%);
  border-radius: 50% 50% 42% 42%;
  border: 2px solid rgba(170, 255, 214, 0.72);
  background:
    radial-gradient(circle at 50% 35%, rgba(255, 255, 255, 0.45), rgba(255, 255, 255, 0.06) 50%, rgba(0, 255, 128, 0.18) 100%);
  box-shadow: 0 0 10px rgba(128, 255, 175, 0.28);
  z-index: 4;
}

.alien-smiley-ufo-beam {
  position: absolute;
  left: 50%;
  top: 40px;
  width: 66%;
  height: 108px;
  transform: translateX(-50%);
  clip-path: polygon(40% 0%, 60% 0%, 100% 100%, 0% 100%);
  background:
    linear-gradient(
      180deg,
      rgba(125, 255, 156, 0.3) 0%,
      rgba(0, 234, 255, 0.2) 38%,
      rgba(255, 115, 243, 0.1) 100%
    );
  filter: blur(0.5px);
  opacity: 0.82;
  z-index: 1;
}

.alien-smiley-ufo-beam::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: 28%;
  height: 100%;
  transform: translateX(-50%);
  clip-path: polygon(42% 0%, 58% 0%, 100% 100%, 0% 100%);
  background:
    linear-gradient(
      180deg,
      rgba(215, 255, 230, 0.7) 0%,
      rgba(125, 255, 156, 0.42) 30%,
      rgba(0, 234, 255, 0.22) 72%,
      rgba(255, 115, 243, 0.08) 100%
    );
  filter: blur(1px);
  opacity: 0.92;
}

.alien-smiley-ufo-beam::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -8px;
  width: 88%;
  height: 18px;
  transform: translateX(-50%);
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(125, 255, 156, 0.45) 0%, rgba(0, 234, 255, 0.18) 46%, rgba(255, 115, 243, 0.04) 72%, transparent 100%);
  filter: blur(3px);
  opacity: 0.95;
}

.alien-smiley-stars {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.75;
}

.alien-smiley-stars::before,
.alien-smiley-stars::after {
  content: "";
  position: absolute;
  inset: 0;
  background-repeat: no-repeat;
}

.alien-smiley-stars::before {
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.85) 0 1.3px, transparent 1.8px),
    radial-gradient(circle, rgba(125, 255, 156, 0.8) 0 1.6px, transparent 2px),
    radial-gradient(circle, rgba(255, 115, 243, 0.8) 0 1.5px, transparent 1.9px),
    radial-gradient(circle, rgba(0, 234, 255, 0.8) 0 1.5px, transparent 1.9px);
  background-size: 14px 14px, 18px 18px, 20px 20px, 16px 16px;
  background-position: 8% 24%, 84% 18%, 22% 70%, 72% 64%;
}

.alien-smiley-stars::after {
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.75) 0 1.2px, transparent 1.7px),
    radial-gradient(circle, rgba(125, 255, 156, 0.75) 0 1.4px, transparent 1.8px),
    radial-gradient(circle, rgba(0, 234, 255, 0.7) 0 1.3px, transparent 1.8px);
  background-size: 12px 12px, 17px 17px, 13px 13px;
  background-position: 58% 22%, 14% 46%, 86% 56%;
}

@keyframes alien-rift-breathe {
  0%,
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 0.9;
  }

  50% {
    transform: scale(1.05) rotate(1.2deg);
    opacity: 1;
  }
}

@keyframes alien-ufo-drift-left {
  0%,
  100% {
    transform: translateY(0) translateX(0) rotate(-2deg);
  }

  50% {
    transform: translateY(6px) translateX(8px) rotate(1deg);
  }
}

@keyframes alien-ufo-drift-right {
  0%,
  100% {
    transform: translateY(0) translateX(0) rotate(2deg);
  }

  50% {
    transform: translateY(-8px) translateX(-10px) rotate(-1deg);
  }
}

/* ===== Contact ===== */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 14px;
  align-items: start;
  margin-top: 16px;
}

.contact-form,
.contact-info {
  padding: 16px;
}

.contact-form label {
  display: grid;
  gap: 6px;
  margin-bottom: 10px;
  font-size: 13px;
  font-weight: 800;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 10px 12px;
  font: inherit;
  color: inherit;
  background: var(--surface-strong);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid rgba(0, 0, 0, 0.2);
  outline-offset: 1px;
}

.contact-form textarea {
  resize: vertical;
}

.form-status {
  margin: 10px 0 12px;
  padding: 10px 12px;
  font-size: 14px;
  border-radius: var(--radius-sm);
}

/* ===== Footer ===== */
.site-footer {
  padding: 22px 0 40px;
  background:
    linear-gradient(180deg, rgba(75, 55, 40, 0.12), rgba(75, 55, 40, 0.22));
  border-top: 1px solid rgba(72, 50, 34, 0.14);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.footer-note {
  opacity: 0.9;
}

/* ===== Gallery Page ===== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.gallery-tile {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-md);
}

.gallery-tile > img {
  width: 100%;
  height: 230px;
  object-fit: cover;
}

.gallery-tile figcaption {
  padding: 10px 12px;
  font-size: 14px;
  opacity: 0.9;
}

.gallery-note {
  margin-top: 14px;
  opacity: 0.85;
}

.gallery-note code {
  padding: 2px 6px;
  background: rgba(0, 0, 0, 0.06);
  border-radius: 8px;
}

/* ===== Lightbox ===== */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  place-items: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.72);
}

.lightbox.open {
  display: grid;
}

.lightbox-inner {
  position: relative;
  width: min(980px, 96vw);
  overflow: hidden;
  background: rgba(245, 241, 234, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-md);
}

.lightbox-img {
  width: 100%;
  max-height: 76vh;
  object-fit: contain;
  background: rgba(0, 0, 0, 0.08);
}

.lightbox-caption {
  padding: 10px 12px;
  font-size: 14px;
  opacity: 0.9;
}

.lightbox-close {
  position: absolute;
  top: 12px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.88);
  border: none;
  border-radius: var(--radius-pill);
}

/* ===== Gallery Tile Slideshow ===== */
.gallery-tile .tile-slides {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 12px;
}

.gallery-tile .tile-slides img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 250ms ease;
}

.gallery-tile .tile-slides img.is-active {
  opacity: 1;
}

/* ===== Responsive ===== */
@media (max-width: 980px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .shop-products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .oversized-row {
    grid-template-columns: 1fr;
  }

  .about-shell {
    padding: 2rem;
  }

  .about-grid,
  .about-values {
    grid-template-columns: 1fr;
  }

  .about-quote {
    min-height: auto;
  }

  .header-inner {
    min-height: 0;
    padding-block: 0;
  }

  .logo-image {
    width: min(100%, 1400px);
    height: 360px;
    max-width: 100%;
  }

  .main-nav {
    margin-top: -50px;
    padding: 4px 10px 6px;
  }

  .alien-smiley-title {
    padding-right: 0;
  }
}

@media (max-width: 860px) {
  .hero-inner,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-media {
    order: 2;
  }
}

@media (max-width: 700px) {
  .header-inner {
    align-items: center;
    gap: 0;
    min-height: auto;
    padding-block: 0;
  }

  .site-header::after {
    min-height: 42px;
    padding: 9px 12px;
    font-size: 12px;
    letter-spacing: 0.13em;
  }

  body::after {
    background-size: 190px 135px;
    opacity: 0.03;
  }

  .logo a {
    justify-content: center;
    width: 100%;
    height: auto;
    padding-inline: 0;
    padding-block: 0;
  }

  .logo-image {
    width: 100vw;
    height: clamp(320px, 82vw, 520px);
    max-width: 100%;
    object-fit: contain;
    object-position: center;
    transform: none;
  }

  .main-nav {
    flex-wrap: wrap;
    overflow: visible;
    gap: 8px;
    justify-content: center;
    margin-top: -48px;
    padding: 4px 8px 6px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .main-nav::-webkit-scrollbar {
    display: none;
  }

  .main-nav a {
    flex: 0 0 auto;
    min-height: 38px;
    padding: 7px 11px;
    font-size: 13px;
  }

  .shop-products {
    grid-template-columns: 1fr;
  }

  .oversized-product-shell {
    max-width: 100%;
  }

  .oversized-frame {
    padding: 3rem 0.85rem;
    border-radius: 20px;
  }

  .oversized-frame-label {
    font-size: 0.78rem;
    letter-spacing: 0.16em;
    padding: 0.2rem 0.7rem;
  }

  .oversized-product-card {
    padding: 0.85rem;
  }

  .alien-smiley-shell {
    padding: 1.2rem;
    border-radius: 22px;
  }

  .alien-smiley-title {
    font-size: clamp(1.7rem, 8vw, 2.5rem);
  }

  .alien-smiley-ufo-left,
  .alien-smiley-ufo-right {
    display: none;
  }

  .alien-smiley-item {
    padding-top: 1.2rem;
  }

  .alien-smiley-rift-badge {
    position: static;
    margin-bottom: 0.75rem;
  }

  .hero {
    padding-top: 26px;
  }
}

@media (max-width: 640px) {
  .section {
    padding-block: 48px;
  }

  .container {
    padding-inline: 14px;
  }

  .hero {
    padding: 26px 0 22px;
  }

  .hero-text h1 {
    font-size: clamp(28px, 9vw, 38px);
  }

  .hero-tagline,
  .hero-sub {
    font-size: 15px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .hero-gallery img {
    aspect-ratio: 1 / 1;
  }

  .about-shell {
    padding: 1.3rem;
    border-radius: 18px;
  }

  .about-header {
    margin-bottom: 1.4rem;
  }

  .about-header h2 {
    font-size: 1.9rem;
  }

  .about-lead {
    font-size: 1rem;
    line-height: 1.65;
  }

  .about-main p,
  .about-values-text p,
  .about-card p,
  .about-points li {
    font-size: 0.98rem;
    line-height: 1.7;
  }

  .about-card {
    padding: 1rem;
    border-radius: 16px;
  }

  .about-quote {
    padding: 1.2rem;
    border-radius: 16px;
  }

  .about-quote strong {
    font-size: 2rem;
  }

  .contact-form,
  .contact-info,
  .service-panel,
  .shop-panel {
    padding: 14px;
  }

  .lightbox {
    padding: 12px;
  }

  .lightbox-close {
    top: 8px;
    right: 8px;
  }
}

@media (max-width: 520px) {
  .section {
    padding-block: 40px;
  }

  .page-title {
    font-size: clamp(24px, 8vw, 32px);
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .gallery-tile > img {
    height: 210px;
  }

  .contact-form input,
  .contact-form textarea {
    padding: 12px;
  }

  .logo-image {
    width: 100vw;
    height: clamp(300px, 82vw, 460px);
    max-width: 100%;
  }

  .main-nav {
    margin-top: -40px;
    padding: 4px 6px 6px;
  }

  .oversized-frame-label {
    font-size: 0.72rem;
    letter-spacing: 0.14em;
  }

  .alien-smiley-rift-badge {
    font-size: 0.68rem;
    letter-spacing: 0.12em;
  }
}

@media (max-width: 420px) {
  .site-header::after {
    font-size: 11px;
    letter-spacing: 0.09em;
  }

  body::after {
    background-size: 160px 114px;
    opacity: 0.028;
  }

  .hero-gallery {
    gap: 8px;
  }

  .about-eyebrow {
    font-size: 0.76rem;
  }

  .lightbox-caption {
    font-size: 13px;
  }

  .logo-image {
    width: 100vw;
    height: clamp(260px, 72vw, 420px);
    max-width: 100%;
    transform: none;
  }

  .main-nav {
    margin-top: -34px;
  }

  .main-nav a {
    font-size: 12px;
    padding: 6px 10px;
  }

  .oversized-frame {
    border-radius: 18px;
  }

  .oversized-frame-label-top {
    top: -0.9rem;
  }

  .oversized-frame-label-bottom {
    bottom: -0.9rem;
  }

  .alien-smiley-shell {
    padding: 1rem;
    border-radius: 18px;
  }

  .alien-smiley-item {
    border-radius: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* =========================================================
   TERRA SERVICES V2 — CONTENT ENGINE / CMS-DRIVEN SECTIONS
   ========================================================= */
.content-page {
  min-height: 65vh;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.project-card {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  background: rgba(9, 14, 18, 0.82);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.24);
}

.project-card-media,
.project-detail-hero,
.project-photo {
  position: relative;
  overflow: hidden;
  background: #0a1014;
}

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

.project-card-media img,
.project-detail-hero img,
.project-photo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.content-image-placeholder {
  width: 100%;
  height: 100%;
  min-height: 220px;
  display: grid;
  place-items: center;
  padding: 2rem;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-align: center;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.04), transparent 45%),
    repeating-linear-gradient(-45deg, rgba(255,255,255,0.025) 0 10px, transparent 10px 20px),
    #0a1014;
}

.project-card-body {
  padding: 1.5rem;
}

.project-eyebrow {
  margin: 0 0 0.55rem;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  opacity: 0.72;
}

.project-card-title {
  margin: 0;
  font-size: clamp(1.45rem, 2.4vw, 2rem);
}

.project-status {
  margin: 0.65rem 0 0;
  font-size: 0.88rem;
  font-weight: 700;
  opacity: 0.72;
}

.project-card-copy {
  margin: 1rem 0 1.35rem;
  line-height: 1.7;
}

.project-detail-header {
  max-width: 900px;
  margin-bottom: 2rem;
}

.project-detail-lead {
  max-width: 850px;
  font-size: clamp(1.08rem, 1.8vw, 1.3rem);
  line-height: 1.75;
}

.project-detail-hero {
  width: 100%;
  min-height: 280px;
  max-height: 620px;
  aspect-ratio: 16 / 7;
  margin: 1.5rem 0 2.5rem;
  border-radius: 20px;
  border: 1px solid rgba(255,255,255,0.12);
}

.project-detail-section {
  max-width: 920px;
  padding: 1.6rem 0;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.project-detail-heading {
  margin: 0 0 0.8rem;
  font-size: clamp(1.35rem, 2.2vw, 1.8rem);
}

.project-detail-copy {
  margin: 0;
  line-height: 1.8;
  white-space: pre-line;
}

.project-roadmap {
  margin: 1rem 0 0;
  padding-left: 1.4rem;
}

.project-roadmap li {
  margin: 0.7rem 0;
  padding-left: 0.35rem;
  line-height: 1.6;
}

.project-photo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.project-photo {
  aspect-ratio: 4 / 3;
  border-radius: 14px;
}

.content-back-link {
  display: inline-block;
  margin-bottom: 1.25rem;
  font-weight: 700;
  text-decoration: none;
}

.content-error,
.empty-state {
  grid-column: 1 / -1;
  padding: 2rem;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  background: rgba(9,14,18,0.72);
}

@media (max-width: 950px) {
  .project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 650px) {
  .project-grid,
  .project-photo-grid { grid-template-columns: 1fr; }
  .project-detail-hero { aspect-ratio: 4 / 3; }
}

.home-projects {
  border-top: 1px solid rgba(255,255,255,0.08);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.content-section-action {
  margin-top: 1.5rem;
}

/* =========================================================
   TERRA SERVICES V2.3 — MODERN PATHFINDER BRAND SYSTEM
   Source of truth: 2026 Modern Pathfinder master logo + pattern
   This block intentionally overrides legacy V1/V2 presentation
   without altering any Shopify product/embed content.
   ========================================================= */
:root {
  --terra-red: #c32e24;
  --terra-red-deep: #9f050a;
  --terra-red-dark: #79050a;
  --terra-charcoal: #111516;
  --terra-charcoal-soft: #24292b;
  --terra-cream: #fcf2e3;
  --terra-cream-soft: #fffaf2;
  --terra-stone: #b4aba6;

  --bg: #f8eedf;
  --surface: rgba(255, 250, 242, 0.90);
  --surface-strong: rgba(255, 252, 247, 0.97);
  --text: #171a1b;
  --text-soft: rgba(23, 26, 27, 0.82);
  --border: rgba(17, 21, 22, 0.12);
  --border-strong: rgba(17, 21, 22, 0.20);
  --shadow: 0 10px 28px rgba(17, 21, 22, 0.09);
  --shadow-soft: 0 16px 42px rgba(17, 21, 22, 0.11);
  --shadow-large: 0 28px 72px rgba(17, 21, 22, 0.16);

  /* Legacy variable aliases retained so existing page sections stay safe. */
  --terra-clay: var(--terra-red);
  --terra-clay-soft: #d65a4f;
  --terra-copper: #a5221b;
  --terra-sand: #f1dfc7;
  --terra-espresso: var(--terra-charcoal);
  --terra-espresso-soft: #303638;
  --terra-bronze: #c5a06e;

  --terra-background-pattern: url("assets/brand/terra-pattern.webp");
}

body {
  color: var(--text);
  background:
    radial-gradient(circle at 14% 6%, rgba(195, 46, 36, 0.07), transparent 27%),
    radial-gradient(circle at 90% 16%, rgba(17, 21, 22, 0.055), transparent 25%),
    linear-gradient(180deg, #fff8ed 0%, #f8eedf 52%, #f5e8d7 100%);
}

/* Quiet paper-like light treatment under the branded ghost pattern. */
body::before {
  opacity: 0.42;
  background:
    radial-gradient(circle at 50% 20%, rgba(255, 255, 255, 0.42), transparent 36%),
    repeating-linear-gradient(
      112deg,
      rgba(255, 255, 255, 0.06) 0,
      rgba(255, 255, 255, 0.06) 2px,
      transparent 2px,
      transparent 46px
    );
}

/* The requested ghost-image treatment: full TERRA pattern on its own layer.
   Content remains 100% opaque; only the pattern is ghosted. */
body::after {
  opacity: 0.065;
  background-image: var(--terra-background-pattern);
  background-repeat: repeat;
  background-size: 900px 900px;
  background-position: 12px 18px;
  mix-blend-mode: multiply;
  filter: saturate(0.92) contrast(1.04);
}

/* ===== Modern Pathfinder Header ===== */
.site-header {
  overflow: visible;
  background: rgba(255, 249, 239, 0.96);
  border-bottom: 1px solid rgba(17, 21, 22, 0.18);
  box-shadow: 0 12px 32px rgba(17, 21, 22, 0.10);
  backdrop-filter: blur(12px);
}

.site-header .container.header-inner {
  width: 100%;
  max-width: none;
  padding-inline: 0;
}

.header-inner {
  gap: 0;
}

.logo {
  padding: 12px 20px 8px;
  background:
    radial-gradient(circle at 18% 0%, rgba(195, 46, 36, 0.055), transparent 28%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.98), rgba(252, 242, 227, 0.95));
}

.logo a {
  padding: 0;
}

.logo-image {
  width: min(94vw, 1180px);
  height: auto;
  max-height: 245px;
  object-fit: contain;
  object-position: center;
  filter: drop-shadow(0 5px 9px rgba(17, 21, 22, 0.09));
}

.main-nav {
  margin-top: 0;
  gap: 7px;
  padding: 10px 14px;
  background:
    linear-gradient(180deg, #181d1f 0%, #0f1314 100%);
  border-top: 1px solid rgba(195, 46, 36, 0.38);
  border-bottom: 1px solid rgba(0, 0, 0, 0.65);
}

.main-nav a {
  min-height: 38px;
  padding: 7px 13px;
  color: rgba(255, 248, 237, 0.94);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.075);
  box-shadow: none;
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: #ffffff;
  background: rgba(195, 46, 36, 0.74);
  border-color: rgba(225, 79, 67, 0.62);
  transform: translateY(-1px);
}

.main-nav a[aria-current="page"] {
  color: #ffffff;
  background: linear-gradient(180deg, #d33a2f 0%, #a70b10 100%);
  border-color: rgba(255, 127, 112, 0.44);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.site-header::after {
  min-height: 38px;
  padding: 8px 16px;
  color: rgba(255, 246, 234, 0.95);
  font-size: clamp(11px, 1.15vw, 14px);
  letter-spacing: 0.22em;
  background:
    linear-gradient(90deg,
      #79050a 0%,
      #b01014 18%,
      #c32e24 43%,
      #a8070c 62%,
      #111516 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.10);
  text-shadow: 0 1px 2px rgba(0,0,0,0.34);
}

/* ===== Brand Typography / Accents ===== */
.page-title,
.hero-text h1,
.about-header h2,
.project-card-title,
.project-detail-heading {
  color: var(--terra-charcoal);
}

.project-eyebrow,
.about-eyebrow {
  color: var(--terra-red-deep);
}

.about-eyebrow {
  background: rgba(195, 46, 36, 0.095);
}

/* ===== Buttons ===== */
.btn-primary {
  color: #fff9ef;
  background: linear-gradient(180deg, #d23a2e 0%, #a3090e 100%);
  border-color: rgba(121, 5, 10, 0.55);
  box-shadow: 0 9px 20px rgba(159, 5, 10, 0.18);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: linear-gradient(180deg, #e04b3e 0%, #b40c11 100%);
}

.btn-outline {
  color: #7f0b0d;
  background: rgba(255, 250, 243, 0.70);
  border-color: rgba(159, 5, 10, 0.25);
}

.btn-outline:hover,
.btn-outline:focus-visible {
  color: #ffffff;
  background: var(--terra-red);
  border-color: var(--terra-red-deep);
}

/* ===== Cards / Panels ===== */
.card,
.contact-form,
.contact-info,
.gallery-tile,
.service-panel,
.shop-panel,
.about-shell {
  background: rgba(255, 251, 245, 0.89);
  border-color: rgba(17, 21, 22, 0.11);
  box-shadow: 0 10px 28px rgba(17, 21, 22, 0.085);
}

.service-panel,
.gallery-tile,
.contact-form,
.contact-info {
  backdrop-filter: blur(7px);
}

/* Keep research cards visually distinct while matching the new mark. */
.project-card {
  color: rgba(255, 249, 239, 0.96);
  background:
    radial-gradient(circle at 92% 7%, rgba(195, 46, 36, 0.24), transparent 35%),
    linear-gradient(155deg, #22282a 0%, #101415 72%);
  border-color: rgba(195, 46, 36, 0.34);
  box-shadow: 0 18px 46px rgba(17, 21, 22, 0.18);
}

.project-card .project-card-title,
.project-card .project-eyebrow {
  color: #fff7ec;
}

.project-card .project-eyebrow {
  opacity: 0.78;
}

.project-card .project-status {
  color: rgba(255, 232, 222, 0.76);
}

.project-card .btn-outline {
  color: #fff8ef;
  background: rgba(255,255,255,0.055);
  border-color: rgba(255,255,255,0.18);
}

.project-card .btn-outline:hover,
.project-card .btn-outline:focus-visible {
  background: var(--terra-red);
  border-color: #df5549;
}

.project-card-media,
.project-detail-hero,
.project-photo {
  background: #111516;
}

.project-detail-hero {
  border-color: rgba(17, 21, 22, 0.16);
  box-shadow: var(--shadow-soft);
}

.project-detail-section {
  border-top-color: rgba(17, 21, 22, 0.11);
}

.content-error,
.empty-state {
  color: var(--text);
  background: rgba(255, 251, 245, 0.90);
  border-color: rgba(17, 21, 22, 0.12);
  box-shadow: var(--shadow);
}

.home-projects {
  border-top-color: rgba(195, 46, 36, 0.14);
  border-bottom-color: rgba(195, 46, 36, 0.14);
}

/* ===== About / Contact ===== */
.about {
  color: var(--text);
  background: linear-gradient(180deg, rgba(255, 249, 239, 0.36), rgba(247, 235, 218, 0.38));
}

.about-card-accent,
.about-quote {
  color: #fff8ee;
  background:
    radial-gradient(circle at 88% 8%, rgba(195, 46, 36, 0.34), transparent 38%),
    linear-gradient(145deg, #292f31 0%, #101415 100%);
  border-color: rgba(195, 46, 36, 0.30);
}

.about-card-accent h4,
.about-points li,
.about-quote strong {
  color: #fff8ee;
}

.about-quote span {
  color: rgba(255, 238, 224, 0.72);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid rgba(195, 46, 36, 0.42);
}

/* ===== Footer ===== */
.site-footer {
  color: rgba(255, 248, 237, 0.92);
  background:
    linear-gradient(135deg, #1d2224 0%, #0e1213 100%);
  border-top: 3px solid var(--terra-red-deep);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.site-footer strong {
  color: #ffffff;
}

.site-footer a {
  color: #ffd7cf;
}

/* ===== Responsive brand behavior ===== */
@media (max-width: 980px) {
  .logo-image {
    width: min(95vw, 1060px);
    height: auto;
    max-height: 215px;
  }
}

@media (max-width: 700px) {
  body::after {
    opacity: 0.052;
    background-size: 720px 720px;
  }

  .logo {
    padding: 10px 12px 6px;
  }

  .logo-image {
    width: min(96vw, 920px);
    height: auto;
    max-height: 190px;
  }

  .main-nav {
    margin-top: 0;
    padding: 9px 8px;
  }

  .site-header::after {
    min-height: 34px;
    padding: 7px 10px;
    font-size: 10px;
    letter-spacing: 0.14em;
  }
}

@media (max-width: 520px) {
  .logo-image {
    width: 98vw;
    height: auto;
    max-height: 160px;
  }

  .main-nav {
    margin-top: 0;
  }

  body::after {
    background-size: 600px 600px;
  }
}

@media (max-width: 420px) {
  .logo-image {
    width: 98vw;
    height: auto;
    max-height: 145px;
  }

  .site-header::after {
    font-size: 9px;
    letter-spacing: 0.10em;
  }
}


/* ==========================================================================\n   TERRA Website V2.4 — Standalone Destinations + Branded Masthead\n   ========================================================================== */

/* The logo now lives in a branded masthead instead of a blank white field. */
.logo {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 18px 20px 15px;
  background:
    radial-gradient(circle at 14% 40%, rgba(195, 46, 36, 0.16), transparent 29%),
    radial-gradient(circle at 88% 30%, rgba(17, 21, 22, 0.09), transparent 28%),
    linear-gradient(135deg, #fff9ef 0%, #f7e9d5 52%, #fff8ed 100%);
  border-top: 5px solid var(--terra-red-deep);
  border-bottom: 1px solid rgba(17, 21, 22, 0.16);
}

.logo::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: 0.075;
  background-image: var(--terra-background-pattern);
  background-repeat: repeat;
  background-size: 760px 760px;
  background-position: center 38%;
  mix-blend-mode: multiply;
}

.logo::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 7px;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(90deg, #111516 0%, #111516 20%, var(--terra-red) 20%, var(--terra-red) 80%, #111516 80%, #111516 100%);
  opacity: 0.92;
}

.logo a {
  position: relative;
  z-index: 2;
}

.logo-image {
  filter: drop-shadow(0 9px 14px rgba(17, 21, 22, 0.13));
}

/* Homepage now acts as a launchpad instead of containing full About/Contact pages. */
.home-destinations {
  border-top: 1px solid rgba(195, 46, 36, 0.13);
}

.destination-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 28px;
}

.destination-card {
  display: flex;
  flex-direction: column;
  min-height: 245px;
  padding: 25px;
  color: var(--text);
  text-decoration: none;
  background: rgba(255, 251, 245, 0.91);
  border: 1px solid rgba(17, 21, 22, 0.12);
  border-top: 4px solid var(--terra-red);
  border-radius: var(--radius-lg);
  box-shadow: 0 14px 34px rgba(17, 21, 22, 0.09);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  backdrop-filter: blur(8px);
}

.destination-card:hover,
.destination-card:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(195, 46, 36, 0.38);
  box-shadow: 0 22px 48px rgba(17, 21, 22, 0.14);
  outline: none;
}

.destination-card h3 {
  margin: 8px 0 8px;
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.05;
}

.destination-card p {
  margin: 0 0 22px;
  opacity: 0.84;
}

.destination-kicker {
  color: var(--terra-red-deep);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.destination-link {
  margin-top: auto;
  color: var(--terra-red-deep);
  font-weight: 900;
}

.destination-card-dark {
  color: #fff8ee;
  background:
    radial-gradient(circle at 90% 10%, rgba(195, 46, 36, 0.30), transparent 36%),
    linear-gradient(150deg, #252b2d 0%, #101415 78%);
  border-color: rgba(195, 46, 36, 0.35);
}

.destination-card-dark .destination-kicker,
.destination-card-dark .destination-link {
  color: #ffb3a7;
}

.destination-card-contact {
  grid-column: span 3;
  min-height: 190px;
  background:
    radial-gradient(circle at 10% 15%, rgba(255,255,255,0.20), transparent 28%),
    linear-gradient(112deg, #8b070b 0%, #c32e24 55%, #a80a0e 100%);
  color: #fff9f0;
  border-color: rgba(121, 5, 10, 0.55);
}

.destination-card-contact .destination-kicker,
.destination-card-contact .destination-link {
  color: #fff4e8;
}

/* Dedicated page opening treatment. */
.standalone-page-hero {
  padding-block: 48px 30px;
  border-bottom: 1px solid rgba(195, 46, 36, 0.13);
}

.standalone-page-hero .container {
  padding-block: 26px;
  border-left: 5px solid var(--terra-red);
}

.standalone-page-hero .page-title {
  max-width: 880px;
  font-size: clamp(34px, 5vw, 58px);
}

.about-page-section,
.contact-page-section {
  padding-top: 34px;
}

.contact-note {
  margin-top: 24px;
  padding: 18px;
  background: rgba(195, 46, 36, 0.08);
  border: 1px solid rgba(195, 46, 36, 0.18);
  border-radius: var(--radius-md);
}

.contact-note p {
  margin-bottom: 0;
}

.standalone-cta {
  padding-top: 0;
}

.standalone-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 28px;
  color: #fff8ee;
  background:
    radial-gradient(circle at 88% 16%, rgba(195, 46, 36, 0.28), transparent 34%),
    linear-gradient(145deg, #282e30 0%, #101415 100%);
  border: 1px solid rgba(195, 46, 36, 0.30);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}

.standalone-cta-inner h2 {
  margin: 4px 0 0;
}

.standalone-cta-inner .project-eyebrow {
  color: #ffb1a6;
}

@media (max-width: 900px) {
  .destination-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .destination-card-contact { grid-column: span 2; }
}

@media (max-width: 620px) {
  .logo { padding: 12px 10px 10px; }
  .logo::before { background-size: 620px 620px; opacity: 0.065; }
  .destination-grid { grid-template-columns: 1fr; }
  .destination-card-contact { grid-column: auto; }
  .destination-card { min-height: 210px; padding: 21px; }
  .standalone-page-hero { padding-block: 32px 18px; }
  .standalone-page-hero .container { border-left-width: 4px; }
  .standalone-cta-inner { flex-direction: column; align-items: flex-start; }
}


/* ==========================================================================
   TERRA Website V2.4.2 — Opaque Reading Surfaces + Refined Section Dividers
   Logo masthead intentionally unchanged from V2.4.1.
   ========================================================================== */

:root {
  /* Reading surfaces are now deliberately opaque. The ghost pattern belongs
     to the page background and the breathing room between content blocks. */
  --surface: #fffaf2;
  --surface-strong: #fffdf8;
}

/* Fully opaque light reading surfaces. */
.card,
.contact-form,
.contact-info,
.gallery-tile,
.service-panel,
.shop-panel,
.about-shell,
.destination-card,
.content-error,
.empty-state,
.contact-note {
  background-color: #fffaf2;
  backdrop-filter: none;
}

.card,
.contact-form,
.contact-info,
.gallery-tile,
.service-panel,
.shop-panel,
.about-shell {
  background: #fffaf2;
}

.destination-card {
  background: #fffaf2;
  backdrop-filter: none;
}

/* Preserve intentionally dark/red cards as fully opaque branded exceptions. */
.destination-card-dark {
  background:
    radial-gradient(circle at 90% 10%, #4e201f 0%, transparent 36%),
    linear-gradient(150deg, #252b2d 0%, #101415 78%);
}

.destination-card-contact {
  background:
    radial-gradient(circle at 10% 15%, #d9574c 0%, transparent 30%),
    linear-gradient(112deg, #8b070b 0%, #c32e24 55%, #a80a0e 100%);
}

.content-error,
.empty-state {
  background: #fffaf2;
}

.contact-note {
  background: #fff4ea;
}

/* Input fields should also read as solid surfaces. */
.contact-form input,
.contact-form textarea {
  background: #fffdf8;
}

/* More confident section separators without turning the page into stripes.
   A charcoal hairline + restrained TERRA-red center gives the dividers weight. */
.home-projects,
.home-destinations,
.standalone-page-hero {
  position: relative;
  border-top: 0;
  border-bottom: 0;
}

.home-projects::before,
.home-destinations::before,
.standalone-page-hero::after {
  content: "";
  position: absolute;
  left: 50%;
  width: min(92%, 1100px);
  height: 3px;
  transform: translateX(-50%);
  pointer-events: none;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(17, 21, 22, 0.18) 0%,
    rgba(17, 21, 22, 0.42) 15%,
    rgba(195, 46, 36, 0.82) 36%,
    rgba(195, 46, 36, 0.82) 64%,
    rgba(17, 21, 22, 0.42) 85%,
    rgba(17, 21, 22, 0.18) 100%
  );
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.55);
}

.home-projects::before,
.home-destinations::before {
  top: 0;
}

.standalone-page-hero::after {
  bottom: 0;
}

/* Give major content sections a small amount of extra breathing room around
   the stronger divider so the line feels architectural rather than decorative. */
.home-projects,
.home-destinations {
  padding-top: calc(var(--section-pad) + 4px);
}

/* Research/detail reading copy stays solid even when future cards are added. */
.project-detail-section {
  background: #fffaf2;
  border: 1px solid rgba(17, 21, 22, 0.11);
  border-top: 3px solid rgba(195, 46, 36, 0.56);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-top: 18px;
  box-shadow: 0 9px 24px rgba(17, 21, 22, 0.07);
}

@media (max-width: 700px) {
  .home-projects::before,
  .home-destinations::before,
  .standalone-page-hero::after {
    width: calc(100% - 36px);
    height: 2px;
  }

  .project-detail-section {
    padding: 17px;
  }
}

/* ==========================================================================
   TERRA Website V2.4.3 — Ghost Pattern Stacking Fix
   The site-wide ghost pattern belongs behind content, never over cards.
   ========================================================================== */

/* body::after is the fixed ghost-pattern layer at z-index: 0. Promote all
   primary page content above it so the pattern cannot paint across opaque
   reading surfaces. */
body > .hero,
body > .section,
body > main {
  position: relative;
  z-index: 1;
}

/* Explicit isolation keeps card backgrounds visually solid even if new
   decorative layers are added later. */
.destination-card,
.card,
.service-panel,
.shop-panel,
.about-shell,
.contact-form,
.contact-info,
.gallery-tile,
.project-detail-section {
  position: relative;
  isolation: isolate;
}

/* ==========================================================================
   TERRA Website V2.5 — Work Story system
   First full case study: Removable Pinned Bear Guard
   ========================================================================== */
.story-detail-header {
  max-width: 980px;
}

.story-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.25rem;
}

.story-meta-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0.45rem 0.75rem;
  border: 1px solid rgba(17, 21, 22, 0.13);
  border-radius: 999px;
  color: #2b3031;
  background: #fffaf2;
  box-shadow: 0 4px 12px rgba(17, 21, 22, 0.045);
  font-size: 0.78rem;
  font-weight: 760;
  letter-spacing: 0.015em;
}

.story-meta-service {
  color: #fff9f1;
  background: #22282a;
  border-color: rgba(195, 46, 36, 0.42);
}

.story-detail-hero {
  aspect-ratio: 16 / 10;
  max-height: none;
  background: #111516;
}

.story-detail-hero img {
  object-position: center center;
}

.story-section {
  max-width: 1040px;
}

.story-section-with-image {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.95fr);
  gap: 1.4rem;
  align-items: center;
}

.story-feature-image,
.story-photo,
.story-closing-image {
  margin: 0;
}

.story-feature-image .story-photo-media {
  aspect-ratio: 16 / 11;
}

.story-photo-media {
  width: 100%;
  overflow: hidden;
  border-radius: 12px;
  background: #111516;
  border: 1px solid rgba(17, 21, 22, 0.11);
}

.story-photo-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-photo-caption {
  margin-top: 0.6rem;
  color: rgba(17, 21, 22, 0.72);
  font-size: 0.84rem;
  line-height: 1.5;
}

.story-gallery-section {
  max-width: 1120px;
}

.story-photo-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.story-process-gallery .story-photo-media,
.story-final-gallery .story-photo-media {
  aspect-ratio: 4 / 5;
}

.story-final-gallery .story-photo-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.story-closing {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.9fr);
  gap: 1.5rem;
  align-items: center;
  max-width: 1120px;
  margin-top: 1.8rem;
  padding: 1.4rem;
  border: 1px solid rgba(195, 46, 36, 0.34);
  border-radius: var(--radius-md);
  color: #fff8ef;
  background:
    radial-gradient(circle at 90% 8%, rgba(195, 46, 36, 0.30), transparent 40%),
    linear-gradient(145deg, #292f31 0%, #101415 100%);
  box-shadow: 0 18px 44px rgba(17, 21, 22, 0.18);
}

.story-closing-image .story-photo-media {
  aspect-ratio: 4 / 3;
  border-color: rgba(255, 255, 255, 0.13);
}

.story-closing .story-photo-caption {
  color: rgba(255, 248, 239, 0.72);
}

.story-closing .project-eyebrow,
.story-closing .project-detail-heading,
.story-closing .project-detail-copy {
  color: #fff8ef;
}

.story-closing .project-eyebrow {
  opacity: 0.74;
}

@media (max-width: 900px) {
  .story-section-with-image,
  .story-closing {
    grid-template-columns: 1fr;
  }

  .story-final-gallery .story-photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 650px) {
  .story-detail-hero {
    aspect-ratio: 4 / 3;
  }

  .story-photo-grid,
  .story-final-gallery .story-photo-grid {
    grid-template-columns: 1fr;
  }

  .story-process-gallery .story-photo-media,
  .story-final-gallery .story-photo-media {
    aspect-ratio: 4 / 5;
  }

  .story-closing {
    padding: 1rem;
  }
}


/* ==========================================================================
   TERRA Website V2.5.1 — Work Story image-fit correction
   Preserve the full photographic frame instead of forcing case-study media
   through generic cover crops.
   ========================================================================== */

/* Story listing cards use a portrait-friendly frame so the completed object
   can be seen as a whole instead of being sliced into a generic landscape. */
#storyGrid .project-card-media {
  aspect-ratio: 3 / 4;
  display: grid;
  place-items: center;
  background: #111516;
}

#storyGrid .project-card-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
}

/* The story hero is allowed to keep its deliberate wide treatment, but we do
   not crop the source again inside that frame. */
.story-detail-hero img {
  object-fit: contain;
}

/* Fusion/design images should follow the image's own proportions. */
.story-feature-image .story-photo-media {
  aspect-ratio: auto;
}

.story-feature-image .story-photo-media img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

/* Current Bear Guard process/final photography is 3:4 portrait. Matching the
   frame to the source preserves every edge while keeping the gallery orderly. */
.story-process-gallery .story-photo-media,
.story-final-gallery .story-photo-media,
.story-closing-image .story-photo-media {
  aspect-ratio: 3 / 4;
}

.story-process-gallery .story-photo-media img,
.story-final-gallery .story-photo-media img,
.story-closing-image .story-photo-media img {
  object-fit: contain;
  object-position: center center;
}

@media (max-width: 650px) {
  .story-process-gallery .story-photo-media,
  .story-final-gallery .story-photo-media,
  .story-closing-image .story-photo-media {
    aspect-ratio: 3 / 4;
  }
}


/* ==========================================================================
   TERRA Website V2.5.2 — Work Story hero frame correction
   The Bear Guard story hero uses the complete portrait source and the frame
   follows that photograph instead of inheriting the generic wide project hero.
   ========================================================================== */

.story-detail-hero {
  width: min(100%, 720px);
  min-height: 0;
  max-height: none;
  aspect-ratio: 3 / 4;
  margin: 1.5rem auto 2.5rem;
  display: grid;
  place-items: center;
  background: #111516;
}

.story-detail-hero img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
}

@media (max-width: 650px) {
  .story-detail-hero {
    width: 100%;
    aspect-ratio: 3 / 4;
  }
}


/* ===== V2.7 Launch Candidate ===== */
.skip-link {
  position: fixed;
  left: 12px;
  top: 12px;
  z-index: 1000;
  transform: translateY(-180%);
  padding: 10px 14px;
  border-radius: 10px;
  background: #171a1b;
  color: #fff8ef;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 10px 28px rgba(0,0,0,.25);
}
.skip-link:focus { transform: translateY(0); }

.latest-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}
.latest-card {
  min-height: 330px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(72,50,34,.14);
  background: #fffaf2;
  text-decoration: none;
  box-shadow: 0 14px 32px rgba(48,31,20,.09);
  transition: transform .18s ease, box-shadow .18s ease;
}
.latest-card:hover, .latest-card:focus-visible { transform: translateY(-3px); box-shadow: 0 18px 40px rgba(48,31,20,.14); outline: none; }
.latest-card img { width:100%; height:210px; object-fit:cover; object-position:center; }
.latest-card-body { display:flex; flex-direction:column; gap:.45rem; padding:1.15rem; }
.latest-card-body strong { font-size:1.25rem; line-height:1.15; }
.latest-card-body > span:last-child { color:#65574b; }
.latest-kicker { color:#a31815; font-size:.74rem; font-weight:950; letter-spacing:.1em; text-transform:uppercase; }
.latest-card-product, .latest-card-research { justify-content:flex-end; color:#fff7ef; }
.latest-card-product { background: linear-gradient(145deg,#211b17,#5c2c22 58%,#171a1b); }
.latest-card-research { background: linear-gradient(145deg,#28231e,#455044 62%,#171a1b); }
.latest-card-product .latest-card-body > span:last-child,
.latest-card-research .latest-card-body > span:last-child { color:rgba(255,247,239,.76); }
.latest-card-product .latest-kicker,.latest-card-research .latest-kicker { color:#f1c7bb; }
.latest-product-mark { margin:auto; display:grid; place-items:center; width:120px; height:120px; border-radius:50%; border:5px solid #c21d18; font-size:4rem; font-weight:950; box-shadow:0 0 0 10px rgba(194,29,24,.16); }
.latest-research-mark { margin:auto; font-size:clamp(2.3rem,5vw,4.5rem); font-weight:950; letter-spacing:-.05em; opacity:.94; }

.product-detail-page { padding-top: 44px; }
.product-detail-hero-card {
  display:grid;
  grid-template-columns:minmax(280px,.9fr) minmax(0,1.1fr);
  overflow:hidden;
  border-radius:28px;
  border:1px solid rgba(80,64,48,.14);
  background:#fffaf2;
  box-shadow:0 20px 50px rgba(31,24,18,.11);
}
.product-detail-media { min-height:520px; display:grid; place-items:center; background:linear-gradient(145deg,#211b17,#5c2c22 55%,#171a1b); }
.product-detail-media img { width:100%; height:100%; object-fit:contain; }
.product-detail-placeholder { min-height:100%; width:100%; display:grid; place-items:center; align-content:center; gap:1rem; padding:2rem; text-align:center; color:#fff7ef; }
.product-detail-placeholder p { max-width:34ch; margin:0; color:rgba(255,247,239,.74); line-height:1.6; }
.product-detail-copy-block { padding:clamp(1.4rem,4vw,3rem); display:flex; flex-direction:column; justify-content:center; }
.product-detail-title { margin:0; font-size:clamp(2.4rem,5vw,4.7rem); line-height:.96; letter-spacing:-.055em; color:#2b241e; }
.product-detail-subtitle { margin:1rem 0 0; font-size:1.2rem; line-height:1.55; color:#54483e; font-weight:650; }
.product-detail-summary { margin:1rem 0 0; line-height:1.72; color:#5f5145; }
.product-detail-actions { display:flex; flex-wrap:wrap; gap:10px; margin-top:1.35rem; }
.product-feature-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px 26px; margin:1rem 0 0; padding-left:1.25rem; }
.product-feature-list li { line-height:1.6; }
.product-spec-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:1rem 0 0; }
.product-spec { padding:1rem; border-radius:16px; background:#fffaf2; border:1px solid rgba(80,64,48,.13); }
.product-spec dt { color:#6c5c50; font-size:.78rem; font-weight:900; letter-spacing:.06em; text-transform:uppercase; }
.product-spec dd { margin:.35rem 0 0; font-weight:850; font-size:1.05rem; }
.product-development-note { margin-top:1.3rem; padding:clamp(1.3rem,4vw,2rem); border-radius:22px; background:#171a1b; color:#fff7ef; border:1px solid rgba(194,29,24,.4); }
.product-development-note .project-detail-heading,.product-development-note .project-detail-copy { color:inherit; }
.product-development-note .project-eyebrow { color:#f1c7bb; }

.not-found-shell { max-width:850px; margin:0 auto; padding:clamp(2rem,6vw,4rem); text-align:center; border-radius:28px; background:#fffaf2; border:1px solid rgba(80,64,48,.14); box-shadow:0 18px 46px rgba(31,24,18,.1); }
.not-found-mark { width:150px; margin:0 auto 1rem; }
.not-found-shell h1 { margin:0; font-size:clamp(3rem,9vw,7rem); line-height:.9; }
.not-found-shell p { max-width:58ch; margin:1rem auto; line-height:1.7; color:#5f5145; }
.not-found-actions { display:flex; flex-wrap:wrap; justify-content:center; gap:10px; margin-top:1.3rem; }

@media (max-width: 900px) {
  .latest-grid { grid-template-columns:1fr; }
  .latest-card { min-height:0; }
  .product-detail-hero-card { grid-template-columns:1fr; }
  .product-detail-media { min-height:360px; }
  .product-spec-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width: 650px) {
  .product-feature-list,.product-spec-grid { grid-template-columns:1fr; }
  .product-detail-media { min-height:320px; }
  .product-detail-copy-block { padding:1.25rem; }
}
@media (max-width: 520px) {
  .latest-card img { height:180px; }
}

.story-closing-actions { margin-top: 1.1rem; display:flex; flex-wrap:wrap; gap:10px; }
