/* WorshipSync – modern marketing + legal site */
:root {
  --bg: #f4f6fb;
  --bg-elevated: #ffffff;
  --text: #0c1222;
  --text-muted: #5c6578;
  --accent: #4338ca;
  --accent-bright: #6366f1;
  --accent-soft: rgba(99, 102, 241, 0.12);
  --accent-glow: rgba(99, 102, 241, 0.25);
  --border: rgba(12, 18, 34, 0.08);
  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 2px 8px rgba(12, 18, 34, 0.06);
  --shadow-lg: 0 20px 50px -24px rgba(67, 56, 202, 0.35), 0 12px 40px -20px rgba(12, 18, 34, 0.12);
  --font: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --header-h: 64px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0e14;
    --bg-elevated: #141821;
    --text: #f1f4fa;
    --text-muted: #9aa3b5;
    --accent: #818cf8;
    --accent-bright: #a5b4fc;
    --accent-soft: rgba(129, 140, 248, 0.15);
    --accent-glow: rgba(129, 140, 248, 0.2);
    --border: rgba(255, 255, 255, 0.08);
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 24px 60px -20px rgba(0, 0, 0, 0.5);
  }
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, var(--accent-glow), transparent),
    radial-gradient(ellipse 60% 40% at 100% 0%, rgba(124, 58, 237, 0.08), transparent),
    radial-gradient(ellipse 50% 30% at 0% 100%, rgba(59, 130, 246, 0.06), transparent);
  pointer-events: none;
}

/* —— Header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  height: var(--header-h);
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.header-inner {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 20px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.site-logo {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-logo-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 100%);
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 1.1rem;
}

.site-logo:hover .site-logo-mark {
  transform: scale(1.05);
  transition: transform 0.2s ease;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.nav-toggle svg {
  width: 22px;
  height: 22px;
}

.site-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.site-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.5rem 0.85rem;
  border-radius: 10px;
  transition: color 0.15s, background 0.15s;
}

.site-nav a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }
  .site-nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    padding: 16px 20px 24px;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
    transform: translateY(-120%);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.28s ease, opacity 0.2s ease, visibility 0.2s;
  }
  body.nav-open .site-nav {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  .site-nav a {
    padding: 14px 16px;
    border-radius: 12px;
  }
}

/* —— Layout —— */
.wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

.wrap-wide {
  max-width: 1080px;
  margin: 0 auto;
  padding: 32px 20px 72px;
}

/* —— Hero (home) —— */
.hero {
  text-align: center;
  padding: 56px 0 48px;
  max-width: 640px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid var(--border);
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(2.25rem, 5vw, 3.25rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1.1;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--text) 0%, var(--text-muted) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@media (prefers-color-scheme: dark) {
  .hero h1 {
    background: linear-gradient(135deg, #fff 0%, var(--text-muted) 100%);
    -webkit-background-clip: text;
    background-clip: text;
  }
}

.hero .sub {
  font-size: 1.125rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 32px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 700;
  font-family: inherit;
  text-decoration: none;
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 100%);
  color: #fff;
  box-shadow: 0 8px 24px -8px var(--accent-glow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px -8px var(--accent-glow);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 14px 22px;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  text-decoration: none;
  color: var(--text);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  transition: border-color 0.15s, transform 0.15s;
}

.btn-secondary:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}

.app-store-badge {
  display: inline-block;
  height: 44px;
  vertical-align: middle;
}

.app-store-badge img {
  height: 100%;
  width: auto;
  border-radius: 8px;
}

/* —— Feature grid —— */
.section-label {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
  text-align: center;
}

.section-head {
  font-size: clamp(1.5rem, 3vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  text-align: center;
  margin-bottom: 40px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 56px;
}

.feature-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  margin-bottom: 16px;
}

.feature-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.feature-card p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* —— Cards & tabs —— */
.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.card h2 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.card p,
.card li {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

.card ul {
  margin: 12px 0 0 1.25em;
}

.tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 28px;
  background: var(--bg-elevated);
  padding: 6px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}

.tabs a {
  flex: 1;
  text-align: center;
  padding: 12px 14px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.tabs a:hover {
  color: var(--text);
  background: var(--accent-soft);
}

.tabs a.active {
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 100%);
  color: #fff;
}

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

.links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  transition: border-color 0.2s, transform 0.15s;
  box-shadow: var(--shadow);
}

.links a:hover {
  border-color: var(--accent);
  transform: translateX(4px);
}

.links a span:last-child {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
  text-align: right;
}

.section-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 36px 0 16px;
  letter-spacing: -0.02em;
}

/* —— Form —— */
.form-card {
  margin-top: 8px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.form-group textarea {
  min-height: 140px;
  resize: vertical;
}

.btn {
  display: inline-block;
  padding: 14px 28px;
  border-radius: 12px;
  border: none;
  font-size: 1rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent) 0%, #7c3aed 100%);
  color: #fff;
  transition: opacity 0.15s, transform 0.15s;
}

.btn:hover:not(:disabled) {
  transform: translateY(-1px);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.form-note {
  margin-top: 16px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.ticket-success {
  padding: 16px 20px;
  border-radius: 12px;
  background: color-mix(in srgb, #10b981 12%, var(--bg-elevated));
  border: 1px solid color-mix(in srgb, #10b981 35%, transparent);
  color: #059669;
  margin-bottom: 20px;
  font-weight: 500;
}

@media (prefers-color-scheme: dark) {
  .ticket-success {
    color: #34d399;
  }
}

.ticket-error {
  padding: 16px 20px;
  border-radius: 12px;
  background: color-mix(in srgb, #ef4444 12%, var(--bg-elevated));
  border: 1px solid color-mix(in srgb, #ef4444 30%, transparent);
  color: #dc2626;
  margin-bottom: 20px;
}

@media (prefers-color-scheme: dark) {
  .ticket-error {
    color: #f87171;
  }
}

/* —— Policy pages —— */
.page-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  margin-bottom: 28px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 0.15s;
}

.page-back:hover {
  color: var(--accent);
}

.page-title {
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 800;
  letter-spacing: -0.04em;
  margin-bottom: 10px;
}

.page-updated {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 36px;
}

.policy-content h2 {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 32px 0 12px;
  letter-spacing: -0.02em;
}

.policy-content p,
.policy-content li {
  margin-bottom: 14px;
  color: var(--text-muted);
  line-height: 1.75;
}

.policy-content ul {
  margin: 0 0 14px 1.35em;
}

.policy-content a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.policy-content a:hover {
  text-decoration: underline;
}

/* —— Footer —— */
.site-footer {
  margin-top: 56px;
  padding: 32px 20px;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.875rem;
  line-height: 1.8;
}

.site-footer a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.site-footer .sep {
  margin: 0 0.4em;
  opacity: 0.5;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px 28px;
  margin-top: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.trust-row span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
