/*
 * CollabTrust Design System v2 – Dark + Gold
 * Shared CSS for all public-facing pages
 * ═══════════════════════════════════════════
 */

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

:root {
  --bg: #0c0b0f;
  --bg-elevated: #15141a;
  --bg-card: #1a1920;
  --accent: #e8a838;
  --accent-soft: #f0c060;
  --accent-glow: rgba(232,168,56,0.12);
  --accent-glow-strong: rgba(232,168,56,0.25);
  --text: #edeae4;
  --text-secondary: #9e9a92;
  --text-muted: #5e5b56;
  --border: rgba(255,255,255,0.06);
  --border-accent: rgba(232,168,56,0.18);
  --radius: 20px;
  --radius-sm: 12px;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, sans-serif;
  --danger: #e74c3c;
  --success: #2ecc71;
}

/* ── Reset ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.6;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-soft); }
img { max-width: 100%; height: auto; }

/* ── Ambient background ── */
.ct-ambient {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
}
.ct-ambient::before {
  content: ''; position: absolute;
  width: 900px; height: 900px; top: -350px; right: -200px;
  background: radial-gradient(circle, rgba(232,168,56,0.08) 0%, transparent 65%);
  animation: ct-float 20s ease-in-out infinite;
}
.ct-ambient::after {
  content: ''; position: absolute;
  width: 700px; height: 700px; bottom: -200px; left: -150px;
  background: radial-gradient(circle, rgba(232,168,56,0.05) 0%, transparent 65%);
  animation: ct-float 25s ease-in-out infinite reverse;
}
@keyframes ct-float {
  0%, 100% { transform: translate(0,0) scale(1); }
  50% { transform: translate(40px,30px) scale(1.08); }
}

/* ── Grain overlay ── */
.ct-grain {
  position: fixed; inset: 0; z-index: 1; pointer-events: none; opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-repeat: repeat; background-size: 180px;
}

/* ── Page wrapper ── */
.ct-page {
  position: relative; z-index: 2;
  max-width: 720px; margin: 0 auto; padding: 0 24px;
}
.ct-page-wide {
  position: relative; z-index: 2;
  max-width: 960px; margin: 0 auto; padding: 0 24px;
}

/* ── Navbar ── */
.ct-nav {
  display: flex; justify-content: space-between; align-items: center;
  padding: 28px 0;
  animation: ct-fadeDown 0.7s ease both;
}
.ct-logo {
  font-family: var(--font-display);
  font-size: 22px; font-weight: 800;
  color: var(--text); letter-spacing: -0.5px;
  cursor: pointer; text-decoration: none;
}
.ct-logo span { color: var(--accent); }
.ct-nav-badge {
  display: flex; align-items: center; gap: 8px;
  background: var(--accent-glow); border: 1px solid var(--border-accent);
  border-radius: 50px; padding: 6px 16px;
  font-size: 12px; font-weight: 600; color: var(--accent-soft);
  text-transform: uppercase; letter-spacing: 0.8px;
}
.ct-nav-badge .pulse {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); animation: ct-pulse 2s ease-in-out infinite;
}
.ct-nav-links { display: flex; align-items: center; gap: 28px; }
.ct-nav-links a {
  font-size: 14px; font-weight: 500; color: var(--text-secondary);
  transition: color 0.2s;
}
.ct-nav-links a:hover { color: var(--text); }
.ct-nav-links .ct-btn-nav {
  background: var(--accent); color: #0c0b0f;
  padding: 10px 22px; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 13px;
  transition: background 0.2s, transform 0.2s;
}
.ct-nav-links .ct-btn-nav:hover {
  background: var(--accent-soft); transform: translateY(-1px);
}

/* ── Hamburger (mobile) ── */
.ct-hamburger { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.ct-hamburger span { display: block; width: 22px; height: 2px; background: var(--text-secondary); border-radius: 2px; margin: 5px 0; transition: 0.3s; }

/* ── Typography ── */
.ct-heading {
  font-family: var(--font-display);
  font-weight: 900; letter-spacing: -1.5px; line-height: 1.08;
  color: var(--text);
}
.ct-heading em {
  font-style: normal;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-soft) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.ct-eyebrow {
  display: inline-block;
  font-size: 11px; font-weight: 700; letter-spacing: 2.5px; text-transform: uppercase;
  color: var(--accent);
}

/* ── Cards ── */
.ct-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px 24px; position: relative; overflow: hidden;
  transition: border-color 0.3s ease, transform 0.25s ease;
}
.ct-card:hover { border-color: var(--border-accent); transform: translateY(-3px); }
.ct-card::after {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0; transition: opacity 0.3s ease;
}
.ct-card:hover::after { opacity: 1; }

/* ── Content card (for legal pages etc) ── */
.ct-content-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 36px 32px; margin-bottom: 20px;
}
.ct-content-card h2 {
  font-family: var(--font-display); font-size: 1.2rem; font-weight: 800;
  color: var(--text); margin-bottom: 16px; display: flex; align-items: center; gap: 10px;
}
.ct-content-card h3 {
  font-size: 15px; font-weight: 700; margin: 20px 0 8px; color: var(--text);
}
.ct-content-card p {
  font-size: 14px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 12px;
}
.ct-content-card ul { padding-left: 20px; margin-bottom: 12px; }
.ct-content-card ul li {
  font-size: 14px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 4px;
}

/* ── Highlight box ── */
.ct-highlight {
  background: var(--accent-glow); border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 14px 18px; margin: 16px 0;
  font-size: 14px; color: var(--text-secondary); line-height: 1.7;
}

/* ── Contact box ── */
.ct-contact-box {
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 14px; padding: 20px; margin-top: 16px;
}
.ct-contact-box p { margin-bottom: 6px; font-size: 14px; color: var(--text-secondary); }
.ct-contact-box strong { color: var(--text); }

/* ── TOC ── */
.ct-toc {
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: 14px; padding: 20px 24px; margin-bottom: 32px;
}
.ct-toc h3 { font-size: 15px; font-weight: 700; margin-bottom: 12px; color: var(--text); }
.ct-toc a {
  display: block; font-size: 14px; color: var(--accent); padding: 4px 0;
}
.ct-toc a:hover { color: var(--accent-soft); text-decoration: underline; }

/* ── Buttons ── */
.ct-btn-primary {
  display: inline-block; padding: 15px 32px; border: none; border-radius: var(--radius-sm);
  background: var(--accent); color: #0c0b0f;
  font-family: var(--font-body); font-size: 15px; font-weight: 700;
  cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: transform 0.2s ease, box-shadow 0.3s ease, background 0.3s ease;
}
.ct-btn-primary:hover {
  transform: translateY(-2px); color: #0c0b0f;
  box-shadow: 0 8px 28px rgba(232,168,56,0.3); background: var(--accent-soft);
}
.ct-btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.ct-btn-secondary {
  display: inline-block; padding: 15px 32px; border-radius: var(--radius-sm);
  background: transparent; color: var(--text);
  font-family: var(--font-body); font-size: 15px; font-weight: 700;
  border: 1.5px solid var(--border-accent); cursor: pointer; text-decoration: none;
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}
.ct-btn-secondary:hover {
  border-color: var(--accent); background: var(--accent-glow);
  transform: translateY(-1px); color: var(--text);
}

/* ── Forms ── */
.ct-input {
  width: 100%; padding: 14px 18px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--border);
  border-radius: var(--radius-sm); font-family: var(--font-body); font-size: 15px;
  color: var(--text); outline: none;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.ct-input::placeholder { color: var(--text-muted); }
.ct-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-glow); }
.ct-input.error { border-color: var(--danger); box-shadow: 0 0 0 3px rgba(231,76,60,0.15); }

.ct-label {
  display: block; font-size: 13px; font-weight: 600;
  color: var(--text-secondary); margin-bottom: 6px;
}

/* ── Form status ── */
.ct-form-status { margin-top: 16px; font-size: 14px; min-height: 22px; }
.ct-form-status.success { color: var(--success); font-weight: 600; }
.ct-form-status.error { color: var(--danger); }

/* ── Divider ── */
.ct-divider { border: none; border-top: 1px solid var(--border); margin: 40px 0; }

/* ── Stats row ── */
.ct-stats {
  display: flex; justify-content: center; gap: 48px;
  padding: 40px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.ct-stat { text-align: center; }
.ct-stat-num { font-family: var(--font-display); font-size: 32px; font-weight: 800; color: var(--accent); }
.ct-stat-label { font-size: 13px; color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* ── Hero banner (for legal pages) ── */
.ct-hero-banner {
  background: linear-gradient(135deg, var(--bg-elevated) 0%, var(--bg-card) 100%);
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 40px; margin-bottom: 32px; position: relative; overflow: hidden;
}
.ct-hero-banner::before {
  content: ''; position: absolute; top: -1px; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--accent), transparent 80%);
}
.ct-hero-banner h1 {
  font-family: var(--font-display); font-size: 28px; font-weight: 900;
  color: var(--text); margin-bottom: 8px;
}
.ct-hero-banner p { font-size: 14px; color: var(--text-secondary); }

/* ── Badge ── */
.ct-badge {
  display: inline-block; background: var(--accent-glow);
  color: var(--accent); border: 1px solid var(--border-accent);
  border-radius: 20px; padding: 4px 12px; font-size: 12px; font-weight: 600;
  margin-bottom: 16px;
}

/* ── FAQ ── */
.ct-faq-item {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  margin-bottom: 10px; background: var(--bg-card); overflow: hidden;
}
.ct-faq-q {
  padding: 18px 20px; font-size: 14px; font-weight: 600;
  cursor: pointer; display: flex; justify-content: space-between; align-items: center;
  user-select: none; transition: color 0.2s; color: var(--text);
}
.ct-faq-q:hover { color: var(--accent); }
.ct-faq-q .arrow { font-size: 11px; color: var(--text-muted); transition: transform 0.3s; }
.ct-faq-item.open .ct-faq-q .arrow { transform: rotate(180deg); }
.ct-faq-a { max-height: 0; overflow: hidden; transition: max-height 0.35s ease; }
.ct-faq-item.open .ct-faq-a { max-height: 200px; padding: 0 20px 18px; }
.ct-faq-a p { font-size: 13.5px; color: var(--text-secondary); line-height: 1.65; }

/* ── Footer ── */
.ct-footer {
  padding: 32px 0; border-top: 1px solid var(--border);
  text-align: center; font-size: 12px; color: var(--text-muted);
  margin-bottom: 40px;
}
.ct-footer a { color: var(--text-muted); text-decoration: underline; text-underline-offset: 3px; }
.ct-footer a:hover { color: var(--text-secondary); }

/* ── Animations ── */
@keyframes ct-fadeUp { from { opacity:0; transform:translateY(24px); } to { opacity:1; transform:translateY(0); } }
@keyframes ct-fadeDown { from { opacity:0; transform:translateY(-16px); } to { opacity:1; transform:translateY(0); } }
@keyframes ct-pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:.4;transform:scale(.7)} }

.ct-anim-1 { animation: ct-fadeUp 0.7s ease 0.1s both; }
.ct-anim-2 { animation: ct-fadeUp 0.7s ease 0.2s both; }
.ct-anim-3 { animation: ct-fadeUp 0.7s ease 0.3s both; }
.ct-anim-4 { animation: ct-fadeUp 0.7s ease 0.4s both; }
.ct-anim-5 { animation: ct-fadeUp 0.7s ease 0.5s both; }
.ct-anim-6 { animation: ct-fadeUp 0.7s ease 0.6s both; }

/* ── Mobile ── */
@media (max-width: 640px) {
  .ct-page, .ct-page-wide { padding: 0 18px; }
  .ct-stats { gap: 28px; flex-wrap: wrap; }
  .ct-stat-num { font-size: 26px; }
  .ct-nav-links { display: none; }
  .ct-hamburger { display: block; }
  .ct-hero-banner { padding: 28px 20px; }
  .ct-hero-banner h1 { font-size: 22px; }
  .ct-content-card { padding: 24px 20px; }
}
