/* ===========================================================
   CarTech design tokens — black / white / turquoise palette.
   Loaded via website.custom_code_head <link>.
   =========================================================== */

@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+Arabic:wght@300;400;500;600;700&family=Tajawal:wght@300;400;500;700;800&family=Inter:wght@200;300;400;500;600;700&display=swap');

:root {
  /* Palette: monochrome + turquoise (CarTech brand) */
  --ct-bg:        #FFFFFF;
  --ct-surface:   #FAF7F1;        /* very faint aqua tint */
  --ct-ink:       #0B1020;        /* near-black with a hint of teal */
  --ct-text-mid:  rgba(11,16,32,0.66);
  --ct-text-low:  rgba(11,16,32,0.45);
  --ct-text-on-dark-mid: rgba(255,255,255,0.72);
  --ct-line:      #ECE7DD;        /* hairline borders, cool aqua-grey */
  --ct-line-dark: rgba(255,255,255,0.12);

  /* Accent: brand turquoise (matches CarTech identity) */
  --ct-blue:      #D8B56B;        /* primary accent — brand turquoise */
  --ct-blue-deep: #B8893D;        /* hover / link emphasis — deep teal (WCAG AA on white) */
  --ct-blue-soft: #F5EBD6;        /* pill backgrounds — pale aqua */

  /* Type scale */
  --ct-fs-display: clamp(44px, 7vw, 92px);
  --ct-fs-h2:      clamp(30px, 4.5vw, 56px);
  --ct-fs-h3:      clamp(22px, 2.2vw, 28px);
  --ct-fs-lede:    clamp(17px, 1.5vw, 21px);
  --ct-fs-body:    16px;

  /* Fonts */
  --ct-font-ar:   'Tajawal', 'IBM Plex Sans Arabic', 'Cairo', system-ui, sans-serif;
  --ct-font-en:   'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --ct-font-num:  'Inter', 'Tajawal', sans-serif;
}

/* Global font selection — Arabic primary */
html[lang^="ar"],
html[lang^="ar"] body {
  font-family: var(--ct-font-ar) !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
html[lang="en-US"],
html[lang="en-US"] body {
  font-family: var(--ct-font-en);
}

/* Numbers/Latin should stay in Inter even within Arabic text for crispness */
.ct-num, .ct-stat strong, .ct-kpi strong, .ct-vital strong,
.ct-case__index, .ct-step__num {
  font-family: var(--ct-font-num);
  font-feature-settings: "tnum" 1, "ss01" 1;
  font-variant-numeric: tabular-nums;
}

/* Force display headings to use Tajawal Bold in Arabic for impact */
html[lang^="ar"] .ct-display,
html[lang^="ar"] .ct-headline {
  font-family: var(--ct-font-ar);
  font-weight: 800;     /* Tajawal extra-bold */
  letter-spacing: -0.01em;
  line-height: 1.15;    /* Arabic needs more line-height than Latin */
}
html[lang^="ar"] .ct-display em,
html[lang^="ar"] .ct-headline em {
  font-style: normal;
  color: var(--ct-blue);
}

/* Tighten Latin display when present */
html[lang="en-US"] .ct-display,
html[lang="en-US"] .ct-headline {
  font-family: var(--ct-font-en);
  letter-spacing: -0.035em;
  line-height: 0.98;
  font-weight: 700;
}

/* Section padding rhythm + colors */
.ct-section          { padding: clamp(72px, 11vw, 144px) 0; }
.ct-section--bg      { background: var(--ct-bg); color: var(--ct-ink); }
.ct-section--surface { background: var(--ct-surface); color: var(--ct-ink); }
.ct-section--ink     { background: var(--ct-ink); color: #FFFFFF; }

/* Containers */
.ct-container        { max-width: 1240px; margin: 0 auto; padding: 0 32px; }
.ct-container--narrow{ max-width: 820px; }

/* Section header (lead block) */
.ct-lead             { text-align: center; margin: 0 auto clamp(48px, 7vw, 88px); max-width: 720px; }
.ct-lead--left       { text-align: start; margin-left: 0; }

/* Eyebrow */
.ct-eyebrow          { font-size: 13px; font-weight: 500;
                       letter-spacing: 0.06em; color: var(--ct-blue-deep);
                       margin: 0 0 20px; display: inline-block; }
html[lang^="ar"] .ct-eyebrow { letter-spacing: 0; font-weight: 700; }
.ct-section--ink .ct-eyebrow { color: var(--ct-blue); }
.ct-eyebrow--on-dark { color: var(--ct-blue); }

/* Larger eyebrow variant — for sections that need extra section-label weight */
.ct-eyebrow--large {
  font-size: clamp(15px, 1.6vw, 18px) !important;
  font-weight: 800 !important;
  letter-spacing: 0 !important;
  padding: 6px 14px;
  background: var(--ct-blue-soft, #F5EBD6);
  color: var(--ct-blue-deep, #B8893D) !important;
  border-radius: 999px;
  margin-bottom: 24px !important;
}

/* Luxury eyebrow variant — gold-ish accent + serif feel */
.ct-eyebrow--luxury {
  font-size: 12px !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase;
  color: transparent !important;
  background: linear-gradient(135deg, #B8893D 0%, #E8C47B 50%, #B8893D 100%);
  -webkit-background-clip: text;
          background-clip: text;
  position: relative;
}
.ct-eyebrow--luxury::before,
.ct-eyebrow--luxury::after {
  content: '✦';
  background: linear-gradient(135deg, #B8893D 0%, #E8C47B 50%, #B8893D 100%);
  -webkit-background-clip: text;
          background-clip: text;
  margin: 0 8px;
  font-size: 10px;
  vertical-align: middle;
}

/* Display / headline / lede */
.ct-display          { font-size: var(--ct-fs-display);
                       margin: 0 0 28px; color: var(--ct-ink); }
.ct-display--on-dark { color: #FFFFFF; text-shadow: 0 2px 24px rgba(0,0,0,0.18); }
.ct-headline         { font-size: var(--ct-fs-h2);
                       margin: 0 0 24px; color: var(--ct-ink); font-weight: 700;
                       line-height: 1.08; letter-spacing: -0.02em; }
.ct-lede             { font-size: var(--ct-fs-lede); line-height: 1.6;
                       color: var(--ct-text-mid); margin: 0; font-weight: 400; }
.ct-lede--on-dark    { color: rgba(255,255,255,0.86); }
.ct-section--ink .ct-lede { color: rgba(255,255,255,0.72); }

/* Buttons */
.ct-btn              { display: inline-flex; align-items: center; justify-content: center;
                       padding: 16px 32px; border-radius: 12px; font-weight: 600;
                       font-size: 15px; text-decoration: none;
                       transition: opacity .18s ease, transform .12s ease, background .18s ease;
                       border: 1px solid transparent; cursor: pointer;
                       font-family: inherit; }
html[lang^="ar"] .ct-btn { font-weight: 700; }
.ct-btn--primary     { background: var(--ct-ink); color: #FFFFFF; }
.ct-btn--primary:hover { background: #000; transform: translateY(-1px); }
.ct-btn--blue        { background: var(--ct-blue); color: var(--ct-ink); font-weight: 700; }
.ct-btn--blue:hover  { background: var(--ct-blue-deep); color: #FFFFFF; }
.ct-btn--on-dark     { background: #FFFFFF; color: var(--ct-ink); }
.ct-btn--on-dark:hover { background: var(--ct-blue); color: var(--ct-ink); }
.ct-btn--ghost       { background: transparent; color: var(--ct-ink); border: 1px solid var(--ct-line); }
.ct-btn--ghost:hover { border-color: var(--ct-ink); }
.ct-btn--text        { background: transparent; color: var(--ct-ink); padding: 16px 12px; }
.ct-btn--text:hover  { color: var(--ct-blue-deep); }
.ct-btn--text-on-dark { background: transparent; color: #FFFFFF; padding: 16px 12px; }
.ct-btn--text-on-dark:hover { color: var(--ct-blue); }

.ct-link             { color: var(--ct-ink); font-weight: 600; text-decoration: none;
                       border-bottom: 2px solid var(--ct-blue); padding-bottom: 4px;
                       display: inline-block; transition: opacity .18s ease; }
.ct-link:hover       { color: var(--ct-blue-deep); }

/* Media frame */
.ct-frame            { position: relative; border-radius: 24px; overflow: hidden;
                       background: var(--ct-ink); margin: 0;
                       box-shadow: 0 30px 80px -30px rgba(10,15,26,0.22),
                                   0 1px 0 rgba(255,255,255,0.5) inset; }
.ct-frame img, .ct-frame video {
                       width: 100%; height: 100%; object-fit: cover; display: block; }

/* Pill */
.ct-pill             { display: inline-flex; align-items: center; gap: 6px;
                       background: var(--ct-blue-soft); color: var(--ct-blue-deep);
                       padding: 6px 14px; border-radius: 999px;
                       font-size: 12px; font-weight: 600; letter-spacing: 0.02em; }

/* RTL niceties */
html[dir="rtl"] body { letter-spacing: 0; }
