@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700;800;900&display=swap');

:root {
  --color-page-bg: #0D141D;
  --color-surface-1: #111B25;
  --color-surface-2: #15212C;
  --color-surface-3: #182631;
  --color-surface-raised: #15212C;
  --color-surface-main: #111B25;
  --color-surface-subtle: #15212C;

  --color-input-bg: #15212C;
  --color-table-bg: #111B25;
  --color-table-header: #15212C;

  --color-border: #22313D;
  --color-border-strong: #22313D;
  --color-border-soft: #1B2934;

  --color-text-primary: #F2F5F7;
  --color-text-secondary: #98A4B3;
  --color-text-muted: #6F7C8B;

  --color-sidebar-bg: #0A1017;
  --color-sidebar-surface: #111A23;
  --color-sidebar-active: #123A34;
  --color-sidebar-text: #F2F5F7;
  --color-sidebar-muted: #98A4B3;
  --color-sidebar-icon-active: #49D3A7;

  --color-brand: #49D3A7;
  --color-brand-hover: #3CC59A;
  --color-brand-soft: #123B34;

  --color-success: #49D3A7;
  --color-success-soft: #123B34;

  --color-warning: #D8AE63;
  --color-warning-soft: #29251C;

  --color-danger: #EF7180;
  --color-danger-soft: #321D24;

  --color-info: #6FA8FF;
  --color-info-soft: #172A42;
}

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

body {
  font-family: 'Tajawal', sans-serif;
  background-color: var(--color-page-bg);
  color: var(--color-text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  direction: rtl;
}

/* Layout */
.app-container {
  display: flex;
  min-height: 100vh;
}

.sidebar {
  width: 260px;
  background-color: var(--color-sidebar-bg);
  border-left: 1px solid var(--color-sidebar-surface);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.sidebar-header {
  height: 80px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--color-sidebar-surface);
  gap: 12px;
}

.brand-logo {
  width: 40px;
  height: 40px;
  background-color: var(--color-brand);
  color: #0A1017;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-weight: bold;
  font-size: 20px;
}

.brand-title {
  font-size: 20px;
  font-weight: bold;
}

.sidebar-nav {
  flex: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 8px;
  color: var(--color-sidebar-muted);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
  transition: all 0.2s;
}

.nav-item:hover {
  background-color: var(--color-sidebar-surface);
  color: var(--color-sidebar-text);
}

.nav-item.active {
  background-color: rgba(18, 58, 52, 0.4);
  color: var(--color-sidebar-icon-active);
}

.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.topbar {
  height: 64px;
  background-color: var(--color-surface-1);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
}

.page-title {
  font-size: 20px;
  font-weight: bold;
}

.page-subtitle {
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: 2px;
}

.content-area {
  flex: 1;
  padding: 32px;
  overflow-y: auto;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

/* UI Components */
.card {
  background-color: var(--color-surface-1);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.card-title {
  font-size: 18px;
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 8px;
}

.card-subtitle {
  font-size: 14px;
  color: var(--color-text-secondary);
  margin-top: 4px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: bold;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  font-family: inherit;
}

.btn-primary {
  background-color: var(--color-brand);
  color: #0A1017;
}

.btn-primary:hover {
  background-color: var(--color-brand-hover);
}

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--color-border);
  color: var(--color-text-primary);
}

.btn-outline:hover {
  background-color: var(--color-surface-2);
}

.btn-danger {
  background-color: var(--color-danger-soft);
  color: var(--color-danger);
  border: 1px solid rgba(239, 113, 128, 0.2);
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: bold;
}

.badge-success {
  background-color: var(--color-success-soft);
  color: var(--color-success);
  border: 1px solid rgba(73, 211, 167, 0.2);
}

.badge-warning {
  background-color: var(--color-warning-soft);
  color: var(--color-warning);
  border: 1px solid rgba(216, 174, 99, 0.2);
}

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

.stat-card {
  background-color: var(--color-surface-2);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 20px;
}

.stat-label {
  color: var(--color-text-secondary);
  font-size: 14px;
  margin-bottom: 8px;
}

.stat-value {
  font-size: 28px;
  font-weight: bold;
}

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

.form-label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--color-text-primary);
}

.form-control {
  width: 100%;
  background-color: var(--color-input-bg);
  border: 1px solid var(--color-border);
  color: var(--color-text-primary);
  padding: 12px 16px;
  border-radius: 8px;
  font-family: inherit;
  font-size: 14px;
  transition: border-color 0.2s;
}

.form-control:focus {
  outline: none;
  border-color: var(--color-brand);
}

.form-control:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Table */
.table-container {
  width: 100%;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  background-color: var(--color-table-header);
  padding: 12px 16px;
  text-align: right;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-secondary);
  border-bottom: 1px solid var(--color-border);
}

td {
  padding: 16px;
  border-bottom: 1px solid var(--color-border);
  font-size: 14px;
}

tbody tr:hover {
  background-color: var(--color-surface-2);
}

.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.gap-4 { gap: 16px; }
.mt-4 { margin-top: 16px; }
.text-secondary { color: var(--color-text-secondary); }
.text-brand { color: var(--color-brand); }

/* Marketing & Info Pages */
.hero-banner {
  background: linear-gradient(135deg, var(--color-surface-2), var(--color-brand-soft));
  border-radius: 16px;
  padding: 64px 32px;
  text-align: center;
  margin-bottom: 32px;
  border: 1px solid var(--color-border);
  position: relative;
  overflow: hidden;
}
.hero-title {
  font-size: 40px;
  font-weight: 900;
  margin-bottom: 16px;
  color: var(--color-text-primary);
}
.hero-subtitle {
  font-size: 18px;
  color: var(--color-text-secondary);
  max-width: 700px;
  margin: 0 auto 32px auto;
  line-height: 1.6;
}
.pricing-card {
  text-align: center;
  padding: 40px 32px;
  border-top: 4px solid var(--color-brand);
  background-color: var(--color-surface-2);
}
.price-amount {
  font-size: 48px;
  font-weight: 900;
  color: var(--color-brand);
  direction: ltr;
  display: inline-block;
}
.price-currency {
  font-size: 18px;
  font-weight: 500;
  color: var(--color-text-secondary);
}
.price-note {
  font-size: 14px;
  color: var(--color-warning);
  margin-top: 12px;
  font-weight: bold;
  background-color: var(--color-warning-soft);
  display: inline-block;
  padding: 4px 12px;
  border-radius: 8px;
  border: 1px solid rgba(216, 174, 99, 0.2);
}
.feature-list {
  list-style: none;
  margin-top: 24px;
  text-align: right;
}
.feature-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 15px;
  color: var(--color-text-primary);
}
.feature-list li i {
  color: var(--color-brand);
  flex-shrink: 0;
}
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.step-card {
  text-align: center;
  padding: 32px 24px;
  background-color: var(--color-surface-2);
  border-radius: 12px;
  border: 1px solid var(--color-border);
  position: relative;
}
.step-number {
  width: 48px;
  height: 48px;
  background-color: var(--color-brand);
  color: #0A1017;
  font-weight: bold;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  margin: 0 auto 16px auto;
}
.step-title {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 8px;
}
.step-desc {
  font-size: 14px;
  color: var(--color-text-secondary);
}
.faq-item {
  border-bottom: 1px solid var(--color-border);
  padding: 24px 0;
}
.faq-item:last-child {
  border-bottom: none;
}
.faq-question {
  font-size: 18px;
  font-weight: bold;
  margin-bottom: 12px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  color: var(--color-brand);
}
.faq-answer {
  color: var(--color-text-primary);
  font-size: 15px;
  line-height: 1.7;
  padding-right: 36px;
}
.text-center { text-align: center; }
.mb-2 { margin-bottom: 8px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.mb-8 { margin-bottom: 32px; }
.p-6 { padding: 24px; }
.p-8 { padding: 32px; }
.top-banner {
  background-color: var(--color-brand-soft);
  color: var(--color-brand);
  padding: 12px 24px;
  text-align: center;
  font-weight: bold;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border-bottom: 1px solid rgba(73, 211, 167, 0.2);
}
.top-banner-btn {
  background-color: var(--color-brand);
  color: #0A1017;
  border: none;
  border-radius: 4px;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: bold;
  cursor: pointer;
}
.comparison-table th {
  text-align: center;
}
.comparison-table td {
  text-align: center;
  vertical-align: middle;
}
.comparison-table td:first-child {
  text-align: right;
  font-weight: bold;
}
.section-title {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 8px;
}
.section-subtitle {
  font-size: 16px;
  color: var(--color-text-secondary);
  margin-bottom: 24px;
}

html {
  scroll-behavior: smooth;
}

/* Floating Back to Top Button */
.back-to-top-btn {
  position: fixed;
  bottom: 32px;
  left: 32px;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-brand-soft);
  border: 1px solid var(--color-brand);
  color: #FFFFFF;
  border-radius: 50%;
  width: 52px;
  height: 52px;
  cursor: pointer;
  box-shadow: 0 0 12px rgba(73, 211, 167, 0.3);
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  text-decoration: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
}

.back-to-top-btn.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top-btn:hover {
  transform: translateY(-6px) /* Keep visible state transformation logic but lift on hover */ scale(1.05);
  background-color: var(--color-brand);
  color: #FFFFFF;
  box-shadow: 0 0 20px rgba(73, 211, 167, 0.5);
}

/* Floating Chat Image Button */
.floating-chat-img-btn {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1000;
  width: 100px;
  height: auto;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.floating-chat-img-btn img {
  width: 100%;
  height: auto;
  border-radius: 16px; /* Soft rounding that preserves text below the bubble */
  object-fit: contain;
}

.floating-chat-img-btn:hover {
  transform: translateY(-4px) scale(1.05);
}

@media (max-width: 768px) {
  .back-to-top-btn {
    bottom: 16px;
    left: 16px;
    width: 44px;
    height: 44px;
  }
  .floating-chat-img-btn {
    bottom: 16px;
    right: 16px;
    width: 80px;
  }
  /* Not present in the original reference file (whatsapp-info.html /
     style.css never defined a mobile breakpoint for these grids, so on a
     narrow screen the two/four columns were squeezed side by side instead
     of stacking). Added here, scoped to this page only, purely to make the
     page usable on mobile — no colors, spacing values, or card styles are
     changed, only the column count collapses to 1 below 768px. */
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 28px;
  }
}

