/* CSS Variables */
:root {
  --primary: #D4AF37;
  --primary-foreground: #1A1A2E;
  --secondary: #B8860B;
  --secondary-foreground: #FFFFFF;
  --accent: #F5DEB3;
  --accent-foreground: #1A1A2E;
  --background: #1A1A2E;
  --foreground: #EAEAEA;
  --card: #16213E;
  --card-foreground: #EAEAEA;
  --border: #2C2C54;
  --input: #2C2C54;
  --ring: #D4AF37;
  --muted: #16213E;
  --muted-foreground: #A0A0B0;
  --font-family: 'Open Sans', sans-serif;
  --radius: 0.25rem;
}

/* Global Styles */
* {
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  background: var(--background);
  color: var(--foreground);
  margin: 0;
  padding: 0;
  line-height: 1.6;
  overflow-wrap: break-word;
}

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

/* Utility Classes */
.hidden {
  display: none !important;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.text-primary {
  color: var(--primary);
}

.text-muted {
  color: var(--muted-foreground);
}

.text-lg {
  font-size: 1.125rem;
}

.text-sm {
  font-size: 0.875rem;
}

.font-medium {
  font-weight: 500;
}

.font-semibold {
  font-weight: 600;
}

.mb-4 {
  margin-bottom: 1rem;
}

/* Grid Layouts */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

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

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

/* Icons */
.icon-sm {
  width: 1rem;
  height: 1rem;
}

.icon-md {
  width: 1.5rem;
  height: 1.5rem;
}

.icon-lg {
  width: 2rem;
  height: 2rem;
}

.icon-xl {
  width: 3rem;
  height: 3rem;
}

.icon-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  background: rgba(212, 175, 55, 0.1);
  border-radius: 50%;
  margin-bottom: 1rem;
}

/* Buttons */
.btn-primary {
  background: var(--primary);
  color: var(--primary-foreground);
  border: 2px solid var(--primary);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  text-decoration: none;
  display: inline-block;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  font-size: 1rem;
}

.btn-primary:hover {
  background: var(--secondary);
  border-color: var(--secondary);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.3);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  text-decoration: none;
  display: inline-block;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  font-size: 1rem;
}

.btn-outline:hover {
  background: var(--primary);
  color: var(--primary-foreground);
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.2);
}

/* Form Elements */
.form-input {
  width: 100%;
  padding: 0.75rem;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  background: var(--input);
  color: var(--foreground);
  font-family: var(--font-family);
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.1);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--foreground);
}

/* Success Message */
.success-message {
  background: rgba(212, 175, 55, 0.1);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  margin-top: 2rem;
}

.success-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.success-content h3 {
  color: var(--primary);
  margin: 0;
}

.success-content p {
  margin: 0;
  color: var(--foreground);
}

/* Header */
.header {
  background: rgba(26, 26, 46, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 1rem 0;
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  display: flex;
  align-items: center;
}

.logo-img {
  height: 2.5rem;
  width: auto;
}

.nav-links {
  display: flex;
  gap: 2rem;
  align-items: center;
}

.nav-links a {
  color: var(--foreground);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.zenlavorix-top_mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--foreground);
  cursor: pointer;
  padding: 0.5rem;
}

.zenlavorix-top_mobile-menu {
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 1rem 0;
}

.zenlavorix-top_mobile-menu a {
  display: block;
  padding: 0.75rem 1rem;
  color: var(--foreground);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
}

.zenlavorix-top_mobile-menu a:hover {
  background: var(--muted);
  color: var(--primary);
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .zenlavorix-top_mobile-menu-toggle {
    display: block;
  }
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  padding: 5rem 0;
  min-height: 60vh;
  display: flex;
  align-items: center;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.hero-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.hero-description {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  opacity: 0.95;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-actions .btn-primary {
  background: #fff;
  color: var(--primary);
  border-color: #fff;
}

.hero-actions .btn-primary:hover {
  background: var(--accent);
  color: var(--primary-foreground);
}

.hero-actions .btn-outline {
  color: #fff;
  border-color: #fff;
}

.hero-actions .btn-outline:hover {
  background: #fff;
  color: var(--primary);
}

.hero-image img {
  border-radius: 1rem;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .hero-actions {
    justify-content: center;
  }
}

/* Sections */
section {
  padding: 5rem 0;
  border-bottom: 1px solid var(--border);
}

.section-title {
  font-size: 2.5rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 3rem;
  color: var(--primary);
}

.page-header {
  text-align: center;
  padding: 3rem 0;
  background: var(--muted);
}

.page-header h1 {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--primary);
}

.page-header p {
  font-size: 1.25rem;
  color: var(--muted-foreground);
  margin: 0;
}

/* Cards */
.service-card,
.value-card,
.team-member,
.stat-item,
.logo-item,
.support-item {
  background: var(--card);
  color: var(--card-foreground);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08), 0 4px 16px rgba(0,0,0,0.04);
}

.service-card:hover,
.value-card:hover,
.team-member:hover,
.support-item:hover {
  border-color: var(--primary);
  box-shadow: 0 8px 32px rgba(212, 175, 55, 0.2);
  transform: translateY(-2px);
}

.service-card h3,
.value-card h3,
.team-member h3 {
  color: var(--primary);
  margin: 1rem 0;
  font-size: 1.5rem;
}

.service-card p,
.value-card p,
.team-member p {
  margin-bottom: 1.5rem;
}

/* Partner Logos */
.logos-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: 2rem;
}

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

/* About Preview */
.about-content h2 {
  color: var(--primary);
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.about-content p {
  margin-bottom: 1.5rem;
  font-size: 1.125rem;
}

.about-image img {
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

/* CTA Section */
.cta {
  background: var(--background);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  margin: 2rem 0;
}

.cta-content {
  text-align: center;
  padding: 3rem 2rem;
}

.cta-content h2 {
  color: var(--primary);
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.cta-content p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  color: var(--foreground);
}

.cta-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Services Page */
.service-detail {
  padding: 3rem 0;
}

.service-content h2 {
  color: var(--primary);
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.service-features {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
}

.service-features li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  font-size: 1.125rem;
}

.pricing-features {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin: 2rem 0;
}

.pricing-feature {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.pricing-content {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.pricing-content h2 {
  color: var(--primary);
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

/* Contact Page */
.contact-main {
  padding: 3rem 0;
}

.zenlavorix-top_contact-form-section h2 {
  color: var(--primary);
  margin-bottom: 2rem;
}

.contact-info-card {
  background: var(--card);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  margin-bottom: 2rem;
}

.contact-info-card h2 {
  color: var(--primary);
  margin-bottom: 2rem;
}

.contact-info-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
  align-items: flex-start;
}

.contact-icon {
  flex-shrink: 0;
}

.contact-details h4 {
  color: var(--primary);
  margin: 0 0 0.5rem 0;
}

.contact-details p {
  margin: 0;
}

.contact-details a {
  color: var(--primary);
  text-decoration: none;
}

.contact-details a:hover {
  text-decoration: underline;
}

.map-placeholder {
  background: var(--muted);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 3rem;
  text-align: center;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.map-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.map-content h4 {
  color: var(--primary);
  margin: 0;
}

/* Mission Statement */
.mission-statement {
  text-align: center;
  padding: 4rem 0;
}

.mission-text {
  font-size: 1.5rem;
  max-width: 800px;
  margin: 0 auto;
  font-weight: 500;
  color: var(--primary);
}

/* Achievements */
.achievements-content {
  align-items: center;
}

.achievement-highlights {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.highlight-item {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.highlight-item h4 {
  color: var(--primary);
  margin: 0;
}

.highlight-item p {
  margin: 0;
  color: var(--muted-foreground);
}

/* FAQ */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
}

.faq-question {
  width: 100%;
  background: none;
  border: none;
  color: var(--foreground);
  text-align: left;
  padding: 1.5rem 0;
  font-size: 1.25rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: color 0.3s ease;
}

.faq-question:hover {
  color: var(--primary);
}

.faq-question.active {
  color: var(--primary);
}

.faq-question.active .faq-icon {
  transform: rotate(180deg);
}

.faq-icon {
  transition: transform 0.3s ease;
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-answer.active {
  max-height: 500px;
}

.faq-answer p {
  padding-bottom: 1.5rem;
  margin: 0;
  line-height: 1.6;
}

.faq-contact {
  background: var(--muted);
  text-align: center;
  padding: 4rem 0;
}

.faq-contact-content h2 {
  color: var(--primary);
  margin: 1rem 0 1.5rem 0;
}

.contact-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2rem;
}

/* Legal Content */
.legal-content {
  padding: 3rem 0;
}

.legal-text {
  max-width: 800px;
  margin: 0 auto;
}

.legal-text h2 {
  color: var(--primary);
  font-size: 2rem;
  margin: 3rem 0 1.5rem 0;
}

.legal-text h3 {
  color: var(--primary);
  font-size: 1.5rem;
  margin: 2rem 0 1rem 0;
}

.legal-text p {
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.legal-text ul {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
}

.legal-text li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}

.legal-text a {
  color: var(--primary);
  text-decoration: none;
}

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

/* Cookie Table */
.cookie-table {
  overflow-x: auto;
  margin: 2rem 0;
}

.cookie-table table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
}

.cookie-table th,
.cookie-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.cookie-table th {
  background: var(--muted);
  color: var(--primary);
  font-weight: 600;
}

.cookie-table td {
  color: var(--card-foreground);
}

/* Footer */
.footer {
  background: var(--muted);
  color: var(--foreground);
  padding: 3rem 0 1rem 0;
  margin-top: auto;
}

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

.footer-column h4 {
  color: var(--primary);
  margin-bottom: 1rem;
  font-size: 1.25rem;
}

.footer-column ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-column li {
  margin-bottom: 0.5rem;
}

.footer-column a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-column a:hover {
  color: var(--secondary);
  text-decoration: underline;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 2rem;
}

.footer-legal {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.legal-links {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.legal-links a {
  color: var(--primary);
  text-decoration: none;
  font-size: 0.875rem;
}

.legal-links a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .footer-legal {
    flex-direction: column;
    text-align: center;
  }
  
  .legal-links {
    justify-content: center;
  }
}

/* Cookie Banner */
.zenlavorix-top_cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--card);
  border-top: 2px solid var(--primary);
  z-index: 9999;
  box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.3);
}

.zenlavorix-top_cookie-banner-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
  padding: 1.5rem 0;
  flex-wrap: wrap;
}

.zenlavorix-top_cookie-banner-text {
  flex: 1;
  min-width: 300px;
}

.zenlavorix-top_cookie-banner-text p {
  margin: 0;
  color: var(--card-foreground);
}

.zenlavorix-top_cookie-banner-actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.zenlavorix-top_cookie-banner-actions button {
  padding: 0.5rem 1rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  white-space: nowrap;
}

/* Cookie Modal */
.zenlavorix-top_cookie-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.zenlavorix-top_cookie-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
}

.zenlavorix-top_cookie-modal-content {
  position: relative;
  background: var(--card);
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  padding: 2rem;
  max-width: 500px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  color: var(--card-foreground);
}

.cookie-toggles {
  margin: 2rem 0;
}

.zenlavorix-top_cookie-toggle-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.zenlavorix-top_cookie-toggle-row:last-child {
  border-bottom: none;
}

.zenlavorix-top_cookie-toggle-row input[type="checkbox"] {
  width: 1.5rem;
  height: 1.5rem;
  accent-color: var(--primary);
}

.zenlavorix-top_cookie-modal-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
  flex-wrap: wrap;
}

@media (max-width: 768px) {
  .zenlavorix-top_cookie-banner-inner {
    flex-direction: column;
    text-align: center;
  }
  
  .zenlavorix-top_cookie-banner-actions {
    justify-content: center;
  }
  
  .zenlavorix-top_cookie-modal-actions {
    justify-content: center;
  }
}

/* Animation Classes */
.animate-hide {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-in {
  opacity: 1;
  transform: translateY(0);
}

/* Apply animation to specific elements only */
.service-card,
.value-card,
.team-member,
.stat-item,
.support-item,
.faq-item,
.pricing-feature {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.service-card.animate-in,
.value-card.animate-in,
.team-member.animate-in,
.stat-item.animate-in,
.support-item.animate-in,
.faq-item.animate-in,
.pricing-feature.animate-in {
  opacity: 1;
  transform: translateY(0);
}

/* === CLASS ALIAS FIXES (injected by engine) === */
.hero-text { /* alias for .hero-content */ }
.hero-text {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

/* === BASELINE SAFETY CSS (injected by engine) === */

/* Ensure .hidden works consistently even with ID-specific overrides */
.hidden { display: none !important; }

/* Prevent content overflow breaking layout */
img, video, iframe { max-width: 100%; height: auto; }
* { box-sizing: border-box; }

/* Ensure container has responsive padding */
.container { width: 100%; max-width: 1200px; margin-left: auto; margin-right: auto; padding-left: 1rem; padding-right: 1rem; }

/* Prevent flex/grid children from overflowing */
.grid-2, .grid-3, .grid-4 { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Responsive grid fallbacks */
@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}
@media (min-width: 769px) and (max-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

/* Ensure forms don't break layout */
.form-input, input[type="text"], input[type="email"], input[type="tel"], textarea, select {
  width: 100%;
  max-width: 100%;
}

/* Success message styling */
.success-message {
  margin-top: 1rem;
  padding: 1rem;
  background: #ecfdf5;
  border: 1px solid #6ee7b7;
  border-radius: 0.5rem;
  color: #065f46;
  text-align: center;
}

/* Stacking context for hero sections — prevents z-index:-1 children from going behind the page */
.hero, .hero-section, .page-header, .cta, .cta-section { isolation: isolate; position: relative; }

/* Desktop nav injected by engine — show on desktop, hide on mobile */
.nav-menu { display: flex; align-items: center; gap: 1.5rem; }
.nav-menu .nav-link { text-decoration: none; color: var(--foreground, #1f2937); font-weight: 500; font-size: 0.95rem; transition: color 0.2s; }
.nav-menu .nav-link:hover { color: var(--primary, #2563eb); }
@media (max-width: 768px) {
  .nav-menu { display: none !important; }
}

/* Fixed header body padding safety */
body { min-height: 100vh; }

/* Prevent long words breaking layout */
h1, h2, h3, h4, p, li, td, th { overflow-wrap: break-word; word-wrap: break-word; }

/* === END BASELINE SAFETY CSS === */

/* Cookie banner visibility rules */
#zenlavorix-top_cookie-banner.hidden, #cookie-consent-banner.hidden { display: none !important; }
#zenlavorix-top_cookie-banner:not(.hidden), #cookie-consent-banner:not(.hidden) { display: block !important; }
#zenlavorix-top_cookie-modal.hidden { display: none !important; }
.hidden { display: none !important; }
