/* =================================------------------ *
   MACLUNGA INVESTMENTS - WEBSITE ENHANCEMENTS CSS
   This stylesheet is additive, providing styles for new 
   features like testimonials, form validations, and legal pages.
   =================================------------------ */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600&display=swap');

/* ====== GLOBAL CORE VARIABLES & STYLE RESETS ====== */
:root {
  --bg: #0A0F0D;
  --gold: #D4A853;
  --gold-light: #e8c07a;
  --green: #1B5E3B;
  --green-light: #2a8a58;
  --text: #e8eae9;
  --text-muted: #9aa49e;
  --card-bg: #111814;
  --border: rgba(212,168,83,0.18);
  --nav-h: 68px;
}

/* ====== TESTIMONIALS SECTION ====== */
#testimonials {
  padding: 80px 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 32px;
  margin-top: 48px;
}
.testimonial-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.3s ease, border-color 0.3s ease;
}
.testimonial-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
}
.testimonial-stars {
  color: var(--gold);
  font-size: 18px;
  margin-bottom: 16px;
}
.testimonial-quote {
  font-size: 15px;
  color: var(--text);
  line-height: 1.6;
  margin-bottom: 24px;
  font-style: italic;
}
.testimonial-author {
  display: flex;
  align-items: center;
  gap: 16px;
}
.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(212,168,83,0.1);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
}
.author-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.author-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}
.author-role {
  font-size: 12px;
  color: var(--text-muted);
}
.author-org {
  font-size: 12px;
  color: var(--gold);
  font-weight: 500;
}

/* ====== FORM SUBMISSION FEEDBACK ====== */
.form-error-msg {
  background: rgba(220, 53, 69, 0.1);
  border: 1px solid rgba(220, 53, 69, 0.3);
  color: #ff6b6b;
  padding: 16px;
  border-radius: 8px;
  font-size: 14px;
  margin-top: 20px;
  margin-bottom: 20px;
  display: none;
  text-align: center;
}
.btn-submit-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.7;
  color: transparent !important;
}
.btn-submit-loading::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  border: 2px solid transparent;
  border-top-color: var(--bg);
  border-radius: 50%;
  animation: button-loading-spinner 1s linear infinite;
}
@keyframes button-loading-spinner {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* ====== SHARED NAVBAR FOR LEGAL PAGES ====== */
.legal-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 40px;
  background: rgba(10, 15, 13, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  height: var(--nav-h);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}
.legal-nav-brand {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  font-weight: 700;
  color: var(--gold);
  text-decoration: none;
}
.legal-nav-links {
  display: flex;
  list-style: none;
  gap: 24px;
}
.legal-nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}
.legal-nav-links a:hover {
  color: var(--gold);
}
.legal-nav-cta {
  border: 1px solid var(--gold);
  padding: 8px 16px;
  border-radius: 6px;
  color: var(--gold) !important;
  font-weight: 600 !important;
  transition: all 0.2s ease !important;
}
.legal-nav-cta:hover {
  background: var(--gold);
  color: var(--bg) !important;
}

/* ====== LEGAL PAGES LAYOUT ====== */
.legal-container {
  max-width: 800px;
  margin: 120px auto 80px auto;
  padding: 0 24px;
}
.legal-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--gold);
  text-decoration: none;
  font-size: 15px;
  margin-bottom: 32px;
  transition: color 0.2s;
}
.legal-back-link:hover {
  color: var(--gold-light);
}
.legal-title {
  font-size: 38px;
  color: var(--gold);
  margin-bottom: 16px;
  font-family: 'Playfair Display', serif;
}
.legal-meta {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 40px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 16px;
}
.legal-content h2 {
  font-size: 22px;
  color: var(--text);
  margin-top: 36px;
  margin-bottom: 16px;
  font-family: 'Playfair Display', serif;
  border-left: 3px solid var(--gold);
  padding-left: 12px;
}
.legal-content p {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}
.legal-content ul, .legal-content ol {
  margin-left: 24px;
  margin-bottom: 24px;
  color: var(--text-muted);
}
.legal-content li {
  font-size: 15px;
  line-height: 1.7;
  margin-bottom: 8px;
}

/* ====== ACCESSIBILITY & UTILITY ====== */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Responsive fixes for testimonials */
@media (max-width: 768px) {
  .legal-nav {
    padding: 0 20px;
  }
  .legal-nav-links {
    display: none; /* simple hidden for mobile, they can go back via back link */
  }
  .legal-title {
    font-size: 30px;
  }
  .testimonials-grid {
    grid-template-columns: 1fr;
  }
}
