/* Library Display Styles for Soundpaste Plugin */

/* Tab styling */
.nav-tab-wrapper {
  margin-bottom: 15px;
}

.tab-content {
  margin-top: 15px;
}

.tab-panel {
  display: block;
}

/* Compact audio player styles */
.compact-audio-player {
  position: relative;
  width: 40px;
  height: 40px;
  margin: 0;
  display: inline-block;
}

.compact-audio-player audio {
  position: absolute;
  opacity: 0;
  width: 40px;
  height: 40px;
  z-index: 2;
  cursor: pointer;
}

.play-button {
  position: absolute;
  width: 36px;
  height: 36px;
  background-color: #0073aa;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1;
  color: white;
  font-size: 18px;
}

.audio-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.audio-meta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.active-label {
  display: inline-block;
  background-color: #0073aa;
  color: white;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 11px;
}

.branding-indicator {
  font-size: 12px;
}

/* Bulk actions styling */
.tablenav {
  clear: both;
  margin: 6px 0 4px;
}

.tablenav .actions {
  padding: 0 8px 0 0;
}

.tablenav .actions select {
  margin-right: 6px;
}

.wp-list-table .check-column {
  width: 2.2em;
  padding: 8px 0 8px 8px;
  vertical-align: top;
}

.wp-list-table tbody th.check-column {
  padding: 11px 0 0 3px;
}

.wp-list-table thead td.check-column,
.wp-list-table tfoot td.check-column {
  padding: 10px 0 0 3px;
}

/* Podcast-specific styles */
.podcast-script-preview {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.podcast-script-full {
  display: none;
  max-height: 200px;
  overflow-y: auto;
  background: #f9f9f9;
  padding: 10px;
  border: 1px solid #ddd;
  margin-top: 5px;
}

.podcast-voices {
  font-size: 12px;
  color: #666;
}

/* Filters styling */
.soundpaste-filters-wrap {
  margin: 15px 0;
  background: #fff;
  border: 1px solid #ccd0d4;
  padding: 10px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
}

.soundpaste-filters-wrap h2 {
  margin-top: 0;
}

.soundpaste-filters-wrap form {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  align-items: flex-end;
}

.soundpaste-filters-wrap select {
  min-width: 150px;
}

.soundpaste-filters-wrap select#post_id {
  min-width: 200px;
}

.soundpaste-filters-wrap .filter-actions {
  display: flex;
  gap: 5px;
}

.soundpaste-filters-wrap .tablenav .actions p {
  margin: 0;
}

/* Voice selector table styling */
.voice-selector-container {
  margin-top: 20px;
  max-width: 100%;
  overflow-x: auto;
}

.voice-selector-table .column-selection {
  width: 40px;
}

.voice-selector-table .column-preview {
  width: 120px;
  text-align: center;
}

.voice-selector-table .column-name {
  width: 200px;
  font-weight: bold;
}

.voice-selector-table .column-provider {
  width: 100px;
}

.voice-selector-table .column-description {
  width: 400px;
}

.voice-selector-table .column-language {
  width: 120px;
}

.voice-selector-table .column-rating {
  width: 150px;
}

.voice-selector-table .column-note {
  width: 200px;
}

/* Voice audio player styling */
.voice-audio-player {
  display: flex;
  align-items: center;
  justify-content: center;
}

.voice-audio-player audio {
  width: 100px;
  height: 30px;
}

.no-preview {
  font-style: italic;
  color: #666;
  font-size: 12px;
}

/* Star Rating Styling */
.star-rating {
  direction: rtl;
  display: inline-block;
  padding: 0;
}

.star-rating input[type="radio"] {
  display: none;
}

.star-rating label {
  color: #bbb;
  font-size: 1.5em;
  padding: 0;
  cursor: pointer;
  transition: all 0.3s ease;
}

.star-rating label:hover,
.star-rating label:hover ~ label,
.star-rating input[type="radio"]:checked ~ label {
  color: #f8c740;
}

/* Provider icons */
.provider-icon {
  font-weight: bold;
}

.provider-elevenlabs {
  color: #5a67d8;
}

.provider-soundpaste {
  color: #28a745;
  font-weight: bold;
}

/* Filter styling */
.soundpaste-filters-wrap {
  margin: 15px 0;
  background: #fff;
  border: 1px solid #ccd0d4;
  padding: 10px;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
}

.soundpaste-filters-title {
  margin-top: 0;
}

.soundpaste-filters-form {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  align-items: flex-end;
}

.soundpaste-filter-select {
  min-width: 150px;
}

.soundpaste-filter-select-wide {
  min-width: 200px;
}

.soundpaste-filter-buttons {
  display: flex;
  gap: 5px;
}

.soundpaste-total-info {
  margin: 0;
}

/* Star icons */
.soundpaste-star-active {
  color: #0073aa;
}

.soundpaste-star-inactive {
  color: #ccc;
}

/* Notice styling */
.soundpaste-info-notice {
  margin-top: 20px;
}

/* Audio meta */
.soundpaste-audio-meta {
  margin-top: 5px;
}

/* Script toggle links */
.soundpaste-toggle-link {
  color: #0073aa;
  cursor: pointer;
}

.soundpaste-script-controls {
  margin-top: 5px;
}

/* Status styling */
.soundpaste-status-processing {
  color: #f56e28;
}

.soundpaste-status-inactive {
  color: #666;
}

/* Voice refresh controls */
.voice-refresh-container {
  margin-bottom: 15px;
}

.soundpaste-refresh-icon {
  margin-top: 3px;
  margin-right: 5px;
}

.soundpaste-refresh-status {
  margin-left: 10px;
  font-style: italic;
}

.soundpaste-submit-spacing {
  margin-bottom: 15px;
}

/* Refresh button animation */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.dashicons-update-spin {
  animation: spin 1.5s linear infinite;
}
