/* ===========================================================================
   Simons Digital Solutions — main.css
   Light theme. Mobile-first. Single accent. No frameworks.
=========================================================================== */

/* ── Tokens ──────────────────────────────────────────────────────────────── */
:root {
  --bg:           #ffffff;
  --bg-soft:      #f6f8fa;
  --bg-subtle:    #eef1f4;
  --text:         #1c1c2e;
  --text-soft:    #4a4a5e;
  --text-muted:   #7a7a8c;
  --border:       #e3e6ec;
  --border-soft:  #eef1f4;
  --accent:       #0d7377;
  --accent-hover: #0a5a5e;
  --accent-soft:  #e3f2f3;
  --accent-tint:  #d2eaeb;
  --shadow-sm:    0 1px 2px rgba(15, 23, 42, 0.04);
  --shadow-md:    0 4px 12px rgba(15, 23, 42, 0.06);
  --shadow-lg:    0 12px 32px rgba(15, 23, 42, 0.10);
  --shadow-card:  0 12px 28px rgba(13, 115, 119, 0.10);
  --radius-sm:    6px;
  --radius-md:    8px;
  --radius-lg:    10px;
  --radius-xl:    16px;
  --max-w:        1100px;
  --max-w-text:   720px;
  --header-h:     72px;
}

/* ── Reset ───────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
               Oxygen, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg { display: block; max-width: 100%; height: auto; }
ul, ol { list-style: none; }
button { font: inherit; }

/* ── Typography ──────────────────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
}
h1 { font-size: clamp(2.6rem, 5vw, 3.6rem); font-weight: 700; }
h2 { font-size: 2rem; font-weight: 700; }
h3 { font-size: 1.2rem; font-weight: 600; }
h4 { font-size: 1.05rem; font-weight: 600; }
@media (max-width: 600px) {
  h1 { font-size: 2.2rem; }
  h2 { font-size: 1.6rem; }
}
p  { color: var(--text-soft); }
p + p { margin-top: 1em; }
a { color: var(--accent); text-decoration: none; transition: color 0.15s; }
a:hover, a:focus { color: var(--accent-hover); text-decoration: underline; }
.eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 14px;
}

/* ── Layout primitives ───────────────────────────────────────────────────── */
.container        { max-width: var(--max-w);      margin: 0 auto; padding: 0 24px; }
.container-narrow { max-width: var(--max-w-text); margin: 0 auto; padding: 0 24px; }
.section { padding: 56px 0; }
.section-tight { padding: 32px 0; }
.section-soft  { background: var(--bg-soft); }
@media (min-width: 768px) {
  .section       { padding: 88px 0; }
  .section-tight { padding: 48px 0; }
}
.text-center { text-align: center; }
.lead { font-size: 1.15rem; color: var(--text-soft); max-width: 60ch; line-height: 1.65; }

/* Section heading with teal underline accent */
.section-heading {
  display: flex; align-items: end; justify-content: space-between;
  flex-wrap: wrap; gap: 16px;
  margin-bottom: 32px;
}
.section-heading h2 {
  position: relative;
  padding-bottom: 14px;
  margin-bottom: 0;
  max-width: 22ch;
}
.section-heading h2::after {
  content: '';
  position: absolute; left: 0; bottom: 0;
  width: 56px; height: 3px;
  background: var(--accent);
  border-radius: 2px;
}
.section-heading .section-link { font-weight: 600; color: var(--accent); white-space: nowrap; }

/* ── Skip link (accessibility) ───────────────────────────────────────────── */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--accent); color: #fff;
  padding: 10px 16px; border-radius: 0 0 var(--radius-sm) 0;
  z-index: 1000;
}
.skip-link:focus { left: 0; }

/* ── Header ──────────────────────────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border-soft);
}
.site-header > .container {
  display: flex; align-items: center; justify-content: space-between;
  min-height: var(--header-h);
}
.wordmark {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
  color: var(--text);
  white-space: nowrap;
}
.wordmark:hover { text-decoration: none; color: var(--accent); }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  background: transparent; border: 1px solid var(--border);
  border-radius: var(--radius-sm); cursor: pointer; color: var(--text);
  transition: border-color 0.15s, color 0.15s;
}
.nav-toggle:hover { border-color: var(--accent); color: var(--accent); }
.nav-toggle svg { width: 22px; height: 22px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

.nav-menu {
  display: flex; gap: 28px; align-items: center;
  list-style: none;
}
.nav-menu a {
  color: var(--text); font-weight: 500; font-size: 0.97rem;
  padding: 8px 4px; position: relative;
  text-decoration: none;
  transition: color 0.15s;
}
.nav-menu a:hover { color: var(--accent); text-decoration: none; }
.nav-menu a.is-active { color: var(--accent); }
.nav-menu a.is-active::after {
  content: ''; position: absolute; left: 4px; right: 4px; bottom: 0;
  height: 2px; background: var(--accent); border-radius: 2px;
}

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; }
  .nav-menu {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0; align-items: stretch;
    background: #fff;
    border-bottom: 1px solid var(--border);
    padding: 8px 0 16px;
    transform: translateY(-8px);
    opacity: 0; pointer-events: none;
    transition: opacity 0.15s, transform 0.15s;
  }
  .nav-menu.is-open { opacity: 1; transform: translateY(0); pointer-events: auto; }
  .nav-menu li { width: 100%; }
  .nav-menu a {
    display: block; padding: 14px 24px;
    border-bottom: 1px solid var(--border-soft);
  }
  .nav-menu a.is-active::after { display: none; }
  .nav-menu a.is-active { background: var(--accent-soft); }
}
@media (min-width: 821px) {
  .nav-toggle { display: none; }
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-sm);
  font-weight: 600; font-size: 0.97rem;
  text-decoration: none; cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn-primary {
  background: var(--accent); color: #fff; border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn-secondary {
  background: #fff; color: var(--accent); border-color: var(--accent);
}
.btn-secondary:hover { background: var(--accent-soft); color: var(--accent-hover); }
.btn-on-dark {
  background: #fff; color: var(--accent);
}
.btn-on-dark:hover { background: var(--accent-soft); color: var(--accent); }

/* ── Hero ────────────────────────────────────────────────────────────────── */
.hero { padding: 80px 0 64px; }
@media (min-width: 768px) { .hero { padding: 112px 0 88px; } }
.hero h1 { max-width: 18ch; }
.hero .subhead {
  margin-top: 20px;
  font-size: 1.15rem;
  color: var(--text-soft);
  max-width: 60ch;
  line-height: 1.65;
}
@media (min-width: 768px) {
  .hero .subhead { font-size: 1.25rem; }
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

/* ── Card grid ───────────────────────────────────────────────────────────── */
.card-grid {
  display: grid; gap: 20px;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
}
@media (min-width: 960px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}
.card {
  display: flex; flex-direction: column;
  padding: 24px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  box-shadow: var(--shadow-sm);
}
.card:hover {
  border-color: var(--accent-tint);
  box-shadow: var(--shadow-card);
  transform: translateY(-3px);
}
.card .badge {
  align-self: flex-start;
  display: inline-block;
  padding: 4px 12px;
  font-size: 0.72rem; font-weight: 700;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 14px;
}
.card .badge.review       { background: var(--accent); color: #fff; }
.card .badge.howto        { background: var(--bg-subtle); color: var(--text-soft); }
.card .badge.alternatives { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
.card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 10px;
  color: var(--text);
}
.card .excerpt {
  color: var(--text-soft);
  font-size: 0.95rem;
  line-height: 1.6;
  flex-grow: 1;
}
.card .read-more {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 18px;
  font-weight: 600; font-size: 0.92rem;
  color: var(--accent);
  text-decoration: none;
}
.card .read-more::after {
  content: '→';
  transition: transform 0.15s;
}
.card:hover .read-more::after { transform: translateX(4px); }
.card .read-more:hover { color: var(--accent-hover); text-decoration: none; }

/* ── Two-column ──────────────────────────────────────────────────────────── */
.two-col {
  display: grid; grid-template-columns: 1fr; gap: 32px;
}
@media (min-width: 800px) {
  .two-col { grid-template-columns: 1fr 1fr; gap: 56px; }
}
.two-col h3 { margin-bottom: 12px; }

/* ── Banner CTA ──────────────────────────────────────────────────────────── */
.banner {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
  color: #fff;
  text-align: center;
  padding: 72px 0;
  position: relative;
  overflow: hidden;
}
.banner::before, .banner::after {
  content: ''; position: absolute; border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  pointer-events: none;
}
.banner::before { width: 360px; height: 360px; left: -120px; top: -160px; }
.banner::after  { width: 280px; height: 280px; right: -100px; bottom: -120px; }
.banner > .container { position: relative; }
.banner h2 { color: #fff; max-width: 24ch; margin: 0 auto; }
.banner h2::after { display: none; }
.banner p { color: rgba(255,255,255,0.9); max-width: 50ch; margin: 16px auto 0; }
.banner .btn { margin-top: 28px; }

/* ── Filter bar ──────────────────────────────────────────────────────────── */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin: 0 0 24px;
  padding: 4px 0;
}
.filter-bar button {
  padding: 8px 18px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--text-soft);
  border-radius: 999px;
  font-size: 0.9rem; font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}
.filter-bar button:hover { border-color: var(--accent); color: var(--accent); }
.filter-bar button.is-active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

/* ── Search box ──────────────────────────────────────────────────────────── */
.search-bar { margin-bottom: 16px; }
.search-input {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-family: inherit; font-size: 1rem;
  color: var(--text);
  background: #fff;
}
.search-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.search-hint {
  margin-top: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ── Feature tile (dashboards page) ──────────────────────────────────────── */
.feature-grid {
  display: grid; gap: 20px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .feature-grid { grid-template-columns: repeat(3, 1fr); gap: 24px; }
}
.feature-tile {
  padding: 32px 28px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: box-shadow 0.2s, transform 0.2s, border-color 0.2s;
}
.feature-tile:hover {
  box-shadow: var(--shadow-card);
  border-color: var(--accent-tint);
  transform: translateY(-3px);
}
.feature-tile .icon-box {
  width: 52px; height: 52px;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--accent);
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
}
.feature-tile .icon-box svg { width: 28px; height: 28px; }
.feature-tile h3 { font-size: 1.15rem; margin-bottom: 10px; }
.feature-tile p { font-size: 0.95rem; }

/* ── Demo iframes (side by side on desktop) ──────────────────────────────── */
.demo-grid {
  display: grid; gap: 28px;
  grid-template-columns: 1fr;
}
@media (min-width: 1024px) {
  .demo-grid { grid-template-columns: 1fr 1fr; }
}
.demo-block .demo-label {
  display: flex; align-items: baseline; justify-content: space-between;
  flex-wrap: wrap; gap: 8px;
  margin-bottom: 12px;
}
.demo-block .demo-label h3 {
  font-size: 1.1rem; font-weight: 600; color: var(--text);
}
.demo-block .demo-label .demo-tag {
  font-size: 0.78rem; font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.demo-frame-wrap {
  position: relative;
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  background: #ffffff;
}
.demo-frame {
  display: block;
  width: 100%;
  min-height: 650px;
  height: 70vh;
  max-height: 850px;
  border: 0;
  background: #ffffff;
}
.demo-block.is-dark .demo-frame-wrap { background: #0b0b0b; }
.demo-block.is-dark .demo-frame { background: #0b0b0b; }
.demo-caption {
  margin-top: 14px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* ── Forms ───────────────────────────────────────────────────────────────── */
.form {
  display: flex; flex-direction: column; gap: 22px;
  max-width: 600px; margin: 0 auto;
  background: #fff;
  padding: 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}
.form-field { display: flex; flex-direction: column; gap: 8px; }
.form-field label {
  font-weight: 600; font-size: 0.92rem;
  color: var(--text);
}
.form-field .req { color: var(--accent); margin-left: 2px; }
.form-field input,
.form-field textarea {
  width: 100%;
  padding: 13px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 1rem;
  color: var(--text);
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.form-field input:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.form-field textarea { min-height: 140px; resize: vertical; line-height: 1.55; }
.form .form-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.form .form-note { font-size: 0.85rem; color: var(--text-muted); }
.honeypot { position: absolute; left: -9999px; top: -9999px; visibility: hidden; }

.nf-thankyou {
  padding: 36px 32px;
  background: var(--accent-soft);
  border: 1px solid var(--accent-tint);
  border-radius: var(--radius-md);
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}
.nf-thankyou h3 { color: var(--accent); margin-bottom: 6px; }
.nf-thankyou p { color: var(--text-soft); }

.nf-error {
  margin-top: 12px;
  padding: 12px 14px;
  background: #fdecec;
  color: #8a1a1a;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
}

/* ── Prose body styling (about / contact) ─────────────────────────────── */
.prose h2 {
  margin-top: 1.8em; padding-bottom: 14px; position: relative;
}
.prose h2:first-of-type { margin-top: 1em; }
.prose h2::after {
  content: ''; position: absolute; left: 0; bottom: 0;
  width: 56px; height: 3px;
  background: var(--accent); border-radius: 2px;
}
.prose h3 { margin-top: 1.4em; }
.prose p { margin-top: 1em; line-height: 1.75; }
.prose ul {
  list-style: disc; padding-left: 24px; margin-top: 1em; color: var(--text-soft);
}
.prose ul li { margin-top: 6px; }
.prose .note,
.prose .disclaimer {
  margin-top: 36px;
  padding: 18px 22px;
  background: var(--bg-soft);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-size: 0.94rem;
  color: var(--text-soft);
}
.prose .disclaimer { font-style: italic; }

/* ── Contact details block ─────────────────────────────────────────────── */
.contact-details {
  display: flex; flex-wrap: wrap; gap: 24px;
  padding: 24px;
  background: var(--bg-soft);
  border-radius: var(--radius-md);
  margin-bottom: 32px;
}
.contact-details .detail { display: flex; align-items: center; gap: 10px; }
.contact-details .detail svg { width: 18px; height: 18px; color: var(--accent); flex-shrink: 0; }

/* ── Footer (dark charcoal, 3-column) ────────────────────────────────────── */
.site-footer {
  background: #1c1c2e;
  color: #d6d6e0;
  padding: 48px 0;
  margin-top: 80px;
}
.site-footer .footer-grid {
  display: grid;
  gap: 32px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .site-footer .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 48px;
  }
}
.site-footer h4 {
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
}
.site-footer .footer-brand {
  font-weight: 700;
  font-size: 1.1rem;
  color: #fff;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
.site-footer .footer-tagline {
  font-size: 0.92rem;
  color: #a0a0b0;
  line-height: 1.65;
  max-width: 36ch;
}
.site-footer ul { display: flex; flex-direction: column; gap: 8px; }
.site-footer ul a {
  color: #d6d6e0;
  font-size: 0.92rem;
  text-decoration: none;
  transition: color 0.15s;
}
.site-footer ul a:hover { color: var(--accent); text-decoration: none; }
.site-footer .contact-list { font-size: 0.92rem; color: #d6d6e0; line-height: 1.8; }
.site-footer .contact-list a { color: #d6d6e0; text-decoration: none; }
.site-footer .contact-list a:hover { color: var(--accent); }
.site-footer .footer-bottom {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 12px;
  font-size: 0.84rem;
  color: #8a8a9a;
}

/* ── Utility ─────────────────────────────────────────────────────────────── */
[hidden] { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); border: 0;
}
