/*
 * TCHAHIT v130 «Maison» — the shared editorial layer of the public and customer pages:
 * header, footer, phone tab bar, and the page bodies of search/cart, tracking, account,
 * errand, /partners and /partner-apply. Loaded with the public chrome only
 * (site-header, public-footer, customer-chrome) and bundled into the home route CSS.
 * Ivory paper, espresso ink, burnt-brown night, fine gold rules; orange is the accent.
 * No tracking on Arabic; Latin display headings in a book serif (system fonts, no download).
 */
/* Tokens: --lx-* in app/design-tokens.css (global). */

/* ---------- The kit: reusable on any surface (components/luxe.tsx renders them) ----------
 * .lx-eyebrow   small quiet label after a gold rule (data-n="01" adds the section number)
 * .lx-display   big editorial heading (Arabic 700; FR/EN in the book serif)
 * .lx-lead      calm paragraph, 17px / 1.75, never wider than 40em
 * .lx-rule      one gold hairline
 * .lx-arch      arched photo frame with a gold inner rule (put an <img> or <picture> inside)
 * .lx-paper     paper panel with a gold hairline, no shadow
 * .lx-night     burnt-brown night panel, ivory text, gold hairline
 * .lx-ruled     list or grid of items split by hairlines instead of boxes
 * .lx-btn       pill action (orange action colour); .lx-btn-quiet = outline pill
 * .lx-num       serif gold numeral (steps, sequences only)
 */
.lx-eyebrow { display: inline-flex; align-items: center; gap: 14px; margin: 0 0 18px; color: var(--lx-ink-3); font-size: 13px; font-weight: 600; line-height: 1.4; }
.lx-eyebrow::before { content: ""; flex: none; width: 38px; height: 1px; background: var(--lx-gold); }
.lx-eyebrow[data-n]::before { content: attr(data-n) / ""; width: auto; height: auto; padding-inline-end: 52px; background: linear-gradient(var(--lx-gold-line), var(--lx-gold-line)) no-repeat right center / 38px 1px; color: var(--lx-gold); font-family: var(--lx-serif); font-size: 15px; font-weight: 400; direction: ltr; unicode-bidi: isolate; }
html[dir="rtl"] .lx-eyebrow[data-n]::before { padding-inline: 52px 0; background-position: left center; }
html:not([dir="rtl"]) .lx-eyebrow { letter-spacing: .14em; }
.lx-display { margin: 0 0 .32em; color: var(--lx-ink); font-size: clamp(34px, 5.6vw, 68px); font-weight: 700; line-height: 1.12; letter-spacing: 0; }
html:not([dir="rtl"]) .lx-display { font-family: var(--lx-serif); font-weight: 400; line-height: 1.04; letter-spacing: -.015em; }
.lx-lead { max-width: 40em; margin: 0; color: var(--lx-ink-2); font-size: 17px; line-height: 1.75; }
.lx-rule { display: block; width: 72px; height: 1px; margin: 22px 0; border: 0; background: var(--lx-gold); }
.lx-arch { position: relative; overflow: hidden; margin: 0; border-radius: 999px 999px 24px 24px; background: var(--lx-espresso); }
.lx-arch::after { content: ""; position: absolute; inset: 12px; border: 1px solid rgba(211, 180, 126, .7); border-radius: 999px 999px 16px 16px; pointer-events: none; }
.lx-arch > :is(img, picture, picture > img) { display: block; width: 100%; height: 100%; object-fit: cover; }
.lx-paper { border: 1px solid var(--lx-gold-line); border-radius: 24px; background: var(--lx-paper); color: var(--lx-ink); }
.lx-night { border: 1px solid var(--lx-gold-night); border-radius: 24px; background: var(--lx-brown); color: var(--lx-ivory); }
.lx-night :is(.lx-display, h1, h2, h3) { color: var(--lx-ivory); }
.lx-night :is(.lx-lead, p) { color: rgba(248, 242, 232, .78); }
.lx-night .lx-eyebrow { color: rgba(248, 242, 232, .7); }
.lx-ruled { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--lx-ink); }
.lx-ruled > * { padding-block: 20px; border-bottom: 1px solid var(--lx-line); }
.lx-night .lx-ruled { border-top-color: var(--lx-gold-night); }
.lx-night .lx-ruled > * { border-bottom-color: rgba(211, 180, 126, .2); }
.lx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px; border: 0; border-radius: 999px; background: var(--lx-action); color: #fff; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; transition: background-color .2s var(--lx-ease); }
.lx-btn:hover { background: var(--tc-action-hover, #9a3412); }
.lx-btn-quiet { background: transparent; color: var(--lx-ink); box-shadow: inset 0 0 0 1px var(--lx-ink); }
.lx-btn-quiet:hover { background: var(--lx-paper); }
.lx-night .lx-btn-quiet { color: var(--lx-ivory); box-shadow: inset 0 0 0 1px var(--lx-gold-2); }
.lx-btn:focus-visible { outline: 3px solid var(--lx-gold-2); outline-offset: 2px; }
.lx-num { color: var(--lx-gold); font-family: var(--lx-serif); font-size: 44px; font-weight: 400; line-height: 1; direction: ltr; unicode-bidi: isolate; }
.lx-night .lx-num { color: var(--lx-gold-2); }

/* ---------- Header ---------- */
html body .tc-header.tc-header:not(.tc-header-dark) {
  border-bottom: 1px solid var(--lx-gold-line) !important;
  background: rgba(248, 242, 232, .97) !important;
  box-shadow: none !important;
}
html body .tc-header .tc-brand b { letter-spacing: .12em; color: var(--lx-ink); }
html body .tc-header-dark .tc-brand b { color: var(--lx-ivory); }
html body .tc-header-dark.tc-header { border-bottom: 1px solid rgba(211, 180, 126, .3) !important; background: var(--lx-espresso) !important; }

/* ---------- Footer: espresso, gold rule, small spaced headings ---------- */
html body .tc-footer, html body .shell > footer.tc-footer {
  position: relative;
  border: 0 !important;
  border-top: 1px solid rgba(211, 180, 126, .45) !important;
  background: var(--lx-espresso) !important;
  color: rgba(248, 242, 232, .72) !important;
  padding-top: clamp(56px, 7vw, 96px) !important;
}
html body .tc-footer::before {
  content: "";
  position: absolute;
  top: 6px;
  inset-inline: 0;
  height: 1px;
  background: rgba(211, 180, 126, .18);
}
html body .tc-footer .tc-footer-logo b { color: var(--lx-ivory) !important; letter-spacing: .12em; }
html body .tc-footer .tc-footer-badge { border: 1px solid rgba(211, 180, 126, .5) !important; background: transparent !important; color: var(--lx-gold-2) !important; }
html body .tc-footer :is(.tc-footer-heading, .tc-footer-toggle, h2, h3) { color: var(--lx-gold-2) !important; font-weight: 600 !important; }
html:not([dir="rtl"]) body .tc-footer :is(.tc-footer-heading, h2, h3) { letter-spacing: .14em; font-size: 13px !important; }
html body .tc-footer a { color: rgba(248, 242, 232, .74) !important; }
html body .tc-footer a:hover { color: var(--lx-ivory) !important; text-decoration-color: var(--lx-gold) !important; }
html body .tc-footer .tc-footer-quick a { color: var(--lx-ivory) !important; }
html body .tc-footer :is(.tc-footer-legal, .tc-footer-quick, .tc-footer-col) { border-color: rgba(211, 180, 126, .2) !important; }

/* ---------- Phone tab bar: espresso, ivory marks, one orange dot ---------- */
@media (max-width: 900px) {
  html:not([data-app]) body .tc-webtabs, html body .shell nav.mobile-nav {
    border-top: 1px solid rgba(211, 180, 126, .35) !important;
    background: var(--lx-espresso) !important;
    box-shadow: 0 -12px 30px -18px rgba(27, 19, 14, .6) !important;
  }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button)) { color: rgba(248, 242, 232, .66) !important; background: transparent !important; }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button)):hover { color: var(--lx-ivory) !important; }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button))[aria-current="page"] { color: var(--lx-ivory) !important; }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button))[aria-current="page"]::before { top: auto !important; bottom: 3px !important; inset-inline: calc(50% - 3px) !important; width: 6px !important; height: 6px !important; border-radius: 50% !important; background: var(--lx-orange) !important; }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button)) .tc-icon { --tc-icon-duo: var(--lx-gold-2); --tc-icon-duo-opacity: .35; }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button)) > i { border-color: var(--lx-espresso) !important; background: var(--lx-orange) !important; color: #fff !important; }
  html body :is(.tc-webtabs > a, .shell nav.mobile-nav > :is(a, button)):focus-visible { outline-color: var(--lx-gold-2) !important; }
}

/* ---------- Shared page bodies ---------- */
html body :is(.partners-page, .tracking-page:not(.storefront), .partner-application, .customer-account-wrap) { background: var(--lx-ivory) !important; color: var(--lx-ink); }
html body :is(.partners-page h1, .tracking-page:not(.storefront) h1, .application-hero h1, .partners-page h2) { color: var(--lx-ink); font-weight: 700; letter-spacing: 0; }
html:not([dir="rtl"]) body :is(.partners-page h1, .tracking-page:not(.storefront) h1, .partners-page h2, .application-hero h1) { font-family: var(--lx-serif); font-weight: 400; letter-spacing: -.015em; }
html body .partners-page h2 svg, html body .tracking-page:not(.storefront) .tracking-kicker svg { color: var(--lx-gold); }

/* Kicker: «— label» with a gold rule */
html body :is(.partners-eyebrow, .tracking-page:not(.storefront) .tracking-kicker) {
  gap: 14px !important;
  padding: 0 !important;
  border-radius: 0 !important;
  background: none !important;
  color: var(--lx-ink-3) !important;
  font-weight: 600 !important;
}
html body :is(.partners-eyebrow, .tracking-page:not(.storefront) .tracking-kicker)::before { content: ""; flex: none; width: 38px; height: 1px; background: var(--lx-gold); }
html:not([dir="rtl"]) body :is(.partners-eyebrow, .tracking-page:not(.storefront) .tracking-kicker) { letter-spacing: .14em; font-size: 13px !important; }
html body :is(.partners-eyebrow, .tracking-page:not(.storefront) .tracking-kicker) svg { display: none; }

/* ---------- /partners ---------- */
html body .partners-hero { padding-block: clamp(48px, 8vw, 120px) clamp(40px, 6vw, 88px); gap: clamp(28px, 6vw, 96px); }
html body .partners-hero h1 { font-size: clamp(40px, 6.6vw, 84px); line-height: 1.08; margin-block: 22px 20px; }
html body .partners-hero h1 em { color: var(--lx-orange); }
html:not([dir="rtl"]) body .partners-hero h1 em { font-style: italic; }
html body .partners-hero p { color: var(--lx-ink-2); }
html body .partners-hero-art { border-radius: 999px 999px 24px 24px; aspect-ratio: 4 / 4.4; box-shadow: none; position: relative; background: var(--lx-espresso); }
html body .partners-hero-art::after { content: ""; position: absolute; inset: 12px; border: 1px solid rgba(211, 180, 126, .7); border-radius: 999px 999px 12px 12px; pointer-events: none; }
html body .partners-cta { border-radius: 999px; background: var(--lx-action); box-shadow: none; }
html body .partners-cta:hover { background: #9a3412; }
html body .partners-ghost { border-radius: 999px; border-color: var(--lx-ink); background: transparent; }
html body .partners-proof { padding-top: 18px; border-top: 1px solid var(--lx-line); color: var(--lx-ink-2); font-weight: 600; }
html body .partners-proof svg { color: var(--lx-gold); }
html body .partners-page > section + section { margin-top: clamp(40px, 6vw, 88px); }
html body .partners-free-grid { gap: 0; border-block: 1px solid var(--lx-gold-line); }
html body .partners-free article { border: 0; border-radius: 0; background: transparent; padding: 28px 24px; }
html body .partners-free article + article { border-inline-start: 1px solid var(--lx-line); }
html body .partners-free article > svg { color: var(--lx-gold); }
html body .partners-free article strong { font-size: clamp(28px, 4vw, 44px); }
html:not([dir="rtl"]) body .partners-free article strong { font-family: var(--lx-serif); font-weight: 400; }
html body .partners-benefit-grid { gap: 0; border-top: 1px solid var(--lx-ink); }
html body .partners-benefit-grid article { border: 0; border-bottom: 1px solid var(--lx-line); border-radius: 0; background: transparent; padding: 24px 20px 24px 0; }
html[dir="rtl"] body .partners-benefit-grid article { padding: 24px 0 24px 20px; }
html body .partners-benefit-grid article > span { inline-size: auto; block-size: auto; place-items: start; background: none; color: var(--lx-gold); }
html body .partners-references a { border: 1px solid var(--lx-line); background: transparent; }
html body .partners-references a:hover { border-color: var(--lx-gold); background: var(--lx-paper); }
html body .partners-gallery { gap: clamp(12px, 2vw, 24px); }
html body .partners-gallery figure:nth-child(2) img { aspect-ratio: 3 / 2.6; border-radius: 999px 999px 12px 12px; }
html body .partners-gallery img { border-radius: 12px; }
html body .partners-start { border-radius: 24px; background: var(--lx-brown); border: 1px solid rgba(211, 180, 126, .3); padding: clamp(24px, 5vw, 64px); }
html body .partners-start-intro h2 { color: var(--lx-ivory); font-size: clamp(30px, 4vw, 52px); }
html body .partners-form { border-radius: 24px; background: var(--lx-paper); }
html body .partners-type button { border-radius: 999px; background: transparent; }
html body .partners-type button.selected { border-color: var(--lx-action); background: #fff5f0; color: var(--lx-action); box-shadow: inset 0 0 0 1px var(--lx-action); }
html body .partners-faq details { border-radius: 0 !important; border: 0 !important; border-bottom: 1px solid var(--lx-line) !important; background: transparent !important; box-shadow: none !important; }
html body .partners-faq { border-top: 1px solid var(--lx-ink); padding-top: 8px; }
html body :is(.partners-calculator > *, .partners-support) { box-shadow: none !important; }
html body .partners-support { border-color: var(--lx-gold-line) !important; background: var(--lx-paper) !important; }

/* ---------- /partner-apply ---------- */
html body .application-hero {
  background: var(--lx-brown) !important;
  border-bottom: 1px solid rgba(211, 180, 126, .35);
}
html body .application-hero h1 { color: var(--lx-ivory) !important; font-size: clamp(36px, 5.6vw, 72px) !important; line-height: 1.08 !important; }
html body .application-hero h1 em { color: var(--lx-orange) !important; }
html:not([dir="rtl"]) body .application-hero h1 em { font-style: italic !important; }
html body .application-hero p { color: rgba(248, 242, 232, .78) !important; }
html body .application-hero > div:first-child > span { color: var(--lx-gold-2) !important; background: none !important; border: 0 !important; padding: 0 !important; }
html body :is(.application-workspace, .application-step, .partner-application-form) { box-shadow: none !important; }
html body :is(.application-workspace, .partner-application-form) { border-color: var(--lx-gold-line) !important; background: var(--lx-paper) !important; }
html body .partner-type-choice :is(button, label) { border-radius: 16px !important; }
html body :is(.application-next, .application-status-submit) { border-radius: 999px !important; background: var(--lx-action) !important; box-shadow: none !important; }

/* ---------- Tracking and errand ---------- */
html body .tracking-page:not(.storefront) .tracking-card,
html body .errand-card {
  border: 1px solid var(--lx-gold-line) !important;
  border-radius: 24px !important;
  background: var(--lx-paper) !important;
  box-shadow: 0 40px 80px -60px rgba(44, 27, 18, .45) !important;
}
html body .tracking-page:not(.storefront) h1, html body .tracking-page:not(.storefront) h2 { font-size: clamp(28px, 3.6vw, 44px) !important; line-height: 1.18 !important; }
html body .tracking-page:not(.storefront) :is(.tracking-lookup-form button, .tracking-support-trigger, .tracking-refresh) { border-radius: 999px !important; box-shadow: none !important; }
html body .tracking-page:not(.storefront) .tracking-lookup-form input { border-color: var(--lx-line) !important; background: var(--lx-ivory) !important; }
html body .tracking-lookup-links a { border: 1px solid var(--lx-line) !important; background: transparent !important; }
html body .errand-hero h1 { font-size: clamp(38px, 6vw, 76px) !important; font-weight: 700 !important; line-height: 1.08 !important; color: var(--lx-ink); }
html:not([dir="rtl"]) body .errand-hero h1 { font-family: var(--lx-serif); font-weight: 400 !important; letter-spacing: -.015em; }
html body .errand-hero p { max-width: 46em; color: var(--lx-ink-2) !important; font-size: 17px !important; line-height: 1.75 !important; }
html body .errand-steps { gap: 0 !important; margin-top: 28px !important; border-block: 1px solid var(--lx-gold-line); }
html body .errand-steps li { border: 0 !important; border-radius: 0 !important; background: transparent !important; padding: 18px 4px !important; align-items: baseline !important; gap: 14px !important; }
html body .errand-steps li + li { border-top: 1px solid var(--lx-line) !important; }
html body .errand-steps li b { width: auto !important; height: auto !important; border-radius: 0 !important; background: none !important; color: var(--lx-gold) !important; font-family: var(--lx-serif); font-size: 28px !important; font-weight: 400 !important; line-height: 1; }
@media (min-width: 801px) {
  html body .errand-steps li + li { border-top: 0 !important; border-inline-start: 1px solid var(--lx-line) !important; padding-inline-start: 22px !important; }
}
html body :is(.errand-primary) { border-radius: 999px !important; box-shadow: none !important; }
html body :is(.errand-secondary) { border-radius: 999px !important; }
html body .errand-policy-note { border-radius: 16px !important; border-color: var(--lx-gold-line) !important; background: var(--lx-paper) !important; }

/* ---------- Sign-in (account entry) ---------- */
html body .unified-login .signin-card {
  border: 1px solid rgba(211, 180, 126, .55);
  border-radius: 24px;
  background: var(--lx-paper);
  box-shadow: 0 40px 90px -50px rgba(0, 0, 0, .7);
  position: relative;
}
html body .unified-login .signin-card::before { content: ""; position: absolute; inset: 10px; border: 1px solid rgba(184, 149, 92, .28); border-radius: 24px; pointer-events: none; }
html body .unified-login .signin-head h1, html body .unified-login .signin-head h2 { font-size: clamp(28px, 4vw, 36px); }
html:not([dir="rtl"]) body .unified-login .signin-head :is(h1, h2) { font-family: var(--lx-serif); font-weight: 400; }
html body .unified-login .signin-submit { border-radius: 999px; }

/* ---------- Cart and checkout sheets (home dialogs) ---------- */
html body .shell :is(.cart-sheet, .checkout-sheet, dialog.sheet, .sheet-panel) { background: var(--lx-paper); }

/* ---------- Entrance: slow and confident (components/luxe-reveal.tsx) ---------- */
@media (prefers-reduced-motion: no-preference) {
  html.lx-motion .lx-reveal:not(.lx-in) { opacity: 0; transform: translateY(28px); }
  html.lx-motion .lx-reveal { transition: opacity 1.1s cubic-bezier(.2, .7, .2, 1), transform 1.1s cubic-bezier(.2, .7, .2, 1); }
}

/* Page ground under short pages (between the content and the footer). */
html body:has(.tc-header:not(.tc-header-dark)):not(:has(.storefront)) { background: var(--lx-ivory); }
