/* ==========================================================================
   PATTERNS — Spices of Kerala
   Layout primitives: container, section padding, alternating backgrounds,
   clean dividers (no SVG waves — borders only), grid utilities
   ========================================================================== */

/* --------------------------------------------------------------------------
   CONTAINER
   max-width 1200px, centered, fluid horizontal padding
   -------------------------------------------------------------------------- */
.container {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(20px, 5vw, 60px);
  padding-right: clamp(20px, 5vw, 60px);
}

/* Narrow container for text-heavy sections */
.container--narrow {
  max-width: 720px;
}

/* Wide container — allows slightly more breathing room */
.container--wide {
  max-width: 1400px;
}

/* --------------------------------------------------------------------------
   SECTION PADDING
   Vertical rhythm using clamp for fluid spacing
   -------------------------------------------------------------------------- */
.section {
  padding-top: clamp(48px, 8vw, 96px);
  padding-bottom: clamp(48px, 8vw, 96px);
}

.section--sm {
  padding-top: clamp(32px, 5vw, 64px);
  padding-bottom: clamp(32px, 5vw, 64px);
}

.section--lg {
  padding-top: clamp(64px, 10vw, 128px);
  padding-bottom: clamp(64px, 10vw, 128px);
}

/* --------------------------------------------------------------------------
   ALTERNATING SECTION BACKGROUNDS
   Cream and Tan in alternating sequence
   -------------------------------------------------------------------------- */
.section--cream {
  background-color: var(--color-bg);
}

.section--tan {
  background-color: var(--color-surface);
}

/* Dark plum surface — cream text, coral eyebrows, cream ornament lines */
.section--plum {
  background-color: var(--color-plum);
  color: var(--color-cream);
}

.section--plum h1,
.section--plum h2,
.section--plum h3,
.section--plum h4,
.section--plum .section__heading,
.section--plum .section-title {
  color: var(--color-cream);
}

.section--plum p,
.section--plum .section__subheading,
.section--plum .section-subtitle {
  color: rgba(245, 243, 236, 0.78);
}

.section--plum .section__eyebrow,
.section--plum .section-eyebrow {
  color: var(--color-coral);
}

.section--plum .ornament {
  color: var(--color-cream);
}

/* Sage surface — testimonials only */
.section--sage {
  background-color: var(--color-sage);
}

/* Alternate automatically when sections are siblings */
.section-sequence .section:nth-child(odd) {
  background-color: var(--color-bg);
}

.section-sequence .section:nth-child(even) {
  background-color: var(--color-surface);
}

/* --------------------------------------------------------------------------
   SECTION DIVIDERS
   Clean border-based — no wavy SVGs
   -------------------------------------------------------------------------- */

/* Simple full-width rule */
.divider {
  display: block;
  width: 100%;
  height: 1px;
  background-color: var(--color-surface);
  border: none;
  margin: 0;
}

.divider--accent {
  background-color: var(--color-accent);
  height: 2px;
}

.divider--strong {
  background-color: rgba(77, 3, 50, 0.15);
}

/* Short decorative rule, centered (used below headings) */
.divider--short {
  display: block;
  width: 48px;
  height: 2px;
  background-color: var(--color-accent);
  margin: 12px auto 0;
  border: none;
}

/* Left-aligned short rule */
.divider--short-left {
  display: block;
  width: 48px;
  height: 2px;
  background-color: var(--color-accent);
  margin: 12px 0 0;
  border: none;
}

/* Divider with text label */
.divider-text {
  display: flex;
  align-items: center;
  gap: 16px;
  color: rgba(77, 3, 50, 0.4);
  font-family: var(--font-heading);
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.divider-text::before,
.divider-text::after {
  content: '';
  flex: 1;
  height: 1px;
  background-color: var(--color-surface);
}

/* --------------------------------------------------------------------------
   2-COLUMN SPLIT LAYOUT
   Text + image halves, reverses on mobile
   -------------------------------------------------------------------------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 6vw, 80px);
  align-items: center;
}

@media (max-width: 767px) {
  .split {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}

.split--reversed {
  direction: rtl;
}

.split--reversed > * {
  direction: ltr;
}

/* --------------------------------------------------------------------------
   FLEX ROW UTILITIES
   -------------------------------------------------------------------------- */
.flex-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.flex-row--between {
  justify-content: space-between;
}

.flex-row--center {
  justify-content: center;
}

.flex-row--end {
  justify-content: flex-end;
}

/* --------------------------------------------------------------------------
   TEXT ALIGNMENT UTILITIES
   -------------------------------------------------------------------------- */
.text-center { text-align: center; }
.text-left   { text-align: left; }
.text-right  { text-align: right; }

/* --------------------------------------------------------------------------
   SPACING UTILITIES
   -------------------------------------------------------------------------- */
.mt-0  { margin-top: 0; }
.mt-sm { margin-top: 16px; }
.mt-md { margin-top: 32px; }
.mt-lg { margin-top: 48px; }

.mb-0  { margin-bottom: 0; }
.mb-sm { margin-bottom: 16px; }
.mb-md { margin-bottom: 32px; }
.mb-lg { margin-bottom: 48px; }

/* --------------------------------------------------------------------------
   VISUALLY HIDDEN (accessibility)
   -------------------------------------------------------------------------- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --------------------------------------------------------------------------
   ASPECT RATIO WRAPPERS
   -------------------------------------------------------------------------- */
.aspect-square    { aspect-ratio: 1 / 1; }
.aspect-landscape { aspect-ratio: 16 / 9; }
.aspect-portrait  { aspect-ratio: 3 / 4; }

/* --------------------------------------------------------------------------
   RESPONSIVE DISPLAY UTILITIES
   -------------------------------------------------------------------------- */
@media (max-width: 767px) {
  .hide-mobile { display: none !important; }
}

@media (min-width: 768px) {
  .hide-desktop { display: none !important; }
}

/* ==========================================================================
   MINIMAL PASS — ornament kit retired. Class names kept inert so any
   stray markup renders cleanly without decoration.
   ========================================================================== */

.jhalar,
.jhalar--flip { display: none; }

.kasavu-rule,
.kasavu-rule--center { height: 1px; background: var(--color-border); border: 0; }
.kasavu-rule--center::after { display: none; }

.arch-mask { -webkit-mask-image: none; mask-image: none; }
.arch-ring::before { display: none; }

.img-heritage,
.img-heritage img { filter: none; }
