/* BarakahTasks landing — design system mirrors design_prototype/styles.css */

:root {
  --bg: #0E1311;
  --bg-elev: #141A18;
  --bg-elev-2: #1B2220;
  --bg-faint: #181F1C;
  --bg-card: #141A18;
  --line: #232B28;
  --line-soft: #1C2421;

  --fg: #ECEEEC;
  --fg-muted: #A2ADA8;
  --fg-soft: #6B756F;
  --fg-faint: #4A524D;

  --accent: #7FB89A;
  --accent-soft: rgba(127, 184, 154, 0.14);
  --accent-line: rgba(127, 184, 154, 0.32);
  --accent-deep: #5C9479;

  --gold: #C9A76A;
  --gold-soft: rgba(201, 167, 106, 0.12);

  --danger: #D88A7A;

  --r-sm: 8px;
  --r: 12px;
  --r-lg: 16px;
  --r-xl: 22px;
  --r-2xl: 28px;

  --font-sans: "Inter", -apple-system, "SF Pro Text", system-ui, sans-serif;
  --font-display: "Inter", -apple-system, "SF Pro Display", system-ui, sans-serif;
  --font-arabic: "Amiri", "Scheherazade New", "Noto Naskh Arabic", serif;

  --container: 1120px;
  --container-narrow: 760px;
  --gutter: 24px;

  --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.02) inset, 0 12px 32px rgba(0, 0, 0, 0.35);
  --shadow-accent: 0 8px 24px rgba(127, 184, 154, 0.32);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: "ss01", "cv11";
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.15s ease;
}
a:hover { color: var(--fg); }

/* Accessibility */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; top: -100px; left: 16px;
  background: var(--accent); color: var(--bg);
  padding: 10px 16px; border-radius: var(--r);
  z-index: 100;
}
.skip-link:focus { top: 16px; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 4px;
}

/* Layout */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.container-narrow { max-width: var(--container-narrow); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  padding: 12px 18px;
  border-radius: var(--r);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #0B100E;
  box-shadow: var(--shadow-accent);
}
.btn-primary:hover {
  background: var(--accent-deep);
  color: #0B100E;
  transform: translateY(-1px);
}
.btn-primary:active { transform: translateY(0); }

.btn-ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--line);
}
.btn-ghost:hover {
  border-color: var(--accent-line);
  color: var(--fg);
  background: var(--accent-soft);
}

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(14, 19, 17, 0.78);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--line-soft);
}
.nav-inner {
  display: flex; align-items: center; gap: 24px;
  padding-top: 14px; padding-bottom: 14px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--fg);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: -0.01em;
}
.brand:hover { color: var(--fg); }
.brand-mark {
  display: inline-block;
  width: 32px; height: 32px;
  flex-shrink: 0;
}
.brand-mark svg { width: 100%; height: 100%; display: block; }
.brand-mark-sm { width: 28px; height: 28px; }
.brand-name { font-family: var(--font-display); }
.brand-name-accent { color: var(--accent); }

.nav-links {
  display: flex; align-items: center; gap: 6px;
  margin-left: auto;
}
.nav-links a {
  color: var(--fg-muted);
  padding: 8px 12px;
  border-radius: var(--r-sm);
  font-size: 14px;
  font-weight: 500;
}
.nav-links a:hover {
  color: var(--fg);
  background: var(--bg-elev);
}
.nav-cta { padding: 10px 16px; font-size: 14px; }

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 40px; height: 40px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  align-items: center; justify-content: center;
  gap: 4px;
}
.nav-toggle span {
  display: block;
  width: 18px; height: 2px;
  background: var(--fg);
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.mobile-menu { display: none; }
.mobile-menu:not([hidden]) {
  display: flex; flex-direction: column;
  gap: 8px;
  padding: 8px 24px 20px;
  border-top: 1px solid var(--line-soft);
  background: var(--bg);
}
.mobile-menu a {
  color: var(--fg);
  padding: 10px 12px;
  border-radius: var(--r-sm);
  font-weight: 500;
}
.mobile-menu a:hover { background: var(--bg-elev); }
.mobile-menu .btn-primary { margin-top: 4px; color: #0B100E; }

/* Hero */
.hero {
  position: relative;
  padding: 56px 0 80px;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute; inset: -10% -10% auto -10%;
  height: 540px;
  background: radial-gradient(60% 60% at 50% 0%, var(--accent-soft) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}
.hero-grid {
  position: relative; z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  color: var(--fg-muted);
  font-size: 13px;
  margin-bottom: 24px;
}
.eyebrow .arabic {
  font-family: var(--font-arabic);
  color: var(--gold);
  font-size: 18px;
  line-height: 1;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(40px, 5.4vw, 64px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin: 0 0 20px;
}
.hero h1 .accent {
  color: var(--accent);
  font-style: italic;
  font-weight: 500;
}

.lede {
  font-size: 18px;
  color: var(--fg-muted);
  margin: 0 0 32px;
  max-width: 540px;
}

/* Signup form */
.signup {
  display: flex; gap: 8px;
  max-width: 480px;
  margin-bottom: 18px;
  flex-wrap: wrap;
  position: relative;
}
.signup input[type="email"] {
  flex: 1 1 220px;
  min-width: 0;
  font-family: inherit;
  font-size: 15px;
  padding: 12px 16px;
  background: var(--bg-elev);
  color: var(--fg);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.signup input[type="email"]:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--bg-faint);
}
.signup input[type="email"]::placeholder { color: var(--fg-soft); }
.signup .btn { flex: 0 0 auto; }
.signup-msg {
  flex-basis: 100%;
  margin: 4px 2px 0;
  font-size: 13px;
  color: var(--fg-muted);
  min-height: 18px;
}
.signup-msg.error { color: var(--danger); }
.signup-msg.success { color: var(--accent); }
.signup.is-submitted .signup-form-row { display: none; }

/* Platform pills */
.platform-pills {
  list-style: none;
  display: flex; flex-wrap: wrap;
  gap: 8px;
  padding: 0; margin: 14px 0 0;
}
.platform-pills li {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--bg-elev);
  border: 1px solid var(--line-soft);
  font-size: 13px;
  color: var(--fg-muted);
}
.platform-pills .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 4px var(--gold-soft);
}

/* Hero art / device frame */
.hero-art {
  position: relative;
  display: flex; align-items: center; justify-content: center;
  min-height: 560px;
}
.hero-glow {
  position: absolute; inset: 10% 5% 10% 5%;
  background: radial-gradient(circle at 50% 50%, var(--accent-soft), transparent 65%);
  filter: blur(40px);
  z-index: 0;
}
.device {
  position: relative; z-index: 1;
  display: block;
  width: 320px;
  border-radius: 36px;
  border: 1px solid var(--line);
  overflow: hidden;
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset;
}
.device img {
  width: 100%;
  height: auto;
  display: block;
}
.device-sm { width: 260px; border-radius: 30px; }

/* Sections */
.section {
  padding: 96px 0;
  position: relative;
}
.section-alt { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-faint) 50%, var(--bg) 100%); }

.section-head {
  text-align: center;
  max-width: 660px;
  margin: 0 auto 56px;
}
.kicker {
  display: inline-block;
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 12px;
}
.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 14px;
}
.section-sub {
  font-size: 17px;
  color: var(--fg-muted);
  margin: 0;
}

/* Features */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.feature {
  background: var(--bg-elev);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  padding: 24px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.feature:hover {
  border-color: var(--accent-line);
  transform: translateY(-2px);
}
.feature-icon {
  width: 44px; height: 44px;
  border-radius: var(--r);
  background: var(--accent-soft);
  display: grid; place-items: center;
  font-size: 22px;
  margin-bottom: 16px;
}
.feature h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.feature p {
  font-size: 14.5px;
  color: var(--fg-muted);
  margin: 0;
  line-height: 1.55;
}

/* Screenshots */
.shots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  align-items: end;
  justify-items: center;
}
.shot { margin: 0; text-align: center; }
.shot figcaption {
  margin-top: 18px;
  font-size: 13px;
  color: var(--fg-soft);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.shot-trigger {
  background: transparent;
  border: 0;
  padding: 0;
  cursor: zoom-in;
  display: inline-block;
  border-radius: var(--r-xl);
  transition: transform 0.25s ease, filter 0.25s ease;
}
.shot-trigger:hover { transform: translateY(-4px); filter: brightness(1.05); }
.shot-trigger:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 6px;
}

/* Lightbox */
.lightbox {
  position: fixed; inset: 0;
  z-index: 100;
  background: rgba(8, 11, 10, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex; align-items: center; justify-content: center;
  padding: 32px 64px;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.lightbox.is-open {
  opacity: 1;
}
.lightbox[hidden] { display: none; }

.lightbox-content {
  position: relative;
  margin: 0;
  max-width: 100%;
  max-height: 100%;
  display: flex; flex-direction: column;
  align-items: center; gap: 16px;
}
.lightbox-image {
  max-width: 100%;
  max-height: calc(100vh - 140px);
  width: auto;
  height: auto;
  border-radius: 28px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  background: #0a0d0c;
}
.lightbox-caption {
  color: var(--fg-muted);
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  display: grid; place-items: center;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  color: var(--fg);
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
}
.lightbox-close:hover,
.lightbox-nav:hover {
  background: var(--bg-elev-2);
  border-color: var(--accent-line);
  color: var(--accent);
}
.lightbox-close:active,
.lightbox-nav:active { transform: scale(0.94); }
.lightbox-close { top: 24px; right: 24px; }
.lightbox-prev { left: 24px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 24px; top: 50%; transform: translateY(-50%); }
.lightbox-prev:active { transform: translateY(-50%) scale(0.94); }
.lightbox-next:active { transform: translateY(-50%) scale(0.94); }

body.lightbox-open { overflow: hidden; }

@media (max-width: 720px) {
  .lightbox { padding: 16px; }
  .lightbox-close { top: 12px; right: 12px; }
  .lightbox-prev { left: 8px; }
  .lightbox-next { right: 8px; }
  .lightbox-image { max-height: calc(100vh - 120px); border-radius: 22px; }
}

/* Pricing */
.pricing-toggle {
  display: inline-flex;
  margin-top: 20px;
  padding: 4px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 999px;
  gap: 2px;
}
.pricing-toggle button {
  background: transparent;
  color: var(--fg-muted);
  border: 0;
  padding: 8px 18px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex; align-items: center; gap: 8px;
}
.pricing-toggle button[aria-selected="true"] {
  background: var(--accent);
  color: #0B100E;
}
.pricing-toggle .save {
  font-size: 11px;
  padding: 2px 8px;
  background: var(--gold-soft);
  color: var(--gold);
  border-radius: 999px;
  font-weight: 600;
}
.pricing-toggle button[aria-selected="true"] .save {
  background: rgba(11, 16, 14, 0.15);
  color: #0B100E;
}

.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  align-items: stretch;
}
.plan {
  position: relative;
  background: var(--bg-elev);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-xl);
  padding: 32px 28px;
  display: flex; flex-direction: column;
  gap: 18px;
}
.plan-featured {
  border-color: var(--accent-line);
  background: linear-gradient(180deg, var(--accent-soft) 0%, var(--bg-elev) 60%);
  box-shadow: var(--shadow-card);
}
.plan-tag {
  position: absolute; top: -12px; left: 24px;
  background: var(--accent);
  color: #0B100E;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
}
.plan h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin: 0;
  letter-spacing: -0.01em;
}
.ai-pill {
  display: inline-block;
  margin-left: 6px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--gold-soft);
  color: var(--gold);
  vertical-align: middle;
  letter-spacing: 0.04em;
}
.plan-price {
  margin: 0;
  display: flex; align-items: baseline; gap: 6px;
  font-family: var(--font-display);
}
.plan-price .amount {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--fg);
}
.plan-price .period {
  font-size: 14px;
  color: var(--fg-muted);
}
.plan-feats {
  list-style: none;
  padding: 0; margin: 0;
  display: flex; flex-direction: column;
  gap: 10px;
  flex: 1;
}
.plan-feats li {
  position: relative;
  padding-left: 24px;
  font-size: 14.5px;
  color: var(--fg);
  line-height: 1.5;
}
.plan-feats li::before {
  content: "";
  position: absolute;
  left: 4px; top: 9px;
  width: 6px; height: 10px;
  border: solid var(--accent);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.plan-feats li.muted {
  color: var(--fg-soft);
  font-size: 13.5px;
}
.plan-feats li.muted::before { border-color: var(--fg-soft); }
.plan .btn { width: 100%; }

/* FAQ */
.faq {
  display: flex; flex-direction: column;
  gap: 10px;
}
.faq details {
  background: var(--bg-elev);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  padding: 18px 22px;
  transition: border-color 0.2s ease;
}
.faq details[open] { border-color: var(--accent-line); }
.faq summary {
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  list-style: none;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-size: 22px;
  font-weight: 400;
  color: var(--fg-muted);
  transition: transform 0.2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); color: var(--accent); }
.faq p {
  margin: 14px 0 0;
  color: var(--fg-muted);
  font-size: 15px;
  line-height: 1.6;
}

/* Closing CTA */
.cta {
  padding: 80px 0;
  background:
    radial-gradient(50% 80% at 50% 0%, var(--accent-soft), transparent 70%),
    linear-gradient(180deg, var(--bg-faint), var(--bg));
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}
.cta-inner { text-align: center; max-width: 620px; }
.cta h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}
.cta p {
  color: var(--fg-muted);
  margin: 0 0 28px;
  font-size: 16px;
}
.signup-lg {
  margin: 0 auto;
  max-width: 480px;
}

/* Footer */
.footer {
  padding: 36px 0;
  color: var(--fg-soft);
}
.footer-inner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 24px;
  justify-content: space-between;
}
.footer-brand {
  display: flex; align-items: center; gap: 10px;
  font-weight: 600;
  color: var(--fg);
}
.footer-brand img { border-radius: 6px; }
.footer-links {
  display: flex; gap: 18px;
  flex-wrap: wrap;
}
.footer-links a {
  color: var(--fg-muted);
  font-size: 14px;
}
.footer-links a:hover { color: var(--fg); }
.footer-meta {
  margin: 0;
  font-size: 13px;
  color: var(--fg-soft);
}

/* Responsive */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  .hero-art { min-height: 0; }
  .device { width: 280px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .shots { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .device-sm { width: 200px; }
  .plans { grid-template-columns: 1fr; max-width: 480px; margin: 0 auto; }
}

@media (max-width: 720px) {
  :root { --gutter: 18px; }
  .nav-links, .nav-cta { display: none; }
  .nav-toggle { display: flex; }
  .hero { padding: 40px 0 64px; }
  .section { padding: 72px 0; }
  .section-head { margin-bottom: 40px; }
  .feature-grid { grid-template-columns: 1fr; }
  .shots {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .device-sm { width: 240px; }
  .footer-inner { flex-direction: column; align-items: flex-start; gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
