/* Именины и праздники (namedays) 1.1 — светлый стиль, жёлтый акцент, прямые углы */
.nd-wrap, .nd-w {
    --nd-accent: #f5c518;
    --nd-accent-dark: #c99a00;
    --nd-ink: #1d1d1f;
    --nd-muted: #6b6b70;
    --nd-line: rgba(0, 0, 0, .1);
    --nd-bg: #fff;
    --nd-soft: #fffbea;
    --nd-lv: #9e3039;
    --nd-ru: #3b5bdb;
    color: var(--nd-ink);
}
.nd-wrap *, .nd-w * { border-radius: 0 !important; box-sizing: border-box; }
.nd-wrap { max-width: 980px; margin: 0 auto; }

.nd-h1 { font-size: 1.45rem; font-weight: 800; margin: 0 0 12px; display: flex; gap: 10px; align-items: center; }
.nd-h1 i { color: var(--nd-accent-dark); }
.nd-h3 { font-size: 1rem; font-weight: 700; margin: 0 0 10px; display: flex; gap: 8px; align-items: center; }
.nd-h3 > i { color: var(--nd-accent-dark); }
.nd-h3-link { margin-left: auto; font-size: .85rem; font-weight: 600; }
.nd-muted { color: var(--nd-muted); }
.nd-small { font-size: .82rem; }

/* Навигация */
.nd-nav { display: flex; border: 1px solid var(--nd-line); background: var(--nd-bg); margin-bottom: 8px; overflow-x: auto; }
.nd-nav a { flex: 1 0 auto; display: flex; gap: 6px; align-items: center; justify-content: center; padding: 10px 12px; color: var(--nd-ink); text-decoration: none; font-weight: 600; font-size: .92rem; border-bottom: 3px solid transparent; white-space: nowrap; }
.nd-nav a:hover { background: var(--nd-soft); }
.nd-nav a.is-active { border-bottom-color: var(--nd-accent); background: var(--nd-soft); }
.nd-nav i { color: var(--nd-accent-dark); }

.nd-search { display: flex; align-items: center; border: 1px solid var(--nd-line); background: var(--nd-bg); margin-bottom: 14px; }
.nd-search > i { padding: 0 10px; color: var(--nd-muted); }
.nd-search input { flex: 1; min-width: 0; border: 0; padding: 10px 4px; font-size: 1rem; background: transparent; outline: none; color: inherit; }
.nd-search button { border: 0; background: var(--nd-accent); color: #1d1d1f; font-weight: 700; padding: 0 16px; align-self: stretch; cursor: pointer; }

/* Блоки */
.nd-box { background: var(--nd-bg); border: 1px solid var(--nd-line); padding: 14px; margin-bottom: 14px; }

.nd-today { display: grid; grid-template-columns: 150px 1fr; border: 1px solid var(--nd-line); margin-bottom: 14px; background: var(--nd-bg); }
.nd-today-date { background: var(--nd-accent); color: #1d1d1f; padding: 14px; display: flex; flex-direction: column; justify-content: center; }
.nd-today-day { font-size: 3.4rem; font-weight: 900; line-height: 1; }
.nd-today-meta b { display: block; font-size: 1.05rem; }
.nd-today-meta span { font-size: .85rem; opacity: .8; }
.nd-today-label { margin-top: 8px; font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; opacity: .75; }
.nd-today-body { padding: 14px; }
@media (max-width: 560px) {
    .nd-today { grid-template-columns: 1fr; }
    .nd-today-date { flex-direction: row; align-items: center; gap: 12px; }
    .nd-today-day { font-size: 2.6rem; }
    .nd-today-label { margin: 0 0 0 auto; }
}

/* Имена */
.nd-names { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 4px 0 8px; }
.nd-names-ext { font-size: .82rem; color: var(--nd-muted); gap: 6px; }
.nd-flag { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 24px; padding: 0 6px; font-size: .72rem; font-weight: 800; background: #eee; color: #555; }
.nd-flag-lv { background: var(--nd-lv); color: #fff; }
.nd-flag-ru { background: var(--nd-ru); color: #fff; }
.nd-chip { display: inline-flex; align-items: stretch; border: 1px solid var(--nd-line); background: var(--nd-bg); }
.nd-chip a { padding: 4px 9px; color: var(--nd-ink); text-decoration: none; font-weight: 600; }
.nd-chip a:hover { background: var(--nd-soft); }
.nd-chip .nd-chip-gift { padding: 4px 7px; border-left: 1px solid var(--nd-line); color: var(--nd-accent-dark); }

/* Праздники */
.nd-hols { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.nd-hol { display: inline-flex; gap: 6px; align-items: center; padding: 4px 9px; font-size: .85rem; font-weight: 600; background: #f3f3f3; }
.nd-hol small { font-weight: 700; color: var(--nd-lv); }
.nd-hol-lv { background: #fbeaec; }
.nd-hol-lv i { color: var(--nd-lv); }
.nd-hol-orth { background: #eaeffd; }
.nd-hol-orth i { color: var(--nd-ru); }
.nd-hol-memo { background: var(--nd-soft); }
.nd-hol-memo i { color: var(--nd-accent-dark); }

.nd-hlist { list-style: none; margin: 0; padding: 0; }
.nd-hlist li { display: grid; grid-template-columns: 110px 1fr auto; gap: 10px; padding: 8px 0 8px 10px; border-bottom: 1px solid var(--nd-line); border-left: 3px solid transparent; align-items: baseline; }
.nd-hlist li:last-child { border-bottom: 0; }
.nd-hlist li.nd-hol-lv { border-left-color: var(--nd-lv); background: none; }
.nd-hlist li.nd-hol-orth { border-left-color: var(--nd-ru); background: none; }
.nd-hlist li.nd-hol-memo { border-left-color: var(--nd-accent); background: none; }
.nd-hlist-date { font-weight: 700; white-space: nowrap; }
.nd-hlist-left { font-size: .8rem; color: var(--nd-muted); white-space: nowrap; }
.nd-off { color: var(--nd-lv); font-weight: 700; }
@media (max-width: 560px) {
    .nd-hlist li { grid-template-columns: 1fr auto; }
    .nd-hlist-title { grid-column: 1 / -1; order: 3; }
}

/* Дни */
.nd-days { display: flex; flex-direction: column; }
.nd-day { display: grid; grid-template-columns: 58px 1fr; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--nd-line); }
.nd-day:last-child { border-bottom: 0; }
.nd-day-date { display: flex; flex-direction: column; align-items: center; justify-content: center; text-decoration: none; color: var(--nd-ink); border: 1px solid var(--nd-line); height: 54px; }
.nd-day-date b { font-size: 1.35rem; line-height: 1; }
.nd-day-date span { font-size: .72rem; text-transform: uppercase; color: var(--nd-muted); }
.nd-day.is-weekend .nd-day-date span { color: var(--nd-lv); font-weight: 700; }
.nd-day.is-today .nd-day-date { background: var(--nd-accent); border-color: var(--nd-accent); }
.nd-day.is-today .nd-day-date span { color: #1d1d1f; }
.nd-day-body .nd-names { margin: 2px 0 4px; }

.nd-monthbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; font-size: 1.1rem; }
.nd-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: .82rem; color: var(--nd-muted); margin-bottom: 10px; }

/* Кнопки */
.nd-btn { display: inline-flex; gap: 8px; align-items: center; justify-content: center; padding: 9px 16px; background: var(--nd-accent); color: #1d1d1f !important; border: 1px solid var(--nd-accent); font-weight: 700; text-decoration: none !important; cursor: pointer; font-size: .95rem; }
.nd-btn:hover { background: #ffd43b; }
.nd-btn-ghost { background: transparent; border-color: var(--nd-line); color: var(--nd-ink) !important; }
.nd-btn-ghost:hover { background: var(--nd-soft); }
.nd-ibtn { display: inline-flex; width: 36px; height: 36px; align-items: center; justify-content: center; border: 1px solid var(--nd-line); color: var(--nd-ink); text-decoration: none; background: var(--nd-bg); }
.nd-ibtn:hover { background: var(--nd-soft); }
.nd-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 4px 0 14px; }
.nd-actions-col { flex-direction: column; align-items: stretch; }
.nd-more { display: inline-flex; gap: 6px; align-items: center; margin-top: 8px; font-weight: 600; font-size: .9rem; }

/* Люди */
.nd-plist { display: flex; flex-direction: column; }
.nd-person { display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--nd-line); align-items: center; }
.nd-person:last-child { border-bottom: 0; }
.nd-person-ava { width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: #f1f1f1; font-weight: 800; font-size: 1.2rem; }
.nd-person.is-soon .nd-person-ava { background: var(--nd-soft); box-shadow: inset 0 0 0 2px var(--nd-accent); }
.nd-person.is-today .nd-person-ava { background: var(--nd-accent); }
.nd-person-name { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 2px; }
.nd-tag { font-size: .72rem; padding: 2px 6px; background: #f1f1f1; color: var(--nd-muted); font-weight: 600; }
.nd-person-row { font-size: .88rem; display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: baseline; }
.nd-person-row i { color: var(--nd-accent-dark); width: 14px; }
.nd-left { color: var(--nd-muted); font-size: .8rem; }
.nd-person.is-today .nd-left, .nd-person.is-soon .nd-left { color: #a06f00; font-weight: 700; }
.nd-person-note { font-size: .82rem; color: var(--nd-muted); margin-top: 2px; }
.nd-person-act { display: flex; gap: 6px; }

/* Форма */
.nd-form { display: flex; flex-direction: column; gap: 12px; }
.nd-field { display: flex; flex-direction: column; gap: 5px; }
.nd-field > span { font-weight: 700; font-size: .9rem; display: flex; gap: 10px; align-items: baseline; }
.nd-field input[type=text], .nd-field input[type=date], .nd-field select, .nd-field textarea {
    border: 1px solid rgba(0, 0, 0, .2); padding: 9px 10px; font-size: 1rem; background: var(--nd-bg); color: inherit; width: 100%; font-family: inherit;
}
.nd-field input:focus, .nd-field select:focus, .nd-field textarea:focus { outline: 2px solid var(--nd-accent); outline-offset: -1px; }
.nd-check { display: flex; gap: 8px; align-items: center; font-size: .9rem; margin-top: -6px; }
.nd-seg { display: flex; flex-wrap: wrap; border: 1px solid rgba(0, 0, 0, .2); }
.nd-seg label { flex: 1 0 auto; margin: 0; }
.nd-seg input { position: absolute; opacity: 0; pointer-events: none; }
.nd-seg span { display: block; text-align: center; padding: 8px 10px; cursor: pointer; font-weight: 600; font-size: .88rem; border-right: 1px solid rgba(0, 0, 0, .1); }
.nd-seg label:last-child span { border-right: 0; }
.nd-seg input:checked + span { background: var(--nd-accent); }
.nd-err { color: #c0392b; font-size: .85rem; font-weight: 600; }
.nd-preview { background: var(--nd-soft); border-left: 3px solid var(--nd-accent); padding: 8px 10px; font-size: .88rem; margin-top: -4px; }
.nd-preview .fa-check-circle { color: #2b8a3e; }
.nd-preview .fa-exclamation-triangle { color: #e67700; }
.nd-del { margin: -4px 0 14px; text-align: right; }
.nd-link-danger { background: none; border: 0; color: #c0392b; cursor: pointer; font-weight: 600; }

/* Панель «Мои люди» */
.nd-toolbar { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 6px; }
.nd-btn-icon { padding: 9px 12px; }
.nd-private { margin-bottom: 12px; }
.nd-person.is-event .nd-person-ava { background: #eef6ff; color: #2f6fb3; font-size: 1.05rem; }
.nd-ibtn-gift { color: var(--nd-accent-dark); }
.nd-alert { background: #fdecea; color: #a5281b; padding: 9px 12px; margin-bottom: 10px; font-weight: 600; font-size: .9rem; }

/* Форма: человек / дата */
.nd-kind { margin-bottom: 2px; }
.nd-kind i { margin-right: 4px; }
.nd-form[data-kind="person"] .nd-only-event,
.nd-form[data-kind="event"] .nd-only-person { display: none !important; }

/* Импорт */
.nd-imp-pane[hidden] { display: none; }
.nd-drop { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 12px; border: 2px dashed rgba(0,0,0,.18); background: var(--nd-soft); cursor: pointer; text-align: center; position: relative; margin: 0; }
.nd-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.nd-drop i { font-size: 1.8rem; color: var(--nd-accent-dark); }
.nd-drop-name { font-weight: 700; color: var(--nd-ink); }
.nd-imp-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 8px; }
.nd-imp-head label { margin: 0; cursor: pointer; }
.nd-imp-list { border: 1px solid var(--nd-line); max-height: 60vh; overflow-y: auto; }
.nd-imp-row { display: grid; grid-template-columns: 22px 26px 1fr; gap: 8px; align-items: center; padding: 8px 10px; border-bottom: 1px solid var(--nd-line); margin: 0; cursor: pointer; }
.nd-imp-row:last-child { border-bottom: 0; }
.nd-imp-row input { width: 18px; height: 18px; margin: 0; }
.nd-imp-ico { color: var(--nd-accent-dark); text-align: center; }
.nd-imp-main { min-width: 0; }
.nd-imp-main b { margin-right: 6px; }
.nd-imp-main small { display: block; color: var(--nd-muted); }
.nd-imp-row.is-dup { opacity: .6; }
.nd-imp-row.is-dup em { color: #a5281b; font-style: normal; font-weight: 600; }
.nd-imp-foot { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.nd-imp-foot .nd-field { max-width: 320px; }

/* Открытка — компактно, удобно с телефона */
.nd-card-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
.nd-card-preview { position: relative; }
.nd-card-preview canvas { display: block; width: auto; height: auto; max-width: 100%; max-height: 58vh; margin: 0 auto; box-shadow: 0 2px 14px rgba(0, 0, 0, .12); background: #fff; }
.nd-card-preview { max-width: 520px; width: 100%; justify-self: center; }
.nd-card-bar { display: flex; gap: 6px; margin-top: 8px; }
.nd-card-bar .nd-card-share { flex: 1; min-height: 46px; font-size: 1rem; }
.nd-card-bar .nd-btn-icon { width: 46px; min-height: 46px; padding: 0; }
.nd-card-more { position: absolute; right: 0; z-index: 20; display: flex; flex-direction: column; min-width: 220px; background: var(--nd-bg); border: 1px solid var(--nd-line); box-shadow: 0 6px 20px rgba(0,0,0,.15); margin-top: 4px; }
.nd-card-more[hidden] { display: none; }
.nd-card-more a, .nd-card-more button { display: flex; gap: 10px; align-items: center; padding: 11px 14px; border: 0; background: none; color: var(--nd-ink) !important; text-decoration: none !important; font: inherit; font-weight: 600; text-align: left; cursor: pointer; border-bottom: 1px solid var(--nd-line); }
.nd-card-more > :last-child { border-bottom: 0; }
.nd-card-more a:hover, .nd-card-more button:hover { background: var(--nd-soft); }
.nd-card-more i { width: 18px; color: var(--nd-accent-dark); }
.nd-card-msg { min-height: 1.2em; margin-top: 4px; }

.nd-card-panel { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.nd-card-preview { min-width: 0; }
.nd-input { width: 100%; border: 1px solid rgba(0, 0, 0, .2); padding: 10px; font-size: 1rem; font-family: inherit; background: var(--nd-bg); color: inherit; }
.nd-input:focus, .nd-textbox textarea:focus { outline: 2px solid var(--nd-accent); outline-offset: -1px; }
.nd-seg-sm span { padding: 7px 6px; font-size: .85rem; }
.nd-textbox { border: 1px solid rgba(0, 0, 0, .2); background: var(--nd-bg); }
.nd-textbox textarea { display: block; width: 100%; border: 0; padding: 10px; font-size: .95rem; font-family: inherit; resize: vertical; background: transparent; color: inherit; }
.nd-textbox-next { display: flex; gap: 6px; align-items: center; width: 100%; border: 0; border-top: 1px solid var(--nd-line); background: var(--nd-soft); padding: 8px 10px; font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer; color: var(--nd-ink); }
.nd-textbox-next i { color: var(--nd-accent-dark); }

.nd-styles { display: flex; gap: 8px; overflow-x: auto; padding: 2px; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.nd-styles::-webkit-scrollbar { display: none; }
.nd-styles button { flex: 0 0 44px; width: 44px; height: 44px; border: 2px solid rgba(0, 0, 0, .15); cursor: pointer; padding: 0; }
.nd-styles button.is-active { border-color: #1d1d1f; box-shadow: 0 0 0 2px var(--nd-accent); }

.nd-to { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: thin; }
.nd-to button { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 6px 10px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); font: inherit; cursor: pointer; text-align: left; }
.nd-to button b { font-size: .88rem; white-space: nowrap; max-width: 160px; overflow: hidden; text-overflow: ellipsis; }
.nd-to button small { font-size: .72rem; color: var(--nd-muted); }
.nd-to button.is-active { border-color: var(--nd-accent); background: var(--nd-soft); box-shadow: inset 0 -3px 0 var(--nd-accent); }

.nd-card-extra summary { cursor: pointer; font-size: .85rem; font-weight: 600; color: var(--nd-muted); padding: 2px 0; }
.nd-card-extra .nd-input { margin-top: 6px; }

@media (max-width: 760px) {
    .nd-card-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
    .nd-card-preview canvas { max-height: 40vh; }
    .nd-card-preview { max-width: none; }
    .nd-cardpage .nd-h1 { display: none; }
    .nd-card-more { left: 0; right: 0; }
}

/* ===== Виджет «Именины сегодня» — светлая карточка ===== */
.nd-w { background: var(--nd-bg) !important; color: var(--nd-ink) !important; border: 1px solid var(--nd-line); border-top: 3px solid var(--nd-accent); font-size: .92rem; line-height: 1.4; }
.nd-w a { text-decoration: none !important; }
.nd-w-head { display: flex; align-items: baseline; gap: 8px; padding: 9px 12px 6px; color: var(--nd-ink) !important; }
.nd-w-date { font-size: 1rem; font-weight: 600; }
.nd-w-date b { font-size: 1.35rem; font-weight: 800; }
.nd-w-wd { color: var(--nd-muted); font-size: .82rem; }
.nd-w-head > i { margin-left: auto; color: var(--nd-muted); align-self: center; }
.nd-w-head:hover .nd-w-date { color: var(--nd-accent-dark); }
.nd-w-sec { padding: 8px 12px; border-top: 1px solid var(--nd-line); }
.nd-w-sec:first-of-type { border-top: 0; }
.nd-w-label { font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 700; color: var(--nd-muted); margin-bottom: 5px; }
.nd-w-names { display: flex; flex-wrap: wrap; gap: 4px; }
.nd-w-name { display: inline-block; padding: 3px 8px; background: var(--nd-soft); border: 1px solid rgba(201, 154, 0, .25); color: var(--nd-ink) !important; font-weight: 600; font-size: .88rem; }
.nd-w-name:hover { background: var(--nd-accent); border-color: var(--nd-accent); }
.nd-w-name-ru { background: #f2f5ff; border-color: rgba(59, 91, 219, .2); }
.nd-w-empty { color: var(--nd-muted); font-size: .85rem; }
.nd-w-tomorrow { margin-top: 6px; font-size: .82rem; color: var(--nd-muted); }
.nd-w-tomorrow span { font-weight: 700; }
.nd-w-person { display: flex; align-items: center; gap: 8px; padding: 4px 0; }
.nd-w-person > i { width: 14px; color: var(--nd-accent-dark); font-size: .85rem; }
.nd-w-pname { flex: 1; min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nd-w-when { font-size: .78rem; color: var(--nd-muted) !important; white-space: nowrap; }
.nd-w-when:hover { color: var(--nd-accent-dark) !important; }
.nd-w-go { flex: 0 0 auto; padding: 3px 8px; background: var(--nd-accent); color: #1d1d1f !important; font-size: .78rem; font-weight: 700; white-space: nowrap; }
.nd-w-person.is-today { background: var(--nd-soft); margin: 0 -12px; padding: 5px 12px; }
.nd-w-hol { display: grid; grid-template-columns: 8px auto 1fr; gap: 8px; align-items: baseline; font-size: .84rem; padding: 2px 0; }
.nd-w-hol > i { width: 8px; height: 8px; background: var(--nd-accent); align-self: center; }
.nd-w-hol-lv > i { background: var(--nd-lv); }
.nd-w-hol-orth > i { background: var(--nd-ru); }
.nd-w-hdate { font-weight: 700; white-space: nowrap; }
.nd-w-htitle { color: var(--nd-muted); }
.nd-w-foot { display: flex; border-top: 1px solid var(--nd-line); }
.nd-w-foot a { flex: 1; text-align: center; padding: 7px 4px; font-size: .8rem; font-weight: 600; color: var(--nd-muted) !important; }
.nd-w-foot a + a { border-left: 1px solid var(--nd-line); }
.nd-w-foot a:hover { color: var(--nd-ink) !important; background: var(--nd-soft); }

/* ===== Тёмная тема сайта — графит, а не чёрный ===== */
html[data-bs-theme="dark"] .nd-wrap, html[data-bs-theme="dark"] .nd-w,
html.dark .nd-wrap, html.dark .nd-w, html.dark-theme .nd-wrap, html.dark-theme .nd-w,
body.dark .nd-wrap, body.dark .nd-w, body.dark-theme .nd-wrap, body.dark-theme .nd-w,
html[data-theme="dark"] .nd-wrap, html[data-theme="dark"] .nd-w {
    --nd-ink: #e9ecef;
    --nd-muted: #a3acb5;
    --nd-line: rgba(255, 255, 255, .12);
    --nd-bg: #262b31;
    --nd-soft: #30363d;
    --nd-accent-dark: #f5c518;
}
html[data-bs-theme="dark"] .nd-w-name-ru, html.dark .nd-w-name-ru, body.dark-theme .nd-w-name-ru, html[data-theme="dark"] .nd-w-name-ru { background: #2c3445; }
html[data-bs-theme="dark"] .nd-input, html[data-bs-theme="dark"] .nd-textbox, html[data-bs-theme="dark"] .nd-field input, html[data-bs-theme="dark"] .nd-field select, html[data-bs-theme="dark"] .nd-field textarea,
html.dark .nd-input, html.dark .nd-textbox, body.dark-theme .nd-input, body.dark-theme .nd-textbox { border-color: rgba(255, 255, 255, .2); }

/* Открытки сайта и своё фото */
.nd-styles .nd-style-img { background-size: cover; background-position: center; }
.nd-styles .nd-style-own { flex: 0 0 auto; width: auto; padding: 0 10px; display: inline-flex; align-items: center; gap: 6px; background: var(--nd-bg); color: var(--nd-ink); border-style: dashed; font-weight: 600; font-size: .8rem; line-height: 1; font-family: inherit; white-space: nowrap; }
.nd-styles .nd-style-own i { color: var(--nd-accent-dark); }

/* Виджет внутри обёртки шаблона: убираем тёмную шапку и двойную рамку */
.icms-widget:has(.nd-w) { background: var(--nd-w-bg, #fff) !important; border: 1px solid rgba(0, 0, 0, .1) !important; border-top: 3px solid #f5c518 !important; box-shadow: none !important; }
.icms-widget:has(.nd-w) > .card-header {
    background: transparent !important; background-image: none !important;
    color: #1d1d1f !important; border: 0 !important; box-shadow: none !important;
    padding: 10px 12px 0 !important; font-size: .78rem !important; font-weight: 700 !important;
    text-transform: uppercase; letter-spacing: .06em; opacity: .7;
}
.icms-widget:has(.nd-w) > .card-header::before, .icms-widget:has(.nd-w) > .card-header::after { display: none !important; }
.icms-widget:has(.nd-w) > .card-body { padding: 0 !important; background: transparent !important; }
.icms-widget:has(.nd-w) .nd-w { border: 0 !important; }
.icms-widget:has(.nd-w) > .card-header + .card-body .nd-w-head { padding-top: 2px; }
html[data-bs-theme="dark"] .icms-widget:has(.nd-w), html.dark .icms-widget:has(.nd-w), body.dark-theme .icms-widget:has(.nd-w), html[data-theme="dark"] .icms-widget:has(.nd-w) { --nd-w-bg: #262b31; border-color: rgba(255,255,255,.12) !important; }
html[data-bs-theme="dark"] .icms-widget:has(.nd-w) > .card-header, html.dark .icms-widget:has(.nd-w) > .card-header, body.dark-theme .icms-widget:has(.nd-w) > .card-header, html[data-theme="dark"] .icms-widget:has(.nd-w) > .card-header { color: #e9ecef !important; }
@media (min-width: 761px) { .nd-styles { flex-wrap: wrap; overflow: visible; } }

/* ===== Календарь-сетка ===== */
.nd-cal { padding: 10px; }
.nd-cal-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; font-size: 1.05rem; }
.nd-cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
.nd-cal-wd { text-align: center; font-size: .7rem; font-weight: 700; text-transform: uppercase; color: var(--nd-muted); padding: 2px 0 4px; }
.nd-cal-wd.is-we { color: var(--nd-lv); }
.nd-cal-day { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; min-height: 62px; padding: 4px 4px 3px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); font: inherit; text-align: left; cursor: pointer; overflow: hidden; }
.nd-cal-day b { display: flex; align-items: center; gap: 3px; font-size: .95rem; line-height: 1.1; }
.nd-cal-day span { display: block; width: 100%; font-size: .68rem; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--nd-ink); }
.nd-cal-day small { font-size: .62rem; color: var(--nd-muted); }
.nd-cal-day.is-we b { color: var(--nd-lv); }
.nd-cal-day.is-today { background: var(--nd-soft); box-shadow: inset 0 0 0 2px var(--nd-accent); }
.nd-cal-day.is-sel { background: var(--nd-accent); border-color: var(--nd-accent); }
.nd-cal-day.is-sel b, .nd-cal-day.is-sel span, .nd-cal-day.is-sel small { color: #1d1d1f; }
.nd-cal-dot { width: 6px; height: 6px; background: var(--nd-lv); display: inline-block; }
.nd-cal-info[hidden] { display: none; }
@media (min-width: 761px) { .nd-cal-day { min-height: 82px; } .nd-cal-day span { font-size: .78rem; } }

/* ===== Конструктор открыток ===== */
.ndc-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
.ndc-left, .ndc-right { min-width: 0; }
.ndc-stage { display: flex; justify-content: center; background: repeating-conic-gradient(#f1f1f1 0% 25%, #fafafa 0% 50%) 0 0 / 20px 20px; padding: 10px; border: 1px solid var(--nd-line); }
.ndc-stage canvas { display: block; width: auto; height: auto; max-width: 100%; max-height: 62vh; box-shadow: 0 2px 14px rgba(0, 0, 0, .15); touch-action: none; cursor: grab; }
.ndc-hint { font-size: .78rem; color: var(--nd-muted); text-align: center; margin: 4px 0; }
.ndc-send { display: flex; gap: 6px; }
.ndc-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 46px; min-height: 46px; padding: 0 12px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); font-weight: 700; font-size: 1rem; line-height: 1; font-family: inherit; cursor: pointer; }
.ndc-btn-main { flex: 1; background: var(--nd-accent); border-color: var(--nd-accent); color: #1d1d1f; }
.ndc-more-wrap { position: relative; }
.ndc-menu { position: absolute; right: 0; bottom: 52px; z-index: 30; display: flex; flex-direction: column; min-width: 210px; background: var(--nd-bg); border: 1px solid var(--nd-line); box-shadow: 0 6px 20px rgba(0,0,0,.18); }
.ndc-menu[hidden] { display: none; }
.ndc-menu a, .ndc-menu button { display: flex; gap: 10px; align-items: center; padding: 11px 14px; border: 0; border-bottom: 1px solid var(--nd-line); background: none; color: var(--nd-ink) !important; text-decoration: none !important; font-weight: 600; font-size: .95rem; font-family: inherit; text-align: left; cursor: pointer; }
.ndc-menu > :last-child { border-bottom: 0; }
.ndc-menu i { width: 18px; color: var(--nd-accent-dark); }
.ndc-msg { min-height: 1.1em; font-size: .82rem; color: var(--nd-muted); text-align: center; }

.ndc-tabs { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--nd-line); background: var(--nd-bg); }
.ndc-tab { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 4px; border: 0; border-bottom: 3px solid transparent; background: none; color: var(--nd-muted); font-weight: 600; font-size: .75rem; line-height: 1.1; font-family: inherit; cursor: pointer; }
.ndc-tab i { font-size: 1.05rem; }
.ndc-tab + .ndc-tab { border-left: 1px solid var(--nd-line); }
.ndc-tab.is-on { color: var(--nd-ink); border-bottom-color: var(--nd-accent); background: var(--nd-soft); }
.ndc-tab.is-on i { color: var(--nd-accent-dark); }
.ndc-panel { display: flex; flex-direction: column; gap: 8px; padding: 10px; border: 1px solid var(--nd-line); border-top: 0; background: var(--nd-bg); }
.ndc-panel[hidden] { display: none; }
.ndc-input { width: 100%; border: 1px solid rgba(0,0,0,.2); padding: 9px 10px; font-size: 1rem; font-family: inherit; background: var(--nd-bg); color: inherit; }
.ndc-input:focus { outline: 2px solid var(--nd-accent); outline-offset: -1px; }
.ndc-seg { display: flex; border: 1px solid rgba(0,0,0,.2); }
.ndc-seg label { flex: 1; margin: 0; }
.ndc-seg input { position: absolute; opacity: 0; pointer-events: none; }
.ndc-seg span { display: block; text-align: center; padding: 8px 4px; font-weight: 600; font-size: .85rem; cursor: pointer; }
.ndc-seg label + label span { border-left: 1px solid rgba(0,0,0,.1); }
.ndc-seg input:checked + span { background: var(--nd-accent); }
.ndc-to { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.ndc-to::-webkit-scrollbar { display: none; }
.ndc-to button { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-start; padding: 6px 10px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); font: inherit; cursor: pointer; text-align: left; }
.ndc-to button b { font-size: .86rem; white-space: nowrap; max-width: 150px; overflow: hidden; text-overflow: ellipsis; }
.ndc-to button small { font-size: .7rem; color: var(--nd-muted); }
.ndc-to button.is-on { border-color: var(--nd-accent); box-shadow: inset 0 -3px 0 var(--nd-accent); background: var(--nd-soft); }
.ndc-row { display: flex; gap: 8px; overflow-x: auto; padding: 2px; scrollbar-width: none; }
.ndc-row::-webkit-scrollbar { display: none; }
.ndc-bg { flex: 0 0 52px; width: 52px; height: 64px; border: 2px solid rgba(0,0,0,.15); padding: 0; cursor: pointer; background-size: cover; background-position: center; }
.ndc-bg.is-on { border-color: #1d1d1f; box-shadow: 0 0 0 2px var(--nd-accent); }
.ndc-bg-own { flex: 0 0 auto; width: auto; padding: 0 10px; display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border-style: dashed; background: var(--nd-bg); color: var(--nd-ink); font-weight: 600; font-size: .72rem; line-height: 1; font-family: inherit; }
.ndc-bg-own i { font-size: 1.1rem; color: var(--nd-accent-dark); }
.ndc-check { display: flex; gap: 8px; align-items: center; font-size: .85rem; margin: 0; }
.ndc-wish { border: 1px solid rgba(0,0,0,.2); }
.ndc-wish textarea { border: 0; resize: vertical; }
.ndc-wish-next { display: flex; gap: 6px; align-items: center; width: 100%; padding: 8px 10px; border: 0; border-top: 1px solid var(--nd-line); background: var(--nd-soft); font-weight: 600; font-size: .85rem; font-family: inherit; color: var(--nd-ink); cursor: pointer; }
.ndc-wish-next i { color: var(--nd-accent-dark); }
.ndc-stickers { flex-wrap: wrap; }
.ndc-st { width: 48px; height: 48px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-accent-dark); font-size: 1.3rem; cursor: pointer; }
.ndc-st:active { background: var(--nd-soft); }
.ndc-props { margin-top: 8px; padding: 10px; border: 1px solid var(--nd-line); border-left: 3px solid var(--nd-accent); background: var(--nd-bg); display: flex; flex-direction: column; gap: 8px; }
.ndc-props[hidden], .ndc-fonts[hidden], .ndc-del[hidden] { display: none; }
.ndc-props-head { display: flex; align-items: center; justify-content: space-between; font-size: .85rem; }
.ndc-del { border: 0; background: none; color: #c0392b; font-weight: 600; font-size: .85rem; font-family: inherit; cursor: pointer; }
.ndc-fonts { display: flex; gap: 6px; }
.ndc-fonts button { flex: 1; height: 40px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); cursor: pointer; }
.ndc-fonts button.is-on { border-color: var(--nd-accent); background: var(--nd-soft); box-shadow: inset 0 -3px 0 var(--nd-accent); }
.ndc-size { display: flex; align-items: center; gap: 10px; margin: 0; color: var(--nd-muted); }
.ndc-size input { flex: 1; accent-color: #c99a00; }
.ndc-colors { display: flex; gap: 6px; flex-wrap: wrap; }
.ndc-colors button { width: 30px; height: 30px; border: 2px solid rgba(0,0,0,.18); cursor: pointer; padding: 0; }

@media (max-width: 760px) {
    .ndc .ndc-h1 { display: none; }
    .ndc-grid { grid-template-columns: minmax(0, 1fr); gap: 8px; }
    .ndc-stage { padding: 6px; }
    .ndc-stage canvas { max-height: 46vh; }
    .ndc-hint { display: none; }
}

/* Перебиваем тёмные/полосатые стили темы для блока даты */
.nd-wrap .nd-today, .nd-wrap .nd-box, .nd-wrap .nd-cal { background-image: none !important; border-image: none !important; }
.nd-wrap .nd-today-date { background: var(--nd-accent) !important; background-image: none !important; color: #1d1d1f !important; border-image: none !important; }
.nd-wrap .nd-today-date *, .nd-wrap .nd-today-day { color: #1d1d1f !important; }
.nd-wrap .nd-today-date::before, .nd-wrap .nd-today-date::after, .nd-wrap .nd-today::before, .nd-wrap .nd-today::after { display: none !important; }

/* Тёмная тема: плашки праздников, флажки, метки — тёмные фоны со светлым текстом */
html[data-bs-theme="dark"] .nd-hol, html.dark .nd-hol, html.dark-theme .nd-hol, body.dark .nd-hol, body.dark-theme .nd-hol, html[data-theme="dark"] .nd-hol { background: #30363d !important; color: #e9ecef !important; }
html[data-bs-theme="dark"] .nd-hol-lv, html.dark .nd-hol-lv, html.dark-theme .nd-hol-lv, body.dark .nd-hol-lv, body.dark-theme .nd-hol-lv, html[data-theme="dark"] .nd-hol-lv { background: rgba(158, 48, 57, .28) !important; }
html[data-bs-theme="dark"] .nd-hol-orth, html.dark .nd-hol-orth, html.dark-theme .nd-hol-orth, body.dark .nd-hol-orth, body.dark-theme .nd-hol-orth, html[data-theme="dark"] .nd-hol-orth { background: rgba(59, 91, 219, .28) !important; }
html[data-bs-theme="dark"] .nd-hol-orth i, html.dark .nd-hol-orth i, html.dark-theme .nd-hol-orth i, body.dark .nd-hol-orth i, body.dark-theme .nd-hol-orth i, html[data-theme="dark"] .nd-hol-orth i { color: #9db0ff !important; }
html[data-bs-theme="dark"] .nd-hol-memo, html.dark .nd-hol-memo, html.dark-theme .nd-hol-memo, body.dark .nd-hol-memo, body.dark-theme .nd-hol-memo, html[data-theme="dark"] .nd-hol-memo { background: rgba(245, 197, 24, .16) !important; }
html[data-bs-theme="dark"] .nd-hol small, html.dark .nd-hol small, html.dark-theme .nd-hol small, body.dark .nd-hol small, body.dark-theme .nd-hol small, html[data-theme="dark"] .nd-hol small, html[data-bs-theme="dark"] .nd-off, html.dark .nd-off, html.dark-theme .nd-off, body.dark .nd-off, body.dark-theme .nd-off, html[data-theme="dark"] .nd-off { color: #ff8f99 !important; }
html[data-bs-theme="dark"] .nd-flag:not(.nd-flag-lv):not(.nd-flag-ru), html.dark .nd-flag:not(.nd-flag-lv):not(.nd-flag-ru), html.dark-theme .nd-flag:not(.nd-flag-lv):not(.nd-flag-ru), body.dark .nd-flag:not(.nd-flag-lv):not(.nd-flag-ru), body.dark-theme .nd-flag:not(.nd-flag-lv):not(.nd-flag-ru), html[data-theme="dark"] .nd-flag:not(.nd-flag-lv):not(.nd-flag-ru), html[data-bs-theme="dark"] .nd-tag, html.dark .nd-tag, html.dark-theme .nd-tag, body.dark .nd-tag, body.dark-theme .nd-tag, html[data-theme="dark"] .nd-tag, html[data-bs-theme="dark"] .nd-person-ava, html.dark .nd-person-ava, html.dark-theme .nd-person-ava, body.dark .nd-person-ava, body.dark-theme .nd-person-ava, html[data-theme="dark"] .nd-person-ava { background: #3a4048 !important; color: #d6dbe0 !important; }
html[data-bs-theme="dark"] .nd-cal-day.is-sel, html.dark .nd-cal-day.is-sel, html.dark-theme .nd-cal-day.is-sel, body.dark .nd-cal-day.is-sel, body.dark-theme .nd-cal-day.is-sel, html[data-theme="dark"] .nd-cal-day.is-sel { color: #1d1d1f; }

/* ===== 3.3 События ===== */
.nd-row2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.nd-row2 > .nd-field { min-width: 0; }
.nd-field input[type=time], .nd-field input[type=url], .nd-row2 input { width: 100%; border: 1px solid rgba(0, 0, 0, .2); padding: 9px 10px; font-size: 1rem; font-family: inherit; background: var(--nd-bg); color: inherit; }
.nd-field input:disabled { opacity: .45; }
.nd-form-foot { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.nd-form-foot .nd-btn-danger { margin-left: auto; }
.nd-btn-danger { color: #c0392b !important; }
.nd-note { background: var(--nd-soft); border-left: 3px solid var(--nd-accent); padding: 8px 12px; font-size: .88rem; margin: 0 0 10px; }
.nd-count { display: inline-block; min-width: 20px; padding: 1px 6px; background: var(--nd-ink); color: #fff; font-size: .75rem; font-weight: 700; text-align: center; line-height: 1.4; }
.nd-btn .nd-count { background: #c0392b; }
.nd-empty { text-align: center; padding: 26px 14px; color: var(--nd-muted); }
.nd-empty > i { font-size: 2rem; color: var(--nd-accent-dark); margin-bottom: 6px; }
.nd-empty p { margin: 0 0 10px; }

.nd-ev-top { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.nd-ev-top .nd-btn { flex: 1 1 auto; }
.nd-ev-when { display: flex; gap: 4px; overflow-x: auto; margin-bottom: 8px; scrollbar-width: none; }
.nd-ev-when::-webkit-scrollbar { display: none; }
.nd-ev-when a { flex: 0 0 auto; padding: 6px 12px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); font-weight: 600; font-size: .88rem; text-decoration: none; white-space: nowrap; }
.nd-ev-when a.is-active { background: var(--nd-accent); border-color: var(--nd-accent); color: #1d1d1f; }
.nd-ev-filter { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 6px; margin-bottom: 12px; }
.nd-ev-filter select, .nd-ev-q input { width: 100%; min-width: 0; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink); padding: 8px; font: inherit; font-size: .9rem; height: 38px; }
.nd-ev-q { display: flex; min-width: 0; }
.nd-ev-q button { border: 0; background: var(--nd-accent); color: #1d1d1f; width: 40px; flex: 0 0 40px; cursor: pointer; }
@media (max-width: 560px) { .nd-ev-filter { grid-template-columns: 1fr 1fr; } .nd-ev-q { grid-column: 1 / -1; } }

.nd-ev-day { display: flex; align-items: center; gap: 8px; font-size: .82rem; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; color: var(--nd-muted); margin: 14px 0 6px; }
.nd-ev-day::after { content: ""; flex: 1; height: 1px; background: var(--nd-line); }
.nd-ev-day span { order: 2; font-weight: 600; }
.nd-ev-day.is-today { color: var(--nd-accent-dark); }
.nd-ev-list { display: flex; flex-direction: column; gap: 6px; }
.nd-ev { display: flex; gap: 10px; padding: 6px; border: 1px solid var(--nd-line); background: var(--nd-bg); color: var(--nd-ink) !important; text-decoration: none !important; align-items: stretch; }
.nd-ev:hover { background: var(--nd-soft); }
.nd-ev-pic { position: relative; flex: 0 0 78px; width: 78px; min-height: 78px; background: var(--nd-soft) center / cover no-repeat; display: flex; align-items: center; justify-content: center; }
.nd-ev-pic > i { font-size: 1.5rem; color: var(--nd-accent-dark); margin-bottom: 18px; }
.nd-ev-date { position: absolute; left: 0; bottom: 0; background: var(--nd-accent); color: #1d1d1f; font-size: .66rem; font-weight: 700; text-transform: uppercase; padding: 1px 5px; line-height: 1.2; text-align: center; }
.nd-ev-date b { display: block; font-size: 1rem; line-height: 1; }
.nd-ev-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.nd-ev-title { font-weight: 700; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.nd-ev-meta { font-size: .8rem; color: var(--nd-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nd-ev-meta i { width: 13px; text-align: center; color: var(--nd-accent-dark); }
.nd-ev-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 2px; }
.nd-ev-tags .nd-tag { text-decoration: none; }
.nd-st-pending { background: #fff3bf !important; color: #8a6d00 !important; }
.nd-st-rejected { background: #ffe3e3 !important; color: #c0392b !important; }
.nd-ev-mine summary { cursor: pointer; font-weight: 700; display: flex; gap: 8px; align-items: center; list-style: none; }
.nd-ev-mine summary::-webkit-details-marker { display: none; }
.nd-ev-mine[open] summary { margin-bottom: 10px; }
.nd-ev-mine summary i { color: var(--nd-accent-dark); }

/* страница события */
.nd-evp-status { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 12px; margin-bottom: 10px; font-weight: 700; }
.nd-evp-status > span { flex: 1 1 auto; }
.nd-evp-card { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 16px; border: 1px solid var(--nd-line); background: var(--nd-bg); padding: 12px; margin-bottom: 14px; }
.nd-evp-card:not(:has(.nd-evp-poster)) { grid-template-columns: minmax(0, 1fr); }
.nd-evp-poster { display: block; background: var(--nd-soft); }
.nd-evp-poster img { display: block; width: 100%; height: auto; max-height: 420px; object-fit: contain; margin: 0 auto; }
.nd-evp-title { font-size: 1.4rem; font-weight: 800; line-height: 1.2; margin: 6px 0 10px; }
.nd-evp-facts { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.nd-evp-facts li { display: flex; gap: 10px; align-items: flex-start; }
.nd-evp-facts li > i { width: 18px; text-align: center; color: var(--nd-accent-dark); margin-top: 3px; }
.nd-evp-facts li > span { display: flex; flex-direction: column; gap: 1px; }
.nd-evp-facts small { color: var(--nd-muted); font-size: .85rem; }
.nd-evp-facts a { font-size: .85rem; font-weight: 600; }
.nd-evp-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.nd-evp-desc { line-height: 1.55; overflow-wrap: anywhere; }
@media (max-width: 640px) {
    .nd-evp-card { grid-template-columns: minmax(0, 1fr); padding: 0; gap: 0; }
    .nd-evp-poster img { max-height: 60vh; }
    .nd-evp-main { padding: 10px 12px 12px; }
    .nd-evp-title { font-size: 1.2rem; }
    .nd-evp-actions .nd-btn:not(.nd-btn-icon) { flex: 1 1 auto; }
}

/* форма */
.nd-evf-more summary { cursor: pointer; font-weight: 700; font-size: .9rem; color: var(--nd-accent-dark); }
.nd-evf-more[open] summary { margin-bottom: 6px; }
.nd-evf-poster { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 8px; }
.nd-evf-drop { position: relative; height: 120px; border: 1px dashed rgba(0, 0, 0, .3); background: var(--nd-soft) center / cover no-repeat; display: flex; align-items: center; justify-content: center; cursor: pointer; text-align: center; font-size: .8rem; font-weight: 600; padding: 6px; }
.nd-evf-drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.nd-evf-drop[style*="background-image"] span { background: rgba(255, 255, 255, .85); padding: 2px 6px; }
.nd-evf-poster-side { display: flex; flex-direction: column; gap: 8px; justify-content: center; }
.nd-evf-poster-side input { width: 100%; border: 1px solid rgba(0, 0, 0, .2); padding: 9px 10px; font: inherit; background: var(--nd-bg); color: inherit; }
.nd-evf .nd-check { margin-top: 2px; }

/* модерация */
.nd-mod-list { display: flex; flex-direction: column; gap: 10px; }
.nd-mod { border: 1px solid var(--nd-line); background: var(--nd-bg); padding: 6px; transition: opacity .3s; }
.nd-mod .nd-ev { border: 0; padding: 0; }
.nd-mod-src { padding: 6px 2px 0; }
.nd-mod-btns { display: flex; gap: 6px; padding-top: 6px; }
.nd-mod-btns .nd-btn:not(.nd-btn-icon) { flex: 1; }
.nd-mod.is-busy { opacity: .5; pointer-events: none; }
.nd-mod.is-done { opacity: 0; }

/* календарь: отметка событий */
.nd-cal-ev { display: inline-block; width: 6px; height: 6px; background: var(--nd-ru); }
.nd-cal-evs { margin-top: 10px; border-top: 1px solid var(--nd-line); padding-top: 8px; display: flex; flex-direction: column; gap: 4px; }
.nd-cal-evs-h { font-size: .85rem; }
.nd-cal-evs-h i { color: var(--nd-accent-dark); }
.nd-cal-evs a { color: var(--nd-ink); text-decoration: none; font-size: .9rem; }
.nd-cal-evs a span { display: inline-block; min-width: 42px; font-weight: 700; color: var(--nd-accent-dark); }
.nd-cal-evs a small { color: var(--nd-muted); }

/* навигация с пятью вкладками на телефоне */
@media (max-width: 560px) {
    .nd-nav a { flex-direction: column; gap: 2px; padding: 7px 6px; font-size: .7rem; flex: 1 0 64px; }
    .nd-nav a i { font-size: 1.05rem; }
}

/* тёмная тема для событий */
html[data-bs-theme="dark"] .nd-wrap .nd-st-pending, html.dark .nd-wrap .nd-st-pending, body.dark-theme .nd-wrap .nd-st-pending, html[data-theme="dark"] .nd-wrap .nd-st-pending { background: rgba(245, 197, 24, .18) !important; color: #ffd43b !important; }
html[data-bs-theme="dark"] .nd-wrap .nd-st-rejected, html.dark .nd-wrap .nd-st-rejected, body.dark-theme .nd-wrap .nd-st-rejected, html[data-theme="dark"] .nd-wrap .nd-st-rejected { background: rgba(192, 57, 43, .25) !important; color: #ff8f99 !important; }
html[data-bs-theme="dark"] .nd-count, html.dark .nd-count, body.dark-theme .nd-count, html[data-theme="dark"] .nd-count { background: #e9ecef; color: #1d1d1f; }
html[data-bs-theme="dark"] .nd-cal-ev, html.dark .nd-cal-ev, body.dark-theme .nd-cal-ev, html[data-theme="dark"] .nd-cal-ev { background: #74c0fc; }
html[data-bs-theme="dark"] .nd-evf-drop, html.dark .nd-evf-drop, body.dark-theme .nd-evf-drop, html[data-theme="dark"] .nd-evf-drop { border-color: rgba(255, 255, 255, .3); }
html[data-bs-theme="dark"] .nd-evf-drop[style*="background-image"] span, html.dark .nd-evf-drop[style*="background-image"] span, body.dark-theme .nd-evf-drop[style*="background-image"] span, html[data-theme="dark"] .nd-evf-drop[style*="background-image"] span { background: rgba(0, 0, 0, .7); }
