/* ==========================================================================
   Spark — energetic startup theme
   ========================================================================== */

:root {
  --bg: #fffaf5;
  --bg-alt: #fff1e6;
  --bg-card: #ffffff;
  --border: #ffe0c7;
  --text: #241505;
  --text-dim: #6b5544;
  --text-dimmer: #a08d7c;
  --accent: #ff6b35;
  --accent-2: #ff2e93;
  --accent-text: #ffffff;

  --container-width: 1160px;
  --radius: 16px;
  --radius-lg: 24px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
h1, h2, h3 { line-height: 1.15; font-weight: 800; letter-spacing: -0.02em; }

.container { width: 100%; max-width: var(--container-width); margin: 0 auto; padding: 0 24px; }

.section { padding: 100px 0; position: relative; }
.section-tint { background: var(--bg-alt); }

.section-head { text-align: center; max-width: 620px; margin: 0 auto 56px; }
.section-head h2 { font-size: clamp(28px, 4vw, 42px); margin: 10px 0 0; }

.eyebrow {
  display: inline-block;
  background: rgba(255, 107, 53, 0.12);
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 7px 16px;
  border-radius: 999px;
}

.highlight {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 15px 30px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 15px;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease, background 0.15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: var(--accent-text);
  box-shadow: 0 10px 24px -8px rgba(255, 46, 147, 0.55);
}
.btn-primary:hover { transform: scale(1.06) rotate(-1deg); box-shadow: 0 14px 30px -8px rgba(255, 46, 147, 0.65); }

.btn-ghost { background: #fff; color: var(--text); border-color: var(--border); }
.btn-ghost:hover { transform: scale(1.06); border-color: var(--accent); }

.btn-lg { padding: 18px 36px; font-size: 16px; }

/* Header
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 18px 0;
  background: rgba(255, 250, 245, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.logo { font-size: 21px; font-weight: 800; color: var(--text); }

.main-nav ul { display: flex; gap: 32px; }
.main-nav a { font-size: 15px; font-weight: 700; color: var(--text-dim); transition: color 0.15s ease; }
.main-nav a:hover { color: var(--accent); }

.header-actions { display: flex; align-items: center; gap: 12px; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: #fff;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
}
.nav-toggle span { display: block; width: 16px; height: 2px; margin: 0 auto; background: var(--text); }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Hero
   ========================================================================== */

.hero { position: relative; padding: 130px 0 110px; text-align: center; overflow: hidden; }
.hero-inner { max-width: 760px; margin: 0 auto; position: relative; z-index: 1; }
.hero .eyebrow { margin-bottom: 22px; }
.hero h1 { font-size: clamp(36px, 6vw, 60px); margin-bottom: 22px; }
.hero p.lead { font-size: 19px; color: var(--text-dim); max-width: 580px; margin: 0 auto 36px; }
.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.hero-shapes { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.shape { position: absolute; border-radius: 42% 58% 65% 35% / 45% 40% 60% 55%; opacity: 0.5; animation: blobMove 12s ease-in-out infinite; }
.shape-1 { width: 320px; height: 320px; background: linear-gradient(135deg, #ffb37a, #ff6b35); top: -60px; left: -80px; }
.shape-2 { width: 260px; height: 260px; background: linear-gradient(135deg, #ff8fc4, #ff2e93); bottom: -60px; right: -60px; animation-delay: -4s; }
.shape-3 { width: 160px; height: 160px; background: linear-gradient(135deg, #ffd27a, #ff9d4d); top: 40%; right: 10%; opacity: 0.35; animation-delay: -8s; }

@keyframes blobMove {
  0%, 100% { transform: translate(0, 0) rotate(0deg) scale(1); border-radius: 42% 58% 65% 35% / 45% 40% 60% 55%; }
  50% { transform: translate(24px, -20px) rotate(8deg) scale(1.06); border-radius: 58% 42% 35% 65% / 40% 60% 45% 55%; }
}

/* Hero image — optional photo/screenshot shown under the hero actions */

.hero-image-wrap {
  max-width: 640px;
  margin: 48px auto 0;
  padding: 10px;
  background: var(--bg-card);
  border: 3px solid var(--accent);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 40px -16px rgba(255, 46, 147, 0.35);
}
.hero-image-wrap img { width: 100%; border-radius: calc(var(--radius-lg) - 8px); }

/* Feature cards
   ========================================================================== */

.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.feature-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px 24px;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), border-color 0.2s ease, box-shadow 0.2s ease;
}
.feature-card:hover { transform: translateY(-6px) rotate(-1deg); border-color: var(--accent); box-shadow: 0 16px 32px -12px rgba(255, 107, 53, 0.35); }

.card-icon { font-size: 30px; margin-bottom: 16px; }
.feature-card h3 { font-size: 17px; margin-bottom: 8px; }
.feature-card p { color: var(--text-dim); font-size: 14px; }

/* Process
   ========================================================================== */

.process-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.process-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 32px 26px;
  text-align: center;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.process-card:hover { transform: translateY(-6px); }

.process-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 800;
  font-size: 18px;
  margin-bottom: 18px;
}
.process-card h3 { font-size: 18px; margin-bottom: 10px; }
.process-card p { color: var(--text-dim); font-size: 14px; }

/* Stories
   ========================================================================== */

.story-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  transition: transform 0.2s ease;
}
.story-card:hover { transform: translateY(-4px); }
.story-quote { font-size: 15px; color: var(--text); margin-bottom: 18px; }
.story-author { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; color: var(--text-dim); }

.avatar-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 13px;
  font-weight: 800;
}

.avatar-photo {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

/* Launch video — shown under the founder stories grid */

.launch-video {
  max-width: 760px;
  margin: 48px auto 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 2px solid var(--border);
}

/* CTA
   ========================================================================== */

.cta-banner {
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
  background: linear-gradient(135deg, #fff1e6, #ffe3f0);
  border-radius: var(--radius-lg);
  padding: 56px 40px;
}
.cta-banner h2 { font-size: clamp(28px, 4vw, 36px); margin-bottom: 14px; }
.cta-banner p { color: var(--text-dim); font-size: 17px; margin-bottom: 30px; }

/* Footer
   ========================================================================== */

.site-footer { border-top: 1px solid var(--border); padding: 32px 0; text-align: center; }
.footer-bottom p { color: var(--text-dimmer); font-size: 13px; }
.footer-admin-link { margin-top: 4px; }
.footer-admin-link a { text-decoration: underline; opacity: 0.7; }
.footer-admin-link a:hover { opacity: 1; }

/* Scroll reveal
   ========================================================================== */

.reveal-up { opacity: 0; transform: translateY(28px); transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.16, 1, 0.3, 1); }
.reveal-up.is-visible { opacity: 1; transform: translateY(0); }

/* Responsive video/embed utility — used anywhere a cms_video() field renders */

.media-embed-16x9 { position: relative; padding-top: 56.25%; background: #000; }
.media-embed-16x9 iframe,
.media-embed-16x9 video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  object-fit: cover;
}

/* Responsive
   ========================================================================== */

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

@media (max-width: 768px) {
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    background: #fffaf5;
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.25s ease;
  }
  .main-nav.is-open { max-height: 320px; }
  .main-nav ul { flex-direction: column; padding: 8px 24px 20px; gap: 4px; }
  .main-nav a { display: block; padding: 12px 0; border-bottom: 1px solid var(--border); }
  .header-actions .btn { display: none; }
  .nav-toggle { display: flex; }
  .cta-banner { padding: 40px 24px; }
}

/* ==========================================================================
   Admin / install / auth — shared across every Deadmojo CMS-driven template.
   Uses var() fallbacks so it works whether or not the theme above defines
   --bg-card / --radius-lg.
   ========================================================================== */

.flash {
  margin: 16px auto 0;
  padding: 12px 18px;
  border-radius: var(--radius, 8px);
  font-size: 14px;
}
.flash-success { background: rgba(80, 200, 120, 0.12); border: 1px solid rgba(80, 200, 120, 0.35); color: #4fbd7a; }
.flash-error { background: rgba(220, 80, 70, 0.12); border: 1px solid rgba(220, 80, 70, 0.35); color: #e2685c; }

.demo-banner {
  background: var(--accent);
  color: var(--accent-text, #fff);
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  padding: 10px 16px;
  position: relative;
  z-index: 200;
}
.demo-banner a { text-decoration: underline; }

.auth-section { padding: 64px 0 80px; display: flex; justify-content: center; }

.auth-card {
  width: 100%;
  max-width: 380px;
  background: var(--bg-card, var(--bg-alt));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg, var(--radius, 12px));
  padding: 36px 32px;
}

.auth-card h1 { font-size: 24px; margin-bottom: 6px; text-align: center; }
.auth-subtext { color: var(--text-dim); font-size: 13px; text-align: center; margin-bottom: 24px; }
.demo-login-hint { font-size: 13px; color: var(--text-dim); background: var(--bg-alt); border: 1px solid var(--border); border-radius: var(--radius, 8px); padding: 10px 14px; margin-bottom: 20px; }

.form-errors { background: rgba(220, 80, 70, 0.1); border: 1px solid rgba(220, 80, 70, 0.3); border-radius: var(--radius, 8px); padding: 14px 18px; margin-bottom: 20px; font-size: 14px; color: #e2685c; }
.form-errors ul { list-style: disc; padding-left: 18px; }

.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; color: var(--text-dim); }
.field-help { font-size: 12px; color: var(--text-dimmer); margin: -2px 0 8px; }

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="url"],
.form-group input[type="file"],
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius, 8px);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
}
.form-group textarea { resize: vertical; }
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus { outline: none; border-color: var(--accent); }

.admin-video-url { margin-top: 8px; }

.admin-checkbox { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--text-dim); margin: 8px 0; }
.admin-checkbox input { width: auto; }

.admin-media-preview { margin-bottom: 10px; }
.admin-media-preview img { max-width: 220px; max-height: 140px; object-fit: cover; border-radius: var(--radius, 8px); border: 1px solid var(--border); }
.admin-media-preview video { max-width: 320px; border-radius: var(--radius, 8px); border: 1px solid var(--border); }

.admin-body { background: var(--bg); }
.admin-shell { display: flex; min-height: 100vh; align-items: flex-start; }

.admin-sidebar {
  width: 220px;
  flex-shrink: 0;
  min-height: 100vh;
  background: var(--bg-card, var(--bg-alt));
  border-right: 1px solid var(--border);
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
}
.admin-sidebar .logo { margin-bottom: 28px; font-size: 18px; display: block; }

.admin-nav { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.admin-nav a {
  padding: 10px 12px;
  border-radius: var(--radius, 8px);
  font-size: 14px;
  color: var(--text-dim);
}
.admin-nav a:hover { background: var(--bg-alt); text-decoration: none; }
.admin-nav a.is-active { background: rgba(255, 255, 255, 0.06); color: var(--accent); }

.admin-sidebar-footer {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 13px;
}
.admin-sidebar-footer a { color: var(--text-dim); }
.admin-sidebar-footer a:hover { color: var(--accent); }

.admin-main { flex: 1; padding: 40px; max-width: 900px; }
.admin-main h1 { font-size: 26px; margin-bottom: 6px; }
.admin-subtext { color: var(--text-dim); margin-bottom: 28px; }

.admin-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 32px; }
.admin-stat { background: var(--bg-card, var(--bg-alt)); border: 1px solid var(--border); border-radius: var(--radius-lg, var(--radius, 12px)); padding: 20px; }
.admin-stat-value { display: block; font-size: 28px; font-weight: 800; margin-bottom: 4px; color: var(--accent); }
.admin-stat-label { font-size: 12px; color: var(--text-dim); }

.admin-quicklinks { display: flex; gap: 10px; flex-wrap: wrap; }

.admin-form { max-width: 640px; }
.admin-form-wide { max-width: 720px; }

.admin-fieldset { border: 1px solid var(--border); border-radius: var(--radius-lg, var(--radius, 12px)); padding: 24px; margin-bottom: 24px; }
.admin-fieldset legend { padding: 0 8px; font-size: 15px; font-weight: 700; color: var(--accent); }

.install-body { display: flex; align-items: flex-start; justify-content: center; padding: 60px 20px; background: var(--bg); }
.install-card {
  width: 100%;
  max-width: 480px;
  background: var(--bg-card, var(--bg-alt));
  border: 1px solid var(--border);
  border-radius: var(--radius-lg, var(--radius, 12px));
  padding: 36px 32px;
}
.install-card h1 { font-size: 24px; margin-bottom: 24px; }
.install-card h2 { font-size: 16px; margin: 24px 0 12px; }
.install-card p { margin-bottom: 12px; font-size: 14px; color: var(--text-dim); }

.install-checklist { list-style: none; font-size: 14px; }
.install-checklist li { padding: 6px 0; }
.install-checklist .is-ok { color: #4fbd7a; }
.install-checklist .is-fail { color: #e2685c; font-weight: 600; }

.install-error { background: rgba(220, 80, 70, 0.1); border: 1px solid rgba(220, 80, 70, 0.3); border-radius: var(--radius, 8px); padding: 14px 18px; margin: 14px 0; font-size: 14px; }
.install-error ul { list-style: disc; padding-left: 18px; margin: 0; }
.install-success { color: #4fbd7a; font-weight: 600; font-size: 15px; }
.install-hint { font-size: 12px; color: var(--text-dimmer); }

@media (max-width: 768px) {
  .admin-shell { flex-direction: column; }
  .admin-sidebar { width: 100%; min-height: auto; position: static; flex-direction: row; align-items: center; flex-wrap: wrap; gap: 16px; }
  .admin-nav { flex-direction: row; flex-wrap: wrap; }
  .admin-sidebar-footer { flex-direction: row; border-top: none; padding-top: 0; margin-left: auto; }
  .admin-main { padding: 24px; }
  .admin-stats { grid-template-columns: repeat(2, 1fr); }
}
