/* MFI Management, LLC - Professional Investment Management Styles */
/* Color Palette:
   Primary: #1b263b (dark navy)
   Accent: #b8860b (gold)
   Background: #ffffff, #f8f9fa
   Text: #1a1a1a, #6b7280
*/

/* ============================================
   RESET & BASE STYLES
   ============================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #1a1a1a;
  background-color: #ffffff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.nav-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

ul, ol {
  list-style: none;
}

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

button {
  font-family: inherit;
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.skip-link {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: #1b263b;
  color: #ffffff;
  padding: 12px 24px;
  z-index: 10000;
  transition: top 0.3s ease;
  border-radius: 0 0 6px 6px;
  font-weight: 600;
}

.skip-link:focus {
  top: 0;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================
   HEADER
   ============================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: #ffffff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  z-index: 1000;
  width: 100%;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #1b263b;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: #1b263b;
  color: #b8860b;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 18px;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.logo-text span:first-child {
  color: #1b263b;
  font-weight: 700;
  font-size: 18px;
}

.logo-text span:last-child {
  color: #6b7280;
  font-size: 12px;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  background: none;
  border: none;
  cursor: pointer;
}

.nav-toggle-bar {
  width: 24px;
  height: 2px;
  background: #1b263b;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.nav-toggle.active .nav-toggle-bar:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active .nav-toggle-bar:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active .nav-toggle-bar:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.primary-nav a {
  color: #4b5563;
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s ease;
  position: relative;
}

.primary-nav a:hover {
  color: #1b263b;
}

.primary-nav a.active {
  color: #1b263b;
}

.primary-nav a.active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 2px;
  background: #b8860b;
}

.nav-cta {
  margin-left: 16px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 600;
  border-radius: 6px;
  transition: all 0.2s ease;
  cursor: pointer;
  border: 2px solid transparent;
  text-decoration: none;
  text-align: center;
}

.btn-primary {
  background: #1b263b;
  color: #ffffff;
  border-color: #1b263b;
}

.btn-primary:hover {
  background: #0f172a;
  border-color: #0f172a;
}

.btn-secondary {
  background: transparent;
  color: #1b263b;
  border-color: #1b263b;
}

.btn-secondary:hover {
  background: #1b263b;
  color: #ffffff;
}

.btn-ghost {
  background: transparent;
  color: #6b7280;
  border-color: transparent;
  padding: 8px 16px;
}

.btn-ghost:hover {
  color: #1b263b;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 14px;
}

.btn-block {
  width: 100%;
  display: flex;
}

/* ============================================
   HERO
   ============================================ */
.hero {
  padding: 160px 0 80px;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 50%, #f8f9fa 100%);
  position: relative;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%231b263b' fill-opacity='0.02'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  opacity: 0.5;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
}

.hero-content {
  max-width: 560px;
}

.hero-title {
  font-size: 48px;
  color: #1b263b;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 24px;
}

.hero-title span {
  color: #b8860b;
}

.hero-subtitle {
  font-size: 18px;
  color: #4b5563;
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.hero-image {
  position: relative;
}

.hero-image img {
  width: 100%;
  border-radius: 12px;
  box-shadow: 0 20px 40px rgba(27, 38, 59, 0.15);
}

.trust-line {
  text-align: center;
  color: #6b7280;
  font-size: 14px;
  margin-top: 32px;
}

/* ============================================
   SECTIONS
   ============================================ */
.section {
  padding: 80px 0;
}

.section-alt {
  background: #f8f9fa;
}

.section-title {
  font-size: 32px;
  color: #1b263b;
  font-weight: 700;
  text-align: center;
  margin-bottom: 16px;
}

.section-intro {
  text-align: center;
  color: #6b7280;
  max-width: 640px;
  margin: 0 auto 48px;
}

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

.container-narrow {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============================================
   CARDS
   ============================================ */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.card {
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

.card-image {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #f1f5f9;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.card:hover .card-image img {
  transform: scale(1.05);
}

.card-content {
  padding: 24px;
}

.card-content h3 {
  color: #1b263b;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 12px;
}

.card-content p {
  color: #6b7280;
  margin-bottom: 16px;
  line-height: 1.6;
}

.card-link {
  color: #b8860b;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 0.2s ease;
}

.card-link:hover {
  color: #8b6508;
}

/* ============================================
   FEATURES
   ============================================ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.feature-card {
  text-align: center;
  padding: 24px;
}

.feature-icon {
  width: 56px;
  height: 56px;
  background: rgba(184, 134, 11, 0.1);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.feature-icon svg {
  width: 28px;
  height: 28px;
  fill: #1b263b;
}

.feature-card h3 {
  color: #1b263b;
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-card p {
  color: #6b7280;
  font-size: 14px;
  line-height: 1.6;
}

/* ============================================
   FORMS
   ============================================ */
.lead-form-wrapper {
  max-width: 600px;
  margin: 0 auto;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  padding: 32px;
}

.lead-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-field label {
  color: #1b263b;
  font-weight: 600;
  font-size: 14px;
}

.form-field input,
.form-field textarea,
.form-field select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  background: #ffffff;
}

.form-field input:focus,
.form-field textarea:focus,
.form-field select:focus {
  border-color: #b8860b;
  outline: none;
  box-shadow: 0 0 0 3px rgba(184, 134, 11, 0.2);
}

.form-field textarea {
  min-height: 120px;
  resize: vertical;
}

.form-consent {
  padding-top: 8px;
}

.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
  font-size: 14px;
  color: #6b7280;
  line-height: 1.5;
}

.consent-label input {
  width: 20px;
  height: 20px;
  accent-color: #b8860b;
  flex-shrink: 0;
  margin-top: 2px;
  cursor: pointer;
}

.consent-label a {
  color: #b8860b;
  text-decoration: underline;
}

.form-error {
  color: #dc2626;
  font-size: 13px;
  display: none;
}

.form-field.error .form-error {
  display: block;
}

.form-field.error input,
.form-field.error textarea,
.form-field.error select {
  border-color: #dc2626;
}

.form-note {
  text-align: center;
  color: #6b7280;
  font-size: 13px;
  margin-top: 16px;
}

.honey {
  position: absolute;
  left: -9999px;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: #1b263b;
  color: #ffffff;
  padding: 48px 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.footer-col {
}

.footer-brand .logo {
  margin-bottom: 16px;
}

.footer-brand p {
  color: #9ca3af;
  font-size: 14px;
  margin-bottom: 16px;
  line-height: 1.6;
}

.footer-heading {
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a {
  color: #9ca3af;
  font-size: 14px;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: #b8860b;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-cookie-btn {
  background: none;
  border: none;
  color: #b8860b;
  cursor: pointer;
  font-size: 14px;
  text-align: left;
  padding: 0;
  transition: text-decoration 0.2s ease;
}

.footer-cookie-btn:hover {
  text-decoration: underline;
}

.footer-line {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin: 32px 0;
}

.footer-disclaimer {
  padding: 0 24px;
  margin-bottom: 24px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.footer-disclaimer p {
  color: #9ca3af;
  font-size: 12px;
  line-height: 1.6;
}

.footer-bottom {
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
  color: #9ca3af;
  font-size: 14px;
}

/* ============================================
   COOKIE BANNER
   ============================================ */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  width: 100%;
  background: #ffffff;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  z-index: 9000;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.cookie-banner.show {
  transform: translateY(0);
}

.cookie-banner-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.cookie-text {
  flex: 1;
  color: #6b7280;
  font-size: 14px;
  line-height: 1.6;
}

.cookie-text a {
  color: #1b263b;
  text-decoration: underline;
}

.cookie-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ============================================
   COOKIE MODAL
   ============================================ */
.cookie-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(27, 38, 59, 0.5);
  z-index: 9100;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.cookie-modal-backdrop.show {
  display: flex;
}

.cookie-modal-card {
  background: #ffffff;
  border-radius: 12px;
  max-width: 480px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 24px;
  position: relative;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.cookie-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  color: #9ca3af;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  font-size: 24px;
  line-height: 1;
  transition: color 0.2s ease;
}

.cookie-modal-close:hover {
  color: #4b5563;
}

.cookie-modal-intro {
  margin-bottom: 24px;
}

.cookie-modal-intro h3 {
  color: #1b263b;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 8px;
}

.cookie-modal-intro p {
  color: #6b7280;
  font-size: 14px;
  line-height: 1.6;
}

.cookie-category {
  padding: 16px 0;
  border-bottom: 1px solid #e5e7eb;
}

.cookie-category:last-child {
  border-bottom: none;
}

.cookie-cat-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
}

.cookie-cat-head h4 {
  color: #1b263b;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}

.cookie-cat-head p {
  color: #6b7280;
  font-size: 13px;
  line-height: 1.5;
}

.switch {
  position: relative;
  width: 44px;
  height: 24px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 100%;
  height: 100%;
  position: absolute;
  margin: 0;
  cursor: pointer;
  z-index: 1;
}

.switch-slider {
  position: absolute;
  inset: 0;
  background: #d1d5db;
  border-radius: 999px;
  transition: background 0.2s ease;
}

.switch-slider::before {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  background: #ffffff;
  border-radius: 50%;
  top: 3px;
  left: 3px;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
}

.switch input:checked + .switch-slider {
  background: #b8860b;
}

.switch input:checked + .switch-slider::before {
  transform: translateX(20px);
}

.switch input:disabled + .switch-slider {
  opacity: 0.5;
  cursor: not-allowed;
}

.switch input:disabled {
  cursor: not-allowed;
}

.cookie-modal-buttons {
  display: flex;
  gap: 12px;
  margin-top: 24px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

/* ============================================
   RESPONSIVE - TABLET (max-width 768px)
   ============================================ */
@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .primary-nav {
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: #ffffff;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
  }

  body.nav-open .primary-nav {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .primary-nav a {
    padding: 8px 0;
  }

  .nav-cta {
    margin-left: 0;
    margin-top: 8px;
  }

  .hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-content {
    max-width: 100%;
  }

  .hero-image {
    order: -1;
  }

  .hero-cta {
    justify-content: center;
  }

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

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .footer-brand {
    grid-column: span 2;
  }

  .cookie-banner-inner {
    flex-direction: column;
    text-align: center;
  }

  .cookie-buttons {
    width: 100%;
    justify-content: center;
  }
}

/* ============================================
   RESPONSIVE - MOBILE (max-width 480px)
   ============================================ */
@media (max-width: 480px) {
  .hero {
    padding: 120px 0 60px;
  }

  .hero-title {
    font-size: 28px;
  }

  .hero-subtitle {
    font-size: 16px;
  }

  .section {
    padding: 60px 0;
  }

  .section-title {
    font-size: 26px;
  }

  .features-grid {
    grid-template-columns: 1fr;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

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

  .footer-brand {
    grid-column: span 1;
  }

  .btn {
    width: 100%;
    justify-content: center;
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .header-inner {
    padding: 12px 16px;
  }

  .lead-form-wrapper {
    padding: 24px 16px;
    margin: 0 16px;
  }

  .cookie-modal-card {
    padding: 16px;
  }

  .cookie-modal-buttons {
    flex-direction: column;
  }

  .cookie-modal-buttons .btn {
    width: 100%;
  }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .site-header,
  .cookie-banner,
  .cookie-modal-backdrop,
  .nav-toggle,
  .btn,
  .hero-image,
  .skip-link {
    display: none !important;
  }

  .hero {
    padding: 40px 0;
    background: none;
  }

  .hero::before {
    display: none;
  }

  body {
    font-size: 12pt;
    color: #000000;
    background: #ffffff;
  }

  .site-footer {
    background: #f8f9fa;
    color: #1a1a1a;
    padding: 24px 0;
  }

  .footer-links a,
  .footer-brand p,
  .footer-disclaimer p,
  .footer-bottom p {
    color: #4b5563;
  }

  .section {
    padding: 24px 0;
    page-break-inside: avoid;
  }

  .card {
    box-shadow: none;
    border: 1px solid #e5e7eb;
    page-break-inside: avoid;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 10pt;
    color: #6b7280;
  }
}
