/* Ornament (owner's request, 2026-11-08): a زخرفة for a medical platform.
 *
 * The background is the classic star-and-cross (نجمة وصليب): eight-pointed
 * stars meeting tip to tip, so the space between them forms crosses on its
 * own. Inside the stars, a medical cross and a heart take turns; in the gaps,
 * a small cross. The sign-in screen and the dashboard welcome carry a larger
 * rosette with a heartbeat through its heart.
 *
 * Drawn by a script (geometry, not freehand) and used as a mask, so the colour
 * is the theme's own brand token in light and dark, never a colour spelled out
 * here. It sits behind everything, at a whisper of opacity, and never takes a
 * click. No gradients (owner's rule).
 */
:root {
  --ornament-tile: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%22160%22 height=%22160%22 viewBox=%220 0 160 160%22%3E%3Cpath d=%22M40.00 0.00 L51.72 11.72 L68.28 11.72 L68.28 28.28 L80.00 40.00 L68.28 51.72 L68.28 68.28 L51.72 68.28 L40.00 80.00 L28.28 68.28 L11.72 68.28 L11.72 51.72 L0.00 40.00 L11.72 28.28 L11.72 11.72 L28.28 11.72 Z M49.18 17.83 L52.99 27.01 L62.17 30.82 L58.37 40.00 L62.17 49.18 L52.99 52.99 L49.18 62.17 L40.00 58.37 L30.82 62.17 L27.01 52.99 L17.83 49.18 L21.63 40.00 L17.83 30.82 L27.01 27.01 L30.82 17.83 L40.00 21.63 Z M51.00 40.00 A11 11 0 1 1 29.00 40.00 A11 11 0 1 1 51.00 40.00 Z M38.30 34.00 L41.70 34.00 L41.70 38.30 L46.00 38.30 L46.00 41.70 L41.70 41.70 L41.70 46.00 L38.30 46.00 L38.30 41.70 L34.00 41.70 L34.00 38.30 L38.30 38.30 Z M120.00 0.00 L131.72 11.72 L148.28 11.72 L148.28 28.28 L160.00 40.00 L148.28 51.72 L148.28 68.28 L131.72 68.28 L120.00 80.00 L108.28 68.28 L91.72 68.28 L91.72 51.72 L80.00 40.00 L91.72 28.28 L91.72 11.72 L108.28 11.72 Z M129.18 17.83 L132.99 27.01 L142.17 30.82 L138.37 40.00 L142.17 49.18 L132.99 52.99 L129.18 62.17 L120.00 58.37 L110.82 62.17 L107.01 52.99 L97.83 49.18 L101.63 40.00 L97.83 30.82 L107.01 27.01 L110.82 17.83 L120.00 21.63 Z M131.00 40.00 A11 11 0 1 1 109.00 40.00 A11 11 0 1 1 131.00 40.00 Z M120.00 37.86 C118.71 34.43 114.00 34.86 114.00 38.71 C114.00 42.14 117.86 43.86 120.00 46.00 C122.14 43.86 126.00 42.14 126.00 38.71 C126.00 34.86 121.29 34.43 120.00 37.86 Z M40.00 80.00 L51.72 91.72 L68.28 91.72 L68.28 108.28 L80.00 120.00 L68.28 131.72 L68.28 148.28 L51.72 148.28 L40.00 160.00 L28.28 148.28 L11.72 148.28 L11.72 131.72 L0.00 120.00 L11.72 108.28 L11.72 91.72 L28.28 91.72 Z M49.18 97.83 L52.99 107.01 L62.17 110.82 L58.37 120.00 L62.17 129.18 L52.99 132.99 L49.18 142.17 L40.00 138.37 L30.82 142.17 L27.01 132.99 L17.83 129.18 L21.63 120.00 L17.83 110.82 L27.01 107.01 L30.82 97.83 L40.00 101.63 Z M51.00 120.00 A11 11 0 1 1 29.00 120.00 A11 11 0 1 1 51.00 120.00 Z M40.00 117.86 C38.71 114.43 34.00 114.86 34.00 118.71 C34.00 122.14 37.86 123.86 40.00 126.00 C42.14 123.86 46.00 122.14 46.00 118.71 C46.00 114.86 41.29 114.43 40.00 117.86 Z M120.00 80.00 L131.72 91.72 L148.28 91.72 L148.28 108.28 L160.00 120.00 L148.28 131.72 L148.28 148.28 L131.72 148.28 L120.00 160.00 L108.28 148.28 L91.72 148.28 L91.72 131.72 L80.00 120.00 L91.72 108.28 L91.72 91.72 L108.28 91.72 Z M129.18 97.83 L132.99 107.01 L142.17 110.82 L138.37 120.00 L142.17 129.18 L132.99 132.99 L129.18 142.17 L120.00 138.37 L110.82 142.17 L107.01 132.99 L97.83 129.18 L101.63 120.00 L97.83 110.82 L107.01 107.01 L110.82 97.83 L120.00 101.63 Z M131.00 120.00 A11 11 0 1 1 109.00 120.00 A11 11 0 1 1 131.00 120.00 Z M118.30 114.00 L121.70 114.00 L121.70 118.30 L126.00 118.30 L126.00 121.70 L121.70 121.70 L121.70 126.00 L118.30 126.00 L118.30 121.70 L114.00 121.70 L114.00 118.30 L118.30 118.30 Z M-1.30 -6.00 L1.30 -6.00 L1.30 -1.30 L6.00 -1.30 L6.00 1.30 L1.30 1.30 L1.30 6.00 L-1.30 6.00 L-1.30 1.30 L-6.00 1.30 L-6.00 -1.30 L-1.30 -1.30 Z M-1.30 74.00 L1.30 74.00 L1.30 78.70 L6.00 78.70 L6.00 81.30 L1.30 81.30 L1.30 86.00 L-1.30 86.00 L-1.30 81.30 L-6.00 81.30 L-6.00 78.70 L-1.30 78.70 Z M-1.30 154.00 L1.30 154.00 L1.30 158.70 L6.00 158.70 L6.00 161.30 L1.30 161.30 L1.30 166.00 L-1.30 166.00 L-1.30 161.30 L-6.00 161.30 L-6.00 158.70 L-1.30 158.70 Z M78.70 -6.00 L81.30 -6.00 L81.30 -1.30 L86.00 -1.30 L86.00 1.30 L81.30 1.30 L81.30 6.00 L78.70 6.00 L78.70 1.30 L74.00 1.30 L74.00 -1.30 L78.70 -1.30 Z M78.70 74.00 L81.30 74.00 L81.30 78.70 L86.00 78.70 L86.00 81.30 L81.30 81.30 L81.30 86.00 L78.70 86.00 L78.70 81.30 L74.00 81.30 L74.00 78.70 L78.70 78.70 Z M78.70 154.00 L81.30 154.00 L81.30 158.70 L86.00 158.70 L86.00 161.30 L81.30 161.30 L81.30 166.00 L78.70 166.00 L78.70 161.30 L74.00 161.30 L74.00 158.70 L78.70 158.70 Z M158.70 -6.00 L161.30 -6.00 L161.30 -1.30 L166.00 -1.30 L166.00 1.30 L161.30 1.30 L161.30 6.00 L158.70 6.00 L158.70 1.30 L154.00 1.30 L154.00 -1.30 L158.70 -1.30 Z M158.70 74.00 L161.30 74.00 L161.30 78.70 L166.00 78.70 L166.00 81.30 L161.30 81.30 L161.30 86.00 L158.70 86.00 L158.70 81.30 L154.00 81.30 L154.00 78.70 L158.70 78.70 Z M158.70 154.00 L161.30 154.00 L161.30 158.70 L166.00 158.70 L166.00 161.30 L161.30 161.30 L161.30 166.00 L158.70 166.00 L158.70 161.30 L154.00 161.30 L154.00 158.70 L158.70 158.70 Z%22 fill=%22none%22 stroke=%22%23000%22 stroke-width=%221.1%22 stroke-linejoin=%22round%22 stroke-linecap=%22round%22/%3E%3C/svg%3E");
  --ornament-medallion: url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%22240%22 height=%22240%22 viewBox=%220 0 240 240%22%3E%3Cpath d=%22M120.00 4.00 L137.95 29.77 L164.39 12.83 L171.11 43.50 L202.02 37.98 L196.50 68.89 L227.17 75.61 L210.23 102.05 L236.00 120.00 L210.23 137.95 L227.17 164.39 L196.50 171.11 L202.02 202.02 L171.11 196.50 L164.39 227.17 L137.95 210.23 L120.00 236.00 L102.05 210.23 L75.61 227.17 L68.89 196.50 L37.98 202.02 L43.50 171.11 L12.83 164.39 L29.77 137.95 L4.00 120.00 L29.77 102.05 L12.83 75.61 L43.50 68.89 L37.98 37.98 L68.89 43.50 L75.61 12.83 L102.05 29.77 Z M154.44 36.85 L168.71 71.29 L203.15 85.56 L188.88 120.00 L203.15 154.44 L168.71 168.71 L154.44 203.15 L120.00 188.88 L85.56 203.15 L71.29 168.71 L36.85 154.44 L51.12 120.00 L36.85 85.56 L71.29 71.29 L85.56 36.85 L120.00 51.12 Z M184.00 120.00 A64 64 0 1 1 56.00 120.00 A64 64 0 1 1 184.00 120.00 Z M177.00 120.00 A57 57 0 1 1 63.00 120.00 A57 57 0 1 1 177.00 120.00 Z M74 130 H98 L105 118 L112 144 L120 102 L127 138 L133 130 H166 M120.00 83.14 C118.29 78.57 112.00 79.14 112.00 84.29 C112.00 88.86 117.14 91.14 120.00 94.00 C122.86 91.14 128.00 88.86 128.00 84.29 C128.00 79.14 121.71 78.57 120.00 83.14 Z%22 fill=%22none%22 stroke=%22%23000%22 stroke-width=%221.6%22 stroke-linejoin=%22round%22 stroke-linecap=%22round%22/%3E%3C/svg%3E");
}

/* The signed-in console: the pattern fills the working area behind the cards. */
.shell__main { position: relative; isolation: isolate; }
.shell__main::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-color: var(--ornament);
  opacity: var(--ornament-alpha);
  -webkit-mask-image: var(--ornament-tile); mask-image: var(--ornament-tile);
  -webkit-mask-size: 160px 160px; mask-size: 160px 160px;
  -webkit-mask-repeat: repeat; mask-repeat: repeat;
}

/* The dashboard welcome: one rosette at the far end, behind the button. */
.page__head--hero { position: relative; isolation: isolate; }
.page__head--hero::before {
  content: ''; position: absolute; z-index: -1; pointer-events: none;
  inset-inline-end: -24px; inset-block-start: 50%; translate: 0 -50%;
  inline-size: 200px; block-size: 200px;
  background-color: var(--ornament);
  opacity: var(--ornament-medallion-alpha);
  -webkit-mask-image: var(--ornament-medallion); mask-image: var(--ornament-medallion);
  -webkit-mask-size: contain; mask-size: contain;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}

/* Sign-in: the pattern behind, a large rosette behind the card. */
.auth { position: relative; isolation: isolate; overflow: hidden; }
.auth::before, .auth::after {
  content: ''; position: absolute; z-index: -1; pointer-events: none;
  background-color: var(--ornament);
}
.auth::before {
  inset: 0; opacity: var(--ornament-alpha);
  -webkit-mask-image: var(--ornament-tile); mask-image: var(--ornament-tile);
  -webkit-mask-size: 160px 160px; mask-size: 160px 160px;
}
.auth::after {
  inline-size: min(720px, 120vw); block-size: min(720px, 120vw);
  inset-block-start: 50%; inset-inline-start: 50%; translate: -50% -50%;
  opacity: var(--ornament-medallion-alpha);
  -webkit-mask-image: var(--ornament-medallion); mask-image: var(--ornament-medallion);
  -webkit-mask-size: contain; mask-size: contain;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}
[dir="rtl"] .auth::after { translate: 50% -50%; }

/* A slow breath on the sign-in rosette — the one place the ornament moves. */
@media (prefers-reduced-motion: no-preference) {
  .auth::after { animation: ornament-breathe 9s var(--ease) infinite alternate; }
}
@keyframes ornament-breathe {
  from { opacity: var(--ornament-medallion-alpha); }
  to { opacity: calc(var(--ornament-medallion-alpha) * 1.6); }
}

@media print {
  .shell__main::before, .page__head--hero::before, .auth::before, .auth::after { display: none; }
}
