#zenya-shell {
    --zenya-accent: #20b2aa;
    --zenya-accent-dark: #188f89;
    --zenya-text: #25282d;
    --zenya-muted: #747980;
    --zenya-border: #dedfe1;
    --zenya-background: #ffffff;

    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 2147483647;

    width: 340px;
    max-width: calc(100vw - 16px);
    /* Keep Filters / long panels usable on short mobile viewports */
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;

    background: var(--zenya-background);
    color: var(--zenya-text);

    border: 1px solid var(--zenya-border);
    border-top: 5px solid var(--zenya-accent);
    border-radius: 10px;

    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.20);

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Helvetica,
        Arial,
        sans-serif;

    font-size: 14px;

    transition:
  left 250ms ease,
    top 250ms ease,
    width 250ms ease,
    height 250ms ease,
    border-radius 250ms ease;
}

#zenya-shell.zenya-dragging {
    transition: none;
}


#zenya-shell * {
    box-sizing: border-box;
}

/* ------------------------------------------------------------
   Header
------------------------------------------------------------ */

.zenya-header {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 9px 18px;

    border-bottom: 1px solid var(--zenya-border);
}

.zenya-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.zenya-mark {
    color: var(--zenya-accent);
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
}

.zenya-name {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.5px;
}

.zenya-window-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.zenya-minimize,
.zenya-close {
    border: 0;
    background: none;
    padding: 0;

    color: var(--zenya-muted);

    cursor: pointer;
    line-height: 1;

    transition: color 150ms ease;
}

.zenya-minimize,
.zenya-close {
    width: 20px;
    height: 20px;
}

.zenya-minimize svg,
.zenya-close svg {
    display: block;
    width: 100%;
    height: 100%;
}

.zenya-minimize:hover,
.zenya-close:hover {
    color: var(--zenya-text);
}

.zenya-kudos-stop {
    display: flex;
    align-items: center;
    justify-content: center;

    position: absolute;

    top: 9px;
    right: 18px;

    height: 28px;
    padding: 0 14px;

    border: 1px solid var(--zenya-border);
    border-radius: 6px;

    background: #ffffff;
    color: var(--zenya-text);

    font: inherit;
    font-weight: 600;

    cursor: pointer;

    z-index: 1000;

    transition:
        border-color 150ms ease,
        background 150ms ease;
}

.zenya-kudos-stop:disabled {
    cursor: default;
}

.zenya-kudos-stop[hidden] {
    display: none !important;
}

.zenya-kudos-stop:hover {
    border-color: var(--zenya-accent);
}

.zenya-tool.sak-stop {
    display: block;

    width: fit-content;
    min-width: 110px;

    margin: 14px auto 0;

    text-align: center;
}

/* ------------------------------------------------------------
   Compact shell
------------------------------------------------------------ */

.zenya-compact {
    padding: 18px;
}

.zenya-auto-kudos-panel {
    display: none;
    padding: 18px;
}

#zenya-shell .zenya-compact {
    display: none;
}

#zenya-shell .zenya-auto-kudos-panel {
    display: block;
}

.zenya-intro {
    margin: 0 0 18px;
    color: var(--zenya-muted);
    font-size: 13px;
    line-height: 1.5;
}

.zenya-tools {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.zenya-tools-secondary {
    display: flex;
    gap: 8px;
}

.zenya-tools-secondary .zenya-tool {
    flex: 1;
    text-align: center;
}

.zenya-tool {
    width: 100%;
    padding: 11px 13px;
    text-align: left;
    background: #f7f8f8;
    color: var(--zenya-text);
    border: 1px solid transparent;
    border-radius: 7px;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
    transition:
        background 150ms ease,
        border-color 150ms ease;
}

.zenya-tool-primary {
    text-align: center;
    background: var(--zenya-accent);
    border-color: var(--zenya-accent);
    color: #fff;

    font-weight: 700;

    box-shadow: 0 8px 24px rgb(32 178 170 / 18%);

    transition:
        background 150ms ease,
        border-color 150ms ease,
        box-shadow 150ms ease,
        transform 150ms ease;
}

.zenya-tool-primary:hover,
[data-kudos-action]:hover {
    box-shadow: 0 11px 28px rgb(32 178 170 / 25%);
    transform: translateY(-2px);
}

.zenya-tool-primary:active {
    transform: translateY(0);
}

.zenya-tool:not(.zenya-tool-primary):hover {
    background: #ffffff;
    border-color: var(--zenya-accent);
}

.zenya-tool-explorer {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding-top: 10px;
    padding-bottom: 10px;
}

.zenya-explorer-btn-brand {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    line-height: 1;
}

.zenya-explorer-btn-mark {
    color: #ffffff;
    font-size: 22px;
    font-weight: 800;
    line-height: 1;
}

.zenya-explorer-btn-name {
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.3px;
    text-transform: none;
}

.zenya-tool:disabled {
    color: #a9adb1;
    background: #f7f8f8;
    cursor: default;
    opacity: 0.65;
}

.zenya-tool:disabled:hover {
    background: #f7f8f8;
    transform: none;
}

/* ------------------------------------------------------------
   Smaller screens
------------------------------------------------------------ 
@media (pointer: coarse) {
    #zenya-shell.zenya-minimized {
        width: 260px;
    }
}

/* ------------------------------------------------------------
   Auto Kudos
------------------------------------------------------------ */

#zenya-shell.zenya-minimized {
    width: 260px;
}

.zenya-auto-kudos-panel h2 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 600;
}

.zenya-auto-kudos-main > p,
.zenya-auto-kudos-favorites > p,
.zenya-auto-kudos-activity-types > p {
    margin: 0 0 18px;
    color: var(--zenya-muted);
    font-size: 13px;
    line-height: 1.5;
}

/* Settings */

.zenya-kudos-settings-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.zenya-kudos-setting-group {
    padding: 10px 13px;
    background: #f7f8f8;
    border: 1px solid var(--zenya-border);
    border-radius: 7px;
}

.zenya-kudos-setting-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.zenya-kudos-setting-row strong,
.zenya-kudos-setting-group > label {
    display: block;
    margin: 0 0 3px;
    font-weight: 600;
}

.zenya-kudos-setting-summary {
    color: var(--zenya-muted);
    font-size: 12px;
}

.zenya-kudos-setting-row button {
    flex: 0 0 auto;
    padding: 6px 12px;
    background: #ffffff;
    color: var(--zenya-text);
    border: 1px solid var(--zenya-border);
    border-radius: 6px;
    font: inherit;
    font-size: 12px;
    cursor: pointer;
}

.zenya-kudos-setting-row button:hover {
    border-color: var(--zenya-accent);
}

.zenya-kudos-setting-row button:focus,
.zenya-kudos-setting-row button:focus-visible {
    outline: none;
    border-color: var(--zenya-accent);
}

/* Distance slider */

.zenya-kudos-distance-setting {
    margin-top: 10px;
}

.zenya-kudos-distance-setting input[type="range"] {
    width: 100%;
    margin: 0;
    cursor: pointer;
    accent-color: var(--zenya-accent);
}

.zenya-kudos-distance-value {
    margin-top: 6px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--zenya-accent-dark);
}
/* Back buttons */

.zenya-kudos-back {
    margin: 0 0 14px;
    padding: 0;
    background: transparent;
    color: var(--zenya-accent-dark);
    border: 0;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.zenya-kudos-back:hover {
    text-decoration: underline;
}

/* ------------------------------------------------------------
   Auto Kudos - Favorite Athletes
------------------------------------------------------------ */

.zenya-kudos-favorites-search {
    margin-top: 18px;
}

.zenya-kudos-favorites-search > label {
    display: block;
    margin-bottom: 7px;
    font-weight: 600;
}

.zenya-kudos-favorites-search-row {
    display: flex;
    gap: 7px;
}

.zenya-kudos-favorites-search-row input {
    flex: 1;
    min-width: 0;
    padding: 8px 10px;
    color: var(--zenya-text);
    background: #ffffff;
    border: 1px solid var(--zenya-border);
    border-radius: 6px;
    font: inherit;
}

.zenya-kudos-favorites-search-row input:focus {
    outline: none;
    border-color: var(--zenya-accent);
}

.zenya-kudos-favorites-search-row button,
.zenya-kudos-saved-favorite button {
    padding: 7px 11px;
    color: var(--zenya-text);
    background: #ffffff;
    border: 1px solid var(--zenya-border);
    border-radius: 6px;
    font: inherit;
    font-size: 12px;
    cursor: pointer;
}

.zenya-kudos-favorites-search-row button:hover,
.zenya-kudos-saved-favorite button:hover {
    border-color: var(--zenya-accent);
}

.zenya-kudos-favorites-results {
    margin-top: 8px;
    max-height: min(360px, 40vh);
    overflow-y: auto;
    padding-right: 6px;
}

.zenya-kudos-favorite-search-result,
.zenya-kudos-saved-favorite {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 9px 10px;
    border-bottom: 1px solid var(--zenya-border);
}

.zenya-kudos-favorites-saved {
    margin-top: 20px;
}

.zenya-kudos-favorites-saved h3 {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 600;
}

.zenya-kudos-no-favorites {
    color: var(--zenya-muted);
    font-size: 13px;
}

/* ------------------------------------------------------------
   Auto Kudos - Activity Types
------------------------------------------------------------ */

.zenya-kudos-activity-types-actions {
    display: flex;
    gap: 7px;
    margin: 16px 0 14px;
}

.zenya-kudos-activity-types-actions button {
    padding: 7px 11px;
    color: var(--zenya-text);
    background: #ffffff;
    border: 1px solid var(--zenya-border);
    border-radius: 6px;
    font: inherit;
    font-size: 12px;
    cursor: pointer;
}

.zenya-kudos-activity-types-actions button:hover {
    border-color: var(--zenya-accent);
}

.zenya-kudos-activity-types-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px 12px;
    max-height: 360px;
    overflow-y: auto;
    padding-right: 6px;
}

.zenya-kudos-activity-types-list label {
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    font-size: 13px;
    line-height: 1.25;
    cursor: pointer;
}

.zenya-kudos-activity-types-list input[type="checkbox"] {
    flex: 0 0 auto;
    margin: 0;
    accent-color: var(--zenya-accent);
}

/* ------------------------------------------------------------
   Auto Kudos - Review Kudos
------------------------------------------------------------ */

.zenya-kudos-review-list {
    max-height: min(360px, 40vh);
    overflow-y: auto;

    margin: 14px 0 0;

    padding: 4px 8px;

    border: 1px solid var(--zenya-border);
    border-radius: 7px;
    background: #ffffff;
}

.zenya-kudos-review-item {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    padding: 9px 4px;
    border-bottom: 1px solid var(--zenya-border);
    cursor: pointer;
}

.zenya-kudos-review-item > input {
    flex: 0 0 auto;
    margin: 3px 0 0;
    accent-color: var(--zenya-accent);
}

.zenya-kudos-review-item-content {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.zenya-kudos-review-item-content strong {
    font-size: 13px;
    line-height: 1.3;
}

.zenya-kudos-review-item-content span {
    margin-top: 2px;
    font-size: 13px;
    line-height: 1.3;
    font-weight: 400;    /* regular */
}

.zenya-kudos-review-item-content small {
    margin-top: 3px;
    color: var(--zenya-muted);
    font-size: 11px;
    line-height: 1.3;
}

.zenya-kudos-review-item-metrics {
    margin-top: 2px;
    font-size: 13px;
    line-height: 1.3;
    font-weight: 600;
    color: var(--zenya-text);
}

.zenya-kudos-review-actions {
    display: flex;
    gap: 7px;
    margin-top: 14px;
}

.zenya-kudos-review-actions button:not(.zenya-tool-primary) {
    padding: 7px 11px;
    background: #ffffff;
    color: var(--zenya-text);
    border: 1px solid var(--zenya-border);
    border-radius: 6px;
    font: inherit;
    font-size: 12px;
    cursor: pointer;
}

.zenya-kudos-give-button {
    width: 100%;
}

.zenya-version {
    margin-top: 24px;
    font-size: 11px;
    color: var(--zenya-muted);
    text-align: center;
}

.zenya-kudos-review-item-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.zenya-kudos-review-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
}

.zenya-kudos-review-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.zenya-kudos-review-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.zenya-kudos-review-select-links {
    position: relative;
    top: -2px;

    font-size: 13px;
    white-space: nowrap;
}

.zenya-kudos-review-select-links a {
    color: var(--zenya-accent);
    text-decoration: none;
    cursor: pointer;
}

.zenya-kudos-review-select-links a:hover {
    text-decoration: underline;
}

.zenya-kudos-review-select-links span {
    margin: 0 4px;
    color: #888;
}

.zenya-auto-kudos-review {
    position: relative;
}

.zenya-kudos-busy-overlay {
    position: absolute;

    top: 0;
    left: 0;
    right: 0;
    bottom: 0;

    z-index: 500;

    background: rgba(255,255,255,0.15);

    cursor: wait;

    pointer-events: all;
}


.zenya-kudos-status {
    color: #fc4c02;
    display: inline-flex;
    align-items: center;
}

.zenya-kudos-status-icon {
    width: 14px;
    height: 14px;
}

.zenya-kudos-status-filled {
    color: #fc4c02;
}

.zenya-kudos-status-outline {
    color: inherit;
}

.zenya-kudos-setting-help {
    margin-top: 6px;
    font-size: 12px;
    line-height: 1.35;
    color: #888;
}

[data-kudos-action="start-from-filters"] {
    margin-bottom: 18px;
}

/* ==========================================================
   Zenya Status Panel
   ========================================================== */

.zenya-status-success,
.zenya-status-warning {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;

    font-weight: 600;
}

.zenya-status-success {
    color: #2e8b57;
}

.zenya-status-warning {
    color: #d39b00;
}

.zenya-status-icon {
    width: 1rem;
    height: 1rem;

    flex-shrink: 0;
}
/* ------------------------------------------------------------
   Zenya confirm dialog
   (Mounted on document.body — must not rely on #zenya-shell tokens)
------------------------------------------------------------ */

.zenya-dialog-backdrop {
  --zenya-accent: #20b2aa;
  --zenya-accent-dark: #188f89;
  --zenya-text: #25282d;
  --zenya-muted: #747980;
  --zenya-border: #dedfe1;
  --zenya-background: #ffffff;

  position: fixed;
  inset: 0;
  z-index: 2147483647;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(37, 40, 45, 0.55);
  box-sizing: border-box;
  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Helvetica,
    Arial,
    sans-serif;
}

.zenya-dialog {
  width: min(360px, 100%);
  background: #ffffff;
  color: #25282d;
  border: 1px solid #dedfe1;
  border-top: 5px solid #20b2aa;
  border-radius: 8px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
  padding: 16px 18px 14px;
}

.zenya-dialog h3 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: #25282d;
}

.zenya-dialog p {
  margin: 0 0 16px;
  font-size: 13px;
  line-height: 1.45;
  color: #5c6168;
}

.zenya-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.zenya-dialog-actions button {
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid #dedfe1;
  background: #ffffff;
  color: #25282d;
}

.zenya-dialog-actions button:hover {
  border-color: #20b2aa;
}

.zenya-dialog-actions .zenya-dialog-confirm {
  background: #20b2aa;
  border-color: #20b2aa;
  color: #ffffff;
}

.zenya-dialog-actions .zenya-dialog-confirm:hover {
  background: #188f89;
  border-color: #188f89;
}

/* ------------------------------------------------------------
   Following picker checkboxes (teal + white check)
------------------------------------------------------------ */

.zenya-kudos-following-picker-list {
  max-height: 220px;
  overflow: auto;
  border: 1px solid var(--zenya-border);
  border-radius: 6px;
  padding: 4px 0;
}

.zenya-kudos-following-picker-list label.zenya-kudos-favorite-search-result {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px;
  cursor: pointer;
  margin: 0;
}

.zenya-kudos-following-picker-list input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  margin: 0;
  flex-shrink: 0;
  border: 2px solid var(--zenya-border);
  border-radius: 4px;
  background: var(--zenya-background);
  cursor: pointer;
  position: relative;
  box-sizing: border-box;
}

.zenya-kudos-following-picker-list input[type="checkbox"]:hover:not(:disabled) {
  border-color: var(--zenya-accent);
}

.zenya-kudos-following-picker-list input[type="checkbox"]:checked {
  background: var(--zenya-accent);
  border-color: var(--zenya-accent);
}

.zenya-kudos-following-picker-list input[type="checkbox"]:checked::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 4px;
  height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.zenya-kudos-following-picker-list input[type="checkbox"]:disabled {
  opacity: 0.7;
  cursor: default;
}

.zenya-kudos-following-picker-list input[type="checkbox"]:disabled:checked {
  background: var(--zenya-accent);
  border-color: var(--zenya-accent);
}

/* Group members saved list — scroll window */
.zenya-kudos-group-members-content {
  max-height: 240px;
  overflow: auto;
  border: 1px solid var(--zenya-border);
  border-radius: 6px;
  padding: 4px 0;
}

.zenya-kudos-group-members-content .zenya-kudos-saved-favorite {
  padding-left: 10px;
  padding-right: 10px;
}

.zenya-kudos-group-members-content .zenya-kudos-no-favorites {
  padding: 10px 12px;
  margin: 0;
}
