/* Spark Agency HR — Spark More (v46). */
@media screen {
  /* bell */
  .mr-bell {
    position: relative;
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    margin: 0;
    padding: 0;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
    box-shadow: none;
  }
  .mr-bell svg {
    width: 22px;
    height: 22px;
  }
  .mr-bell.has-new svg {
    animation: mr-ring 2.6s ease-in-out infinite;
    transform-origin: 50% 10%;
  }
  @keyframes mr-ring {
    0%,
    80%,
    100% {
      transform: rotate(0);
    }
    84% {
      transform: rotate(14deg);
    }
    88% {
      transform: rotate(-12deg);
    }
    92% {
      transform: rotate(8deg);
    }
  }
  .mr-bell i {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 99px;
    background: var(--rose);
    color: #fff;
    font-size: 11px;
    font-style: normal;
    font-weight: 800;
    line-height: 20px;
  }
  .mr-bell i[hidden] {
    display: none;
  }
  .mr-notes header {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  .mr-notes h2 {
    margin: 0;
  }
  .mr-notes ul {
    list-style: none;
    margin: 12px 0;
    padding: 0;
    display: grid;
    gap: 6px;
    max-height: 46vh;
    overflow: auto;
  }
  .mr-notes li button {
    display: grid;
    width: 100%;
    margin: 0;
    padding: 10px 12px;
    min-height: 0;
    text-align: left;
    border-radius: 12px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--text);
    box-shadow: none;
  }
  .mr-notes li.is-new button {
    border-color: #b8e1df;
    background: var(--teal-soft);
  }
  .mr-notes li span {
    color: var(--text-2);
    font-weight: 500;
  }
  .mr-notes li small {
    color: var(--text-2);
    letter-spacing: 0;
  }
  .mr-empty {
    padding: 14px;
  }
  .mr-app {
    display: grid;
    gap: 8px;
    padding: 14px;
    border-radius: 14px;
    background: linear-gradient(135deg, #0f2a36, #0a9a9c);
    color: #fff;
  }
  .mr-app p {
    margin: 4px 0 0;
    color: #d6efee !important;
  }
  .mr-app .hub-error {
    color: #ffd0d6;
  }
  .mr-tip {
    font-size: 12px;
  }

  /* weekly report */
  .mr-ins header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
  }
  .mr-ins h2 {
    margin: 0;
  }
  .mr-ins header p {
    margin: 2px 0 0;
  }
  .mr-ins-list {
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
    display: grid;
    gap: 6px;
  }
  .mr-ins-list li {
    display: grid;
    grid-template-columns: 34px 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--mist);
    border-left: 4px solid var(--line-strong);
    animation: set-in 0.35s var(--ease-out) both;
  }
  .mr-ins-list li:nth-child(2) {
    animation-delay: 60ms;
  }
  .mr-ins-list li:nth-child(3) {
    animation-delay: 120ms;
  }
  .mr-ins-list li:nth-child(4) {
    animation-delay: 180ms;
  }
  .mr-ins-list li p {
    margin: 0;
    font-weight: 600;
  }
  .mr-ins-ico {
    font-size: 22px;
    text-align: center;
  }
  .mr-ins-list li.is-bad {
    border-left-color: var(--rose);
    background: var(--rose-soft);
  }
  .mr-ins-list li.is-warn {
    border-left-color: var(--amber);
    background: var(--amber-soft);
  }
  .mr-ins-list li.is-good {
    border-left-color: var(--teal);
    background: var(--teal-soft);
  }
  .mr-ins-list li.is-info {
    border-left-color: #6366f1;
    background: #eef0ff;
  }

  /* public pages (host page, sign by link) */
  .mr-pub {
    position: fixed;
    inset: 0;
    z-index: 6000;
    overflow: auto;
    display: grid;
    justify-items: center;
    align-items: start;
    padding: 24px 14px;
    background: radial-gradient(120% 80% at 50% 0%, #10474f, #0f2a36 55%, #0a1c24);
  }
  .mr-pub-card {
    --c: #0a9a9c;
    display: grid;
    justify-items: center;
    gap: 8px;
    width: min(460px, 100%);
    padding: 26px 22px;
    border-radius: 26px;
    background: #fff;
    text-align: center;
    box-shadow: 0 30px 80px #0008;
    animation: set-in 0.5s var(--ease-out) both;
  }
  .mr-pub-card h1 {
    margin: 4px 0 0;
    font-size: 28px;
  }
  .mr-pub-logo {
    height: 44px;
  }
  .mr-pub-top {
    position: relative;
  }
  .mr-pub-photo {
    display: grid;
    place-items: center;
    width: 128px;
    height: 128px;
    border-radius: 50%;
    overflow: hidden;
    padding: 4px;
    background: conic-gradient(var(--c), #f6c453, #f43f5e, var(--c));
    animation: fun-spin 8s linear infinite;
  }
  .mr-pub-photo img,
  .mr-pub-photo span {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    display: grid;
    place-items: center;
    background: #fff;
    font-size: 40px;
    font-weight: 800;
    color: var(--c);
    animation: fun-spin 8s linear infinite reverse;
  }
  .mr-pub-level {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    padding: 3px 12px;
    border-radius: 99px;
    background: #dfe8e7;
    font-weight: 800;
    font-size: 13px;
  }
  .mr-pub-level.is-gold {
    background: linear-gradient(135deg, #fde7a6, #e2b04a);
  }
  .mr-pub-level.is-diamond {
    background: linear-gradient(135deg, #c9f1ff, #7cc7f0 60%, #b9a6ff);
  }
  .mr-pub-level.is-silver {
    background: linear-gradient(135deg, #eef2f4, #c4ced3);
  }
  .mr-pub-team {
    margin: 0;
    color: var(--text-2);
  }
  .mr-pub-top3 {
    margin: 0;
    padding: 4px 12px;
    border-radius: 99px;
    background: #fdf3e2;
    color: #7a4f10;
    font-weight: 800;
  }
  .mr-pub-bio {
    margin: 4px 0;
    font-size: 16px;
  }
  .mr-pub-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
  }
  .mr-pub-links a {
    padding: 8px 16px;
    border-radius: 99px;
    background: #0f2a36;
    color: #fff;
    font-weight: 700;
    text-decoration: none;
  }
  .mr-pub-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
  }
  .mr-pub-badges span {
    padding: 3px 10px;
    border-radius: 99px;
    background: #fdf3e2;
    color: #7a4f10;
    font-weight: 700;
    font-size: 12px;
  }
  .mr-pub-card h2 {
    margin: 12px 0 0;
    font-size: 16px;
  }
  .mr-pub-lives {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 6px;
    width: 100%;
  }
  .mr-pub-lives li {
    display: grid;
    padding: 10px 12px;
    border-radius: 12px;
    background: var(--mist);
    text-align: left;
  }
  .mr-pub-lives li.is-now {
    background: var(--rose-soft);
    color: var(--rose);
  }
  .mr-pub-lives span {
    font-size: 13px;
    color: var(--text-2);
  }
  .mr-pub-foot {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 10px 0 0;
    font-size: 12px;
    color: var(--text-2);
  }
  .mr-pub-foot img {
    height: 16px;
  }
  .mr-sign {
    text-align: left;
    justify-items: stretch;
  }
  .mr-sign .mr-pub-logo {
    justify-self: center;
  }
  .mr-sign form {
    display: grid;
    gap: 8px;
  }
  .mr-sign label {
    display: grid;
    gap: 4px;
    font-weight: 650;
  }
  .mr-sign-go {
    min-height: 50px;
    font-size: 17px;
  }
  .mr-pub-card .hr-tick {
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: var(--teal);
    color: #fff;
    font-size: 38px;
  }

  /* host pages admin */
  .mr-hp-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 12px;
  }
  .mr-hp {
    display: grid;
    gap: 8px;
    border-top: 4px solid var(--c, var(--teal));
  }
  .mr-hp.is-on {
    box-shadow: 0 0 0 2px #b8e1df;
  }
  .mr-hp header {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .mr-hp header div {
    display: grid;
    flex: 1;
  }
  .mr-hp header small {
    color: var(--text-2);
  }
  .mr-hp label {
    display: grid;
    gap: 3px;
    font-size: 13px;
    font-weight: 650;
  }
  .mr-hp-photo {
    display: grid !important;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--teal-soft);
    color: var(--teal-deep);
    font-weight: 800;
    cursor: pointer;
  }
  .mr-hp-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
  }
  .mr-hp-url {
    display: flex;
    align-items: center;
    gap: 2px;
    color: var(--text-2);
  }
  .mr-hp-url input {
    flex: 1;
  }
  .mr-switch {
    display: flex !important;
    align-items: center;
    gap: 6px;
  }
  .mr-switch input {
    appearance: none;
    position: relative;
    width: 38px !important;
    height: 22px;
    min-height: 0;
    margin: 0;
    border-radius: 99px;
    border: 0;
    background: #cdd9d8;
    transition: background 0.2s;
  }
  .mr-switch input::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    transition: transform 0.2s var(--ease-out);
  }
  .mr-switch input:checked {
    background: var(--teal);
  }
  .mr-switch input:checked::before {
    transform: translateX(16px);
  }
  a.secondary-link {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 6px 14px;
    border-radius: 10px;
    border: 1px solid var(--line-strong);
    color: var(--text);
    text-decoration: none;
    font-weight: 650;
  }

  /* owners report */
  .mr-own header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--teal);
  }
  .mr-own header img {
    height: 46px;
  }
  .mr-own h1 {
    margin: 0;
    font-size: 22px;
  }
  .mr-own header p {
    margin: 2px 0 0;
    color: var(--text-2);
  }
  .mr-own h2 {
    font-size: 15px;
    margin: 18px 0 8px;
  }
  .mr-own-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-top: 14px;
  }
  .mr-own-kpis div {
    display: grid;
    padding: 12px 14px;
    border-radius: 14px;
    background: var(--mist);
  }
  .mr-own-kpis small {
    color: var(--text-2);
  }
  .mr-own-kpis b {
    font-size: 24px;
  }
  .mr-own-kpis em {
    font-style: normal;
    font-size: 12px;
    color: var(--text-2);
  }
  .mr-own-kpis .is-good {
    background: var(--teal-soft);
  }
  .mr-own-kpis .is-bad {
    background: var(--rose-soft);
  }
  .mr-own .up {
    color: #0b7a52 !important;
  }
  .mr-own .down {
    color: var(--rose) !important;
  }
  .mr-own-chart {
    width: 100%;
    height: 130px;
  }
  .mr-area {
    fill: #0a9a9c22;
    stroke: none;
  }
  .mr-line {
    fill: none;
    stroke: var(--teal);
    stroke-width: 2.5;
    vector-effect: non-scaling-stroke;
  }
  .mr-own-teams {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
  }
  .mr-own-team {
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--line);
    border-top: 4px solid var(--c);
  }
  .mr-own-team p {
    margin: 6px 0 0;
    font-size: 13px;
  }
  .mr-own-team .lh-prog i {
    background: var(--c);
  }
  .mr-own-two {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
  .mr-own-two ol,
  .mr-own-two ul {
    margin: 0;
    padding-left: 18px;
    display: grid;
    gap: 4px;
  }
  .mr-own-two em {
    float: right;
    font-style: normal;
    font-weight: 700;
  }
  .mr-own-foot {
    margin-top: 16px;
    font-size: 11px;
    color: var(--text-2);
  }

  /* contracts */
  .mr-ct-fields {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }
  .mr-ct-url {
    width: 100%;
    font-size: 13px;
  }
  .mr-ct-tpl {
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
  }
  .mr-ct-tpl textarea {
    font-family: ui-monospace, monospace;
    font-size: 12px;
  }

  /* office map */
  .mr-om-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    margin: 0;
    font-size: 13px;
  }
  .mr-om-legend i {
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-right: 5px;
    border-radius: 4px;
    vertical-align: -1px;
  }
  .mr-om-legend .is-in i,
  .mr-om-it.st-in {
    --st: #10b981;
  }
  .mr-om-legend .is-late i,
  .mr-om-it.st-late {
    --st: #f59e0b;
  }
  .mr-om-legend .is-out i,
  .mr-om-it.st-out {
    --st: #64748b;
  }
  .mr-om-legend .is-away i,
  .mr-om-it.st-away {
    --st: #cbd5e1;
  }
  .mr-om-legend .is-leave i,
  .mr-om-it.st-leave {
    --st: #8b5cf6;
  }
  .mr-om-legend .is-live i {
    --st: #f43f5e;
  }
  .mr-om-legend i {
    background: var(--st);
  }
  .mr-om-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
  }
  .mr-om-tools button {
    margin: 0;
  }
  .mr-om-wrap {
    overflow-x: auto;
  }
  .mr-om {
    position: relative;
    display: grid;
    grid-template-columns: repeat(var(--cols), 1fr);
    grid-template-rows: repeat(var(--rows), 1fr);
    min-width: 720px;
    aspect-ratio: calc(var(--cols) / var(--rows));
    border-radius: 14px;
    background: linear-gradient(#e7efee 1px, transparent 1px) 0 0 / calc(100% / var(--cols)) calc(100% / var(--rows)), linear-gradient(90deg, #e7efee 1px, transparent 1px) 0 0 / calc(100% / var(--cols)) calc(100% / var(--rows)), #f8fbfb;
  }
  .mr-om:not(.is-edit) {
    background: #f4f8f8;
  }
  .mr-om-empty {
    grid-column: 1 / -1;
    grid-row: 1 / -1;
    place-self: center;
    color: var(--text-2);
  }
  .mr-om-it {
    position: relative;
    grid-column: calc(var(--x) + 1) / span var(--w);
    grid-row: calc(var(--y) + 1) / span var(--h);
    display: grid;
    align-content: center;
    justify-items: center;
    gap: 2px;
    margin: 3px;
    padding: 4px;
    border-radius: 12px;
    text-align: center;
    overflow: hidden;
    font-size: 12px;
    transition: box-shadow 0.2s, background 0.3s;
  }
  .mr-om-it.is-desk {
    background: #fff;
    border: 2px solid var(--st, #dbe5e4);
  }
  .mr-om-it.is-desk.st-in {
    box-shadow: 0 0 0 4px #10b98122;
  }
  .mr-om-it.is-studio {
    background: #fff5f6;
    border: 2px dashed #f2b6c0;
  }
  .mr-om-it.is-studio.st-live {
    background: #ffe4e9;
    border: 2px solid #f43f5e;
    animation: mr-live 1.6s ease-in-out infinite;
  }
  @keyframes mr-live {
    50% {
      box-shadow: 0 0 0 8px #f43f5e22;
    }
  }
  .mr-om-it.is-room {
    background: #eef6ff;
    border: 2px solid #cfe1f7;
  }
  .mr-om-it.is-wall {
    background: #94a3b8;
    border-radius: 4px;
  }
  .mr-om-av {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--st, #e2e8f0);
    color: #fff;
    font-weight: 800;
    font-size: 11px;
  }
  .mr-om-it.st-away .mr-om-av {
    color: #64748b;
  }
  .mr-om-it small {
    color: var(--text-2);
    letter-spacing: 0;
  }
  .mr-om.is-edit .mr-om-it {
    cursor: move;
    touch-action: none;
  }
  .mr-om-it.is-sel {
    outline: 3px solid var(--teal);
  }
  .mr-om-rs {
    position: absolute;
    right: 2px;
    bottom: 2px;
    width: 12px;
    height: 12px;
    border-right: 3px solid var(--teal-deep);
    border-bottom: 3px solid var(--teal-deep);
    cursor: nwse-resize;
  }

  @media (max-width: 760px) {
    .mr-own-two,
    .mr-ct-fields {
      grid-template-columns: 1fr;
    }
  }
  @media (prefers-reduced-motion: reduce) {
    .mr-bell.has-new svg,
    .mr-pub-photo,
    .mr-pub-photo img,
    .mr-pub-photo span,
    .mr-om-it.is-studio.st-live {
      animation: none !important;
    }
  }
}
@media print {
  .mr-own header img {
    height: 40px;
  }
  .mr-own-kpis,
  .mr-own-teams {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
  }
  .mr-own-chart {
    width: 100%;
    height: 110px;
  }
  .mr-area {
    fill: #0a9a9c22;
  }
  .mr-line {
    fill: none;
    stroke: #0a9a9c;
    stroke-width: 2;
  }
}

/* Settings › Spark Plus › Phone app (v48) */
@media screen {
  .set-phone { margin-top: 16px; }
  .mr-phone { border: 1px solid #d6e2e1; border-radius: 16px; padding: 18px 20px; background: #fff; display: grid; gap: 10px; }
  .mr-phone-head { display: flex; align-items: flex-start; gap: 14px; flex-wrap: wrap; }
  .mr-phone-head > div { flex: 1; min-width: 220px; }
  .mr-phone-head b { display: block; font-size: 15px; }
  .mr-phone-head small { display: block; color: var(--text-2, #5b7178); }
  .mr-phone-head p { margin: 6px 0 0; }
  .mr-phone-ico { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: #0f2a36; color: #5fe0dc; flex: none; }
  .mr-phone-ico svg { width: 22px; height: 22px; }
  .mr-phone-state { align-self: center; padding: 5px 12px; border-radius: 999px; background: #f1f4f4; color: #5b7178; font-size: 12.5px; font-weight: 700; }
  .mr-phone-state.is-on { background: #e2f6ef; color: #0d7a5c; }
  .mr-phone details summary { cursor: pointer; font-weight: 700; color: var(--teal-deep, #0b6b6d); }
  .mr-phone textarea { width: 100%; font: 12px/1.45 ui-monospace, Menlo, Consolas, monospace; margin: 8px 0; box-sizing: border-box; }
}
@media screen {
  .mr-app .link { color: #bff3ef; text-decoration: underline; }
}
@media screen { .mr-phone-head small { text-align: left; } }
/* v57: the paper to sign is the Spark paper */
@media screen {
  .mr-pub-card.is-paper { width: min(760px, 100%); padding: 14px; gap: 14px; }
  .mr-pub-card.is-paper .sp-sheet { box-shadow: none; border: 1px solid #dfe6f2; }
  .mr-pub-card.is-paper form { padding: 4px 6px 8px; }
  .mr-signed-top { display: grid; justify-items: center; gap: 4px; text-align: center; padding-top: 8px; }
  .mr-signed-top h1 { margin: 0; }
  .sg-doc .sp-sheet.sp-fluid { margin: 6px 0 14px; box-shadow: none; border: 1px solid #dfe6f2; }
  .sg-from { margin: 0 0 4px; }
  .mr-sign .sg-agree { display: flex !important; grid-template-columns: none; align-items: center; gap: 10px; }
  .mr-sign .sg-agree input { width: 20px; height: 20px; flex: none; margin: 0; }
}
