/* RMP Farms – BASS-inspired editorial */

:root {
  --color-text: #0a0a0a;
  --color-text-muted: #444;
  --color-border: #e0e0e0;
  --color-bg: #fdfdfc;
  --color-white: #fff;
  --font-sans: "DM Sans", system-ui, sans-serif;
  --font-display: "Playfair Display", Georgia, serif;
  --space-sm: 0.5rem;
  --space: 1.5rem;
  --space-lg: 3rem;
  --space-xl: 5rem;
  --space-2xl: 8rem;
  --max-width: 900px;
  --header-h: 64px;
}

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

html {
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  overflow-x: hidden;
}
html::-webkit-scrollbar { display: none; }

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text);
  background: var(--color-bg);
  overflow-x: hidden;
  width: 100%;
  min-width: 100%;
}

main { position: relative; z-index: 1; }

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

/* Header – minimal */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-lg);
  z-index: 100;
  transition: background 0.2s;
}

.site-header.transparent { background: transparent; }
.site-header.scrolled { background: var(--color-white); border-bottom: 1px solid var(--color-border); }

.site-header .logo {
  height: 64px;
  width: auto;
  margin-left: -16px;
  transition: transform 0.25s ease, filter 0.25s ease;
}
.site-header.transparent .logo { filter: brightness(0) invert(1) blur(1px); }
.site-header.scrolled .logo { filter: none; }
.site-header.transparent .logo:hover {
  transform: scale(1.08);
  filter: brightness(0) invert(1) blur(0.5px);
}
.site-header.scrolled .logo:hover {
  transform: scale(1.08);
  filter: none;
}

.nav-toggle {
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  background: none;
  border: none;
  cursor: pointer;
  transition: transform 0.25s ease, filter 0.25s ease;
}
.site-header.transparent .nav-toggle {
  color: var(--color-white);
  text-shadow: 0 0 20px rgba(255,255,255,0.5);
  filter: blur(1px);
}
.site-header.scrolled .nav-toggle { color: var(--color-text); filter: none; }
.site-header.transparent .nav-toggle:hover {
  transform: scale(1.12);
  filter: blur(0.5px);
}
.site-header.scrolled .nav-toggle:hover {
  transform: scale(1.12);
  filter: none;
}

/* Sidebar – dark, editorial */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 101;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.nav-overlay.open { opacity: 1; pointer-events: auto; }

.nav-sidebar {
  position: fixed;
  top: 0; right: 0;
  width: 320px;
  max-width: 90vw;
  height: 100%;
  background: var(--color-text);
  z-index: 102;
  padding: calc(var(--header-h) + var(--space-lg)) var(--space-lg) var(--space-lg);
  transform: translateX(100%);
  transition: transform 0.35s ease;
}
.nav-sidebar.open { transform: translateX(0); }

.nav-sidebar .nav-close {
  position: absolute;
  top: var(--space);
  right: var(--space-lg);
  font-size: 1.5rem;
  color: var(--color-white);
  background: none;
  border: none;
  cursor: pointer;
  opacity: 0.8;
}
.nav-sidebar .nav-close:hover { opacity: 1; }

.nav-sidebar a {
  display: block;
  padding: var(--space-sm) 0;
  color: var(--color-white);
  font-size: 1rem;
  letter-spacing: 0.03em;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  transition: opacity 0.2s;
}
.nav-sidebar a:last-of-type { border-bottom: none; }
.nav-sidebar a:hover { opacity: 0.8; }

/* Hero – fixed video background */
.hero-video {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 0;
}
.hero-video video {
  position: absolute;
  top: 50%; left: 50%;
  min-width: 100%; min-height: 100%;
  transform: translate(-50%, -50%);
  object-fit: cover;
  filter: blur(12px);
}
.hero-video::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.4);
}

/* Fixed text layers – smooth vertical crossfade on scroll */
.hero-content {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  text-align: center;
  padding: 0 var(--space);
  width: 100%;
  pointer-events: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.practice-overlay {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, calc(-50% + 80px));
  z-index: 2;
  text-align: center;
  padding: 0 var(--space);
  width: 100%;
  max-width: 640px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.practice-overlay-label {
  display: block;
  font-size: 3rem;
  font-weight: 700;
  filter: blur(0.6px);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.95);
  margin-bottom: var(--space);
}
.practice-overlay-text {
  font-size: clamp(1.35rem, 2.2vw, 1.65rem);
  line-height: 1.8;
  color: var(--color-white);
  text-shadow: 0 2px 20px rgba(0,0,0,0.5);
  filter: blur(0.8px);
}

/* Video fade overlay – controlled by JS */
.video-fade {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: var(--color-bg);
  z-index: 1;
  opacity: 0;
  pointer-events: none;
}

/* Parallax scroll spacers */
.parallax-scroll { position: relative; z-index: -1; }
.parallax-spacer { height: 100vh; }
.parallax-spacer-short { height: 80vh; }

/* Static content after video */
.static-content {
  position: relative;
  z-index: 3;
  background: var(--color-bg);
}

/* Mobile: comfortable side padding in static section (after video fades) */
@media (max-width: 768px) {
  .static-content .section,
  .static-content .cta-section {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }
  .static-content .section {
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
  }
  .static-content .cta-section {
    padding-top: 2.5rem;
    padding-bottom: 2.5rem;
  }
  .static-content .cf-content,
  .static-content .cf-hero-overlay {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }
}

/* Intro text above cards */
.ops-intro {
  color: var(--color-text-muted);
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  line-height: 1.75;
  max-width: 600px;
  margin-bottom: var(--space-xl);
  margin-left: 0;
  margin-right: auto;
}

.ops-header {
  max-width: 600px;
  margin: 0;
}

/* Auto-scrolling marquee cards */
.marquee {
  overflow: hidden;
  padding: var(--space-lg) 0;
}

.marquee-track {
  display: flex;
  gap: var(--space-lg);
  width: max-content;
  animation: marquee 30s linear infinite;
}

.marquee:hover .marquee-track {
  animation-play-state: paused;
}

@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.card {
  flex: 0 0 420px;
  background: var(--color-white);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 16px rgba(0,0,0,0.06);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.card:hover {
  box-shadow: 0 8px 30px rgba(0,0,0,0.1);
  transform: translateY(-4px);
}

.card img {
  width: 100%;
  height: 260px;
  object-fit: cover;
}

.card h3 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--color-text);
  padding: var(--space-lg) var(--space-lg) var(--space-sm);
}

.card p {
  font-size: 1rem;
  color: var(--color-text-muted);
  line-height: 1.7;
  padding: 0 var(--space-lg) var(--space-lg);
}

/* Marquee arrows – visible only on mobile, translucent */
.marquee-wrap {
  position: relative;
}
.marquee-arrow {
  display: none;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: opacity 0.2s ease;
  opacity: 0.9;
}
.marquee-arrow:hover {
  opacity: 1;
}
.marquee-arrow:active {
  opacity: 0.8;
}
.marquee-arrow::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 10px;
  height: 10px;
  border-style: solid;
  border-color: rgba(10, 10, 10, 0.7);
}
.marquee-arrow-prev {
  left: 0.5rem;
}
.marquee-arrow-prev::after {
  border-width: 2px 0 0 2px;
  transform: rotate(-45deg);
  margin-left: 6px;
}
.marquee-arrow-next {
  right: 0.5rem;
}
.marquee-arrow-next::after {
  border-width: 2px 0 0 2px;
  transform: rotate(135deg);
  margin-right: 6px;
}

/* Mobile: card carousel (one card at a time, no scroll) + arrows */
@media (max-width: 768px) {
  .marquee-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .marquee-wrap {
    padding: 0 0.5rem;
  }
  .marquee {
    overflow: hidden;
  }
  .marquee-track {
    animation: none;
    width: 400%;
    display: flex;
    gap: 0;
    transition: transform 0.4s ease;
    will-change: transform;
  }
  .marquee-track .card {
    flex: 0 0 25%;
    box-sizing: border-box;
  }
  .marquee-track .card:nth-child(n+5) {
    display: none;
  }
  .card img {
    height: 200px;
  }
  .card h3 {
    font-size: 1.2rem;
    padding: var(--space) var(--space) var(--space-sm);
  }
  .card p {
    font-size: 0.95rem;
    padding: 0 var(--space) var(--space);
  }
}

/* Contract Farming section */
.cf-section {
  background: var(--color-bg);
}

.cf-hero {
  position: relative;
  width: 100%;
  min-height: 70vh;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.cf-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cf-hero-overlay {
  position: relative;
  z-index: 1;
  padding: var(--space-2xl) var(--space-xl);
  max-width: 600px;
}

.cf-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0.2) 60%, transparent 100%);
  z-index: 0;
}

.cf-heading {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.25rem);
  font-weight: 400;
  color: var(--color-white);
  line-height: 1.2;
  margin-bottom: var(--space-lg);
}

.cf-link {
  color: var(--color-white);
  border-color: rgba(255,255,255,0.8);
}
.cf-link:hover { opacity: 0.8; }
.cf-link::after { content: " +"; }

.cf-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  padding: var(--space-2xl) var(--space-xl);
  align-items: start;
}

.cf-body {
  max-width: 500px;
}

.cf-body p {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  color: var(--color-text-muted);
  line-height: 1.8;
  margin-bottom: var(--space);
}

.cf-body .link-plus {
  margin-top: var(--space);
}

/* Carousel */
.cf-carousel {
  position: relative;
  background: none;
  min-height: 320px;
  overflow: hidden;
}

.cf-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  padding: 0;
  padding-bottom: 50px;
  opacity: 0;
  transition: opacity 0.8s ease;
  pointer-events: none;
}

.cf-slide-active {
  opacity: 1;
  pointer-events: auto;
  position: relative;
}

.cf-step-num {
  display: block;
  font-family: var(--font-display);
  font-size: 3rem;
  font-weight: 400;
  color: var(--color-border);
  margin-bottom: var(--space-sm);
}

.cf-slide h3 {
  font-family: var(--font-display);
  font-size: 1.65rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: var(--space);
}

.cf-slide p {
  font-size: 1.1rem;
  color: var(--color-text-muted);
  line-height: 1.75;
}

.cf-dots {
  position: absolute;
  bottom: 0;
  left: 0;
  display: flex;
  gap: 8px;
}

.cf-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--color-border);
  cursor: pointer;
  padding: 0;
  transition: background 0.25s, width 0.25s;
}

.cf-dot-active {
  width: 24px;
  border-radius: 4px;
  background: var(--color-text);
}

@media (max-width: 768px) {
  .cf-hero { min-height: 50vh; }
  .cf-hero-overlay { padding: var(--space-xl) var(--space-lg); }
  .cf-hero::after { background: linear-gradient(180deg, transparent 20%, rgba(0,0,0,0.8) 100%); }
  .cf-content { grid-template-columns: 1fr; padding: var(--space-xl) var(--space-lg); }
  .cf-carousel { min-height: 350px; }
}

/* Get in Touch CTA */
.cta-section {
  text-align: center;
  padding: var(--space-2xl) var(--space-lg);
  background: var(--color-text);
}

.cta-heading {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 400;
  color: var(--color-white);
  margin-bottom: var(--space);
}

.cta-text {
  font-size: clamp(1rem, 1.2vw, 1.1rem);
  color: rgba(255,255,255,0.7);
  line-height: 1.75;
  max-width: 500px;
  margin: 0 auto var(--space-lg);
}

.cta-btn {
  display: inline-block;
  padding: 0.85rem 2rem;
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  color: var(--color-text);
  background: var(--color-white);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.cta-btn:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(4rem, 14vw, 8rem);
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin-bottom: var(--space);
  text-shadow: 0 0 30px rgba(255,255,255,0.6), 0 0 60px rgba(255,255,255,0.4), 0 0 90px rgba(255,255,255,0.3);
  filter: blur(1px);
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: rgba(255,255,255,0.95);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 600;
  text-shadow: 0 0 20px rgba(255,255,255,0.5), 0 0 40px rgba(255,255,255,0.3);
  filter: blur(1px);
}

/* Editorial sections – BASS style */
.section {
  padding: var(--space-2xl) var(--space-lg);
  background: var(--color-bg);
  position: relative;
  z-index: 1;
}

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.section-label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: var(--space);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 400;
  color: var(--color-text);
  line-height: 1.3;
  margin-bottom: var(--space);
}

/* Text link – "read more +" style */
.link-plus {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  color: var(--color-text);
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  transition: opacity 0.2s;
}
.link-plus:hover { opacity: 0.6; }
.link-plus::after { content: " +"; }

/* Practice block */
.practice {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: var(--space-xl);
  align-items: start;
}
@media (max-width: 768px) { .practice { grid-template-columns: 1fr; gap: var(--space); } }

.practice-text {
  font-size: clamp(1rem, 1.15vw, 1.1rem);
  color: var(--color-text-muted);
  line-height: 1.75;
}

/* Products / intro block */
.products-img {
  width: 100%;
  margin: 0 0 var(--space-xl);
}

.products-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: start;
}
@media (max-width: 768px) { .products-split { grid-template-columns: 1fr; } }

.products-split p {
  color: var(--color-text-muted);
  margin-bottom: var(--space);
}

/* Contract banner */
.contract-banner img {
  width: 100%;
  transition: opacity 0.3s;
}
.contract-banner a:hover img { opacity: 0.92; }

/* Contact CTA */
.contact-cta {
  text-align: center;
  max-width: 480px;
  margin: 0 auto;
}
.contact-cta p { color: var(--color-text-muted); margin-bottom: var(--space-lg); }

/* Footer – BASS-style columns */
.site-footer {
  background: var(--color-text);
  color: var(--color-white);
  padding: var(--space-xl) var(--space-lg);
}

.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--space-xl);
  align-items: end;
}
@media (max-width: 600px) { .footer-inner { grid-template-columns: 1fr; } }

.footer-nav a {
  display: inline-block;
  margin-right: var(--space-lg);
  margin-bottom: var(--space-sm);
  color: rgba(255,255,255,0.8);
  font-size: 0.9rem;
}
.footer-nav a:hover { color: var(--color-white); }

.footer-credit {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
}
.footer-credit a { color: rgba(255,255,255,0.8); }
.footer-credit a:hover { color: var(--color-white); }

/* Page hero (subpages) */
.page-hero {
  padding-top: calc(var(--header-h) + var(--space-2xl));
  padding-bottom: var(--space-xl);
}

/* Operations page – alternating layout */
.ops-item {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: var(--space-xl);
  align-items: center;
  margin-bottom: var(--space-2xl);
}
@media (max-width: 768px) {
  .ops-item { grid-template-columns: 1fr; }
  .ops-item:nth-child(even) .ops-img { order: -1; }
}

.ops-item .section-label { display: block; margin-bottom: var(--space-sm); }

.ops-item h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 1.9rem);
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: var(--space-sm);
}

.ops-item p { color: var(--color-text-muted); font-size: 0.95rem; }

.ops-img img { width: 100%; }

/* Contract page */
.contract-hero {
  position: relative;
  margin: calc(var(--header-h) + var(--space-lg)) 0 var(--space-2xl);
}
.contract-hero img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  display: block;
}
.contract-hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: var(--space-xl);
  background: linear-gradient(90deg, rgba(0,0,0,0.6) 0%, transparent 70%);
}
.contract-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 400;
  color: var(--color-white);
  margin-bottom: var(--space);
}
.contract-hero .link-plus { color: var(--color-white); border-color: rgba(255,255,255,0.8); }
.contract-hero .link-plus:hover { opacity: 0.85; }

@media (max-width: 768px) {
  .contract-hero-content {
    background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,0.8) 100%);
    justify-content: flex-end;
  }
}

.contract-intro {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  line-height: 1.75;
  margin-bottom: var(--space-2xl);
}

.contract-steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}
@media (max-width: 768px) { .contract-steps { grid-template-columns: 1fr; } }

.contract-step {
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--color-border);
}
.contract-step:last-child { border-bottom: none; }

.contract-step h3 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: var(--space-sm);
}

.contract-step p { color: var(--color-text-muted); font-size: 0.95rem; }

.contract-why {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.contract-cta { text-align: center; margin: var(--space-xl) 0; }

/* Contact page */
.contact-hero {
  text-align: center;
  margin-bottom: var(--space-2xl);
}
.contact-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: var(--space);
}
.contact-hero > p {
  color: var(--color-text-muted);
  max-width: 520px;
  margin: 0 auto;
  font-size: 1.05rem;
}

.contact-details {
  max-width: 400px;
  margin: 0 auto;
  text-align: center;
}
.contact-details p { margin: var(--space-sm) 0; }
.contact-details a { color: var(--color-text); border-bottom: 1px solid currentColor; padding-bottom: 1px; }
.contact-details a:hover { opacity: 0.7; }
.contact-details .address {
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
}

/* Reveal */
.reveal { opacity: 0; transform: translateY(16px); transition: 0.5s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }
