/* ==========================================================================
   UPLOAD PAGE — upload-specific styles only
   Shared base look (nav, buttons, inputs, #app) lives in base.css
   ========================================================================== */

/* The upload tab is a narrow centred card (this used to be the whole page's
   width, before the pages were merged into tabs — so it's scoped now). */
#view-upload {
    max-width: 560px;
    margin: 0 auto;
}

/* Form card */
#upload-form {
    background: #1e1e1e;
    padding: 30px;
    border-radius: 16px;
    border: 1px solid #2a2a2a;
    margin-bottom: 20px;
}

#upload-form .form-group {
    margin-bottom: 24px;
}

/* ---------- Song info lookup ---------- */
.lookup-group {
    background: #181818;
    padding: 16px;
    border-radius: 12px;
    border: 1px solid #2c2c2c;
}
.lookup-search-row {
    display: flex;
    gap: 8px;
}
.lookup-search-row input[type="text"] {
    flex: 1;
}
.lookup-search-row button {
    width: auto;
    padding: 0 20px;
    font-size: 0.9rem;
    border-radius: 8px;
    flex-shrink: 0;
}
.lookup-status {
    font-size: 0.85rem;
    color: #b3b3b3;
    margin-top: 10px;
}
.lookup-status:empty {
    margin-top: 0;
}
.lookup-results {
    max-height: 260px;
    overflow-y: auto;
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.lookup-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #242424;
    border: 1px solid #333;
    border-radius: 8px;
    padding: 8px 10px;
    cursor: pointer;
    text-align: left;
    width: 100%;
    font-weight: normal;
    font-size: 1rem;
}
.lookup-result-item:hover {
    background: #2e2e2e;
    border-color: var(--accent);
}
.lookup-result-art {
    width: 44px;
    height: 44px;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
    background: #333;
}
.lookup-result-text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.lookup-result-title {
    font-size: 0.9rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.lookup-result-artist {
    font-size: 0.78rem;
    color: #b3b3b3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ---------- Field hint + cover preview ---------- */
.field-hint {
    font-size: 0.78rem;
    color: #888;
    margin: 8px 0 0 0;
}
.cover-preview-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    background: #1a1a1a;
    border: 1px solid #2c2c2c;
    border-radius: 8px;
    padding: 8px 10px;
}
.cover-preview-wrap img {
    width: 44px;
    height: 44px;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
}
.cover-preview-wrap span {
    flex: 1;
    font-size: 0.82rem;
    color: #ccc;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Submit button fills the card width */
#submit-btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
}
#submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #1a8c3e;
}

.lookup-status .icon,
#status-message .icon {
    vertical-align: -3px;
}

/* Status message (hidden until it has content) */
#status-message {
    margin-top: 20px;
    font-weight: 600;
    text-align: center;
    padding: 14px;
    border-radius: 10px;
    background: #1e1e1e;
    border: 1px solid #333;
    color: #b3b3b3;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}
#status-message:not(:empty) {
    opacity: 1;
    visibility: visible;
}

/* Mobile tweaks */
@media (max-width: 768px) {
    #upload-form {
        padding: 20px;
    }
}
