/* ORMSY Catalog Builder Frontend */
.ormsy-catalog-builder {
    max-width: 800px;
    margin: 20px auto;
    font-family: inherit;
}

/* Title & Description */
.ormsy-cb-title {
    font-size: 26px;
    font-weight: 700;
    color: #333;
    margin: 0 0 8px;
    text-align: center;
}
.ormsy-cb-desc {
    font-size: 15px;
    color: #666;
    margin: 0 0 24px;
    text-align: center;
}

/* Sections */
.ormsy-cb-section {
    margin-bottom: 24px;
}
.ormsy-cb-section-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #8B6F47;
    margin: 0 0 10px;
    padding-bottom: 6px;
    border-bottom: 1px solid #e8e0d6;
}

/* =========================================
   Artist Cards
   ========================================= */
.ormsy-artist-cards {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 8px;
    -webkit-overflow-scrolling: touch;
}
.ormsy-artist-card {
    flex: 0 0 auto;
    width: 110px;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 8px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}
.ormsy-artist-card:hover {
    border-color: #c4a875;
    box-shadow: 0 2px 8px rgba(139,111,71,0.15);
}
.ormsy-artist-card.active {
    border-color: #8B6F47;
    background: #f9f5f0;
    box-shadow: 0 0 0 2px rgba(139,111,71,0.2);
}
.ormsy-artist-card-img {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    overflow: hidden;
    background: #f0ebe4;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
}
.ormsy-artist-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.ormsy-artist-card-img .ormsy-artist-initial {
    font-size: 24px;
    font-weight: 700;
    color: #8B6F47;
}
.ormsy-all-icon {
    color: #8B6F47;
}
.ormsy-artist-card-name {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    line-height: 1.2;
}
.ormsy-artist-card-count {
    font-size: 11px;
    color: #999;
    margin-top: 2px;
}

/* =========================================
   Category Pills
   ========================================= */
.ormsy-category-pills,
.ormsy-status-toggle {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.ormsy-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 16px;
    border: 1px solid #d0c8be;
    border-radius: 20px;
    background: #fff;
    color: #555;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    line-height: 1;
}
.ormsy-pill:hover {
    border-color: #c4a875;
    color: #8B6F47;
}
.ormsy-pill.active {
    background: #8B6F47;
    border-color: #8B6F47;
    color: #fff;
}
.ormsy-pill-count {
    font-size: 11px;
    opacity: 0.7;
}
.ormsy-pill.active .ormsy-pill-count {
    opacity: 0.9;
}

/* =========================================
   Layout Picker
   ========================================= */
.ormsy-layout-picker {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.ormsy-layout-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 70px;
}
.ormsy-layout-option input[type="radio"] {
    display: none;
}
.ormsy-layout-option:hover {
    border-color: #c4a875;
}
.ormsy-layout-option.active {
    border-color: #8B6F47;
    background: #f9f5f0;
}
.ormsy-layout-preview {
    color: #888;
}
.ormsy-layout-option.active .ormsy-layout-preview {
    color: #8B6F47;
}
.ormsy-layout-option span {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #777;
}
.ormsy-layout-option.active span {
    color: #8B6F47;
}

/* =========================================
   Footer: count + download button
   ========================================= */
.ormsy-cb-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid #e8e0d6;
    gap: 16px;
}
.ormsy-cb-count {
    font-size: 14px;
    color: #888;
    min-height: 20px;
}
.ormsy-cb-count strong {
    color: #333;
    font-weight: 700;
}

.ormsy-pdf-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 36px;
    background: #8B6F47;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
    white-space: nowrap;
}
.ormsy-pdf-download-btn:hover {
    background: #725a39;
    transform: translateY(-1px);
}
.ormsy-pdf-download-btn:active {
    transform: translateY(0);
}
.ormsy-pdf-download-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}
.ormsy-pdf-download-btn svg {
    flex-shrink: 0;
}
.ormsy-pdf-download-btn.loading svg {
    animation: ormsy-spin 1s linear infinite;
}
@keyframes ormsy-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* =========================================
   WhatsApp Section
   ========================================= */
.ormsy-whatsapp-section {
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid #e8e0d6;
}
.ormsy-whatsapp-row {
    display: flex;
    gap: 10px;
    align-items: stretch;
}
.ormsy-whatsapp-input-wrap {
    flex: 1;
    display: flex;
    align-items: center;
    border: 2px solid #d0c8be;
    border-radius: 6px;
    background: #fff;
    padding: 0 12px;
    transition: border-color 0.2s;
}
.ormsy-whatsapp-input-wrap:focus-within {
    border-color: #25D366;
}
.ormsy-whatsapp-icon {
    flex-shrink: 0;
    margin-right: 8px;
}
.ormsy-whatsapp-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 15px;
    padding: 12px 0;
    background: transparent;
    font-family: inherit;
}
.ormsy-whatsapp-input::placeholder {
    color: #aaa;
}
.ormsy-whatsapp-input.ormsy-input-error {
    color: #c0392b;
}
.ormsy-whatsapp-input-wrap:has(.ormsy-input-error) {
    border-color: #c0392b;
}
.ormsy-whatsapp-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #25D366;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
    white-space: nowrap;
}
.ormsy-whatsapp-btn:hover {
    background: #1ebe57;
    transform: translateY(-1px);
}
.ormsy-whatsapp-btn:active {
    transform: translateY(0);
}
.ormsy-whatsapp-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}
.ormsy-whatsapp-btn.loading svg {
    animation: ormsy-spin 1s linear infinite;
}
.ormsy-whatsapp-hint {
    font-size: 12px;
    color: #999;
    margin: 6px 0 0;
}
.ormsy-cb-actions {
    display: flex;
    gap: 10px;
}

/* =========================================
   Responsive
   ========================================= */
@media (max-width: 640px) {
    .ormsy-catalog-builder {
        padding: 0 12px;
    }
    .ormsy-artist-cards {
        gap: 8px;
    }
    .ormsy-artist-card {
        width: 90px;
        padding: 10px 6px;
    }
    .ormsy-artist-card-img {
        width: 50px;
        height: 50px;
    }
    .ormsy-layout-picker {
        gap: 6px;
    }
    .ormsy-layout-option {
        padding: 8px 10px;
        min-width: 60px;
    }
    .ormsy-cb-footer {
        flex-direction: column;
        text-align: center;
    }
    .ormsy-pdf-download-btn {
        width: 100%;
        justify-content: center;
    }
    .ormsy-cb-actions {
        width: 100%;
    }
    .ormsy-whatsapp-row {
        flex-direction: column;
    }
    .ormsy-whatsapp-btn {
        width: 100%;
        justify-content: center;
    }
}
