/* =============================================
   LIFESTYLE WINDOWS — DIVI 5 OVERRIDES
   File: assets/css/lsw-divi-overrides.css
   Corrects Divi 5 defaults that conflict with
   the LSW design system.
   ============================================= */

/* ─────────────────────────────────────────────
   DIVI 5 SECTION / ROW / MODULE RESETS
   ───────────────────────────────────────────── */

/* Remove Divi's default section padding — we control this via lsw-section */
.et_pb_section {
  padding: 0 !important;
}

/* Remove Divi row width constraints and padding */
.et_pb_row {
  max-width: none !important;
  padding-right: 0 !important;
  padding-left: 0 !important;
  width: 100% !important;
}

/* Remove Divi module bottom margins */
.et_pb_module {
  margin-bottom: 0 !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 TYPOGRAPHY OVERRIDES
   ───────────────────────────────────────────── */

/* Force our font family — Divi loads its own */
body,
.et_pb_module,
.et_pb_text,
.et_pb_blurb,
.et_pb_button {
  font-family: var(--font-body) !important;
}

h1, h2, h3, h4, h5, h6,
.et_pb_module h1,
.et_pb_module h2,
.et_pb_module h3,
.et_pb_module h4 {
  font-family: var(--font-display) !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 BUTTON OVERRIDES
   ───────────────────────────────────────────── */

/* Reset Divi button styles when using our .lsw-btn class */
.lsw-btn.et_pb_button,
.et_pb_button.lsw-btn {
  padding: 0.85rem 1.75rem !important;
  font-size: var(--text-sm) !important;
  font-family: var(--font-body) !important;
  border-radius: var(--radius-md) !important;
  text-transform: none !important;
  letter-spacing: 0.02em !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 NAVIGATION OVERRIDES
   ───────────────────────────────────────────── */

/* Ensure Divi nav doesn't override our header spacing */
#et-top-navigation {
  padding: 0 !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 BLOG MODULE OVERRIDES
   ───────────────────────────────────────────── */

.et_pb_posts .et_pb_post {
  background: var(--lsw-white) !important;
  border-radius: var(--radius-lg) !important;
  box-shadow: var(--shadow-card) !important;
  border: 1px solid var(--lsw-border) !important;
  overflow: hidden !important;
  margin-bottom: var(--gap-md) !important;
  transition: var(--transition-base) !important;
}

.et_pb_posts .et_pb_post:hover {
  box-shadow: var(--shadow-lg) !important;
  transform: translateY(-3px) !important;
}

.et_pb_posts .post-content {
  padding: var(--space-5) !important;
}

.et_pb_posts h2.entry-title a {
  font-family: var(--font-display) !important;
  font-size: var(--text-xl) !important;
  color: var(--lsw-navy) !important;
  font-weight: 600 !important;
  text-decoration: none !important;
}

.et_pb_posts h2.entry-title a:hover {
  color: var(--lsw-amber) !important;
}

.et_pb_posts .post-meta {
  font-size: var(--text-xs) !important;
  color: var(--lsw-slate-lt) !important;
}

.et_pb_posts .et_pb_read_more {
  font-size: var(--text-sm) !important;
  font-weight: 600 !important;
  color: var(--lsw-amber) !important;
  background: none !important;
  border: none !important;
  padding: 0 !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 GALLERY MODULE OVERRIDES
   ───────────────────────────────────────────── */

.et_pb_gallery .et_pb_gallery_image {
  border-radius: var(--radius-lg) !important;
  overflow: hidden !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 MOBILE MENU OVERRIDES
   ───────────────────────────────────────────── */

/* We use our own mobile menu — hide Divi's if it appears */
.et_mobile_nav_menu .et_toggle_slide_menu {
  display: none;
}

/* ─────────────────────────────────────────────
   DIVI 5 FULL-WIDTH SECTION SUPPORT
   ───────────────────────────────────────────── */

/* Full-width Divi sections should not add inner padding */
.et_pb_fullwidth_section {
  padding: 0 !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 CODE MODULE
   ───────────────────────────────────────────── */

/* Code modules inherit our design — remove Divi's pre styling */
.et_pb_code_inner {
  font-family: inherit !important;
  font-size: inherit !important;
  color: inherit !important;
  background: none !important;
  padding: 0 !important;
}

/* ─────────────────────────────────────────────
   DIVI 5 WOOCOMMERCE (future)
   ───────────────────────────────────────────── */

/* Placeholder for WooCommerce integration if needed */
.woocommerce .button,
.woocommerce button.button {
  background: var(--lsw-amber) !important;
  color: var(--lsw-navy) !important;
  border-radius: var(--radius-md) !important;
  font-family: var(--font-body) !important;
  font-weight: 600 !important;
}

/* ─────────────────────────────────────────────
   STICKY HEADER STATE
   ───────────────────────────────────────────── */

.lsw-header.is-scrolled {
  box-shadow: 0 2px 20px rgba(14, 27, 46, 0.12);
}

/* Prevent body jump when sticky header activates */
body.lsw-has-sticky-header {
  padding-top: var(--lsw-header-height, 80px);
}

/* ─────────────────────────────────────────────
   PRINT STYLES
   ───────────────────────────────────────────── */

@media print {
  .lsw-hero__bg,
  .lsw-cta-banner,
  .lsw-calc-inline-cta,
  nav,
  footer {
    display: none !important;
  }
  body {
    font-size: 12pt !important;
    color: #000 !important;
    background: #fff !important;
  }
}
