      /* Disable long-press text selection everywhere */
      *, *::before, *::after {
        -webkit-user-select: none;
        user-select: none;
        -webkit-touch-callout: none;
      }

      /* Re-enable text selection only for input fields */
      input, textarea, [contenteditable="true"] {
        -webkit-user-select: text;
        user-select: text;
        -webkit-touch-callout: default;
      }

      body {
        font-family: "Assistant", sans-serif;
        transition:
          background-color 0.5s ease,
          color 0.5s ease;
      }
      .holy-text-style {
        font-family: 'Frank Ruhl Libre', serif;
        font-size: 25px;
        font-weight: 700;
        line-height: 1.7;
        text-align: center;
        color: #000000;
      }
      /* Chok L'Israel Rashi inline colors — must override .holy-text-style */
      .chok-rashi-dibur { color: #b45309 !important; font-weight: 700; }
      .chok-rashi-sep   { color: #6b7280 !important; }
      .chok-rashi-rest  { color: #4c1d95 !important; }
      .chok-rashi-label { color: #7c3aed !important; font-size: 0.75em; font-weight: 700; display: block; margin-bottom: 0.15rem; }

      /* Mobile-optimized prayer modal: use full width */
      .prayer-modal-body-mobile {
        padding: 0.5rem 0.4rem !important;
      }
      @media (min-width: 640px) {
        .prayer-modal-body-mobile {
          padding: 1.25rem !important;
        }
      }

      /* ── Stars Canvas ── */
      #stars-canvas {
        position: absolute;
        inset: 0;
        z-index: 0;
        pointer-events: none;
        opacity: 1;
        transition: opacity 0.7s ease;
      }

      /* ── Glass Card ── */
      .glass-card {
        background: linear-gradient(165deg, rgba(255, 255, 255, 0.10) 0%, rgba(255, 255, 255, 0.04) 100%);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(232, 193, 90, 0.25);
        box-shadow:
          0 4px 30px rgba(0, 0, 0, 0.22),
          inset 0 1px 0 rgba(255, 255, 255, 0.12);
        transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
      }
      .glass-card:hover {
        background: linear-gradient(165deg, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0.06) 100%);
        border-color: rgba(232, 193, 90, 0.5);
        transform: translateY(-3px);
        box-shadow:
          0 12px 44px rgba(0, 0, 0, 0.32),
          0 0 22px rgba(232, 193, 90, 0.12),
          inset 0 1px 0 rgba(255, 255, 255, 0.14);
      }
      /* ── Filter Chips ── */
      .chip {
        transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        border: 1px solid transparent;
        border-radius: 999px !important;
        /* overflow:hidden (בשביל ה-ripple) מאפס את רוחב המינימום של פריט flex
           וגורם לחיתוך הטקסט במובייל — מקבעים שלא יתכווץ */
        flex-shrink: 0;
      }
      .chip:hover:not(.active) {
        border-color: rgba(200, 155, 60, 0.55);
        color: #a16207;
      }
      .dark .chip:hover:not(.active) {
        color: #f2d98a;
      }
      .chip.active {
        background: linear-gradient(135deg, #f2d98a 0%, #dfb254 45%, #c9993a 100%) !important;
        color: #1a2547 !important;
        box-shadow:
          0 4px 20px rgba(201, 153, 58, 0.45),
          inset 0 1px 0 rgba(255, 255, 255, 0.45);
        border-color: rgba(161, 118, 42, 0.6);
        text-shadow: 0 1px 0 rgba(255, 255, 255, 0.3);
      }

      /* ── Event Cards ── */
      .event-card {
        transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        opacity: 1;
        transform: translateY(0);
        position: relative;
        overflow: hidden;
      }
      .event-card.visible {
        opacity: 1;
        transform: translateY(0);
      }
      .event-card:hover {
        transform: translateY(-6px);
        box-shadow:
          0 20px 50px -12px rgba(15, 23, 42, 0.22),
          0 0 0 1px rgba(200, 155, 60, 0.18);
      }
      .event-card::before {
        content: '';
        position: absolute;
        top: 0; right: 0; bottom: 0;
        width: 4px;
        border-radius: 0 2rem 2rem 0;
      }
      [dir="rtl"] .event-card::before { right: 0; left: auto; border-radius: 0 2rem 2rem 0; }
      [dir="ltr"] .event-card::before { left: 0; right: auto; border-radius: 2rem 0 0 2rem; }
      .event-card.card-major::before  { background: linear-gradient(180deg,#3b82f6,#1d4ed8); }
      .event-card.card-fast::before   { background: linear-gradient(180deg,#f43f5e,#be123c); }
      .event-card.card-moon::before   { background: linear-gradient(180deg,#a855f7,#7e22ce); }
      .event-card.card-rosh-chodesh::before { background: linear-gradient(180deg,#10b981,#059669); }
      .event-card.card-minor::before  { background: linear-gradient(180deg,#94a3b8,#64748b); }

      /* ── Countdown Strip ── */
      #shabbat-countdown-bar {
        background: linear-gradient(90deg, rgba(232,193,90,0.05) 0%, rgba(255,255,255,0.10) 50%, rgba(232,193,90,0.05) 100%);
        border: 1px solid rgba(232, 193, 90, 0.28);
        border-radius: 999px;
        padding: 0.75rem 1.75rem;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.75rem;
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.10);
        transition: border-color 0.3s ease, box-shadow 0.3s ease;
      }
      #shabbat-countdown-wrap:hover #shabbat-countdown-bar {
        border-color: rgba(232, 193, 90, 0.5);
        box-shadow: 0 6px 30px rgba(0, 0, 0, 0.3), 0 0 24px rgba(232, 193, 90, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.12);
      }
      @keyframes gold-breathe {
        0%, 100% { text-shadow: 0 0 14px rgba(232, 193, 90, 0.25); }
        50% { text-shadow: 0 0 28px rgba(232, 193, 90, 0.55); }
      }
      .countdown-digit {
        font-variant-numeric: tabular-nums;
        font-feature-settings: "tnum";
        letter-spacing: 0.04em;
        color: #fdf3d0;
        font-weight: 900;
        font-size: 1.4rem;
        animation: gold-breathe 3.5s ease-in-out infinite;
      }

      /* ── Omer Ring ── */
      .omer-ring-container {
        position: relative;
        width: 96px;
        height: 96px;
        flex-shrink: 0;
      }
      .omer-ring-svg {
        transform: rotate(-90deg);
      }
      .omer-ring-bg { fill: none; stroke: rgba(255,255,255,0.15); stroke-width: 6; }
      .omer-ring-progress {
        fill: none;
        stroke: #f2d98a;
        stroke-width: 6;
        stroke-linecap: round;
        transition: stroke-dashoffset 1.2s cubic-bezier(0.4, 0, 0.2, 1);
        filter: drop-shadow(0 0 8px rgba(232, 193, 90, 0.55));
      }
      .omer-ring-text {
        position: absolute;
        inset: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        color: #fff;
      }

      /* ── Zmanim Day Bar ── */
      #zmanim-day-bar {
        height: 6px;
        background: rgba(255,255,255,0.1);
        border-radius: 3px;
        overflow: hidden;
        margin-bottom: 1rem;
      }
      #zmanim-day-bar-fill {
        height: 100%;
        background: linear-gradient(90deg, #60a5fa, #f2d98a);
        border-radius: 3px;
        transition: width 1s ease;
        box-shadow: 0 0 10px rgba(232, 193, 90, 0.4);
      }

      /* ── Toast Notifications ── */
      #toast-container {
        position: fixed;
        bottom: 5rem;
        left: 50%;
        transform: translateX(-50%);
        z-index: 9999;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
        pointer-events: none;
      }
      .toast {
        pointer-events: auto;
        padding: 0.75rem 1.5rem;
        border-radius: 1rem;
        font-weight: 700;
        font-size: 0.9rem;
        color: white;
        opacity: 0;
        transform: translateY(12px) scale(0.95);
        transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
        max-width: 90vw;
        text-align: center;
        backdrop-filter: blur(12px);
        box-shadow: 0 8px 32px rgba(0,0,0,0.25);
      }
      .toast.show {
        opacity: 1;
        transform: translateY(0) scale(1);
      }
      .toast.toast-success { background: linear-gradient(135deg, #059669, #10b981); }
      .toast.toast-error   { background: linear-gradient(135deg, #be123c, #f43f5e); }
      .toast.toast-info    { background: linear-gradient(135deg, #1d4ed8, #3b82f6); }

      /* ── Skeleton Loader ── */
      @keyframes skeleton-pulse {
        0%, 100% { opacity: 0.5; }
        50% { opacity: 1; }
      }
      .skeleton { animation: skeleton-pulse 1.5s ease-in-out infinite; background: rgba(255,255,255,0.08); border-radius: 0.5rem; }

      /* ── Wave Divider ── */
      .wave-divider {
        position: absolute;
        bottom: -2px;
        left: 0; right: 0;
        overflow: hidden;
        line-height: 0;
      }
      .wave-divider svg { display: block; width: 100%; }
      .notification-toggle-row {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        min-width: 8.5rem;
        flex-shrink: 0;
        justify-content: flex-end;
      }
      #notif-master-status {
        min-width: 4.75rem;
        text-align: center;
        white-space: nowrap;
      }
      #notif-master-toggle {
        direction: ltr;
      }
      html[dir="rtl"] .notification-toggle-row {
        flex-direction: row-reverse;
      }
      html[dir="ltr"] .notification-toggle-row {
        flex-direction: row;
      }
      .loader {
        border: 4px solid rgba(255, 255, 255, 0.1);
        border-top: 4px solid #e0b74f;
        border-radius: 50%;
        width: 40px;
        height: 40px;
        animation: spin 1s linear infinite;
        margin: 0 auto;
      }
      @keyframes spin {
        0% {
          transform: rotate(0deg);
        }
        100% {
          transform: rotate(360deg);
        }
      }
      .scrollbar-hide::-webkit-scrollbar {
        display: none;
      }
      .scrollbar-hide {
        -ms-overflow-style: none;
        scrollbar-width: none;
      }
      html[dir="ltr"] #settings-modal-title {
        padding-left: 3.5rem;
      }
      select option {
        background-color: #1e293b;
        color: white;
      }
      .cal-grid {
        display: grid;
        grid-template-columns: repeat(7, 1fr);
        gap: 3px;
        width: 100%;
        min-width: 0;
      }
      @media (max-width: 640px) {
        .cal-grid { gap: 2px; }
      }
      .cal-header {
        text-align: center;
        font-weight: bold;
        font-size: 0.85rem;
        padding-bottom: 0.5rem;
      }
      .gradient-bg {
        background:
          radial-gradient(ellipse 120% 70% at 50% -10%, rgba(232, 193, 90, 0.07) 0%, transparent 55%),
          radial-gradient(ellipse 90% 60% at 85% 100%, rgba(49, 46, 129, 0.35) 0%, transparent 60%),
          linear-gradient(160deg, #050b1a 0%, #0c1530 45%, #16233f 100%);
      }
      .compass-ring {
        background: radial-gradient(
          circle,
          transparent 50%,
          rgba(255, 255, 255, 0.05) 50%
        );
      }
      .compass-direction-label {
        position: absolute;
        z-index: 20;
        color: rgba(191, 219, 254, 0.95);
        font-weight: 800;
        font-size: 0.8rem;
        line-height: 1;
        text-shadow: 0 0 12px rgba(15, 23, 42, 0.75);
        pointer-events: none;
        user-select: none;
      }
      .compass-direction-n {
        top: 0;
        left: 50%;
        transform: translateX(-50%);
      }
      .compass-direction-e {
        right: 0;
        top: 50%;
        transform: translateY(-50%);
      }
      .compass-direction-s {
        bottom: 0;
        left: 50%;
        transform: translateX(-50%);
      }
      .compass-direction-w {
        left: 0;
        top: 50%;
        transform: translateY(-50%);
      }

      /* ── Font size scaling ── */
      html.fs-1 { font-size: 108% !important; }
      html.fs-2 { font-size: 116% !important; }
      html.fs-3 { font-size: 130% !important; }
      html.fs-4 { font-size: 150% !important; }
      /* Prevent card overflow on larger font */
      html.fs-1 .zman-card, html.fs-2 .zman-card,
      html.fs-3 .zman-card, html.fs-4 .zman-card { overflow: hidden; }

      /* ── Prayer Grid ── */
      .prayer-btn {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 0.35rem;
        background: linear-gradient(165deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.03) 100%);
        border: 1px solid rgba(255,255,255,0.12);
        border-radius: 1.25rem;
        padding: 0.75rem 0.5rem;
        cursor: pointer;
        transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
        color: white;
        min-height: 72px;
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
      }
      .prayer-btn:hover {
        background: linear-gradient(165deg, rgba(232,193,90,0.16) 0%, rgba(30,58,138,0.28) 100%);
        border-color: rgba(232, 193, 90, 0.45);
        transform: translateY(-2px);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28), 0 0 18px rgba(232, 193, 90, 0.10);
      }
      .prayer-btn:active {
        transform: translateY(0) scale(0.98);
      }
      .prayer-icon {
        font-size: 1.4rem;
        line-height: 1;
        transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
      }
      .prayer-btn:hover .prayer-icon { transform: scale(1.18); }
      .prayer-label {
        font-size: 0.7rem;
        font-weight: 700;
        text-align: center;
        line-height: 1.2;
        color: rgba(226,232,240,0.9);
      }
      @media (min-width: 768px) {
        .prayer-label { font-size: 0.8rem; }
        .prayer-icon  { font-size: 1.6rem; }
      }

      /* ── Sefaria Reader Styles ── */
      #sefaria-modal-content p {
        font-size: 0.74em;
        margin-bottom: 1rem;
        color: inherit;
      }
      #sefaria-modal-content .text-left {
        text-align: left;
        direction: ltr;
      }

      /* ── Zmanim Card Hover ── */
      .zman-card {
        transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
      }
      .zman-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgba(0,0,0,0.25);
      }
      /* FAB scroll-to-top: desktop only */
      @media (max-width: 767px) {
        #fab-top { display: none !important; }
      }
      /* Scroll-to-top (white): mobile only */
      @media (min-width: 768px) {
        #scroll-top-btn { display: none !important; }
      }
      /* Al-HaMichya (ברכת מעין שלוש) — on mobile, move "של א״י ועל מחיתה ועל כלכלתה" to its own line so it fits inside the supplement box */
      @media (max-width: 767px) {
        .al-hamichya-shel-ai-line {
          font-size: 0.85em;
        }
        .al-hamichya-shel-ai-line .al-hamichya-shel-ai-wrap {
          display: block;
          margin-top: 0.3em;
        }
      }
      /* בכפתור "בתי כנסת מקוואות וציוני צדיקים באזורך" — keep on a single line on mobile, same button size, by shrinking the text. */
      #btn-shul-mikve span { white-space: nowrap; }
      @media (max-width: 480px) {
        #btn-shul-mikve span { font-size: 0.80rem; }
      }
      @media (max-width: 380px) {
        #btn-shul-mikve span { font-size: 0.70rem; }
      }
      @media (max-width: 340px) {
        #btn-shul-mikve span { font-size: 0.62rem; }
      }

      /* ── Hero stat cards pulse on load ── */
      @keyframes fadeSlideUp {
        from { opacity: 0; transform: translateY(16px); }
        to   { opacity: 1; transform: translateY(0); }
      }
      #dashboard-state article {
        animation: fadeSlideUp 0.5s ease forwards;
      }
      #dashboard-state article:nth-child(1) { animation-delay: 0.05s; }
      #dashboard-state article:nth-child(2) { animation-delay: 0.12s; }
      #dashboard-state article:nth-child(3) { animation-delay: 0.19s; }
      #dashboard-state article:nth-child(4) { animation-delay: 0.26s; }
      #dashboard-state article {
        min-height: 132px;
      }
      .dashboard-shabbat-line {
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 0.32rem;
        margin-bottom: 0.24rem;
        direction: rtl;
      }
      .dashboard-shabbat-line:last-child {
        margin-bottom: 0;
      }
      .dashboard-shabbat-label {
        color: rgba(191, 219, 254, 0.72);
        font-size: 0.82rem;
        font-weight: 800;
        white-space: nowrap;
      }
      .dashboard-shabbat-value {
        color: #fff;
        font-size: 0.95rem;
        font-weight: 900;
        line-height: 1.1;
        letter-spacing: 0.01em;
      }
      .dashboard-card-title-tight {
        margin-bottom: 0.35rem;
      }
      .dashboard-card-meta-tight {
        margin-top: 0.28rem;
      }
      .zman-meta {
        display: block;
        margin-top: 0.35rem;
        color: rgba(191, 219, 254, 0.68);
        font-size: 0.72rem;
        font-weight: 700;
        line-height: 1.35;
      }
      .prayer-richtext h2,
      .prayer-richtext h3,
      .prayer-richtext h4 {
        color: #000000;
        font-weight: 900;
        margin: 1rem 0 0.45rem;
      }
      .prayer-richtext p,
      .prayer-richtext li {
        color: #000000;
        line-height: 2.02;
        overflow-wrap: anywhere;
      }
      .prayer-richtext ul,
      .prayer-richtext ol {
        margin: 0.75rem 0;
        padding-inline-start: 1.4rem;
      }
      .prayer-richtext a {
        color: #1d4ed8;
        text-decoration: underline;
      }
      .prayer-richtext .seasonal-block {
        background: rgba(59, 130, 246, 0.06);
        border: 1px solid rgba(59, 130, 246, 0.18);
        border-radius: 0.85rem;
        padding: 0.7rem 0.85rem;
        margin-bottom: 0.75rem;
        font-size: 0.82em;
        color: #1e40af;
        line-height: 1.65;
        position: relative;
      }
      .prayer-richtext .seasonal-block::before {
        content: "";
        display: block;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(59,130,246,0.3), transparent);
        margin-bottom: 0.6rem;
      }
      .prayer-richtext .seasonal-block::after {
        content: "";
        display: block;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(59,130,246,0.3), transparent);
        margin-top: 0.6rem;
      }
      /* Supplement/addition styling for prayer texts */
      .prayer-supplement {
        color: #1e40af;
        font-size: 0.60em;
        line-height: 1.65;
        background: rgba(59,130,246,0.04);
        border: 1px solid rgba(59,130,246,0.14);
        border-right: 3px solid rgba(37,99,235,0.35);
        border-radius: 0.6rem;
        padding: 0.55rem 0.75rem;
        margin: 0.6rem 0;
        display: block;
      }
      .prayer-supplement p,
      .prayer-supplement li {
        color: #1e40af !important;
        line-height: 1.65 !important;
      }
      .prayer-supplement strong {
        color: #1e3a8a;
      }
      .prayer-richtext .seasonal-block strong {
        color: #1d4ed8;
        font-size: 0.9em;
      }
      .prayer-richtext .seasonal-block div {
        color: #2563eb;
      }
      .prayer-richtext .prayer-divider {
        border: 0;
        border-top: 1px solid rgba(148, 163, 184, 0.35);
        margin: 1.35rem 0;
      }
      @media (max-width: 767px) {
        #dashboard-state article {
          min-height: 114px;
        }
        .dashboard-shabbat-label {
          font-size: 0.72rem;
        }
        .dashboard-shabbat-value {
          font-size: 0.9rem;
        }
      }

      /* ── Mobile: shnayim-mikra & daf-yomi same size ── */
      @media (max-width: 767px) {
        #halacha-banner .flex-row {
          flex-direction: column;
          align-items: stretch;
          gap: 0.5rem;
        }
        #shnayim-mikra-link,
        #daf-yomi-link {
          width: 100%;
          box-sizing: border-box;
        }
        #shnayim-mikra-link .shnayim-parsha-suffix {
          display: none;
        }
      }

      /* ── Footer credits ── */
      footer a:hover {
        background: linear-gradient(135deg, rgba(37,99,235,0.08), rgba(139,92,246,0.08));
      }

      /* ── Calendar day hover ── */
      #cal-days-grid > div:not([aria-hidden]) {
        transition: all 0.2s ease;
        cursor: pointer;
      }
      #cal-days-grid > div:not([aria-hidden]):hover {
        transform: scale(1.05);
        box-shadow: 0 6px 18px rgba(0,0,0,0.14), 0 0 0 2px rgba(224, 183, 79, 0.55);
        z-index: 2;
      }

      /* ── Scrollbar Styling ── */
      ::-webkit-scrollbar { width: 6px; height: 6px; }
      ::-webkit-scrollbar-track { background: transparent; }
      ::-webkit-scrollbar-thumb { background: rgba(180, 150, 80, 0.35); border-radius: 3px; }
      ::-webkit-scrollbar-thumb:hover { background: rgba(200, 165, 90, 0.55); }

      /* ── Theme circle (settings panel) ── */
      .theme-circle {
        cursor: pointer;
        position: relative;
      }
      .theme-circle.theme-circle-active {
        border-color: #e0b74f !important;
        box-shadow: 0 0 0 3px rgba(224,183,79,0.4), 0 4px 14px rgba(224,183,79,0.3);
        transform: scale(1.08);
      }

      /* ── Contact-modal copy toast animation ── */
      @keyframes fadeInOut {
        0%   { opacity: 0; transform: translate(-50%, -50%) scale(0.92); }
        15%  { opacity: 1; transform: translate(-50%, -50%) scale(1); }
        85%  { opacity: 1; transform: translate(-50%, -50%) scale(1); }
        100% { opacity: 0; transform: translate(-50%, -50%) scale(0.92); }
      }

      /* ── Scroll-snap for fast scroll: stops at every section/chapter/parsha ── */
      /* Scroll containers — wherever scrollable content lives */
      #sn-reader-content,
      #bih-content-area,
      #psalm-text-area,
      #shir-scroll-area,
      #sefaria-modal-content,
      #chok-israel-modal-content,
      #prayer-modal .modal-body,
      #prayer-modal-body,
      #prayer-modal-body .holy-text-style {
        scroll-snap-type: none; /* בוטל - הסנפ היה גורם להתקעות ולקפיצות בגלילה אוטומטית וידנית. שאר הסלקטורים נשארים לנוחות החזרה */
        scroll-padding-top: 0.5rem;
        -webkit-overflow-scrolling: touch;
      }
      /* Snap points — target meaningful section breaks */
      /* Sefarim Nosafim reader — each chapter div */
      #sn-reader-content > div,
      /* Ben Ish Hai — section headings */
      #bih-content-area h2,
      #bih-content-area h3,
      /* Tehillim — each chapter (both heading + chapter wrapper) */
      #psalm-text-area h4,
      #psalm-text-area > div[id^="psalm-chapter-"],
      /* Shir HaShirim — each chapter wrapper */
      #shir-scroll-area .shir-chapter,
      /* Prayer modal — simple (markdown bold) section headers */
      #prayer-modal .modal-body strong,
      /* Prayer-richtext rendering (Shacharit/Mincha/Maariv/Birchot Hashachar/etc.) */
      .prayer-richtext h2,
      .prayer-richtext h3,
      .prayer-richtext hr.prayer-divider,
      .prayer-richtext > p:has(> big > b),
      /* Chok LeIsrael — each source block */
      #chok-israel-modal-content > div,
      /* Sefaria modal — each paragraph */
      #sefaria-modal-content > p {
        scroll-snap-align: start;
        scroll-snap-stop: normal; /* normal (לא forced) */
      }

      /* ── Pulse highlight for "תפילות נוספות" & "ספרים נוספים" buttons ── */
      @keyframes prayer-cta-pulse {
        0%, 100% {
          box-shadow: 0 0 0 0 rgba(251,191,36,0.55),
                      0 6px 18px rgba(251,191,36,0.25),
                      inset 0 0 0 1.5px rgba(251,191,36,0.55);
          transform: scale(1);
        }
        50% {
          box-shadow: 0 0 0 12px rgba(251,191,36,0),
                      0 6px 18px rgba(251,191,36,0.40),
                      inset 0 0 0 1.5px rgba(251,191,36,0.85);
          transform: scale(1.025);
        }
      }
      .prayer-btn.prayer-cta-highlight {
        animation: prayer-cta-pulse 2.4s ease-in-out infinite;
        position: relative;
      }
      .prayer-btn.prayer-cta-highlight .prayer-label {
        color: #fde68a !important;
        font-weight: 800;
      }

      /* ── Pulse for the small chevron "more prayers" button ── */
      @keyframes chevron-cta-pulse {
        0%, 100% {
          background-color: rgba(251,191,36,0.12);
          border-color: rgba(251,191,36,0.40);
          color: rgb(254,243,199);
          box-shadow: 0 0 0 0 rgba(251,191,36,0.45);
        }
        50% {
          background-color: rgba(251,191,36,0.22);
          border-color: rgba(251,191,36,0.65);
          color: rgb(253,224,71);
          box-shadow: 0 0 0 7px rgba(251,191,36,0);
        }
      }
      #prayer-more-btn.chevron-cta-pulse {
        animation: chevron-cta-pulse 2.2s ease-in-out infinite;
      }


/* ── ברכת הלבנה: הדגשות, פס סימן טוב, הבהוב סמל וכפתור "ברכתי" ── */
.levana-siman-tov-box {
  border-right: 4px solid #f59e0b;
  background: rgba(245, 158, 11, 0.08);
  padding: 0.35rem 0.9rem 0.35rem 0.35rem;
  margin: 0.85rem 0;
  border-radius: 0.9rem 0.25rem 0.25rem 0.9rem;
}
.levana-repeat-note {
  color: #b45309 !important;
  font-weight: 800 !important;
}
.levana-times-badge {
  color: #b45309 !important;
  font-weight: 800;
  background: rgba(245, 158, 11, 0.18);
  border-radius: 0.5rem;
  padding: 0 0.4rem;
}
.levana-phrase-david {
  color: #6d28d9 !important;
  font-weight: 700;
}
.levana-phrase-lev {
  color: #0d9488 !important;
}
.levana-blessed-wrap {
  text-align: center;
  margin: 1.6rem 0 0.6rem;
}
.levana-blessed-btn {
  background: linear-gradient(135deg, #7c3aed, #4f46e5);
  color: #fff;
  border: none;
  border-radius: 1rem;
  font-weight: 800;
  font-size: 1.05rem;
  font-family: inherit;
  padding: 0.8rem 2.2rem;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(124, 58, 237, 0.35);
  transition: transform 0.15s ease;
}
.levana-blessed-btn:hover { transform: scale(1.04); }
.levana-blessed-btn.blessed {
  background: #10b981;
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.35);
}
.levana-blessed-note {
  color: #94a3b8;
  font-size: 0.72rem;
  margin-top: 0.45rem;
}
@keyframes levana-blink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.3; transform: scale(0.88); }
}
.levana-blinking {
  display: inline-block;
  animation: levana-blink 1.1s ease-in-out infinite;
}
/* ── דף יומי: סימון שורה במרקר (צהוב בהיר) ── */
.daf-line-marked {
  background: linear-gradient(to bottom, transparent 8%, rgba(254, 240, 138, 0.55) 8%, rgba(254, 240, 138, 0.55) 88%, transparent 88%);
  border-radius: 4px;
  box-shadow: 0 0 0 3px rgba(254, 240, 138, 0.2);
}
/* ── מרקר אוניברסלי — סימון שורה בכל הספרים והתפילות ── */
.lux-mark-hl {
  background: linear-gradient(to bottom, transparent 6%, rgba(254, 240, 138, 0.55) 6%, rgba(254, 240, 138, 0.55) 90%, transparent 90%) !important;
  border-radius: 5px;
  box-shadow: 0 0 0 3px rgba(254, 240, 138, 0.2);
}
.lux-night .lux-mark-hl {
  background: linear-gradient(to bottom, transparent 6%, rgba(202, 138, 4, 0.4) 6%, rgba(202, 138, 4, 0.4) 90%, transparent 90%) !important;
}
/* ── אחידות גדלי אותיות בטקסטים (תפילות, ספרים, דף יומי, חוק לישראל) ──
   טקסטים מ-Sefaria מגיעים עם תגי big/small מקוננים שיוצרים אותיות ענק/זעירות.
   כאן מנרמלים: big קבוע ועדין, ומניעת הצטברות בקינון. ── */
.holy-text-style big,
.prayer-richtext big,
#sefaria-modal-content big,
#chok-israel-modal-content big,
#sn-reader-area big,
#bih-content-area big,
#psalm-text-area big {
  font-size: 1.12em;
}
.holy-text-style big big,
.prayer-richtext big big,
#sefaria-modal-content big big,
#chok-israel-modal-content big big,
#sn-reader-area big big,
#bih-content-area big big,
#psalm-text-area big big {
  font-size: 1em;
}
.holy-text-style small,
.prayer-richtext small,
#sefaria-modal-content small,
#chok-israel-modal-content small,
#sn-reader-area small,
#bih-content-area small,
#psalm-text-area small {
  font-size: 0.8em;
}
/* קינון כפול של small — לא מקטינים שוב לגודל בלתי-קריא */
.holy-text-style small small,
.prayer-richtext small small,
#sefaria-modal-content small small,
#chok-israel-modal-content small small,
#sn-reader-area small small,
#bih-content-area small small,
#psalm-text-area small small {
  font-size: 0.95em;
}

/* ═══════════════════════════════════════════════════════════════════
   ROYAL NIGHT & GOLD — שכבת עיצוב יוקרתית
   שכבה ויזואלית בלבד: אינה משנה התנהגות, רק מראה.
   ═══════════════════════════════════════════════════════════════════ */
:root {
  --lux-gold-100: #fdf3d0;
  --lux-gold-200: #f7e6ab;
  --lux-gold-300: #f2d98a;
  --lux-gold-400: #e0b74f;
  --lux-gold-500: #c9993a;
  --lux-gold-600: #a1762a;
  --lux-navy-700: #1e3a8a;
  --lux-navy-800: #14275e;
  --lux-navy-900: #0c1530;
  --lux-navy-950: #050b1a;
  --lux-paper: #faf8f3;
  --lux-serif: "Frank Ruhl Libre", "David Libre", serif;
  --lux-hairline: rgba(200, 155, 60, 0.28);
  --lux-hairline-strong: rgba(212, 168, 66, 0.5);
}

/* ── בסיס: בחירת טקסט, פוקוס ── */
::selection {
  background: rgba(224, 183, 79, 0.35);
  color: inherit;
}
:focus-visible {
  outline: 2px solid rgba(224, 183, 79, 0.75);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ── עיטור זהב מתחת לכותרת ── */
.hero-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  margin: -0.5rem auto 1.5rem;
  max-width: 22rem;
  opacity: 0.9;
}
.hero-ornament svg {
  filter: drop-shadow(0 0 8px rgba(224, 183, 79, 0.45));
  flex-shrink: 0;
}
.hero-ornament-line {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, rgba(224, 183, 79, 0.65), transparent);
}

/* ── רקע שנהב חם למצב בהיר ── */
html:not(.dark) body {
  background-color: #f6f3ea !important;
  background-image:
    radial-gradient(ellipse 90% 40% at 50% 0%, rgba(200, 155, 60, 0.055) 0%, transparent 60%);
  /* בלי background-attachment: fixed — בנייד זה גרר repaint של כל הרקע בכל נעילת פופאפ */
}

/* ── תיבת חיפוש — פינות מעודנות + זכוכית מגדלת בזהב ── */
#mainSearch {
  border-radius: 999px !important;
}
nav[aria-label="סינון וחיפוש"] > div.relative > svg {
  color: #c9993a !important;
}

/* ── כפתור נוסח הברכה בסקשן העומר ── */
#omer-container button {
  border-color: rgba(232, 193, 90, 0.5) !important;
  transition: all 0.25s ease !important;
}
#omer-container button:hover {
  background: rgba(232, 193, 90, 0.2) !important;
  border-color: rgba(242, 217, 138, 0.8) !important;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3), 0 0 16px rgba(232, 193, 90, 0.2) !important;
}

/* ── כפתורי סנכרון בכרטיסי אירועים ── */
#resultsGrid .event-card button {
  transition: all 0.22s ease !important;
}
#resultsGrid .event-card button:hover {
  border-color: rgba(200, 155, 60, 0.55) !important;
  box-shadow: 0 4px 14px rgba(200, 155, 60, 0.18);
  transform: translateY(-1px);
}

/* ── שאלות נפוצות — פתיחה בזהב ── */
details.group summary:hover {
  color: #a1762a !important;
}
details.group summary .text-blue-500 {
  color: #c9993a !important;
}
#omer-modal-title,
#settings-modal-title,
#sefaria-modal-title,
#chok-israel-modal-title,
#compass-modal-title,
#cal-month-title,
#omer-full-text {
  font-family: var(--lux-serif);
}

/* ── סרגל פעולות עליון — תמיד נראה, גם בגלילה על רקע בהיר ── */
.nav-action-btn {
  background: rgba(12, 21, 48, 0.55) !important;
  border: 1px solid rgba(232, 193, 90, 0.38) !important;
  color: #fdf3d0 !important;
  box-shadow: 0 4px 16px rgba(5, 11, 26, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12) !important;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.nav-action-btn:hover {
  background: rgba(20, 35, 78, 0.78) !important;
  border-color: rgba(242, 217, 138, 0.7) !important;
  box-shadow: 0 6px 22px rgba(5, 11, 26, 0.45), 0 0 18px rgba(232, 193, 90, 0.25) !important;
  transform: translateY(-1px) scale(1.05);
}
.nav-donate-btn {
  box-shadow: 0 4px 16px rgba(5, 11, 26, 0.35), 0 0 14px rgba(232, 193, 90, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.12) !important;
}
.nav-donate-btn:hover {
  border-color: rgba(242, 217, 138, 0.8) !important;
  box-shadow: 0 6px 22px rgba(5, 11, 26, 0.45), 0 0 22px rgba(232, 193, 90, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
  transform: translateY(-1px);
}

/* ── כפתורי CTA בהירו — לוח שנה / בתי כנסת / מוצאי שבת ── */
#btn-open-calendar,
#btn-motzei-shabbat {
  background: linear-gradient(150deg, rgba(36, 81, 184, 0.5) 0%, rgba(12, 21, 48, 0.6) 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.45) !important;
  box-shadow: 0 6px 24px rgba(5, 11, 26, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.14) !important;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
#btn-open-calendar:hover,
#btn-motzei-shabbat:hover {
  border-color: rgba(242, 217, 138, 0.8) !important;
  box-shadow: 0 10px 32px rgba(5, 11, 26, 0.5), 0 0 24px rgba(232, 193, 90, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
  transform: translateY(-2px);
}
/* בתי כנסת ומקוואות — זהב מלכותי במקום טורקיז, בהתאמה לשפת האתר */
#btn-shul-mikve {
  background: linear-gradient(150deg, rgba(224, 183, 79, 0.30) 0%, rgba(30, 58, 138, 0.42) 55%, rgba(12, 21, 48, 0.55) 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.55) !important;
  box-shadow: 0 6px 24px rgba(5, 11, 26, 0.4), 0 0 18px rgba(232, 193, 90, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.16) !important;
  color: #fdf3d0 !important;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35);
}
#btn-shul-mikve:hover {
  border-color: rgba(242, 217, 138, 0.85) !important;
  box-shadow: 0 10px 32px rgba(5, 11, 26, 0.5), 0 0 26px rgba(232, 193, 90, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

/* ── ספירה לאחור — תוויות בזהב ── */
#countdown-label,
#countdown-event-type {
  color: rgba(242, 217, 138, 0.9) !important;
}

/* ── קישורי הכרטיסיות בדשבורד — זהב ── */
#dashboard-state article > div:last-child {
  color: rgba(242, 217, 138, 0.92) !important;
}

/* ── כפתורי הלכה (שנים מקרא / חוק לישראל / דף יומי / דבר תורה) ── */
#shnayim-mikra-link,
#daf-yomi-link {
  background: linear-gradient(150deg, #2451b8 0%, #16307a 100%) !important;
  border-color: rgba(147, 197, 253, 0.45) !important;
  box-shadow: 0 5px 18px rgba(22, 48, 122, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
}
#chok-israel-btn {
  background: linear-gradient(150deg, #0d9265 0%, #065f46 100%) !important;
  border-color: rgba(110, 231, 183, 0.45) !important;
  box-shadow: 0 5px 18px rgba(6, 95, 70, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
}
#month-torah-btn {
  background: linear-gradient(150deg, #8b34c9 0%, #5b21a6 100%) !important;
  border-color: rgba(216, 180, 254, 0.45) !important;
  box-shadow: 0 5px 18px rgba(91, 33, 166, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
}
#shnayim-mikra-link:hover,
#daf-yomi-link:hover,
#chok-israel-btn:hover,
#month-torah-btn:hover {
  border-color: rgba(242, 217, 138, 0.75) !important;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4), 0 0 20px rgba(232, 193, 90, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.22) !important;
  transform: translateY(-2px);
  filter: brightness(1.08);
}
#shnayim-mikra-link,
#daf-yomi-link,
#chok-israel-btn,
#month-torah-btn {
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
  border-radius: 999px !important;
}

/* ── כרטיסי זמני היום ── */
.zman-card {
  background: linear-gradient(160deg, rgba(30, 41, 90, 0.55) 0%, rgba(15, 23, 52, 0.4) 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.16) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.zman-card:hover {
  border-color: rgba(232, 193, 90, 0.55) !important;
  background: linear-gradient(160deg, rgba(37, 51, 108, 0.75) 0%, rgba(20, 30, 66, 0.6) 100%) !important;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3), 0 0 16px rgba(232, 193, 90, 0.12);
}
.zman-card > span:first-child {
  color: rgba(242, 217, 138, 0.88) !important;
}

/* ── תיבת חיפוש וסינון ── */
nav[aria-label="סינון וחיפוש"] {
  position: relative;
  overflow: hidden;
  border-radius: 2rem !important;
  box-shadow:
    0 24px 60px -18px rgba(15, 23, 42, 0.28),
    0 0 0 1px rgba(200, 155, 60, 0.12) !important;
}
nav[aria-label="סינון וחיפוש"]::before {
  content: '';
  position: absolute;
  top: 0;
  left: 8%;
  right: 8%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(224, 183, 79, 0.75), transparent);
  pointer-events: none;
}
#mainSearch {
  transition: all 0.3s ease !important;
}
#mainSearch:focus {
  box-shadow: 0 0 0 3px rgba(224, 183, 79, 0.28), 0 6px 20px rgba(200, 155, 60, 0.12) !important;
  border-color: rgba(224, 183, 79, 0.6) !important;
}

/* ── כרטיסי אירועים — נייר יוקרה ── */
#resultsGrid .event-card {
  border-radius: 1.75rem !important;
  box-shadow:
    0 2px 6px rgba(15, 23, 42, 0.05),
    0 12px 32px -14px rgba(15, 23, 42, 0.12);
}
#resultsGrid .event-card::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 55% 120% at 100% 50%, rgba(200, 155, 60, 0.06), transparent 60%);
}
#resultsGrid .event-card h3 {
  font-family: var(--lux-serif);
  letter-spacing: 0.005em;
}
#resultsGrid .event-card:hover h3 {
  color: #a1762a !important;
}
.dark #resultsGrid .event-card:hover h3 {
  color: #f2d98a !important;
}
/* אריח האייקון בכרטיס — עומק וזהב עדין */
#resultsGrid .event-card > div:first-child > div:first-child {
  border-radius: 1.25rem !important;
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.10), inset 0 1px 0 rgba(255, 255, 255, 0.8) !important;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.dark #resultsGrid .event-card > div:first-child > div:first-child {
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
}
#resultsGrid .event-card:hover > div:first-child > div:first-child {
  transform: scale(1.08) rotate(-3deg);
}

/* ── כרטיסיות הדשבורד — כותרות עדינות ── */
#dashboard-state .dashboard-card-title-tight {
  color: rgba(242, 217, 138, 0.85) !important;
  letter-spacing: 0.14em;
}

/* ── זמני היום: כותרת ── */
#halacha-banner h2[data-i18n-key="zmanim"] {
  font-family: var(--lux-serif);
  color: var(--lux-gold-300);
  font-size: 1.05rem;
  letter-spacing: 0.22em;
}

/* ── מודאל הגדרות ── */
#settings-modal > div {
  border: 1px solid rgba(200, 155, 60, 0.18);
  box-shadow: 0 30px 80px -20px rgba(5, 11, 26, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.04) !important;
}
#settings-modal select:focus,
#settings-modal select:hover,
#settings-modal button[onclick="openPrayerOrderEditor()"]:hover {
  border-color: rgba(224, 183, 79, 0.55) !important;
  box-shadow: 0 0 0 3px rgba(224, 183, 79, 0.18);
}
#settings-modal button[onclick="saveSettings()"] {
  background: linear-gradient(135deg, #1e3a8a 0%, #172554 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.4);
  color: #fdf3d0 !important;
  box-shadow: 0 8px 24px rgba(23, 37, 84, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  transition: all 0.25s ease !important;
}
#settings-modal button[onclick="saveSettings()"]:hover {
  box-shadow: 0 10px 30px rgba(23, 37, 84, 0.55), 0 0 18px rgba(232, 193, 90, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transform: translateY(-1px);
}
#settings-modal input[type="range"] {
  accent-color: #e0b74f !important;
}
#settings-modal button[onclick="showContactModal()"] {
  background: linear-gradient(135deg, #f2d98a 0%, #dfb254 45%, #c9993a 100%) !important;
  color: #1a2547 !important;
  border: 1px solid rgba(161, 118, 42, 0.5);
  box-shadow: 0 6px 20px rgba(201, 153, 58, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.45) !important;
}
#settings-modal button[onclick="showContactModal()"]:hover {
  filter: brightness(1.06);
  transform: translateY(-1px);
  box-shadow: 0 8px 26px rgba(201, 153, 58, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.5) !important;
}
#settings-modal button[onclick="useGPS()"]:hover {
  box-shadow: 0 0 0 2px rgba(224, 183, 79, 0.35);
}

/* ── מודאל לוח שנה חודשי ── */
#calendar-modal > div {
  border: 1px solid rgba(200, 155, 60, 0.16);
  box-shadow: 0 40px 100px -30px rgba(5, 11, 26, 0.7) !important;
}
#calendar-modal > div > div:first-child {
  background:
    radial-gradient(ellipse 100% 120% at 50% -20%, rgba(232, 193, 90, 0.10) 0%, transparent 55%),
    linear-gradient(160deg, #0c1530 0%, #14275e 100%) !important;
  border-bottom: 1px solid rgba(232, 193, 90, 0.22);
}
#calendar-modal button[onclick="resetMonth()"] {
  background: linear-gradient(135deg, #b98a2e, #96691f) !important;
  border: 1px solid rgba(253, 243, 208, 0.25);
  color: #fffaf0 !important;
  box-shadow: 0 3px 12px rgba(150, 105, 31, 0.4);
}
#calendar-modal button[onclick="resetMonth()"]:hover {
  background: linear-gradient(135deg, #cf9c36, #a87724) !important;
}
#calendar-modal button[onclick="downloadBulkICS()"] {
  background: linear-gradient(135deg, #0d9265, #06724f) !important;
  border: 1px solid rgba(167, 243, 208, 0.35);
  box-shadow: 0 3px 12px rgba(6, 114, 79, 0.4);
}
#calendar-modal button[onclick="downloadBulkICS()"]:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 16px rgba(13, 146, 101, 0.5), 0 0 12px rgba(232, 193, 90, 0.15);
}
#cal-month-heb {
  color: var(--lux-gold-300) !important;
}

/* ── קורא ספריא / חוק לישראל — תחושת קלף ── */
#sefaria-modal,
#chok-israel-modal {
  background:
    radial-gradient(ellipse 140% 40% at 50% 0%, rgba(200, 155, 60, 0.05) 0%, transparent 60%),
    #faf8f3 !important;
}
#sefaria-modal > div:first-child,
#chok-israel-modal > div:first-child {
  background: rgba(250, 248, 243, 0.92) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(200, 155, 60, 0.25) !important;
}

/* ── מודאל עומר ── */
#omer-modal > div {
  border: 1px solid rgba(200, 155, 60, 0.2);
}

/* ── פוטר ── */
footer a {
  transition: all 0.25s ease !important;
}
footer a:hover {
  border-color: rgba(200, 155, 60, 0.5) !important;
  color: #a1762a !important;
  box-shadow: 0 4px 14px rgba(200, 155, 60, 0.12);
  transform: translateY(-1px);
}
.dark footer a:hover {
  color: #f2d98a !important;
  border-color: rgba(232, 193, 90, 0.4) !important;
}

/* ── טוסטים ── */
.toast {
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* ═══ פופאפים דינמיים (נבנים ב-JS) — ליטוש יוקרתי ═══ */

/* תפילות — מודאל כהה */
#prayer-modal .modal-inner {
  border-color: rgba(232, 193, 90, 0.30) !important;
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.65),
    0 0 0 1px rgba(255, 255, 255, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.07) !important;
}
#prayer-modal .modal-title {
  font-family: var(--lux-serif) !important;
}

/* שבת/חג — פרטים */
#shabbat-info-modal > div,
#motzei-shabbat-modal > div {
  background:
    radial-gradient(ellipse 130% 60% at 50% -10%, rgba(232, 193, 90, 0.10) 0%, transparent 55%),
    linear-gradient(150deg, #14275e 0%, #0c1530 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.30) !important;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
}

/* דעות בזמנים */
#zman-opinions-modal > div {
  background:
    radial-gradient(ellipse 130% 60% at 50% -10%, rgba(232, 193, 90, 0.08) 0%, transparent 55%),
    linear-gradient(150deg, #16224a 0%, #0c1530 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.28) !important;
}

/* תרומה */
#donation-modal > div {
  background:
    radial-gradient(ellipse 130% 60% at 50% -10%, rgba(232, 193, 90, 0.12) 0%, transparent 55%),
    linear-gradient(160deg, #171d3d 0%, #0c1226 100%) !important;
  border: 1.5px solid rgba(232, 193, 90, 0.45) !important;
}

/* מודאלים על נייר קלף (נוסח/יצירת קשר/פרטי יום) */
#nusach-selection-modal > div,
#contact-modal > div,
#calendar-day-modal > div {
  background:
    radial-gradient(ellipse 140% 50% at 50% 0%, rgba(200, 155, 60, 0.06) 0%, transparent 60%),
    #faf8f3 !important;
  border: 1px solid rgba(200, 155, 60, 0.25) !important;
  box-shadow: 0 30px 80px rgba(5, 11, 26, 0.35) !important;
}

/* קוראי ספרים במסך מלא — כותרות בגופן ספר */
#tehillim-modal h2,
#sn-modal h2,
#ben-ish-hai-modal h2,
#prayer-modal h2,
#prayer-modal h3.modal-title,
#hilulot-modal h3,
#moad-torah-modal h3 {
  font-family: var(--lux-serif) !important;
}

/* ── ספרים נוספים / תפילות נוספות — ספריית קודש ── */
#sn-modal [id$="-view"] > div:first-child {
  border-bottom-color: rgba(232, 193, 90, 0.20) !important;
}
#sn-books-grid button,
#sn-subbook-grid button,
#sn-sections-grid button {
  border-color: rgba(232, 193, 90, 0.16) !important;
  transition: all 0.2s ease !important;
}
#sn-books-grid button:hover,
#sn-subbook-grid button:hover,
#sn-sections-grid button:hover {
  border-color: rgba(232, 193, 90, 0.45) !important;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), 0 0 12px rgba(232, 193, 90, 0.10);
}

/* ── מודאל מצפן ── */
#compass-modal > div {
  border-color: rgba(232, 193, 90, 0.22) !important;
  background:
    radial-gradient(ellipse 130% 60% at 50% -10%, rgba(232, 193, 90, 0.07) 0%, transparent 55%),
    linear-gradient(160deg, #16224a 0%, #0c1530 100%) !important;
}

/* ── כפתור חזרה למעלה (דסקטופ) ── */
#fab-top {
  background: linear-gradient(135deg, #1e3a8a, #14275e) !important;
  border: 1px solid rgba(232, 193, 90, 0.4) !important;
  box-shadow: 0 4px 20px rgba(12, 21, 48, 0.55), 0 0 14px rgba(232, 193, 90, 0.12) !important;
}

/* ── באנר התקנת אפליקציה ── */
#pwa-install-banner > div {
  background:
    radial-gradient(ellipse 130% 70% at 50% -10%, rgba(232, 193, 90, 0.12) 0%, transparent 55%),
    linear-gradient(150deg, #14275e 0%, #0c1530 100%) !important;
  border: 1px solid rgba(232, 193, 90, 0.35) !important;
  box-shadow: 0 12px 44px rgba(5, 11, 26, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
}

/* ── כפתור "בתי כנסת מקוואות" — ליטוש ── */
#btn-shul-mikve {
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* ═══════════════════════════════════════════════════════════════════
   LUX EXPERIENCE LAYER — פתיח, ניווט תחתון, שמיים חיים, מצבי קריאה
   ═══════════════════════════════════════════════════════════════════ */

/* ── מסך פתיחה קולנועי ── */
#lux-splash {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(ellipse 120% 70% at 50% -10%, rgba(232, 193, 90, 0.08) 0%, transparent 55%),
    linear-gradient(160deg, #050b1a 0%, #0c1530 55%, #16233f 100%);
  opacity: 1;
  transition: opacity 0.7s ease;
  cursor: pointer;
}
#lux-splash.lux-splash-out {
  opacity: 0;
  pointer-events: none;
}
.lux-splash-inner {
  text-align: center;
  padding: 1rem;
}
.lux-splash-star {
  width: clamp(72px, 18vw, 110px);
  height: auto;
  margin: 0 auto 1.1rem;
  display: block;
}
.lux-splash-path {
  stroke: #e0b74f;
  stroke-dasharray: 720;
  stroke-dashoffset: 720;
  animation: lux-draw 1.1s ease forwards;
  filter: drop-shadow(0 0 10px rgba(224, 183, 79, 0.5));
}
.lux-splash-path2 {
  animation-delay: 0.25s;
}
@keyframes lux-draw {
  to { stroke-dashoffset: 0; }
}
.lux-splash-title {
  color: #fdf3d0;
  font-family: var(--lux-serif);
  font-weight: 900;
  font-size: clamp(1.6rem, 6vw, 2.4rem);
  letter-spacing: 0.02em;
  opacity: 0;
  transform: translateY(10px);
  animation: lux-rise 0.7s ease 0.5s forwards;
  text-shadow: 0 0 30px rgba(232, 193, 90, 0.35);
}
.lux-splash-sub {
  color: rgba(191, 219, 254, 0.65);
  font-size: clamp(0.72rem, 3vw, 0.85rem);
  font-weight: 600;
  letter-spacing: 0.18em;
  margin-top: 0.5rem;
  opacity: 0;
  animation: lux-rise 0.7s ease 0.8s forwards;
}
@keyframes lux-rise {
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .lux-splash-path { animation-duration: 0.01s; }
  .lux-splash-title, .lux-splash-sub { animation-duration: 0.01s; animation-delay: 0s; }
}

/* ── ניווט תחתון — מובייל בלבד ── */
#lux-bottom-nav,
#lux-bottom-nav:empty {
  display: none;
}
/* כשההגדרות בסרגל התחתון — אין צורך בגלגל השיניים העליון במובייל */
@media (max-width: 767px) {
  body.lux-nav-has-settings div[role="toolbar"] button[aria-label="הגדרות"] {
    display: none !important;
  }
}

/* ── עורך סרגל הניווט ── */
#lux-nav-editor {
  position: fixed;
  inset: 0;
  z-index: 10090;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  direction: rtl;
}
.lux-ne-inner {
  width: min(100%, 430px);
  max-height: min(86vh, 700px);
  overflow-y: auto;
  background:
    radial-gradient(ellipse 140% 50% at 50% 0%, rgba(200, 155, 60, 0.06) 0%, transparent 60%),
    #faf8f3;
  border: 1px solid rgba(200, 155, 60, 0.3);
  border-radius: 1.5rem;
  padding: 1.4rem 1.2rem 1.1rem;
  box-shadow: 0 30px 80px rgba(5, 11, 26, 0.45);
  text-align: center;
}
.lux-ne-title {
  margin: 0 0 0.3rem;
  color: #0f172a;
  font-size: 1.2rem;
  font-weight: 900;
  font-family: var(--lux-serif);
}
.lux-ne-note {
  margin: 0 0 1rem;
  color: #64748b;
  font-size: 0.82rem;
}
.lux-ne-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-bottom: 1.1rem;
}
@media (max-width: 380px) {
  .lux-ne-grid { grid-template-columns: repeat(2, 1fr); }
}
.lux-ne-chip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  min-height: 64px;
  padding: 0.5rem 0.3rem;
  background: #fff;
  border: 1.5px solid rgba(148, 163, 184, 0.4);
  border-radius: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.lux-ne-chip:hover {
  border-color: rgba(200, 155, 60, 0.55);
}
.lux-ne-chip.lux-ne-on {
  background: linear-gradient(165deg, #fdf9ec 0%, #f6eed7 100%);
  border-color: rgba(200, 155, 60, 0.7);
  box-shadow: 0 0 0 2px rgba(224, 183, 79, 0.25), 0 4px 12px rgba(200, 155, 60, 0.18);
}
.lux-ne-num {
  position: absolute;
  top: -7px;
  right: -7px;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #1a2547;
  font-size: 0.68rem;
  font-weight: 900;
  border-radius: 50%;
  box-shadow: 0 2px 6px rgba(150, 105, 31, 0.4);
}
.lux-ne-ico { font-size: 1.25rem; line-height: 1; }
.lux-ne-lbl {
  color: #334155;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.15;
}
@keyframes lux-ne-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}
.lux-ne-chip.lux-ne-shake { animation: lux-ne-shake 0.35s ease; }
.lux-ne-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
}
.lux-ne-actions button {
  border: none;
  border-radius: 999px;
  padding: 0.65rem 1.3rem;
  font-weight: 800;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.lux-ne-save {
  background: linear-gradient(135deg, #f2d98a 0%, #dfb254 45%, #c9993a 100%);
  color: #1a2547;
  box-shadow: 0 5px 16px rgba(201, 153, 58, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
.lux-ne-save:hover { filter: brightness(1.05); transform: translateY(-1px); }
.lux-ne-reset {
  background: rgba(15, 23, 42, 0.07);
  color: #334155;
}
.lux-ne-reset:hover { background: rgba(15, 23, 42, 0.12); }
.lux-ne-cancel {
  background: none;
  color: #94a3b8;
}
.lux-ne-cancel:hover { color: #475569; }
@media (max-width: 767px) {
  #lux-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 45;
    background: rgba(9, 16, 36, 0.82);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-top: 1px solid rgba(232, 193, 90, 0.25);
    box-shadow: 0 -8px 30px rgba(5, 11, 26, 0.35);
    padding: 0.35rem 0.25rem calc(0.35rem + env(safe-area-inset-bottom, 0px));
    justify-content: space-around;
  }
  #lux-bottom-nav button {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.12rem;
    background: none;
    border: none;
    color: rgba(226, 232, 240, 0.85);
    cursor: pointer;
    padding: 0.3rem 0.2rem;
    border-radius: 0.9rem;
    min-height: 52px;
    position: relative;
    overflow: hidden;
    transition: color 0.2s ease, background 0.2s ease;
  }
  #lux-bottom-nav button:active {
    background: rgba(232, 193, 90, 0.12);
    color: #f2d98a;
  }
  #lux-bottom-nav .lbn-ico {
    font-size: 1.25rem;
    line-height: 1;
  }
  #lux-bottom-nav .lbn-label {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.02em;
  }
  /* פינוי מקום לניווט */
  #toast-container { bottom: 6.2rem; }
  #pwa-install-banner { bottom: 6.4rem !important; }
}

/* ── רקע ההירו לפי שעת היום ── */
.gradient-bg.lux-t-dawn::after,
.gradient-bg.lux-t-day::after,
.gradient-bg.lux-t-dusk::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  transition: opacity 1.2s ease;
}
.gradient-bg.lux-t-dawn::after {
  background:
    radial-gradient(ellipse 130% 55% at 50% 105%, rgba(244, 137, 89, 0.16) 0%, transparent 60%),
    radial-gradient(ellipse 90% 40% at 50% 110%, rgba(232, 193, 90, 0.10) 0%, transparent 55%);
}
.gradient-bg.lux-t-day::after {
  background: radial-gradient(ellipse 130% 60% at 50% -10%, rgba(96, 165, 250, 0.13) 0%, transparent 60%);
}
.gradient-bg.lux-t-dusk::after {
  background:
    radial-gradient(ellipse 130% 55% at 50% 105%, rgba(234, 110, 40, 0.18) 0%, transparent 60%),
    radial-gradient(ellipse 90% 40% at 50% 110%, rgba(190, 60, 80, 0.10) 0%, transparent 55%);
}

/* ── ערב שבת — הנר שבספירה מהבהב בחום ── */
@keyframes lux-candle-flicker {
  0%, 100% { text-shadow: 0 0 8px rgba(253, 224, 71, 0.6), 0 0 18px rgba(245, 158, 11, 0.35); opacity: 1; }
  45% { text-shadow: 0 0 14px rgba(253, 224, 71, 0.85), 0 0 26px rgba(245, 158, 11, 0.55); opacity: 0.92; }
  70% { text-shadow: 0 0 6px rgba(253, 224, 71, 0.5), 0 0 14px rgba(245, 158, 11, 0.3); opacity: 1; }
}
.lux-erev-shabbat #countdown-label {
  animation: lux-candle-flicker 2.2s ease-in-out infinite;
}

/* ── כוכב נופל ── */
.lux-shooting-star {
  position: absolute;
  width: 120px;
  height: 2px;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(270deg, rgba(255, 255, 255, 0.9), rgba(242, 217, 138, 0.5), transparent);
  border-radius: 2px;
  transform: rotate(200deg);
  opacity: 0;
  animation: lux-shoot 1.3s ease-out forwards;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.6));
}
@keyframes lux-shoot {
  0% { opacity: 0; transform: rotate(200deg) translateX(0); }
  12% { opacity: 1; }
  100% { opacity: 0; transform: rotate(200deg) translateX(340px); }
}

/* ── ירח חי ── */
#lux-moon {
  position: absolute;
  top: 4.7rem;
  left: 1.1rem;
  /* מעל שכבת התוכן של ההירו (z-10) — אחרת הקליקים נבלעים בקונטיינר */
  z-index: 30;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: rgba(12, 21, 48, 0.4);
  border: 1px solid rgba(232, 193, 90, 0.3);
  border-radius: 50%;
  cursor: pointer;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 0 18px rgba(191, 219, 254, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: all 0.25s ease;
  animation: lux-moon-glow 5s ease-in-out infinite;
}
#lux-moon:hover {
  transform: scale(1.12);
  border-color: rgba(242, 217, 138, 0.7);
  box-shadow: 0 0 26px rgba(232, 193, 90, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}
@keyframes lux-moon-glow {
  0%, 100% { box-shadow: 0 0 14px rgba(191, 219, 254, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.1); }
  50% { box-shadow: 0 0 24px rgba(191, 219, 254, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.1); }
}
/* הרחבת שטח הלחיצה של הירח — בעיקר למובייל */
#lux-moon::after {
  content: '';
  position: absolute;
  inset: -14px;
  border-radius: 50%;
}
@media (max-width: 480px) {
  #lux-moon { top: 4.4rem; left: 0.8rem; width: 40px; height: 40px; font-size: 1.35rem; }
  #lux-moon::after { inset: -16px; }
}

/* ── גלילה חושפת ── */
html.lux-js #resultsGrid .event-card {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.55s ease,
    transform 0.55s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
html.lux-js #resultsGrid .event-card.lux-in {
  opacity: 1;
  transform: translateY(0);
}
html.lux-js #resultsGrid .event-card.lux-in:hover {
  transform: translateY(-6px);
}
@media (prefers-reduced-motion: reduce) {
  html.lux-js #resultsGrid .event-card {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* ── גל אור (ripple) ── */
.prayer-btn, .chip, .nav-action-btn, .nav-donate-btn, .zman-card {
  position: relative;
  overflow: hidden;
}
.lux-ripple {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(242, 217, 138, 0.35) 0%, rgba(242, 217, 138, 0.12) 45%, transparent 70%);
  transform: scale(0);
  animation: lux-ripple-anim 0.6s ease-out forwards;
  pointer-events: none;
}
@keyframes lux-ripple-anim {
  to { transform: scale(1); opacity: 0; }
}

/* ── קונפטי זהב ── */
.lux-confetti {
  position: fixed;
  inset: 0;
  z-index: 11000;
  pointer-events: none;
  overflow: hidden;
}
.lux-confetti span {
  position: absolute;
  top: -3vh;
  width: 8px;
  height: 12px;
  opacity: 0;
  animation: lux-fall linear forwards;
  box-shadow: 0 0 6px rgba(232, 193, 90, 0.35);
}
@keyframes lux-fall {
  0% { opacity: 1; transform: translate(0, 0) rotate(0deg); }
  100% { opacity: 0.15; transform: translate(var(--lx, 0px), 105vh) rotate(var(--lr, 360deg)); }
}

/* ── פס התקדמות קריאה ── */
.lux-progress {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  z-index: 60;
  background: rgba(200, 155, 60, 0.12);
  pointer-events: none;
}
.lux-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #e0b74f, #f2d98a);
  box-shadow: 0 0 8px rgba(224, 183, 79, 0.5);
  transition: width 0.15s ease-out;
}

/* ── סרגלי הגופן בקוראים — גלישה לשורות במקום חיתוך במובייל ── */
#sefaria-font-bar,
#chok-israel-font-bar,
.lux-font-bar {
  flex-wrap: wrap !important;
  row-gap: 0.4rem !important;
  justify-content: center !important;
}
@media (max-width: 480px) {
  #sefaria-font-bar,
  #chok-israel-font-bar,
  .lux-font-bar {
    gap: 0.4rem !important;
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
  }
}

/* ── כפתורי מצב לימוד / קריאת לילה ── */
.lux-reader-toggle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid rgba(200, 155, 60, 0.35);
  background: linear-gradient(135deg, #fdf9ec 0%, #f6eed7 100%);
  color: #96691f;
  font-size: 1rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(200, 155, 60, 0.2);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
  flex-shrink: 0;
}
.lux-reader-toggle:hover { transform: scale(1.08); }
.lux-reader-toggle.lux-on {
  background: linear-gradient(135deg, #f2d98a, #dfb254);
  border-color: rgba(161, 118, 42, 0.7);
  box-shadow: 0 0 0 2px rgba(224, 183, 79, 0.35), 0 2px 8px rgba(200, 155, 60, 0.35);
}

/* ── מצב לימוד — טקסט ספר ממורכז ומרווח ── */
.lux-study .holy-text-style,
.lux-study #sn-reader-content,
.lux-study #psalm-text-area,
.lux-study #shir-scroll-area > div,
.lux-study #bih-content-area {
  max-width: 44rem;
  margin-inline: auto;
  line-height: 2.25 !important;
}
.lux-study #sefaria-modal-content,
.lux-study #chok-israel-modal-content {
  padding-top: 1.5rem !important;
}
.lux-study .holy-text-style::before {
  content: '✦';
  display: block;
  text-align: center;
  color: #c9993a;
  font-size: 0.8rem;
  letter-spacing: 0.5em;
  margin-bottom: 1.1rem;
  opacity: 0.75;
}
@media (min-width: 768px) and (hover: hover) {
  .lux-study > div:first-child {
    opacity: 0.6;
    transition: opacity 0.3s ease;
  }
  .lux-study > div:first-child:hover { opacity: 1; }
}

/* ── קריאת לילה — קלף כהה חם ── */
.lux-night,
#sefaria-modal.lux-night,
#chok-israel-modal.lux-night,
#tehillim-modal.lux-night,
#sn-modal.lux-night,
#ben-ish-hai-modal.lux-night,
#shir-hashirim-modal.lux-night {
  background: #181008 !important;
}
.lux-night > div,
#sefaria-modal.lux-night > div:first-child,
#chok-israel-modal.lux-night > div:first-child {
  background-color: #181008 !important;
  background-image: none !important;
  border-color: rgba(232, 193, 90, 0.16) !important;
}
#sefaria-modal.lux-night #sefaria-modal-title,
#chok-israel-modal.lux-night #chok-israel-modal-title {
  color: #f2d98a !important;
}
.lux-night div {
  background-color: transparent;
}
.lux-night .holy-text-style,
.lux-night .holy-text-style p,
.lux-night .holy-text-style span,
.lux-night .holy-text-style div,
.lux-night .holy-text-style strong,
.lux-night .holy-text-style b,
.lux-night .holy-text-style big,
.lux-night .holy-text-style small,
.lux-night #sn-reader-content,
.lux-night #sn-reader-content p,
.lux-night #sn-reader-content span,
.lux-night #psalm-text-area p,
.lux-night #psalm-text-area span,
.lux-night #shir-scroll-area p,
.lux-night #shir-scroll-area span,
.lux-night #bih-content-area p,
.lux-night #bih-content-area span {
  color: #eaddc0 !important;
}
.lux-night h2, .lux-night h3, .lux-night h4 {
  color: #f2d98a !important;
}
.lux-night .prayer-richtext p,
.lux-night .prayer-richtext li,
.lux-night .prayer-richtext h2,
.lux-night .prayer-richtext h3 {
  color: #eaddc0 !important;
}
.lux-night [id$="-content"],
.lux-night [id$="-area"] {
  background-color: #181008 !important;
}

/* ── תמה מלכותית — זהב על בורדו-לילה ── */
html.lux-royal .gradient-bg {
  background:
    radial-gradient(ellipse 120% 70% at 50% -10%, rgba(232, 193, 90, 0.10) 0%, transparent 55%),
    radial-gradient(ellipse 90% 60% at 85% 100%, rgba(120, 30, 80, 0.30) 0%, transparent 60%),
    linear-gradient(160deg, #12050e 0%, #250b1e 45%, #3a1230 100%) !important;
}
html.lux-royal body {
  background-color: #150910 !important;
}
html.lux-royal .glass-card {
  border-color: rgba(232, 193, 90, 0.35);
}
html.lux-royal #omer-container {
  background: linear-gradient(135deg, #3a1230 0%, #250b1e 55%, #4a1638 100%) !important;
}
html.lux-royal #lux-bottom-nav {
  background: rgba(26, 8, 20, 0.85);
}
html.lux-royal .wave-divider path {
  fill: #150910 !important;
}
html.lux-royal .chip.active {
  box-shadow: 0 4px 20px rgba(201, 153, 58, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

/* ── לוח השנה — היום כתכשיט ── */
@keyframes lux-today-pulse {
  0%, 100% { box-shadow: 0 0 0 2px rgba(224, 183, 79, 0.45), 0 4px 14px rgba(224, 183, 79, 0.2); }
  50% { box-shadow: 0 0 0 4px rgba(224, 183, 79, 0.2), 0 4px 20px rgba(224, 183, 79, 0.35); }
}
#cal-days-grid > div.border-blue-500 {
  border-color: #e0b74f !important;
  animation: lux-today-pulse 2.6s ease-in-out infinite;
}
#cal-days-grid > div.border-blue-500 > div > span.font-black {
  color: #b8860b !important;
}
/* עמודת שבת — נגיעת קלף מוזהבת */
#cal-days-grid > div:nth-child(7n):not([aria-hidden]) {
  background: linear-gradient(165deg, #fdf9ec 0%, #f5edd8 100%) !important;
}
.dark #cal-days-grid > div:nth-child(7n):not([aria-hidden]) {
  background: linear-gradient(165deg, rgba(66, 50, 16, 0.45) 0%, rgba(40, 32, 14, 0.35) 100%) !important;
}
/* דפדוף חודשים */
@keyframes lux-flip-in {
  from { opacity: 0; transform: perspective(900px) rotateX(7deg) translateY(10px); }
  to { opacity: 1; transform: none; }
}
#cal-days-grid.lux-flip {
  animation: lux-flip-in 0.45s ease;
}

/* ═══════════════════════════════════════════════════════════════════
   LUX LAYER 3 — קשת שמש, גלגל שנה, מצב שבת, פנינה, סיור, רצף, הדפסה
   ═══════════════════════════════════════════════════════════════════ */

/* ── "הזמן הבא" — שורה קומפקטית ── */
#lux-next-zman {
  text-align: center;
  color: rgba(242, 217, 138, 0.95);
  font-size: 0.85rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
}
#lux-next-zman b {
  font-variant-numeric: tabular-nums;
  color: #fdf3d0;
}

/* ── כפתורי שיתוף / הדפסה בכותרת הזמנים ── */
.lux-zmanim-tools {
  display: inline-flex;
  gap: 0.4rem;
  margin-right: 0.5rem;
  vertical-align: middle;
}
.lux-zmanim-tools button {
  background: rgba(232, 193, 90, 0.12);
  border: 1px solid rgba(232, 193, 90, 0.35);
  color: #f2d98a;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s ease;
  letter-spacing: normal;
  font-family: "Assistant", sans-serif;
}
.lux-zmanim-tools button:hover {
  background: rgba(232, 193, 90, 0.25);
  border-color: rgba(242, 217, 138, 0.7);
}

/* ── גלגל השנה ── */
#lux-year-wheel-btn {
  background: linear-gradient(150deg, rgba(36, 81, 184, 0.5) 0%, rgba(12, 21, 48, 0.6) 100%);
  border: 1px solid rgba(232, 193, 90, 0.45);
  color: #fff;
  font-weight: 700;
  padding: 0.75rem 2rem;
  border-radius: 1rem;
  cursor: pointer;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 6px 24px rgba(5, 11, 26, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 auto 1rem;
}
#lux-year-wheel-btn:hover {
  border-color: rgba(242, 217, 138, 0.8);
  box-shadow: 0 10px 32px rgba(5, 11, 26, 0.5), 0 0 24px rgba(232, 193, 90, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}
#lux-year-wheel {
  position: fixed;
  inset: 0;
  z-index: 10085;
  background: rgba(2, 6, 23, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  direction: rtl;
}
.lux-yw-inner {
  width: min(100%, 520px);
  max-height: 94vh;
  overflow-y: auto;
  background:
    radial-gradient(ellipse 130% 60% at 50% -10%, rgba(232, 193, 90, 0.09) 0%, transparent 55%),
    linear-gradient(150deg, #14275e 0%, #0c1530 100%);
  border: 1px solid rgba(232, 193, 90, 0.35);
  border-radius: 1.5rem;
  padding: 1.1rem 0.9rem 1rem;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  text-align: center;
  position: relative;
}
.lux-yw-title {
  margin: 0 0 0.15rem;
  color: #fdf3d0;
  font-family: var(--lux-serif);
  font-size: 1.25rem;
  font-weight: 900;
}
.lux-yw-sub {
  margin: 0 0 0.4rem;
  color: rgba(191, 219, 254, 0.7);
  font-size: 0.78rem;
}
.lux-yw-close {
  position: absolute;
  top: 0.8rem;
  left: 0.8rem;
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  font-size: 1rem;
  cursor: pointer;
}
#lux-yw-svg {
  width: 100%;
  max-width: 440px;
  height: auto;
  margin: 0 auto;
  display: block;
  touch-action: manipulation;
}
.lux-yw-monthlabel {
  fill: rgba(191, 219, 254, 0.85);
  font-size: 10.5px;
  font-weight: 700;
}
.lux-yw-tick {
  stroke: rgba(148, 180, 255, 0.22);
  stroke-width: 1;
}
.lux-yw-ring {
  fill: none;
  stroke: rgba(232, 193, 90, 0.3);
  stroke-width: 1.5;
}
/* טבעת מקווקוות מסתובבת לאט — תחושת גלגל חי */
.lux-yw-dashring {
  fill: none;
  stroke: rgba(232, 193, 90, 0.35);
  stroke-width: 1.5;
  stroke-dasharray: 3 9;
  transform-origin: 170px 170px;
  animation: lux-yw-rotate 90s linear infinite;
}
@keyframes lux-yw-rotate {
  to { transform: rotate(360deg); }
}
/* אייקוני החגים — הילה זהב, גדילה בריחוף */
.lux-yw-evt {
  cursor: pointer;
}
.lux-yw-halo {
  fill: rgba(12, 21, 48, 0.85);
  stroke: rgba(232, 193, 90, 0.55);
  stroke-width: 1.2;
  filter: drop-shadow(0 0 5px rgba(232, 193, 90, 0.45));
  transition: all 0.2s ease;
}
.lux-yw-evt:hover .lux-yw-halo {
  fill: rgba(60, 45, 12, 0.9);
  stroke: rgba(253, 224, 71, 0.95);
  filter: drop-shadow(0 0 10px rgba(232, 193, 90, 0.8));
}
.lux-yw-evt text {
  pointer-events: none;
}
.lux-yw-year {
  fill: #f2d98a;
  font-family: var(--lux-serif);
  font-size: 30px;
  font-weight: 900;
  filter: drop-shadow(0 0 14px rgba(232, 193, 90, 0.45));
}
.lux-yw-today {
  fill: rgba(219, 231, 255, 0.85);
  font-size: 12.5px;
  font-weight: 700;
}
.lux-yw-now {
  fill: #fff;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.9));
}
/* כניסה קולנועית לגלגל */
@keyframes lux-yw-enter {
  from { opacity: 0; transform: scale(0.9) rotate(-8deg); }
  to { opacity: 1; transform: scale(1) rotate(0deg); }
}
#lux-yw-svg {
  animation: lux-yw-enter 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes lux-yw-card-in {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}
.lux-yw-inner {
  animation: lux-yw-card-in 0.35s ease;
}
#lux-yw-info {
  min-height: 3.2rem;
  margin-top: 0.4rem;
  color: #e2e8f0;
  font-size: 0.9rem;
}
#lux-yw-info .lux-yw-evname {
  color: #f2d98a;
  font-weight: 900;
  font-family: var(--lux-serif);
  font-size: 1.05rem;
}
#lux-yw-info button {
  margin-top: 0.35rem;
  background: linear-gradient(135deg, #f2d98a, #c9993a);
  color: #1a2547;
  border: none;
  border-radius: 999px;
  padding: 0.4rem 1.1rem;
  font-weight: 800;
  font-size: 0.8rem;
  cursor: pointer;
}
/* הבהוב כרטיס אירוע שנבחר מהגלגל */
@keyframes lux-card-flash {
  0%, 100% { box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05); }
  30%, 60% { box-shadow: 0 0 0 3px rgba(224, 183, 79, 0.75), 0 8px 30px rgba(200, 155, 60, 0.35); }
}
.lux-card-flash {
  animation: lux-card-flash 1.6s ease 2;
}

/* ── צמצום רווחים במובייל: בין זמני היום לתיבת החיפוש ── */
@media (max-width: 767px) {
  #hero-section {
    padding-bottom: 6rem !important;
  }
  #halacha-banner {
    padding: 1rem 0.9rem 1.1rem !important;
  }
}

/* ── מצב שבת ── */
body.lux-shabbat .gradient-bg {
  background:
    radial-gradient(ellipse 120% 70% at 50% -10%, rgba(253, 186, 116, 0.10) 0%, transparent 55%),
    radial-gradient(ellipse 90% 55% at 50% 110%, rgba(180, 83, 9, 0.16) 0%, transparent 60%),
    linear-gradient(160deg, #170d05 0%, #241205 45%, #3a2008 100%) !important;
}
#lux-shabbat-banner {
  display: none;
  margin: 0 auto 1rem;
  text-align: center;
}
body.lux-shabbat #lux-shabbat-banner {
  display: block;
}
#lux-shabbat-banner .lux-sb-title {
  font-family: var(--lux-serif);
  font-weight: 900;
  font-size: clamp(1.5rem, 6vw, 2.2rem);
  color: #fde8b0;
  text-shadow: 0 0 30px rgba(253, 186, 116, 0.4);
}
#lux-shabbat-banner .lux-sb-candles {
  font-size: 1.5rem;
  letter-spacing: 0.4em;
  margin-bottom: 0.2rem;
  animation: lux-candle-flicker 2.2s ease-in-out infinite;
}
body.lux-shabbat .glass-card {
  border-color: rgba(253, 186, 116, 0.28);
}
body.lux-shabbat #shabbat-countdown-bar {
  border-color: rgba(253, 186, 116, 0.45);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.25), 0 0 24px rgba(253, 186, 116, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* ── ברכת שלום חכמה ── */
#lux-greeting {
  color: rgba(226, 232, 240, 0.92);
  font-size: clamp(0.85rem, 3.4vw, 1rem);
  font-weight: 700;
  margin-bottom: 0.6rem;
  opacity: 0;
  animation: lux-rise 0.7s ease 0.2s forwards;
}
#lux-greeting .lux-greet-date {
  color: #f2d98a;
  font-family: var(--lux-serif);
  font-weight: 800;
}

/* ── פנינה יומית ── */
#lux-pearl {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 140% 50% at 50% 0%, rgba(200, 155, 60, 0.07) 0%, transparent 60%),
    #fdfbf5;
  border: 1px solid rgba(200, 155, 60, 0.3);
  border-radius: 1.75rem;
  padding: 1.4rem 1.5rem 1.1rem;
  margin-bottom: 2rem;
  text-align: center;
  box-shadow: 0 12px 32px -14px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(200, 155, 60, 0.08);
}
.dark #lux-pearl {
  background:
    radial-gradient(ellipse 140% 50% at 50% 0%, rgba(200, 155, 60, 0.08) 0%, transparent 60%),
    #1a2035;
  border-color: rgba(232, 193, 90, 0.25);
}
#lux-pearl::before {
  content: '✦';
  display: block;
  color: #c9993a;
  font-size: 0.75rem;
  letter-spacing: 0.5em;
  margin-bottom: 0.5rem;
  opacity: 0.8;
}
#lux-pearl .lux-pearl-text {
  font-family: var(--lux-serif);
  font-size: clamp(1.02rem, 4vw, 1.25rem);
  font-weight: 700;
  color: #1e293b;
  line-height: 1.9;
  margin: 0 0 0.5rem;
}
.dark #lux-pearl .lux-pearl-text { color: #f1e9d2; }
#lux-pearl .lux-pearl-src {
  color: #a1762a;
  font-size: 0.78rem;
  font-weight: 800;
  margin: 0 0 0.6rem;
}
.dark #lux-pearl .lux-pearl-src { color: #e0b74f; }
/* ── שלדי טעינה זהובים ── */
.lux-skeleton-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.8rem;
  max-width: 640px;
  margin: 1.4rem auto 0;
}
@media (min-width: 768px) {
  .lux-skeleton-grid { grid-template-columns: repeat(4, 1fr); }
}
.lux-skeleton-card {
  height: 108px;
  border-radius: 1.5rem;
  border: 1px solid rgba(232, 193, 90, 0.14);
  background: linear-gradient(100deg,
    rgba(255, 255, 255, 0.04) 30%,
    rgba(232, 193, 90, 0.12) 48%,
    rgba(232, 193, 90, 0.16) 52%,
    rgba(232, 193, 90, 0.12) 56%,
    rgba(255, 255, 255, 0.04) 74%);
  background-size: 240% 100%;
  animation: lux-shimmer-bg 1.6s linear infinite;
}
@keyframes lux-shimmer-bg {
  from { background-position: 130% 0; }
  to { background-position: -110% 0; }
}
/* "מחשב זמנים..." — שלד במקום טקסט מהבהב */
#zmanim-details > div.animate-pulse {
  min-height: 56px;
  border-radius: 1rem;
  border: 1px solid rgba(232, 193, 90, 0.14);
  background: linear-gradient(100deg,
    rgba(255, 255, 255, 0.05) 30%,
    rgba(232, 193, 90, 0.13) 50%,
    rgba(255, 255, 255, 0.05) 70%);
  background-size: 240% 100%;
  animation: lux-shimmer-bg 1.6s linear infinite;
  color: rgba(191, 219, 254, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
}

/* ── משיכה לרענון ── */
#lux-ptr {
  position: fixed;
  top: -64px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 11500;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(12, 21, 48, 0.9);
  border: 1px solid rgba(232, 193, 90, 0.5);
  border-radius: 50%;
  box-shadow: 0 8px 24px rgba(5, 11, 26, 0.5), 0 0 16px rgba(232, 193, 90, 0.2);
  transition: top 0.2s ease;
  pointer-events: none;
}
#lux-ptr svg {
  width: 24px;
  height: 24px;
}
#lux-ptr.lux-ptr-spin svg {
  animation: spin 0.8s linear infinite;
}

/* ── מודאל קלף גנרי (שם, שמות לתפילה, יארצייטים, הישגים, סיום) ── */
.lux-sheet-overlay {
  position: fixed;
  inset: 0;
  z-index: 10090;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  direction: rtl;
}
.lux-sheet {
  width: min(100%, 420px);
  max-height: min(86vh, 660px);
  overflow-y: auto;
  background:
    radial-gradient(ellipse 140% 50% at 50% 0%, rgba(200, 155, 60, 0.06) 0%, transparent 60%),
    #faf8f3;
  border: 1px solid rgba(200, 155, 60, 0.3);
  border-radius: 1.5rem;
  padding: 1.4rem 1.2rem 1.1rem;
  box-shadow: 0 30px 80px rgba(5, 11, 26, 0.45);
  text-align: center;
  animation: lux-yw-card-in 0.3s ease;
}
.lux-sheet-title {
  margin: 0 0 0.3rem;
  color: #0f172a;
  font-size: 1.2rem;
  font-weight: 900;
  font-family: var(--lux-serif);
}
.lux-sheet-note {
  margin: 0 0 1rem;
  color: #64748b;
  font-size: 0.82rem;
  line-height: 1.6;
}
.lux-sheet-input {
  width: 100%;
  box-sizing: border-box;
  padding: 0.7rem 1rem;
  border: 1.5px solid rgba(148, 163, 184, 0.45);
  border-radius: 0.9rem;
  background: #fff;
  color: #0f172a;
  font: inherit;
  font-size: 0.95rem;
  outline: none;
  margin-bottom: 0.5rem;
  direction: rtl;
}
.lux-sheet-input:focus {
  border-color: rgba(224, 183, 79, 0.7);
  box-shadow: 0 0 0 3px rgba(224, 183, 79, 0.2);
}
.lux-sheet-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 0.9rem;
}
.lux-sheet-primary {
  background: linear-gradient(135deg, #f2d98a 0%, #dfb254 45%, #c9993a 100%);
  color: #1a2547;
  border: none;
  border-radius: 999px;
  padding: 0.6rem 1.4rem;
  font-weight: 800;
  font-size: 0.88rem;
  cursor: pointer;
  box-shadow: 0 5px 16px rgba(201, 153, 58, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}
.lux-sheet-primary:hover { filter: brightness(1.05); }
.lux-sheet-secondary {
  background: rgba(15, 23, 42, 0.07);
  color: #334155;
  border: none;
  border-radius: 999px;
  padding: 0.6rem 1.2rem;
  font-weight: 800;
  font-size: 0.85rem;
  cursor: pointer;
}
.lux-sheet-cancel {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}
.lux-sheet-cancel:hover { color: #475569; }
.lux-names-add { margin-top: 0.75rem; }
.lux-nm-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  background: #fff;
  border: 1px solid rgba(200, 155, 60, 0.25);
  border-radius: 0.85rem;
  padding: 0.5rem 0.85rem;
  margin-bottom: 0.4rem;
  font-size: 0.88rem;
  color: #1e293b;
  font-weight: 700;
  text-align: right;
}
.lux-nm-row small { color: #a1762a; font-weight: 700; }
.lux-nm-row button {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.95rem;
  flex-shrink: 0;
}

/* ── ברכה: כפתור שם ── */
.lux-name-add, .lux-name-edit {
  background: rgba(232, 193, 90, 0.18);
  border: 1.5px solid rgba(232, 193, 90, 0.55);
  color: #f2d98a;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.22rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  margin-right: 0.3rem;
  transition: all 0.2s ease;
  vertical-align: middle;
  box-shadow: 0 1px 6px rgba(224, 183, 79, 0.25);
  white-space: nowrap;
}
.lux-name-add:hover, .lux-name-edit:hover {
  background: rgba(232, 193, 90, 0.3);
  box-shadow: 0 2px 10px rgba(224, 183, 79, 0.4);
}

/* ── חיפוש-על ── */
#lux-search-panel {
  display: none;
  margin: -0.75rem 0 1rem;
  border: 1px solid rgba(200, 155, 60, 0.3);
  border-radius: 1.25rem;
  overflow: hidden;
  background: #fdfbf5;
  box-shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.18);
}
.dark #lux-search-panel {
  background: #131a2e;
  border-color: rgba(232, 193, 90, 0.25);
}
.lux-sp-item {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  width: 100%;
  padding: 0.7rem 1.1rem;
  background: none;
  border: none;
  border-bottom: 1px solid rgba(200, 155, 60, 0.12);
  cursor: pointer;
  text-align: right;
  font: inherit;
  color: #1e293b;
  transition: background 0.15s ease;
}
.dark .lux-sp-item { color: #e2e8f0; }
.lux-sp-item:last-child { border-bottom: none; }
.lux-sp-item:hover {
  background: rgba(224, 183, 79, 0.1);
}
.lux-sp-ico { font-size: 1.1rem; flex-shrink: 0; }
.lux-sp-txt { flex: 1; font-weight: 700; font-size: 0.92rem; }
.lux-sp-txt small { color: #a1762a; font-weight: 800; }
.dark .lux-sp-txt small { color: #f2d98a; }
.lux-sp-go { color: #c9993a; font-weight: 900; flex-shrink: 0; }

/* ── תזכורת זמן קריטי ── */
#lux-crit-pill {
  position: fixed;
  top: calc(3.6rem + env(safe-area-inset-top, 0px));
  left: 50%;
  transform: translateX(-50%);
  z-index: 48;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(150deg, rgba(120, 45, 10, 0.92), rgba(90, 30, 8, 0.94));
  border: 1px solid rgba(253, 186, 116, 0.6);
  color: #ffedd5;
  font-size: 0.8rem;
  font-weight: 800;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(5, 11, 26, 0.4), 0 0 18px rgba(253, 186, 116, 0.25);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  max-width: 92vw;
  white-space: nowrap;
  animation: lux-rise 0.4s ease;
}
#lux-crit-pill .lux-crit-x {
  background: none;
  border: none;
  color: rgba(255, 237, 213, 0.7);
  cursor: pointer;
  font-size: 0.8rem;
  padding: 0;
  flex-shrink: 0;
}

/* ── באנר יום מיוחד + יארצייט ── */
#lux-day-banner,
#lux-yz-banner {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 auto 0.8rem;
  background: rgba(232, 193, 90, 0.10);
  border: 1px solid rgba(232, 193, 90, 0.35);
  color: #fde8b0;
  font-size: clamp(0.75rem, 3.2vw, 0.88rem);
  font-weight: 700;
  padding: 0.45rem 1rem;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  max-width: 94%;
  line-height: 1.6;
}
#lux-yz-banner {
  border-color: rgba(253, 186, 116, 0.45);
  color: #ffe9c7;
  border-radius: 1rem;
  text-align: right;
}
#lux-yz-banner b { color: #fde8b0; }
#lux-day-banner button {
  background: none;
  border: none;
  color: rgba(253, 232, 176, 0.6);
  cursor: pointer;
  font-size: 0.75rem;
  padding: 0;
  flex-shrink: 0;
}

/* ── מעקב תהילים ── */
#lux-th-progress {
  flex-shrink: 0;
  padding: 0.5rem 1.25rem 0.55rem;
  background: #fdf8ea;
  border-bottom: 1px solid rgba(200, 155, 60, 0.25);
}
.lux-thp-txt {
  font-size: 0.75rem;
  font-weight: 800;
  color: #a1762a;
  margin-bottom: 0.3rem;
  text-align: center;
}
.lux-thp-track {
  height: 6px;
  background: rgba(200, 155, 60, 0.15);
  border-radius: 3px;
  overflow: hidden;
}
.lux-thp-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #e0b74f, #f2d98a);
  border-radius: 3px;
  box-shadow: 0 0 8px rgba(224, 183, 79, 0.5);
  transition: width 0.6s ease;
}
#lux-names-banner {
  flex-shrink: 0;
  padding: 0.45rem 1.25rem;
  background: #f5f9ff;
  border-bottom: 1px solid rgba(59, 130, 246, 0.18);
  color: #1e40af;
  font-size: 0.78rem;
  font-weight: 700;
  text-align: center;
  line-height: 1.6;
}
.lux-th-mark {
  display: block;
  margin: 0.4rem auto 1rem;
  background: none;
  border: 1.5px solid rgba(148, 163, 184, 0.5);
  color: #94a3b8;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.3rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: "Assistant", sans-serif;
}
.lux-th-mark.lux-on {
  background: linear-gradient(135deg, #f2d98a, #dfb254);
  border-color: rgba(161, 118, 42, 0.6);
  color: #1a2547;
  box-shadow: 0 3px 10px rgba(201, 153, 58, 0.3);
}

/* ── הישגים ── */
.lux-ach-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-top: 0.4rem;
}
@media (max-width: 380px) {
  .lux-ach-grid { grid-template-columns: repeat(2, 1fr); }
}
.lux-ach {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  min-height: 78px;
  padding: 0.5rem 0.3rem;
  background: #f1f0ec;
  border: 1.5px solid rgba(148, 163, 184, 0.3);
  border-radius: 1rem;
  filter: grayscale(1);
  opacity: 0.55;
}
.lux-ach-on {
  background: linear-gradient(165deg, #fdf9ec 0%, #f6eed7 100%);
  border-color: rgba(200, 155, 60, 0.6);
  filter: none;
  opacity: 1;
  box-shadow: 0 0 0 2px rgba(224, 183, 79, 0.2), 0 4px 12px rgba(200, 155, 60, 0.2);
}
.lux-ach-ico { font-size: 1.5rem; line-height: 1; }
.lux-ach-on .lux-ach-ico { filter: drop-shadow(0 0 6px rgba(232, 193, 90, 0.6)); }
.lux-ach-txt {
  color: #475569;
  font-size: 0.66rem;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}
.lux-ach-on .lux-ach-txt { color: #7a5a1e; }

/* ── "הזמן הבא" — שורה אחת תמיד ── */
#lux-next-zman {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: clamp(0.72rem, 3.4vw, 0.85rem);
}

/* ── רצף לימוד ── */
#lux-streak {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(232, 193, 90, 0.12);
  border: 1px solid rgba(232, 193, 90, 0.35);
  color: #fde8b0;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  margin: 0.15rem auto 0;
}

/* ── לוח זמנים להדפסה — דחוס לעמוד אחד ── */
#lux-print-sheet { display: none; }
@media print {
  @page { margin: 8mm; }
  html, body {
    height: auto !important;
    min-height: 0 !important;
  }
  body > *:not(#lux-print-sheet) { display: none !important; }
  body { background: #fff !important; padding: 0 !important; margin: 0 !important; }
  /* גובה קבוע של עמוד אחד: השורות מתפרסות אוטומטית על כל הגובה,
     ו-overflow:hidden מבטיח שלעולם לא תהיה גלישה לעמוד שני */
  #lux-print-sheet {
    display: flex !important;
    flex-direction: column;
    height: 250mm;
    box-sizing: border-box;
    overflow: hidden;
    direction: rtl;
    font-family: "Frank Ruhl Libre", serif;
    line-height: 1.25;
    color: #1a2035;
    border: 3px double #b8912e;
    border-radius: 12px;
    padding: 8mm 11mm;
    margin: 0;
    page-break-inside: avoid;
    break-inside: avoid;
    page-break-after: avoid;
  }
  #lux-print-sheet .lux-pr-title {
    text-align: center;
    font-size: 23pt;
    font-weight: 900;
    margin: 0 0 2mm;
    flex-shrink: 0;
  }
  #lux-print-sheet .lux-pr-sub {
    text-align: center;
    font-size: 12.5pt;
    color: #6b5518;
    margin: 0 0 4mm;
    flex-shrink: 0;
  }
  #lux-print-sheet table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14pt;
    flex: 1 1 auto;
    min-height: 0;
  }
  #lux-print-sheet td {
    padding: 1.5mm 5mm;
    border-bottom: 1px solid #e5d9b8;
    vertical-align: middle;
  }
  #lux-print-sheet tr { page-break-inside: avoid; }
  #lux-print-sheet td:last-child {
    text-align: left;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
  }
  #lux-print-sheet .lux-pr-foot {
    text-align: center;
    font-size: 9pt;
    color: #8a7434;
    margin-top: 3mm;
    flex-shrink: 0;
    page-break-inside: avoid;
  }
}

/* ── תנועה מופחתת ── */
@media (prefers-reduced-motion: reduce) {
  .prayer-btn.prayer-cta-highlight,
  #prayer-more-btn.chevron-cta-pulse,
  .levana-blinking,
  .countdown-digit,
  #lux-moon,
  .lux-shooting-star,
  #cal-days-grid > div.border-blue-500,
  .lux-skeleton-card,
  #zmanim-details > div.animate-pulse,
  #lux-shabbat-banner .lux-sb-candles {
    animation: none !important;
  }
}

/* ═══════════════════════════════════════════════════════════════════
   LUX 5 — פס התקדמות בולט, מצב לימוד משופר, סיור מודרך, סליחות
   ═══════════════════════════════════════════════════════════════════ */

/* ── פס התקדמות קריאה — בולט וזוהר, בעיקר במובייל ── */
.lux-progress {
  height: 5px;
  z-index: 900;
  background: rgba(200, 155, 60, 0.18);
}
.lux-progress-fill {
  background: linear-gradient(90deg, #c9993a, #e0b74f, #f2d98a);
  box-shadow: 0 0 10px rgba(224, 183, 79, 0.75), 0 1px 4px rgba(161, 118, 42, 0.5);
  border-radius: 0 3px 3px 0;
}
@media (max-width: 640px) {
  .lux-progress { height: 7px; }
}

/* ── מצב לימוד — חוויה מורגשת ומשמעותית, בעיקר במובייל ── */
.lux-study .holy-text-style,
.lux-study #sn-reader-content,
.lux-study #psalm-text-area,
.lux-study #shir-scroll-area > div,
.lux-study #bih-content-area {
  font-size: 1.12em !important;
  letter-spacing: 0.012em;
}
.lux-study .holy-text-style p,
.lux-study #psalm-text-area p {
  margin-bottom: 0.55em;
}
@media (max-width: 640px) {
  .lux-study .holy-text-style,
  .lux-study #sn-reader-content,
  .lux-study #psalm-text-area,
  .lux-study #shir-scroll-area > div,
  .lux-study #bih-content-area {
    font-size: 1.2em !important;
    line-height: 2.45 !important;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
  }
}
/* מסגרת זהב עדינה סביב הטקסט במצב לימוד — תחושת "דף לימוד" */
.lux-study .holy-text-style,
.lux-study #psalm-text-area,
.lux-study #sn-reader-content,
.lux-study #bih-content-area {
  background:
    linear-gradient(180deg, rgba(224, 183, 79, 0.06), transparent 120px);
  border-top: 2px solid rgba(201, 153, 58, 0.35);
}

/* ── סיור מודרך ── */
#lux-tour-overlay {
  position: fixed;
  inset: 0;
  z-index: 13000;
  pointer-events: none;
}
#lux-tour-hi {
  position: fixed;
  border-radius: 1.2rem;
  box-shadow:
    0 0 0 3px rgba(242, 217, 138, 0.95),
    0 0 24px 6px rgba(224, 183, 79, 0.55),
    0 0 0 9999px rgba(2, 6, 23, 0.78);
  transition: all 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}
#lux-tour-tip {
  position: fixed;
  right: 50%;
  transform: translateX(50%);
  width: min(92vw, 360px);
  background: linear-gradient(160deg, #0c1530 0%, #16233f 100%);
  border: 1px solid rgba(224, 183, 79, 0.55);
  border-radius: 1.25rem;
  padding: 1.1rem 1.2rem 0.9rem;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  pointer-events: auto;
  direction: rtl;
  text-align: right;
  transition: top 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}
.lux-tour-title {
  color: #f2d98a;
  font-weight: 900;
  font-size: 1.06rem;
  margin-bottom: 0.35rem;
  font-family: var(--lux-serif);
}
.lux-tour-desc {
  color: #dbe7ff;
  font-size: 0.86rem;
  line-height: 1.75;
  margin-bottom: 0.7rem;
}
.lux-tour-dots {
  display: flex;
  gap: 4px;
  justify-content: center;
  margin-bottom: 0.7rem;
}
.lux-tour-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(242, 217, 138, 0.25);
  transition: all 0.3s;
}
.lux-tour-dots span.lux-td-on {
  width: 18px;
  border-radius: 3px;
  background: #e0b74f;
}
.lux-tour-btns {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.lux-tour-btns button {
  border: none;
  cursor: pointer;
  font-weight: 800;
  border-radius: 0.7rem;
  padding: 0.5rem 1rem;
  font-size: 0.85rem;
  transition: transform 0.15s ease;
}
.lux-tour-btns button:active { transform: scale(0.96); }
.lux-tour-next {
  flex: 1;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  box-shadow: 0 4px 14px rgba(224, 183, 79, 0.4);
}
.lux-tour-prev {
  background: rgba(255, 255, 255, 0.08);
  color: #dbe7ff;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
}
.lux-tour-skip {
  background: none;
  color: rgba(148, 163, 184, 0.9);
  font-size: 0.78rem !important;
  padding: 0.5rem 0.4rem !important;
}

/* ── כרטיס הסליחות בדף הראשי ── */
#lux-selichot-card {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0 0 1.5rem;
  padding: 1.15rem 1.3rem;
  border-radius: 1.6rem;
  cursor: pointer;
  direction: rtl;
  background: linear-gradient(135deg, #101a35 0%, #1c2b4f 55%, #14213f 100%);
  border: 1.5px solid rgba(224, 183, 79, 0.55);
  box-shadow: 0 10px 34px rgba(10, 18, 40, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  animation: lux-selc-in 0.6s ease;
}
@keyframes lux-selc-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}
.lux-selc-glow {
  position: absolute;
  inset: -40% -20%;
  background: radial-gradient(ellipse at 80% 0%, rgba(232, 193, 90, 0.18) 0%, transparent 55%);
  pointer-events: none;
}
.lux-selc-icon {
  font-size: 2.1rem;
  flex-shrink: 0;
  filter: drop-shadow(0 0 10px rgba(242, 217, 138, 0.45));
}
.lux-selc-txt { flex: 1; min-width: 0; }
.lux-selc-txt h3 {
  color: #f2d98a;
  font-family: var(--lux-serif);
  font-weight: 900;
  font-size: 1.15rem;
  margin: 0 0 0.15rem;
}
.lux-selc-txt p {
  color: rgba(191, 219, 254, 0.85);
  font-size: 0.78rem;
  margin: 0;
  font-weight: 600;
}
.lux-selc-txt .lux-selc-day {
  color: rgba(242, 217, 138, 0.9);
  font-size: 0.74rem;
  margin-top: 0.15rem;
}
#lux-selc-open {
  flex-shrink: 0;
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  font-weight: 900;
  font-size: 0.86rem;
  padding: 0.65rem 1.1rem;
  border-radius: 0.9rem;
  box-shadow: 0 6px 18px rgba(224, 183, 79, 0.4);
  transition: transform 0.15s ease;
  white-space: nowrap;
}
#lux-selc-open:active { transform: scale(0.96); }
@media (max-width: 560px) {
  #lux-selichot-card { flex-wrap: wrap; padding: 1rem 1.1rem; }
  #lux-selc-open { width: 100%; padding: 0.75rem; }
}

/* ── קורא הסליחות ── */
#lux-selichot-reader {
  position: fixed;
  inset: 0;
  z-index: 240;
  display: flex;
  flex-direction: column;
  background: #faf9f6;
  direction: rtl;
}
.lux-sel-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem 1.1rem;
  background: linear-gradient(160deg, #0c1530 0%, #16233f 100%);
  border-bottom: 2px solid rgba(224, 183, 79, 0.5);
  flex-shrink: 0;
}
.lux-sel-close {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 2.2rem;
  height: 2.2rem;
  cursor: pointer;
  color: #e2e8f0;
  font-size: 1.05rem;
  flex-shrink: 0;
}
.lux-sel-titles { flex: 1; min-width: 0; }
.lux-sel-titles h2 {
  color: #f2d98a;
  font-family: var(--lux-serif);
  font-weight: 900;
  font-size: 1.15rem;
  margin: 0;
}
.lux-sel-titles p {
  color: rgba(191, 219, 254, 0.7);
  font-size: 0.72rem;
  margin: 0.1rem 0 0;
}
.lux-sel-chips {
  display: flex;
  gap: 0.4rem;
  padding: 0.7rem 1.1rem;
  overflow-x: auto;
  flex-shrink: 0;
  background: #f3efe4;
  border-bottom: 1px solid rgba(0, 0, 0, 0.07);
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.lux-sel-chips::-webkit-scrollbar { display: none; }
.lux-sel-chip {
  flex-shrink: 0;
  padding: 0.38rem 0.8rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  border: 1px solid rgba(161, 118, 42, 0.35);
  background: transparent;
  color: #6b5620;
  cursor: pointer;
  white-space: nowrap;
}
.lux-sel-chip-on {
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  border-color: #a1762a;
  box-shadow: 0 3px 10px rgba(224, 183, 79, 0.4);
}
.lux-sel-area {
  flex: 1;
  overflow-y: auto;
  padding: 1.4rem 1.2rem 3rem;
  direction: rtl;
  text-align: center;
  font-family: 'Frank Ruhl Libre', 'David Libre', serif;
  font-weight: 600;
  line-height: 2;
  color: #1a1408;
}
.lux-sel-para {
  max-width: 44rem;
  margin: 0 auto 1.05em;
  /* em ולא rem — כך כפתורי ההקטנה/הגדלה (שמשנים % על המיכל) עובדים */
  font-size: 1.3em;
  line-height: 2.05;
}
.lux-sel-para b, .lux-sel-para strong { color: #7c2d12; }
/* קרדיט ספריא — בתחתית הטקסט, אחרי סיום הקריאה */
.lux-sel-credit {
  text-align: center;
  margin: 2.2rem auto 0.5rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(161, 118, 42, 0.3);
  max-width: 22rem;
  font-family: Assistant, sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  color: #a1762a;
  line-height: 1.9;
}
html.dark .lux-sel-credit { color: #d9c48a; border-top-color: rgba(224, 183, 79, 0.3); }
html.dark #lux-selichot-reader { background: #0f172a; }
html.dark .lux-sel-area { color: #e2e8f0; }
html.dark .lux-sel-para b, html.dark .lux-sel-para strong { color: #f2d98a; }
html.dark .lux-sel-chips { background: #111c33; border-bottom-color: rgba(255, 255, 255, 0.08); }
html.dark .lux-sel-chip { color: #d9c48a; border-color: rgba(224, 183, 79, 0.35); }

/* ── פס התקדמות תהילים — לחיץ + רשימת הפרקים שנקראו ── */
#lux-th-progress {
  cursor: pointer;
  transition: background 0.2s ease;
  -webkit-tap-highlight-color: rgba(224, 183, 79, 0.2);
}
#lux-th-progress:hover { background: #faf0d8; }
#lux-th-progress:active { background: #f5e8c8; }
.lux-th-readgrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(52px, 1fr));
  gap: 0.4rem;
  max-height: 46vh;
  overflow-y: auto;
  padding: 0.3rem 0.1rem;
  margin-bottom: 0.5rem;
}
.lux-th-readchip {
  border: 1.5px solid rgba(201, 153, 58, 0.45);
  background: linear-gradient(135deg, #fdf9ec, #f6eed7);
  color: #7a5c1a;
  font-weight: 800;
  font-size: 0.85rem;
  padding: 0.5rem 0.2rem;
  border-radius: 0.7rem;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.15s ease;
}
.lux-th-readchip:hover {
  transform: scale(1.06);
  box-shadow: 0 3px 10px rgba(224, 183, 79, 0.4);
}
.lux-th-readchip:active { transform: scale(0.95); }

/* ── לוח שנה במובייל: כפתור ה-✕ נשאר בפנים, בלי לבלגן את הכפתורים ── */
@media (max-width: 560px) {
  #calendar-modal > div > div:first-child {
    padding: 0.7rem 0.5rem;
    gap: 0.25rem;
  }
  #calendar-modal > div > div:first-child > div:first-child {
    gap: 0.25rem !important;
    flex: 1;
    min-width: 0;
  }
  #calendar-modal > div > div:first-child > div:first-child > .text-center {
    min-width: 0 !important;
    flex-shrink: 1;
  }
  #cal-month-title { font-size: 1.02rem !important; }
  #cal-month-heb { font-size: 0.66rem !important; }
  #calendar-modal > div > div:first-child button[onclick="changeMonth(-1)"],
  #calendar-modal > div > div:first-child button[onclick="changeMonth(1)"] {
    padding: 0.4rem !important;
    flex-shrink: 0;
  }
  #calendar-modal button[onclick="resetMonth()"],
  #calendar-modal button[onclick="downloadBulkICS()"] {
    padding: 0.35rem 0.5rem !important;
    font-size: 0.68rem !important;
    flex-shrink: 0;
    white-space: nowrap;
  }
  /* מירכוז "היום"+"סנכרן" ברווח שבין חיצי החודשים לכפתור ה-✕ */
  #calendar-modal button[onclick="resetMonth()"] {
    margin-left: 0 !important;
    margin-right: auto !important;
  }
  #calendar-modal button[onclick="downloadBulkICS()"] {
    margin-left: auto !important;
  }
  #calendar-modal > div > div:first-child > button[aria-label="סגור"] {
    padding: 0.45rem !important;
    flex-shrink: 0;
  }
  #calendar-modal > div > div:first-child > button[aria-label="סגור"] svg {
    width: 1.15rem;
    height: 1.15rem;
  }
}

/* ═══════════════════════════════════════════════════════════════════
   LUX 6 — עונתיות, מצב שבת, סטוריז, שעון הלכתי, שנה טובה, מסלולים
   ═══════════════════════════════════════════════════════════════════ */

/* ── תחתית קורא הסליחות/מסלולים: גלילה אוטומטית ── */
.lux-sel-foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.55rem 1rem;
  background: #f3efe4;
  border-top: 1px solid rgba(0, 0, 0, 0.07);
  flex-shrink: 0;
}
html.dark .lux-sel-foot { background: #111c33; border-top-color: rgba(255, 255, 255, 0.08); }
.lux-sel-scroll-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid rgba(16, 185, 129, 0.4);
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  color: #047857;
  font-size: 0.95rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.2);
}
.lux-sel-speed {
  font-size: 0.8rem;
  font-weight: 800;
  color: #047857;
  min-width: 2.5rem;
  text-align: center;
  background: rgba(209, 250, 229, 0.9);
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(16, 185, 129, 0.3);
  cursor: pointer;
}
/* כפתורי גופן בתחתית הקורא — ליד הגלילה האוטומטית */
.lux-sel-fbtn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid rgba(99, 102, 241, 0.35);
  background: linear-gradient(135deg, #eef2ff, #e0e7ff);
  color: #4338ca;
  font-size: 1.25rem;
  font-weight: 900;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(99, 102, 241, 0.18);
}
.lux-sel-foot-sep {
  width: 1px;
  height: 26px;
  background: rgba(0, 0, 0, 0.12);
  margin: 0 0.15rem;
}
html.dark .lux-sel-foot-sep { background: rgba(255, 255, 255, 0.15); }
.lux-tr-done {
  margin-right: auto;
  border: 1.5px solid rgba(201, 153, 58, 0.5);
  background: linear-gradient(135deg, #fdf9ec, #f6eed7);
  color: #7a5c1a;
  font-weight: 800;
  font-size: 0.82rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s ease;
}
.lux-tr-done-on {
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  box-shadow: 0 3px 12px rgba(224, 183, 79, 0.45);
}
#lux-track-reader {
  position: fixed;
  inset: 0;
  z-index: 240;
  display: flex;
  flex-direction: column;
  background: #faf9f6;
  direction: rtl;
}
html.dark #lux-track-reader { background: #0f172a; }

/* אנימציית ריחוף עדינה (בשימוש בסטוריז) */
@keyframes lux-season-float {
  from { transform: translateY(0) rotate(-6deg); }
  to { transform: translateY(-16px) rotate(8deg); }
}

/* ── מניעת "זליגת" גלילה מהפופאפים אל הרקע ── */
.lux-sheet-overlay,
.lux-sheet,
#lux-stories,
#lux-year-wheel,
#lux-nav-editor,
#lux-selichot-reader .lux-sel-area,
#lux-track-reader .lux-sel-area,
.lux-sel-chips {
  overscroll-behavior: contain;
}

/* ── מצב שבת — סצנת נרות ── */
#lux-shabbat-scene {
  position: relative;
  max-width: 560px;
  margin: 0 auto 1.2rem;
  padding: 1.6rem 1.2rem 1.3rem;
  border-radius: 1.8rem;
  background:
    radial-gradient(ellipse 90% 60% at 50% 0%, rgba(232, 193, 90, 0.14) 0%, transparent 60%),
    linear-gradient(165deg, rgba(8, 14, 33, 0.92), rgba(16, 26, 53, 0.94));
  border: 1.5px solid rgba(224, 183, 79, 0.5);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  overflow: hidden;
  animation: lux-selc-in 0.8s ease;
}
.lux-sbs-x {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  z-index: 3;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 1.9rem;
  height: 1.9rem;
  color: rgba(226, 232, 240, 0.8);
  cursor: pointer;
  font-size: 0.85rem;
}
.lux-sbs-dust { position: absolute; inset: 0; pointer-events: none; }
.lux-sbs-dust i {
  position: absolute;
  bottom: -6px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: rgba(242, 217, 138, 0.8);
  box-shadow: 0 0 8px rgba(242, 217, 138, 0.8);
  animation: lux-sbs-rise linear infinite;
  opacity: 0;
}
@keyframes lux-sbs-rise {
  0% { transform: translateY(0) scale(1); opacity: 0; }
  12% { opacity: 0.9; }
  100% { transform: translateY(-190px) scale(0.4); opacity: 0; }
}
.lux-sbs-candles {
  display: flex;
  justify-content: center;
  gap: 3rem;
  margin-bottom: 0.9rem;
}
.lux-sbs-candle { position: relative; width: 26px; height: 96px; }
.lux-sbs-body {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 62px;
  border-radius: 6px 6px 8px 8px;
  background: linear-gradient(180deg, #fdf6e3, #e8d9b8);
  box-shadow: inset -4px 0 8px rgba(161, 118, 42, 0.25);
}
.lux-sbs-wick {
  position: absolute;
  bottom: 60px;
  left: 50%;
  width: 2px;
  height: 7px;
  background: #3f2d10;
  transform: translateX(-50%);
}
.lux-sbs-flame {
  position: absolute;
  bottom: 65px;
  left: 50%;
  width: 16px;
  height: 30px;
  transform: translateX(-50%);
  background: radial-gradient(circle at 50% 78%, #fff7d6 0%, #ffd35c 42%, #ff9d2e 68%, rgba(255, 110, 40, 0) 100%);
  border-radius: 50% 50% 48% 52% / 62% 62% 38% 38%;
  animation: lux-flame 0.9s ease-in-out infinite alternate;
  transform-origin: 50% 100%;
}
.lux-sbs-glow {
  position: absolute;
  bottom: 46px;
  left: 50%;
  width: 78px;
  height: 78px;
  transform: translate(-50%, 0);
  background: radial-gradient(circle, rgba(255, 190, 90, 0.35) 0%, transparent 70%);
  border-radius: 50%;
  animation: lux-flame-glow 1.8s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes lux-flame {
  from { transform: translateX(-50%) scale(1) rotate(-2.5deg); }
  40% { transform: translateX(-52%) scale(1.06, 0.96) rotate(2deg); }
  to { transform: translateX(-48%) scale(0.95, 1.08) rotate(-1.5deg); }
}
@keyframes lux-flame-glow {
  from { opacity: 0.75; transform: translate(-50%, 0) scale(1); }
  to { opacity: 1; transform: translate(-50%, -4px) scale(1.12); }
}
.lux-sbs-title {
  text-align: center;
  color: #f2d98a;
  font-family: var(--lux-serif);
  font-weight: 900;
  font-size: clamp(1.7rem, 7vw, 2.3rem);
  text-shadow: 0 0 26px rgba(232, 193, 90, 0.45);
  margin-bottom: 0.2rem;
}
.lux-sbs-parsha {
  text-align: center;
  color: rgba(191, 219, 254, 0.9);
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.45rem;
}
.lux-sbs-times {
  text-align: center;
  color: rgba(226, 232, 240, 0.85);
  font-size: 0.85rem;
  font-weight: 600;
}
.lux-sbs-times b { color: #f2d98a; }
/* הספירה לאחור מקבלת הדגשה כשמצב שבת פעיל */
body.lux-shabbat-scene-on #shabbat-countdown-wrap {
  background: rgba(232, 193, 90, 0.1);
  border: 1px solid rgba(224, 183, 79, 0.45);
  border-radius: 1.2rem;
  padding: 0.55rem 1.2rem;
  box-shadow: 0 0 24px rgba(224, 183, 79, 0.22);
}
body.lux-shabbat-scene-on #countdown-display {
  color: #f2d98a !important;
  text-shadow: 0 0 18px rgba(232, 193, 90, 0.5);
}

/* ── כפתור הסטוריז — בסרגל העליון, ליד השיתוף והמצפן ── */
#lux-story-ring {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}
.lux-sr-ring {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  padding: 3px;
  background: conic-gradient(#e0b74f, #f2d98a, #c9993a, #fdf3d0, #e0b74f);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: lux-sr-pulse 2.4s ease-in-out infinite;
  box-shadow: 0 0 16px rgba(224, 183, 79, 0.45);
}
@keyframes lux-sr-pulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 12px rgba(224, 183, 79, 0.4); }
  50% { transform: scale(1.07); box-shadow: 0 0 22px rgba(224, 183, 79, 0.7); }
}
.lux-sr-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(160deg, #0c1530, #16233f);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
}
@media (prefers-reduced-motion: reduce) {
  .lux-sr-ring { animation: none; }
}

/* ── הסטוריז עצמם ── */
#lux-stories {
  position: fixed;
  inset: 0;
  z-index: 14000;
  background: #04070f;
  direction: rtl;
  overflow: hidden;
  animation: lux-st-in 0.28s ease;
  touch-action: pan-y;
}
@keyframes lux-st-in {
  from { opacity: 0; transform: scale(1.04); }
  to { opacity: 1; transform: none; }
}
.lux-st-bars {
  position: absolute;
  top: calc(0.6rem + env(safe-area-inset-top));
  left: 0.7rem;
  right: 0.7rem;
  display: flex;
  gap: 4px;
  z-index: 5;
}
.lux-st-bar {
  flex: 1;
  height: 3.5px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.22);
  overflow: hidden;
  direction: ltr;
}
.lux-st-bar i {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #e0b74f, #f2d98a);
  border-radius: 2px;
}
.lux-st-bar.lux-st-done i { width: 100%; }
@keyframes lux-st-fill { from { width: 0%; } to { width: 100%; } }
.lux-st-x {
  position: absolute;
  top: calc(1.4rem + env(safe-area-inset-top));
  left: 1rem;
  z-index: 6;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  border-radius: 50%;
  width: 2.3rem;
  height: 2.3rem;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
}
.lux-st-tap {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 38%;
  z-index: 4;
}
.lux-st-tap-next { left: 0; }
.lux-st-tap-prev { right: 0; }
.lux-st-slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 3.5rem 1.6rem;
  animation: lux-st-slide-in 0.4s ease;
  background:
    radial-gradient(ellipse 120% 60% at 50% -5%, rgba(232, 193, 90, 0.14) 0%, transparent 55%),
    linear-gradient(165deg, #050b1a 0%, #0c1530 55%, #16233f 100%);
}
@keyframes lux-st-slide-in {
  from { opacity: 0; transform: translateX(-14px); }
  to { opacity: 1; transform: none; }
}
.lux-st-slide.lux-st-pearl {
  background:
    radial-gradient(ellipse 120% 60% at 50% -5%, rgba(167, 139, 250, 0.16) 0%, transparent 55%),
    linear-gradient(165deg, #0c0a1f 0%, #1e1b4b 60%, #0c0a1f 100%);
}
.lux-st-slide.lux-st-selichot {
  background:
    radial-gradient(ellipse 120% 60% at 50% -5%, rgba(232, 193, 90, 0.2) 0%, transparent 55%),
    linear-gradient(165deg, #1a1205 0%, #2b1d08 55%, #16233f 100%);
}
.lux-st-big {
  font-size: 3.4rem;
  margin-bottom: 0.8rem;
  filter: drop-shadow(0 0 18px rgba(232, 193, 90, 0.4));
  animation: lux-season-float 3.5s ease-in-out infinite alternate;
}
.lux-st-slide h2 {
  color: #f2d98a;
  font-family: var(--lux-serif);
  font-weight: 900;
  font-size: clamp(1.7rem, 7.5vw, 2.4rem);
  margin: 0 0 0.7rem;
  text-shadow: 0 0 30px rgba(232, 193, 90, 0.35);
}
.lux-st-heb {
  color: #fff;
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0 0 0.3rem;
}
.lux-st-sub {
  color: rgba(191, 219, 254, 0.75);
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0.3rem 0 0;
}
.lux-st-line {
  color: #e8eefc;
  font-size: 1.12rem;
  line-height: 1.9;
  font-weight: 600;
  margin: 0.3rem 0;
}
.lux-st-line b, .lux-st-range { color: #f2d98a; }
.lux-st-range { font-size: 1.5rem; display: inline-block; margin-top: 0.4rem; }
.lux-st-next {
  color: #f2d98a;
  font-weight: 800;
  font-size: 1.05rem;
  background: rgba(232, 193, 90, 0.12);
  border: 1px solid rgba(224, 183, 79, 0.4);
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  margin: 0 0 1rem;
}
.lux-st-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  max-width: 330px;
}
.lux-st-chip {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(148, 180, 255, 0.25);
  color: #dbe7ff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
}
.lux-st-chip b { color: #f2d98a; }
.lux-st-quote {
  color: #fff;
  font-family: var(--lux-serif);
  font-size: clamp(1.15rem, 5vw, 1.5rem);
  line-height: 2;
  font-weight: 700;
  max-width: 340px;
  margin: 0 0 0.8rem;
}
.lux-st-src { color: rgba(196, 181, 253, 0.85); font-size: 0.85rem; font-weight: 700; }
.lux-st-ctas {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 1.4rem;
  z-index: 6;
  position: relative;
  width: min(88vw, 300px);
}
.lux-st-cta {
  border: none;
  cursor: pointer;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  font-weight: 900;
  font-size: 0.95rem;
  padding: 0.75rem 1.4rem;
  border-radius: 1rem;
  box-shadow: 0 8px 24px rgba(224, 183, 79, 0.45);
  width: 100%;
}
.lux-st-cta:active { transform: scale(0.97); }

/* ── מתג הגדרות (סוויץ') ── */
.lux-sw {
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.4);
  position: relative;
  transition: background 0.25s ease;
  flex-shrink: 0;
  display: inline-block;
}
.lux-sw-dot {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.25s ease;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}
.lux-sw-on { background: linear-gradient(135deg, #e0b74f, #c9993a); }
.lux-sw-on .lux-sw-dot { transform: translateX(-18px); }

/* ── שעון הלכתי ── */
#lux-hc-btn {
  border: 1px solid rgba(224, 183, 79, 0.5);
  background: rgba(232, 193, 90, 0.1);
  color: #c9993a;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  margin-inline-end: 0.4rem;
}
.lux-hc-num { fill: #7a5c1a; font-size: 16px; font-weight: 800; font-family: 'Frank Ruhl Libre', serif; }
.lux-hc-num-n { fill: #d9c48a; }
.lux-hc-tick { stroke: rgba(161, 118, 42, 0.6); stroke-width: 2; }
.lux-hc-hand {
  stroke: url(#lux-hch);
  stroke-width: 5;
  stroke-linecap: round;
}
.lux-hc-mark {
  fill: #e0b74f;
  stroke: #a1762a;
  stroke-width: 1;
}
.lux-hc-mark-past { fill: rgba(148, 163, 184, 0.45); }
.lux-hc-mklbl {
  fill: rgba(122, 92, 26, 0.95);
  font-size: 8.5px;
  font-weight: 800;
  /* הילה בהירה סביב האותיות — התווית קריאה גם מעל שנתות וקשתות */
  paint-order: stroke;
  stroke: rgba(255, 250, 232, 0.85);
  stroke-width: 2.4px;
  stroke-linejoin: round;
}
.lux-hc-mklbl-n {
  fill: rgba(230, 212, 158, 0.98);
  stroke: rgba(6, 12, 29, 0.85);
}
.lux-hc-mklbl-past { opacity: 0.45; }
.lux-hc-leader { stroke: rgba(161, 118, 42, 0.35); stroke-width: 1; stroke-dasharray: 2 3; }
.lux-hc-dig {
  fill: #7a3c09;
  font-size: 16px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}
.lux-hc-dig-n { fill: #f2d98a; }
.lux-hc-sub2 { fill: #a1762a; font-size: 10px; font-weight: 800; }
.lux-hc-spin { animation: lux-hc-rot 60s linear infinite; }
@keyframes lux-hc-rot { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .lux-hc-spin { animation: none; } }
/* תגית מצב השעון — מעל לשעון, לא מתנגשת בציור */
.lux-hc-badge {
  width: fit-content;
  margin: 0 auto 0.6rem;
  font-size: 0.82rem;
  font-weight: 900;
  color: #7a5c1a;
  background: rgba(232, 193, 90, 0.16);
  border: 1px solid rgba(201, 153, 58, 0.45);
  border-radius: 999px;
  padding: 0.3rem 1rem;
}
.lux-hc-badge-n {
  color: #dbe7ff;
  background: rgba(16, 26, 53, 0.75);
  border-color: rgba(148, 180, 255, 0.35);
}
.lux-hc-next {
  text-align: center;
  font-weight: 800;
  font-size: 0.92rem;
  color: #a1762a;
  background: rgba(232, 193, 90, 0.12);
  border: 1px solid rgba(201, 153, 58, 0.35);
  border-radius: 999px;
  padding: 0.45rem 1rem;
  margin-bottom: 0.6rem;
}
html.dark .lux-hc-next { color: #f2d98a; }
.lux-hc-next b { color: #b45309; }
html.dark .lux-hc-next b { color: #fdf3d0; }
.lux-hc-pbar {
  height: 7px;
  border-radius: 4px;
  background: rgba(201, 153, 58, 0.18);
  overflow: hidden;
}
.lux-hc-pfill {
  height: 100%;
  background: linear-gradient(90deg, #c9993a, #f2d98a);
  border-radius: 4px;
  box-shadow: 0 0 8px rgba(224, 183, 79, 0.6);
  transition: width 1s linear;
}
.lux-hc-pct {
  text-align: center;
  font-size: 0.72rem;
  font-weight: 700;
  opacity: 0.75;
  margin: 0.25rem 0 0.5rem;
}
#lux-hc-info { margin-top: 0.8rem; }
.lux-hc-row {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.45rem 0.2rem;
  border-bottom: 1px dashed rgba(161, 118, 42, 0.25);
  font-size: 0.9rem;
  color: inherit;
}
.lux-hc-row b { color: #b45309; }
html.dark .lux-hc-row b { color: #f2d98a; }
.lux-hc-note {
  margin-top: 0.6rem;
  font-size: 0.75rem;
  line-height: 1.7;
  opacity: 0.75;
}

/* ── כרטיס שנה טובה ── */
.lux-sn-designs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.45rem;
  margin-bottom: 0.6rem;
}
.lux-sn-d {
  border: 2px solid transparent;
  border-radius: 0.8rem;
  padding: 0.7rem 0.3rem;
  font-weight: 800;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lux-sn-d-on {
  border-color: #e0b74f;
  box-shadow: 0 0 0 2px rgba(224, 183, 79, 0.35), 0 4px 14px rgba(224, 183, 79, 0.3);
  transform: scale(1.04);
}
#lux-shana-entry {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
  margin: 0 0 1.5rem;
  padding: 0.95rem 1.2rem;
  border-radius: 1.4rem;
  cursor: pointer;
  direction: rtl;
  text-align: right;
  border: 1.5px dashed rgba(224, 183, 79, 0.6);
  background: linear-gradient(135deg, rgba(232, 193, 90, 0.1), rgba(232, 193, 90, 0.04));
  transition: all 0.2s ease;
}
#lux-shana-entry:hover { background: rgba(232, 193, 90, 0.16); }
.lux-se-emo { font-size: 1.7rem; flex-shrink: 0; }
.lux-se-txt { flex: 1; display: flex; flex-direction: column; }
.lux-se-txt b { color: #a1762a; font-size: 0.98rem; }
html.dark .lux-se-txt b { color: #f2d98a; }
.lux-se-txt small { color: #94a3b8; font-size: 0.75rem; margin-top: 0.1rem; }
.lux-se-go { color: #c9993a; font-weight: 900; font-size: 1.1rem; }

/* ── ממיר תאריכים ── */
.lux-dt-sec { margin-bottom: 1rem; text-align: right; }
.lux-dt-sec h4 {
  font-size: 0.88rem;
  font-weight: 800;
  color: #a1762a;
  margin: 0 0 0.45rem;
}
html.dark .lux-dt-sec h4 { color: #f2d98a; }
.lux-dt-out {
  margin-top: 0.45rem;
  padding: 0.6rem 0.8rem;
  border-radius: 0.8rem;
  background: rgba(232, 193, 90, 0.1);
  border: 1px solid rgba(201, 153, 58, 0.3);
  font-size: 0.88rem;
  line-height: 1.7;
  min-height: 1.4rem;
}
.lux-dt-out b { color: #b45309; }
html.dark .lux-dt-out b { color: #f2d98a; }

/* ── מסלולי הלימוד היומיים ── */
#lux-tracks-row { margin: 0 0 1.6rem; }
.lux-tracks-title {
  font-size: 1.02rem;
  font-weight: 900;
  color: #a1762a;
  margin: 0 0 0.6rem;
  text-align: right;
}
html.dark .lux-tracks-title { color: #f2d98a; }
.lux-tracks-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
}
.lux-track-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 0.85rem 0.5rem 0.7rem;
  border-radius: 1.2rem;
  cursor: pointer;
  border: 1.5px solid rgba(201, 153, 58, 0.35);
  background: linear-gradient(165deg, #fffdf6, #faf3df);
  box-shadow: 0 4px 14px rgba(161, 118, 42, 0.12);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
  text-align: center;
}
.lux-track-card:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(161, 118, 42, 0.22); }
.lux-track-card:active { transform: scale(0.97); }
html.dark .lux-track-card {
  background: linear-gradient(165deg, #101a35, #0c1530);
  border-color: rgba(224, 183, 79, 0.3);
}
.lux-tc-icon { font-size: 1.6rem; }
.lux-tc-name { font-weight: 900; font-size: 0.9rem; color: var(--tc, #1d4ed8); }
html.dark .lux-tc-name { color: #f2d98a; }
.lux-tc-ref {
  font-size: 0.68rem;
  color: #94a3b8;
  font-weight: 600;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lux-tc-badge {
  font-size: 0.7rem;
  font-weight: 800;
  color: #a1762a;
  background: rgba(232, 193, 90, 0.15);
  border: 1px solid rgba(201, 153, 58, 0.3);
  padding: 0.18rem 0.6rem;
  border-radius: 999px;
  margin-top: 0.15rem;
}
.lux-tc-badge.lux-tc-done {
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  border-color: #a1762a;
}
@media (max-width: 480px) {
  .lux-tc-ref { display: none; }
  .lux-tracks-grid { gap: 0.45rem; }
  .lux-tc-name { font-size: 0.82rem; }
}
/* ═══════════════════════════════════════════════════════════════════
   LUX 7 — שעון הלכתי מלא, כרטיסי ברכה משודרגים, המרת תאריכים,
   גרירת כפתורי תפילה חלקה
   ═══════════════════════════════════════════════════════════════════ */

/* ── השעון ההלכתי: לוח כל זמני היום ── */
#lux-hc-modal .lux-sheet { max-width: 600px; }
.lux-hc-sched {
  margin-top: 1.1rem;
  text-align: right;
}
.lux-hc-sched-title {
  font-family: 'Frank Ruhl Libre', serif;
  font-size: 1rem;
  font-weight: 900;
  color: #7a5c1a;
  margin: 0 0 0.55rem;
  text-align: center;
}
html.dark .lux-hc-sched-title { color: #f2d98a; }
.lux-hc-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.32rem;
}
@media (min-width: 540px) {
  .lux-hc-grid { grid-template-columns: 1fr 1fr; }
}
.lux-hc-zrow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.42rem 0.7rem;
  border-radius: 0.7rem;
  background: linear-gradient(135deg, #fdf9ec, #f7efdb);
  border: 1px solid rgba(201, 153, 58, 0.28);
  font-size: 0.83rem;
  font-weight: 700;
  color: #3d2f0e;
  min-width: 0;
}
.lux-hc-zname {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.lux-hc-zemo { flex-shrink: 0; }
.lux-hc-ztime {
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  color: #7a5c1a;
  flex-shrink: 0;
  direction: ltr;
}
.lux-hc-zpast { opacity: 0.55; }
.lux-hc-zpast .lux-hc-ztime { color: #059669; }
.lux-hc-znext {
  background: linear-gradient(135deg, #f9edc8, #f2dfa4);
  border-color: #c9993a;
  box-shadow: 0 3px 12px rgba(224, 183, 79, 0.35);
}
.lux-hc-zin {
  font-size: 0.68rem;
  font-weight: 800;
  color: #92400e;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(201, 153, 58, 0.4);
  padding: 0.1rem 0.5rem;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}
html.dark .lux-hc-zrow {
  background: linear-gradient(135deg, #16233f, #101a35);
  border-color: rgba(224, 183, 79, 0.22);
  color: #e2e8f0;
}
html.dark .lux-hc-ztime { color: #f2d98a; }
html.dark .lux-hc-znext {
  background: linear-gradient(135deg, #2a2410, #3a3012);
  border-color: #c9993a;
}
html.dark .lux-hc-zin {
  background: rgba(0, 0, 0, 0.35);
  color: #f2d98a;
}

/* ── מחולל כרטיסי הברכה: בחירת פונט ── */
.lux-sn-fonts {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  justify-content: center;
  margin: 0.15rem 0 0.5rem;
}
.lux-sn-f {
  border: 1.5px solid rgba(201, 153, 58, 0.4);
  background: #fdfaf1;
  color: #3d2f0e;
  font-size: 1rem;
  font-weight: 700;
  padding: 0.3rem 0.85rem;
  border-radius: 0.7rem;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lux-sn-f-on {
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  border-color: #a1762a;
  box-shadow: 0 3px 10px rgba(224, 183, 79, 0.4);
}
html.dark .lux-sn-f { background: #16233f; color: #e2e8f0; }
html.dark .lux-sn-f-on {
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
}

/* ── המרת תאריכים: תוצאות מעוצבות ── */
.lux-dt-big {
  font-family: 'Frank Ruhl Libre', serif;
  font-size: 1.08rem;
  font-weight: 900;
  color: #3d2f0e;
  margin-bottom: 0.2rem;
}
html.dark .lux-dt-big { color: #f2d98a; }
.lux-dt-chip {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 800;
  color: #1e40af;
  background: rgba(191, 219, 254, 0.5);
  border: 1px solid rgba(59, 130, 246, 0.3);
  padding: 0.1rem 0.55rem;
  border-radius: 999px;
  margin-inline-start: 0.3rem;
  white-space: nowrap;
}
.lux-dt-chip-today {
  color: #166534;
  background: rgba(187, 247, 208, 0.6);
  border-color: rgba(22, 163, 74, 0.4);
}
.lux-dt-chip-past {
  color: #6b7280;
  background: rgba(229, 231, 235, 0.6);
  border-color: rgba(107, 114, 128, 0.3);
}
html.dark .lux-dt-chip { background: rgba(30, 58, 138, 0.4); color: #93c5fd; }
html.dark .lux-dt-chip-today { background: rgba(20, 83, 45, 0.5); color: #86efac; }
html.dark .lux-dt-chip-past { background: rgba(55, 65, 81, 0.5); color: #9ca3af; }
.lux-dt-evs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.4rem;
}
.lux-dt-ev {
  font-size: 0.7rem;
  font-weight: 800;
  color: #7a5c1a;
  background: rgba(232, 193, 90, 0.18);
  border: 1px solid rgba(201, 153, 58, 0.35);
  padding: 0.14rem 0.6rem;
  border-radius: 999px;
}
html.dark .lux-dt-ev { color: #f2d98a; background: rgba(232, 193, 90, 0.12); }
.lux-dt-actions {
  display: flex;
  gap: 0.4rem;
  margin-top: 0.5rem;
}
.lux-dt-mini {
  border: 1px solid rgba(201, 153, 58, 0.45);
  background: rgba(253, 249, 236, 0.9);
  color: #7a5c1a;
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lux-dt-mini:active { transform: scale(0.95); }
html.dark .lux-dt-mini { background: #16233f; color: #f2d98a; border-color: rgba(224, 183, 79, 0.35); }
.lux-dt-occ-list {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.lux-dt-occ {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  font-size: 0.8rem;
  padding: 0.35rem 0.6rem;
  border-radius: 0.6rem;
  background: rgba(253, 249, 236, 0.75);
  border: 1px solid rgba(201, 153, 58, 0.22);
  color: #3d2f0e;
}
.lux-dt-occ-first {
  background: linear-gradient(135deg, #f9edc8, #f2dfa4);
  border-color: #c9993a;
  font-weight: 800;
}
html.dark .lux-dt-occ { background: #16233f; color: #e2e8f0; border-color: rgba(224, 183, 79, 0.2); }
html.dark .lux-dt-occ-first { background: linear-gradient(135deg, #2a2410, #3a3012); border-color: #c9993a; }

/* ── סידור כפתורי התפילות: גרירה חלקה ── */
.po-tile { transition: none; }
.po-tile.po-dragging { box-shadow: inset 0 0 0 2px rgba(251, 191, 36, 0.6); border-radius: 0.8rem; }

/* ── תחתית קוראי הסליחות/מסלולים — לא נשברת במסכים צרים ── */
.lux-sel-foot { flex-wrap: wrap; }

/* ═══════════════════════════════════════════════════════════════════
   LUX 8 — סדר לימוד אישי, המרת תאריכים ידידותית, תג פרימיום, מרקר
   ═══════════════════════════════════════════════════════════════════ */

/* ── תחתית קוראי הלימוד (סדר אישי + מסלולים יומיים) — במובייל כפתור
   "למדתי/סיימתי" עובר לשורה משלו כדי שלא ידחוף את שאר הכפתורים החוצה ── */
@media (max-width: 520px) {
  #lux-plan-reader .lux-sel-foot,
  #lux-track-reader .lux-sel-foot {
    flex-wrap: wrap;
    row-gap: 0.45rem;
    padding-bottom: 0.6rem;
  }
  #lux-pl-done,
  #lux-tr-done {
    flex-basis: 100%;
    order: 10;
    margin-right: 0;
    text-align: center;
  }
}

/* ── קריאת שמע — הפסוק הראשון ו"ברוך שם" מובלטים ── */
.shema-main {
  font-size: 1.32em;
  font-weight: 800;
  line-height: 1.9;
}
.shema-baruch {
  font-size: 1.14em;
  font-weight: 700;
}

/* ── גלגל השנה — זום חודשי: אייקוני החודש הנבחר מרחפים ומתרחבים ── */
#lux-yw-svg .lux-yw-evt {
  transition: transform 0.32s cubic-bezier(0.34, 1.4, 0.64, 1), opacity 0.25s ease;
  transform-box: fill-box;
  transform-origin: center;
  cursor: pointer;
}
#lux-yw-svg.lux-yw-zoommode .lux-yw-evt { opacity: 0.18; pointer-events: none; }
#lux-yw-svg.lux-yw-zoommode .lux-yw-evt.lux-yw-zoomed { opacity: 1; pointer-events: auto; }
#lux-yw-svg .lux-yw-evt.lux-yw-zoomed .lux-yw-halo {
  fill: rgba(232, 193, 90, 0.28);
  stroke: rgba(232, 193, 90, 0.85);
  stroke-width: 1.5;
  filter: drop-shadow(0 0 6px rgba(232, 193, 90, 0.7));
}

/* ── סדר לימוד אישי — נושאי כלים בקורא ── */
.lux-pl-cmbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: rgba(232, 193, 90, 0.08);
  border-bottom: 1px solid rgba(201, 153, 58, 0.25);
  direction: rtl;
}
.lux-pl-cmbar-lbl {
  font-size: 0.72rem;
  font-weight: 800;
  color: #7a5c1a;
}
html.dark .lux-pl-cmbar { background: rgba(232, 193, 90, 0.06); }
html.dark .lux-pl-cmbar-lbl { color: #f2d98a; }
.lux-pl-cmchip {
  border: 1.5px solid rgba(124, 58, 237, 0.35);
  background: rgba(124, 58, 237, 0.06);
  color: #6d28d9;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.24rem 0.75rem;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lux-pl-cmchip-on {
  background: rgba(124, 58, 237, 0.85);
  color: #fff;
  border-color: rgba(124, 58, 237, 0.9);
  box-shadow: 0 2px 8px rgba(124, 58, 237, 0.35);
}
html.dark .lux-pl-cmchip { background: rgba(124, 58, 237, 0.12); color: #c4b5fd; }
html.dark .lux-pl-cmchip-on { background: rgba(124, 58, 237, 0.8); color: #fff; }
.lux-pl-cm {
  margin: 0.6rem 0.4rem 1.1rem;
  padding: 0.7rem 0.9rem;
  background: rgba(124, 58, 237, 0.05);
  border: 1px solid rgba(124, 58, 237, 0.15);
  border-right: 4px solid rgba(124, 58, 237, 0.5);
  border-radius: 0.7rem;
  direction: rtl;
}
.lux-pl-cm-t {
  font-size: 0.78em;
  font-weight: 900;
  color: #6d28d9;
  margin-bottom: 0.35rem;
}
.lux-pl-cm-p {
  font-size: 0.88em;
  line-height: 1.9;
  color: #4c1d95;
  margin: 0 0 0.35em;
}
html.dark .lux-pl-cm { background: rgba(124, 58, 237, 0.1); }
html.dark .lux-pl-cm-t { color: #c4b5fd; }
html.dark .lux-pl-cm-p { color: #ddd6fe; }

/* ── פופאפ מצב הירח — לפני מעבר לברכת הלבנה ── */
#lux-moon-pop {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(10, 18, 40, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: lux-badge-fade 0.25s ease;
  direction: rtl;
}
.lux-moon-pop-in {
  background: linear-gradient(170deg, #0f1c3f, #1e2a52 55%, #16213f);
  border: 1.5px solid rgba(148, 187, 255, 0.35);
  border-radius: 1.5rem;
  padding: 1.5rem 2rem 1.2rem;
  text-align: center;
  max-width: 21rem;
  width: calc(100vw - 3rem);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.55), 0 0 40px rgba(96, 165, 250, 0.15);
  animation: lux-badge-pop 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.lux-moon-pop-face {
  display: block;
  font-size: 4rem;
  line-height: 1;
  margin-bottom: 0.5rem;
  filter: drop-shadow(0 0 18px rgba(226, 232, 240, 0.45));
}
.lux-moon-pop-in h3 { color: #dbeafe; font-size: 0.95rem; font-weight: 800; margin: 0 0 0.2rem; }
.lux-moon-pop-day { color: #e2e8f0; font-size: 0.9rem; margin: 0 0 0.8rem; }
.lux-moon-pop-day b { color: #fde68a; font-size: 1.05rem; }
.lux-moon-pop-track {
  height: 5px;
  border-radius: 999px;
  background: rgba(148, 187, 255, 0.18);
  overflow: hidden;
  margin-bottom: 0.45rem;
}
.lux-moon-pop-fill {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #60a5fa, #93c5fd);
  animation: lux-moon-fill 4.6s linear forwards;
}
@keyframes lux-moon-fill { from { width: 0; } to { width: 100%; } }
.lux-moon-pop-note { color: #94a3b8; font-size: 0.72rem; margin: 0 0 0.9rem; }
.lux-moon-pop-btns { display: flex; gap: 0.5rem; align-items: center; }
.lux-moon-pop-go {
  flex: 1;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  font-size: 0.85rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.45);
}
.lux-moon-pop-x {
  flex-shrink: 0;
  background: rgba(148, 163, 184, 0.15);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.3);
  border-radius: 50%;
  width: 2.3rem;
  height: 2.3rem;
  cursor: pointer;
  font-size: 0.9rem;
}
@media (prefers-reduced-motion: reduce) {
  .lux-moon-pop-in, .lux-moon-pop-fill { animation: none; }
  .lux-moon-pop-fill { width: 100%; }
}

/* ── חיפוש ספרים — ספינר סטטוס ── */
.sn-spin {
  display: inline-block;
  width: 0.85rem;
  height: 0.85rem;
  border: 2px solid rgba(99, 102, 241, 0.25);
  border-top-color: #6366f1;
  border-radius: 50%;
  animation: sn-spin-rot 0.7s linear infinite;
  flex-shrink: 0;
}
@keyframes sn-spin-rot { to { transform: rotate(360deg); } }

/* ── סדר לימוד אישי — סליידרים באשף ── */
.lux-pw-slider-row {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin: 0.3rem 0 0.6rem;
}
.lux-pw-range {
  flex: 1;
  -webkit-appearance: none;
  appearance: none;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(201, 153, 58, 0.55), rgba(232, 193, 90, 0.25));
  outline: none;
  cursor: pointer;
}
.lux-pw-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  border: 2.5px solid #fff;
  box-shadow: 0 2px 8px rgba(160, 120, 30, 0.45);
  cursor: grab;
}
.lux-pw-range::-moz-range-thumb {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  border: 2.5px solid #fff;
  box-shadow: 0 2px 8px rgba(160, 120, 30, 0.45);
  cursor: grab;
}
.lux-pw-slider-val {
  flex-shrink: 0;
  min-width: 5.5rem;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 900;
  color: #7a5c1a;
  background: rgba(232, 193, 90, 0.16);
  border: 1px solid rgba(201, 153, 58, 0.4);
  border-radius: 999px;
  padding: 0.3rem 0.6rem;
}
html.dark .lux-pw-slider-val { color: #f2d98a; background: rgba(232, 193, 90, 0.1); }
.lux-pw-books { max-height: 38vh; overflow-y: auto; }

/* ── רצף לימוד — תג להבה בכותרת ── */
.lux-plan-streak {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 900;
  color: #b45309;
  background: rgba(251, 191, 36, 0.2);
  border: 1px solid rgba(245, 158, 11, 0.45);
  border-radius: 999px;
  padding: 0.1rem 0.55rem;
  margin-right: 0.35rem;
  vertical-align: middle;
}
html.dark .lux-plan-streak { color: #fbbf24; background: rgba(251, 191, 36, 0.12); }

/* ── פופאפ "תג חדש נפתח" ── */
.lux-badge-pop {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  animation: lux-badge-fade 0.3s ease;
  cursor: pointer;
}
.lux-badge-pop-in {
  background: linear-gradient(160deg, #fffbeb, #fef3c7);
  border: 2px solid rgba(201, 153, 58, 0.6);
  border-radius: 1.5rem;
  padding: 1.6rem 2.2rem;
  text-align: center;
  max-width: 20rem;
  box-shadow: 0 20px 60px rgba(120, 80, 10, 0.35), 0 0 0 6px rgba(232, 193, 90, 0.15);
  animation: lux-badge-pop 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.lux-badge-ico {
  display: block;
  font-size: 3.2rem;
  margin-bottom: 0.4rem;
  animation: lux-badge-bounce 1.1s ease infinite alternate;
}
.lux-badge-pop-in h3 { color: #92400e; font-size: 1.1rem; font-weight: 900; margin: 0 0 0.25rem; }
.lux-badge-pop-in p { color: #78350f; font-size: 0.95rem; font-weight: 800; margin: 0 0 0.6rem; }
.lux-badge-pop-in small { color: #a16207; font-size: 0.7rem; line-height: 1.5; display: block; }
.lux-badge-pop-out { opacity: 0; transition: opacity 0.45s ease; }
@keyframes lux-badge-pop {
  0% { transform: scale(0.4); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes lux-badge-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lux-badge-bounce { from { transform: translateY(0); } to { transform: translateY(-7px); } }
@media (prefers-reduced-motion: reduce) {
  .lux-badge-pop-in, .lux-badge-ico { animation: none; }
}

/* ── תג "בניית אתר פרימיום" — הבהוב זוהר עדין כל כמה שניות ── */
@keyframes lux-premium-pulse {
  0%, 78%, 100% {
    box-shadow: 0 0 22px rgba(232, 193, 90, 0.28), 0 0 38px rgba(59, 130, 246, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.15);
  }
  86% {
    box-shadow: 0 0 34px rgba(232, 193, 90, 0.65), 0 0 60px rgba(59, 130, 246, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  }
}
.lux-premium-badge { animation: lux-premium-pulse 4.5s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) {
  .lux-premium-badge { animation: none; }
}

/* ── המרת תאריכים — הסברים ותוויות ── */
.lux-dt-help {
  font-size: 0.76rem;
  color: #7a6a3a;
  line-height: 1.7;
  margin: 0 0 0.55rem;
  font-weight: 600;
}
html.dark .lux-dt-help { color: #b8a97a; }
.lux-dt-lbl {
  display: block;
  font-size: 0.68rem;
  font-weight: 800;
  color: #8a7434;
  margin: 0 0 0.2rem;
}
html.dark .lux-dt-lbl { color: #d9c48a; }

/* ── סדר לימוד אישי — כרטיסים בדף הראשי ── */
#lux-plan-row {
  max-width: 560px;
  margin: 0 auto 1.2rem;
  padding: 0 0.5rem;
}
.lux-plan-empty {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  width: 100%;
  text-align: right;
  padding: 1rem 1.2rem;
  border-radius: 1.2rem;
  border: 2px dashed rgba(201, 153, 58, 0.5);
  background: linear-gradient(135deg, rgba(253, 249, 236, 0.9), rgba(247, 239, 219, 0.9));
  color: #5a4713;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 0.85rem;
  line-height: 1.6;
}
.lux-plan-empty:hover { border-color: #c9993a; box-shadow: 0 6px 20px rgba(224, 183, 79, 0.25); }
.lux-plan-empty small { color: #8a7434; font-weight: 600; }
.lux-plan-plus {
  flex-shrink: 0;
  width: 2.6rem;
  height: 2.6rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  font-size: 1.6rem;
  font-weight: 900;
  box-shadow: 0 4px 12px rgba(224, 183, 79, 0.4);
}
html.dark .lux-plan-empty {
  background: linear-gradient(135deg, #16233f, #101a35);
  color: #e2e8f0;
  border-color: rgba(224, 183, 79, 0.35);
}
html.dark .lux-plan-empty small { color: #94a3b8; }
.lux-plan-card {
  background: linear-gradient(135deg, #fdf9ec, #f7efdb);
  border: 1.5px solid rgba(201, 153, 58, 0.35);
  border-radius: 1.1rem;
  padding: 0.85rem 1rem;
  margin-bottom: 0.6rem;
  box-shadow: 0 3px 12px rgba(160, 120, 40, 0.12);
}
html.dark .lux-plan-card {
  background: linear-gradient(135deg, #16233f, #101a35);
  border-color: rgba(224, 183, 79, 0.25);
}
.lux-plan-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}
.lux-plan-name {
  font-family: 'Frank Ruhl Libre', serif;
  font-weight: 900;
  font-size: 0.95rem;
  color: #3d2f0e;
}
html.dark .lux-plan-name { color: #f2d98a; }
.lux-plan-del {
  background: none;
  border: none;
  color: #b0a070;
  cursor: pointer;
  font-size: 0.85rem;
  padding: 0.15rem 0.35rem;
  border-radius: 50%;
}
.lux-plan-del:hover { color: #b45309; }
.lux-plan-bar {
  height: 9px;
  border-radius: 999px;
  background: rgba(201, 153, 58, 0.18);
  overflow: hidden;
  margin-bottom: 0.4rem;
}
.lux-plan-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #e0b74f, #c9993a);
  box-shadow: 0 0 8px rgba(224, 183, 79, 0.5);
  transition: width 0.6s ease;
}
.lux-plan-stats {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  font-weight: 700;
  color: #8a7434;
  margin-bottom: 0.6rem;
}
html.dark .lux-plan-stats { color: #b8a97a; }
.lux-plan-open {
  width: 100%;
  border: 1.5px solid rgba(201, 153, 58, 0.5);
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  font-weight: 900;
  font-size: 0.85rem;
  padding: 0.55rem;
  border-radius: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.lux-plan-open:hover { box-shadow: 0 4px 14px rgba(224, 183, 79, 0.45); }
.lux-plan-open-done {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  color: #047857;
  border-color: rgba(16, 185, 129, 0.4);
}
.lux-plan-more {
  width: 100%;
  border: 1.5px dashed rgba(201, 153, 58, 0.45);
  background: none;
  color: #8a7434;
  font-weight: 800;
  font-size: 0.8rem;
  padding: 0.5rem;
  border-radius: 0.8rem;
  cursor: pointer;
  margin-top: 0.2rem;
}
html.dark .lux-plan-more { color: #d9c48a; }

/* ── אשף סדר הלימוד ── */
.lux-pw-step {
  font-family: 'Frank Ruhl Libre', serif;
  font-size: 0.95rem;
  font-weight: 900;
  color: #7a5c1a;
  margin: 0.9rem 0 0.5rem;
  text-align: right;
}
html.dark .lux-pw-step { color: #f2d98a; }
.lux-pw-books {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.4rem;
  max-height: 220px;
  overflow-y: auto;
  padding: 0.2rem;
}
.lux-pw-book {
  border: 1.5px solid rgba(201, 153, 58, 0.35);
  background: #fdfaf1;
  color: #3d2f0e;
  border-radius: 0.8rem;
  padding: 0.55rem 0.6rem;
  font-size: 0.8rem;
  font-weight: 800;
  cursor: pointer;
  text-align: right;
  line-height: 1.4;
  transition: all 0.15s ease;
}
.lux-pw-book small {
  display: block;
  color: #8a7434;
  font-weight: 600;
  font-size: 0.68rem;
}
.lux-pw-book-on {
  background: linear-gradient(135deg, #e0b74f, #c9993a);
  color: #211603;
  border-color: #a1762a;
  box-shadow: 0 3px 10px rgba(224, 183, 79, 0.4);
}
.lux-pw-book-on small { color: #4a3a10; }
html.dark .lux-pw-book { background: #16233f; color: #e2e8f0; }
html.dark .lux-pw-book small { color: #94a3b8; }
html.dark .lux-pw-book-on { background: linear-gradient(135deg, #e0b74f, #c9993a); color: #211603; }
html.dark .lux-pw-book-on small { color: #4a3a10; }
.lux-pw-mode-on {
  background: linear-gradient(135deg, #e0b74f, #c9993a) !important;
  color: #211603 !important;
  border-color: #a1762a !important;
}

/* כותרת יחידה בקורא סדר הלימוד */
.lux-pl-unit {
  font-family: 'Frank Ruhl Libre', serif;
  text-align: center;
  color: #a1762a;
  font-size: 1.05em;
  font-weight: 900;
  margin: 1.6rem 0 0.8rem;
}
.lux-pl-unit::before, .lux-pl-unit::after { content: ' ✦ '; opacity: 0.6; font-size: 0.8em; }
html.dark .lux-pl-unit { color: #f2d98a; }
#lux-plan-reader {
  position: fixed;
  inset: 0;
  z-index: 240;
  display: flex;
  flex-direction: column;
  background: #faf9f6;
  direction: rtl;
}
html.dark #lux-plan-reader { background: #0f172a; }
#lux-plan-reader .lux-sel-area { overscroll-behavior: contain; }


/* ═══════════════════════════════════════════════════════
   ✦ הקפאת רקע בזמן פופאפ פתוח (html.lux-modal-open)
   כל שכבות הפופאפ הן backdrop-filter על כל המסך; כל אנימציה שרצה
   מתחתיהן מכריחה את ה-GPU לחשב מחדש את הטשטוש בכל פריים — זה היה
   מקור הריצוד בנייד. כשפופאפ פתוח משהים את אנימציות הרקע (הן ממילא
   מוסתרות) ומורידים את הטשטוש מסרגל הניווט התחתון. הכול חוזר לחיים
   מיד עם הסגירה. אין לגעת בתוכן הפופאפים עצמם — הם אחים ישירים של
   body ולכן לא נתפסים בסלקטורים האלה.
   ═══════════════════════════════════════════════════════ */
html.lux-modal-open #hero-section *,
html.lux-modal-open #main-content *,
html.lux-modal-open body > section *,
html.lux-modal-open body > footer *,
html.lux-modal-open #lux-bottom-nav *,
html.lux-modal-open #lux-shabbat-scene *,
html.lux-modal-open #pwa-install-banner * {
  animation-play-state: paused !important;
}
/* אחרי הניגון הראשון של כניסת הדשבורד — קריאות חוזרות ל-showDashboard
   לא מריצות שוב את fadeSlideUp מאפס (זה הבהב את ארבעת הכרטיסים) */
#dashboard-state.lux-anim-done article {
  animation: none !important;
  opacity: 1 !important;
  transform: none !important;
}


/* ═══════════════════════════════════════════════════════
   ✦ מובייל: פופאפים בלי backdrop-filter (תיקון "הבהוב בפתיחה")
   בטלפון הטשטוש של כל המסך לא מוכן בפריים הראשון של הפתיחה —
   השכבה מופיעה ואז הטשטוש "קופץ" פנימה פריים אחר-כך, מה שנראה
   כהבהוב/טעינה-כפולה בכל פתיחת פופאפ (בעיקר בשעון ההלכתי ובכרטיס
   שנה טובה). הרקעים ממילא כהים וכמעט אטומים — במובייל מוותרים על
   הטשטוש ומעלים מעט את האטימות; בדסקטופ מראה הזכוכית נשאר.
   ═══════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  [id$="-modal"],
  .lux-sheet-overlay,
  #lux-year-wheel,
  #lux-nav-editor,
  #lux-stories,
  #lux-moon-pop,
  .lux-badge-pop,
  #chapter-nav-popup,
  #cal-month-year-picker {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  .lux-sheet-overlay {
    background: rgba(2, 6, 23, 0.84);
  }
}


/* ═══════════════════════════════════════════════════════
   ✦ מובייל: חיסול גורף של backdrop-filter + כניסה מיידית ליריעות
   הכלל הקודם כיסה רק את שכבות-הרקע של הפופאפים, אבל נשארו טשטושים
   על אלמנטים פנימיים (סרגלי גופן/חיפוש דביקים בתוך קוראים, הכרטיס
   הפנימי של ספריא/חוק-לישראל, טוסטים) — וכל אחד מהם "קופץ" באיחור
   של פריים-שניים במובייל ונראה כהבהוב בתוך הפופאפ עצמו. לכן: במובייל
   אין טשטוש בשום מקום. פיצויי אטימות לבודדים שהיו שקופים מדי.
   אנימציית הכניסה של .lux-sheet מבוטלת במובייל — הופעה מיידית
   אינה יכולה להבהב (בדסקטופ הכול נשאר כשהיה).
   ═══════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  *,
  *::before,
  *::after {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  #lux-bottom-nav {
    background: rgba(9, 16, 36, 0.95) !important;
  }
  #sefaria-modal > div:first-child,
  #chok-israel-modal > div:first-child {
    background: rgba(250, 248, 243, 0.97) !important;
  }
  .lux-sheet {
    animation: none !important;
  }
}
