/*
 * Social features: dashboard welcome + mood check-in + background scenes, the top bar mood chip,
 * unread notices, kudos, gift box, the person combobox, «پیشنهادها و انتقادها», «گزارش تخلف»,
 * HR gifts and the mood report. Colors only from tokens.css.
 * Every animation is gentle and stops under prefers-reduced-motion (end of this file).
 */

/* ===== Dashboard welcome ============================================== */

.dash-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 340px);
  gap: var(--space-24);
  align-items: center;
  padding: var(--space-24);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-xl);
  background: var(--color-surface-base);
  overflow: visible; /* the «تغییر پس‌زمینه» menu may reach past the card */
}
.dash-hero__text { display: flex; flex-direction: column; gap: var(--space-8); min-width: 0; }
.dash-hero__date { color: var(--color-text-tertiary); font-size: 13px; line-height: 20px; }
.dash-hero__title { font-size: 26px; line-height: 36px; font-weight: 700; }
.dash-hero__line { color: var(--color-text-secondary); font-size: 14px; line-height: 24px; }
.dash-hero__art { position: relative; align-self: stretch; display: flex; align-items: center; justify-content: center; }

.hero-scene { display: block; width: 100%; height: auto; max-height: 240px; overflow: visible; }
.hs-sky { fill: var(--color-surface-info-subtle); }
.hs-sun__glow { fill: var(--color-surface-warning-subtle); }
.hs-sun__disc { fill: var(--color-action-primary-default); }
.hs-moon-cut { fill: var(--color-surface-info-subtle); display: none; }
.hs-cloud { fill: var(--color-surface-base); }
.hs-hill-far { fill: var(--color-surface-success-subtle); }
.hs-hill-near { fill: var(--color-border-success); opacity: .35; }
.hs-flower { fill: var(--color-action-primary-default); }
.hs-flower--2 { fill: var(--color-border-danger); opacity: .7; }
.hs-stem { fill: none; stroke: var(--color-text-success); stroke-width: 1.5; stroke-linecap: round; opacity: .6; }
.hs-stars { display: none; }
.hs-star { fill: var(--color-surface-base); }

/* Noon: the sun is higher. Evening: warm sky, low sun. Night: moon and stars. */
.dash-hero--noon .hs-sun { transform: translateY(-14px); }
.dash-hero--evening .hs-sky { fill: var(--color-surface-warning-subtle); }
.dash-hero--evening .hs-sun { transform: translateY(26px); }
.dash-hero--evening .hs-sun__disc { fill: var(--color-border-warning); }
.dash-hero--evening .hs-sun__glow { fill: var(--color-surface-danger-subtle); }
.dash-hero--night .hs-sky { fill: var(--color-surface-inverse); }
.dash-hero--night .hs-sun__glow { fill: var(--color-surface-inverse); }
.dash-hero--night .hs-sun__disc { fill: var(--color-surface-warning-subtle); }
.dash-hero--night .hs-moon-cut { display: inline; fill: var(--color-surface-inverse); }
.dash-hero--night .hs-stars { display: inline; }
.dash-hero--night .hs-cloud { opacity: .25; }
.dash-hero--night .hs-hill-far { fill: var(--color-text-secondary); opacity: .5; }
.dash-hero--night .hs-hill-near { fill: var(--color-text-tertiary); opacity: .6; }

.hs-cloud { animation: hs-drift 4s ease-in-out infinite alternate; }
.hs-cloud--2 { animation-duration: 3.4s; animation-direction: alternate-reverse; }
.hs-sun__glow { transform-box: fill-box; transform-origin: center; animation: hs-glow 3s ease-in-out infinite; }
.hs-star { animation: hs-twinkle 2.6s ease-in-out infinite; }
.hs-star--2 { animation-delay: .9s; }
.hs-star--3 { animation-delay: 1.7s; }
@keyframes hs-drift { from { transform: translateX(0); } to { transform: translateX(10px); } }
@keyframes hs-glow { 0%, 100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.08); opacity: 1; } }
@keyframes hs-twinkle { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }

/* ===== Welcome background scenes (data-scene on .dash-hero) ============== */

.hs-scene { display: none; }
.dash-hero:not([data-scene]) .hs-scene--meadow,
.dash-hero[data-scene="meadow"] .hs-scene--meadow,
.dash-hero[data-scene="beach"] .hs-scene--beach,
.dash-hero[data-scene="mountain"] .hs-scene--mountain,
.dash-hero[data-scene="city"] .hs-scene--city,
.dash-hero[data-scene="forest"] .hs-scene--forest,
.dash-hero[data-scene="night"] .hs-scene--night { display: inline; }

.hs-drift { animation: hs-drift 4s ease-in-out infinite alternate; }
.hs-drift--rev { animation-duration: 3.4s; animation-direction: alternate-reverse; }
.hs-twinkle { animation: hs-twinkle 2.6s ease-in-out infinite; }
.hs-twinkle--2 { animation-delay: .9s; }
.hs-twinkle--3 { animation-delay: 1.7s; }
.hs-twinkle--slow { animation-duration: 4.5s; }
.hs-pulse { transform-box: fill-box; transform-origin: center; animation: hs-glow 3s ease-in-out infinite; }

/* ساحل */
.hb-sky { fill: var(--color-surface-info-subtle); }
.hb-glow { fill: var(--color-surface-warning-subtle); }
.hb-sun { fill: var(--color-action-primary-default); }
.hb-bird { fill: none; stroke: var(--color-text-tertiary); stroke-width: 1.8; stroke-linecap: round; }
.hb-sea { fill: var(--color-border-info); opacity: .55; }
.hb-wave { fill: none; stroke: var(--color-surface-base); stroke-width: 2; stroke-linecap: round; opacity: .8; }
.hb-sail { fill: var(--color-surface-base); }
.hb-boat { fill: var(--color-border-danger); opacity: .75; }
.hb-sand { fill: var(--color-surface-warning-subtle); }
.hb-trunk { fill: none; stroke: var(--color-border-warning); stroke-width: 6; stroke-linecap: round; }
.hb-leaf { fill: var(--color-border-success); }
.hb-shell { fill: var(--color-surface-danger-subtle); }
.hb-shell--2 { fill: var(--color-border-warning); opacity: .7; }

/* کوهستان */
.hm-sky { fill: var(--color-surface-info-subtle); }
.hm-sun { fill: var(--color-action-primary-default); }
.hm-cloud { fill: var(--color-surface-base); }
.hm-far { fill: var(--color-border-default); }
.hm-snow { fill: var(--color-surface-base); }
.hm-near { fill: var(--color-surface-success-subtle); }
.hm-pine { fill: var(--color-text-success); opacity: .55; }

/* شهر */
.hc-sky { fill: var(--color-surface-warning-subtle); }
.hc-sun { fill: var(--color-border-warning); }
.hc-cloud { fill: var(--color-surface-base); }
.hc-far { fill: var(--color-border-default); opacity: .7; }
.hc-near { fill: var(--color-text-tertiary); opacity: .55; }
.hc-win { fill: var(--color-action-primary-default); }
.hc-ground { fill: var(--color-border-subtle); }

/* جنگل */
.hf-sky { fill: var(--color-surface-info-subtle); }
.hf-glow { fill: var(--color-surface-warning-subtle); }
.hf-sun { fill: var(--color-action-primary-default); }
.hf-bird { fill: none; stroke: var(--color-text-tertiary); stroke-width: 1.8; stroke-linecap: round; }
.hf-far { fill: var(--color-surface-success-subtle); }
.hf-pine { fill: var(--color-text-success); opacity: .7; }
.hf-pine--far { fill: var(--color-border-success); opacity: .55; }
.hf-trunk { fill: none; stroke: var(--color-border-warning); stroke-width: 4; stroke-linecap: round; }
.hf-ground { fill: var(--color-border-success); opacity: .35; }
.hf-berry { fill: var(--color-border-danger); }

/* شب پرستاره */
.hn-sky { fill: var(--color-surface-inverse); }
.hn-star { fill: var(--color-surface-base); }
.hn-shoot { fill: none; stroke: var(--color-surface-base); stroke-width: 1.5; stroke-linecap: round; stroke-dasharray: 14 70; animation: hn-shoot 6s linear infinite; }
.hn-moon { fill: var(--color-surface-warning-subtle); }
.hn-moon-cut { fill: var(--color-surface-inverse); }
.hn-hill-far { fill: var(--color-text-secondary); opacity: .5; }
.hn-hill-near { fill: var(--color-text-tertiary); opacity: .6; }
.hn-house { fill: var(--color-text-secondary); }
.hn-window { fill: var(--color-action-primary-default); }
@keyframes hn-shoot { 0% { stroke-dashoffset: 84; opacity: 0; } 8% { opacity: 1; } 22% { stroke-dashoffset: -14; opacity: 0; } 100% { stroke-dashoffset: -14; opacity: 0; } }

/* «تغییر پس‌زمینه» */
.hero-bg { position: absolute; z-index: 2; inset-block-start: var(--space-8); inset-inline-end: var(--space-8); }
.hero-bg__btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-4);
  min-height: 36px;
  padding: 0 var(--space-12);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-full);
  background: var(--color-surface-base);
  color: var(--color-text-secondary);
  font: inherit;
  font-size: 12px;
  line-height: 18px;
  cursor: pointer;
}
.hero-bg__btn:hover { color: var(--color-text-primary); border-color: var(--color-border-default); }
.hero-bg__btn:focus-visible { outline: 2px solid var(--color-focus-ring); outline-offset: 2px; }
.hero-bg__menu {
  position: absolute;
  inset-block-start: calc(100% + var(--space-6));
  inset-inline-end: 0;
  width: 264px;
  padding: var(--space-12);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-lg);
  background: var(--color-surface-overlay);
  box-shadow: 0 16px 40px -16px var(--color-border-strong);
}
.hero-bg__title { margin-bottom: var(--space-8); font-size: 13px; line-height: 20px; font-weight: 600; }
.hero-bg__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-6); }
.hero-bg__opt {
  display: flex;
  align-items: center;
  gap: var(--space-8);
  min-height: var(--size-touch-min);
  padding: var(--space-4) var(--space-6);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-md);
  background: var(--color-surface-base);
  color: var(--color-text-secondary);
  font: inherit;
  font-size: 12px;
  line-height: 18px;
  text-align: start;
  cursor: pointer;
}
.hero-bg__opt:hover { background: var(--color-surface-page); }
.hero-bg__opt:focus-visible { outline: 2px solid var(--color-focus-ring); outline-offset: 2px; }
.hero-bg__opt[aria-pressed="true"] { border-color: var(--color-text-primary); color: var(--color-text-primary); font-weight: 600; }
.hero-bg__swatch { flex: none; width: 28px; height: 28px; border-radius: var(--radius-sm); border: var(--border-thin) solid var(--color-border-subtle); }
.hero-bg__opt--meadow .hero-bg__swatch { background: linear-gradient(to bottom, var(--color-surface-info-subtle) 55%, var(--color-border-success) 55%); }
.hero-bg__opt--beach .hero-bg__swatch { background: linear-gradient(to bottom, var(--color-surface-info-subtle) 45%, var(--color-border-info) 45% 70%, var(--color-surface-warning-subtle) 70%); }
.hero-bg__opt--mountain .hero-bg__swatch { background: linear-gradient(to bottom, var(--color-surface-info-subtle) 35%, var(--color-border-default) 35% 75%, var(--color-surface-success-subtle) 75%); }
.hero-bg__opt--city .hero-bg__swatch { background: linear-gradient(to bottom, var(--color-surface-warning-subtle) 40%, var(--color-text-tertiary) 40%); }
.hero-bg__opt--forest .hero-bg__swatch { background: linear-gradient(to bottom, var(--color-surface-info-subtle) 35%, var(--color-text-success) 35%); }
.hero-bg__opt--night .hero-bg__swatch { background: radial-gradient(circle at 70% 30%, var(--color-surface-warning-subtle) 0 18%, transparent 20%), var(--color-surface-inverse); }

/* ===== Top bar mood chip ================================================ */

/* Looks like the gift box and bell buttons next to it (.icon-btn--bordered). */
.mood-chip { flex: none; }
.mood-chip[hidden] { display: none; }
.mood-chip:focus-visible { outline: 2px solid var(--color-focus-ring); outline-offset: 2px; }
.mood-chip__face { width: 28px; height: 28px; }
.mood-chip__face .mf-shadow { display: none; }

/* ===== Mood characters ================================================= */

.mood-face { display: block; overflow: visible; }
.mood-face .mf-f { display: none; }
.mood-face[data-mood="great"] .mf-f--great,
.mood-face[data-mood="happy"] .mf-f--happy,
.mood-face[data-mood="neutral"] .mf-f--neutral,
.mood-face[data-mood="none"] .mf-f--neutral,
.mood-face[data-mood="tired"] .mf-f--tired,
.mood-face[data-mood="sad"] .mf-f--sad,
.mood-face[data-mood="angry"] .mf-f--angry,
.mood-face[data-mood="great"] .mf-f--cheeks,
.mood-face[data-mood="happy"] .mf-f--cheeks,
.mood-face[data-mood="none"] .mf-f--cheeks { display: inline; }

.mf-shadow { fill: var(--color-text-primary); opacity: .08; }
.mf-body { fill: var(--color-border-brand); transition: fill var(--motion-moderate) ease; }
.mood-face[data-mood="great"] .mf-body { fill: var(--color-action-primary-default); }
.mood-face[data-mood="happy"] .mf-body { fill: var(--color-border-success); }
.mood-face[data-mood="neutral"] .mf-body { fill: var(--color-border-brand); }
.mood-face[data-mood="tired"] .mf-body { fill: var(--color-border-default); }
.mood-face[data-mood="sad"] .mf-body { fill: var(--color-border-info); }
.mood-face[data-mood="angry"] .mf-body { fill: var(--color-border-danger); }
.mf-shine { fill: var(--color-surface-base); opacity: .45; }
.mf-cheek { fill: var(--color-surface-danger-subtle); opacity: .9; }
.mf-ink { fill: var(--color-text-primary); }
.mf-glint { fill: var(--color-surface-base); }
.mf-tongue { fill: var(--color-border-danger); opacity: .8; }
.mf-line { fill: none; stroke: var(--color-text-primary); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.mf-line--thin { stroke-width: 3; }
.mf-spark { fill: var(--color-border-warning); }
.mf-z { fill: none; stroke: var(--color-text-tertiary); stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.mf-tear { fill: var(--color-surface-info-subtle); }
.mf-steam { fill: var(--color-border-subtle); }

.mf-eyes { transform-box: fill-box; transform-origin: center; animation: mf-blink 5s ease-in-out infinite; }
.mf-spark, .mf-z, .mf-steam { transform-box: fill-box; transform-origin: center; animation: mf-twinkle 2.4s ease-in-out infinite; }
.mf-spark--2, .mf-z--2, .mf-steam--2 { animation-delay: .8s; }
.mood-face--float .mf-wrap { animation: mf-float 3.6s ease-in-out infinite; }
.mood-face--float .mf-shadow { transform-box: fill-box; transform-origin: center; animation: mf-shadow 3.6s ease-in-out infinite; }
.mood-face.is-pop .mf-wrap { animation: mf-pop .7s cubic-bezier(.3, 1.6, .5, 1) 1; }
@keyframes mf-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes mf-shadow { 0%, 100% { transform: scaleX(1); opacity: .08; } 50% { transform: scaleX(.86); opacity: .05; } }
@keyframes mf-blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes mf-twinkle { 0%, 100% { opacity: .35; transform: scale(.85); } 50% { opacity: 1; transform: scale(1); } }
@keyframes mf-pop { 0% { transform: scale(.8); } 60% { transform: scale(1.08); } 100% { transform: scale(1); } }

/* ===== Mood check-in =================================================== */

.mood-check { margin-top: var(--space-8); }
.mood-check__q { font-size: 14px; line-height: 22px; font-weight: 600; }
.mood-check__list { display: flex; flex-wrap: wrap; gap: var(--space-8); margin-top: var(--space-8); }
.mood-check__status { margin-top: var(--space-8); color: var(--color-text-tertiary); font-size: 12px; line-height: 20px; min-height: 20px; }

.mood-pick {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  min-width: 64px;
  min-height: var(--size-touch-min);
  padding: var(--space-6) var(--space-4) var(--space-4);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-lg);
  background: var(--color-surface-base);
  color: var(--color-text-secondary);
  font: inherit;
  font-size: 12px;
  line-height: 18px;
  cursor: pointer;
  transition: border-color var(--motion-fast) ease, background-color var(--motion-fast) ease, transform var(--motion-standard) ease;
}
.mood-pick__face { width: 40px; height: 40px; transition: transform var(--motion-moderate) cubic-bezier(.3, 1.6, .5, 1); }
.mood-pick:hover { border-color: var(--color-border-brand); background: var(--color-surface-page); }
.mood-pick:hover .mood-pick__face { transform: translateY(-3px) rotate(-6deg); }
.mood-pick:focus-visible { outline: 2px solid var(--color-focus-ring); outline-offset: 2px; }
.mood-pick[aria-pressed="true"] { border-color: var(--color-text-primary); background: var(--color-surface-subtle); color: var(--color-text-primary); font-weight: 600; }
.mood-pick[aria-pressed="true"] .mood-pick__face { animation: mf-pop .6s cubic-bezier(.3, 1.6, .5, 1) 1; }

/* ===== Dashboard notices =============================================== */

.dash-notices { border-inline-start: 4px solid var(--color-border-info); }
.dash-notices .card__head { flex-wrap: wrap; }
.dash-notices .card__title { display: inline-flex; align-items: center; gap: var(--space-8); }
.dash-notices__bell { color: var(--color-icon-info); }
.dash-notices__all { margin-inline-start: auto; min-height: var(--size-touch-min); font-weight: 500; }
.dash-notices .card__head .badge { margin-inline-end: 0; }
.dash-notices__list { margin: 0; padding: 0; list-style: none; }
.dash-notices__item { display: flex; align-items: center; gap: var(--space-8); padding-inline-end: var(--space-16); }
.dash-notices__item + .dash-notices__item { border-top: var(--border-thin) solid var(--color-border-subtle); }
.dash-notices__link {
  flex: 1;
  display: flex;
  align-items: flex-start;
  gap: var(--space-12);
  min-width: 0;
  padding: var(--space-12) var(--space-24);
  color: var(--color-text-primary);
  text-decoration: none;
}
.dash-notices__link:hover { background: var(--color-surface-page); }
.dash-notices__link:focus-visible { outline: 2px solid var(--color-focus-ring); outline-offset: -2px; }
.dash-notices__chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  background: var(--color-surface-info-subtle);
  color: var(--color-icon-info);
}
.dash-notices__text { display: flex; flex-direction: column; min-width: 0; }
.dash-notices__title { font-size: 14px; line-height: 22px; font-weight: 500; }
.dash-notices__body { color: var(--color-text-secondary); font-size: 12px; line-height: 20px; }
.dash-notices__time { color: var(--color-text-tertiary); font-size: 12px; line-height: 18px; }
.dash-notices__done { flex: none; width: var(--size-touch-min); height: var(--size-touch-min); color: var(--color-icon-secondary); }
.dash-notices__more { padding: var(--space-8) var(--space-24) var(--space-12); color: var(--color-text-tertiary); font-size: 12px; }

/* ===== Kudos ============================================================ */

.kudos-badge { flex: none; display: block; }
.kudos-badge--sm { width: 32px; height: 32px; }
.kudos-badge--md { width: 44px; height: 44px; }
.kudos-badge--lg { width: 56px; height: 56px; }
.kb-ring { fill: var(--color-surface-subtle); }
.kb-fill { fill: var(--color-surface-base); }
.kb-hole { fill: var(--color-text-primary); opacity: .55; }
.kb-stroke { fill: none; stroke: var(--color-surface-base); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.kb-stroke--ink { stroke: var(--color-text-primary); opacity: .55; }
.kudos-badge--gold .kb-face { fill: var(--color-action-primary-default); }
.kudos-badge--gold .kb-ring { fill: var(--color-surface-warning-subtle); }
.kudos-badge--success .kb-face { fill: var(--color-border-success); }
.kudos-badge--success .kb-ring { fill: var(--color-surface-success-subtle); }
.kudos-badge--warning .kb-face { fill: var(--color-border-warning); }
.kudos-badge--warning .kb-ring { fill: var(--color-surface-warning-subtle); }
.kudos-badge--info .kb-face { fill: var(--color-border-info); }
.kudos-badge--info .kb-ring { fill: var(--color-surface-info-subtle); }
.kudos-badge--danger .kb-face { fill: var(--color-border-danger); }
.kudos-badge--danger .kb-ring { fill: var(--color-surface-danger-subtle); }
.kudos-badge--neutral .kb-face { fill: var(--color-border-default); }

.kudo-list { display: grid; gap: var(--space-12); }
.kudo-list--wall { grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: var(--space-16); }
.kudo {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: var(--space-12);
  padding: var(--space-16);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-xl);
  background: var(--color-surface-base);
}
.kudo--compact { padding: var(--space-12); border-radius: var(--radius-lg); background: var(--color-surface-page); }
.kudo__body { flex: 1; min-width: 0; }
.kudo__people { font-size: 13px; line-height: 22px; color: var(--color-text-secondary); }
.kudo__people strong { color: var(--color-text-primary); font-weight: 600; }
.kudo__arrow { color: var(--color-text-tertiary); }
.kudo__label { font-size: 15px; line-height: 24px; font-weight: 600; }
.kudo--compact .kudo__label { font-size: 14px; line-height: 22px; }
.kudo__note { margin-top: var(--space-4); color: var(--color-text-secondary); font-size: 13px; line-height: 22px; overflow-wrap: anywhere; }
.kudo__meta { margin-top: var(--space-4); color: var(--color-text-tertiary); font-size: 12px; line-height: 18px; }
.kudo__tools { flex: none; }
.kudo:target { border-color: var(--color-border-focus); }

.dash-kudos .kudo-list { margin-bottom: var(--space-16); }
.dash-kudos__empty { margin-bottom: var(--space-16); color: var(--color-text-secondary); font-size: 13px; line-height: 22px; }

.kudos-page .tabs { margin-bottom: var(--space-16); }
.kudos-picks { margin: 0; padding: 0; border: 0; }
.kudos-picks .field__label { margin-bottom: var(--space-8); }
.kudos-picks__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-8); }
.kudos-pick {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
  min-height: 96px;
  padding: var(--space-12) var(--space-6);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-lg);
  background: var(--color-surface-base);
  text-align: center;
  cursor: pointer;
  transition: border-color var(--motion-fast) ease, background-color var(--motion-fast) ease;
}
.kudos-pick__input { position: absolute; opacity: 0; pointer-events: none; }
.kudos-pick__label { font-size: 12px; line-height: 18px; color: var(--color-text-secondary); }
.kudos-pick .kudos-badge { transition: transform var(--motion-moderate) cubic-bezier(.3, 1.6, .5, 1); }
.kudos-pick:hover { background: var(--color-surface-page); }
.kudos-pick:hover .kudos-badge { transform: translateY(-2px) rotate(-6deg); }
.kudos-pick:has(.kudos-pick__input:checked) { border-color: var(--color-text-primary); background: var(--color-surface-subtle); }
.kudos-pick:has(.kudos-pick__input:checked) .kudos-pick__label { color: var(--color-text-primary); font-weight: 600; }
.kudos-pick:has(.kudos-pick__input:checked) .kudos-badge { animation: mf-pop .6s cubic-bezier(.3, 1.6, .5, 1) 1; }
.kudos-pick:has(.kudos-pick__input:focus-visible) { outline: 2px solid var(--color-focus-ring); outline-offset: 2px; }

/* ===== Gift box ========================================================= */

.gift-icon { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.giftbox { position: relative; }
.giftbox__btn { position: relative; width: var(--size-control-medium); height: var(--size-control-medium); }
.giftbox__btn.has-new .giftbox__icon,
.giftbox-card__title .giftbox__icon.has-new { transform-origin: 50% 90%; animation: gift-wiggle 3s ease-in-out infinite; }
.giftbox__count {
  position: absolute;
  top: -4px;
  inset-inline-end: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border: 2px solid var(--color-surface-base);
  border-radius: var(--radius-full);
  background: var(--color-icon-danger);
  color: var(--color-text-inverse);
  font-size: 11px;
  line-height: 14px;
  font-weight: 700;
  text-align: center;
}
@keyframes gift-wiggle {
  0%, 70%, 100% { transform: rotate(0); }
  75% { transform: rotate(-12deg); }
  80% { transform: rotate(10deg); }
  85% { transform: rotate(-8deg); }
  90% { transform: rotate(5deg); }
}
.giftbox__panel {
  position: absolute;
  z-index: 45;
  top: calc(100% + var(--space-8));
  inset-inline-end: 0;
  width: 400px;
  max-width: calc(100vw - var(--space-32));
  max-height: min(70vh, 560px);
  overflow-y: auto;
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-xl);
  background: var(--color-surface-overlay);
  box-shadow: 0 16px 40px -16px var(--color-border-strong);
}
.giftbox__head { padding: var(--space-16) var(--space-20); border-bottom: var(--border-thin) solid var(--color-border-subtle); }
.giftbox__heading { font-size: 16px; line-height: 24px; font-weight: 600; }
.giftbox__all { display: block; padding: var(--space-12) var(--space-20); color: var(--color-text-primary); font-size: 13px; font-weight: 500; text-decoration: none; }
.giftbox__all:hover { text-decoration: underline; }
.giftbox__list { margin: 0; padding: 0; list-style: none; }
.giftbox__item { display: flex; align-items: flex-start; gap: var(--space-12); padding: var(--space-12) var(--space-20); }
.giftbox__item + .giftbox__item { border-top: var(--border-thin) solid var(--color-border-subtle); }
.giftbox__item--kudo { display: block; }
.giftbox__item.is-new { background: var(--color-surface-warning-subtle); }
.giftbox__item--party { align-items: center; background: var(--color-surface-warning-subtle); }
.giftbox__art { flex: none; width: 96px; height: 80px; }
.giftbox__chip {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--color-surface-warning-subtle);
  color: var(--color-text-warning);
}
.giftbox__text { flex: 1; min-width: 0; }
.giftbox__kicker { color: var(--color-text-tertiary); font-size: 12px; line-height: 18px; }
.giftbox__title { font-size: 14px; line-height: 22px; font-weight: 600; }
.giftbox__item--party .giftbox__title { font-size: 16px; line-height: 26px; }
.giftbox__desc { color: var(--color-text-secondary); font-size: 13px; line-height: 22px; overflow-wrap: anywhere; }
.giftbox__done { display: inline-flex; align-items: center; gap: var(--space-4); margin-top: var(--space-4); color: var(--color-text-success); font-size: 12px; }
.giftbox__actions { margin-top: var(--space-8); }
.giftbox-card__title { display: inline-flex; align-items: center; gap: var(--space-8); }
.giftbox-card .giftbox__item { padding-inline: var(--space-24); }

.celebration-art { display: block; overflow: visible; }
.ca-c { transform-box: fill-box; transform-origin: center; animation: ca-fall 2.6s ease-out 1 both; }
.ca-c--1 { fill: var(--color-action-primary-default); }
.ca-c--2 { fill: var(--color-border-info); animation-delay: .2s; }
.ca-c--3 { fill: var(--color-border-success); animation-delay: .4s; }
.ca-c--4 { fill: var(--color-border-danger); animation-delay: .1s; }
.ca-c--5 { fill: var(--color-border-warning); animation-delay: .3s; }
.ca-plate { fill: var(--color-border-subtle); }
.ca-cake { fill: var(--color-action-primary-default); }
.ca-cake--top { fill: var(--color-border-warning); }
.ca-icing { fill: var(--color-surface-base); }
.ca-candle { fill: var(--color-border-info); }
.ca-flame { fill: var(--color-border-warning); transform-box: fill-box; transform-origin: 50% 100%; animation: ca-flicker 1.4s ease-in-out infinite; }
.ca-flame--2 { animation-delay: .3s; }
.ca-flame--3 { animation-delay: .6s; }
.ca-medal { fill: var(--color-action-primary-default); }
.ca-medal__inner { fill: var(--color-surface-warning-subtle); }
.ca-star { fill: var(--color-action-primary-pressed); }
.ca-ribbon { fill: var(--color-border-info); }
@keyframes ca-fall { from { opacity: 0; transform: translateY(-14px) rotate(-40deg); } to { opacity: 1; transform: translateY(0) rotate(0); } }
@keyframes ca-flicker { 0%, 100% { transform: scale(1, 1); } 50% { transform: scale(.85, 1.12); } }

/* ===== Person combobox ================================================= */

.combo__input { cursor: text; }
.combo__control:has(.combo__input[aria-expanded="true"]) .combo__chevron { transform: rotate(90deg); }
.combo__pop {
  position: absolute;
  z-index: 40;
  inset-block-start: calc(100% + var(--space-4));
  inset-inline: -1px;
  max-height: 272px;
  overflow-y: auto;
  padding: var(--space-4);
  border: var(--border-thin) solid var(--color-border-subtle);
  border-radius: var(--radius-md);
  background: var(--color-surface-overlay);
  box-shadow: 0 16px 40px -16px var(--color-border-strong);
}
.combo__list { margin: 0; padding: 0; list-style: none; }
.combo__opt {
  display: flex;
  align-items: center;
  gap: var(--space-8);
  min-height: var(--size-touch-min);
  padding: var(--space-4) var(--space-8);
  border-radius: var(--radius-sm);
  color: var(--color-text-primary);
  cursor: pointer;
}
.combo__opt[hidden] { display: none; }
.combo__opt:hover { background: var(--color-surface-page); }
.combo__opt.is-active { background: var(--color-surface-subtle); box-shadow: inset 0 0 0 2px var(--color-focus-ring); }
.combo__opt--none { color: var(--color-text-secondary); font-size: 13px; }
.combo__avatar {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--color-surface-subtle);
  color: var(--color-text-secondary);
  font-size: 11px;
  font-weight: 600;
}
.combo__text { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.combo__name { font-size: 14px; line-height: 22px; }
.combo__sub { color: var(--color-text-tertiary); font-size: 12px; line-height: 18px; }
.combo__check { flex: none; color: var(--color-icon-success); visibility: hidden; }
.combo__opt.is-chosen .combo__check { visibility: visible; }
.combo__opt.is-chosen .combo__name { font-weight: 600; }
.combo__empty { margin: 0; padding: var(--space-12); color: var(--color-text-tertiary); font-size: 13px; line-height: 22px; }

/* ===== «پیشنهادها و انتقادها» (private) ================================== */

.my-suggestions .section-title { margin-top: var(--space-8); }
.my-suggestions__list { display: grid; gap: var(--space-16); margin: 0; padding: 0; list-style: none; }
.my-suggestion { display: flex; flex-direction: column; gap: var(--space-8); }
.my-suggestion__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-8); }
.my-suggestion__tags { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-8); }
.my-suggestion__tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-4);
  min-height: 24px;
  padding: 0 var(--space-8);
  border-radius: var(--radius-full);
  background: var(--color-surface-subtle);
  color: var(--color-text-secondary);
  font-size: 12px;
  font-weight: 500;
}
.my-suggestion__title { font-size: 17px; line-height: 28px; font-weight: 600; }
.my-suggestion__body { color: var(--color-text-primary); font-size: 14px; line-height: 26px; overflow-wrap: anywhere; }
.my-suggestion__meta { color: var(--color-text-tertiary); font-size: 12px; line-height: 20px; }
.my-suggestion__reply {
  margin-top: var(--space-4);
  padding: var(--space-12) var(--space-16);
  border-inline-start: 3px solid var(--color-border-success);
  border-radius: var(--radius-md);
  background: var(--color-surface-success-subtle);
  font-size: 13px;
  line-height: 22px;
}
.my-suggestion__reply-title { display: inline-flex; align-items: center; gap: var(--space-4); color: var(--color-text-success); font-weight: 600; }
.my-suggestion:target { border-color: var(--color-border-focus); }
.suggestion-to .segmented { margin-bottom: var(--space-4); }

/* ===== «همکاران»: today's mood ========================================== */

.person__name { display: inline-flex; align-items: center; gap: var(--space-6); }
.person__mood { display: inline-flex; }
.person__mood-face { width: 22px; height: 22px; }
.person__mood-face .mf-shadow { display: none; }

/* ===== «گزارش تخلف» ===================================================== */

.whistle .switch { margin-bottom: var(--space-16); }
.whistle__form > div { display: flex; flex-direction: column; gap: var(--space-16); }
.whistle__done { align-items: flex-start; }
.whistle__done-text { color: var(--color-text-secondary); font-size: 14px; line-height: 24px; }
.whistle__code {
  align-self: stretch;
  padding: var(--space-16);
  border: 2px dashed var(--color-border-brand);
  border-radius: var(--radius-lg);
  background: var(--color-surface-page);
  font-family: ui-monospace, "SFMono-Regular", Consolas, monospace;
  font-size: 22px;
  line-height: 32px;
  font-weight: 700;
  letter-spacing: .06em;
  text-align: center;
  user-select: all;
}
.whistle__track .form-stack + .whistle__result { margin-top: var(--space-16); }
.whistle__status { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-8); font-size: 13px; color: var(--color-text-secondary); }
.whistle__thread { display: grid; gap: var(--space-8); margin: var(--space-12) 0; padding: 0; list-style: none; }
.whistle__msg { padding: var(--space-8) var(--space-12); border-radius: var(--radius-md); background: var(--color-surface-subtle); font-size: 13px; line-height: 22px; }
.whistle__msg--hr { background: var(--color-surface-info-subtle); }
.whistle__msg-head { color: var(--color-text-tertiary); font-size: 12px; }
.whistle__msg-body { white-space: pre-line; overflow-wrap: anywhere; }
.whistle__none { margin: var(--space-12) 0; color: var(--color-text-tertiary); font-size: 12px; line-height: 20px; }
.whistle__main { display: flex; flex-direction: column; gap: var(--space-16); min-width: 0; }
.whistle__mine .card__title { margin-bottom: var(--space-12); }
.whistle__mine-list { display: grid; gap: var(--space-12); margin: 0; padding: 0; list-style: none; font-size: 13px; }
.whistle__mine-item + .whistle__mine-item { padding-top: var(--space-12); border-top: var(--border-thin) solid var(--color-border-subtle); }
.whistle__mine-row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-8); }
.whistle__mine-item .whistle__thread { margin-bottom: 0; }
.whistle__track-hint { margin-bottom: var(--space-12); color: var(--color-text-secondary); font-size: 13px; line-height: 22px; }
.whistle .form-layout__side { display: flex; flex-direction: column; gap: var(--space-16); }
.whistle-hr .tabs { margin-bottom: var(--space-16); }
.whistle-hr__facts { margin-bottom: var(--space-8); }
.whistle-hr__body { white-space: normal; }

/* ===== HR gifts ========================================================= */

.gifts-hr__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gifts-hr__recent { margin-top: var(--space-8); }
.occasion-list { display: grid; margin: 0; padding: 0; list-style: none; }
.occasion-list__row { display: flex; align-items: center; gap: var(--space-12); padding: var(--space-12) 0; border-bottom: var(--border-thin) solid var(--color-border-subtle); }
.occasion-list__row:last-child { border-bottom: 0; }
.occasion-list__row.is-today { background: var(--color-surface-warning-subtle); padding-inline: var(--space-8); border-radius: var(--radius-md); }
.occasion-list__day { flex: none; min-width: 72px; color: var(--color-text-secondary); font-size: 13px; }
.occasion-list__who { flex: 1; display: flex; flex-direction: column; min-width: 0; font-size: 13px; line-height: 20px; }
.occasion-list__who span { color: var(--color-text-tertiary); font-size: 12px; }

/* ===== HR mood report =================================================== */

.mood-report { display: flex; flex-direction: column; gap: var(--space-16); margin-top: var(--space-24); }
.mood-report .reports__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mood-bars { display: grid; gap: var(--space-8); margin: 0; padding: 0; list-style: none; }
.mood-bars__row { display: grid; grid-template-columns: 28px 64px minmax(0, 1fr) 72px; gap: var(--space-8); align-items: center; font-size: 13px; line-height: 20px; }
.mood-bars__face { width: 28px; height: 28px; }
.mood-bars__value { color: var(--color-text-secondary); text-align: end; }
.mood-bars__fill--great { background: var(--color-action-primary-default); }
.mood-bars__fill--happy { background: var(--color-border-success); }
.mood-bars__fill--neutral { background: var(--color-border-brand); }
.mood-bars__fill--tired { background: var(--color-border-default); }
.mood-bars__fill--sad { background: var(--color-border-info); }
.mood-bars__fill--angry { background: var(--color-border-danger); }
.mood-units th, .mood-units td { text-align: center; }
.mood-units th[scope="row"] { text-align: start; }

/* ===== Responsive ======================================================= */

@media (max-width: 1023px) {
  .dash-hero { grid-template-columns: minmax(0, 1fr) 200px; }
  .gifts-hr__grid,
  .mood-report .reports__grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 767px) {
  .dash-hero {
    grid-template-columns: minmax(0, 1fr) 104px;
    gap: var(--space-12);
    padding: var(--space-16);
    align-items: start;
  }
  .dash-hero__text { display: contents; }
  .dash-hero__date { grid-column: 1; grid-row: 1; }
  .dash-hero__title { grid-column: 1; grid-row: 2; font-size: 20px; line-height: 30px; }
  .dash-hero__line { grid-column: 1 / -1; grid-row: 3; font-size: 13px; line-height: 22px; }
  .dash-hero__art { grid-column: 2; grid-row: 1 / span 2; }
  .mood-check { grid-column: 1 / -1; grid-row: 4; margin-top: 0; }
  .hero-scene { max-height: 96px; }
  .mood-check__list { flex-wrap: nowrap; justify-content: space-between; gap: var(--space-4); }
  .mood-pick { flex: 1 1 0; min-width: 0; padding-inline: 0; font-size: 11px; }
  .mood-pick__face { width: 34px; height: 34px; }

  .dash-notices { border-inline-start-width: 4px; }
  .dash-notices__link { padding: var(--space-12) var(--space-16); }
  .dash-notices__item { padding-inline-end: var(--space-8); }

  .kudos-picks__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-bg { inset-block-start: 0; inset-inline-end: 0; }
  .hero-bg__btn { width: var(--size-touch-min); height: var(--size-touch-min); min-height: 0; padding: 0; justify-content: center; }
  .hero-bg__btn-label { display: none; }
  .hero-bg__menu { width: min(264px, calc(100vw - 64px)); }
  .giftbox__panel { position: fixed; top: 72px; inset-inline: var(--space-16); width: auto; }
  .giftbox-card .giftbox__item { padding-inline: var(--space-16); }
  .giftbox__art { width: 72px; height: 60px; }
  .mood-report .table-wrap { overflow-x: auto; }
  .mood-bars__row { grid-template-columns: 24px 56px minmax(0, 1fr) 64px; }
  .mood-bars__row .bar-list__track { grid-column: auto; grid-row: auto; }
  .whistle__code { font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .hs-cloud, .hs-sun__glow, .hs-star, .hs-drift, .hs-twinkle, .hs-pulse, .hn-shoot,
  .mf-eyes, .mf-spark, .mf-z, .mf-steam,
  .mood-face--float .mf-wrap, .mood-face--float .mf-shadow, .mood-face.is-pop .mf-wrap,
  .mood-pick[aria-pressed="true"] .mood-pick__face,
  .kudos-pick:has(.kudos-pick__input:checked) .kudos-badge,
  .giftbox__btn.has-new .giftbox__icon, .giftbox-card__title .giftbox__icon.has-new,
  .ca-c, .ca-flame { animation: none; }
  .mood-pick, .mood-pick__face, .kudos-pick, .kudos-pick .kudos-badge, .mf-body { transition: none; }
  .mood-pick:hover .mood-pick__face, .kudos-pick:hover .kudos-badge { transform: none; }
}

.giftbox__empty { display: grid; justify-items: center; gap: 6px; padding: var(--space-16) var(--space-12); text-align: center; }
.giftbox__empty-art { width: 88px; height: auto; }
.giftbox__empty-title { margin: 0; font-weight: 700; }
.giftbox__empty-text { margin: 0; font-size: 13px; line-height: 22px; color: var(--color-text-secondary); max-width: 28ch; }
@media (prefers-reduced-motion: no-preference) {
  .giftbox__empty-art { animation: ahr-gift-bob 3s ease-in-out infinite; }
  @keyframes ahr-gift-bob { 50% { transform: translateY(-3px) rotate(-2deg); } }
}
