{"id":385,"date":"2026-05-31T18:38:10","date_gmt":"2026-05-31T18:38:10","guid":{"rendered":"https:\/\/www.dariba.co\/?page_id=385"},"modified":"2026-05-31T18:38:10","modified_gmt":"2026-05-31T18:38:10","slug":"saudi-tax-implications-assessment","status":"publish","type":"page","link":"https:\/\/www.dariba.co\/?page_id=385","title":{"rendered":"Self Tax Assessment"},"content":{"rendered":"\n<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n<meta charset=\"UTF-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n<title>Saudi Tax Implications Checker \u2014 Dariba.co<\/title>\n<link rel=\"preconnect\" href=\"https:\/\/fonts.googleapis.com\">\n<link rel=\"preconnect\" href=\"https:\/\/fonts.gstatic.com\" crossorigin>\n<link href=\"https:\/\/fonts.googleapis.com\/css2?family=Playfair+Display:ital,wght@0,700;0,900;1,700&#038;family=Source+Serif+4:ital,wght@0,300;0,400;0,600;1,300;1,400&#038;display=swap\" rel=\"stylesheet\">\n<style>\n\/* \u2500\u2500\u2500 Dariba Design System \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n:root {\n  --ink:              #0f0e0c;\n  --ink-light:        #3a3732;\n  --ink-muted:        #7a756e;\n  --parchment:        #faf8f4;\n  --cream:            #f2ede4;\n  --rule:             #d8d2c6;\n  --gold:             #b8860b;\n  --gold-light:       #e6c96a;\n  --gold-pale:        #fef6dc;\n  --green:            #1a6b3c;\n  --green-pale:       #f0f7f2;\n  --red:              #c0392b;\n  --red-pale:         #fdf2f0;\n  --accent:           #1a4a7a;\n  --blue-dark:        #0d2b4e;\n  --slate-mid:        #1a3a5e;\n  --steel-pale:       #dce8f5;\n  --font-display:     'Playfair Display', Georgia, serif;\n  --font-serif:       'Source Serif 4', Georgia, serif;\n  --radius:           3px;\n  --shadow-sm:        0 1px 3px rgba(15,14,12,.06), 0 1px 2px rgba(15,14,12,.04);\n  --shadow-md:        0 4px 16px rgba(15,14,12,.09), 0 2px 6px rgba(15,14,12,.06);\n  --shadow-lg:        0 12px 40px rgba(15,14,12,.13), 0 4px 12px rgba(15,14,12,.08);\n  --transition:       0.2s ease;\n}\n\n*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }\n\nbody {\n  font-family: var(--font-serif);\n  background: var(--parchment);\n  color: var(--ink-light);\n  min-height: 100vh;\n  line-height: 1.6;\n  -webkit-font-smoothing: antialiased;\n}\n\n\/* \u2500\u2500\u2500 Tool Wrapper \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.tax-tool {\n  max-width: 780px;\n  margin: 0 auto;\n  padding: 2rem 1.25rem 4rem;\n}\n\n\/* \u2500\u2500\u2500 Header \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.tool-header {\n  text-align: center;\n  padding: 2.5rem 0 2rem;\n  border-bottom: 1px solid var(--rule);\n  margin-bottom: 2.5rem;\n}\n.tool-eyebrow {\n  font-family: var(--font-serif);\n  font-size: 0.6875rem;\n  font-weight: 600;\n  letter-spacing: 0.14em;\n  text-transform: uppercase;\n  color: var(--gold);\n  margin-bottom: 0.75rem;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  gap: 0.5rem;\n}\n.tool-eyebrow::before, .tool-eyebrow::after {\n  content: '';\n  display: block;\n  width: 2rem;\n  height: 1px;\n  background: var(--gold-light);\n}\n.tool-title {\n  font-family: var(--font-display);\n  font-size: clamp(1.75rem, 4vw, 2.5rem);\n  font-weight: 900;\n  color: var(--ink);\n  line-height: 1.15;\n  margin-bottom: 0.75rem;\n  letter-spacing: -0.02em;\n}\n.tool-title em {\n  color: var(--accent);\n  font-style: italic;\n}\n.tool-subtitle {\n  font-size: 1rem;\n  color: var(--ink-muted);\n  font-weight: 300;\n  max-width: 500px;\n  margin: 0 auto;\n  font-style: italic;\n}\n\n\/* \u2500\u2500\u2500 Progress Bar \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.progress-wrap {\n  margin-bottom: 2rem;\n}\n.progress-meta {\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  margin-bottom: 0.5rem;\n}\n.progress-label {\n  font-size: 0.75rem;\n  font-weight: 600;\n  letter-spacing: 0.06em;\n  text-transform: uppercase;\n  color: var(--ink-muted);\n}\n.progress-count {\n  font-size: 0.75rem;\n  color: var(--ink-muted);\n}\n.progress-track {\n  height: 3px;\n  background: var(--cream);\n  border-radius: 2px;\n  overflow: hidden;\n}\n.progress-fill {\n  height: 100%;\n  background: linear-gradient(90deg, var(--accent), var(--gold));\n  border-radius: 2px;\n  transition: width 0.5s cubic-bezier(0.4,0,0.2,1);\n}\n\n\/* \u2500\u2500\u2500 Question Card \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.question-card {\n  background: #fff;\n  border: 1px solid var(--rule);\n  border-radius: var(--radius);\n  padding: 2rem 2rem 1.75rem;\n  box-shadow: var(--shadow-md);\n  animation: slideUp 0.35s cubic-bezier(0.4,0,0.2,1);\n  position: relative;\n  overflow: hidden;\n}\n.question-card::before {\n  content: '';\n  position: absolute;\n  top: 0; left: 0; right: 0;\n  height: 3px;\n  background: linear-gradient(90deg, var(--accent), var(--gold));\n}\n@keyframes slideUp {\n  from { opacity: 0; transform: translateY(18px); }\n  to   { opacity: 1; transform: translateY(0); }\n}\n\n.question-number {\n  font-size: 0.6875rem;\n  font-weight: 600;\n  letter-spacing: 0.12em;\n  text-transform: uppercase;\n  color: var(--gold);\n  margin-bottom: 0.75rem;\n}\n.question-text {\n  font-family: var(--font-display);\n  font-size: clamp(1.1rem, 2.5vw, 1.375rem);\n  font-weight: 700;\n  color: var(--ink);\n  line-height: 1.3;\n  margin-bottom: 0.375rem;\n}\n.question-hint {\n  font-size: 0.875rem;\n  color: var(--ink-muted);\n  font-style: italic;\n  margin-bottom: 1.5rem;\n}\n\n\/* \u2500\u2500\u2500 Option Cards \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.options-grid {\n  display: grid;\n  gap: 0.625rem;\n}\n.options-grid.two-col { grid-template-columns: 1fr 1fr; }\n.options-grid.three-col { grid-template-columns: 1fr 1fr 1fr; }\n\n.option-card {\n  background: var(--parchment);\n  border: 1.5px solid var(--rule);\n  border-radius: var(--radius);\n  padding: 0.875rem 1.125rem;\n  cursor: pointer;\n  transition: all var(--transition);\n  display: flex;\n  align-items: flex-start;\n  gap: 0.75rem;\n  text-align: left;\n  position: relative;\n  overflow: hidden;\n}\n.option-card:hover {\n  border-color: var(--accent);\n  background: var(--steel-pale);\n  box-shadow: var(--shadow-sm);\n  transform: translateY(-1px);\n}\n.option-card.selected {\n  border-color: var(--accent);\n  background: var(--steel-pale);\n  box-shadow: 0 0 0 2px rgba(26,74,122,.15);\n}\n.option-card.selected::after {\n  content: '\u2713';\n  position: absolute;\n  top: 0.5rem; right: 0.625rem;\n  width: 1.125rem; height: 1.125rem;\n  background: var(--accent);\n  color: white;\n  border-radius: 50%;\n  font-size: 0.5rem;\n  display: flex; align-items: center; justify-content: center;\n  font-weight: 700;\n  line-height: 1;\n  display: grid;\n  place-items: center;\n}\n.option-icon {\n  font-size: 1.25rem;\n  flex-shrink: 0;\n  line-height: 1;\n  margin-top: 0.1rem;\n}\n.option-label {\n  font-size: 0.9375rem;\n  font-weight: 600;\n  color: var(--ink);\n  line-height: 1.25;\n}\n.option-desc {\n  font-size: 0.8125rem;\n  color: var(--ink-muted);\n  margin-top: 0.2rem;\n  font-style: italic;\n}\n\n\/* \u2500\u2500\u2500 Navigation \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.question-nav {\n  display: flex;\n  justify-content: space-between;\n  align-items: center;\n  margin-top: 1.625rem;\n  padding-top: 1.25rem;\n  border-top: 1px solid var(--cream);\n}\n.btn-back {\n  background: none;\n  border: none;\n  font-family: var(--font-serif);\n  font-size: 0.875rem;\n  color: var(--ink-muted);\n  cursor: pointer;\n  display: flex;\n  align-items: center;\n  gap: 0.375rem;\n  transition: color var(--transition);\n  padding: 0.5rem 0;\n}\n.btn-back:hover { color: var(--ink); }\n.btn-next {\n  background: var(--accent);\n  color: white;\n  border: none;\n  font-family: var(--font-serif);\n  font-size: 0.9375rem;\n  font-weight: 600;\n  padding: 0.75rem 1.75rem;\n  border-radius: var(--radius);\n  cursor: pointer;\n  transition: all var(--transition);\n  display: flex;\n  align-items: center;\n  gap: 0.5rem;\n  letter-spacing: 0.01em;\n}\n.btn-next:hover {\n  background: var(--blue-dark);\n  transform: translateY(-1px);\n  box-shadow: 0 4px 12px rgba(13,43,78,.25);\n}\n.btn-next:disabled {\n  background: var(--rule);\n  color: var(--ink-muted);\n  cursor: not-allowed;\n  transform: none;\n  box-shadow: none;\n}\n\n\/* \u2500\u2500\u2500 Lead Capture Form \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.lead-gate {\n  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--slate-mid) 100%);\n  border-radius: var(--radius);\n  padding: 2.25rem 2rem;\n  box-shadow: var(--shadow-lg);\n  animation: slideUp 0.35s ease;\n  position: relative;\n  overflow: hidden;\n}\n.lead-gate::before {\n  content: '';\n  position: absolute;\n  top: -60px; right: -60px;\n  width: 200px; height: 200px;\n  border-radius: 50%;\n  background: rgba(184,134,11,.08);\n  pointer-events: none;\n}\n.lead-gate-badge {\n  display: inline-flex;\n  align-items: center;\n  gap: 0.375rem;\n  background: rgba(230,201,106,.15);\n  border: 1px solid rgba(230,201,106,.3);\n  color: var(--gold-light);\n  font-size: 0.6875rem;\n  font-weight: 600;\n  letter-spacing: 0.1em;\n  text-transform: uppercase;\n  padding: 0.3rem 0.75rem;\n  border-radius: 20px;\n  margin-bottom: 1rem;\n}\n.lead-gate h2 {\n  font-family: var(--font-display);\n  font-size: clamp(1.375rem, 3vw, 1.875rem);\n  color: white;\n  font-weight: 900;\n  line-height: 1.2;\n  margin-bottom: 0.5rem;\n}\n.lead-gate h2 em {\n  color: var(--gold-light);\n  font-style: italic;\n}\n.lead-gate p {\n  color: rgba(255,255,255,.65);\n  font-size: 0.9375rem;\n  margin-bottom: 1.5rem;\n  font-style: italic;\n}\n\n.lead-form {\n  display: grid;\n  grid-template-columns: 1fr 1fr;\n  gap: 0.75rem;\n}\n.lead-form .full-width { grid-column: 1 \/ -1; }\n\n.form-group label {\n  display: block;\n  font-size: 0.75rem;\n  font-weight: 600;\n  letter-spacing: 0.06em;\n  text-transform: uppercase;\n  color: rgba(255,255,255,.55);\n  margin-bottom: 0.375rem;\n}\n.form-group input {\n  width: 100%;\n  background: rgba(255,255,255,.09);\n  border: 1px solid rgba(255,255,255,.18);\n  border-radius: var(--radius);\n  padding: 0.75rem 0.875rem;\n  font-family: var(--font-serif);\n  font-size: 0.9375rem;\n  color: white;\n  transition: all var(--transition);\n  outline: none;\n}\n.form-group input::placeholder { color: rgba(255,255,255,.3); }\n.form-group input:focus {\n  border-color: var(--gold-light);\n  background: rgba(255,255,255,.12);\n  box-shadow: 0 0 0 3px rgba(230,201,106,.15);\n}\n.form-group input.error { border-color: #e87060; }\n\n.lead-form-note {\n  grid-column: 1 \/ -1;\n  font-size: 0.75rem;\n  color: rgba(255,255,255,.35);\n  font-style: italic;\n  text-align: center;\n}\n\n.btn-unlock {\n  grid-column: 1 \/ -1;\n  background: linear-gradient(135deg, var(--gold) 0%, #8a6209 100%);\n  color: white;\n  border: none;\n  font-family: var(--font-serif);\n  font-size: 1rem;\n  font-weight: 700;\n  padding: 0.9375rem 2rem;\n  border-radius: var(--radius);\n  cursor: pointer;\n  transition: all var(--transition);\n  letter-spacing: 0.02em;\n  display: flex;\n  align-items: center;\n  justify-content: center;\n  gap: 0.625rem;\n}\n.btn-unlock:hover {\n  transform: translateY(-2px);\n  box-shadow: 0 6px 20px rgba(184,134,11,.4);\n}\n\n\/* \u2500\u2500\u2500 Results Page \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.results-header {\n  background: var(--blue-dark);\n  border-radius: var(--radius);\n  padding: 2rem;\n  margin-bottom: 1.5rem;\n  animation: slideUp 0.4s ease;\n  position: relative;\n  overflow: hidden;\n}\n.results-header::after {\n  content: '';\n  position: absolute;\n  bottom: -40px; right: -40px;\n  width: 160px; height: 160px;\n  border-radius: 50%;\n  background: rgba(184,134,11,.07);\n}\n.results-greeting {\n  font-size: 0.75rem;\n  font-weight: 600;\n  letter-spacing: 0.1em;\n  text-transform: uppercase;\n  color: var(--gold-light);\n  margin-bottom: 0.5rem;\n}\n.results-header h2 {\n  font-family: var(--font-display);\n  font-size: clamp(1.375rem, 3vw, 1.75rem);\n  color: white;\n  font-weight: 900;\n  line-height: 1.2;\n  margin-bottom: 0.5rem;\n}\n.results-header p {\n  color: rgba(255,255,255,.6);\n  font-size: 0.875rem;\n  font-style: italic;\n}\n\n.results-disclaimer {\n  background: var(--gold-pale);\n  border: 1px solid var(--gold-light);\n  border-left: 3px solid var(--gold);\n  border-radius: var(--radius);\n  padding: 0.875rem 1rem;\n  font-size: 0.8125rem;\n  color: var(--ink-light);\n  font-style: italic;\n  margin-bottom: 1.5rem;\n  animation: slideUp 0.4s ease 0.1s both;\n}\n\n.results-grid {\n  display: grid;\n  gap: 0.875rem;\n}\n\n\/* Tax Result Card *\/\n.tax-card {\n  background: #fff;\n  border: 1px solid var(--rule);\n  border-radius: var(--radius);\n  overflow: hidden;\n  animation: slideUp 0.4s ease both;\n  box-shadow: var(--shadow-sm);\n  transition: box-shadow var(--transition);\n}\n.tax-card:hover { box-shadow: var(--shadow-md); }\n\n.tax-card-header {\n  display: flex;\n  align-items: center;\n  gap: 0.875rem;\n  padding: 1rem 1.25rem;\n  cursor: pointer;\n  user-select: none;\n}\n.tax-card-icon {\n  width: 2.25rem; height: 2.25rem;\n  border-radius: 50%;\n  display: grid;\n  place-items: center;\n  font-size: 1rem;\n  flex-shrink: 0;\n}\n.status-applies .tax-card-icon { background: rgba(26,107,60,.1); }\n.status-maybe .tax-card-icon   { background: rgba(184,134,11,.1); }\n.status-exempt .tax-card-icon  { background: rgba(192,57,43,.07); }\n\n.tax-card-meta { flex: 1; }\n.tax-card-name {\n  font-family: var(--font-display);\n  font-size: 1rem;\n  font-weight: 700;\n  color: var(--ink);\n  line-height: 1.2;\n}\n.tax-card-summary {\n  font-size: 0.8125rem;\n  color: var(--ink-muted);\n  font-style: italic;\n  margin-top: 0.125rem;\n}\n.tax-status-badge {\n  font-size: 0.6875rem;\n  font-weight: 700;\n  letter-spacing: 0.08em;\n  text-transform: uppercase;\n  padding: 0.25rem 0.625rem;\n  border-radius: 20px;\n  white-space: nowrap;\n}\n.status-applies .tax-status-badge {\n  background: rgba(26,107,60,.12);\n  color: var(--green);\n}\n.status-maybe .tax-status-badge {\n  background: rgba(184,134,11,.12);\n  color: var(--gold);\n}\n.status-exempt .tax-status-badge {\n  background: rgba(120,120,120,.1);\n  color: var(--ink-muted);\n}\n.tax-card-toggle {\n  color: var(--ink-muted);\n  font-size: 0.75rem;\n  transition: transform var(--transition);\n  flex-shrink: 0;\n}\n.tax-card.expanded .tax-card-toggle { transform: rotate(180deg); }\n\n.tax-card-body {\n  display: none;\n  padding: 0 1.25rem 1.25rem;\n  border-top: 1px solid var(--cream);\n  padding-top: 1rem;\n}\n.tax-card.expanded .tax-card-body { display: block; }\n\n.tax-detail-grid {\n  display: grid;\n  grid-template-columns: 1fr 1fr;\n  gap: 0.625rem;\n  margin-bottom: 1rem;\n}\n.tax-detail-item {\n  background: var(--parchment);\n  border-radius: var(--radius);\n  padding: 0.625rem 0.75rem;\n}\n.tax-detail-label {\n  font-size: 0.6875rem;\n  font-weight: 600;\n  letter-spacing: 0.08em;\n  text-transform: uppercase;\n  color: var(--ink-muted);\n  margin-bottom: 0.25rem;\n}\n.tax-detail-value {\n  font-size: 0.9375rem;\n  font-weight: 700;\n  color: var(--ink);\n}\n.tax-detail-value.accent { color: var(--accent); }\n.tax-detail-value.gold   { color: var(--gold); }\n\n.tax-obligations {\n  margin-bottom: 0.875rem;\n}\n.tax-obligations h4 {\n  font-size: 0.75rem;\n  font-weight: 700;\n  letter-spacing: 0.08em;\n  text-transform: uppercase;\n  color: var(--ink-muted);\n  margin-bottom: 0.5rem;\n}\n.obligation-list {\n  list-style: none;\n  display: flex;\n  flex-direction: column;\n  gap: 0.375rem;\n}\n.obligation-list li {\n  display: flex;\n  align-items: flex-start;\n  gap: 0.5rem;\n  font-size: 0.875rem;\n  color: var(--ink-light);\n}\n.obligation-list li::before {\n  content: '';\n  width: 5px; height: 5px;\n  background: var(--gold);\n  border-radius: 50%;\n  margin-top: 0.45rem;\n  flex-shrink: 0;\n}\n\n.tax-risk-flag {\n  background: var(--red-pale);\n  border: 1px solid rgba(192,57,43,.2);\n  border-left: 3px solid var(--red);\n  border-radius: var(--radius);\n  padding: 0.75rem 0.875rem;\n  font-size: 0.8125rem;\n  color: var(--ink-light);\n  display: flex;\n  gap: 0.5rem;\n}\n.tax-tip {\n  background: var(--green-pale);\n  border: 1px solid rgba(26,107,60,.2);\n  border-left: 3px solid var(--green);\n  border-radius: var(--radius);\n  padding: 0.75rem 0.875rem;\n  font-size: 0.8125rem;\n  color: var(--ink-light);\n  display: flex;\n  gap: 0.5rem;\n  margin-top: 0.625rem;\n}\n\n\/* \u2500\u2500\u2500 CTA Section \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n.results-cta {\n  background: linear-gradient(135deg, var(--blue-dark) 0%, var(--slate-mid) 100%);\n  border-radius: var(--radius);\n  padding: 2rem;\n  text-align: center;\n  margin-top: 1.5rem;\n  animation: slideUp 0.4s ease 0.3s both;\n}\n.results-cta h3 {\n  font-family: var(--font-display);\n  color: white;\n  font-size: 1.375rem;\n  font-weight: 700;\n  margin-bottom: 0.5rem;\n}\n.results-cta p {\n  color: rgba(255,255,255,.6);\n  font-size: 0.9375rem;\n  font-style: italic;\n  margin-bottom: 1.25rem;\n}\n.cta-buttons {\n  display: flex;\n  gap: 0.75rem;\n  justify-content: center;\n  flex-wrap: wrap;\n}\n.btn-cta-primary {\n  background: var(--gold);\n  color: white;\n  border: none;\n  font-family: var(--font-serif);\n  font-size: 0.9375rem;\n  font-weight: 700;\n  padding: 0.75rem 1.5rem;\n  border-radius: var(--radius);\n  cursor: pointer;\n  text-decoration: none;\n  transition: all var(--transition);\n}\n.btn-cta-primary:hover {\n  background: #8a6209;\n  transform: translateY(-1px);\n}\n.btn-cta-secondary {\n  background: rgba(255,255,255,.1);\n  color: white;\n  border: 1px solid rgba(255,255,255,.25);\n  font-family: var(--font-serif);\n  font-size: 0.9375rem;\n  font-weight: 400;\n  padding: 0.75rem 1.5rem;\n  border-radius: var(--radius);\n  cursor: pointer;\n  text-decoration: none;\n  transition: all var(--transition);\n}\n.btn-cta-secondary:hover { background: rgba(255,255,255,.15); }\n\n\/* \u2500\u2500\u2500 Responsive \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500 *\/\n@media (max-width: 600px) {\n  .options-grid.two-col,\n  .options-grid.three-col { grid-template-columns: 1fr; }\n  .lead-form { grid-template-columns: 1fr; }\n  .lead-form .full-width { grid-column: 1; }\n  .btn-unlock { grid-column: 1; }\n  .tax-detail-grid { grid-template-columns: 1fr; }\n  .question-card { padding: 1.5rem 1.25rem; }\n  .cta-buttons { flex-direction: column; align-items: stretch; }\n}\n\n\/* Hidden utility *\/\n.hidden { display: none !important; }\n.fade-in { animation: slideUp 0.35s ease; }\n<\/style>\n<\/head>\n<body>\n\n<div class=\"tax-tool\" id=\"dariba-tax-tool\">\n\n  <!-- HEADER -->\n  <header class=\"tool-header\">\n    <div class=\"tool-eyebrow\">Free Self-Assessment<\/div>\n    <h1 class=\"tool-title\">Know Your <em>Tax Obligations<\/em><br>in Saudi Arabia<\/h1>\n    <p class=\"tool-subtitle\">Answer a few questions and receive an instant, personalised overview of the Saudi taxes applicable to your business \u2014 based on ZATCA regulations.<\/p>\n  <\/header>\n\n  <!-- PROGRESS -->\n  <div class=\"progress-wrap\" id=\"progress-wrap\">\n    <div class=\"progress-meta\">\n      <span class=\"progress-label\">Assessment Progress<\/span>\n      <span class=\"progress-count\" id=\"progress-count\">Step 1 of 9<\/span>\n    <\/div>\n    <div class=\"progress-track\">\n      <div class=\"progress-fill\" id=\"progress-fill\" style=\"width: 11%\"><\/div>\n    <\/div>\n  <\/div>\n\n  <!-- QUESTIONS CONTAINER -->\n  <div id=\"questions-container\"><\/div>\n\n  <!-- LEAD GATE -->\n  <div id=\"lead-gate\" class=\"hidden\">\n    <div class=\"lead-gate\">\n      <div class=\"lead-gate-badge\">\ud83d\udd12 Your Assessment Is Ready<\/div>\n      <h2>Unlock Your <em>Free Tax Report<\/em><\/h2>\n      <p>Enter your details below to receive your personalised Saudi tax implications assessment \u2014 no consultation required.<\/p>\n      <div class=\"lead-form\" id=\"lead-form\">\n        <div class=\"form-group\">\n          <label for=\"lead-name\">Full Name *<\/label>\n          <input type=\"text\" id=\"lead-name\" placeholder=\"Mohammed Al-Hassan\" autocomplete=\"name\">\n        <\/div>\n        <div class=\"form-group\">\n          <label for=\"lead-company\">Company Name *<\/label>\n          <input type=\"text\" id=\"lead-company\" placeholder=\"Al-Hassan Trading Co.\" autocomplete=\"organization\">\n        <\/div>\n        <div class=\"form-group\">\n          <label for=\"lead-email\">Email Address *<\/label>\n          <input type=\"email\" id=\"lead-email\" placeholder=\"m.hassan@company.com\" autocomplete=\"email\">\n        <\/div>\n        <div class=\"form-group\">\n          <label for=\"lead-phone\">Mobile (WhatsApp) *<\/label>\n          <input type=\"tel\" id=\"lead-phone\" placeholder=\"+966 5x xxx xxxx\" autocomplete=\"tel\">\n        <\/div>\n        <p class=\"lead-form-note\">\ud83d\udd12 Your information is confidential and will not be shared with third parties.<\/p>\n        <button class=\"btn-unlock\" onclick=\"submitLead()\">\n          <svg width=\"16\" height=\"16\" viewBox=\"0 0 16 16\" fill=\"none\"><path d=\"M8 1l2 4 5 .7-3.5 3.4.8 5L8 12l-4.3 2.1.8-5L1 5.7 6 5z\" stroke=\"currentColor\" stroke-width=\"1.2\" stroke-linejoin=\"round\"\/><\/svg>\n          View My Tax Assessment \u2192\n        <\/button>\n      <\/div>\n    <\/div>\n  <\/div>\n\n  <!-- RESULTS -->\n  <div id=\"results-container\" class=\"hidden\"><\/div>\n\n<\/div>\n\n<script>\n\/* \u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\n   DARIBA TAX ASSESSMENT TOOL\n   Tax logic based on: VAT Implementing Regulations (June 2023 + Apr 2025 amendments),\n   Income Tax Implementing Regulations (Nov 2024), Zakat Implementing Regulations (2024),\n   RETT Regulations (2025), Transfer Pricing Bylaws (2021 + 2024 update)\n   \u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550\u2550 *\/\n\n\/\/ State\nconst state = {\n  currentStep: 0,\n  answers: {},\n  userName: '',\n  userCompany: ''\n};\n\n\/\/ Questions definition\nconst questions = [\n  {\n    id: 'entity_type',\n    number: 'Question 1 of 9',\n    text: 'What best describes your business or entity?',\n    hint: 'This determines which tax regimes apply \u2014 Zakat, CIT, or both.',\n    layout: 'two-col',\n    options: [\n      { value: 'saudi_100', icon: '\ud83c\uddf8\ud83c\udde6', label: '100% Saudi \/ GCC Owned', desc: 'All shareholders are Saudi or GCC nationals' },\n      { value: 'mixed', icon: '\ud83e\udd1d', label: 'Mixed Ownership', desc: 'Saudi + foreign shareholders' },\n      { value: 'foreign', icon: '\ud83c\udf0d', label: 'Foreign \/ Non-GCC Company', desc: 'Branch, PE, or fully foreign-owned' },\n      { value: 'individual', icon: '\ud83d\udc64', label: 'Individual \/ Freelancer', desc: 'Saudi or resident natural person' },\n    ]\n  },\n  {\n    id: 'activity',\n    number: 'Question 2 of 9',\n    text: 'What is your primary business activity?',\n    hint: 'Some activities trigger specific VAT exemptions, zero-rating, or excise taxes.',\n    layout: 'two-col',\n    options: [\n      { value: 'services', icon: '\ud83d\udece\ufe0f', label: 'Professional \/ Consulting Services', desc: 'Advisory, IT, legal, HR, etc.' },\n      { value: 'trading', icon: '\ud83c\udfea', label: 'Trading \/ Retail \/ Distribution', desc: 'Import, wholesale, e-commerce' },\n      { value: 'manufacturing', icon: '\ud83c\udfed', label: 'Manufacturing \/ Industrial', desc: 'Production, processing' },\n      { value: 'real_estate', icon: '\ud83c\udfd7\ufe0f', label: 'Real Estate', desc: 'Development, leasing, or transactions' },\n      { value: 'finance', icon: '\ud83c\udfe6', label: 'Finance \/ Banking \/ Insurance', desc: 'Partially VAT-exempt' },\n      { value: 'hydrocarbons', icon: '\u26fd', label: 'Oil, Gas & Hydrocarbons', desc: 'CIT applies at special rates' },\n    ]\n  },\n  {\n    id: 'revenue',\n    number: 'Question 3 of 9',\n    text: 'What is your estimated annual revenue in Saudi Riyals?',\n    hint: 'This determines your VAT registration obligation and e-invoicing wave.',\n    layout: 'two-col',\n    options: [\n      { value: 'below_187k', icon: '\ud83d\udcca', label: 'Below SAR 187,500', desc: 'Below voluntary VAT threshold' },\n      { value: '187k_375k', icon: '\ud83d\udcc8', label: 'SAR 187,500 \u2013 375,000', desc: 'Voluntary VAT registration zone' },\n      { value: '375k_3m', icon: '\ud83d\udcbc', label: 'SAR 375,000 \u2013 3 Million', desc: 'Mandatory VAT registration' },\n      { value: '3m_150m', icon: '\ud83c\udfe2', label: 'SAR 3M \u2013 150 Million', desc: 'VAT + full compliance obligations' },\n      { value: '150m_500m', icon: '\ud83c\udfdb\ufe0f', label: 'SAR 150M \u2013 500 Million', desc: 'TP + advanced e-invoicing' },\n      { value: 'above_500m', icon: '\ud83d\udcb0', label: 'Above SAR 500 Million', desc: 'Full enterprise compliance regime' },\n    ]\n  },\n  {\n    id: 'foreign_ownership_pct',\n    number: 'Question 4 of 9',\n    text: 'What percentage of your company is owned by non-Saudi \/ non-GCC shareholders?',\n    hint: 'CIT applies only to the foreign-owned portion; Zakat applies to the Saudi\/GCC-owned portion.',\n    layout: 'two-col',\n    condition: (ans) => ans.entity_type === 'mixed',\n    options: [\n      { value: 'foreign_lt25', icon: '\ud83d\udcc9', label: 'Less than 25% foreign', desc: 'Majority Saudi\/GCC-owned' },\n      { value: 'foreign_25_49', icon: '\ud83d\udcca', label: '25% \u2013 49% foreign', desc: 'Minority foreign ownership' },\n      { value: 'foreign_50_74', icon: '\ud83d\udcc8', label: '50% \u2013 74% foreign', desc: 'Majority foreign ownership' },\n      { value: 'foreign_75_99', icon: '\ud83d\udccb', label: '75% \u2013 99% foreign', desc: 'Substantially foreign-owned' },\n    ]\n  },\n  {\n    id: 'nrp_payments',\n    number: 'Question 5 of 9',\n    text: 'Do you make payments to companies or individuals outside Saudi Arabia?',\n    hint: 'WHT (Withholding Tax) applies when making certain payments to non-residents from a Saudi source.',\n    layout: 'two-col',\n    options: [\n      { value: 'nrp_regular', icon: '\ud83d\udd04', label: 'Yes, regularly', desc: 'Monthly \/ ongoing cross-border payments' },\n      { value: 'nrp_occasional', icon: '\ud83d\udcc5', label: 'Yes, occasionally', desc: 'One-off or infrequent payments' },\n      { value: 'nrp_no', icon: '\u2705', label: 'No', desc: 'All payments are to Saudi-resident parties' },\n    ]\n  },\n  {\n    id: 'related_parties',\n    number: 'Question 6 of 9',\n    text: 'Do you transact with related parties \u2014 parent companies, subsidiaries, or affiliates?',\n    hint: 'Transfer Pricing rules apply to all entities with related-party transactions since January 2024.',\n    layout: 'two-col',\n    options: [\n      { value: 'rp_crossborder', icon: '\ud83c\udf10', label: 'Yes \u2014 cross-border', desc: 'Transactions with overseas group companies' },\n      { value: 'rp_domestic', icon: '\ud83c\udfe0', label: 'Yes \u2014 domestic only', desc: 'Transactions within KSA group' },\n      { value: 'rp_both', icon: '\ud83d\udd17', label: 'Yes \u2014 both', desc: 'Domestic and cross-border related-party transactions' },\n      { value: 'rp_none', icon: '\u26d4', label: 'No related parties', desc: 'Fully independent entity' },\n    ]\n  },\n  {\n    id: 'rp_value',\n    number: 'Question 7 of 9',\n    text: 'What is the approximate total value of your related-party transactions per year?',\n    hint: 'This determines your Transfer Pricing documentation requirements under ZATCA bylaws.',\n    layout: 'two-col',\n    condition: (ans) => ans.related_parties !== 'rp_none',\n    options: [\n      { value: 'rp_under6m', icon: '\ud83d\udca1', label: 'Under SAR 6 Million', desc: 'TP disclosure form required' },\n      { value: 'rp_6m_48m', icon: '\ud83d\udccb', label: 'SAR 6M \u2013 48 Million', desc: 'TP disclosure + affidavit required' },\n      { value: 'rp_48m_100m', icon: '\ud83d\udcc2', label: 'SAR 48M \u2013 100 Million', desc: 'Local\/Master File optional (FY2024-2026)' },\n      { value: 'rp_above100m', icon: '\ud83d\uddc2\ufe0f', label: 'Above SAR 100 Million', desc: 'Mandatory Local File + Master File' },\n    ]\n  },\n  {\n    id: 'real_estate',\n    number: 'Question 8 of 9',\n    text: 'Does your business buy, sell, develop, or transfer real estate in Saudi Arabia?',\n    hint: 'RETT (Real Estate Transaction Tax) of 5% applies to real estate disposals.',\n    layout: 'two-col',\n    options: [\n      { value: 're_core', icon: '\ud83c\udfd7\ufe0f', label: 'Yes \u2014 core business', desc: 'Real estate is my main activity' },\n      { value: 're_occasional', icon: '\ud83c\udfe0', label: 'Yes \u2014 occasionally', desc: 'Infrequent property transactions' },\n      { value: 're_company_shares', icon: '\ud83d\udcc8', label: 'Transfer of RE company shares', desc: '\u226550% of company assets are real estate' },\n      { value: 're_no', icon: '\u2705', label: 'No real estate activity', desc: 'No property transactions' },\n    ]\n  },\n  {\n    id: 'vat_registered',\n    number: 'Question 9 of 9',\n    text: 'Are you currently VAT-registered with ZATCA?',\n    hint: 'E-Invoicing (FATOORAH) Phase 1 & 2 obligations apply to all VAT-registered taxpayers.',\n    layout: 'two-col',\n    options: [\n      { value: 'vat_yes', icon: '\u2705', label: 'Yes, registered', desc: 'I have a VAT registration number' },\n      { value: 'vat_no', icon: '\u274c', label: 'No, not registered', desc: 'Not yet registered for VAT' },\n      { value: 'vat_unsure', icon: '\u2753', label: 'Not sure', desc: 'Unsure of current status' },\n    ]\n  },\n];\n\n\/\/ \u2500\u2500\u2500 Render Engine \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\nfunction getActiveQuestions() {\n  return questions.filter(q => !q.condition || q.condition(state.answers));\n}\n\nfunction render() {\n  const activeQs = getActiveQuestions();\n  const totalSteps = activeQs.length;\n  const step = state.currentStep;\n\n  if (step >= totalSteps) {\n    showLeadGate();\n    return;\n  }\n\n  const q = activeQs[step];\n  const pct = Math.round(((step) \/ totalSteps) * 100);\n\n  \/\/ Progress\n  document.getElementById('progress-fill').style.width = pct + '%';\n  document.getElementById('progress-count').textContent = `Step ${step + 1} of ${totalSteps}`;\n  document.getElementById('progress-wrap').classList.remove('hidden');\n\n  \/\/ Render question\n  const container = document.getElementById('questions-container');\n  container.innerHTML = `\n    <div class=\"question-card\" id=\"q-card\">\n      <div class=\"question-number\">${q.number}<\/div>\n      <div class=\"question-text\">${q.text}<\/div>\n      <div class=\"question-hint\">${q.hint}<\/div>\n      <div class=\"options-grid ${q.layout === 'three-col' ? 'three-col' : 'two-col'}\" id=\"options-grid\">\n        ${q.options.map(opt => `\n          <button class=\"option-card ${state.answers[q.id] === opt.value ? 'selected' : ''}\"\n                  onclick=\"selectOption('${q.id}', '${opt.value}', this)\"\n                  data-value=\"${opt.value}\">\n            <span class=\"option-icon\">${opt.icon}<\/span>\n            <div>\n              <div class=\"option-label\">${opt.label}<\/div>\n              <div class=\"option-desc\">${opt.desc}<\/div>\n            <\/div>\n          <\/button>\n        `).join('')}\n      <\/div>\n      <div class=\"question-nav\">\n        <button class=\"btn-back\" onclick=\"goBack()\" ${step === 0 ? 'style=\"visibility:hidden\"' : ''}>\n          \u2190 Back\n        <\/button>\n        <button class=\"btn-next\" id=\"btn-next\" onclick=\"goNext()\" ${!state.answers[q.id] ? 'disabled' : ''}>\n          ${step === totalSteps - 1 ? 'See My Results \u2192' : 'Continue \u2192'}\n        <\/button>\n      <\/div>\n    <\/div>\n  `;\n}\n\nfunction selectOption(qId, value, el) {\n  state.answers[qId] = value;\n  \/\/ Update UI\n  el.closest('.options-grid').querySelectorAll('.option-card').forEach(c => c.classList.remove('selected'));\n  el.classList.add('selected');\n  document.getElementById('btn-next').disabled = false;\n}\n\nfunction goNext() {\n  const activeQs = getActiveQuestions();\n  if (state.currentStep < activeQs.length - 1) {\n    state.currentStep++;\n    render();\n    window.scrollTo({ top: 0, behavior: 'smooth' });\n  } else {\n    showLeadGate();\n  }\n}\n\nfunction goBack() {\n  if (state.currentStep > 0) {\n    state.currentStep--;\n    render();\n    window.scrollTo({ top: 0, behavior: 'smooth' });\n  }\n}\n\n\/\/ \u2500\u2500\u2500 Lead Gate \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\nfunction showLeadGate() {\n  document.getElementById('questions-container').innerHTML = '';\n  document.getElementById('progress-wrap').classList.add('hidden');\n  document.getElementById('lead-gate').classList.remove('hidden');\n  window.scrollTo({ top: 0, behavior: 'smooth' });\n}\n\nfunction submitLead() {\n  const name    = document.getElementById('lead-name').value.trim();\n  const company = document.getElementById('lead-company').value.trim();\n  const email   = document.getElementById('lead-email').value.trim();\n  const phone   = document.getElementById('lead-phone').value.trim();\n\n  \/\/ Validation\n  let valid = true;\n  ['lead-name','lead-company','lead-email','lead-phone'].forEach(id => {\n    const el = document.getElementById(id);\n    if (!el.value.trim()) { el.classList.add('error'); valid = false; }\n    else el.classList.remove('error');\n  });\n  if (!email.includes('@')) {\n    document.getElementById('lead-email').classList.add('error');\n    valid = false;\n  }\n  if (!valid) return;\n\n  state.userName    = name.split(' ')[0];\n  state.userCompany = company;\n\n  \/\/ Send to WordPress AJAX \u2192 Dariba Lead Gate plugin \u2192 Brevo\n  submitToWordPress({ name, company, email, phone, answers: state.answers });\n\n  \/\/ Show results\n  document.getElementById('lead-gate').classList.add('hidden');\n  showResults();\n}\n\nfunction submitToWordPress(data) {\n  \/\/ \u2500\u2500 Send lead to WordPress (Dariba Lead Gate plugin) via AJAX \u2500\u2500\u2500\u2500\n  \/\/ The plugin's AJAX handler saves to DB and pushes to Brevo automatically.\n  \/\/ window.DARIBA_WP is injected by WordPress via wp_localize_script() \u2014 see note below.\n\n  const wpAjaxUrl = (window.DARIBA_WP && window.DARIBA_WP.ajax_url)\n    ? window.DARIBA_WP.ajax_url\n    : '\/wp-admin\/admin-ajax.php'; \/\/ fallback\n\n  const nonce = (window.DARIBA_WP && window.DARIBA_WP.nonce)\n    ? window.DARIBA_WP.nonce\n    : '';\n\n  \/\/ Build form data (WordPress AJAX expects application\/x-www-form-urlencoded)\n  const formData = new URLSearchParams({\n    action:    'dlg_submit_lead',\n    nonce:     nonce,\n    name:      data.name,\n    email:     data.email,\n    tool_slug: 'saudi-tax-assessment',\n  });\n\n  \/\/ Fire-and-forget \u2014 results show regardless of network outcome\n  fetch(wpAjaxUrl, {\n    method:  'POST',\n    headers: { 'Content-Type': 'application\/x-www-form-urlencoded' },\n    body:    formData.toString(),\n  })\n  .then(r => r.json())\n  .then(res => {\n    if (res.success) {\n      console.log('[Dariba] Lead saved & synced to Brevo \u2713');\n    } else {\n      console.warn('[Dariba] Lead save issue:', res.data && res.data.message);\n    }\n  })\n  .catch(e => console.warn('[Dariba] Network error (lead still shown results):', e));\n\n  \/\/ Also fire a DOM event \u2014 useful for any future GTM \/ analytics triggers\n  document.dispatchEvent(new CustomEvent('daribaLeadSubmit', { detail: data }));\n}\n\n\/\/ \u2500\u2500\u2500 TAX LOGIC ENGINE \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\nfunction computeTaxImplications(ans) {\n  const results = [];\n\n  const entityType   = ans.entity_type;\n  const activity     = ans.activity;\n  const revenue      = ans.revenue;\n  const foreignPct   = ans.foreign_ownership_pct;\n  const nrpPayments  = ans.nrp_payments;\n  const relatedParty = ans.related_parties;\n  const rpValue      = ans.rp_value;\n  const realEstate   = ans.real_estate;\n  const vatStatus    = ans.vat_registered;\n\n  \/\/ \u2500\u2500 1. VAT \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let vatStatus_result = 'applies';\n  let vatObligations = [];\n  let vatRisk = null;\n  let vatTip = null;\n  let vatSummary = '';\n  let vatDetails = {};\n\n  const isFinance = activity === 'finance';\n  const aboveManThreshold = ['375k_3m','3m_150m','150m_500m','above_500m'].includes(revenue);\n  const aboveVolThreshold = ['187k_375k','375k_3m','3m_150m','150m_500m','above_500m'].includes(revenue);\n\n  if (aboveManThreshold) {\n    vatStatus_result = 'applies';\n    vatSummary = 'Mandatory registration required';\n    vatObligations = [\n      'Register with ZATCA immediately if not already registered',\n      'Charge 15% VAT on all standard-rated taxable supplies',\n      'File VAT returns (monthly or quarterly based on revenue)',\n      'Issue tax-compliant invoices for all B2B supplies',\n      'Maintain VAT records for a minimum of 6 years',\n    ];\n    if (vatStatus === 'vat_no') {\n      vatRisk = '\u26a0\ufe0f Your revenue exceeds the mandatory registration threshold of SAR 375,000. Failure to register exposes you to ZATCA penalties and back-assessment.';\n    }\n    vatDetails = { Rate: '15%', Threshold: 'SAR 375,000 (mandatory)', Frequency: revenue === 'above_500m' ? 'Monthly' : 'Quarterly' };\n  } else if (aboveVolThreshold) {\n    vatStatus_result = 'maybe';\n    vatSummary = 'Voluntary registration is available';\n    vatObligations = [\n      'You may voluntarily register for VAT (revenue between SAR 187,500 \u2013 375,000)',\n      'Registration allows you to recover input VAT on business purchases',\n      'Once registered, all VAT obligations apply equally',\n    ];\n    vatTip = '\ud83d\udca1 Tip: If you have significant VAT-bearing costs, voluntary registration can improve cash flow.';\n    vatDetails = { Rate: '15% (if registered)', Threshold: 'SAR 187,500 (voluntary)', Status: 'Optional' };\n  } else {\n    vatStatus_result = 'exempt';\n    vatSummary = 'Below registration thresholds \u2014 not required';\n    vatObligations = ['Revenue is below the SAR 187,500 voluntary registration threshold', 'No VAT obligations unless you voluntarily register'];\n    vatDetails = { Threshold: 'SAR 187,500 (voluntary)', Status: 'Not applicable' };\n  }\n\n  if (isFinance) {\n    vatTip = '\ud83d\udca1 Financial services are largely exempt from VAT. You may not be able to recover input VAT on exempt supplies. A partial exemption calculation (pro-rata) may be required if you make mixed supplies.';\n  }\n  if (activity === 'real_estate') {\n    vatTip = (vatTip || '') + ' \ud83c\udfd7\ufe0f The sale and rental of bare land and residential real estate are VAT-exempt. Commercial real estate and construction services are standard-rated at 15%.';\n  }\n\n  results.push({\n    name: 'Value Added Tax (VAT)',\n    icon: '\ud83e\uddfe',\n    status: vatStatus_result,\n    summary: vatSummary,\n    obligations: vatObligations,\n    details: vatDetails,\n    risk: vatRisk,\n    tip: vatTip,\n    regulation: 'VAT Implementing Regulations (June 2023 + Apr 2025 Amendments)'\n  });\n\n  \/\/ \u2500\u2500 2. ZAKAT \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let zakatStatus = 'exempt';\n  let zakatSummary = '';\n  let zakatObligations = [];\n  let zakatDetails = {};\n  let zakatTip = null;\n  let zakatRisk = null;\n\n  if (entityType === 'saudi_100' || entityType === 'individual') {\n    zakatStatus = 'applies';\n    zakatSummary = '100% Saudi\/GCC-owned entities are fully subject to Zakat';\n    zakatObligations = [\n      'File annual Zakat return with ZATCA',\n      'Zakat is calculated at 2.5% of the Zakat Base (equity + long-term liabilities \u2212 fixed assets \u2212 investments)',\n      'Zakat year aligns with fiscal year (Hijri or Gregorian)',\n      'Zakat return must be filed within 120 days of fiscal year end',\n      'Payment of Zakat due within the same deadline as return filing',\n    ];\n    zakatDetails = { Rate: '2.5% of Zakat Base', Applies_to: 'Saudi \/ GCC ownership', Filing: 'Within 120 days of FY end' };\n    zakatTip = '\ud83d\udca1 Zakat is not an expense deductible from income \u2014 it is a religious obligation calculated on your net worth\/equity deployed in business.';\n  } else if (entityType === 'mixed') {\n    zakatStatus = 'applies';\n    let saudiPct = '\u2014';\n    if (foreignPct === 'foreign_lt25') saudiPct = '75\u2013100% Saudi portion \u2192 Zakat';\n    else if (foreignPct === 'foreign_25_49') saudiPct = '51\u201375% Saudi portion \u2192 Zakat';\n    else if (foreignPct === 'foreign_50_74') saudiPct = '26\u201350% Saudi portion \u2192 Zakat';\n    else if (foreignPct === 'foreign_75_99') saudiPct = '1\u201325% Saudi portion \u2192 Zakat';\n    zakatSummary = 'Zakat applies on the Saudi\/GCC-owned share; CIT applies on foreign share';\n    zakatObligations = [\n      'The Zakat base and tax base are apportioned by ownership percentage',\n      `Saudi\/GCC-owned portion is subject to Zakat at 2.5% \u2014 ${saudiPct}`,\n      'Separate Zakat return and CIT return required for each regime',\n      'Both filings are due within 120 days of fiscal year end',\n    ];\n    zakatDetails = { Rate: '2.5% on Saudi\/GCC share', Structure: 'Apportioned ownership', Filing: '120 days post FY-end' };\n  } else if (entityType === 'foreign') {\n    zakatStatus = 'exempt';\n    zakatSummary = 'Fully foreign-owned entities are not subject to Zakat';\n    zakatObligations = ['CIT (Income Tax) applies instead \u2014 see below'];\n    zakatDetails = { Status: 'Not applicable', Reason: 'Non-Saudi \/ non-GCC ownership' };\n  }\n\n  results.push({\n    name: 'Zakat',\n    icon: '\u262a\ufe0f',\n    status: zakatStatus,\n    summary: zakatSummary,\n    obligations: zakatObligations,\n    details: zakatDetails,\n    risk: zakatRisk,\n    tip: zakatTip,\n    regulation: 'Zakat Implementing Regulations 1445H (2024)'\n  });\n\n  \/\/ \u2500\u2500 3. CORPORATE INCOME TAX (CIT) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let citStatus = 'exempt';\n  let citSummary = '';\n  let citObligations = [];\n  let citDetails = {};\n  let citTip = null;\n  let citRisk = null;\n\n  if (entityType === 'foreign') {\n    citStatus = 'applies';\n    citSummary = 'CIT applies on all income from Saudi sources';\n    citObligations = [\n      'Register with ZATCA before the end of your first fiscal year',\n      'CIT applies at 20% on net taxable income attributable to foreign ownership',\n      'File annual income tax return within 120 days of fiscal year end',\n      'Maintain accounting records in Arabic, in the Kingdom',\n      'Deductible expenses must be ordinary, necessary, and supported by documentation',\n      activity === 'hydrocarbons' ? 'Special CIT rates apply for oil & hydrocarbon activities \u2014 consult ZATCA' : '',\n    ].filter(Boolean);\n    citDetails = { Rate: '20% on taxable income', Applies_to: '100% foreign-owned entity', Filing: '120 days post FY-end' };\n    citTip = '\ud83d\udca1 A non-resident with no Permanent Establishment in KSA generating Saudi-source income may still be subject to Withholding Tax (see WHT section below).';\n  } else if (entityType === 'mixed') {\n    citStatus = 'applies';\n    let foreignShare = '\u2014';\n    if (foreignPct === 'foreign_lt25') foreignShare = 'Up to 25% of income subject to CIT';\n    else if (foreignPct === 'foreign_25_49') foreignShare = '25\u201349% of income subject to CIT';\n    else if (foreignPct === 'foreign_50_74') foreignShare = '50\u201374% of income subject to CIT';\n    else if (foreignPct === 'foreign_75_99') foreignShare = '75\u201399% of income subject to CIT';\n    citSummary = 'CIT applies on the foreign-owned share of income';\n    citObligations = [\n      `${foreignShare} at a rate of 20%`,\n      'Apportioned CIT return must be filed separately from the Zakat return',\n      'Both due within 120 days after fiscal year end',\n      'Transfer pricing rules apply to any related-party cross-border transactions',\n    ];\n    citDetails = { Rate: '20% on foreign share', Apportionment: 'By ownership %', Filing: '120 days post FY-end' };\n  } else if (entityType === 'saudi_100' || entityType === 'individual') {\n    citStatus = 'exempt';\n    citSummary = 'CIT does not apply \u2014 100% Saudi\/GCC entity pays Zakat instead';\n    citObligations = ['No CIT obligation for fully Saudi\/GCC-owned entities (Zakat applies)'];\n    citDetails = { Status: 'Not applicable', Reason: '100% Saudi\/GCC ownership' };\n    if (activity === 'hydrocarbons') {\n      citStatus = 'applies';\n      citSummary = 'CIT applies for oil & hydrocarbons activity regardless of ownership';\n      citObligations = ['CIT applies to ALL persons engaged in oil & hydrocarbon production\/transportation', 'Rate may vary; consult ZATCA and specialist tax advisors'];\n    }\n  }\n\n  results.push({\n    name: 'Corporate Income Tax (CIT)',\n    icon: '\ud83c\udfdb\ufe0f',\n    status: citStatus,\n    summary: citSummary,\n    obligations: citObligations,\n    details: citDetails,\n    risk: citRisk,\n    tip: citTip,\n    regulation: 'Income Tax Implementing Regulations (Nov 2024)'\n  });\n\n  \/\/ \u2500\u2500 4. WITHHOLDING TAX (WHT) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let whtStatus = 'exempt';\n  let whtSummary = '';\n  let whtObligations = [];\n  let whtDetails = {};\n  let whtRisk = null;\n  let whtTip = null;\n\n  if (nrpPayments === 'nrp_regular' || nrpPayments === 'nrp_occasional') {\n    whtStatus = 'applies';\n    whtSummary = 'WHT applies on payments to non-residents from Saudi sources';\n    whtObligations = [\n      'Register with ZATCA as a WHT payer before making the first payment',\n      'Withhold tax at source before remitting payments abroad',\n      'Management fees: 20% WHT',\n      'Royalties: 15% WHT',\n      'Technical\/consulting services, rent, dividends, interest, insurance, freight: 5% WHT',\n      'Other payments to non-residents: 15% WHT',\n      'File and pay WHT to ZATCA within the first 10 days of the following month',\n      'Obtain a Tax Identification Number (TIN) from ZATCA',\n    ];\n    whtDetails = { Mgmt_Fees: '20%', Royalties: '15%', Tech_Services_Dividends: '5%', Other: '15%' };\n    whtRisk = nrpPayments === 'nrp_occasional'\n      ? '\u26a0\ufe0f Even occasional payments to non-residents trigger WHT obligations. Late withholding or failure to register can result in penalties and liability for the gross payment amount.'\n      : null;\n    whtTip = '\ud83d\udca1 Double Tax Treaties (DTTs) may reduce WHT rates if the recipient country has a treaty with Saudi Arabia. Review applicable treaties before determining final rates.';\n  } else {\n    whtStatus = 'exempt';\n    whtSummary = 'No cross-border payments \u2014 WHT obligation not triggered';\n    whtObligations = ['No WHT obligation as long as all payments are to Saudi-resident parties'];\n    whtDetails = { Status: 'Not triggered', Reason: 'No payments to non-residents' };\n  }\n\n  results.push({\n    name: 'Withholding Tax (WHT)',\n    icon: '\u2702\ufe0f',\n    status: whtStatus,\n    summary: whtSummary,\n    obligations: whtObligations,\n    details: whtDetails,\n    risk: whtRisk,\n    tip: whtTip,\n    regulation: 'Income Tax Law Article 68 + Article 63 of Implementing Regulations'\n  });\n\n  \/\/ \u2500\u2500 5. TRANSFER PRICING \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let tpStatus = 'exempt';\n  let tpSummary = '';\n  let tpObligations = [];\n  let tpDetails = {};\n  let tpRisk = null;\n  let tpTip = null;\n\n  if (relatedParty && relatedParty !== 'rp_none') {\n    tpStatus = 'applies';\n    let docLevel = '';\n    if (rpValue === 'rp_under6m') {\n      docLevel = 'TP Disclosure Form + Chartered Accountant Affidavit required';\n    } else if (rpValue === 'rp_6m_48m') {\n      docLevel = 'TP Disclosure Form + Affidavit required; Local\/Master File not required';\n    } else if (rpValue === 'rp_48m_100m') {\n      docLevel = 'TP Disclosure + Local\/Master File optional (mandatory from FY2027)';\n    } else if (rpValue === 'rp_above100m') {\n      docLevel = 'TP Disclosure + Local File + Master File MANDATORY';\n    }\n    const isCrossborder = relatedParty === 'rp_crossborder' || relatedParty === 'rp_both';\n    tpSummary = 'Transfer Pricing rules apply to all entities with related-party transactions (since Jan 2024)';\n    tpObligations = [\n      'All related-party transactions must comply with the arm\\'s length principle',\n      docLevel,\n      'Submit TP Disclosure Form with annual Zakat\/CIT return',\n      'Affidavit from a chartered accountant is required',\n      isCrossborder ? 'Cross-border transactions require full TP documentation' : '',\n      rpValue === 'rp_above100m' && revenue === 'above_500m' ? 'Country-by-Country Report (CbCR) may be required if consolidated group revenue exceeds SAR 3.2 billion' : '',\n    ].filter(Boolean);\n    tpDetails = { Scope: 'All related-party transactions', Rate: 'Arm\\'s length principle', Threshold_DocFile: 'SAR 48M (mandatory FY2024-2026: >100M)' };\n    tpRisk = relatedParty === 'rp_crossborder' || relatedParty === 'rp_both'\n      ? '\u26a0\ufe0f Since January 2024, TP rules apply to ALL Zakat payers \u2014 not just CIT payers. Even domestic-only Saudi companies with related-party transactions must comply.'\n      : null;\n    tpTip = '\ud83d\udca1 Transactions below SAR 6M do not exempt you from TP disclosure. There is NO de minimis threshold for the disclosure form and affidavit obligation.';\n  } else {\n    tpStatus = 'exempt';\n    tpSummary = 'No related-party transactions \u2014 Transfer Pricing not triggered';\n    tpObligations = ['No TP obligations for independent entities with no related-party transactions'];\n    tpDetails = { Status: 'Not applicable', Reason: 'No related parties identified' };\n  }\n\n  results.push({\n    name: 'Transfer Pricing (TP)',\n    icon: '\ud83d\udd04',\n    status: tpStatus,\n    summary: tpSummary,\n    obligations: tpObligations,\n    details: tpDetails,\n    risk: tpRisk,\n    tip: tpTip,\n    regulation: 'TP Bylaws 2021 + ZATCA 2024 Expansion to Zakat Payers'\n  });\n\n  \/\/ \u2500\u2500 6. RETT \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let rettStatus = 'exempt';\n  let rettSummary = '';\n  let rettObligations = [];\n  let rettDetails = {};\n  let rettRisk = null;\n  let rettTip = null;\n\n  if (realEstate !== 're_no') {\n    rettStatus = 'applies';\n    if (realEstate === 're_core') {\n      rettSummary = 'RETT applies to all real estate disposals at 5%';\n      rettObligations = [\n        '5% RETT applies on the total value (gross consideration) of each real estate transaction',\n        'RETT replaces VAT for residential real estate \u2014 NOT cumulative with VAT on the same transaction',\n        'File and pay RETT to ZATCA within 30 days of the transaction date',\n        'The transferor (seller) is the liable party unless agreed otherwise',\n        'Commercial real estate transactions may also be subject to VAT (15%) on top of RETT \u2014 consult a specialist',\n      ];\n    } else if (realEstate === 're_company_shares') {\n      rettSummary = 'RETT may apply to share transfers in real estate companies';\n      rettObligations = [\n        'RETT applies if the company is a \"real estate company\" \u2014 \u226550% of fair market value of assets = real estate',\n        'Triggered when \u226530% of company shares are transferred (in aggregate within 3 years)',\n        'Tax base: FMV of real estate \u00d7 transferred share percentage',\n        'ZATCA must be notified of share transfers in real estate companies',\n      ];\n      rettRisk = '\u26a0\ufe0f Share transfers in real estate-holding companies are often overlooked for RETT. This applies to indirect real estate disposals through corporate structures.';\n    } else if (realEstate === 're_occasional') {\n      rettSummary = 'RETT applies to each individual real estate transaction at 5%';\n      rettObligations = [\n        'Each property sale or transfer triggers 5% RETT on the transaction value',\n        'File and pay within 30 days of the transaction date',\n        'Key exemptions: inheritance division, endowments (waqf), transfers to public entities, charitable organisations',\n        'Intra-group restructuring exemptions may apply under specific conditions',\n      ];\n    }\n    rettDetails = { Rate: '5% of gross transaction value', Payment: 'Within 30 days of transaction', Exemptions: 'Inheritance, waqf, public entities' };\n    rettTip = rettTip || '\ud83d\udca1 RETT replaced VAT on most real estate transactions. However, commercial leases and construction services remain subject to 15% VAT. Dual exposure is possible \u2014 verify the nature of each transaction.';\n  } else {\n    rettStatus = 'exempt';\n    rettSummary = 'No real estate transactions \u2014 RETT not applicable';\n    rettObligations = ['RETT does not apply to your business based on your answers'];\n    rettDetails = { Status: 'Not applicable' };\n  }\n\n  results.push({\n    name: 'Real Estate Transaction Tax (RETT)',\n    icon: '\ud83c\udfd8\ufe0f',\n    status: rettStatus,\n    summary: rettSummary,\n    obligations: rettObligations,\n    details: rettDetails,\n    risk: rettRisk,\n    tip: rettTip,\n    regulation: 'RETT Implementation Regulations (March 2025)'\n  });\n\n  \/\/ \u2500\u2500 7. E-INVOICING \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n  let einvStatus = 'exempt';\n  let einvSummary = '';\n  let einvObligations = [];\n  let einvDetails = {};\n  let einvRisk = null;\n  let einvTip = null;\n\n  const isVatRegistered = vatStatus === 'vat_yes' || (aboveManThreshold && vatStatus !== 'vat_no');\n  const isLargeRevenue = ['150m_500m','above_500m'].includes(revenue);\n  const isMidRevenue = revenue === '3m_150m';\n\n  if (isVatRegistered || aboveManThreshold) {\n    einvStatus = 'applies';\n    if (isLargeRevenue) {\n      einvSummary = 'E-Invoicing Phase 1 & Phase 2 (FATOORAH integration) apply';\n      einvObligations = [\n        'Phase 1 (Generation): All VAT-registered taxpayers must generate and store e-invoices in compliant format',\n        'Phase 2 (Integration): Your revenue bracket is within ZATCA\\'s phased integration rollout',\n        'Must integrate with ZATCA\\'s FATOORAH system \u2014 Peppol-based real-time reporting',\n        'Standard tax invoices: full XML + QR code + cryptographic stamp required',\n        'Simplified tax invoices: QR code + hash required',\n        'Retain all e-invoices electronically for a minimum of 6 years',\n      ];\n      einvDetails = { Phase_1: 'Active (All VAT registrants)', Phase_2: 'Active \u2014 check your ZATCA wave letter', System: 'FATOORAH (ZATCA portal)' };\n      einvRisk = '\u26a0\ufe0f Large businesses in your revenue bracket have already been onboarded for Phase 2. If you have not received your ZATCA wave letter, contact ZATCA immediately.';\n    } else {\n      einvSummary = 'E-Invoicing Phase 1 applies; Phase 2 rollout ongoing by ZATCA waves';\n      einvObligations = [\n        'Phase 1 (Generation): Active for ALL VAT-registered taxpayers since December 2021',\n        'Generate e-invoices in ZATCA-compliant XML format with QR codes',\n        'Phase 2 (Integration): ZATCA will notify you by wave \u2014 monitor ZATCA announcements',\n        'Retain all electronic invoices for a minimum of 6 years',\n        'Standard invoices require buyer TIN; simplified invoices for retail\/B2C',\n      ];\n      einvDetails = { Phase_1: 'Mandatory (all VAT registrants)', Phase_2: 'Wave-based rollout \u2014 await ZATCA notification', System: 'FATOORAH (ZATCA portal)' };\n    }\n    einvTip = '\ud83d\udca1 Non-compliance with e-invoicing requirements can result in fines from SAR 5,000 to SAR 50,000 per violation. Use ZATCA-approved solution providers (ASPs) for compliant implementation.';\n  } else {\n    einvStatus = 'exempt';\n    einvSummary = 'E-invoicing does not apply \u2014 requires VAT registration first';\n    einvObligations = ['E-invoicing obligations arise only upon VAT registration', 'If your revenue triggers mandatory VAT registration, e-invoicing follows automatically'];\n    einvDetails = { Status: 'Not applicable', Note: 'Applies upon VAT registration' };\n  }\n\n  results.push({\n    name: 'E-Invoicing (FATOORAH)',\n    icon: '\ud83d\udda5\ufe0f',\n    status: einvStatus,\n    summary: einvSummary,\n    obligations: einvObligations,\n    details: einvDetails,\n    risk: einvRisk,\n    tip: einvTip,\n    regulation: 'VAT Implementing Regulations \u2014 E-Invoicing provisions + ZATCA FATOORAH regulations'\n  });\n\n  return results;\n}\n\n\/\/ \u2500\u2500\u2500 Render Results \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\nfunction showResults() {\n  document.getElementById('progress-wrap').classList.add('hidden');\n  const container = document.getElementById('results-container');\n  container.classList.remove('hidden');\n\n  const results = computeTaxImplications(state.answers);\n  const applicableCount = results.filter(r => r.status === 'applies').length;\n\n  let html = `\n    <div class=\"results-header\">\n      <div class=\"results-greeting\">Assessment Complete<\/div>\n      <h2>Your Saudi Tax Obligations Overview<\/h2>\n      <p>Based on your inputs \u2014 ${applicableCount} of ${results.length} tax regimes are applicable to ${state.userCompany || 'your business'}.<\/p>\n    <\/div>\n    <div class=\"results-disclaimer\">\n      \u26a0\ufe0f <strong>Important:<\/strong> This assessment is a high-level indicative overview based on the information you provided. It does not constitute professional tax advice. Regulations change frequently \u2014 consult a qualified Saudi tax advisor before making compliance decisions.\n    <\/div>\n    <div class=\"results-grid\">\n  `;\n\n  results.forEach((r, i) => {\n    const statusLabel = r.status === 'applies' ? 'APPLICABLE' : r.status === 'maybe' ? 'REVIEW NEEDED' : 'NOT APPLICABLE';\n    const detailsHtml = Object.entries(r.details).map(([k, v]) => `\n      <div class=\"tax-detail-item\">\n        <div class=\"tax-detail-label\">${k.replace(\/_\/g,' ')}<\/div>\n        <div class=\"tax-detail-value ${['Rate','CIT_Rate','WHT_Rate'].includes(k) ? 'gold' : ''}\">${v}<\/div>\n      <\/div>\n    `).join('');\n\n    html += `\n      <div class=\"tax-card status-${r.status}\" style=\"animation-delay: ${i * 0.07}s\" id=\"tax-card-${i}\">\n        <div class=\"tax-card-header\" onclick=\"toggleCard(${i})\">\n          <div class=\"tax-card-icon\">${r.icon}<\/div>\n          <div class=\"tax-card-meta\">\n            <div class=\"tax-card-name\">${r.name}<\/div>\n            <div class=\"tax-card-summary\">${r.summary}<\/div>\n          <\/div>\n          <span class=\"tax-status-badge\">${statusLabel}<\/span>\n          <span class=\"tax-card-toggle\">\u25bc<\/span>\n        <\/div>\n        <div class=\"tax-card-body\">\n          ${Object.keys(r.details).length > 0 ? `<div class=\"tax-detail-grid\">${detailsHtml}<\/div>` : ''}\n          ${r.obligations.length > 0 ? `\n          <div class=\"tax-obligations\">\n            <h4>Key Obligations & Notes<\/h4>\n            <ul class=\"obligation-list\">\n              ${r.obligations.map(o => `<li>${o}<\/li>`).join('')}\n            <\/ul>\n          <\/div>` : ''}\n          ${r.risk ? `<div class=\"tax-risk-flag\">\u26a0\ufe0f <span>${r.risk.replace('\u26a0\ufe0f ','')}<\/span><\/div>` : ''}\n          ${r.tip ? `<div class=\"tax-tip\">\ud83d\udca1 <span>${r.tip.replace('\ud83d\udca1 ','').replace('\ud83d\udca1','')}<\/span><\/div>` : ''}\n          <div style=\"margin-top:0.875rem; font-size:0.75rem; color:var(--ink-muted); font-style:italic; border-top:1px solid var(--cream); padding-top:0.5rem;\">\n            Regulatory basis: ${r.regulation}\n          <\/div>\n        <\/div>\n      <\/div>\n    `;\n  });\n\n  html += `\n    <\/div>\n    <div class=\"results-cta\">\n      <h3>Need Expert Clarity on Your Obligations?<\/h3>\n      <p>Dariba.co provides authoritative, ZATCA-aligned guidance on all Saudi tax regimes. Our team of specialists can help you navigate complex compliance requirements.<\/p>\n      <div class=\"cta-buttons\">\n        <a href=\"https:\/\/dariba.co\/advisory\" class=\"btn-cta-primary\">Book a Free Consultation<\/a>\n        <a href=\"https:\/\/dariba.co\/tax-topics\" class=\"btn-cta-secondary\">Explore Tax Topics \u2192<\/a>\n      <\/div>\n    <\/div>\n  `;\n\n  container.innerHTML = html;\n  window.scrollTo({ top: 0, behavior: 'smooth' });\n}\n\nfunction toggleCard(idx) {\n  const card = document.getElementById(`tax-card-${idx}`);\n  card.classList.toggle('expanded');\n}\n\n\/\/ \u2500\u2500\u2500 Initialize \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\ndocument.addEventListener('DOMContentLoaded', function() {\n  render();\n  \/\/ Expand first applicable card by default in results\n});\n<\/script>\n<\/body>\n<\/html>\n\n","protected":false},"excerpt":{"rendered":"<p>Saudi Tax Implications Checker \u2014 Dariba.co Free Self-Assessment Know Your Tax Obligationsin Saudi Arabia Answer a few questions and receive an instant, personalised overview of the Saudi taxes applicable to your business \u2014 based on ZATCA regulations. Assessment Progress Step 1 of 9 \ud83d\udd12 Your Assessment Is Ready Unlock Your Free Tax Report Enter your [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-385","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.dariba.co\/index.php?rest_route=\/wp\/v2\/pages\/385","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dariba.co\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.dariba.co\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.dariba.co\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dariba.co\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=385"}],"version-history":[{"count":0,"href":"https:\/\/www.dariba.co\/index.php?rest_route=\/wp\/v2\/pages\/385\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.dariba.co\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=385"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}