@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,500;0,9..144,600;1,9..144,500&family=Manrope:wght@400;500;600;700&family=Space+Mono:wght@400;500&display=swap');

/* ============================================================
   SERVICES GRID WIDGET STYLES
   ============================================================ */

.sv-section {
  --sv-ivory: #f5f8fc;
  --sv-paper: #ffffff;
  --sv-line: #e9e1d2;
  --sv-ink: #1e2a24;
  --sv-ink-soft: #647065;
  --sv-emerald: #1f6f54;
  --sv-emerald-deep: #154f3c;
  --sv-gold: #c9a227;
  --sv-gold-light: #e6c665;
  --sv-coral: #e2603f;

  --sv-font-display: 'Fraunces', 'Georgia', serif;
  --sv-font-body: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --sv-font-mono: 'Space Mono', monospace;

  position: relative;
  background: var(--sv-ivory);
  color: var(--sv-ink);
  font-family: var(--sv-font-body);
  padding: clamp(56px, 8vw, 100px) 0;
  box-sizing: border-box;
}

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

/* ============================================================
   WIDTH & HEIGHT VARIATIONS (Full-Screen Edge-to-Edge Breakout)
   ============================================================ */

/* Full Screen Edge-to-Edge 100vw Breakout (Default, Full & Viewport) */
.uwe-widget--services-grid,
.sv-section,
.sv-section.sv-width-full,
.sv-section.sv-width-viewport {
  width: 100vw !important;
  position: relative !important;
  left: 50% !important;
  right: 50% !important;
  margin-left: -50vw !important;
  margin-right: -50vw !important;
  max-width: 100vw !important;
  box-sizing: border-box !important;
  overflow-x: clip;
}

/* Explicit Boxed Container Mode (when chosen in Elementor) */
.sv-section.sv-width-boxed,
.sv-section.sv-width-container {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  left: auto !important;
  right: auto !important;
}

/* Height Variations */
.sv-section.sv-height-viewport {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.sv-section.sv-height-custom,
.sv-section.sv-height-min {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* ============================================================
   WRAPPER & HEADER
   ============================================================ */

.sv-wrap {
  max-width: var(--sv-container-max-width, 1180px);
  margin: 0 auto;
  padding: 0 clamp(16px, 3vw, 32px);
  width: 100%;
  box-sizing: border-box;
}

.sv-head {
  max-width: 620px;
  margin: 0 auto 44px;
  text-align: center;
}

.sv-eyebrow {
  display: inline-block;
  font-family: var(--sv-font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sv-emerald);
  margin-bottom: 16px;
}

.sv-title {
  font-family: var(--sv-font-display);
  font-weight: 500;
  font-size: clamp(30px, 4vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.01em;
  color: var(--sv-ink);
  margin: 0;
}

.sv-title em,
.sv-title span {
  font-style: italic;
  color: var(--sv-emerald);
  font-weight: 500;
}

.sv-sub {
  margin-top: 12px;
  margin-bottom: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--sv-ink-soft);
}

/* ============================================================
   SERVICES GRID
   ============================================================ */

.sv-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

/* ============================================================
   SERVICES CARD
   ============================================================ */

.sv-card {
  position: relative;
  background: var(--sv-paper);
  border: 1px solid var(--sv-line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 14px 30px rgba(30, 42, 36, 0.05);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  opacity: 0;
  transform: translateY(18px);
}

.sv-section.sv-in-view .sv-card {
  opacity: 1;
  transform: translateY(0);
}

.sv-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 22px 44px rgba(30, 42, 36, 0.11);
  border-color: rgba(31, 111, 84, 0.28);
}

/* Numbered ticket tag, top-right corner over the photo */
.sv-card-tag {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  font-family: var(--sv-font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--sv-paper);
  background: rgba(21, 79, 60, 0.55);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  padding: 4px 9px;
  border-radius: 999px;
  line-height: 1.4;
}

/* Card photo stamp */
.sv-card-media {
  position: relative;
  width: 100%;
  height: 168px;
  overflow: hidden;
  background: var(--sv-line);
}

.sv-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.sv-card:hover .sv-card-media img {
  transform: scale(1.06);
}

/* Icon badge, overlapping the bottom edge of the photo */
.sv-card-icon {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--sv-paper);
  color: var(--sv-emerald-deep);
  box-shadow: 0 8px 18px rgba(30, 42, 36, 0.16);
  margin: -26px 0 0 22px;
  transition: transform 0.25s ease;
}

.sv-card-icon svg {
  width: 24px;
  height: 24px;
}

.sv-card:hover .sv-card-icon {
  transform: rotate(-4deg) scale(1.05);
}

/* Card Body */
.sv-card-body {
  padding: 16px 24px 24px;
}

.sv-card-title {
  font-family: var(--sv-font-display);
  font-weight: 600;
  font-size: 19.5px;
  line-height: 1.25;
  color: var(--sv-ink);
  margin: 0 0 8px;
}

.sv-card-desc {
  font-size: 14px;
  line-height: 1.65;
  color: var(--sv-ink-soft);
  margin: 0 0 18px;
}

.sv-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--sv-font-body);
  font-weight: 700;
  font-size: 13px;
  color: var(--sv-emerald);
  text-decoration: none;
}

.sv-card-link svg {
  transition: transform 0.2s ease;
}

.sv-card:hover .sv-card-link {
  color: var(--sv-emerald-deep);
}

.sv-card:hover .sv-card-link svg {
  transform: translateX(3px);
}

.sv-card:focus-within {
  outline: 2px solid var(--sv-gold);
  outline-offset: 3px;
}

/* Stagger Animation Delays */
.sv-card[data-idx="0"] { transition-delay: 0ms; }
.sv-card[data-idx="1"] { transition-delay: 70ms; }
.sv-card[data-idx="2"] { transition-delay: 140ms; }
.sv-card[data-idx="3"] { transition-delay: 210ms; }
.sv-card[data-idx="4"] { transition-delay: 280ms; }
.sv-card[data-idx="5"] { transition-delay: 350ms; }
.sv-card[data-idx="6"] { transition-delay: 420ms; }
.sv-card[data-idx="7"] { transition-delay: 490ms; }
.sv-card[data-idx="8"] { transition-delay: 560ms; }

/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */

@media (max-width: 980px) {
  .sv-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

  .sv-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .sv-card-media {
    height: 150px;
  }
}

/* ============================================================
   ACCESSIBILITY & REDUCED MOTION
   ============================================================ */

@media (prefers-reduced-motion: reduce) {
  .sv-card,
  .sv-card-icon,
  .sv-card-media img,
  .sv-card-link svg {
    transition: none !important;
  }

  .sv-card {
    opacity: 1 !important;
    transform: none !important;
  }
}
