/* Components layer: UI modules (clock, modal, login float). */

/* Breath clock + settings modal */
.breathclock {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  user-select: none;
  -webkit-user-select: none;
  font-family: Monaco, "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono",
    "Courier New", monospace;
  color: #334155;
  --breathclock-color: #10b981;
}

.breathclock__panel {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  box-shadow: none;
  overflow: hidden;
  cursor: default;
}

.breathclock__dot {
  position: relative;
  display: flex;
  height: 8px;
  width: 8px;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
  flex: 0 0 auto;
}

.breathclock__dot:focus-visible {
  outline: 2px solid rgba(16, 185, 129, 0.55);
  outline-offset: 3px;
}

@keyframes breathclock-ping {
  75%,
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

.breathclock__dot-ring {
  position: absolute;
  inset: 0;
  display: inline-flex;
  height: 100%;
  width: 100%;
  border-radius: 999px;
  background: var(--breathclock-color);
  opacity: 0.55;
  animation: breathclock-ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;
}

.breathclock__dot-core {
  position: relative;
  display: inline-flex;
  height: 8px;
  width: 8px;
  border-radius: 999px;
  background: var(--breathclock-color);
}

.breathclock__panel {
  cursor: pointer;
}


/* Settings modal */
.picker-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(231, 231, 231, 0.6);
  backdrop-filter: blur(10px);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 10000;
  opacity: 1;
}

.picker-modal.active {
  display: flex;
}

.picker-card {
  background: #f0f2f5;
  width: 95%;
  max-width: 400px;
  padding: 1.2rem;
  border-radius: 40px;
  box-shadow: 8px 8px 16px #d1d9e6, -8px -8px 16px #ffffff;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-height: 95vh;
  overflow-y: auto;
}

.picker-card::-webkit-scrollbar {
  width: 0;
}

.color-board {
  width: 100%;
  height: 160px;
  border-radius: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: inset 4px 4px 8px #d1d9e6, inset -4px -4px 8px #ffffff;
  cursor: crosshair;
  touch-action: none;
}

.board-hue {
  width: 100%;
  height: 100%;
  position: absolute;
}

.board-saturation {
  width: 100%;
  height: 100%;
  position: absolute;
  background: linear-gradient(to right, #fff, transparent);
}

.board-brightness {
  width: 100%;
  height: 100%;
  position: absolute;
  background: linear-gradient(to top, #000, transparent);
}

.picker-thumb {
  width: 24px;
  height: 24px;
  background: #fff;
  border-radius: 41% 59% 45% 55% / 58% 44% 56% 42%;
  position: absolute;
  box-shadow: inset 3px 3px 6px rgba(0, 0, 0, 0.2),
    inset -3px -3px 6px rgba(255, 255, 255, 0.4),
    2px 2px 4px rgba(255, 255, 255, 0.5);
  border: 2px solid #fff;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 10;
}

.modal-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.preview-circle {
  width: 48px;
  height: 48px;
  background-color: var(--breath-color, #3b82f6);
  border-radius: 41% 59% 45% 55% / 58% 44% 56% 42%;
  box-shadow: inset 3px 3px 6px rgba(0, 0, 0, 0.2),
    inset -3px -3px 6px rgba(255, 255, 255, 0.4),
    2px 2px 4px rgba(255, 255, 255, 0.5);
  flex-shrink: 0;
  transition: background-color 0.1s;
}

.clay-input-group {
  flex-grow: 1;
  height: 48px;
  background: #f0f2f5;
  box-shadow: inset 4px 4px 8px #d1d9e6, inset -4px -4px 8px #ffffff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  padding: 0 12px;
}

.clay-input-hash {
  font-weight: bold;
  color: #9ca3af;
  margin-right: 4px;
}

.clay-input {
  background: transparent;
  border: none;
  outline: none;
  width: 100%;
  font-family: monospace;
  font-size: 0.95rem;
  color: #4b5563;
  text-transform: uppercase;
}

.btn-done {
  height: 48px;
  padding: 0 25px;
  border-radius: 12px;
  border: none;
  background: #f0f2f5;
  box-shadow: 8px 8px 16px #d1d9e6, -8px -8px 16px #ffffff;
  font-weight: bold;
  color: var(--breath-color, #3b82f6);
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-done:active {
  box-shadow: inset 4px 4px 8px #d1d9e6, inset -4px -4px 8px #ffffff;
  transform: scale(0.95);
}

.presets-container {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  justify-items: center;
}

.preset-item {
  width: 48px;
  height: 48px;
  border: 2px solid #fff;
  cursor: pointer;
  background-color: var(--color);
  border-radius: 41% 59% 45% 55% / 58% 44% 56% 42%;
  box-shadow: inset 3px 3px 6px rgba(0, 0, 0, 0.2),
    inset -3px -3px 6px rgba(255, 255, 255, 0.4),
    2px 2px 4px rgba(255, 255, 255, 0.5);
  transition: background-color 0.1s, transform 0.2s;
}

.preset-item:hover {
  transform: scale(1.1) rotate(5deg);
}

.clay-divider {
  width: 100%;
  padding-top: 10px;
  border-top: 2px dashed rgba(160, 160, 160, 0.2);
  margin-top: 5px;
  box-sizing: border-box;
}

.picker-card .breathclock__panel {
  -webkit-user-select: none;
  font-family: Monaco, "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", "Courier New", monospace;
  color: #334155;
  box-sizing: border-box;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 12px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  box-shadow: none;
  overflow: hidden;
  cursor: pointer;
  margin: 6px 0;
}

.picker-card .breathclock__btn {
  background: none;
  border: 0;
  padding: 0;
  font-family: inherit;
  color: inherit;
  cursor: pointer;
  text-align: left;
  display: block;
  line-height: 1.1;
}

.preview-time {
  font-size: 12px;
  font-weight: 700;
  color: #0f172a;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.preview-date {
  font-size: 11px;
  font-weight: 500;
  color: rgba(148, 163, 184, 1);
}

.config-options {
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: rgba(0, 0, 0, 0.02);
  padding: 14px;
  border-radius: 22px;
  box-shadow: inset 1px 1px 3px rgba(0, 0, 0, 0.05);
}

.option-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  font-weight: 600;
  color: #64748b;
}

.clay-switch {
  width: 44px;
  height: 22px;
  background: #f0f2f5;
  box-shadow: inset 4px 4px 8px #d1d9e6, inset -4px -4px 8px #ffffff;
  border-radius: 11px;
  position: relative;
  cursor: pointer;
  transition: all 0.3s ease;
}

.clay-switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 18px;
  height: 18px;
  background: #fff;
  border-radius: 41% 59% 45% 55% / 58% 44% 56% 42%;
  box-shadow: inset 3px 3px 6px rgba(0, 0, 0, 0.2),
    inset -3px -3px 6px rgba(255, 255, 255, 0.4),
    2px 2px 4px rgba(255, 255, 255, 0.5);
  transition: 0.3s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}

.clay-switch.active::after {
  left: 24px;
  background: var(--breath-color, #3b82f6);
}

.clay-select,
.clay-date-input {
  background: #f0f2f5;
  box-shadow: inset 4px 4px 8px #d1d9e6, inset -4px -4px 8px #ffffff;
  border: none;
  padding: 6px 10px;
  border-radius: 10px;
  outline: none;
  font-size: 0.8rem;
  color: #4b5563;
}

#countdown-detail {
  display: none;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

#countdown-detail.visible {
  display: flex;
}

.picker-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: #f0f2f5;
  box-shadow: 8px 8px 16px #d1d9e6, -8px -8px 16px #ffffff;
  font-weight: 700;
  color: #6b7280;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.breathclock__content {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.breathclock__btn {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  color: inherit;
  cursor: pointer;
  font: inherit;
  line-height: 1.1;
}

.breathclock__btn:active {
  transform: scale(0.99);
}

.breathclock__time {
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.breathclock__time:hover {
  color: #16a34a;
}

.breathclock__date {
  font-size: 11px;
  font-weight: 500;
  color: rgba(148, 163, 184, 1);
  transition: color 0.2s ease;
}

.breathclock__date:hover {
  color: rgba(100, 116, 139, 1);
}

@media (max-width: 640px) {
  .breathclock {
    top: 10px;
    right: 10px;
  }
  .breathclock__date {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .breathclock__dot-ring {
    animation: none !important;
  }
}


/* Login float */
.login-float {
  position: fixed;
  left: 40px;
  bottom: 16px;
  z-index: 9999;
  gap: 10px;
  padding: 6px 8px;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

@media (min-width: 1260px) {
  .login-float {
    left: 64px;
  }
}

.login-float.is-hidden {
  opacity: 0;
}

.login-float .team-avatars {
  display: flex;
  align-items: center;
  gap: 6px;
}

.login-float .avatarlinkblock,
.login-float .image-114,
.login-float .you-link {
  position: relative;
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  border-radius: 999px;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.login-float .avatarlinkblock .image-42,
.login-float .image-114,
.login-float .image-115 {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.login-float .avatarborder {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 999px;
  pointer-events: none;
}

.login-float .avatarblackoverlay,
.login-float .image-43,
.login-float .text-block-16 {
  display: none;
}

.login-float .you-link__icon {
  position: relative;
  width: 72px;
  height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 10px;
  align-self: center;
  transform: translate(-10px, -6px);
}

.login-float .you-link__icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

@media (min-width: 1536px) {
  .login-float .avatarlinkblock,
  .login-float .image-114,
  .login-float .you-link {
    width: 32px;
    height: 32px;
  }
}
  
