/**
 * NedaBal Fun — design tokens.
 *
 * Single source of truth for the approved-v1 visual language
 * (references/approved-v1/01–10): white/blue/navy palette, soft shadows,
 * generous rounded cards, Persian RTL composition.
 *
 * Values are consumed everywhere via var(--nbf-*). Never hard-code raw
 * colors/sizes in component CSS.
 */

:root {
	/* ------------------------------------------------------------------
	 * Color — brand blues
	 * ---------------------------------------------------------------- */
	--nbf-color-primary-50: #eef5fe;
	--nbf-color-primary-100: #d9e9fd;
	--nbf-color-primary-200: #b3d3fa;
	--nbf-color-primary-300: #7fb3f3;
	--nbf-color-primary-400: #4a90e8;
	--nbf-color-primary-500: #2276dd;
	--nbf-color-primary-600: #1565d8; /* solid buttons, links, active states */
	--nbf-color-primary-700: #0f54b5;
	--nbf-color-primary-800: #0c4494;
	--nbf-color-primary-900: #0a3775;

	/* Navy — dark bars, footer, headings */
	--nbf-color-navy-500: #2c5578;
	--nbf-color-navy-600: #234563;
	--nbf-color-navy-700: #1b3a55; /* top utility bar */
	--nbf-color-navy-800: #142c42;
	--nbf-color-navy-900: #101c2b; /* footer background */

	/* Surfaces */
	--nbf-color-surface: #ffffff;
	--nbf-color-surface-alt: #f5f8fc;   /* page background */
	--nbf-color-surface-tint: #eaf3fe;  /* light blue panels, hero wash */
	--nbf-color-surface-sunken: #edf1f7;

	/* Text */
	--nbf-color-text: #1a2b3c;
	--nbf-color-text-2: #4d6075;       /* secondary copy */
	--nbf-color-text-3: #5c6c7f; /* >= 4.5:1 on white and surface-alt */       /* muted captions */
	--nbf-color-text-inverse: #ffffff;

	/* Borders */
	--nbf-color-border: #e2e9f2;
	--nbf-color-border-strong: #cfd9e6; /* inputs */

	/* Status */
	--nbf-color-success: #0e7a49; /* >= 4.5:1 on white */
	--nbf-color-success-bg: #e7f7ef;
	--nbf-color-warning: #91600a; /* >= 4.5:1 on white/surface-alt */
	--nbf-color-warning-bg: #fdf3e0;
	--nbf-color-error: #d63b4d;
	--nbf-color-error-bg: #fdeaed;
	--nbf-color-info: var(--nbf-color-primary-600);
	--nbf-color-info-bg: var(--nbf-color-primary-50);

	/* Semantic aliases */
	--nbf-color-link: var(--nbf-color-primary-600);
	--nbf-color-focus-ring: var(--nbf-color-primary-400);
	--nbf-color-backdrop: rgb(16 28 43 / 0.55);

	/* ------------------------------------------------------------------
	 * Typography
	 * ----------------------------------------------------------------
	 * Vazirmatn v33.003 is bundled locally (assets/fonts/vazirmatn/)
	 * and is the site default. The theme "Site font" setting can switch
	 * to the system stack or a custom family — the choice is emitted as
	 * a single :root override by nedabal_fun_output_font_token(); this
	 * declaration is only the stylesheet default.
	 */
	--nbf-font-sans: "Vazirmatn", Tahoma, Arial, sans-serif;

	--nbf-fs-2xs: 0.6875rem; /* 11px — fine print */
	--nbf-fs-xs: 0.75rem;    /* 12px — captions, badges */
	--nbf-fs-sm: 0.875rem;   /* 14px — secondary text, chips */
	--nbf-fs-md: 1rem;       /* 16px — body */
	--nbf-fs-lg: 1.125rem;   /* 18px — lead, card titles */
	--nbf-fs-xl: 1.25rem;    /* 20px — section subheads */
	--nbf-fs-2xl: 1.5rem;    /* 24px — section titles */
	--nbf-fs-3xl: 1.875rem;  /* 30px — page titles */
	--nbf-fs-4xl: 2.25rem;   /* 36px — hero title desktop */

	--nbf-lh-tight: 1.35;
	--nbf-lh-heading: 1.5;
	--nbf-lh-body: 1.8;      /* Persian body copy needs generous leading */

	--nbf-fw-regular: 400;
	--nbf-fw-medium: 500;
	--nbf-fw-bold: 700;
	--nbf-fw-black: 800;

	/* ------------------------------------------------------------------
	 * Spacing — 4px base scale
	 * ---------------------------------------------------------------- */
	--nbf-space-1: 0.25rem;
	--nbf-space-2: 0.5rem;
	--nbf-space-3: 0.75rem;
	--nbf-space-4: 1rem;
	--nbf-space-5: 1.25rem;
	--nbf-space-6: 1.5rem;
	--nbf-space-8: 2rem;
	--nbf-space-10: 2.5rem;
	--nbf-space-12: 3rem;
	--nbf-space-16: 4rem;

	/* Section rhythm (vertical gap between page sections) */
	--nbf-section-gap: clamp(2.5rem, 5vw, 4rem);

	/* ------------------------------------------------------------------
	 * Radius — soft, generous rounding per approved references
	 * ---------------------------------------------------------------- */
	--nbf-radius-xs: 0.375rem;
	--nbf-radius-sm: 0.5rem;
	--nbf-radius-md: 0.75rem;  /* buttons, inputs */
	--nbf-radius-lg: 1rem;     /* cards */
	--nbf-radius-xl: 1.25rem;  /* hero panels, large cards */
	--nbf-radius-pill: 999px;
	/* Alias: several components reference the common "full" name. */
	--nbf-radius-full: 999px;

	/* ------------------------------------------------------------------
	 * Shadows — soft blue-tinted elevation
	 * ---------------------------------------------------------------- */
	--nbf-shadow-xs: 0 1px 3px rgb(16 44 84 / 0.06);
	--nbf-shadow-sm: 0 2px 8px rgb(16 44 84 / 0.07);
	--nbf-shadow-md: 0 6px 20px rgb(16 44 84 / 0.09);
	--nbf-shadow-lg: 0 12px 32px rgb(16 44 84 / 0.13);

	/* ------------------------------------------------------------------
	 * Layout
	 * ----------------------------------------------------------------
	 * Breakpoints (min-width, for reference in media queries — custom
	 * properties cannot be used inside @media):
	 *   xs 360px · sm 480px · md 768px · lg 1024px · xl 1280px · 2xl 1440px
	 */
	--nbf-container-max: 75rem; /* 1200px content column */
	--nbf-container-pad: clamp(1rem, 4vw, 1.5rem);

	/* Touch targets */
	--nbf-tap-target: 2.75rem; /* 44px minimum interactive size */
	--nbf-control-h: 3rem;     /* default input/button height 48px */
	--nbf-control-h-sm: 2.5rem;

	/* ------------------------------------------------------------------
	 * Z-index scale
	 * ---------------------------------------------------------------- */
	--nbf-z-dropdown: 100;
	--nbf-z-sticky: 200;   /* sticky CTAs, bottom nav */
	--nbf-z-header: 300;
	--nbf-z-overlay: 400;  /* search overlay, drawers */
	--nbf-z-modal: 500;
	--nbf-z-toast: 600;

	/* ------------------------------------------------------------------
	 * Motion
	 * ---------------------------------------------------------------- */
	--nbf-ease: cubic-bezier(0.25, 0.6, 0.3, 1);
	--nbf-duration-fast: 120ms;
	--nbf-duration: 200ms;
	--nbf-duration-slow: 320ms;
}
