/* ==========================================================================
   DiamondWells marketing site v2 - modern fintech pass over the scraped
   Materialize/crest-capital base. Loads LAST in fronpage/main.html and
   restyles every public page through the shared classes + CSS variables.
   ========================================================================== */

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

html {
  --hover: #eef0fe !important;
  --nav-primary-font-colour: #101828 !important;
  --nav-secondary-font-colour: #667085 !important;
  --background-colour: #f4f6fb !important;
  --background-font-colour: #475467 !important;
  --background-heading-colour: #0f1d40 !important;
  --primary-background: #ffffff !important;
  --primary-font-colour: #0f1d40 !important;
  --primary-border-colour: #e6eaf2 !important;
  --primary-link-colour: #4154f1 !important;
  --secondary-background: #0c1b45 !important;
  --secondary-font-colour: #b7c3e5 !important;
  --secondary-heading-colour: #ffffff !important;
  --border-colour: #e6eaf2 !important;
}

body {
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif !important;
  background: var(--background-colour);
  color: var(--background-font-colour);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Plus Jakarta Sans', 'Inter', system-ui, sans-serif !important;
  font-weight: 800 !important;
  letter-spacing: -.02em;
  line-height: 1.2;
}
h1 { font-size: clamp(2.1rem, 4.5vw, 3.3rem) !important; margin: 0 0 1rem; }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.3rem) !important; margin: 0 0 .9rem; }
h3 { font-size: clamp(1.3rem, 2.4vw, 1.7rem) !important; margin: 0 0 .7rem; }
.f-24 { font-size: 1.08rem !important; line-height: 1.7; }
.f-20 { font-size: 1rem !important; line-height: 1.7; }

/* ---------- sections ---------- */
.bg { background: var(--background-colour); }
.bg.bg-secondary {
  background: linear-gradient(160deg, #071233 0%, #0c1b45 55%, #14276b 100%) !important;
  color: #c4cfec;
}
.bg.bg-secondary h1, .bg.bg-secondary h2, .bg.bg-secondary h3 { color: #fff; }
.bg.bg-secondary p { color: #c4cfec; }
article { border: 0 !important; }

/* ---------- navbar (flex rebuild; markup in fronpage/main.html) ---------- */
.navbar-fixed { height: 68px !important; }
.navbar-fixed nav.dw-nav {
  background: rgba(255, 255, 255, .9) !important;
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid #e6eaf2;
  box-shadow: none !important;
  height: 68px;
  line-height: normal;
  padding: 0;
}
.dw-nav-wrap {
  display: flex;
  align-items: center;
  gap: 1.6rem;
  height: 68px;
  max-width: 1180px;
  width: 92%;
}
.dw-nav-brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
  flex: 0 0 auto;
}
.dw-nav-brand img { height: 34px; width: 34px; }
.dw-nav-brand span {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800;
  font-size: 1.12rem;
  color: #0f1d40;
  letter-spacing: -.01em;
}
.dw-nav-links {
  display: flex;
  align-items: center;
  gap: .35rem;
}
.dw-nav-links > a, .dw-nav-links .dw-nav-drop-toggle {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: #344054 !important;
  font-weight: 600;
  font-size: .92rem;
  line-height: normal;
  padding: .5rem .8rem !important;
  border-radius: 10px;
  background: transparent !important;
}
.dw-nav-links > a:hover, .dw-nav-item:hover .dw-nav-drop-toggle {
  color: #4154f1 !important;
  background: #eef0fe !important;
}
.dw-nav-drop-toggle .material-icons { font-size: 18px; margin-top: 1px; }

/* dropdown submenus */
.dw-nav-item { position: relative; }
.dw-nav-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 210px;
  background: #fff;
  border: 1px solid #e6eaf2;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(16, 24, 40, .14);
  padding: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity .15s ease, transform .15s ease, visibility .15s;
  z-index: 1100;
}
.dw-nav-item::after {
  /* invisible bridge so the menu does not close crossing the 6px gap */
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: 100%;
  height: 10px;
}
.dw-nav-item:hover .dw-nav-menu, .dw-nav-item:focus-within .dw-nav-menu {
  opacity: 1;
  visibility: visible;
  transform: none;
}
.dw-nav-menu a {
  display: block;
  padding: .55rem .8rem !important;
  border-radius: 9px;
  color: #344054 !important;
  font-weight: 600;
  font-size: .9rem;
  line-height: normal;
  background: transparent !important;
}
.dw-nav-menu a:hover { background: #eef0fe !important; color: #4154f1 !important; }
body.dark .dw-nav-menu {
  background: #111a2e;
  border-color: #1e2a44;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .5);
}
body.dark .dw-nav-menu a { color: #cdd6ea !important; }
body.dark .dw-nav-menu a:hover { background: rgba(255, 255, 255, .07) !important; color: #8b9cf5 !important; }
.dw-nav-actions {
  display: flex;
  align-items: center;
  gap: .65rem;
  margin-left: auto;
}
.dw-nav-theme {
  width: 40px; height: 40px;
  border: 0 !important;
  border-radius: 50%;
  background: transparent !important;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  padding: 0 !important;
  line-height: 1;
  box-shadow: none !important;
}
.dw-nav-theme .change {
  color: #667085;
  font-size: 22px;
  line-height: 1;
  display: block;
}
/* materialize paints focused buttons teal; never let that through */
.dw-nav-theme:focus, .dw-nav-theme:focus-visible, .dw-nav-theme:active {
  background: transparent !important;
  outline: none;
}
.dw-nav-theme:hover, .dw-nav-theme:hover:focus { background: #eef0fe !important; }
.dw-nav-theme:hover .change { color: #4154f1; }
body.dark .dw-nav-theme:hover, body.dark .dw-nav-theme:hover:focus {
  background: rgba(255, 255, 255, .07) !important;
}
a.dw-nav-login {
  color: #344054 !important;
  font-weight: 700;
  font-size: .9rem;
  padding: 0 12px !important;
  line-height: 40px;
  border-radius: 10px;
  background: transparent !important;
}
a.dw-nav-login:hover { color: #4154f1 !important; background: #eef0fe !important; }
a.dw-nav-cta {
  display: inline-block;
  background: #4154f1 !important;
  color: #fff !important;
  font-weight: 700;
  font-size: .9rem;
  height: 40px;
  line-height: 40px;
  padding: 0 18px !important;
  border-radius: 12px;
  white-space: nowrap;
}
a.dw-nav-login { white-space: nowrap; }
a.dw-nav-cta:hover { background: #3242d8 !important; }
a.dw-nav-burger {
  display: none;
  width: 42px; height: 42px;
  align-items: center; justify-content: center;
  border-radius: 10px;
  cursor: pointer;
  padding: 0 !important;
  background: transparent !important;
}
a.dw-nav-burger:hover { background: #eef0fe !important; }
a.dw-nav-burger .toggle-sidebar-btn { color: #344054 !important; font-size: 26px; }
@media (max-width: 992px) {
  .dw-nav-links { display: none; }
  a.dw-nav-burger { display: flex; }
  .dw-nav-wrap { gap: .8rem; }
}
/* Small phones: the whole row (brand + toggle + CTA + burger) must fit 360px */
@media (max-width: 480px) {
  .dw-nav-wrap { width: 100%; padding: 0 10px; gap: .45rem; }
  .dw-nav-actions { gap: .3rem; }
  .dw-nav-brand img { height: 28px; width: 28px; }
  .dw-nav-brand span { font-size: .98rem; }
  .dw-nav-theme { width: 36px; height: 36px; }
  a.dw-nav-login { display: none; }
  a.dw-nav-cta { padding: 0 12px !important; font-size: .84rem; }
}
@media (max-width: 374px) {
  .dw-nav-brand span { display: none; }
}

/* dark mode: the rebuilt nav (the old body.dark nav ul rules do not match it) */
body.dark .navbar-fixed nav.dw-nav {
  background: rgba(11, 17, 32, .92) !important;
  border-bottom-color: #1e2a44;
}
body.dark .dw-nav-brand span { color: #e7ecf6; }
body.dark .dw-nav-links a, body.dark a.dw-nav-login { color: #cdd6ea !important; }
body.dark .dw-nav-links a:hover, body.dark a.dw-nav-login:hover {
  color: #8b9cf5 !important;
  background: rgba(255, 255, 255, .07) !important;
}
body.dark .dw-nav-theme .change { color: #9aa5bd; }
body.dark .dw-nav-theme:hover { background: rgba(255, 255, 255, .07); }
body.dark .dw-nav-theme:hover .change { color: #8b9cf5; }
body.dark a.dw-nav-burger .toggle-sidebar-btn { color: #cdd6ea !important; }
body.dark a.dw-nav-burger:hover { background: rgba(255, 255, 255, .07) !important; }
body.dark .dw-nav-brand img { background: #fff; border-radius: 8px; padding: 2px; }

/* ---------- drawer (mobile sitemap) ---------- */
aside#sidebar.sidebar {
  position: fixed;
  top: 0; bottom: 0; left: -310px;
  width: 300px;
  z-index: 1200;
  overflow-y: auto;
  transition: left .25s ease;
  padding: 10px 8px;
}
body.toggle-sidebar aside#sidebar.sidebar { left: 0; }

/* ---------- buttons (site-wide, flat - no glow) ---------- */
.btn, .btn-large {
  border-radius: 14px !important;
  background: #4154f1;
  color: #fff;
  font-weight: 700 !important;
  text-transform: none !important;
  letter-spacing: 0 !important;
  box-shadow: none !important;
  transition: background .15s ease, transform .12s ease;
}
.btn:hover, .btn-large:hover { background: #3242d8; box-shadow: none !important; }
.btn:active, .btn-large:active { transform: scale(.98); }
.btn-large {
  height: 52px !important;
  line-height: 52px !important;
  padding: 0 28px !important;
  font-size: 1rem !important;
  border-radius: 14px !important;
}

/* ---------- cards (pricing etc.) ---------- */
.card {
  border-radius: 18px !important;
  border: 1px solid #e6eaf2 !important;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 6px 22px rgba(16, 24, 40, .06) !important;
  transition: transform .18s ease, box-shadow .18s ease;
  background: #fff;
}
.card.hoverable:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(16, 24, 40, .12) !important;
}
.alt-color { color: #4154f1 !important; }

/* Cards stay light even inside dark (bg-secondary) sections - the section
   text rules must never bleed into them. This was washing out the pricing. */
.bg.bg-secondary .card,
.bg.bg-secondary .card p,
.bg.bg-secondary .card span { color: #475467; }
.bg.bg-secondary .card h1, .bg.bg-secondary .card h2, .bg.bg-secondary .card h3,
.bg.bg-secondary .card h4, .bg.bg-secondary .card h5, .bg.bg-secondary .card h6 { color: #0f1d40; }
.bg.bg-secondary .card .alt-color { color: #4154f1 !important; }

/* pricing plan name chip */
.card center > span:first-child {
  display: inline-block;
  font-weight: 700;
  font-size: .78rem;
  letter-spacing: .1em;
  color: #667085;
  background: #f1f4fa;
  border-radius: 999px;
  padding: .3rem 1rem;
  margin: .9rem 0 .5rem;
}
.card center > span.alt-color { background: transparent; letter-spacing: 0; }

/* ---------- FAQ accordions ---------- */
ul.collapsible {
  border: 0 !important;
  box-shadow: none !important;
  margin: 0;
}
ul.collapsible > li {
  background: #fff;
  border: 1px solid #e6eaf2 !important;
  border-radius: 14px !important;
  margin-bottom: 10px;
  overflow: hidden;
}
.collapsible-header {
  font-weight: 600;
  color: #0f1d40 !important;
  background: #fff !important;
  border-bottom: 0 !important;
  padding: 1rem 1.2rem !important;
  font-size: .97rem;
}
.collapsible-header i { color: #4154f1 !important; }
.collapsible-body {
  border-bottom: 0 !important;
  background: #f8fafd !important;
  color: #475467;
  padding: 1.1rem 1.3rem !important;
}

/* ---------- drawer sidebar ---------- */
aside#sidebar.sidebar, .sidebar {
  background: #fff !important;
  box-shadow: 0 20px 60px rgba(16, 24, 40, .18) !important;
}
.sidebar .user-view .background img { border-radius: 0 !important; }
.sidebar-nav .nav-link, .sidebar-nav .nav-item a {
  font-family: 'Inter', sans-serif !important;
  font-weight: 600;
  color: #475467 !important;
  border-radius: 10px;
  margin: 2px 10px;
  font-size: .92rem !important;
}
.sidebar-nav .nav-link:hover { background: #eef0fe !important; color: #4154f1 !important; }
.sidebar-nav .nav-link i, .sidebar-nav .nav-link .material-icons { color: inherit !important; }

/* ---------- video ---------- */
.video-container {
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 16px 44px rgba(16, 24, 40, .16);
  max-width: 880px;
  margin: 0 auto;
}

/* ---------- mobile section rhythm ---------- */
@media (max-width: 992px) {
  .bg.bg-secondary .container.app-py-3 { padding-top: 1.6rem; }
  /* Stack sections content-first on phones (the scraped rows use
     wrap-reverse, which shoved images against the navbar) */
  article .row.container, article .container.row { flex-wrap: wrap !important; }
  .app-mobile-center { text-align: center; }
  .dw-hero-stats { justify-content: center; gap: 1.6rem; }
  .dw-btn-ghost-front { margin-left: 0; margin-top: 10px; }
  h1 { font-size: 2.1rem !important; }
  article .container.row, .row.container { margin-left: auto; margin-right: auto; }
  img.responsive-img { max-height: 46vh; width: auto; }
}

/* ---------- hero polish (first section of the homepage) ---------- */
.dw-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  background: rgba(255, 255, 255, .1);
  border: 1px solid rgba(255, 255, 255, .22);
  color: #dbe3ff !important;
  border-radius: 999px;
  padding: .35rem 1rem;
  font-size: .82rem;
  font-weight: 600;
}
.dw-hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 2.2rem;
  margin-top: 2rem;
}
.dw-hero-stats b {
  display: block;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
}
.dw-hero-stats span { color: #9fb0dd; font-size: .85rem; }
.dw-btn-ghost-front {
  display: inline-block;
  border-radius: 14px;
  height: 52px;
  line-height: 49px;   /* border compensation - matches .btn-large visually */
  box-sizing: border-box;
  padding: 0 28px;
  margin-left: 10px;
  color: #fff !important;
  font-weight: 700;
  font-size: 1rem;
  border: 1.5px solid rgba(255, 255, 255, .35);
  background: rgba(255, 255, 255, .08);
  transition: background .15s ease;
  vertical-align: top;
}
.dw-btn-ghost-front:hover { background: rgba(255, 255, 255, .18); }

/* ---------- footer (markup in fronpage/main.html) ---------- */
footer.dw-foot {
  background: #071233;
  color: #8fa0cb;
  padding: 3.2rem 0 2rem;
  font-size: .9rem;
}
.dw-foot-wrap { max-width: 1180px; width: 92%; margin: 0 auto; }
.dw-foot-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 2rem;
  margin-bottom: 2.2rem;
}
@media (max-width: 992px) { .dw-foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .dw-foot-grid { grid-template-columns: 1fr; } }
.dw-foot-brand {
  display: inline-flex; align-items: center; gap: .6rem;
  color: #fff; text-decoration: none;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 800; font-size: 1.1rem;
}
.dw-foot-brand img { height: 32px; width: 32px; }
.dw-foot h6 {
  color: #fff !important;
  font-size: .82rem !important;
  font-weight: 700 !important;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.dw-foot a { color: #9daccf !important; display: block; padding: .28rem 0; }
.dw-foot a:hover { color: #fff !important; }
.dw-foot .dw-foot-note {
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding-top: 1.4rem;
  color: #8fa0cb;
  font-size: .78rem;
  line-height: 1.7;
  text-align: left;
}
.dw-foot .dw-foot-copy { color: #8fa0cb; margin-top: 1rem; font-size: .82rem; }

/* ---------- dark mode (marketing) ---------- */
body.dark {
  --background-colour: #0b1120 !important;
  --primary-background: #111a2e !important;
  --primary-font-colour: #e7ecf6 !important;
  --background-font-colour: #9aa5bd !important;
  --background-heading-colour: #e7ecf6 !important;
  --border-colour: #1e2a44 !important;
  background: #0b1120 !important;
  color: #9aa5bd !important;
}
body.dark .navbar-fixed nav, body.dark nav.bg.bg-secondary {
  background: rgba(13, 20, 38, .88) !important;
  border-bottom-color: #1e2a44;
}
body.dark nav .nav-wrapper li a, body.dark nav ul a { color: #cdd6ea !important; }
body.dark nav h6 { color: #fff !important; }
body.dark .card, body.dark ul.collapsible > li {
  background: #111a2e !important;
  border-color: #1e2a44 !important;
}
body.dark .collapsible-header { background: #111a2e !important; color: #e7ecf6 !important; }
body.dark .collapsible-body { background: #0e1628 !important; color: #9aa5bd; }
body.dark .card p, body.dark .card span { color: #9aa5bd; }
body.dark aside#sidebar.sidebar, body.dark .sidebar { background: #111a2e !important; }
body.dark .sidebar-nav .nav-link { color: #9aa5bd !important; }

/* ---------- article/legal content styling ---------- */
.card-panel { border-radius: 18px !important; }
.card-panel h2, .card-panel .dw-legal-h {
  font-family: 'Plus Jakarta Sans', sans-serif !important;
  font-size: 1.18rem !important;
  font-weight: 700 !important;
  color: #0f1d40;
  margin: 1.8rem 0 .5rem;
  line-height: 1.35;
}
body.dark .card-panel h2, body.dark .card-panel .dw-legal-h { color: #e7ecf6; }
body.dark .card-panel { background: #111a2e !important; color: #9aa5bd; }
body.dark .card-panel a, body.dark .card a { color: #8b9cf5; }
ul.dw-legal-list { list-style: disc; padding-left: 1.3rem; margin: .6rem 0 1rem; }
ul.dw-legal-list li { padding: .2rem 0; }

/* dark pricing cards: outrank the light-section card rules */
body.dark .bg.bg-secondary .card,
body.dark .bg.bg-secondary .card p,
body.dark .bg.bg-secondary .card span,
body.dark .card p, body.dark .card span { color: #9aa5bd; }
body.dark .bg.bg-secondary .card h1, body.dark .bg.bg-secondary .card h2,
body.dark .bg.bg-secondary .card h3, body.dark .bg.bg-secondary .card h4,
body.dark .bg.bg-secondary .card h5, body.dark .bg.bg-secondary .card h6 { color: #e7ecf6; }
body.dark .bg.bg-secondary .card .alt-color, body.dark .card .alt-color { color: #8b9cf5 !important; }
body.dark .card center > span:first-child { background: #1a2440; color: #9aa5bd; }

/* dark form inputs (contact page uses materialize input-field) */
body.dark .input-field input, body.dark .input-field textarea,
body.dark input.validate, body.dark textarea.materialize-textarea {
  color: #e7ecf6 !important;
  border-bottom-color: #33405e !important;
}
body.dark .input-field input::placeholder, body.dark .input-field textarea::placeholder,
body.dark input.validate::placeholder, body.dark textarea.materialize-textarea::placeholder {
  color: #9aa5bd !important;
  opacity: 1;
}

/* feature illustrations: equal boxes, readable on dark */
article.bg.center .row img.responsive-img { height: 140px; object-fit: contain; }
body.dark article.bg.center .row img.responsive-img {
  background: #eef2f9;
  border-radius: 16px;
  padding: 10px;
}

/* install-app step pager in dark mode */
body.dark .dwi-nav-btn { background: #4154f1; }
body.dark .dwi-nav-btn:disabled { background: #2a3550; color: #66719b; }
body.dark .dwi-tab { border-color: #6172ff; color: #8b9cf5; }
body.dark .dwi-tab.active { background: #4154f1; border-color: #4154f1; color: #fff; }
body.dark .dwi-caption, body.dark .dwi-counter { color: #9aa5bd; }
body.dark .dwi-caption b { color: #e7ecf6; }

/* hero bands: brand navy wash over the scraped stock imagery so third
   party logos and off-palette colors never show through */
.overlay1, .overlay2 {
  /* fully opaque: even 4% bleed made the stock-photo brand logos legible */
  background: linear-gradient(120deg, rgb(7, 18, 51), rgb(23, 42, 112)) !important;
  opacity: 1 !important;
}

/* the scraped input padding rule omits type=tel (contact page phone field) */
input[type="tel"]:not(.browser-default) { padding-left: 10px !important; box-sizing: border-box; }

/* hero titles need breathing room on phones */
@media (max-width: 992px) {
  .hero-mixed h1, .hero-mixed p { padding-left: 1.25rem; padding-right: 1.25rem; }
  .app-text-justify { text-align: left !important; }
}

/* ---------- misc ---------- */
::selection { background: #4154f1; color: #fff; }
img.responsive-img { border-radius: 6px; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; transition-duration: .001s !important; }
}
