/* Mali Cutz — shared tokens and components for the site and the dashboard.
   Palette: black, charcoal, porcelain off-white, brass. Brass is hardware, not paint:
   it marks state (today, selected, open) and never fills large areas. */

@font-face {
  font-family: 'Archivo';
  src: url('../fonts/archivo-var.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212;
}
@font-face { font-family: 'Plex'; src: url('../fonts/plex-sans-400.woff2') format('woff2'); font-weight: 400; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: 'Plex'; src: url('../fonts/plex-sans-500.woff2') format('woff2'); font-weight: 500; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: 'Plex'; src: url('../fonts/plex-sans-600.woff2') format('woff2'); font-weight: 600 700; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2212; }
@font-face { font-family: 'Plex Arabic'; src: url('../fonts/plex-arabic-400.woff2') format('woff2'); font-weight: 400; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'Plex Arabic'; src: url('../fonts/plex-arabic-500.woff2') format('woff2'); font-weight: 500; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'Plex Arabic'; src: url('../fonts/plex-arabic-600.woff2') format('woff2'); font-weight: 600; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }
@font-face { font-family: 'Plex Arabic'; src: url('../fonts/plex-arabic-700.woff2') format('woff2'); font-weight: 700 800; font-display: swap; unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0898-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC; }

:root {
  --black: #000000;
  --charcoal: #1d1d1c;
  --charcoal-2: #2b2b29;
  --line-dark: #3a3a37;
  --porcelain: #edece7;
  --paper: #ffffff;
  --line: #cfcdc5;
  --ink: #151514;
  --muted: #5d5c57;
  --muted-dark: #a6a59e;
  --brass: #b8975a;
  --brass-ink: #7d6232; /* brass dark enough for text on light backgrounds */
  --danger: #a3302a;
  --ok: #2f6b3f;

  --font-display: 'Archivo', 'Arial Black', 'Helvetica Neue', Arial, sans-serif;
  --font-text: 'Plex', 'Plex Arabic', 'Helvetica Neue', Arial, sans-serif;
  --font-arabic: 'Plex Arabic', 'Plex', Tahoma, sans-serif;

  --radius: 3px;
  --tap: 48px;
  --gutter: 16px;
  --focus: 0 0 0 2px var(--paper), 0 0 0 4px var(--brass);

  /* Palestinian patterns, drawn in brass by scripts/patterns.py:
     tatreez (cross-stitch borders) and the keffiyeh fishnet. */
  --keffiyeh: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3E%3Cpath d='M0 0L30 30M30 0L0 30' stroke='%23151514' stroke-width='1.2'/%3E%3Cg fill='%23151514'%3E%3Cellipse cx='15.0' cy='15.0' rx='4.4' ry='2.4' transform='rotate%28-45 15.0 15.0%29'/%3E%3Cellipse cx='0' cy='0' rx='4.4' ry='2.4' transform='rotate%28-45 0 0%29'/%3E%3Cellipse cx='30' cy='0' rx='4.4' ry='2.4' transform='rotate%28-45 30 0%29'/%3E%3Cellipse cx='0' cy='30' rx='4.4' ry='2.4' transform='rotate%28-45 0 30%29'/%3E%3Cellipse cx='30' cy='30' rx='4.4' ry='2.4' transform='rotate%28-45 30 30%29'/%3E%3C/g%3E%3C/svg%3E");
  --keffiyeh-size: 30px;
  --tatreez-rule-ink: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='15' viewBox='0 0 18 15'%3E%3Cpath d='M6.42 0.42L8.58 2.58M8.58 0.42L6.42 2.58M3.42 3.42L5.58 5.58M5.58 3.42L3.42 5.58M9.42 3.42L11.58 5.58M11.58 3.42L9.42 5.58M0.42 6.42L2.58 8.58M2.58 6.42L0.42 8.58M6.42 6.42L8.58 8.58M8.58 6.42L6.42 8.58M12.42 6.42L14.58 8.58M14.58 6.42L12.42 8.58M3.42 9.42L5.58 11.58M5.58 9.42L3.42 11.58M9.42 9.42L11.58 11.58M11.58 9.42L9.42 11.58M6.42 12.42L8.58 14.58M8.58 12.42L6.42 14.58' stroke='%237d6232' stroke-width='1' stroke-linecap='round' fill='none'/%3E%3C/svg%3E");
  --tatreez-band: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='52' viewBox='0 0 48 52'%3E%3Cpath d='M0.56 0.56L3.44 3.44M3.44 0.56L0.56 3.44M8.56 0.56L11.44 3.44M11.44 0.56L8.56 3.44M16.56 0.56L19.44 3.44M19.44 0.56L16.56 3.44M24.56 0.56L27.44 3.44M27.44 0.56L24.56 3.44M32.56 0.56L35.44 3.44M35.44 0.56L32.56 3.44M40.56 0.56L43.44 3.44M43.44 0.56L40.56 3.44M20.56 8.56L23.44 11.44M23.44 8.56L20.56 11.44M16.56 12.56L19.44 15.44M19.44 12.56L16.56 15.44M24.56 12.56L27.44 15.44M27.44 12.56L24.56 15.44M12.56 16.56L15.44 19.44M15.44 16.56L12.56 19.44M20.56 16.56L23.44 19.44M23.44 16.56L20.56 19.44M28.56 16.56L31.44 19.44M31.44 16.56L28.56 19.44M8.56 20.56L11.44 23.44M11.44 20.56L8.56 23.44M16.56 20.56L19.44 23.44M19.44 20.56L16.56 23.44M24.56 20.56L27.44 23.44M27.44 20.56L24.56 23.44M32.56 20.56L35.44 23.44M35.44 20.56L32.56 23.44M4.56 24.56L7.44 27.44M7.44 24.56L4.56 27.44M12.56 24.56L15.44 27.44M15.44 24.56L12.56 27.44M20.56 24.56L23.44 27.44M23.44 24.56L20.56 27.44M28.56 24.56L31.44 27.44M31.44 24.56L28.56 27.44M36.56 24.56L39.44 27.44M39.44 24.56L36.56 27.44M44.56 24.56L47.44 27.44M47.44 24.56L44.56 27.44M8.56 28.56L11.44 31.44M11.44 28.56L8.56 31.44M16.56 28.56L19.44 31.44M19.44 28.56L16.56 31.44M24.56 28.56L27.44 31.44M27.44 28.56L24.56 31.44M32.56 28.56L35.44 31.44M35.44 28.56L32.56 31.44M12.56 32.56L15.44 35.44M15.44 32.56L12.56 35.44M20.56 32.56L23.44 35.44M23.44 32.56L20.56 35.44M28.56 32.56L31.44 35.44M31.44 32.56L28.56 35.44M16.56 36.56L19.44 39.44M19.44 36.56L16.56 39.44M24.56 36.56L27.44 39.44M27.44 36.56L24.56 39.44M20.56 40.56L23.44 43.44M23.44 40.56L20.56 43.44M0.56 48.56L3.44 51.44M3.44 48.56L0.56 51.44M8.56 48.56L11.44 51.44M11.44 48.56L8.56 51.44M16.56 48.56L19.44 51.44M19.44 48.56L16.56 51.44M24.56 48.56L27.44 51.44M27.44 48.56L24.56 51.44M32.56 48.56L35.44 51.44M35.44 48.56L32.56 51.44M40.56 48.56L43.44 51.44M43.44 48.56L40.56 51.44' stroke='%23b8975a' stroke-width='1.15' stroke-linecap='round' fill='none'/%3E%3C/svg%3E");
  --tatreez-band-w: 48px;
  --tatreez-band-h: 52px;
  --tatreez-rule: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='15' viewBox='0 0 18 15'%3E%3Cpath d='M6.42 0.42L8.58 2.58M8.58 0.42L6.42 2.58M3.42 3.42L5.58 5.58M5.58 3.42L3.42 5.58M9.42 3.42L11.58 5.58M11.58 3.42L9.42 5.58M0.42 6.42L2.58 8.58M2.58 6.42L0.42 8.58M6.42 6.42L8.58 8.58M8.58 6.42L6.42 8.58M12.42 6.42L14.58 8.58M14.58 6.42L12.42 8.58M3.42 9.42L5.58 11.58M5.58 9.42L3.42 11.58M9.42 9.42L11.58 11.58M11.58 9.42L9.42 11.58M6.42 12.42L8.58 14.58M8.58 12.42L6.42 14.58' stroke='%23b8975a' stroke-width='1' stroke-linecap='round' fill='none'/%3E%3C/svg%3E");
  --tatreez-rule-w: 18px;
  --tatreez-rule-h: 15px;
}

html[lang='ar'] {
  --font-text: 'Plex Arabic', 'Plex', Tahoma, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-text);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--porcelain);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
html[lang='ar'] body {
  font-size: 1.0625rem;
  line-height: 1.75;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: none;
  box-shadow: var(--focus);
}

.i {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  vertical-align: -0.25em;
}
[dir='rtl'] .i.flip {
  transform: scaleX(-1);
}

/* ---------------------------------------------------------------- tatreez */

/* Full border band: stitched edges with a row of diamonds. */
.tatreez-band {
  height: var(--tatreez-band-h);
  background: var(--tatreez-band) repeat-x center;
}
/* One line of small stitched diamonds. */
.tatreez-line {
  height: var(--tatreez-rule-h);
  background: var(--tatreez-rule) repeat-x center;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Phone numbers, prices and emails always read left-to-right, even inside Arabic text. */
.ltr {
  direction: ltr;
  unicode-bidi: isolate;
}
/* Keeps a phone number or price on one line. */
.nowrap {
  white-space: nowrap;
}
bdi {
  unicode-bidi: isolate;
}

/* ---------------------------------------------------------------- wordmark */

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  white-space: nowrap;
}
.wordmark__latin {
  font-family: var(--font-display);
  font-stretch: 125%;
  font-weight: 800;
  font-size: 1.0625rem;
  letter-spacing: 0.02em;
  direction: ltr;
}
.wordmark__arabic {
  font-family: var(--font-arabic);
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--brass);
  padding-inline-start: 10px;
  border-inline-start: 1px solid currentColor;
  line-height: 1.1;
}

/* ---------------------------------------------------------------- buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: var(--tap);
  padding: 0 20px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 1rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.btn:disabled,
.btn[aria-disabled='true'] {
  opacity: 0.45;
  cursor: not-allowed;
}
.btn--solid {
  background: var(--ink);
  color: var(--porcelain);
}
.btn--solid:hover {
  background: #2c2c2a;
}
.btn--light {
  background: var(--porcelain);
  color: var(--black);
}
.btn--light:hover {
  background: #fff;
}
.btn--outline {
  background: transparent;
  border-color: currentColor;
}
.btn--outline:hover {
  background: rgba(127, 127, 120, 0.12);
}
.btn--quiet {
  background: transparent;
  padding-inline: 8px;
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 500;
}
.btn--danger {
  background: transparent;
  color: var(--danger);
  border-color: currentColor;
}
.btn--block {
  width: 100%;
}
.btn--sm {
  min-height: 40px;
  padding: 0 14px;
  font-size: 0.9375rem;
}

/* ---------------------------------------------------------------- forms */

.field {
  display: grid;
  gap: 6px;
  margin-bottom: 18px;
}
.field__label {
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.45;
}
.field__label small {
  font-weight: 400;
  color: var(--muted);
}
.field__hint {
  font-size: 0.875rem;
  color: var(--muted);
}
.field__error {
  font-size: 0.875rem;
  color: var(--danger);
  font-weight: 500;
}
.input,
.select,
.textarea {
  width: 100%;
  min-height: var(--tap);
  padding: 10px 12px;
  background: var(--paper);
  border: 1px solid #b9b7ae;
  border-radius: var(--radius);
  font-size: 1rem; /* 16px stops iOS from zooming in */
  line-height: 1.35;
}
.input,
.select {
  height: var(--tap);
}
.textarea {
  min-height: 88px;
  resize: vertical;
}
.select {
  appearance: none;
  padding-inline-end: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23151514' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M7 10l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: 18px;
  background-position: right 10px center;
}
[dir='rtl'] .select {
  background-position: left 10px center;
}
.input:focus,
.select:focus,
.textarea:focus {
  border-color: var(--ink);
}
.input[aria-invalid='true'],
.textarea[aria-invalid='true'] {
  border-color: var(--danger);
}
.input--ltr {
  direction: ltr;
  text-align: start;
}
[dir='rtl'] .input--ltr {
  text-align: right;
}

.check {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: var(--tap);
  padding: 12px 0;
  cursor: pointer;
}
.check input {
  width: 22px;
  height: 22px;
  margin: 1px 0 0;
  accent-color: var(--ink);
  flex: none;
}

.notice {
  padding: 12px 14px;
  border-inline-start: 3px solid var(--brass);
  background: var(--paper);
  font-size: 0.9375rem;
}
.notice--error {
  border-color: var(--danger);
  color: var(--danger);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
