/* Scoped styles for music-metadata-and-discography-lookup (prefix: mmdl-) */

.mmdl-container {
  max-width: 1040px;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem 1rem;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--text, #1f2937);
}

.mmdl-hero {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.75rem 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.mmdl-pill-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #0284c7;
  background-color: #e0f2fe;
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
  margin-bottom: 0.75rem;
}

.mmdl-title {
  font-size: 2rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 0.5rem 0;
  line-height: 1.25;
}

.mmdl-subtitle {
  font-size: 1rem;
  color: #64748b;
  margin: 0;
  line-height: 1.5;
  max-width: 820px;
}

/* Nav Tabs */
.mmdl-nav-tabs {
  display: flex;
  gap: 0.5rem;
  border-bottom: 2px solid #e2e8f0;
  margin-bottom: 1.5rem;
  overflow-x: auto;
}

.mmdl-tab-btn {
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 0.75rem 1.25rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s;
  margin-bottom: -2px;
}

.mmdl-tab-btn:hover {
  color: #0f172a;
}

.mmdl-tab-active {
  color: #0284c7;
  border-bottom-color: #0284c7;
}

.mmdl-tab-panel {
  display: none;
}

.mmdl-panel-active {
  display: block;
}

/* Panel Card */
.mmdl-card-panel {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 2rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.mmdl-section-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.35rem 0;
}

.mmdl-text-muted {
  font-size: 0.9rem;
  color: #64748b;
  margin: 0 0 1.25rem 0;
  line-height: 1.45;
}

/* Directory Header */
.mmdl-dir-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mmdl-count-badge {
  font-size: 0.825rem;
  font-weight: 600;
  color: #475569;
  background-color: #f1f5f9;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
}

.mmdl-filter-bar {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
  .mmdl-filter-bar {
    grid-template-columns: 1fr;
  }
}

.mmdl-form-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.mmdl-search-field {
  flex-grow: 1;
}

.mmdl-lbl {
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
}

.mmdl-input, .mmdl-select {
  font-size: 0.95rem;
  padding: 0.6rem 0.85rem;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  background-color: #ffffff;
  color: #0f172a;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.mmdl-input:focus, .mmdl-select:focus {
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

/* Cards Grid */
.mmdl-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1.25rem;
}

.mmdl-card {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s, box-shadow 0.15s;
}

.mmdl-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
  border-color: #7dd3fc;
}

.mmdl-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.mmdl-artist-name {
  font-size: 1.15rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.25rem 0;
  line-height: 1.3;
}

.mmdl-mbid-text {
  font-size: 0.75rem;
  color: #64748b;
}

.mmdl-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  background-color: #f1f5f9;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  color: #0f172a;
  font-size: 0.72rem;
}

.mmdl-badge-group {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
}

.mmdl-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  white-space: nowrap;
}

.mmdl-badge-type {
  background-color: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
}

.mmdl-badge-genre {
  background-color: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
}

.mmdl-meta-line {
  font-size: 0.825rem;
  color: #64748b;
  margin-bottom: 0.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.mmdl-bio {
  font-size: 0.875rem;
  color: #475569;
  line-height: 1.45;
  margin: 0 0 0.85rem 0;
  flex-grow: 1;
}

.mmdl-releases-preview {
  background-color: #f8fafc;
  border: 1px solid #edf2f7;
  border-radius: 6px;
  padding: 0.65rem 0.85rem;
  margin-bottom: 1rem;
}

.mmdl-preview-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #475569;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

.mmdl-release-list {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 0.8rem;
  color: #334155;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.mmdl-card-footer {
  padding-top: 0.75rem;
  border-top: 1px solid #f1f5f9;
}

.mmdl-view-btn {
  width: 100%;
}

.mmdl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.6rem 1.15rem;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.mmdl-btn-primary {
  background-color: #0284c7;
  color: #ffffff;
}

.mmdl-btn-primary:hover {
  background-color: #0369a1;
}

.mmdl-btn-secondary {
  background-color: #f8fafc;
  border-color: #cbd5e1;
  color: #334155;
}

.mmdl-btn-secondary:hover {
  background-color: #f1f5f9;
  color: #0f172a;
}

.mmdl-no-results {
  text-align: center;
  padding: 3rem 1rem;
  background-color: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  color: #64748b;
}

/* Live Search Box */
.mmdl-live-search-box {
  max-width: 600px;
  margin-bottom: 1.5rem;
}

.mmdl-search-input-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.mmdl-search-input-row input {
  flex-grow: 1;
}

.mmdl-api-status {
  padding: 0.85rem 1rem;
  border-radius: 6px;
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
}

.mmdl-status-loading {
  background-color: #eff6ff;
  color: #1e40af;
  border: 1px solid #bfdbfe;
}

.mmdl-status-error {
  background-color: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.mmdl-api-results-container {
  background-color: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.25rem;
}

.mmdl-subheading {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 1rem 0;
}

.mmdl-api-results-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mmdl-api-result-item {
  background-color: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.mmdl-item-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.2rem 0;
}

.mmdl-item-meta {
  font-size: 0.85rem;
  color: #64748b;
}

/* Guide Grid */
.mmdl-guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.mmdl-guide-box {
  background-color: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 1.25rem;
}

.mmdl-guide-box-title {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem 0;
}

.mmdl-guide-box p {
  font-size: 0.85rem;
  color: #475569;
  line-height: 1.5;
  margin: 0;
}

/* Table in Modal */
.mmdl-table-wrap {
  overflow-x: auto;
  margin-top: 1rem;
}

.mmdl-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  text-align: left;
}

.mmdl-table th {
  background-color: #f8fafc;
  padding: 0.65rem 0.85rem;
  border-bottom: 2px solid #e2e8f0;
  font-weight: 600;
  color: #475569;
}

.mmdl-table td {
  padding: 0.65rem 0.85rem;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
}

/* Modal View */
.mmdl-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(15, 23, 42, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
  backdrop-filter: blur(2px);
}

.mmdl-modal-content {
  background-color: #ffffff;
  border-radius: 12px;
  max-width: 680px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
  overflow: hidden;
}

.mmdl-modal-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  background-color: #f8fafc;
}

.mmdl-modal-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.25rem 0;
}

.mmdl-modal-subtitle {
  font-size: 0.9rem;
  color: #64748b;
}

.mmdl-modal-close {
  background: transparent;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  color: #94a3b8;
  cursor: pointer;
  padding: 0.25rem;
}

.mmdl-modal-close:hover {
  color: #0f172a;
}

.mmdl-modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  font-size: 0.925rem;
  line-height: 1.55;
  color: #334155;
}

.mmdl-modal-footer {
  padding: 1rem 1.5rem;
  border-top: 1px solid #e2e8f0;
  background-color: #f8fafc;
  display: flex;
  justify-content: flex-end;
}

.mmdl-modal-open {
  overflow: hidden;
}

/* Ad Slot */
.mmdl-ad-slot {
  min-height: 280px;
  margin: 2rem 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f9fafb;
  border: 1px dashed #e5e7eb;
  border-radius: 8px;
}

/* Disclaimer */
.mmdl-disclaimer {
  background-color: #f0f9ff;
  border-left: 4px solid #0284c7;
  padding: 1rem 1.25rem;
  border-radius: 6px;
  margin: 2rem 0;
}

.mmdl-disclaimer-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0369a1;
  margin-bottom: 0.35rem;
}

.mmdl-disclaimer-text {
  font-size: 0.85rem;
  color: #075985;
  margin: 0;
  line-height: 1.5;
}
