/* === main.css — SBW Events Global Styles === */

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

:root {
  --color-green: #2D5016;
  --color-green-dark: #1E3510;
  --color-green-light: #3D6B20;
  --color-gold: #C9A84C;
  --color-gold-light: #E8D49A;
  --color-gold-dark: #A8873A;
  --color-blush: #C9889A;
  --color-blush-light: #F0DDE2;
  --color-cream: #FAF7F2;
  --color-cream-dark: #F0EBE3;
  --color-dark: #1A1A1A;
  --color-dark-2: #2A2A2A;
  --color-mid: #555555;
  --color-mid-light: #888888;
  --color-border: #E8E0D5;
  --color-white: #FFFFFF;

  --overlay-dark: rgba(26, 26, 26, 0.58);
  --overlay-green: rgba(30, 53, 16, 0.72);

  --font-display: 'Cormorant Garamond', 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', system-ui, -apple-system, sans-serif;

  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 2rem;
  --text-4xl: 2.75rem;
  --text-5xl: 3.5rem;
  --text-6xl: 4.5rem;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  --transition-fast: 150ms ease;
  --transition-base: 300ms ease;
  --transition-slow: 600ms ease;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.15);
  --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.2);

  --radius-sm: 3px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-full: 9999px;

  --container-max: 1600px;
  --container-pad: 1.25rem;
  --header-height: 140px;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--color-dark);
  background-color: var(--color-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

ul, ol { list-style: none; }

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  font-size: inherit;
}

input, textarea, select {
  font-family: inherit;
  font-size: inherit;
}

/* === Layout === */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-left: var(--container-pad);
  padding-right: var(--container-pad);
}

.section {
  padding: var(--space-16) 0;
}

.section--lg {
  padding: var(--space-20) 0;
}

.section--sm {
  padding: var(--space-10) 0;
}

.section--cream {
  background-color: var(--color-cream);
  background-image: url("data:image/svg+xml,%3Csvg width='64' height='64' viewBox='0 0 64 64' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M32 3L61 32L32 61L3 32Z' fill='none' stroke='%23C9A84C' stroke-width='0.75' stroke-opacity='0.2'/%3E%3Cpath d='M32 15L49 32L32 49L15 32Z' fill='none' stroke='%23C9A84C' stroke-width='0.5' stroke-opacity='0.15'/%3E%3C/svg%3E");
  background-size: 64px 64px;
}

/* Subtle warm gold radial wash for plain white content sections */
.section--warm {
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(201, 168, 76, 0.05) 0%, transparent 70%),
    var(--color-white);
}

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

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

/* === Typography === */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.15;
  color: var(--color-dark);
}

h1 { font-size: clamp(2.25rem, 7vw, var(--text-6xl)); }
h2 { font-size: clamp(1.9rem, 4.5vw, var(--text-5xl)); }
h3 { font-size: clamp(1.35rem, 2.5vw, var(--text-3xl)); font-weight: 500; }
h4 { font-size: var(--text-xl); font-weight: 500; }

.section-label {
  display: block;
  font-family: var(--font-body);
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: var(--space-3);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4.5vw, var(--text-5xl));
  font-weight: 400;
  color: var(--color-dark);
  margin-bottom: var(--space-4);
  line-height: 1.15;
}

.section-subtitle {
  font-size: var(--text-lg);
  color: var(--color-mid);
  max-width: 600px;
  line-height: 1.75;
}

.section-header {
  margin-bottom: var(--space-12);
}

.section-header--center {
  text-align: center;
}

.section-header--center .section-subtitle {
  margin: 0 auto;
}

.section--dark h1,
.section--dark h2,
.section--dark h3,
.section--green h1,
.section--green h2,
.section--green h3 {
  color: var(--color-white);
}

.section--dark .section-title,
.section--green .section-title {
  color: var(--color-white);
}

.section--dark .section-subtitle,
.section--green .section-subtitle {
  color: rgba(255, 255, 255, 0.75);
}

.section--dark .section-label,
.section--green .section-label {
  color: var(--color-gold-light);
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 0.875rem 2rem;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: var(--radius-sm);
  transition: all var(--transition-base);
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  border: 2px solid transparent;
  line-height: 1;
}

.btn--gold {
  background-color: var(--color-gold);
  color: var(--color-white);
  border-color: var(--color-gold);
}
.btn--gold:hover, .btn--gold:focus-visible {
  background-color: var(--color-gold-dark);
  border-color: var(--color-gold-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn--gold-outline {
  background-color: transparent;
  color: var(--color-gold);
  border-color: var(--color-gold);
}
.btn--gold-outline:hover, .btn--gold-outline:focus-visible {
  background-color: var(--color-gold);
  color: var(--color-white);
}

.btn--white {
  background-color: var(--color-white);
  color: var(--color-dark);
  border-color: var(--color-white);
}
.btn--white:hover, .btn--white:focus-visible {
  background-color: transparent;
  color: var(--color-white);
}

.btn--white-outline {
  background-color: transparent;
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.8);
}
.btn--white-outline:hover, .btn--white-outline:focus-visible {
  background-color: var(--color-white);
  color: var(--color-dark);
  border-color: var(--color-white);
}

.btn--green {
  background-color: var(--color-green);
  color: var(--color-white);
  border-color: var(--color-green);
}
.btn--green:hover, .btn--green:focus-visible {
  background-color: var(--color-green-dark);
  border-color: var(--color-green-dark);
}

.btn--lg {
  padding: 1.125rem 2.5rem;
  font-size: var(--text-base);
}

.btn-group {
  display: flex;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.btn-group--center {
  justify-content: center;
}

/* === Scroll reveal (classes added/removed by main.js) === */
/* Uses the standalone `translate` property so it never fights a component's
   own `transform` hover effects. `html` prefix out-ranks component rules
   (e.g. `.service-card { transition: … }` in cards.css, loaded later). */
html .reveal {
  opacity: 0;
  translate: 0 24px;
}

/* Transition lives on the reveal-in state only, so hiding is instant
   (no fade-out when main.js first tags below-the-fold content) */
html .reveal.is-revealed {
  opacity: 1;
  translate: none;
  transition:
    opacity 0.7s ease var(--reveal-delay, 0ms),
    translate 0.7s cubic-bezier(0.2, 0.65, 0.3, 1) var(--reveal-delay, 0ms);
}

@media (prefers-reduced-motion: reduce) {
  html .reveal {
    opacity: 1;
    translate: none;
    transition: none;
  }
}

/* === Page Hero (non-slider) === */
.page-hero {
  position: relative;
  height: auto;
  min-height: 45vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background-color: var(--color-green-dark);
  /* Extends behind fixed header so transparent nav shows dark bg on sub-pages */
  padding-top: var(--header-height);
}

.page-hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.45;
}

.page-hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 0 var(--container-pad);
}

.page-hero__content h1 {
  color: var(--color-white);
  margin-bottom: var(--space-4);
}

.breadcrumb {
  color: rgba(255, 255, 255, 0.65);
  font-size: var(--text-sm);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  justify-content: center;
}

.breadcrumb a {
  color: var(--color-gold-light);
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.breadcrumb__sep {
  opacity: 0.5;
}

/* === Gold Divider === */
.gold-divider {
  width: 56px;
  height: 3px;
  background: linear-gradient(90deg, var(--color-gold), var(--color-gold-light));
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-6);
}

.gold-divider--left {
  margin-left: 0;
}

/* === CTA Banner === */
.cta-banner {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, var(--color-green) 0%, var(--color-green-dark) 100%);
  padding: var(--space-20) 0;
  text-align: center;
}

.cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23C9A84C' fill-opacity='0.06'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/svg%3E");
}

.cta-banner__inner {
  position: relative;
  z-index: 1;
}

.cta-banner h2 {
  color: var(--color-white);
  margin-bottom: var(--space-4);
}

.cta-banner p {
  color: rgba(255, 255, 255, 0.8);
  font-size: var(--text-lg);
  margin-bottom: var(--space-8);
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

/* === Intro Strip === */
.intro-strip {
  padding: var(--space-16) 0;
  background:
    radial-gradient(ellipse 70% 90% at 50% 50%, rgba(201, 168, 76, 0.07) 0%, transparent 70%),
    var(--color-cream);
  position: relative;
  overflow: hidden;
}

/* Large concentric diamond ornament watermark — South Asian geometric motif */
.intro-strip::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(480px, 90vw);
  aspect-ratio: 1;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 280 280' xmlns='http://www.w3.org/2000/svg' fill='none' stroke='%23C9A84C'%3E%3Cpath d='M140 6L274 140L140 274L6 140Z' stroke-width='1.5' stroke-opacity='.8'/%3E%3Cpath d='M140 36L244 140L140 244L36 140Z' stroke-width='1' stroke-opacity='.6'/%3E%3Cpath d='M140 66L214 140L140 214L66 140Z' stroke-width='.8' stroke-opacity='.5'/%3E%3Cpath d='M140 96L184 140L140 184L96 140Z' stroke-width='.7' stroke-opacity='.5'/%3E%3Ccircle cx='140' cy='140' r='14' stroke-width='.8' stroke-opacity='.5'/%3E%3Cline x1='140' y1='6' x2='140' y2='274' stroke-width='.5' stroke-opacity='.3'/%3E%3Cline x1='6' y1='140' x2='274' y2='140' stroke-width='.5' stroke-opacity='.3'/%3E%3Ccircle cx='140' cy='6' r='3.5' fill='%23C9A84C' fill-opacity='.6'/%3E%3Ccircle cx='274' cy='140' r='3.5' fill='%23C9A84C' fill-opacity='.6'/%3E%3Ccircle cx='140' cy='274' r='3.5' fill='%23C9A84C' fill-opacity='.6'/%3E%3Ccircle cx='6' cy='140' r='3.5' fill='%23C9A84C' fill-opacity='.6'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  opacity: 0.06;
  pointer-events: none;
}

.intro-strip__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 780px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.intro-strip__text h2 {
  margin-bottom: var(--space-4);
}

.intro-strip__text p {
  color: var(--color-mid);
  font-size: var(--text-lg);
  line-height: 1.75;
}

/* === Recent Work Grid === */
.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: 240px;
  gap: 4px;
}

/* When grid is a direct child of .section (full-bleed, outside .container) */
.section > .work-grid {
  margin-top: var(--space-10);
}

.work-grid__item {
  position: relative;
  overflow: hidden;
  background-color: var(--color-cream-dark);
}

.work-grid__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.work-grid__item:hover img {
  transform: scale(1.04);
}

/* === Related Reading (service pages → blog) === */
.related-reading .section-header {
  margin-bottom: var(--space-8);
}

.related-reading__list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-4);
  max-width: 900px;
  margin: 0 auto;
}

.related-reading__list li {
  flex: 1 1 280px;
  max-width: 440px;
}

.related-reading__link {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  height: 100%;
  padding: var(--space-6);
  background: var(--color-white);
  border: 1px solid var(--color-border);
  border-top: 2px solid var(--color-gold-light);
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: box-shadow var(--transition-base), transform var(--transition-base);
}

.related-reading__link:hover,
.related-reading__link:focus-visible {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.related-reading__title {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  line-height: 1.25;
  color: var(--color-dark);
}

.related-reading__more {
  margin-top: auto;
  font-size: var(--text-xs);
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-gold-dark);
}

/* === Text utilities === */
.text-center { text-align: center; }
.text-gold { color: var(--color-gold); }
.text-green { color: var(--color-green); }
.text-white { color: var(--color-white); }
.text-mid { color: var(--color-mid); }

/* === Animations === */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeIn 0.7s ease both;
}

.fade-in--delay-1 { animation-delay: 0.2s; }
.fade-in--delay-2 { animation-delay: 0.4s; }
.fade-in--delay-3 { animation-delay: 0.6s; }

/* === Responsive === */
@media (min-width: 640px) {
  .work-grid {
    grid-auto-rows: 320px;
  }
}

@media (min-width: 768px) {
  :root {
    --container-pad: 2rem;
    --header-height: 140px;
  }

  .page-hero {
    min-height: 55vh;
  }
}

@media (min-width: 1024px) {
  .section { padding: var(--space-20) 0; }
  .section--lg { padding: var(--space-32) 0; }

  .work-grid {
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 380px;
    gap: 6px;
  }
}

@media (min-width: 1280px) {
  :root { --container-pad: 2rem; }
}
