/* UI jasnoća: ujednačena potvrda, odsustva, Ask oblačić i izbor prikaza. */
.settings-category-content[hidden] {
  display: none !important;
}

#results .dashboard-grid :is(.satisfied-gauge, .reset-complete-check, .check-mark) {
  align-items: center !important;
  background: color-mix(in srgb, #b6ead0 28%, transparent) !important;
  border: 5px solid #8edbb5 !important;
  border-radius: 50% !important;
  box-sizing: border-box !important;
  color: #54c58d !important;
  display: flex !important;
  font: 800 42px/1 system-ui, sans-serif !important;
  height: 70px !important;
  justify-content: center !important;
  margin: 0 auto !important;
  position: static !important;
  transform: none !important;
  width: 70px !important;
}

.paid-leave-form {
  align-items: end;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.paid-leave-form > .paid-leave-type,
.paid-leave-form > label:nth-of-type(4),
.paid-leave-form > label:nth-of-type(5) {
  grid-column: span 2;
}

.paid-leave-form :is(input, select) {
  background: var(--theme-field, #fff);
  border: 1px solid var(--theme-border, #c9d8e3);
  border-radius: 12px;
  box-sizing: border-box;
  color: var(--theme-text, #142230);
  font: 750 .9rem/1.2 system-ui, sans-serif;
  min-height: 44px;
  min-width: 0;
  padding: 9px 11px;
  width: 100%;
}

.paid-leave-form .paid-leave-actions {
  grid-column: 1 / -1;
  justify-content: flex-end;
}

.paid-leave-item > div:first-child {
  min-width: 0;
}

.paid-leave-item > div:first-child span {
  overflow-wrap: anywhere;
}

.guided-ask-conversation,
[data-panel="ask_tachoduck"] #askConversation {
  display: none !important;
}

.ask-answer-bubble {
  align-items: start;
  animation: ask-answer-bubble-in .2s ease-out both;
  background: var(--theme-surface, #fff);
  border: 2px solid color-mix(in srgb, #159ddd 45%, var(--theme-border, #c9d8e3));
  border-radius: 22px 22px 5px 22px;
  bottom: 20px;
  box-shadow: 0 20px 55px color-mix(in srgb, #061725 30%, transparent);
  display: grid;
  gap: 12px;
  grid-template-columns: 74px minmax(0, 1fr);
  padding: 16px;
  position: fixed;
  right: 20px;
  width: min(480px, calc(100vw - 28px));
  z-index: 10040;
}

.ask-answer-bubble[hidden] {
  display: none !important;
}

.ask-answer-bubble::after {
  border-left: 14px solid transparent;
  border-top: 14px solid color-mix(in srgb, #159ddd 45%, var(--theme-border, #c9d8e3));
  bottom: -14px;
  content: "";
  position: absolute;
  right: 18px;
}

.ask-answer-bubble-duck {
  align-items: center;
  background: #fff;
  border: 1px solid color-mix(in srgb, #159ddd 22%, #fff);
  border-radius: 18px;
  display: flex;
  height: 72px;
  justify-content: center;
  overflow: hidden;
  width: 72px;
}

.ask-answer-bubble-duck img {
  height: 66px;
  object-fit: contain;
  width: 66px;
}

.ask-answer-bubble-copy {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding-right: 24px;
}

.ask-answer-bubble-copy > strong {
  color: #087fc4;
  font-size: 1rem;
}

.ask-answer-bubble-copy p {
  color: var(--theme-text, #142230);
  font-size: .9rem;
  font-weight: 650;
  line-height: 1.45;
  margin: 0;
  max-height: min(42vh, 280px);
  overflow: auto;
  overflow-wrap: anywhere;
}

.ask-answer-bubble-x,
.ask-answer-bubble-close {
  cursor: pointer;
}

.ask-answer-bubble-x {
  background: transparent;
  border: 0;
  border-radius: 9px;
  color: var(--theme-muted, #627487);
  font: 500 1.45rem/1 system-ui, sans-serif;
  height: 36px;
  position: absolute;
  right: 8px;
  top: 8px;
  width: 36px;
}

.ask-answer-bubble-close {
  background: linear-gradient(135deg, #159bdc, #0879bd);
  border: 0;
  border-radius: 11px;
  color: #fff;
  font: 850 .8rem/1 system-ui, sans-serif;
  justify-self: start;
  min-height: 38px;
  padding: 9px 18px;
}

.ask-answer-bubble.is-error {
  border-color: #e55a68;
}

@keyframes ask-answer-bubble-in {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.activity-view-switch {
  background: transparent;
  border: 0;
  padding: 0;
}

.activity-view-switch-buttons {
  background: transparent;
  gap: 10px;
  padding: 0;
}

.activity-view-switch-buttons button {
  background: var(--theme-field, #fff);
  border: 2px solid color-mix(in srgb, #159ddd 35%, var(--theme-border, #c9d8e3));
  border-radius: 13px;
  color: #087fc4;
  min-height: 46px;
}

.activity-view-switch-buttons button.active,
.activity-view-switch-buttons button[aria-pressed="true"] {
  background: linear-gradient(135deg, #159bdc, #0879bd);
  border-color: #0879bd;
  box-shadow: 0 7px 18px color-mix(in srgb, #087fc4 26%, transparent);
  color: #fff;
}

.activity-view-switch-buttons button[aria-pressed="true"]::before {
  content: "✓ ";
}

@media (max-width: 720px) {
  #results .dashboard-grid :is(.satisfied-gauge, .reset-complete-check, .check-mark) {
    border-width: 4px !important;
    font-size: 32px !important;
    height: 54px !important;
    width: 54px !important;
  }

  .paid-leave-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .paid-leave-form > .paid-leave-type {
    grid-column: 1 / -1;
  }

  .ask-answer-bubble {
    bottom: 14px;
    grid-template-columns: 62px minmax(0, 1fr);
    left: 14px;
    padding: 13px;
    right: 14px;
    width: auto;
  }

  html[data-command-bar-position="bottom"] .ask-answer-bubble {
    bottom: calc(var(--persistent-command-bar-height, 58px) + 12px);
  }

  .ask-answer-bubble-duck {
    height: 60px;
    width: 60px;
  }

  .ask-answer-bubble-duck img {
    height: 56px;
    width: 56px;
  }
}

@media (max-width: 480px) {
  .paid-leave-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .paid-leave-form > :is(.paid-leave-type, label:nth-of-type(4), label:nth-of-type(5)),
  .paid-leave-form .paid-leave-actions {
    grid-column: 1;
  }

  .paid-leave-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .activity-view-switch-buttons {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .activity-view-switch-buttons button {
    padding-inline: 6px;
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ask-answer-bubble {
    animation: none;
  }
}
