/* ==========================================================================
   LEATZEV · Cinema theme for the CRM (2026-11)
   Visual only, loaded after elegant-theme.css. Brings the system in line with
   the new public site: cream and ivory paper, deep teal, turquoise, pink and
   gold, the FbCoherentiSans font, and the site's dragon.
   No workflow, data, API or form behaviour changes.
   Kept from CLAUDE.md: no emoji, no blur on cards, no transform on grid/flex
   items or on hover, no purple gradients.
   ========================================================================== */

:root {
  --cine-cream: #F5EEDF;
  --cine-cream-deep: #EADFC8;
  --cine-ivory: #FCF8F0;
  --cine-paper: #FFFCF6;
  --cine-ink: #0C0E0F;
  --cine-ink-soft: #42484A;
  --cine-muted: #5C6366;
  --cine-teal-deep: #06363A;
  --cine-teal: #0B5F64;
  --cine-turq: #12A5A0;
  --cine-turq-light: #9ADBD4;
  --cine-emerald: #0D7C57;
  --cine-pink: #D61F69;
  --cine-pink-deep: #A3134E;
  --cine-rose: #F2B4C5;
  --cine-blush: #F9DEE4;
  --cine-gold: #C39A3C;
  --cine-gold-light: #E7C877;
  --cine-gold-deep: #8A651A;
  --cine-line: #E3D7C1;
  --cine-on-teal: #BFD6D3;

  /* the elegant theme's tokens, pointed at the site palette */
  --elegant-ink: var(--cine-ink);
  --elegant-ink-soft: var(--cine-ink-soft);
  --elegant-muted: var(--cine-muted);
  --elegant-line: var(--cine-line);
  --elegant-panel: var(--cine-ivory);
  --elegant-panel-strong: var(--cine-paper);
  --elegant-wash: var(--cine-cream);
  --elegant-wash-2: var(--cine-cream-deep);
  --elegant-green: var(--cine-turq);
  --elegant-green-dark: var(--cine-teal);
  --elegant-copper: var(--cine-gold);
  --elegant-red: #B4233F;
  --elegant-yellow: var(--cine-gold-deep);
  --elegant-blue: var(--cine-teal);
  --elegant-radius: 16px;
  --elegant-shadow: 0 18px 44px rgba(6, 54, 58, 0.10);
  --elegant-shadow-soft: 0 6px 20px rgba(6, 54, 58, 0.06);
  --elegant-bg-app: none;
  --elegant-bg-greeting: none;
  --elegant-bg-proposal: none;
  --elegant-bg-auth: none;
  --elegant-bg-paper: none;

  /* base tokens from style.css */
  --color-mint: var(--cine-ink);
  --color-mint-dark: var(--cine-ink);
  --color-mint-light: #DDEFEC;
  --color-peach: var(--cine-pink);
  --color-peach-light: var(--cine-blush);
  --color-peach-dark: var(--cine-pink-deep);
  --color-blue: var(--cine-teal);
  --color-blue-light: #E0F0EE;
  --color-blue-dark: var(--cine-teal-deep);
  --color-cream: var(--cine-cream);
  --color-charcoal: var(--cine-ink);
  --color-gray-50: #FBF7EF;
  --color-gray-100: #F2EBDD;
  --color-gray-200: #E3D7C1;
  --color-gray-300: #CDBFA6;
  --color-gray-400: #9A9284;
  --color-gray-500: #6E6A62;
  --color-gray-600: #575A57;
  --color-gray-700: #42484A;
  --color-gray-800: #2A2E30;
  --color-gray-900: #0C0E0F;

  --status-new: var(--cine-turq);
  --status-new-bg: #DDF1EE;
  --status-in-progress: var(--cine-teal);
  --status-in-progress-bg: #D9ECEA;
  --status-on-hold: var(--cine-gold-deep);
  --status-on-hold-bg: #F5E8C2;
  --status-pending-approval: var(--cine-pink);
  --status-pending-approval-bg: var(--cine-blush);
  --status-completed: var(--cine-emerald);
  --status-completed-bg: #D6EDE2;
  --status-cancelled: #8A3B46;
  --status-cancelled-bg: #F1E3E3;

  --radius-md: 14px;
  --radius-lg: 18px;
  --radius-xl: 26px;
  --shadow-mint: 0 8px 20px rgba(12, 14, 15, 0.18);
  --shadow-peach: 0 8px 20px rgba(214, 31, 105, 0.18);
  --shadow-blue: 0 8px 20px rgba(6, 54, 58, 0.16);
}

/* ---------- page ---------- */
html { background: var(--cine-cream); }
body {
  color: var(--cine-ink);
  background: var(--cine-cream) !important;
}
body::before { display: none !important; }

h1, h2, h3, h4, h5, h6,
.dashboard__hello,
.dashboard__section-title,
.section-title {
  color: var(--cine-ink);
  letter-spacing: -0.01em;
}

::selection { background: var(--cine-gold-light); color: var(--cine-ink); }

/* ---------- top bar ---------- */
.app-header {
  background: rgba(245, 238, 223, 0.96) !important;
  border-bottom: 1px solid var(--cine-line) !important;
}
@media (min-width: 1024px) {
  .app-header { background: transparent !important; border-bottom: 0 !important; }
}
.notif-bell {
  background: var(--cine-paper) !important;
  border: 1px solid var(--cine-line) !important;
  box-shadow: none !important;
  color: var(--cine-ink);
}
.notif-bell:hover { color: var(--cine-teal) !important; border-color: var(--cine-turq) !important; }
.notif-bell__badge { background: var(--cine-pink) !important; color: #fff !important; }

/* ---------- side menu: deep teal with a film-strip edge ---------- */
.app-sidebar {
  background: var(--cine-teal-deep) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  color: var(--cine-cream);
}
.app-sidebar::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 9px;
  width: 7px;
  background: repeating-linear-gradient(to bottom, rgba(245, 238, 223, 0.14) 0 9px, transparent 9px 20px);
  border-radius: 2px;
  pointer-events: none;
}
.sidebar__brand {
  color: var(--cine-cream) !important;
  background: transparent !important;
  border-bottom: 1px solid rgba(245, 238, 223, 0.12) !important;
}
.sidebar__brand img { filter: brightness(0) invert(0.94) sepia(0.28); }
.sidebar__link {
  margin-inline: 12px 24px !important;
  color: var(--cine-on-teal) !important;
  border-radius: 999px !important;
  transition: background 150ms ease, color 150ms ease !important;
}
.sidebar__link:hover {
  background: rgba(245, 238, 223, 0.08) !important;
  color: var(--cine-ivory) !important;
  transform: none !important;
}
.sidebar__link--active {
  background: var(--cine-gold-light) !important;
  color: var(--cine-ink) !important;
  box-shadow: none !important;
}
.sidebar__link--logout { color: var(--cine-rose) !important; }

/* ---------- bottom menu (phone) ---------- */
.bottom-nav {
  background: var(--cine-teal-deep) !important;
  border-top: 0 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  box-shadow: 0 -8px 24px rgba(6, 54, 58, 0.18) !important;
}
.bottom-nav__item { color: var(--cine-on-teal) !important; }
.bottom-nav__item--active { color: var(--cine-gold-light) !important; }

.fab {
  background: var(--cine-pink) !important;
  color: #fff !important;
  box-shadow: 0 14px 30px rgba(214, 31, 105, 0.32) !important;
}

/* ---------- cards ---------- */
.card,
.stat-card,
.client-card,
.order-list-card,
.modal,
.notif-panel {
  border-radius: 18px !important;
}

/* the greeting: a teal "scene" with the dragon holding the day's checklist */
.dashboard__greeting {
  /* sized by the card's width, so on narrower laptops the dragon shrinks instead of reaching the greeting */
  background:
    url("/assets/cine/img/roles/dragon-order.webp") no-repeat left -6px bottom -14px / min(56%, 404px) auto,
    var(--cine-teal-deep) !important;
  border-color: transparent !important;
  color: var(--cine-ivory);
}
.dashboard__greeting::before,
.dashboard__greeting::after { display: none !important; }
.dashboard__greeting > div { max-width: 46%; }
.dashboard__greeting .dashboard__eyebrow {
  display: inline-block;
  color: var(--cine-gold-light) !important;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(231, 200, 119, 0.45);
}
.dashboard__greeting .dashboard__hello { color: var(--cine-ivory) !important; }
.dashboard__greeting .dashboard__date { color: var(--cine-on-teal) !important; max-width: 24ch; }
@media (max-width: 640px) {
  .dashboard__greeting {
    background:
      url("/assets/cine/img/roles/dragon-order.webp") no-repeat left -18px bottom -8px / auto 62%,
      var(--cine-teal-deep) !important;
  }
}

/* numbers */
.stat-card__value,
.exp-summary__value,
.report-metric__value {
  color: var(--cine-ink) !important;
  font-family: var(--font-display);
}
.stat-card__icon { color: var(--cine-pink) !important; background: var(--cine-blush) !important; }
.dashboard__stats > :nth-child(2) .stat-card__icon,
.dashboard__stats > .stat-card:nth-child(2) .stat-card__icon { color: var(--cine-teal) !important; background: #DDEFEC !important; }
.dashboard__stats > :nth-child(3) .stat-card__icon,
.dashboard__stats > .stat-card:nth-child(3) .stat-card__icon { color: var(--cine-gold-deep) !important; background: #F5E8C2 !important; }

/* ---------- buttons ---------- */
.btn--primary,
.submit-btn,
.login-btn,
.form-submit-btn {
  background: var(--cine-ink) !important;
  border-color: var(--cine-ink) !important;
  color: var(--cine-ivory) !important;
  box-shadow: none !important;
}
.btn--primary:hover,
.submit-btn:hover,
.login-btn:hover,
.form-submit-btn:hover {
  background: var(--cine-pink) !important;
  border-color: var(--cine-pink) !important;
  box-shadow: 0 10px 22px rgba(214, 31, 105, 0.22) !important;
}
.btn--secondary,
.btn--ghost,
.btn--outline,
.portal-logout-btn {
  background: transparent !important;
  color: var(--cine-ink) !important;
  border: 1.5px solid rgba(12, 14, 15, 0.22) !important;
}
.btn--secondary:hover,
.btn--ghost:hover,
.btn--outline:hover {
  border-color: var(--cine-ink) !important;
  background: rgba(12, 14, 15, 0.04) !important;
}
.btn:hover,
.btn:active { transform: none !important; }

/* ---------- status chips ---------- */
.badge,
.order-status-badge { border-radius: 999px !important; font-weight: 600; }
.badge--new { background: var(--status-new-bg) !important; color: var(--cine-teal) !important; }
.badge--in-progress { background: var(--status-in-progress-bg) !important; color: var(--cine-teal-deep) !important; }
.badge--hold { background: var(--status-on-hold-bg) !important; color: var(--cine-gold-deep) !important; }
.badge--pending-approval { background: var(--status-pending-approval-bg) !important; color: var(--cine-pink-deep) !important; }
.badge--completed { background: var(--status-completed-bg) !important; color: var(--cine-emerald) !important; }
.badge--cancelled { background: var(--status-cancelled-bg) !important; color: var(--status-cancelled) !important; }

/* ---------- fields ---------- */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="time"],
input[type="search"],
input[type="password"],
input[type="url"],
select,
textarea {
  background-color: var(--cine-paper);
  border-color: var(--cine-line);
}
input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
input[type="time"]:focus,
input[type="search"]:focus,
input[type="password"]:focus,
input[type="url"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--cine-turq) !important;
  box-shadow: 0 0 0 3px rgba(18, 165, 160, 0.18) !important;
}
input[type="checkbox"],
input[type="radio"] { accent-color: var(--cine-teal); }

/* ---------- windows and messages ---------- */
.modal-overlay {
  background: rgba(6, 20, 22, 0.55) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}
.modal { background: var(--cine-ivory) !important; }
.toast {
  background: var(--cine-ink) !important;
  color: var(--cine-ivory) !important;
  border-color: rgba(245, 238, 223, 0.14) !important;
}

a { color: inherit; }
.link, a.link { color: var(--cine-teal); }

/* ---------- login: the dragon calls "action" over the ticket ---------- */
body:has(#loginForm) {
  background: var(--cine-teal-deep) !important;
}
body:has(#loginForm) .bg { display: none !important; }
body:has(#loginForm) > .card {
  position: relative;
  overflow: visible !important;
  background: var(--cine-ivory) !important;
  border: 0 !important;
  border-radius: 26px !important;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.32) !important;
}
body:has(#loginForm) > .card::before {
  content: "";
  position: absolute;
  top: -118px;
  left: -34px;
  width: 190px;
  height: 142px;
  background: url("/assets/cine/img/roles/dragon-director.webp") no-repeat center / contain;
  pointer-events: none;
}
body:has(#loginForm) > .card::after {
  content: "";
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 12px;
  height: 0;
  border-bottom: 2px dashed var(--cine-line);
  pointer-events: none;
}
body:has(#loginForm) label { color: var(--cine-ink-soft); }
body:has(#loginForm) .submit-btn { min-height: 52px; font-size: 1.05rem; }

/* ---------- order board: its status colours come inline from orders.js; remap them to the palette ---------- */
[style*="#7a9ef5"] { --col-color: #12A5A0 !important; --card-accent: #12A5A0 !important; --chip-color: #12A5A0 !important; }
[style*="#5ec69a"] { --col-color: #0B5F64 !important; --card-accent: #0B5F64 !important; --chip-color: #0B5F64 !important; }
[style*="#f5a623"] { --col-color: #C39A3C !important; --card-accent: #C39A3C !important; --chip-color: #C39A3C !important; }
[style*="#e8849a"] { --col-color: #D61F69 !important; --card-accent: #D61F69 !important; --chip-color: #D61F69 !important; }
[style*="#34b76f"] { --col-color: #0D7C57 !important; --card-accent: #0D7C57 !important; --chip-color: #0D7C57 !important; }
:is(.kanban__column-dot, .orders-mobile-group__dot, .move-sheet__dot)[style*="#7a9ef5"] { background: #12A5A0 !important; }
:is(.kanban__column-dot, .orders-mobile-group__dot, .move-sheet__dot)[style*="#5ec69a"] { background: #0B5F64 !important; }
:is(.kanban__column-dot, .orders-mobile-group__dot, .move-sheet__dot)[style*="#f5a623"] { background: #C39A3C !important; }
:is(.kanban__column-dot, .orders-mobile-group__dot, .move-sheet__dot)[style*="#e8849a"] { background: #D61F69 !important; }
:is(.kanban__column-dot, .orders-mobile-group__dot, .move-sheet__dot)[style*="#34b76f"] { background: #0D7C57 !important; }

/* ---------- login: the page's own lilac touches, moved to the palette ---------- */
body:has(#loginForm) .field input::placeholder { color: #9A9284 !important; }
body:has(#loginForm) .subtitle,
body:has(#loginForm) .client-link,
body:has(#loginForm) .footer { color: var(--cine-muted) !important; }
body:has(#loginForm) .client-link a,
body:has(#loginForm) .footer a { color: var(--cine-teal) !important; }
body:has(#loginForm) .pass-toggle { color: var(--cine-muted) !important; }
body:has(#loginForm) .field input { background: var(--cine-paper) !important; border-color: var(--cine-line) !important; }

/* ---------- leftovers found on the phone screens ---------- */
/* "days open" on order cards, inline from orders.js: amber and coral moved to the palette
   (the :not() keeps inline variables such as --stat-color out of it) */
[style*="color:#f5a623"]:not([style*="-color:#f5a623"]) { color: var(--cine-gold-deep) !important; }
[style*="color:#e74c5e"]:not([style*="-color:#e74c5e"]) { color: #B4233F !important; }
/* cancelled status (inline too) */
[style*="#e74c5e"] { --col-color: #8A3B46 !important; --card-accent: #8A3B46 !important; --chip-color: #8A3B46 !important; --stat-color: #B4233F !important; }
:is(.kanban__column-dot, .orders-mobile-group__dot, .move-sheet__dot)[style*="#e74c5e"] { background: #8A3B46 !important; }
/* stat cards get their accent from an inline --stat-color with the same old colours */
[style*="--stat-color:#7a9ef5"] { --stat-color: #12A5A0 !important; }
[style*="--stat-color:#5ec69a"] { --stat-color: #0B5F64 !important; }
[style*="--stat-color:#34b76f"] { --stat-color: #0D7C57 !important; }

/* debt amounts: the client chip and the home screen's collection list */
.client-card__balance--debt { background-color: #F6E1E5 !important; color: #B4233F !important; }
.unpaid-mini-card__amount,
.unpaid-sub-item__amount { color: #B4233F !important; }

/* window header: the same ivory as the window, no lighter strip */
.modal__header { background: transparent !important; }

/* phone "more" menu (built inline in app.js): an ivory sheet over the teal bar */
#more-menu {
  background: var(--cine-ivory) !important;
  border-top: 1px solid var(--cine-line) !important;
  border-radius: 22px 22px 0 0;
  box-shadow: 0 -12px 30px rgba(6, 54, 58, 0.14) !important;
}
#more-menu > button {
  background: var(--cine-cream) !important;
  color: var(--cine-ink-soft) !important;
  border-radius: 14px !important;
}

/* today's tasks on the home screen: the side stripe in turquoise instead of grey-brown */
.dashboard-task-card {
  border-right-color: var(--cine-turq) !important;
  background: var(--cine-paper) !important;
  box-shadow: none !important;
}

/* the site screen ("האתר"): ivory paper like every other card */
.site-screen .site-stat,
.site-screen .site-card {
  background: var(--cine-ivory) !important;
  border: 1px solid var(--cine-line) !important;
  box-shadow: none !important;
}
.site-screen .site-stat--new {
  background: var(--cine-blush) !important;
  border-color: var(--cine-rose) !important;
}

/* login: the last lilac touches */
body:has(#loginForm) .divider { border-top-color: var(--cine-line) !important; }
body:has(#loginForm) .field input { color: var(--cine-ink) !important; }
body:has(#loginForm) .error-msg { background: #F6E1E5 !important; color: #B4233F !important; }

/* order board: owed and paid notes on the cards */
.kanban-card__price--debt { color: #B4233F !important; }
.kanban-card__price--paid { color: var(--cine-emerald) !important; }

/* desktop home screen: start below the round buttons at the top, so they no longer sit on the first card */
@media (min-width: 1024px) {
  .dashboard--elegant { padding-top: 58px; }
}
