/* "Custom" feed: the "+" add panel, and the add_verse_modal form. Kept
   entirely separate from style.css so the existing feeds/screens are
   untouched by this feature. */

.custom-add-panel {
  margin-top: 20px;
  cursor: pointer;
}

.custom-add-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  line-height: 1;
}

/* .info-share has an explicit display:flex in style.css, which otherwise
   beats the browser's default [hidden]{display:none} (equal specificity,
   author CSS always wins over the UA stylesheet regardless of source
   order) -- so this needs !important to actually hide it. */
.info-share[hidden] {
  display: none !important;
}

/* Favourite/unfavourite heart inside the add_verse_modal, top-left --
   shown only in edit mode (see openEditModal). Mirrors .player-modal-heart
   in style.css for visual consistency, since it's the same underlying
   offlineStore favouriting mechanism, just toggled from here instead of
   play_modal_overview (which shows only the edit pencil for a custom
   track, no heart -- see .info-share[hidden] comment above for the
   [hidden]-vs-author-CSS caveat; not needed here since this button has no
   conflicting display rule of its own). */
.custom-edit-heart {
  position: absolute;
  top: 0.75rem;
  left: 0.8rem;
  width: 28px;
  height: 28px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.custom-edit-heart svg {
  width: 20px;
  height: 20px;
}

.custom-edit-heart:hover {
  color: var(--text);
}

.custom-edit-heart.active {
  color: #e0245e;
}

.custom-edit-heart:disabled {
  opacity: 0.5;
  cursor: default;
}

.custom-edit-heart.hidden {
  display: none;
}

/* add_verse_modal */
.custom-add-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-top: 0.5rem;
  text-align: left;
}

.custom-field.hidden {
  display: none;
}

.custom-field label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.custom-field-subtext {
  margin: 0 0 0.4rem;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.custom-field input {
  width: 100%;
  box-sizing: border-box;
  background: var(--bg);
  border: 1px solid rgba(255,255,255,0.14);
  color: var(--text);
  font: inherit;
  padding: 0.55rem 0.7rem;
  border-radius: 8px;
}

.custom-field input:focus {
  outline: none;
  border-color: var(--accent);
}

.custom-field-error {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  color: #e0245e;
}

.custom-field-error.hidden {
  display: none;
}

.custom-field-confirm {
  margin-top: 0.6rem;
  border: none;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 600;
  padding: 0.5rem 1.2rem;
  border-radius: 999px;
  cursor: pointer;
}

.custom-field-confirm:disabled {
  opacity: 0.6;
  cursor: default;
}

.custom-field-confirm.hidden {
  display: none;
}

.custom-add-submit {
  border: none;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 700;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  cursor: pointer;
}

.custom-add-submit:disabled {
  opacity: 0.6;
  cursor: default;
}

.custom-add-submit.hidden {
  display: none;
}

.custom-add-delete {
  border: none;
  background: none;
  color: #e0245e;
  font: inherit;
  font-weight: 600;
  padding: 0.5rem;
  cursor: pointer;
  text-align: center;
}

.custom-add-delete:hover {
  text-decoration: underline;
}

.custom-add-delete:disabled {
  opacity: 0.6;
  cursor: default;
  text-decoration: none;
}

.custom-add-delete.hidden {
  display: none;
}

.custom-add-status {
  margin: 0.8rem 0 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
}

.custom-add-status.error {
  color: #e0245e;
}

.custom-add-status.hidden {
  display: none;
}

/* Toast */
.custom-toast {
  position: fixed;
  left: 50%;
  bottom: 1.5rem;
  transform: translate(-50%, 0);
  max-width: calc(100vw - 2rem);
  background: var(--card-bg);
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.14);
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  font-size: 0.9rem;
  text-align: center;
  z-index: 2000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.custom-toast.visible {
  opacity: 1;
  transform: translate(-50%, -0.4rem);
}
