/* ============================================================
   ClinTrust.ai — Main Stylesheet
   Design System: Deep Navy + Clean White + Fintech Teal
   ============================================================ */

/* --- Google Fonts Import --- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=DM+Sans:wght@300;400;500;600;700&display=swap');

/* --- CSS Custom Properties --- */
:root {
  /* Color Palette */
  --navy-950: #0D2547;
  --navy-900: #091d38;
  --navy-800: #0f2040;
  --navy-700: #163057;
  --navy-600: #1e4070;
  --navy-500: #2a5298;
  --teal-600: #0d7377;
  --teal-500: #14a085;
  --teal-400: #1abc9c;
  --teal-300: #48d1cc;
  --teal-100: #e0f7f6;
  --white: #ffffff;
  --gray-50: #f8fafc;
  --gray-100: #f1f5f9;
  --gray-200: #e2e8f0;
  --gray-300: #cbd5e1;
  --gray-400: #94a3b8;
  --gray-500: #64748b;
  --gray-600: #475569;
  --gray-700: #334155;
  --gray-800: #1e293b;
  --amber-400: #fbbf24;
  --amber-300: #fcd34d;
  --red-400: #f87171;
  --green-400: #4ade80;

  /* Typography */
  --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'DM Sans', 'Inter', sans-serif;

  /* Spacing */
  --section-pad-y: 44px;
  --section-pad-x: 80px;
  --container-max: 1280px;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.12), 0 1px 2px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.12), 0 2px 6px rgba(0,0,0,0.08);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.15), 0 4px 12px rgba(0,0,0,0.10);
  --shadow-navy: 0 8px 32px rgba(10, 22, 40, 0.35);
  --shadow-teal: 0 4px 24px rgba(20, 160, 133, 0.25);

  /* Borders */
  --border-radius: 8px;
  --border-radius-lg: 16px;
  --border-radius-xl: 24px;

  /* Transitions */
  --transition: all 0.2s ease;
  --transition-slow: all 0.4s ease;
}

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

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

body {
  font-family: var(--font-primary);
  background-color: var(--white);
  color: var(--gray-800);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* --- Container --- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 40px;
}

@media (max-width: 768px) {
  .container { padding: 0 20px; }
  :root { --section-pad-y: 28px; --section-pad-x: 20px; }
}

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(13, 37, 71, 0.97);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  transition: var(--transition);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 40px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-logo-mark {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: white;
  border-radius: 10px;
  padding: 3px;
  box-shadow: 0 0 0 1px rgba(20,160,133,0.25), 0 2px 10px rgba(0,0,0,0.25);
}

.nav-logo-mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.nav-logo-text {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.3px;
}

.nav-logo-text span {
  color: var(--teal-400);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  padding: 7px 14px;
  font-size: 13.5px;
  font-weight: 500;
  color: rgba(255,255,255,0.72);
  border-radius: 6px;
  transition: var(--transition);
  letter-spacing: 0.1px;
}

.nav-link:hover, .nav-link.active {
  color: var(--white);
  background: rgba(255,255,255,0.07);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--border-radius);
  transition: var(--transition);
  letter-spacing: 0.1px;
}

.btn-primary {
  background: linear-gradient(135deg, var(--teal-500), var(--teal-600));
  color: var(--white);
  border: 1px solid transparent;
  box-shadow: var(--shadow-teal);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--teal-400), var(--teal-500));
  transform: translateY(-1px);
  box-shadow: 0 6px 28px rgba(20,160,133,0.35);
}

.btn-secondary {
  background: transparent;
  color: rgba(255,255,255,0.85);
  border: 1px solid rgba(255,255,255,0.2);
}

.btn-secondary:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.35);
  color: white;
}

.btn-outline-teal {
  background: transparent;
  color: var(--teal-400);
  border: 1.5px solid var(--teal-500);
}

.btn-outline-teal:hover {
  background: var(--teal-500);
  color: white;
  transform: translateY(-1px);
}

.btn-lg {
  padding: 14px 32px;
  font-size: 15px;
}

.btn-xl {
  padding: 16px 40px;
  font-size: 16px;
  border-radius: 10px;
}

/* Hamburger */
.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
  cursor: pointer;
}
.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.8);
  border-radius: 2px;
  transition: var(--transition);
}

/* Mobile nav */
.nav-mobile {
  display: none;
  position: fixed;
  top: 68px; left: 0; right: 0;
  background: var(--navy-950);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding: 20px 24px 28px;
  z-index: 999;
}

.nav-mobile.open { display: block; }

.nav-mobile .nav-link {
  display: block;
  padding: 12px 0;
  font-size: 15px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.nav-mobile .btn {
  margin-top: 16px;
  width: 100%;
  justify-content: center;
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */
.display-xl {
  font-family: var(--font-display);
  font-size: clamp(34px, 4.2vw, 60px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -1.5px;
}

.display-lg {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.2vw, 46px);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -1px;
}

.display-md {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.5vw, 34px);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.5px;
}

.section-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--teal-400);
  margin-bottom: 6px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.4vw, 32px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.8px;
  color: var(--navy-900);
  margin-bottom: 10px;
}

.section-title-light { color: var(--white); }

.section-subtitle {
  font-size: 14.5px;
  color: var(--gray-500);
  line-height: 1.6;
  max-width: 620px;
}

.section-subtitle-light {
  color: rgba(255,255,255,0.62);
}

.text-teal { color: var(--teal-500); }
.text-teal-light { color: var(--teal-300); }
.text-white { color: var(--white); }
.text-navy { color: var(--navy-900); }
.text-muted { color: var(--gray-500); }

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
  padding: var(--section-pad-y) 0;
}

.section-dark {
  background: var(--navy-900);
  padding: var(--section-pad-y) 0;
}

.section-navy {
  background: var(--navy-950);
  padding: var(--section-pad-y) 0;
}

.section-light {
  background: var(--gray-50);
  padding: var(--section-pad-y) 0;
}

.section-center { text-align: center; }

.section-header {
  margin-bottom: 28px;
}

.section-header.center {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--white);
  border: 1px solid var(--gray-200);
  border-radius: var(--border-radius-lg);
  padding: 20px;
  transition: var(--transition-slow);
}

.card:hover {
  border-color: var(--teal-300);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card-dark {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: var(--border-radius-lg);
  padding: 20px;
  transition: var(--transition-slow);
}

.card-dark:hover {
  border-color: rgba(20,160,133,0.35);
  background: rgba(255,255,255,0.065);
}

.card-icon {
  width: 42px;
  height: 42px;
  background: linear-gradient(135deg, rgba(20,160,133,0.12), rgba(20,160,133,0.06));
  border: 1px solid rgba(20,160,133,0.2);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  font-size: 18px;
}

.card-title {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  color: var(--navy-900);
  margin-bottom: 10px;
  letter-spacing: -0.2px;
}

.card-title-light {
  color: var(--white);
}

.card-text {
  font-size: 14.5px;
  color: var(--gray-500);
  line-height: 1.65;
}

.card-text-light {
  color: rgba(255,255,255,0.58);
}

/* ============================================================
   STAT PILL / METRIC
   ============================================================ */
.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(20,160,133,0.1);
  border: 1px solid rgba(20,160,133,0.2);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--teal-400);
}

.metric-value {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 44px);
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1;
}

.metric-label {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3px;
  color: var(--gray-500);
  margin-top: 6px;
}

/* ============================================================
   BADGE / TAG
   ============================================================ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 12px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.3px;
}

.badge-teal {
  background: rgba(20,160,133,0.12);
  color: var(--teal-400);
  border: 1px solid rgba(20,160,133,0.25);
}

.badge-amber {
  background: rgba(251,191,36,0.12);
  color: var(--amber-400);
  border: 1px solid rgba(251,191,36,0.25);
}

.badge-navy {
  background: rgba(14,32,64,0.08);
  color: var(--navy-700);
  border: 1px solid rgba(14,32,64,0.15);
}

/* ============================================================
   DIVIDER
   ============================================================ */
.divider {
  height: 1px;
  background: var(--gray-200);
  margin: 0;
}
.divider-dark {
  height: 1px;
  background: rgba(255,255,255,0.07);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--navy-950);
  border-top: 1px solid rgba(255,255,255,0.07);
  padding: 36px 0 22px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 28px;
}

.footer-brand-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.48);
  line-height: 1.65;
  margin: 12px 0 16px;
  max-width: 280px;
}

.footer-col-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  margin-bottom: 18px;
}

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

.footer-link {
  font-size: 14px;
  color: rgba(255,255,255,0.52);
  transition: var(--transition);
}

.footer-link:hover {
  color: var(--teal-400);
}

.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid rgba(255,255,255,0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-copyright {
  font-size: 13px;
  color: rgba(255,255,255,0.3);
}

.footer-bottom-links {
  display: flex;
  gap: 24px;
}

.footer-bottom-link {
  font-size: 13px;
  color: rgba(255,255,255,0.3);
  transition: var(--transition);
}

.footer-bottom-link:hover { color: rgba(255,255,255,0.6); }

.footer-compliance-badges {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.compliance-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 10px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.5px;
}

/* ============================================================
   GRID UTILITIES
   ============================================================ */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

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

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 16px; text-align: center; }
  .nav-links, .nav-cta { display: none; }
  .nav-hamburger { display: flex; }
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideRight {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(0.97); }
}

@keyframes flowDot {
  0% { transform: translateX(0); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateX(160px); opacity: 0; }
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.animate-fade-up {
  animation: fadeUp 0.6s ease forwards;
}

.animate-delay-1 { animation-delay: 0.1s; opacity: 0; }
.animate-delay-2 { animation-delay: 0.2s; opacity: 0; }
.animate-delay-3 { animation-delay: 0.3s; opacity: 0; }
.animate-delay-4 { animation-delay: 0.4s; opacity: 0; }

/* Intersection Observer triggered */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(24px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}
.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

/* ============================================================
   MISC UI
   ============================================================ */

/* Gradient line top accent */
.accent-line {
  height: 3px;
  background: linear-gradient(90deg, var(--teal-600), var(--teal-400), var(--teal-300));
  width: 48px;
  border-radius: 3px;
  margin-bottom: 16px;
}

.accent-line-center { margin: 0 auto 24px; }

/* Dot grid bg decoration */
.bg-dot-grid {
  background-image: radial-gradient(circle, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 32px 32px;
}

/* Glow effects */
.glow-teal {
  box-shadow: 0 0 0 1px rgba(20,160,133,0.2), 0 8px 32px rgba(20,160,133,0.15);
}

/* Number circle */
.num-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal-600), var(--teal-400));
  color: white;
  font-size: 15px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Checkmark list */
.check-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 16px;
}

.check-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14.5px;
  color: var(--gray-600);
  line-height: 1.5;
}

.check-item-light { color: rgba(255,255,255,0.62); }

.check-icon {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(20,160,133,0.15);
  border: 1px solid rgba(20,160,133,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
  font-size: 10px;
  color: var(--teal-400);
}

/* Horizontal rule */
hr { border: none; height: 1px; background: var(--gray-200); }

/* Quote block */
.quote-block {
  border-left: 3px solid var(--teal-500);
  padding: 16px 24px;
  background: rgba(20,160,133,0.04);
  border-radius: 0 8px 8px 0;
}

/* Tag row */
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

/* Tooltip basic */
[data-tooltip] {
  position: relative;
}
[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--navy-900);
  color: white;
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 6px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
}
[data-tooltip]:hover::after { opacity: 1; }

/* Tab UI */
.tabs {
  display: flex;
  gap: 4px;
  background: var(--gray-100);
  border-radius: 10px;
  padding: 4px;
  width: fit-content;
}

.tab-btn {
  padding: 9px 20px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--gray-500);
  border-radius: 7px;
  transition: var(--transition);
  letter-spacing: 0.1px;
}

.tab-btn.active, .tab-btn:hover {
  background: var(--white);
  color: var(--navy-900);
  box-shadow: var(--shadow-sm);
}

.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* Progress bar */
.progress-bar {
  height: 6px;
  background: var(--gray-200);
  border-radius: 3px;
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--teal-600), var(--teal-400));
  border-radius: 3px;
  transition: width 1.2s ease;
}

/* Sticky CTA bar */
.sticky-cta {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  background: var(--navy-950);
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 14px 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 900;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.sticky-cta.visible {
  transform: translateY(0);
}

.sticky-cta-text {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
}

/* Scroll progress indicator */
.scroll-progress {
  position: fixed;
  top: 68px; left: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--teal-600), var(--teal-400));
  z-index: 1001;
  transition: width 0.1s linear;
}

/* Table styles */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.data-table th {
  padding: 12px 16px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gray-400);
  border-bottom: 1px solid var(--gray-200);
}

.data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700);
}

.data-table tr:hover td { background: var(--gray-50); }

/* Range input (calculator) */
input[type=range] {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: var(--gray-200);
  outline: none;
}

input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--teal-500);
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(20,160,133,0.35);
}
