/*
 * AREB website styles.
 * Tokens come from the Figma file "Areb (Copy)" (page Dev): Inter Tight Medium, -2% tracking, warm secondary
 * palette, near-black accent, 24px card radius, soft card shadow. Arabic uses IBM Plex Sans Arabic with no tracking.
 * Layout uses logical properties only, so the same rules serve left-to-right and right-to-left pages.
 */
:root {
  --white: #ffffff;
  --n200: #f9f9f9;
  --n300: #ededed;
  --n400: #cccccc;
  --n500: #a3a3a3;
  --n600: #686868;
  --n700: #181818;
  --ink: #030303;
  --orange: #ff8b4d;
  --peach: #ffac79;
  --red: #e73038;
  --pink: #ff638d;
  --blush: #ffdee2;
  --rose: #ff8694;
  --orange-soft: #fff1e8;
  --pink-soft: #ffeef1;

  --grad-hero: linear-gradient(135deg, #ffac79 0%, #ff8b4d 28%, #ff638d 64%, #e73038 100%);
  --grad-warm: linear-gradient(135deg, #ff8b4d 0%, #ff638d 100%);
  --grad-soft-orange: linear-gradient(160deg, #fff6f0 0%, #ffe4d3 100%);
  --grad-soft-pink: linear-gradient(160deg, #fff5f7 0%, #ffdfe6 100%);

  --font-en: "Inter Tight", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-ar: "IBM Plex Sans Arabic", "Segoe UI", Tahoma, system-ui, sans-serif;
  --font: var(--font-en);
  --track: -0.02em;
  --lh-head: 1.18;

  --fs-display: clamp(2.25rem, 1.45rem + 3.1vw, 3.25rem);
  --fs-h1: clamp(2.1rem, 1.45rem + 2.5vw, 3rem);
  --fs-h2: clamp(1.85rem, 1.3rem + 2.1vw, 3rem);
  --fs-h3: clamp(1.5rem, 1.2rem + 1.1vw, 2.25rem);
  --fs-h4: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
  --fs-h5: 1.25rem;
  --fs-lead: 1.125rem;
  --fs-body: 1rem;
  --fs-small: 0.875rem;

  --radius-xs: 12px;
  --radius-sm: 16px;
  --radius: 24px;
  --radius-lg: 32px;
  --radius-xl: 40px;
  --pill: 999px;
  --shadow: 0 4px 4px rgba(211, 211, 211, 0.06), 0 1px 1px rgba(14, 14, 14, 0.06);
  --shadow-lift: 0 18px 40px rgba(231, 48, 56, 0.10), 0 2px 6px rgba(14, 14, 14, 0.05);
  --border: 1px solid rgba(3, 3, 3, 0.06);

  --container: 1256px;
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(64px, 6vw + 32px, 120px);
  --focus: 0 0 0 3px rgba(255, 99, 141, 0.45);
}

[dir="rtl"] {
  --font: var(--font-ar);
  --track: 0;
  --lh-head: 1.4;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.6;
  font-weight: 400;
  letter-spacing: var(--track);
  color: var(--ink);
  background: var(--n200);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
[dir="rtl"] body { line-height: 1.75; }
[lang="en"] { font-family: var(--font-en); }
[dir="rtl"] [lang="en"] { letter-spacing: -0.01em; }
img, video, svg { max-width: 100%; }
img, video { height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, h4, h5, h6, p, blockquote, figure, ul, ol, dl, dd { margin: 0; }
h1, h2, h3, h4, h5, h6 { font-weight: 500; line-height: var(--lh-head); letter-spacing: var(--track); text-wrap: balance; }
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3, [dir="rtl"] h4 { font-weight: 600; }
p { text-wrap: pretty; }
button, input, textarea, select { font: inherit; color: inherit; letter-spacing: inherit; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 8px; }

.display { font-size: var(--fs-display); }
.h1 { font-size: var(--fs-h1); }
.h2 { font-size: var(--fs-h2); }
.h3 { font-size: var(--fs-h3); }
.h4 { font-size: var(--fs-h4); }
.h5 { font-size: var(--fs-h5); }
.lead { font-size: var(--fs-lead); color: var(--n600); }
.muted { color: var(--n600); }

.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.hp { position: absolute; inset-inline-start: -10000px; width: 1px; height: 1px; overflow: hidden; }
.skip-link {
  position: absolute; inset-inline-start: 16px; top: -100px; z-index: 100;
  background: var(--ink); color: var(--white); padding: 10px 16px; border-radius: var(--pill); text-decoration: none;
}
.skip-link:focus { top: 16px; }
main:focus { outline: none; }

.container { width: 100%; max-width: calc(var(--container) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.container.narrow { max-width: calc(880px + 2 * var(--gutter)); }

.icon { flex: none; }
[dir="rtl"] .icon-dir { transform: scaleX(-1); }

/* ------------------------------------------------------------------ buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 28px; border-radius: var(--pill);
  font-weight: 500; font-size: 1rem; text-decoration: none; white-space: nowrap;
  border: 1px solid transparent; cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--ink); color: var(--white); }
.btn-primary:hover { background: var(--n700); box-shadow: 0 10px 24px rgba(3, 3, 3, 0.18); }
.btn-secondary { background: var(--white); color: var(--ink); border-color: var(--n300); }
.btn-secondary:hover { border-color: var(--ink); }
.btn-light { background: var(--white); color: var(--ink); }
.btn-light:hover { box-shadow: 0 10px 24px rgba(3, 3, 3, 0.16); }
.btn-sm { min-height: 44px; padding: 0 22px; font-size: 0.95rem; }
.btn-block { width: 100%; }
.btn-round {
  width: 44px; height: 44px; min-height: 0; padding: 0; border-radius: 50%;
  background: var(--ink); color: var(--white);
}
.btn[disabled], .btn[aria-busy="true"] { opacity: 0.6; cursor: progress; transform: none; }

.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--pill);
  background: var(--n200); border: var(--border); font-size: var(--fs-small); font-weight: 500;
}
.badge-accent { background: var(--grad-warm); color: var(--white); border: 0; }

/* ------------------------------------------------------------------ header */
.site-header { position: absolute; inset-inline: 0; top: 0; z-index: 30; padding-top: 20px; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; text-decoration: none; flex: none; }
.brand-logo { height: 34px; width: auto; }
.brand-mark { display: inline-flex; align-items: center; background: var(--ink); border-radius: var(--radius-sm); padding: 8px 14px; box-shadow: var(--shadow); }
.brand-mark.on-dark { background: transparent; padding: 0; box-shadow: none; }
.brand-mark.on-dark .brand-logo { height: 44px; }
.brand-word {
  font-family: var(--font-en); font-weight: 600; font-size: 1.6rem; letter-spacing: -0.04em;
  background: var(--ink); color: var(--white); padding: 4px 14px; border-radius: var(--radius-xs);
}
.brand-light .brand-word { background: var(--white); color: var(--ink); }
.main-nav {
  display: flex; align-items: center; gap: 8px;
  background: var(--white); border-radius: var(--pill); padding: 6px; box-shadow: var(--shadow);
}
.nav-list { display: flex; align-items: center; gap: 2px; list-style: none; padding: 0 6px; }
.nav-list a {
  display: block; padding: 10px 14px; border-radius: var(--pill); text-decoration: none;
  font-weight: 500; font-size: 0.975rem; color: var(--ink); transition: background-color 0.2s ease;
}
.nav-list a:hover, .nav-list a[aria-current="page"] { background: var(--n200); }
.nav-actions { display: flex; align-items: center; gap: 6px; }
.lang-switch {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px 14px; border-radius: var(--pill);
  text-decoration: none; font-weight: 500; color: var(--ink);
}
.lang-switch:hover { background: var(--n200); }
.lang-switch[lang="ar"] { font-family: var(--font-ar); letter-spacing: 0; }
.lang-switch[lang="en"] { font-family: var(--font-en); }
.nav-toggle {
  display: none; width: 48px; height: 48px; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--white); box-shadow: var(--shadow); align-items: center; justify-content: center;
}
.nav-toggle .i-close { display: none; }
.nav-open .nav-toggle .i-close { display: block; }
.nav-open .nav-toggle .i-open { display: none; }

/* ------------------------------------------------------------------ decorative art (used until real images are uploaded) */
.art { position: relative; width: 100%; height: 100%; min-height: 180px; overflow: hidden; border-radius: inherit; }
.art span { position: absolute; border-radius: 50%; filter: blur(0.5px); }
.art span:nth-child(1) { width: 58%; aspect-ratio: 1; inset-inline-end: 6%; top: 10%;
  background: radial-gradient(circle at 32% 28%, #fff 0%, #ffd2c2 18%, #ff8f70 55%, #ff638d 100%); box-shadow: 0 30px 60px rgba(231, 48, 56, 0.25); }
.art span:nth-child(2) { width: 30%; aspect-ratio: 1; inset-inline-start: 10%; bottom: 8%;
  background: radial-gradient(circle at 30% 30%, #fff 0%, #ffe0e6 30%, #ff9bb3 100%); }
.art span:nth-child(3) { width: 16%; aspect-ratio: 1; inset-inline-start: 38%; top: 12%;
  background: radial-gradient(circle at 30% 30%, #fff 0%, #ffd9bf 40%, #ffac79 100%); }
.art-hero { position: absolute; inset: 0; min-height: 0; }
.art-hero span:nth-child(1) { width: min(560px, 46vw); inset-inline-end: 4%; top: 14%;
  background: radial-gradient(circle at 30% 26%, rgba(255,255,255,0.95) 0%, rgba(255,214,200,0.9) 16%, rgba(255,143,112,0.85) 52%, rgba(231,48,56,0.65) 100%); }
.art-hero span:nth-child(2) { width: min(240px, 22vw); inset-inline-end: 38%; top: 58%;
  background: radial-gradient(circle at 30% 30%, #fff 0%, rgba(255,222,226,0.95) 30%, rgba(255,99,141,0.8) 100%); }
.art-hero span:nth-child(3) { width: min(120px, 12vw); inset-inline-end: 8%; top: 8%;
  background: radial-gradient(circle at 30% 30%, #fff 0%, rgba(255,217,191,0.95) 40%, rgba(255,172,121,0.9) 100%); }
.art-card { min-height: 0; position: absolute; inset: 0; }
.art-card span:nth-child(1) { width: 46%; inset-inline-end: 8%; top: 14%; }
.art-card span:nth-child(2) { width: 24%; inset-inline-start: 12%; bottom: 12%; }
.art-card span:nth-child(3) { width: 12%; inset-inline-start: 42%; top: 18%; }
.art-v1 span:nth-child(1) { width: 40%; inset-inline-end: auto; inset-inline-start: 14%; top: 18%; }
.art-v1 span:nth-child(2) { width: 22%; inset-inline-start: auto; inset-inline-end: 14%; bottom: 14%; }
.art-v1 span:nth-child(3) { inset-inline-start: auto; inset-inline-end: 34%; top: 10%; }
.art-v2 span:nth-child(1) { width: 34%; inset-inline-end: 33%; top: 22%; }
.art-v2 span:nth-child(2) { width: 18%; inset-inline-start: 8%; bottom: 20%; }
.art-v2 span:nth-child(3) { width: 14%; inset-inline-start: auto; inset-inline-end: 12%; top: 16%; }
.art-coins span:nth-child(1) { width: 52%; inset-inline-end: 10%; top: 12%;
  background: radial-gradient(circle at 30% 26%, #fff 0%, #ffe6dc 24%, #ffc3a5 60%, #ff9b7a 100%); }
.art-coins span:nth-child(2) { background: radial-gradient(circle at 30% 30%, #fff 0%, #fff1f4 40%, #ffc2d1 100%); }

/* ------------------------------------------------------------------ hero */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  border-end-start-radius: var(--radius-xl); border-end-end-radius: var(--radius-xl);
}
.hero-bg {
  position: absolute; inset: 0; z-index: -1; overflow: hidden;
  background: var(--grad-hero); border-end-start-radius: var(--radius-xl); border-end-end-radius: var(--radius-xl);
}
.hero-video, .hero-image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-video { opacity: 0; transition: opacity 1.2s ease; }
.hero-video.is-playing { opacity: 1; }
/* 3D illustration on the end side, behind the card (as in the template). The artwork bleeds off its right and
   bottom edges, so it sits flush with that corner and is mirrored on right-to-left pages. */
.hero-illustration {
  position: absolute; z-index: 1; inset-inline-end: 0; bottom: 0; width: min(46%, 640px); height: auto; max-height: 88%;
  object-fit: contain; object-position: right bottom; pointer-events: none; user-select: none;
}
.hero-home .hero-illustration { width: min(68%, 1000px); inset-inline-end: -9%; bottom: -13%; max-height: none; }
.hero-image-start .hero-inner { justify-content: flex-end; }
.hero-image-start .hero-illustration { inset-inline-start: -3%; inset-inline-end: auto; object-position: left bottom; }
[dir="rtl"] .hero-illustration { transform: scaleX(-1); }
.hero-inner { display: flex; align-items: flex-end; min-height: clamp(560px, 70vh, 780px); padding-top: 132px; padding-bottom: clamp(40px, 6vw, 72px); }
.hero-page .hero-inner { min-height: clamp(440px, 52vh, 560px); }
.hero-card {
  position: relative; z-index: 2;
  background: var(--white); border-radius: var(--radius); padding: clamp(28px, 3vw, 40px);
  max-width: 560px; box-shadow: var(--shadow-lift); display: grid; gap: 16px;
}
.hero-sub { font-size: var(--fs-lead); color: var(--n600); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; padding-top: 4px; }
.hero-404 .code-404 {
  font-family: var(--font-en); font-size: clamp(4rem, 3rem + 6vw, 8rem); font-weight: 600; line-height: 1;
  letter-spacing: -0.05em; background: var(--grad-warm); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; font-size: var(--fs-small); color: var(--n600); }
.breadcrumb li + li::before { content: "/"; margin-inline-end: 6px; color: var(--n400); }
.breadcrumb a { text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ------------------------------------------------------------------ sections */
.section { padding-block: var(--section) 0; }
main > .section:last-child { padding-bottom: var(--section); }
.section-head { display: grid; gap: 16px; max-width: 760px; margin-bottom: clamp(32px, 4vw, 56px); }
.section-head.is-center { text-align: center; margin-inline: auto; justify-items: center; }
.section-head.split { max-width: none; display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px; }
.section-cta { display: flex; justify-content: center; margin-top: clamp(32px, 4vw, 48px); }
.grid { display: grid; gap: 24px; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); border: var(--border); }

.checks { list-style: none; padding: 0; display: grid; gap: 10px; }
.checks li { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; }
.checks .icon { margin-top: 2px; color: var(--orange); }
.checks.tone-pink .icon { color: var(--pink); }

/* services */
.service-card { position: relative; overflow: hidden; display: flex; flex-direction: column; transition: transform 0.25s ease, box-shadow 0.25s ease; }
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.service-media { position: relative; aspect-ratio: 6 / 5; margin: 10px; border-radius: calc(var(--radius) - 8px); overflow: hidden; background: var(--grad-soft-orange); }
.tone-pink .service-media { background: var(--grad-soft-pink); }
.service-media img { width: 100%; height: 100%; object-fit: cover; }
.service-body { display: grid; gap: 14px; padding: 14px 24px 28px; align-content: start; }
.stretched { text-decoration: none; }
.stretched::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.stretched:focus-visible { box-shadow: none; }
.stretched:focus-visible::after { box-shadow: var(--focus); }

/* process */
.process-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
.process-intro .section-head { margin-bottom: 32px; }
.process-tabs { display: grid; gap: 10px; }
.process-tab {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%;
  padding: 14px 14px 14px 20px; padding-inline: 20px 14px; border: var(--border); border-radius: var(--radius-sm);
  background: var(--white); cursor: pointer; text-align: start; font-weight: 500; box-shadow: var(--shadow);
}
.tab-arrow { display: inline-flex; width: 36px; height: 36px; border-radius: 10px; align-items: center; justify-content: center; background: var(--n200); transition: background-color 0.2s ease, color 0.2s ease; }
.process-tab[aria-selected="true"] .tab-arrow { background: var(--ink); color: var(--white); }
.process-panels { display: grid; gap: 24px; }
.process-panel { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; padding: 12px; align-items: center; }
.process-panel[hidden] { display: none; }
.process-media { position: relative; min-height: 320px; height: 100%; border-radius: calc(var(--radius) - 8px); overflow: hidden; background: var(--grad-soft-orange); }
.tone-pink .process-media { background: var(--grad-soft-pink); }
.process-media img { width: 100%; height: 100%; object-fit: cover; }
.process-media .art { position: absolute; inset: 0; }
.process-text { display: grid; gap: 14px; padding: 20px 16px; justify-items: start; }
.process-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; }
/* square gradient icons (workflow steps, packages) */
.square-icon {
  display: inline-flex; flex: none; width: 48px; height: 48px; border-radius: 12px; overflow: hidden;
  box-shadow: 0 1px 1px rgba(68, 0, 0, 0.06), 0 4px 4px rgba(255, 134, 148, 0.06);
}
.square-icon img { width: 100%; height: 100%; object-fit: cover; }

/* call to action */
.cta-split {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center; gap: 32px;
  background: var(--grad-hero); color: var(--white); border-radius: var(--radius-xl); padding: clamp(32px, 5vw, 72px); overflow: hidden;
}
.cta-text { display: grid; gap: 18px; justify-items: start; }
.cta-split .lead { color: rgba(255, 255, 255, 0.9); }
.cta-art { position: relative; min-height: 280px; }
.cta-art .art { position: absolute; inset: 0; }
/* main image on the bottom edge of the card, with up to four floating decorations around it */
.cta-split.has-image { padding-bottom: 0; }
.cta-split.has-image .cta-text { padding-bottom: clamp(32px, 5vw, 72px); }
.cta-split.has-image .cta-art { align-self: end; min-height: 0; margin-bottom: -5%; padding-top: 4%; }
.cta-art .cta-main { position: relative; z-index: 1; display: block; width: 88%; height: auto; margin-inline: auto; }
.cta-art .cta-decor { position: absolute; z-index: 2; height: auto; pointer-events: none; animation: areb-float 7s ease-in-out infinite; }
.cta-art .cta-decor-1 { width: 15%; max-width: 96px; bottom: 24%; inset-inline-start: 0; }
.cta-art .cta-decor-2 { width: 19%; max-width: 126px; top: 0; inset-inline-start: 16%; animation-delay: -1.75s; }
.cta-art .cta-decor-3 { width: 18%; max-width: 124px; bottom: 15%; inset-inline-end: 0; animation-delay: -3.5s; }
.cta-art .cta-decor-4 { width: 14%; max-width: 96px; bottom: 56%; inset-inline-end: 22%; animation-delay: -5.25s; }
@keyframes areb-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* testimonials */
.testimonial-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }
.testimonial { padding: 32px; display: grid; gap: 20px; }
.testimonial blockquote p { font-size: 1.25rem; font-weight: 500; line-height: 1.45; }
.quote-mark { color: var(--pink); }
.testimonial figcaption { display: flex; align-items: center; gap: 12px; }
.avatar { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; }
.who { display: grid; }
.who span { color: var(--n600); font-size: var(--fs-small); }

/* contact */
.contact-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
.contact-intro { display: grid; gap: 20px; }
.contact-page { padding-top: 140px; }
.contact-cards { display: grid; gap: 12px; margin-top: 12px; }
.contact-card {
  display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 16px; align-items: center;
  padding: 18px 20px; text-decoration: none; transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.contact-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.contact-card .icon { grid-row: span 2; width: 44px; height: 44px; padding: 11px; border-radius: 50%; background: var(--pink-soft); color: var(--pink); }
.contact-label { color: var(--n600); font-size: var(--fs-small); }
.contact-value { font-weight: 600; overflow-wrap: anywhere; text-align: start; unicode-bidi: plaintext; }
.form-card { padding: clamp(24px, 3vw, 36px); }

/* forms */
.form { display: grid; gap: 18px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.field { display: grid; gap: 8px; border: 0; margin: 0; padding: 0; min-width: 0; }
.field label, .field legend { font-weight: 500; font-size: 0.95rem; padding: 0; }
.field input, .field textarea {
  width: 100%; min-height: 52px; padding: 14px 18px; border-radius: var(--radius-sm);
  background: var(--n200); border: 1px solid var(--n300); transition: border-color 0.2s ease, background-color 0.2s ease;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:hover, .field textarea:hover { border-color: var(--n400); }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--pink); background: var(--white); box-shadow: var(--focus); }
.field input[dir="ltr"] { text-align: left; }
[dir="rtl"] .field input[dir="ltr"]::placeholder { text-align: right; }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: var(--red); background: #fff7f7; }
.field-error { color: var(--red); font-size: var(--fs-small); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 4px; }
.chip { position: relative; cursor: pointer; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span {
  display: inline-flex; align-items: center; min-height: 40px; padding: 8px 16px; border-radius: var(--pill);
  background: var(--n200); border: 1px solid var(--n300); font-size: 0.925rem; font-weight: 500;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.chip:hover span { border-color: var(--n500); }
.chip input:checked + span { background: var(--ink); color: var(--white); border-color: var(--ink); }
.chip input:focus-visible + span { box-shadow: var(--focus); }
.form-msg { border-radius: var(--radius-sm); padding: 16px 18px; }
.form-success { background: #effaf2; color: #135c2d; display: grid; gap: 6px; }
.form-error { background: #fff1f2; color: #a3122b; }
.form.is-sent > :not(.form-success):not(input[type="hidden"]) { display: none; }
.cf-turnstile { min-height: 65px; }

.newsletter-row { display: flex; gap: 8px; align-items: center; background: var(--white); border-radius: var(--pill); padding: 6px; padding-inline-start: 20px; border: 1px solid var(--n300); }
.newsletter-row input { flex: 1; min-width: 0; border: 0; background: transparent; min-height: 44px; outline: none; }
.newsletter-row input::placeholder { color: var(--n500); }
[dir="rtl"] .newsletter-row input::placeholder { text-align: right; }
.newsletter-row:focus-within { box-shadow: var(--focus); }
.newsletter-form { display: grid; gap: 10px; }
.newsletter-form.is-hero { margin-top: 8px; }
.newsletter-form.is-hero .newsletter-row { background: var(--n200); }

/* faq */
.faq-list { display: grid; gap: 12px; }
.faq-item { background: var(--white); border-radius: var(--radius-sm); border: var(--border); box-shadow: var(--shadow); }
.faq-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 24px;
  cursor: pointer; list-style: none; font-weight: 500; font-size: 1.075rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-toggle { display: inline-flex; flex: none; width: 36px; height: 36px; border-radius: 10px; align-items: center; justify-content: center; background: var(--n200); transition: transform 0.25s ease, background-color 0.2s ease, color 0.2s ease; }
.faq-item[open] .faq-toggle { transform: rotate(45deg); background: var(--ink); color: var(--white); }
.faq-a { padding: 0 24px 22px; color: var(--n600); }

/* media + text, statement */
.media-text { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 80px); align-items: center; }
.media-text-art { position: relative; min-height: 360px; border-radius: var(--radius-lg); overflow: hidden; background: var(--grad-soft-pink); }
.media-text-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.media-text-art .art { position: absolute; inset: 0; }
.media-text-body { display: grid; gap: 20px; justify-items: start; }
.statement-text { font-size: var(--fs-h3); font-weight: 500; line-height: 1.35; text-align: center; text-wrap: balance; }
.statement .container { background: var(--white); border-radius: var(--radius-xl); padding-block: clamp(40px, 6vw, 88px); box-shadow: var(--shadow); }

/* team, values, benefits */
.member { position: relative; padding: 28px 24px; display: grid; justify-items: center; text-align: center; gap: 8px; }
.member-photo { width: 96px; height: 96px; border-radius: 50%; overflow: hidden; background: var(--grad-warm); display: grid; place-items: center; margin-bottom: 8px; }
.member-photo img { width: 100%; height: 100%; object-fit: cover; }
.initials { color: var(--white); font-family: var(--font-en); font-weight: 600; font-size: 1.6rem; }
.member-link { position: absolute; top: 16px; inset-inline-end: 16px; color: var(--n600); }
.member-link:hover { color: var(--ink); }
.member-join { padding: 28px 24px; display: grid; gap: 18px; align-content: center; justify-items: start; background: var(--grad-soft-orange); }
.member-join.has-image { align-content: start; padding-bottom: 0; overflow: hidden; }
.member-join-art { justify-self: end; width: 64%; max-width: 200px; height: auto; margin-top: auto; }
.items-grid { row-gap: clamp(32px, 4vw, 48px); }
.item { display: grid; gap: 10px; justify-items: start; align-content: start; }
.item-icon { display: inline-flex; width: 56px; height: 56px; border-radius: 18px; align-items: center; justify-content: center; background: var(--pink-soft); color: var(--pink); margin-bottom: 4px; }
.item-icon img { width: 40px; height: 40px; object-fit: contain; }
.item-icon.has-image { width: 80px; height: 80px; border-radius: 0; background: none; }
.item-icon.has-image img { width: 100%; height: 100%; }
.values .section-head, .benefits .section-head { max-width: 820px; }

/* social */
.social-inner { display: grid; justify-items: center; gap: 28px; text-align: center; }
.social-tiles, .social-icons { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; list-style: none; padding: 0; }
.social-tiles a {
  display: inline-flex; width: 76px; height: 76px; border-radius: 22px; align-items: center; justify-content: center;
  background: var(--white); box-shadow: var(--shadow-lift); color: var(--pink); transition: transform 0.2s ease;
}
.social-tiles a:hover { transform: translateY(-4px) rotate(-3deg); }
.social-tiles .icon { width: 30px; height: 30px; }
/* tiles with images over a soft glow, as in the template */
.social-stage { position: relative; display: grid; place-items: center; width: 100%; max-width: 648px; margin-inline: auto; }
.social-stage.has-bg { min-height: clamp(200px, 46vw, 420px); }
.social-bg { position: absolute; inset: 0; margin: auto; width: 78%; max-width: 500px; height: auto; pointer-events: none; }
.social-stage .social-tiles { position: relative; z-index: 1; }
.social-tiles a.has-tile {
  width: 148px; height: 148px; padding: 10px; border-radius: 28px; border: 1px solid var(--n300);
  background: rgba(255, 255, 255, 0.8); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  box-shadow: 0 1.5px 8px rgba(255, 141, 156, 0.2), 0 1.5px 5px rgba(255, 141, 156, 0.2);
}
.social-tiles a.has-tile:hover { transform: translateY(-6px); }
.social-tiles a.has-tile img { width: 100%; height: 100%; border-radius: 20px; object-fit: cover; }

/* packages */
.packages-first { padding-top: 150px; }
.package { padding: 32px 28px; display: flex; flex-direction: column; gap: 16px; position: relative; }
.package .badge { align-self: flex-start; margin-bottom: -4px; }
.package-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.package-top .badge { margin: 0; }
.package.is-featured { border: 2px solid var(--pink); box-shadow: var(--shadow-lift); }
.package-cta { margin-top: auto; padding-top: 12px; }

/* quote + stats */
.quote-stats { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 3fr) minmax(0, 3fr); gap: 24px; }
.quote-card { padding: 36px; display: grid; gap: 18px; }
.quote-card blockquote p { font-size: var(--fs-h4); font-weight: 500; line-height: 1.4; }
.quote-card figcaption { display: flex; align-items: center; gap: 12px; }
.quote-card .who > span { color: var(--n600); }
.stats { display: grid; gap: 24px; }
.stat { padding: 28px; display: flex; flex-direction: column-reverse; gap: 6px; }
.stat dd { font-family: var(--font-en); font-size: var(--fs-h2); font-weight: 600; letter-spacing: -0.04em; line-height: 1; background: var(--grad-warm); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat dt { color: var(--n600); }
.cta-mini { padding: 32px; display: grid; gap: 18px; align-content: center; justify-items: start; background: var(--grad-soft-pink); }
.cta-mini-art { width: 88px; height: auto; }

/* service detail */
.service-detail { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
.service-main { display: grid; gap: 20px; }
.service-main .checks { gap: 14px; margin-bottom: 16px; font-size: 1.075rem; }
.service-aside-media { position: relative; overflow: hidden; aspect-ratio: 4 / 3; padding: 0; background: var(--grad-soft-orange); }
.service-aside-media img { width: 100%; height: 100%; object-fit: cover; }

/* blog */
.empty-state { padding: 40px; border-radius: var(--radius); background: var(--white); text-align: center; color: var(--n600); border: 1px dashed var(--n400); }
.post-card { position: relative; display: flex; flex-direction: column; overflow: hidden; transition: transform 0.25s ease, box-shadow 0.25s ease; }
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }
.post-media { position: relative; aspect-ratio: 16 / 10; margin: 10px; border-radius: calc(var(--radius) - 8px); overflow: hidden; background: var(--grad-soft-pink); }
.post-media img { width: 100%; height: 100%; object-fit: cover; }
.post-body { display: grid; gap: 10px; padding: 12px 22px 26px; }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; font-size: var(--fs-small); color: var(--n600); }
.post-meta .badge { text-decoration: none; position: relative; z-index: 1; }
.featured-post { margin-bottom: 24px; }
.post-card.is-big { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center; }
.post-card.is-big .post-media { aspect-ratio: 16 / 9; }
.post-card.is-big .post-body { padding: 24px 32px; }
.cat-chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin-top: 12px; }
.chip-link { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 6px 16px; border-radius: var(--pill); background: var(--white); border: 1px solid var(--n300); text-decoration: none; font-weight: 500; }
.chip-link span { font-size: 0.8rem; color: var(--n500); }
.chip-link:hover { border-color: var(--ink); }
.chip-link.is-active { background: var(--ink); color: var(--white); border-color: var(--ink); }
.chip-link.is-active span { color: rgba(255, 255, 255, 0.7); }
.blog-cats { padding-top: 48px; }
.blog-search { display: flex; gap: 8px; align-items: center; background: var(--white); border: 1px solid var(--n300); border-radius: var(--pill); padding: 5px; padding-inline-start: 18px; min-width: min(360px, 100%); }
.blog-search input { flex: 1; min-width: 0; border: 0; background: transparent; min-height: 40px; outline: none; }
.blog-search:focus-within { box-shadow: var(--focus); }
.search-note { margin: -24px 0 24px; }
.pagination { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 40px; }
.post-hero { padding-top: 140px; }
.post-hero .container { display: grid; gap: 18px; }
.post-author { display: flex; align-items: center; gap: 12px; }
.member-photo.small { width: 48px; height: 48px; margin: 0; }
.member-photo.small .initials { font-size: 1rem; }
.post-cover { margin-top: 32px; }
.post-cover img { width: 100%; max-height: 620px; object-fit: cover; border-radius: var(--radius-lg); }
.post-text { padding: 40px 0 0; font-size: 1.075rem; }
.tag-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin-top: 32px; }
.tag-list a { display: inline-block; padding: 4px 12px; border-radius: var(--pill); background: var(--white); border: 1px solid var(--n300); text-decoration: none; font-size: var(--fs-small); }
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--n300); }
.share-label { font-weight: 600; margin-inline-end: 6px; }
.share a, .share-copy { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 12px; border-radius: var(--pill); background: var(--white); border: 1px solid var(--n300); text-decoration: none; font-size: 0.85rem; font-weight: 600; cursor: pointer; }
.share a:hover, .share-copy:hover { border-color: var(--ink); }
.video-embed { margin: 1.5em 0; }
.video-embed a { position: relative; display: block; border-radius: var(--radius-sm); overflow: hidden; }
.video-embed img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.video-embed .play { position: absolute; inset: 0; margin: auto; width: 72px; height: 72px; border-radius: 50%; background: rgba(3, 3, 3, 0.75); }
.video-embed .play::after { content: ""; position: absolute; inset: 0; margin: auto; width: 0; height: 0; border-style: solid; border-width: 12px 0 12px 20px; border-color: transparent transparent transparent #fff; transform: translateX(3px); }
.newsletter-cta { padding: clamp(28px, 4vw, 48px); display: grid; gap: 18px; text-align: center; justify-items: center; background: var(--grad-soft-orange); }
.newsletter-cta .newsletter-form { width: min(520px, 100%); }

/* prose (legal pages, articles, service bodies) */
.prose { padding: clamp(24px, 4vw, 56px); line-height: 1.75; color: var(--n700); }
.prose > * + * { margin-top: 1em; }
.prose h2 { font-size: var(--fs-h4); margin-top: 1.8em; color: var(--ink); }
.prose h3 { font-size: var(--fs-h5); margin-top: 1.5em; color: var(--ink); }
.prose h4, .prose h5, .prose h6 { font-size: 1.05rem; margin-top: 1.3em; }
.prose ul, .prose ol { padding-inline-start: 1.4em; }
.prose li + li { margin-top: 0.4em; }
.prose a { color: var(--red); text-underline-offset: 3px; overflow-wrap: anywhere; }
.prose blockquote { border-inline-start: 4px solid var(--pink); padding-inline-start: 18px; color: var(--ink); font-size: 1.15rem; }
.prose img { border-radius: var(--radius-sm); }
.prose figcaption { font-size: var(--fs-small); color: var(--n600); margin-top: 8px; }
.prose table { width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.prose th, .prose td { border: 1px solid var(--n300); padding: 10px 12px; text-align: start; }

/* ------------------------------------------------------------------ footer */
.site-footer {
  margin-top: var(--section); background: var(--ink); color: var(--white);
  border-start-start-radius: var(--radius-xl); border-start-end-radius: var(--radius-xl); padding-block: clamp(48px, 6vw, 88px) 32px;
}
.footer-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; padding-bottom: 40px; border-bottom: 1px solid rgba(255, 255, 255, 0.12); }
.footer-brand { display: grid; gap: 22px; justify-items: start; }
.footer-contact { font-style: normal; display: grid; gap: 6px; color: rgba(255, 255, 255, 0.72); }
.footer-contact a { color: var(--white); text-decoration: none; }
.footer-contact a:hover { text-decoration: underline; }
.footer-newsletter { display: grid; gap: 20px; align-content: start; }
.footer-newsletter .h4 { font-weight: 500; }
.site-footer .newsletter-row { border-color: transparent; }
.site-footer .form-success { background: rgba(255, 255, 255, 0.1); color: var(--white); }
.site-footer .form-error { background: rgba(231, 48, 56, 0.18); color: #ffd7db; }
.site-footer .social-icons { justify-content: flex-start; }
.social-icons a { display: inline-flex; width: 40px; height: 40px; border-radius: 50%; align-items: center; justify-content: center; color: var(--white); background: rgba(255, 255, 255, 0.08); }
.social-icons a:hover { background: rgba(255, 255, 255, 0.18); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; padding-top: 24px; color: rgba(255, 255, 255, 0.6); font-size: var(--fs-small); }
.legal-links { display: flex; flex-wrap: wrap; gap: 16px; list-style: none; padding: 0; }
.legal-links a { color: rgba(255, 255, 255, 0.85); text-decoration: none; }
.legal-links a:hover { color: var(--white); text-decoration: underline; }

.notice { background: var(--blush); padding: 10px 0; font-size: var(--fs-small); }
.error-page { padding-block: 120px; display: grid; gap: 16px; }
.is-preview::before {
  content: "Preview"; position: fixed; z-index: 99; inset-inline-end: 16px; bottom: 16px; padding: 8px 14px;
  background: var(--ink); color: var(--white); border-radius: var(--pill); font-size: var(--fs-small);
}

/* ------------------------------------------------------------------ responsive */
@media (max-width: 991px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .process-grid, .contact-grid, .media-text, .service-detail, .cta-split, .footer-top { grid-template-columns: minmax(0, 1fr); }
  .quote-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .quote-card { grid-column: 1 / -1; }
  .cta-art { min-height: 220px; }
  .nav-toggle { display: inline-flex; }
  .main-nav {
    position: absolute; top: calc(100% + 10px); inset-inline: var(--gutter); display: none; flex-direction: column; align-items: stretch;
    border-radius: var(--radius); padding: 12px; box-shadow: var(--shadow-lift);
  }
  .nav-open .main-nav { display: flex; }
  .nav-list { flex-direction: column; align-items: stretch; padding: 0; }
  .nav-list a { padding: 14px 16px; border-radius: var(--radius-xs); }
  .nav-actions { flex-direction: column; align-items: stretch; padding-top: 8px; border-top: 1px solid var(--n300); margin-top: 6px; }
  .nav-actions .btn { width: 100%; }
  .site-header { padding-top: 14px; }
  .header-inner { position: relative; }
  /* the illustration moves under the card and rests on the bottom edge of the hero, as in the template */
  .hero.has-illustration .hero-inner { flex-direction: column; align-items: stretch; justify-content: flex-end; min-height: 0; }
  .hero .hero-illustration {
    position: relative; inset: auto; z-index: 1; width: min(84%, 560px); height: auto; max-height: none;
    margin-block: -12px calc(-1 * clamp(40px, 6vw, 72px) - 6%); margin-inline: auto calc(-1 * var(--gutter));
  }
  .hero.hero-image-start .hero-illustration { margin-inline: calc(-1 * var(--gutter) - 4%) auto; }
  .social-tiles a.has-tile { width: 120px; height: 120px; }
}
@media (max-width: 767px) {
  .grid-3, .grid-4, .form-grid, .quote-stats { grid-template-columns: minmax(0, 1fr); }
  .post-card.is-big { grid-template-columns: minmax(0, 1fr); }
  .post-hero { padding-top: 112px; }
  .process-panel { grid-template-columns: minmax(0, 1fr); }
  .process-media { min-height: 220px; }
  .hero-inner { min-height: 520px; padding-top: 108px; }
  .hero-page .hero-inner { min-height: 420px; }
  .hero-card { max-width: none; }
  .art-hero span:nth-child(1) { width: 72vw; top: 6%; }
  .art-hero span:nth-child(2) { width: 34vw; top: 40%; inset-inline-end: 56%; }
  .media-text-art { min-height: 260px; }
  .faq-item summary { padding: 18px; }
  .faq-a { padding: 0 18px 18px; }
  .packages-first, .contact-page { padding-top: 120px; }
  .social-tiles a.has-tile { width: 96px; height: 96px; padding: 6px; border-radius: 20px; }
  .social-tiles a.has-tile img { border-radius: 14px; }
}
@media (max-width: 479px) {
  .btn { padding: 0 22px; }
  .hero-actions .btn { width: 100%; }
  .footer-bottom { flex-direction: column; }
  .social-tiles a { width: 64px; height: 64px; }
  .social-tiles { gap: 10px; }
  .social-tiles a.has-tile { width: 76px; height: 76px; padding: 5px; border-radius: 18px; }
  .social-tiles a.has-tile img { border-radius: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  .hero-video { display: none; }
}
@media (max-width: 767px) and (prefers-reduced-data: reduce) { .hero-video { display: none; } }

@media print {
  .site-header, .site-footer, .hero-bg, .hero-illustration, .nav-toggle { display: none; }
  .hero-inner { min-height: 0; padding: 0; }
  .card { box-shadow: none; border: 1px solid var(--n300); }
}
