/* ========================================
   MapleTrust Advisors - Main Stylesheet
   ======================================== */

:root {
  --primary: #1B365D;
  --primary-light: #2A4A7F;
  --primary-dark: #0F2140;
  --accent: #C4A962;
  --accent-light: #D4BF82;
  --accent-dark: #A88D4A;
  --white: #FFFFFF;
  --off-white: #F8F9FA;
  --light-gray: #E9ECEF;
  --medium-gray: #6C757D;
  --dark-gray: #343A40;
  --text: #2D3436;
  --text-light: #636E72;
  --shadow: 0 2px 15px rgba(27, 54, 93, 0.08);
  --shadow-lg: 0 10px 40px rgba(27, 54, 93, 0.12);
  --radius: 8px;
  --radius-lg: 16px;
  --transition: all 0.3s ease;
  --max-width: 1200px;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Merriweather', Georgia, serif;
  font-weight: 700;
  line-height: 1.3;
  color: var(--primary);
}

h1 { font-size: 2.8rem; }
h2 { font-size: 2.2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p { margin-bottom: 1rem; }

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

a:hover { color: var(--accent); }

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

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  border: 2px solid transparent;
  text-align: center;
}

.btn-primary {
  background: var(--accent);
  color: var(--primary-dark);
  border-color: var(--accent);
}

.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(196, 169, 98, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: var(--white);
}

.btn-outline:hover {
  background: var(--white);
  color: var(--primary);
}

.btn-dark {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

.btn-dark:hover {
  background: var(--primary-light);
  border-color: var(--primary-light);
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(27, 54, 93, 0.3);
}

/* ========== HEADER ========== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(10px);
  transition: var(--transition);
  border-bottom: 1px solid transparent;
}

.header.scrolled {
  box-shadow: var(--shadow);
  border-bottom: 1px solid var(--light-gray);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Merriweather', serif;
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--primary);
}

.logo img {
  width: 42px;
  height: 42px;
}

.logo span {
  color: var(--accent);
}

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

.nav-links a {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text);
  position: relative;
  padding: 6px 0;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-links a.active {
  color: var(--primary);
  font-weight: 600;
}

.nav-cta {
  padding: 10px 24px !important;
  background: var(--primary);
  color: var(--white) !important;
  border-radius: var(--radius);
  font-weight: 600 !important;
}

.nav-cta::after { display: none !important; }

.nav-cta:hover {
  background: var(--primary-light) !important;
  color: var(--white) !important;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 8px;
}

.menu-toggle span {
  width: 26px;
  height: 2.5px;
  background: var(--primary);
  border-radius: 2px;
  transition: var(--transition);
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}
.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ========== HERO ========== */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, rgba(27, 54, 93, 0.92), rgba(15, 33, 64, 0.85)),
              url('../images/hero-office.jpg') center/cover no-repeat;
  color: var(--white);
  padding-top: 80px;
}

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

.hero-badge {
  display: inline-block;
  background: rgba(196, 169, 98, 0.2);
  border: 1px solid rgba(196, 169, 98, 0.4);
  color: var(--accent-light);
  padding: 8px 20px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  letter-spacing: 0.5px;
}

.hero h1 {
  color: var(--white);
  font-size: 3.2rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.hero h1 .accent {
  color: var(--accent);
}

.hero p {
  font-size: 1.15rem;
  line-height: 1.8;
  opacity: 0.9;
  margin-bottom: 2.5rem;
  max-width: 560px;
}

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

.hero-stats {
  display: flex;
  gap: 3rem;
  margin-top: 4rem;
  padding-top: 3rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.stat-item h3 {
  color: var(--accent);
  font-size: 2.2rem;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
}

.stat-item p {
  font-size: 0.9rem;
  opacity: 0.75;
  margin: 0;
}

/* ========== PAGE HERO (inner pages) ========== */
.page-hero {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  padding: 160px 0 80px;
  color: var(--white);
  text-align: center;
}

.page-hero h1 {
  color: var(--white);
  margin-bottom: 1rem;
}

.page-hero p {
  font-size: 1.15rem;
  opacity: 0.85;
  max-width: 600px;
  margin: 0 auto;
}

.breadcrumb {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  opacity: 0.7;
}

.breadcrumb a { color: var(--accent-light); }
.breadcrumb span { color: var(--white); }

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

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

.section-header .label {
  display: inline-block;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.section-header h2 {
  margin-bottom: 1rem;
}

.section-header p {
  color: var(--text-light);
  font-size: 1.05rem;
}

.section-alt {
  background: var(--off-white);
}

/* ========== SERVICES GRID ========== */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.service-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  transition: var(--transition);
  border: 1px solid var(--light-gray);
}

.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.service-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  color: var(--accent);
}

.service-card h3 {
  margin-bottom: 0.75rem;
}

.service-card p {
  color: var(--text-light);
  font-size: 0.95rem;
}

.service-card .learn-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-dark);
  font-weight: 600;
  font-size: 0.9rem;
  margin-top: 1rem;
}

.service-card .learn-more:hover { gap: 10px; }

/* ========== ABOUT / TWO-COL ========== */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.two-col-img {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.two-col-img img {
  width: 100%;
  height: 400px;
  object-fit: cover;
}

.two-col-content .label {
  display: inline-block;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}

.two-col-content h2 {
  margin-bottom: 1.25rem;
}

.two-col-content p {
  color: var(--text-light);
  margin-bottom: 1.25rem;
}

/* Values */
.values-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.value-item {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.value-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  background: var(--off-white);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.2rem;
}

.value-item h4 { margin-bottom: 0.4rem; }
.value-item p { color: var(--text-light); font-size: 0.9rem; margin: 0; }

/* ========== TEAM ========== */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.team-card {
  text-align: center;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.team-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.team-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 2.5rem;
  color: var(--accent);
  font-family: 'Merriweather', serif;
}

.team-card h3 { margin-bottom: 0.3rem; font-size: 1.2rem; }
.team-card .role { color: var(--accent-dark); font-weight: 600; font-size: 0.9rem; margin-bottom: 1rem; }
.team-card p { color: var(--text-light); font-size: 0.9rem; }

/* ========== TESTIMONIALS ========== */
.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 2rem;
}

.testimonial-card {
  background: var(--white);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  border-left: 4px solid var(--accent);
  position: relative;
}

.testimonial-card .quote-mark {
  font-size: 4rem;
  color: var(--accent);
  font-family: 'Merriweather', serif;
  line-height: 1;
  opacity: 0.3;
  position: absolute;
  top: 15px;
  right: 25px;
}

.testimonial-card p {
  font-style: italic;
  color: var(--text-light);
  margin-bottom: 1.5rem;
  font-size: 1.02rem;
  line-height: 1.8;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.testimonial-author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-weight: 700;
  font-family: 'Merriweather', serif;
}

.testimonial-author-info strong {
  display: block;
  color: var(--primary);
  font-size: 0.95rem;
}

.testimonial-author-info span {
  color: var(--text-light);
  font-size: 0.85rem;
}

/* Stars */
.stars {
  color: var(--accent);
  margin-bottom: 1rem;
  letter-spacing: 3px;
}

/* ========== CTA SECTION ========== */
.cta-section {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  padding: 80px 0;
  text-align: center;
  color: var(--white);
}

.cta-section h2 {
  color: var(--white);
  margin-bottom: 1rem;
}

.cta-section p {
  opacity: 0.85;
  max-width: 560px;
  margin: 0 auto 2rem;
  font-size: 1.1rem;
}

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

/* ========== CONTACT ========== */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
}

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

.contact-form label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: var(--primary);
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--light-gray);
  border-radius: var(--radius);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  transition: var(--transition);
  background: var(--white);
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(196, 169, 98, 0.15);
}

.contact-form textarea {
  resize: vertical;
  min-height: 140px;
}

.contact-info-card {
  background: var(--off-white);
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  margin-bottom: 2rem;
}

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

.contact-info-item:last-child { margin-bottom: 0; }

.contact-info-icon {
  width: 48px;
  height: 48px;
  min-width: 48px;
  background: var(--primary);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.2rem;
}

.contact-info-item h4 { margin-bottom: 0.3rem; font-size: 1rem; }
.contact-info-item p { color: var(--text-light); font-size: 0.9rem; margin: 0; }

.map-placeholder {
  width: 100%;
  height: 250px;
  background: var(--light-gray);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--medium-gray);
  font-size: 0.95rem;
  overflow: hidden;
}

.map-placeholder iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

/* ========== SERVICES PAGE DETAIL ========== */
.service-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  padding: 3rem 0;
  border-bottom: 1px solid var(--light-gray);
}

.service-detail:last-child { border-bottom: none; }

.service-detail.reverse { direction: rtl; }
.service-detail.reverse > * { direction: ltr; }

.service-detail-content .label {
  color: var(--accent);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  display: block;
}

.service-detail-content h3 {
  font-size: 1.6rem;
  margin-bottom: 1rem;
}

.service-detail-content p {
  color: var(--text-light);
}

.service-detail-content ul {
  list-style: none;
  margin: 1.25rem 0;
}

.service-detail-content ul li {
  padding: 0.4rem 0;
  color: var(--text-light);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.service-detail-content ul li::before {
  content: '✓';
  color: var(--accent);
  font-weight: 700;
}

.service-detail-visual {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: var(--radius-lg);
  padding: 3rem;
  text-align: center;
  color: var(--white);
  min-height: 300px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.service-detail-visual .icon-large {
  font-size: 3.5rem;
  margin-bottom: 1.5rem;
}

/* ========== LEGAL PAGES ========== */
.legal-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 60px 2rem;
}

.legal-content h2 {
  font-size: 1.5rem;
  margin: 2.5rem 0 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--light-gray);
}

.legal-content h2:first-of-type {
  border-top: none;
  padding-top: 0;
}

.legal-content p,
.legal-content li {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.8;
}

.legal-content ul {
  margin: 1rem 0;
  padding-left: 1.5rem;
}

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

.legal-content a { color: var(--accent-dark); text-decoration: underline; }

/* ========== FOOTER ========== */
.footer {
  background: var(--primary-dark);
  color: rgba(255, 255, 255, 0.75);
  padding: 60px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 3rem;
}

.footer-brand .logo {
  color: var(--white);
  margin-bottom: 1rem;
}

.footer-brand p {
  font-size: 0.9rem;
  line-height: 1.8;
  opacity: 0.8;
}

.footer h4 {
  color: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  margin-bottom: 1.5rem;
}

.footer-links {
  list-style: none;
}

.footer-links li { margin-bottom: 0.75rem; }

.footer-links a {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-contact-item {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.footer-contact-item .icon {
  color: var(--accent);
  min-width: 20px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.5rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
}

.footer-bottom-links {
  display: flex;
  gap: 2rem;
}

.footer-bottom-links a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.85rem;
}

.footer-bottom-links a:hover { color: var(--accent); }

/* ========== ANIMATIONS ========== */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.fade-in-left {
  opacity: 0;
  transform: translateX(-30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.fade-in-right {
  opacity: 0;
  transform: translateX(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 992px) {
  h1 { font-size: 2.2rem; }
  h2 { font-size: 1.8rem; }
  .hero h1 { font-size: 2.5rem; }

  .two-col,
  .contact-grid,
  .service-detail {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .service-detail.reverse { direction: ltr; }

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

  .hero-stats { gap: 2rem; }
}

@media (max-width: 768px) {
  .menu-toggle { display: flex; }

  .nav-links {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background: var(--white);
    flex-direction: column;
    padding: 2rem;
    gap: 0;
    box-shadow: var(--shadow-lg);
    transform: translateY(-120%);
    transition: transform 0.3s ease;
    z-index: 999;
  }

  .nav-links.active {
    transform: translateY(0);
  }

  .nav-links li {
    width: 100%;
    border-bottom: 1px solid var(--light-gray);
  }

  .nav-links a {
    display: block;
    padding: 1rem 0;
  }

  .nav-cta {
    margin-top: 1rem;
    text-align: center;
    display: block !important;
  }

  .hero { min-height: 80vh; }
  .hero h1 { font-size: 2rem; }
  .hero-stats { flex-direction: column; gap: 1.5rem; }
  .section { padding: 60px 0; }

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

  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
}

@media (max-width: 480px) {
  .container { padding: 0 1rem; }
  .hero h1 { font-size: 1.75rem; }
  .hero-buttons { flex-direction: column; }
  .hero-buttons .btn { width: 100%; }
  .service-card { padding: 2rem; }
  .btn { padding: 12px 24px; }
}
