/* ==========================================================================
   fermeloubayle.com - Home Security Systems & Smart Protection
   Global Stylesheet with Strict Responsive and Compliance Standards
   ========================================================================== */

:root {
  --color-bg-primary: #0B132B;
  --color-bg-secondary: #1C2541;
  --color-bg-tertiary: #111A35;
  --color-surface-card: #16223F;
  --color-surface-card-hover: #1E2D52;
  --color-surface-border: #2A3B66;
  --color-text-primary: #FFFFFF;
  --color-text-secondary: #CBD5E1;
  --color-text-muted: #94A3B8;
  --color-accent-yellow: #FFC107;
  --color-accent-yellow-hover: #FFB300;
  --color-accent-yellow-text: #0B132B;
  --color-accent-blue: #3A86FF;
  --color-accent-green: #10B981;
  --color-danger: #EF4444;
  --font-sans: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  --container-max-width: 1200px;
  --header-height: 80px;
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-sans);
  background-color: var(--color-bg-primary);
  color: var(--color-text-secondary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1 0 auto;
}

a {
  color: inherit;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

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

/* Container */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.25rem;
  padding-right: 1.25rem;
}

/* ==========================================================================
   HEADER & NAVIGATION DIRECTIVES (STRICT COMPLIANCE)
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--color-bg-primary);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

/* Top Utility Bar (Plain unstyled text only, light slate color, no button styling) */
.header-top-bar {
  background-color: #060B18;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.5rem 0;
  font-size: 0.875rem;
  color: #CBD5E1 !important;
}

.header-top-bar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.top-bar-left,
.top-bar-right {
  color: #CBD5E1 !important;
  font-weight: 500;
}

.top-bar-right a {
  color: #CBD5E1 !important;
  text-decoration: none;
  font-weight: 600;
}

.top-bar-right a:hover {
  color: var(--color-accent-yellow) !important;
  text-decoration: underline;
}

/* Main Navigation Bar (3-Column Desktop Alignment) */
.header-main-bar {
  background-color: var(--color-bg-primary);
  border-bottom: 1px solid var(--color-surface-border);
  padding: 0.85rem 0;
}

.header-main-bar .nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

/* 1. Left Side: Brand Logo */
.brand-logo-wrap {
  flex: 0 0 auto;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.35rem;
  font-weight: 800;
  color: #FFFFFF !important;
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand-logo .shield-icon {
  width: 28px;
  height: 28px;
  fill: var(--color-accent-yellow);
}

.brand-logo:hover {
  color: var(--color-accent-yellow) !important;
}

/* 2. Center Alignment: 5 Centered Navigation Menu Links */
.main-nav {
  flex: 1 1 auto;
  display: flex;
  justify-content: center;
}

.nav-menu-list {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

/* STRICT COLOR RULE FOR NAV LINKS */
.nav-link,
.main-nav a {
  color: #FFFFFF !important;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  padding: 0.5rem 0.25rem;
  position: relative;
  transition: color 0.2s ease;
  white-space: nowrap;
}

.nav-link:hover,
.nav-link:focus,
.nav-link.active,
.main-nav a:hover,
.main-nav a.active {
  color: #FFC107 !important;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--color-accent-yellow);
  border-radius: 2px;
}

/* 3. Right Side: STRICTLY ONE CALL CTA BUTTON */
.header-cta-wrap {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
}

.btn-primary,
.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  background-color: var(--color-accent-yellow);
  color: var(--color-accent-yellow-text) !important;
  font-weight: 700;
  font-size: 1.05rem;
  padding: 0.75rem 1.4rem;
  border-radius: 6px;
  text-decoration: none;
  transition: background-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 12px rgba(255, 193, 7, 0.25);
  border: 1px solid rgba(255, 193, 7, 0.5);
  min-height: 48px;
  cursor: pointer;
  white-space: nowrap;
}

.btn-primary:hover,
.cta-button:hover {
  background-color: var(--color-accent-yellow-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(255, 193, 7, 0.35);
  color: #000000 !important;
}

.btn-primary:active,
.cta-button:active {
  transform: translateY(0);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  background-color: transparent;
  color: #FFFFFF !important;
  font-weight: 600;
  font-size: 1.05rem;
  padding: 0.75rem 1.4rem;
  border-radius: 6px;
  text-decoration: none;
  border: 2px solid var(--color-surface-border);
  min-height: 48px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  border-color: var(--color-accent-yellow);
  color: var(--color-accent-yellow) !important;
  background-color: rgba(255, 193, 7, 0.05);
}

/* Mobile Toggle Hamburger */
.mobile-nav-toggle {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: #FFFFFF;
  min-height: 48px;
  min-width: 48px;
  align-items: center;
  justify-content: center;
}

.mobile-nav-toggle svg {
  width: 28px;
  height: 28px;
  stroke: #FFFFFF;
}

/* ==========================================================================
   HERO SECTIONS & BADGES
   ========================================================================== */

.hero-section {
  position: relative;
  padding: 4rem 0 4.5rem;
  background: linear-gradient(180deg, #0B132B 0%, #16223F 100%);
  border-bottom: 1px solid var(--color-surface-border);
  overflow: hidden;
}

.hero-split {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  align-items: center;
  gap: 3rem;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  align-self: flex-start;
  background-color: rgba(255, 193, 7, 0.12);
  border: 1px solid rgba(255, 193, 7, 0.4);
  color: var(--color-accent-yellow);
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.35rem 0.85rem;
  border-radius: 4px;
}

.hero-title,
h1 {
  font-size: 2.75rem;
  line-height: 1.15;
  font-weight: 800;
  color: #FFFFFF;
  letter-spacing: -0.02em;
}

.hero-subtitle {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--color-text-secondary);
}

.hero-cta-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.5rem;
}

.hero-disclosure-note {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
  line-height: 1.5;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-media {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid var(--color-surface-border);
}

.hero-media img {
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* ==========================================================================
   PAGE HEADERS (INTERIOR PAGES)
   ========================================================================== */

.page-hero {
  padding: 3.5rem 0;
  background: linear-gradient(180deg, #0B132B 0%, #15203D 100%);
  border-bottom: 1px solid var(--color-surface-border);
  text-align: center;
}

.page-hero h1 {
  font-size: 2.5rem;
  color: #FFFFFF;
  margin-bottom: 1rem;
}

.page-hero p {
  font-size: 1.15rem;
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
  color: var(--color-text-secondary);
}

.page-hero .cta-wrapper {
  margin-top: 1.75rem;
}

/* ==========================================================================
   CONTENT SECTIONS & HEADINGS
   ========================================================================== */

.section {
  padding: 4.5rem 0;
}

.section-alt {
  background-color: var(--color-bg-secondary);
}

.section-dark {
  background-color: #070D1F;
}

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 3rem auto;
}

.section-tag {
  display: inline-block;
  color: var(--color-accent-yellow);
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
}

.section-title,
h2 {
  font-size: 2.15rem;
  font-weight: 700;
  color: #FFFFFF;
  line-height: 1.25;
  margin-bottom: 1rem;
}

.section-desc {
  font-size: 1.1rem;
  color: var(--color-text-secondary);
}

h3 {
  font-size: 1.35rem;
  font-weight: 600;
  color: #FFFFFF;
  margin-bottom: 0.75rem;
}

/* ==========================================================================
   2-COLUMN ALTERNATING FEATURE BLOCKS
   ========================================================================== */

.feature-block-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 3.5rem;
  margin-bottom: 4.5rem;
}

.feature-block-split:last-child {
  margin-bottom: 0;
}

.feature-block-split.reverse {
  direction: rtl;
}

.feature-block-split.reverse > * {
  direction: ltr;
}

.feature-media {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--color-surface-border);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.4);
}

.feature-info {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.feature-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.feature-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  color: var(--color-text-secondary);
}

.feature-list .check-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--color-accent-yellow);
  margin-top: 2px;
}

/* ==========================================================================
   GRIDS & COMPARISON CARDS
   ========================================================================== */

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.card {
  background-color: var(--color-surface-card);
  border: 1px solid var(--color-surface-border);
  border-radius: 10px;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 193, 7, 0.5);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3);
}

.card-icon {
  width: 48px;
  height: 48px;
  background-color: rgba(255, 193, 7, 0.12);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent-yellow);
  margin-bottom: 1.25rem;
}

.comparison-card {
  background-color: var(--color-surface-card);
  border: 2px solid var(--color-surface-border);
  border-radius: 12px;
  padding: 2.25rem;
  display: flex;
  flex-direction: column;
  position: relative;
}

.comparison-card.highlight {
  border-color: var(--color-accent-yellow);
  box-shadow: 0 8px 30px rgba(255, 193, 7, 0.15);
}

.badge-featured {
  position: absolute;
  top: -14px;
  right: 24px;
  background-color: var(--color-accent-yellow);
  color: #0B132B;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
}

/* ==========================================================================
   HOTLINE BANNER / CALLOUT CONTAINERS
   ========================================================================== */

.hotline-banner {
  background: linear-gradient(135deg, #1C2541 0%, #0B132B 100%);
  border: 2px solid var(--color-accent-yellow);
  border-radius: 12px;
  padding: 2.5rem;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  margin: 3rem 0;
}

.hotline-banner h3 {
  font-size: 1.85rem;
  color: #FFFFFF;
  margin-bottom: 0.75rem;
}

.hotline-banner p {
  color: var(--color-text-secondary);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
  max-width: 650px;
  margin-left: auto;
  margin-right: auto;
}

.hotline-number-display {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 2rem;
  font-weight: 800;
  color: var(--color-accent-yellow);
  text-decoration: none;
  margin-bottom: 1rem;
}

.hotline-number-display:hover {
  text-decoration: underline;
}

/* Pre-Footer Callout Banner */
.pre-footer-banner {
  background: linear-gradient(135deg, #14203E 0%, #0B132B 100%);
  border-top: 2px solid var(--color-accent-yellow);
  border-bottom: 1px solid var(--color-surface-border);
  padding: 3.5rem 0;
  text-align: center;
}

.pre-footer-banner h2 {
  font-size: 2.25rem;
  color: #FFFFFF;
  margin-bottom: 1rem;
}

.pre-footer-banner p {
  font-size: 1.15rem;
  max-width: 700px;
  margin: 0 auto 1.75rem auto;
  color: var(--color-text-secondary);
}

/* ==========================================================================
   FOOTER NAVIGATION STRUCTURE (4 COLUMNS)
   ========================================================================== */

.site-footer {
  background-color: #060B18;
  border-top: 1px solid var(--color-surface-border);
  padding-top: 4rem;
  font-size: 0.9375rem;
  color: var(--color-text-secondary);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 3.5rem;
}

.footer-col h4 {
  font-size: 1.1rem;
  font-weight: 700;
  color: #FFFFFF;
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 32px;
  height: 2px;
  background-color: var(--color-accent-yellow);
}

.footer-links-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.footer-links-list a {
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: color 0.2s ease, transform 0.2s ease;
  display: inline-block;
}

.footer-links-list a:hover {
  color: var(--color-accent-yellow);
  transform: translateX(3px);
}

.footer-brand-desc {
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.footer-hotline-box {
  background-color: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--color-surface-border);
  padding: 1rem;
  border-radius: 6px;
  margin-bottom: 1.25rem;
}

.footer-hotline-label {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: block;
}

.footer-hotline-number {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-accent-yellow);
  text-decoration: none;
  display: block;
  margin-top: 0.25rem;
}

.footer-hotline-number:hover {
  text-decoration: underline;
}

.footer-compliance-text {
  font-size: 0.8125rem;
  line-height: 1.5;
  color: var(--color-text-muted);
}

/* Footer Bottom Bar */
.footer-bottom-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.5rem 0 2rem;
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-text-muted);
}

/* ==========================================================================
   MOBILE STICKY CALL BAR (<768px)
   ========================================================================== */

.mobile-sticky-call-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 999;
  background-color: var(--color-bg-primary);
  border-top: 2px solid var(--color-accent-yellow);
  padding: 0.75rem 1rem;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.5);
}

.mobile-sticky-call-bar a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  background-color: var(--color-accent-yellow);
  color: #0B132B !important;
  font-weight: 800;
  font-size: 1.15rem;
  padding: 0.85rem 1rem;
  border-radius: 6px;
  text-decoration: none;
  min-height: 48px;
  width: 100%;
}

/* ==========================================================================
   LEGAL & CONTENT PAGES
   ========================================================================== */

.legal-content-wrap {
  background-color: var(--color-surface-card);
  border: 1px solid var(--color-surface-border);
  border-radius: 10px;
  padding: 3rem;
  margin: 3rem auto;
  max-width: 900px;
}

.legal-content-wrap h2 {
  font-size: 1.6rem;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: #FFFFFF;
}

.legal-content-wrap p {
  margin-bottom: 1.25rem;
  color: var(--color-text-secondary);
  line-height: 1.7;
}

.legal-content-wrap ul {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
  color: var(--color-text-secondary);
}

.legal-content-wrap li {
  margin-bottom: 0.5rem;
}

/* Form Styles */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-label {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #FFFFFF;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 0.85rem 1rem;
  background-color: var(--color-bg-primary);
  border: 1px solid var(--color-surface-border);
  border-radius: 6px;
  color: #FFFFFF;
  font-family: inherit;
  font-size: 1rem;
  min-height: 48px;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--color-accent-yellow);
  box-shadow: 0 0 0 2px rgba(255, 193, 7, 0.2);
}

/* ==========================================================================
   RESPONSIVE MEDIA QUERIES (STRICT RULES)
   ========================================================================== */

@media (max-width: 992px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
  
  .grid-3 {
    grid-template-columns: 1fr 1fr;
  }
  
  .grid-4 {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  body {
    padding-bottom: 72px; /* Space for sticky bottom call bar */
  }

  .mobile-sticky-call-bar {
    display: block;
  }

  /* Header mobile adjustment */
  .header-top-bar {
    text-align: center;
  }
  
  .header-top-bar .container {
    justify-content: center;
    text-align: center;
  }
  
  .top-bar-left {
    display: none; /* Keep clean on small mobile view */
  }

  .mobile-nav-toggle {
    display: flex;
  }

  /* Mobile menu collapse */
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--color-bg-primary);
    border-bottom: 2px solid var(--color-accent-yellow);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
    padding: 1.5rem;
  }

  .main-nav.active {
    display: block;
  }

  .nav-menu-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .nav-link,
  .main-nav a {
    padding: 0.85rem 1rem;
    font-size: 1.1rem;
    border-radius: 6px;
    display: block;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }

  .nav-link:hover,
  .nav-link.active {
    background-color: rgba(255, 193, 7, 0.1);
  }

  /* Header desktop CTA button becomes mobile drawer item if needed or stays header */
  .header-cta-wrap {
    display: none; /* Handled via hamburger and sticky bottom bar on mobile to avoid clutter */
  }

  /* Force multi-column sections to stack vertically */
  .hero-split,
  .feature-block-split,
  .feature-block-split.reverse,
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
    direction: ltr !important;
  }

  .hero-title,
  h1 {
    font-size: 1.75rem !important; /* Scaled down to prevent awkward mobile wrapping */
    line-height: 1.25 !important;
  }

  .section-title,
  h2 {
    font-size: 1.5rem !important;
  }

  .hotline-number-display {
    font-size: 1.5rem;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .legal-content-wrap {
    padding: 1.5rem;
    margin: 1.5rem auto;
  }
}

@media (max-width: 480px) {
  .hero-title,
  h1 {
    font-size: 1.6rem !important;
  }

  .btn-primary,
  .btn-secondary,
  .cta-button {
    width: 100%;
    text-align: center;
  }

  .hero-cta-group {
    flex-direction: column;
    width: 100%;
  }
}
