/* ──────────────────────────────────────────
   Estee Advisors — Custom CSS overrides
   Tailwind handles layout; this file handles
   component-level style and animation.
────────────────────────────────────────── */

/* ── Global ─────────────────────────────── */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 72px; /* sticky nav height */
}

body {
  overflow-x: hidden;
}

/* ── Navbar ─────────────────────────────── */
#site-header {
  background: transparent;
}

#site-header.scrolled {
  background: #ffffff;
  box-shadow: 0 1px 16px rgba(27, 58, 107, 0.1);
}

#site-header.scrolled .nav-link {
  color: #1B3A6B;
}

#site-header.scrolled .nav-link:hover {
  color: #00A878;
}

/* Logo: white version on dark hero, original on white scrolled nav */
.nav-logo {
  filter: brightness(0) invert(1);
  transition: filter 0.3s;
}

#site-header.scrolled .nav-logo {
  filter: none;
}

/* ── Hero particle grid ──────────────────── */
.particle-grid {
  background-image:
    radial-gradient(circle, rgba(0, 168, 120, 0.15) 1px, transparent 1px);
  background-size: 48px 48px;
  animation: gridShift 20s linear infinite;
}

@keyframes gridShift {
  0%   { background-position: 0 0; }
  100% { background-position: 48px 48px; }
}

/* ── Trust badges (hero) ─────────────────── */
.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.8rem;
  font-weight: 500;
}

.trust-check {
  display: inline-block;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: rgba(0, 168, 120, 0.25);
  border: 1.5px solid rgba(0, 168, 120, 0.6);
  position: relative;
  flex-shrink: 0;
}

.trust-check::after {
  content: '';
  position: absolute;
  left: 3px;
  top: 1px;
  width: 5px;
  height: 8px;
  border-right: 1.5px solid #C9A84C;
  border-bottom: 1.5px solid #C9A84C;
  transform: rotate(45deg);
}

/* ── Stat cards ──────────────────────────── */
.stat-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1.5rem;
  text-align: center;
  transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(27, 58, 107, 0.12);
}

.stat-card-gold {
  background: #C9A84C;
  border-color: #C9A84C;
}

.stat-number {
  display: block;
  font-family: "Playfair Display", Georgia, serif;
  font-size: 2rem;
  font-weight: 700;
  color: #1B3A6B;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  font-size: 0.8rem;
  color: #64748b;
  font-weight: 500;
}

/* ── Portfolio cards ─────────────────────── */
.portfolio-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 2rem;
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}

.portfolio-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(27, 58, 107, 0.15);
  border-color: #C9A84C;
}

/* ── PMS banner ──────────────────────────── */
.pms-banner {
  background: linear-gradient(135deg, #C9A84C 0%, #DFC170 100%);
  border-radius: 16px;
  padding: 1.25rem 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  justify-content: center;
  text-align: center;
}

/* ── Philosophy cards (dark — kept for reference) ─── */
.philosophy-card {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  padding: 2rem;
  transition: background 0.25s, border-color 0.25s;
}

.philosophy-card:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(201, 168, 76, 0.4);
}

.philosophy-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(201, 168, 76, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #C9A84C;
  margin-bottom: 1.25rem;
}

/* ── Philosophy cards (light variant) ────── */
.philosophy-card-light {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 20px;
  padding: 2rem;
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}

.philosophy-card-light:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(27, 58, 107, 0.1);
  border-color: #C9A84C;
}

.philosophy-icon-light {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(201, 168, 76, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #C9A84C;
  margin-bottom: 1.25rem;
}

/* ── Risk indicator dots ─────────────────── */
.risk-dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.risk-dot-red         { background-color: #ef4444; }
.risk-dot-yellow      { background-color: #eab308; }
.risk-dot-green       { background-color: #16a34a; }
.risk-dot-orange      { background-color: #f97316; }
.risk-dot-light-green { background-color: #86efac; }
.risk-dot-blue        { background-color: #60a5fa; }

/* ── Steps / How it works ────────────────── */
.step-item {
  position: relative;
  padding-left: 1rem;
}

.step-number {
  position: absolute;
  left: -2.75rem;
  top: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #00A878;
  color: #ffffff;
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 0 4px rgba(0, 168, 120, 0.2);
}

/* ── Press section ───────────────────────── */
.press-logo {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #94a3b8;
  transition: color 0.2s;
}

.press-logo:hover {
  color: #1B3A6B;
}

.press-quote {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  font-style: italic;
  color: #475569;
  padding: 1.5rem 2rem;
  border-left: 4px solid #00A878;
  text-align: left;
  margin: 0;
}

/* ── FAQ accordion ───────────────────────── */
.faq-item {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  transition: box-shadow 0.2s;
}

.faq-item.open {
  box-shadow: 0 4px 16px rgba(27, 58, 107, 0.08);
  border-color: #00A878;
}

.faq-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  font-size: 0.95rem;
  font-weight: 600;
  color: #1A1A2E;
  transition: background 0.15s;
}

.faq-trigger:hover {
  background: #f8fafc;
}

.faq-chevron {
  transition: transform 0.3s ease;
  color: #00A878;
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.faq-answer {
  padding: 0 1.5rem 1.25rem;
  font-size: 0.9rem;
  line-height: 1.75;
  color: #475569;
  margin: 0;
}

/* ── Contact form ────────────────────────── */
.form-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.4rem;
}

.form-input {
  display: block;
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid #d1d5db;
  border-radius: 12px;
  font-size: 0.9rem;
  color: #1A1A2E;
  background: #ffffff;
  transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none;
  -webkit-appearance: none;
  font-family: inherit;
}

.form-input:focus {
  outline: none;
  border-color: #1B3A6B;
  box-shadow: 0 0 0 3px rgba(27, 58, 107, 0.12);
}

.form-input::placeholder {
  color: #9ca3af;
}

/* ── Trust signals ───────────────────────── */
.trust-signal {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

/* ── Scroll reveal animation ─────────────── */
.reveal-fade {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-fade.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Hamburger menu animation ────────────── */
#menu-toggle.menu-open .hamburger-line:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}
#menu-toggle.menu-open .hamburger-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
#menu-toggle.menu-open .hamburger-line:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* ── Print / no-motion ───────────────────── */
@media (prefers-reduced-motion: reduce) {
  .particle-grid { animation: none; }
  .reveal-fade { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ── Honeypot (both forms) ───────────────── */
.form-honeypot {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 0;
  height: 0;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

/* ── Lead capture popup ──────────────────── */
#lead-popup {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

#lead-popup.is-open {
  display: flex;
}

.popup-overlay-bg {
  position: absolute;
  inset: 0;
  background: rgba(10, 26, 53, 0.78);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  cursor: pointer;
  animation: popupFadeIn 0.2s ease;
}

.popup-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 440px;
  max-height: 90vh;
  overflow-y: auto;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 24px 64px rgba(10, 26, 53, 0.45);
  animation: popupSlideIn 0.32s cubic-bezier(0.34, 1.4, 0.64, 1);
}

.popup-gold-bar {
  height: 4px;
  background: linear-gradient(90deg, #C9A84C 0%, #DFC170 100%);
  border-radius: 20px 20px 0 0;
}

.popup-close-btn {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 2;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #f3f4f6;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6b7280;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}

.popup-close-btn:hover {
  background: #e5e7eb;
  color: #1B3A6B;
}

.popup-body {
  padding: 1.5rem;
}

@media (min-width: 480px) {
  .popup-body { padding: 2rem; }
}

.popup-header-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.popup-header-line {
  height: 1px;
  width: 28px;
  background: #C9A84C;
  flex-shrink: 0;
}

.popup-header-tag {
  color: #C9A84C;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.popup-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1B3A6B;
  margin: 0 0 0.2rem;
  line-height: 1.25;
}

.popup-subtitle {
  color: #6b7280;
  font-size: 0.875rem;
  margin: 0 0 1.25rem;
}

.popup-success-state {
  text-align: center;
  padding: 1.5rem 0 0.5rem;
}

.popup-success-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #dcfce7;
  color: #16a34a;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}

.popup-success-title {
  font-family: "Playfair Display", Georgia, serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #1B3A6B;
  margin: 0 0 0.4rem;
}

.popup-success-text {
  color: #6b7280;
  font-size: 0.875rem;
  margin: 0;
}

.popup-error {
  margin-bottom: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 12px;
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
  font-size: 0.875rem;
}

.popup-form {
  display: flex;
  flex-direction: column;
  gap: 0.875rem;
}

.popup-field {
  display: flex;
  flex-direction: column;
}

.popup-phone-row {
  display: flex;
}

.popup-phone-prefix {
  display: flex;
  align-items: center;
  padding: 0 0.875rem;
  border: 1.5px solid #d1d5db;
  border-right: none;
  border-radius: 12px 0 0 12px;
  background: #f9fafb;
  color: #6b7280;
  font-size: 0.875rem;
  font-weight: 500;
  flex-shrink: 0;
}

.popup-phone-input {
  border-radius: 0 12px 12px 0 !important;
}

.popup-textarea {
  height: 72px;
  resize: none;
}

.popup-captcha-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.popup-captcha-ans {
  max-width: 108px !important;
  flex-shrink: 0;
}

.popup-captcha-question {
  color: #1B3A6B;
}

.popup-captcha-refresh-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 10px;
  border: 1.5px solid #d1d5db;
  background: #f9fafb;
  color: #6b7280;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.popup-captcha-refresh-btn:hover {
  background: #f3f4f6;
  border-color: #C9A84C;
  color: #C9A84C;
}

.popup-optional-label {
  color: #9ca3af;
  font-weight: 400;
}

.popup-privacy-note {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #9ca3af;
  font-size: 0.75rem;
  margin: 0;
}

.popup-submit-btn {
  width: 100%;
  padding: 0.9rem 2rem;
  border-radius: 9999px;
  background: #C9A84C;
  color: #1B3A6B;
  font-weight: 700;
  font-size: 1rem;
  font-family: inherit;
  border: none;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
  box-shadow: 0 4px 18px rgba(201, 168, 76, 0.4);
}

.popup-submit-btn:hover {
  background: #DFC170;
}

.popup-submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.popup-trust-note {
  text-align: center;
  font-size: 0.7rem;
  color: #9ca3af;
  margin: 0.25rem 0 0;
}

@keyframes popupSlideIn {
  from { opacity: 0; transform: translateY(28px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes popupFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .popup-card { animation: none; }
  .popup-overlay-bg { animation: none; }
}

/* ── Legal modals (Disclosures, T&C, Privacy, Complaints) ── */
.legal-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 110;
  align-items: flex-start;
  justify-content: center;
  padding: 1.5rem 1rem;
  overflow-y: auto;
}

.legal-modal.is-open {
  display: flex;
}

.disclosures-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10, 26, 53, 0.82);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  cursor: pointer;
  animation: popupFadeIn 0.2s ease;
}

.disclosures-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 760px;
  margin: auto;
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 24px 64px rgba(10, 26, 53, 0.45);
  animation: popupSlideIn 0.32s cubic-bezier(0.34, 1.4, 0.64, 1);
  overflow: hidden;
}

.disclosures-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #e5e7eb;
  background: #1B3A6B;
  color: #ffffff;
  position: sticky;
  top: 0;
  z-index: 2;
}

.disclosures-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  margin: 0;
}

.disclosures-close-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255,255,255,0.12);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: background 0.15s;
  flex-shrink: 0;
}

.disclosures-close-btn:hover {
  background: rgba(255,255,255,0.24);
}

.disclosures-body {
  padding: 1.75rem 1.5rem 2rem;
  font-size: 0.875rem;
  line-height: 1.75;
  color: #374151;
  max-height: 78vh;
  overflow-y: auto;
}

.disclosures-body h2 {
  font-size: 1rem;
  font-weight: 700;
  color: #1B3A6B;
  margin: 1.5rem 0 0.5rem;
  padding-bottom: 0.25rem;
  border-bottom: 2px solid #e5e7eb;
}

.disclosures-body h2:first-child {
  margin-top: 0;
}

.disclosures-body h3 {
  font-size: 0.9rem;
  font-weight: 700;
  color: #1B3A6B;
  margin: 1.25rem 0 0.4rem;
}

.disclosures-body p {
  margin: 0 0 0.75rem;
}

.disclosures-body ol,
.disclosures-body ul {
  margin: 0 0 0.75rem;
  padding-left: 1.4rem;
}

.disclosures-body li {
  margin-bottom: 0.4rem;
}

.disclosures-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  margin-bottom: 0.75rem;
}

.disclosures-body th,
.disclosures-body td {
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  text-align: left;
  vertical-align: top;
}

.disclosures-body th {
  background: #f1f5f9;
  font-weight: 700;
  color: #1B3A6B;
}

.disclosures-body tr:nth-child(even) td {
  background: #f8fafc;
}

@media (prefers-reduced-motion: reduce) {
  .disclosures-card { animation: none; }
  .disclosures-overlay { animation: none; }
}
