/* ===== Design Tokens ===== */
:root {
  --bg-primary: #0a0f1a;
  --bg-secondary: #111827;
  --bg-card: #1a2332;
  --bg-card-hover: #1f2b3d;
  --green-primary: #00c853;
  --green-dark: #00a344;
  --gold-accent: #d4a853;
  --gold-dark: #b8923f;
  --text-primary: #f0f0f0;
  --text-secondary: #a0aec0;
  --text-muted: #6b7a90;
  --border-color: #2d3748;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
  --transition: 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: 'IBM Plex Sans Arabic', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
}

/* ===== Container ===== */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  white-space: nowrap;
}

.btn--primary {
  background: var(--green-primary);
  color: #fff;
}
.btn--primary:hover {
  background: var(--green-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 200, 83, 0.3);
}

.btn--gold {
  background: var(--gold-accent);
  color: #0a0f1a;
}
.btn--gold:hover {
  background: var(--gold-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 168, 83, 0.3);
}

.btn--outline {
  background: transparent;
  border: 2px solid var(--green-primary);
  color: var(--green-primary);
}
.btn--outline:hover {
  background: var(--green-primary);
  color: #fff;
  transform: translateY(-2px);
}

.btn--sm {
  padding: 10px 24px;
  font-size: 0.9rem;
}

.btn--block {
  width: 100%;
}

/* ===== Nav ===== */
.nav {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  z-index: 100;
  background: rgba(10, 15, 26, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.nav__logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--green-primary);
  display: flex;
  align-items: center;
}

.nav__logo-img {
  height: 40px;
  width: auto;
  display: block;
  mix-blend-mode: screen;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}

.nav__links a {
  color: var(--text-secondary);
  font-weight: 500;
  transition: var(--transition);
}
.nav__links a:hover {
  color: var(--green-primary);
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: var(--transition);
}

/* ===== Hero ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 72px;
  background: var(--bg-primary);
  background-image:
    radial-gradient(ellipse 60% 50% at 50% 0%, rgba(0, 200, 83, 0.08) 0%, transparent 70%);
}

.hero__inner {
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
  padding: 80px 0;
}

.hero__title {
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 24px;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--green-primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero__logo {
  width: 180px;
  height: auto;
  margin: 0 auto 24px;
  display: block;
  mix-blend-mode: screen;
}

.hero__tagline {
  font-size: 1.3rem;
  color: var(--green-primary);
  font-weight: 500;
  margin-bottom: 24px;
}

.hero__desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 40px;
  line-height: 1.9;
}

.hero__actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===== Section Titles ===== */
.section__title {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 12px;
}

.section__subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 48px;
  font-size: 1.05rem;
}

/* ===== Analyzer Wizard ===== */
.analyzer {
  padding: 100px 0;
  background: var(--bg-primary);
  background-image:
    radial-gradient(ellipse 50% 40% at 50% 100%, rgba(0, 200, 83, 0.06) 0%, transparent 70%);
}

.wizard {
  max-width: 640px;
  margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 40px 32px;
}

/* Step indicator */
.wizard__steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 36px;
}

.wizard__step {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  transition: var(--transition);
}

.wizard__step--active {
  color: var(--green-primary);
}

.wizard__step--done {
  color: var(--green-primary);
}

.wizard__step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid currentColor;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.9rem;
}

.wizard__step--active .wizard__step-num {
  background: var(--green-primary);
  color: #fff;
  border-color: var(--green-primary);
}

.wizard__step--done .wizard__step-num {
  background: var(--green-primary);
  color: #fff;
  border-color: var(--green-primary);
}

.wizard__step-label {
  font-size: 0.9rem;
  font-weight: 500;
}

.wizard__step-line {
  width: 60px;
  height: 2px;
  background: var(--border-color);
  margin: 0 16px;
  transition: var(--transition);
}

.wizard__step-line--active {
  background: var(--green-primary);
}

/* Panels */
.wizard__panel {
  display: none;
}

.wizard__panel--active {
  display: block;
}

/* Upload zone */
.upload-zone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius);
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
}

.upload-zone:hover,
.upload-zone--dragover {
  border-color: var(--green-primary);
  background: rgba(0, 200, 83, 0.04);
}

.upload-zone__icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.upload-zone__text {
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.upload-zone__hint {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* File info */
.upload-zone__file {
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(0, 200, 83, 0.08);
  border: 1px solid var(--green-primary);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-top: 16px;
}

.upload-zone__file-icon {
  font-size: 1.2rem;
}

.upload-zone__file-name {
  flex: 1;
  font-size: 0.95rem;
  color: var(--text-primary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.upload-zone__file-remove {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.4rem;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
  transition: var(--transition);
}

.upload-zone__file-remove:hover {
  color: #e53e3e;
}

.wizard__btn {
  margin-top: 20px;
}

.wizard__btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

.wizard__btn-new {
  margin-top: 16px;
}

/* Loader */
.loader {
  text-align: center;
  padding: 48px 0;
}

.loader__spinner {
  width: 48px;
  height: 48px;
  border: 4px solid var(--border-color);
  border-top-color: var(--green-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 20px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.loader__text {
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.loader__hint {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Result box */
.result-box {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 24px;
  max-height: 400px;
  overflow-y: auto;
  font-size: 0.95rem;
  line-height: 1.9;
  color: var(--text-secondary);
  white-space: pre-wrap;
  direction: rtl;
  margin-bottom: 24px;
}

.result-box::-webkit-scrollbar {
  width: 6px;
}

.result-box::-webkit-scrollbar-track {
  background: var(--bg-card);
}

.result-box::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 3px;
}

/* Email step */
.email-step {
  background: rgba(0, 200, 83, 0.04);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 20px;
}

.email-step__label {
  font-size: 0.95rem;
  color: var(--text-primary);
  margin-bottom: 12px;
  font-weight: 500;
}

.email-step__form {
  display: flex;
  gap: 10px;
}

.email-step__form input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
}

.email-step__form input::placeholder {
  color: var(--text-muted);
}

.email-step__form input:focus {
  outline: none;
  border-color: var(--green-primary);
  box-shadow: 0 0 0 3px rgba(0, 200, 83, 0.15);
}

.email-step__form .btn {
  padding: 12px 28px;
  flex-shrink: 0;
}

.email-step__status {
  margin-top: 10px;
  font-size: 0.85rem;
  min-height: 20px;
}

.email-step__status.success {
  color: var(--green-primary);
}

.email-step__status.error {
  color: #e53e3e;
}

/* Error box */
.error-box {
  text-align: center;
  padding: 40px 20px;
}

.error-box__icon {
  font-size: 3rem;
  margin-bottom: 12px;
}

.error-box__text {
  font-size: 1.05rem;
  color: #e53e3e;
}

/* ===== Features ===== */
.features {
  padding: 100px 0;
  background: var(--bg-secondary);
}

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

.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 32px;
  transition: var(--transition);
}
.card:hover {
  background: var(--bg-card-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--green-primary);
}

.card__icon {
  font-size: 2rem;
  margin-bottom: 16px;
}

.card__title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--green-primary);
}

.card__desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.8;
}

/* ===== Pricing ===== */
.pricing {
  padding: 100px 0;
}

.pricing__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  max-width: 800px;
  margin: 0 auto;
}

.pricing__card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 40px 32px;
  position: relative;
  transition: var(--transition);
}
.pricing__card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.pricing__card--pro {
  border-color: var(--gold-accent);
  background: linear-gradient(180deg, rgba(212, 168, 83, 0.08) 0%, var(--bg-card) 40%);
}

.pricing__badge {
  position: absolute;
  top: -14px;
  right: 24px;
  background: var(--gold-accent);
  color: #0a0f1a;
  padding: 6px 20px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
}

.pricing__header {
  text-align: center;
  margin-bottom: 28px;
}

.pricing__tier {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.pricing__price {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--green-primary);
}
.pricing__card--pro .pricing__price {
  color: var(--gold-accent);
}
.pricing__price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-muted);
}

.pricing__features {
  margin-bottom: 28px;
}

.pricing__features li {
  padding: 10px 0;
  border-bottom: 1px solid var(--border-color);
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 10px;
}
.pricing__features li:last-child {
  border-bottom: none;
}
.pricing__features li.yes::before {
  content: '✓';
  color: var(--green-primary);
  font-weight: 700;
}
.pricing__features li.no {
  color: var(--text-muted);
}
.pricing__features li.no::before {
  content: '✗';
  color: var(--text-muted);
}

.pricing__trial {
  text-align: center;
  margin-top: 16px;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ===== Contact Form ===== */
.contact {
  padding: 100px 0;
  background: var(--bg-secondary);
}

.contact__form {
  max-width: 480px;
  margin: 0 auto;
}

.form__group {
  margin-bottom: 16px;
}

.form__group input {
  width: 100%;
  padding: 14px 18px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 1rem;
  transition: var(--transition);
}
.form__group input::placeholder {
  color: var(--text-muted);
}
.form__group input:focus {
  outline: none;
  border-color: var(--green-primary);
  box-shadow: 0 0 0 3px rgba(0, 200, 83, 0.15);
}

.form__status {
  text-align: center;
  margin-top: 12px;
  font-size: 0.9rem;
  min-height: 24px;
}
.form__status.success {
  color: var(--green-primary);
}
.form__status.error {
  color: #e53e3e;
}

/* ===== Footer ===== */
.footer {
  padding: 60px 0 0;
  border-top: 1px solid var(--border-color);
}

.footer__inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
}

.footer__brand .nav__logo-img {
  mix-blend-mode: screen;
}

.footer__brand p {
  color: var(--text-secondary);
  margin-top: 8px;
  font-size: 0.95rem;
}

.footer__links h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.footer__links li {
  margin-bottom: 10px;
}

.footer__links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: var(--transition);
}
.footer__links a:hover {
  color: var(--green-primary);
}

.footer__bottom {
  border-top: 1px solid var(--border-color);
  padding: 20px 0;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* ===== Animations ===== */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .nav__toggle {
    display: flex;
  }

  .nav__links {
    position: fixed;
    top: 72px;
    right: 0;
    left: 0;
    flex-direction: column;
    background: rgba(10, 15, 26, 0.97);
    backdrop-filter: blur(12px);
    padding: 24px;
    gap: 20px;
    transform: translateY(-120%);
    transition: var(--transition);
    border-bottom: 1px solid var(--border-color);
  }
  .nav__links.open {
    transform: translateY(0);
  }

  .features__grid {
    grid-template-columns: 1fr;
  }

  .pricing__grid {
    grid-template-columns: 1fr;
  }

  .footer__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .hero__inner {
    padding: 40px 0;
  }
}
