/**
 * Publisuites Panel Styles
 *
 * BEM naming: .contai-ps  (block)
 *             .contai-ps-card  (sub-block)
 *             .contai-ps-card--benefit  (modifier)
 *             .contai-ps-card__title  (element)
 *
 * Extends base.css CSS custom properties (--contai-*).
 * Publisuites accent uses --ps-* variables.
 */

/* ----------------------------------------------------------------
   1. Custom Properties
   ---------------------------------------------------------------- */
:root {
    --ps-primary: #00a32a;
    --ps-primary-dark: #008a20;
    --ps-primary-light: #d1fae5;
    --ps-accent: var(--contai-success);
}

/* ----------------------------------------------------------------
   2. Info Boxes (shared license notice)
   ---------------------------------------------------------------- */
.contai-info-box {
    padding: 20px;
    border-radius: var(--contai-radius-md);
    margin-bottom: var(--contai-spacing-lg);
    border-width: 1px;
    border-style: solid;
    display: flex;
    gap: var(--contai-spacing-md);
    align-items: flex-start;
}

.contai-info-box > .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    margin-top: 2px;
}

.contai-info-box p {
    margin: 0 0 var(--contai-spacing-xs) 0;
    line-height: 1.6;
    font-size: 14px;
}

.contai-info-box p:last-child {
    margin-bottom: 0;
}

.contai-info-box p strong {
    font-weight: 700;
    font-size: 15px;
}

.contai-info-box-warning {
    background: var(--contai-warning-bg);
    border-color: var(--contai-warning-border);
    color: var(--contai-warning-text);
}

.contai-info-box-warning > .dashicons {
    color: var(--contai-warning);
}

/* ----------------------------------------------------------------
   3. Layout Container
   ---------------------------------------------------------------- */
.contai-ps {
    display: flex;
    flex-direction: column;
    gap: var(--contai-spacing-lg);
    max-width: 1200px;
}

/* ----------------------------------------------------------------
   3. Status Badge
   ---------------------------------------------------------------- */
.contai-ps-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    width: fit-content;
    line-height: 1;
    border: 1px solid transparent;
}

.contai-ps-status__dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.contai-badge--success {
    background: var(--ps-primary-light);
    color: #065f46;
    border-color: #a7f3d0;
}

.contai-badge--success .contai-ps-status__dot {
    background: var(--ps-primary);
}

.contai-badge--warning {
    background: var(--contai-warning-bg);
    color: var(--contai-warning-text);
    border-color: var(--contai-warning-border);
}

.contai-badge--warning .contai-ps-status__dot {
    background: #f59e0b;
}

.contai-badge--neutral {
    background: var(--contai-neutral-200);
    color: var(--contai-neutral-600);
    border-color: var(--contai-neutral-300);
}

.contai-badge--neutral .contai-ps-status__dot {
    background: var(--contai-neutral-500);
}

.contai-badge--error {
    background: var(--contai-error-bg);
    color: var(--contai-error-text);
    border-color: var(--contai-error-border);
}

.contai-badge--error .contai-ps-status__dot {
    background: var(--contai-error);
}

/* ----------------------------------------------------------------
   4. Hero / Intro Text
   ---------------------------------------------------------------- */
.contai-ps-hero__text {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--contai-neutral-600);
    max-width: 680px;
}

/* ----------------------------------------------------------------
   5. Section Title
   ---------------------------------------------------------------- */
.contai-ps-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 var(--contai-spacing-md) 0;
    font-size: 15px;
    font-weight: 700;
    color: var(--contai-neutral-700);
}

.contai-ps-section-title .dashicons {
    color: var(--ps-primary);
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* ----------------------------------------------------------------
   6. Card Base
   ---------------------------------------------------------------- */
.contai-ps-card {
    background: #fff;
    border: 1px solid var(--contai-neutral-300);
    border-radius: var(--contai-radius-lg);
    padding: var(--contai-spacing-lg);
    box-shadow: var(--contai-shadow-sm);
}

/* ----------------------------------------------------------------
   7. Benefits Section & Grid
   ---------------------------------------------------------------- */
.contai-ps-benefits__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--contai-spacing-md);
}

.contai-ps-card--benefit {
    display: flex;
    flex-direction: column;
    gap: var(--contai-spacing-sm);
    text-align: center;
    transition: box-shadow var(--contai-duration-fast) ease, border-color var(--contai-duration-fast) ease;
}

.contai-ps-card--benefit:hover {
    border-color: #a7f3d0;
    box-shadow: 0 4px 12px rgba(0, 163, 42, 0.1);
}

.contai-ps-card__icon {
    width: 48px;
    height: 48px;
    margin: 0 auto;
    background: linear-gradient(135deg, var(--ps-primary) 0%, var(--ps-accent) 100%);
    border-radius: var(--contai-radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contai-ps-card__icon .dashicons {
    font-size: 24px;
    width: 24px;
    height: 24px;
    color: #fff;
}

.contai-ps-card__title {
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: var(--contai-neutral-700);
}

.contai-ps-card__desc {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--contai-neutral-600);
}

/* ----------------------------------------------------------------
   8. Info Card (Website Info / Integration Details)
   ---------------------------------------------------------------- */
.contai-ps-card--info {
    padding: 0;
    overflow: hidden;
}

.contai-ps-card__header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: var(--contai-spacing-md) var(--contai-spacing-lg);
    font-size: 14px;
    font-weight: 700;
    color: var(--contai-neutral-700);
    background: var(--contai-neutral-100);
    border-bottom: 1px solid var(--contai-neutral-300);
}

.contai-ps-card__header .dashicons {
    color: var(--contai-primary);
    font-size: 20px;
    width: 20px;
    height: 20px;
}

/* Info list (dl) */
.contai-ps-info-list {
    margin: 0;
}

.contai-ps-info-list__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--contai-spacing-sm) var(--contai-spacing-lg);
    border-bottom: 1px solid var(--contai-neutral-200);
}

.contai-ps-info-list__row:last-child {
    border-bottom: none;
}

.contai-ps-info-list__row dt {
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--contai-neutral-600);
}

.contai-ps-info-list__row dd {
    margin: 0;
    font-size: 13px;
    color: var(--contai-neutral-700);
    text-align: right;
    word-break: break-all;
    max-width: 60%;
}

.contai-ps-mono {
    font-family: var(--contai-font-mono);
    font-size: 12px;
}

/* Inline badge (Active status) */
.contai-ps-inline-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.5;
}

.contai-ps-inline-badge--active {
    background: var(--ps-primary-light);
    color: #065f46;
}

/* ----------------------------------------------------------------
   9. Success Card (Connected / Verified)
   ---------------------------------------------------------------- */
.contai-ps-card--success {
    display: flex;
    align-items: flex-start;
    gap: var(--contai-spacing-md);
    background: linear-gradient(135deg, var(--contai-success-bg) 0%, #dcfce7 100%);
    border-color: #a7f3d0;
}

.contai-ps-card--success__icon {
    color: var(--ps-primary);
    font-size: 32px;
    width: 32px;
    height: 32px;
    flex-shrink: 0;
    margin-top: 2px;
}

.contai-ps-card--success .contai-ps-card__title {
    color: #065f46;
    font-size: 16px;
    margin-bottom: 4px;
}

.contai-ps-card--success .contai-ps-card__desc {
    color: #047857;
}

/* ----------------------------------------------------------------
   10. Steps (Verification Flow)
   ---------------------------------------------------------------- */
.contai-ps-steps__list {
    display: flex;
    flex-direction: column;
    gap: var(--contai-spacing-md);
}

.contai-ps-card--step {
    display: flex;
    gap: var(--contai-spacing-md);
    align-items: flex-start;
}

.contai-ps-step-number {
    width: 32px;
    height: 32px;
    background: var(--ps-primary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 2px;
}

.contai-ps-step-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--contai-spacing-xs);
}

/* Code block */
.contai-ps-code-block {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--contai-neutral-100);
    border: 1px solid var(--contai-neutral-300);
    border-radius: var(--contai-radius-md);
    padding: var(--contai-spacing-sm) var(--contai-spacing-md);
    margin-top: 4px;
}

.contai-ps-code-block code {
    flex: 1;
    font-family: var(--contai-font-mono);
    font-size: 12px;
    color: var(--contai-neutral-700);
    word-break: break-all;
}

/* Copy button */
.contai-ps-copy-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--contai-neutral-300);
    border-radius: var(--contai-radius-sm);
    background: #fff;
    cursor: pointer;
    flex-shrink: 0;
    transition: background-color var(--contai-duration-fast) ease;
}

.contai-ps-copy-btn:hover {
    background: var(--contai-neutral-200);
}

.contai-ps-copy-btn:focus-visible {
    outline: 3px solid var(--ps-primary);
    outline-offset: 2px;
}

.contai-ps-copy-btn .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    color: var(--contai-neutral-600);
}

.contai-ps-copy-btn.copied {
    background: var(--ps-primary);
    border-color: var(--ps-primary);
}

.contai-ps-copy-btn.copied .dashicons {
    color: #fff;
}

.contai-ps-copy-btn.error {
    background: var(--contai-error);
    border-color: var(--contai-error);
}

.contai-ps-copy-btn.error .dashicons {
    color: #fff;
}

/* File status */
.contai-ps-file-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
    padding: 4px 0;
}

.contai-ps-file-status .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

.contai-ps-file-status--ok {
    color: var(--ps-primary);
}

.contai-ps-file-status--missing {
    color: #f59e0b;
}

/* Help text */
.contai-ps-help {
    margin: 4px 0 0 0;
    font-size: 12px;
    color: var(--contai-neutral-500);
}

/* ----------------------------------------------------------------
   11. Forms & Buttons
   ---------------------------------------------------------------- */
.contai-ps-form--primary {
    padding-top: var(--contai-spacing-md);
}

.contai-ps-form--inline {
    margin-top: var(--contai-spacing-xs);
}

/* Main CTA */
.contai-ps-cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 15px !important;
    font-weight: 700;
    padding: 12px 28px !important;
    border-radius: var(--contai-radius-lg) !important;
    background: linear-gradient(135deg, var(--ps-primary) 0%, var(--ps-primary-dark) 100%) !important;
    border-color: var(--ps-primary-dark) !important;
    box-shadow: 0 2px 8px rgba(0, 163, 42, 0.25);
    transition: box-shadow var(--contai-duration-fast) ease, background var(--contai-duration-fast) ease;
}

.contai-ps-cta:hover,
.contai-ps-cta:focus {
    background: linear-gradient(135deg, var(--ps-primary-dark) 0%, #006617 100%) !important;
    box-shadow: 0 4px 12px rgba(0, 163, 42, 0.35);
    color: #fff !important;
}

.contai-ps-cta:focus-visible {
    outline: 3px solid var(--ps-primary);
    outline-offset: 2px;
}

.contai-ps-cta .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Loading state */
.contai-ps-form.is-loading button,
.contai-ps-form--inline.is-loading button {
    opacity: 0.6;
    cursor: not-allowed;
    pointer-events: none;
    position: relative;
}

.contai-ps-form.is-loading button::after,
.contai-ps-form--inline.is-loading button::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    right: 12px;
    margin-top: -8px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: contai-ps-spin 0.8s linear infinite;
}

@keyframes contai-ps-spin {
    to { transform: rotate(360deg); }
}

/* ----------------------------------------------------------------
   12. Danger Zone
   ---------------------------------------------------------------- */
.contai-ps-danger {
    border: 1px solid var(--contai-error-border);
    border-radius: var(--contai-radius-lg);
    background: #fff;
    overflow: hidden;
    margin-top: var(--contai-spacing-md);
}

.contai-ps-danger__title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: var(--contai-spacing-sm) var(--contai-spacing-lg);
    font-size: 13px;
    font-weight: 700;
    color: var(--contai-error-text);
    background: var(--contai-error-bg);
    border-bottom: 1px solid var(--contai-error-border);
}

.contai-ps-danger__title .dashicons {
    color: var(--contai-error);
    font-size: 18px;
    width: 18px;
    height: 18px;
}

.contai-ps-danger__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--contai-spacing-md);
    padding: var(--contai-spacing-md) var(--contai-spacing-lg);
}

.contai-ps-danger__desc {
    margin: 0;
    font-size: 13px;
    color: var(--contai-neutral-600);
    line-height: 1.5;
}

.contai-ps-btn--danger {
    color: var(--contai-error) !important;
    border-color: var(--contai-error-border) !important;
    white-space: nowrap;
    flex-shrink: 0;
}

.contai-ps-btn--danger:hover {
    background: var(--contai-error-bg) !important;
    border-color: var(--contai-error) !important;
    color: var(--contai-error-text) !important;
}

.contai-ps-btn--danger:focus-visible {
    outline: 3px solid var(--contai-error);
    outline-offset: 2px;
}

/* ----------------------------------------------------------------
   13. Flash Message
   ---------------------------------------------------------------- */
.contai-ps-flash {
    margin-bottom: var(--contai-spacing-md);
}

/* ----------------------------------------------------------------
   14. Alert (website_required / error states)
   ---------------------------------------------------------------- */
.contai-ps-alert {
    margin-bottom: var(--contai-spacing-md);
}

/* ----------------------------------------------------------------
   15. Accessibility: Reduced Motion
   ---------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    .contai-ps-card--benefit,
    .contai-ps-copy-btn,
    .contai-ps-cta,
    .contai-ps-form.is-loading button::after,
    .contai-ps-form--inline.is-loading button::after {
        transition: none;
        animation: none;
    }
}

/* ----------------------------------------------------------------
   16. Accessibility: High Contrast
   ---------------------------------------------------------------- */
@media (prefers-contrast: high) {
    .contai-ps-card {
        border-width: 2px;
    }

    .contai-ps-status {
        border-width: 2px;
    }

    .contai-ps-cta {
        border-width: 2px !important;
    }

    .contai-ps-danger {
        border-width: 2px;
    }
}

/* ----------------------------------------------------------------
   17. Responsive: Tablet
   ---------------------------------------------------------------- */
@media (max-width: 960px) {
    .contai-ps-benefits__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ----------------------------------------------------------------
   18. Responsive: Mobile
   ---------------------------------------------------------------- */
@media (max-width: 768px) {
    .contai-ps-benefits__grid {
        grid-template-columns: 1fr;
    }

    .contai-ps-card--benefit {
        flex-direction: row;
        text-align: left;
        gap: var(--contai-spacing-md);
    }

    .contai-ps-card__icon {
        margin: 0;
    }

    .contai-ps-danger__row {
        flex-direction: column;
        align-items: flex-start;
    }

    .contai-ps-btn--danger {
        width: 100%;
        justify-content: center;
    }

    .contai-ps-info-list__row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .contai-ps-info-list__row dd {
        text-align: left;
        max-width: 100%;
    }

    /* Touch targets */
    .contai-ps-copy-btn,
    .contai-ps-cta,
    .button {
        min-height: 44px;
        min-width: 44px;
    }

    .contai-ps-cta {
        width: 100%;
        justify-content: center;
    }
}

/* ── 19. Orders Section — Tab Layout ── */

.contai-ps-orders__header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; flex-wrap: wrap; gap: 12px; }
.contai-ps-orders__title { font-size: 18px; font-weight: 600; color: #1e293b; display: flex; align-items: center; gap: 8px; }
.contai-ps-orders__sync-info { display: flex; align-items: center; gap: 12px; }
.contai-ps-orders__synced-at { font-size: 13px; color: #64748b; }
.contai-ps-orders__sync-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; background: var(--ps-primary, #00a32a); color: #fff; border: none; border-radius: 6px; font-size: 13px; font-weight: 500; cursor: pointer; transition: background 0.2s; }
.contai-ps-orders__sync-btn:hover { background: var(--ps-primary-dark, #008a20); }
.contai-ps-orders__stale-warning { background: #fef3c7; border: 1px solid #f59e0b; border-radius: 8px; padding: 10px 16px; margin-bottom: 16px; font-size: 13px; color: #92400e; display: flex; align-items: center; gap: 8px; }

/* Tab Navigation */
.contai-ps-orders__tabs-nav { display: flex; gap: 0; background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px 10px 0 0; border-bottom: 2px solid #e2e8f0; }
.contai-ps-orders__tab { display: inline-flex; align-items: center; gap: 6px; padding: 12px 20px; background: transparent; border: none; border-bottom: 2px solid transparent; margin-bottom: -2px; font-size: 13px; font-weight: 500; color: #64748b; cursor: pointer; transition: all 0.2s; white-space: nowrap; }
.contai-ps-orders__tab:hover { color: #1e293b; background: #f1f5f9; }
.contai-ps-orders__tab.active { color: var(--ps-primary, #00a32a); border-bottom-color: var(--ps-primary, #00a32a); background: #fff; }
.contai-ps-orders__tab .dashicons { font-size: 16px; width: 16px; height: 16px; }
.contai-ps-orders__tab-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; font-size: 11px; font-weight: 600; background: #e2e8f0; color: #475569; }
.contai-ps-orders__tab-badge--alert { background: #ef4444; color: #fff; animation: contai-ps-pulse 2s infinite; }
@keyframes contai-ps-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.7; } }

/* Tab Content */
.contai-ps-orders__tab-content { display: none; border: 1px solid #e2e8f0; border-top: none; border-radius: 0 0 10px 10px; padding: 20px; background: #fff; }
.contai-ps-orders__tab-content.active { display: block; animation: contai-ps-reveal 0.2s ease-out; }
@keyframes contai-ps-reveal { from { opacity: 0; } to { opacity: 1; } }

/* Order Cards */
.contai-ps-orders__cards { display: grid; gap: 16px; }
.contai-ps-orders__card { border: 1px solid #e2e8f0; border-radius: 10px; padding: 16px 20px; background: #fff; transition: box-shadow 0.2s; }
.contai-ps-orders__card:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.contai-ps-orders__card-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; flex-wrap: wrap; gap: 8px; }
.contai-ps-orders__card-id { font-weight: 700; font-size: 15px; color: #1e293b; display: flex; align-items: center; gap: 8px; }
.contai-ps-orders__type-badge { display: inline-flex; padding: 2px 8px; border-radius: 4px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; }
.contai-ps-orders__type-badge--post { background: #dbeafe; color: #1e40af; }
.contai-ps-orders__type-badge--link { background: #f3e8ff; color: #7c3aed; }
.contai-ps-orders__card-earnings { font-size: 18px; font-weight: 700; color: #059669; }
.contai-ps-orders__card-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 24px; font-size: 13px; margin-bottom: 14px; }
.contai-ps-orders__card-meta-row { display: flex; justify-content: space-between; align-items: center; }
.contai-ps-orders__card-label { font-weight: 500; color: #94a3b8; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; }
.contai-ps-orders__card-deadline--urgent { color: #ef4444; font-weight: 600; }
.contai-ps-orders__card-deadline--warning { color: #f59e0b; font-weight: 600; }
.contai-ps-orders__card-deadline--overdue { color: #dc2626; font-weight: 700; }
.contai-ps-orders__card-website { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.contai-ps-orders__card-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding-top: 14px; border-top: 1px solid #f1f5f9; }
.contai-ps-orders__card-earnings-inline { color: #059669; font-weight: 600; }

/* Status Badge */
.contai-ps-orders__status { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 12px; font-size: 12px; font-weight: 500; white-space: nowrap; }

/* Action Buttons */
.contai-ps-orders__action-form--inline { display: inline-flex; }
.contai-ps-orders__action-form--url { display: flex; gap: 8px; align-items: center; flex: 1; }
.contai-ps-orders__btn-accept { background: #059669 !important; border-color: #059669 !important; color: #fff !important; }
.contai-ps-orders__btn-accept:hover { background: #047857 !important; }
.contai-ps-orders__url-input { flex: 1; padding: 6px 12px; border: 1px solid #e2e8f0; border-radius: 6px; font-size: 13px; min-width: 200px; }
.contai-ps-orders__url-input:focus { border-color: var(--ps-primary, #00a32a); outline: none; box-shadow: 0 0 0 2px rgba(0,163,42,0.15); }

/* History Table */
.contai-ps-orders__table-wrap { overflow-x: auto; }
.contai-ps-orders__table th { padding: 8px 14px; text-align: left; font-weight: 600; color: #475569; border-bottom: 1px solid #e2e8f0; font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
.contai-ps-orders__table td { padding: 10px 14px; border-bottom: 1px solid #f1f5f9; color: #64748b; }
.contai-ps-orders__table tr:last-child td { border-bottom: none; }

/* Empty State */
.contai-ps-orders__empty { text-align: center; padding: 40px 20px; }
.contai-ps-orders__empty-icon { font-size: 40px; margin-bottom: 8px; opacity: 0.4; }
.contai-ps-orders__empty-text { font-size: 14px; color: #94a3b8; }

/* ── 20. Order Detail Panel ── */
.contai-ps-orders__detail { margin-top: 12px; border-top: 1px solid #f1f5f9; }
.contai-ps-orders__detail-summary { display: flex; align-items: center; gap: 4px; padding: 10px 0 4px; font-size: 13px; font-weight: 500; color: #64748b; cursor: pointer; list-style: none; user-select: none; }
.contai-ps-orders__detail-summary::-webkit-details-marker { display: none; }
.contai-ps-orders__detail-summary .dashicons { font-size: 14px; width: 14px; height: 14px; transition: transform 0.2s; color: #94a3b8; }
.contai-ps-orders__detail[open] > .contai-ps-orders__detail-summary .dashicons { transform: rotate(90deg); }
.contai-ps-orders__detail-body { padding: 12px 0 4px; animation: contai-ps-reveal 0.2s ease-out; }
.contai-ps-orders__detail-field { margin-bottom: 14px; }
.contai-ps-orders__detail-label { display: block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: #94a3b8; margin-bottom: 4px; }
.contai-ps-orders__detail-value { font-size: 13px; color: #1e293b; line-height: 1.5; margin: 0; }
.contai-ps-orders__detail-value--title { font-size: 14px; font-weight: 600; color: #0f172a; }
.contai-ps-orders__detail-specs { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.contai-ps-orders__detail-spec { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: #475569; padding: 4px 10px; background: #f8fafc; border-radius: 6px; border: 1px solid #e2e8f0; }
.contai-ps-orders__detail-spec .dashicons { font-size: 14px; width: 14px; height: 14px; color: #94a3b8; }
.contai-ps-orders__detail-links { width: 100%; border-collapse: collapse; font-size: 12px; margin-top: 4px; }
.contai-ps-orders__detail-links th { text-align: left; font-weight: 600; color: #64748b; padding: 6px 10px; border-bottom: 1px solid #e2e8f0; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; }
.contai-ps-orders__detail-links td { padding: 6px 10px; border-bottom: 1px solid #f1f5f9; color: #334155; }
.contai-ps-orders__detail-links code { background: #f1f5f9; padding: 2px 6px; border-radius: 4px; font-size: 12px; }
.contai-ps-orders__detail-links a { color: var(--ps-primary, #00a32a); text-decoration: none; word-break: break-all; }
.contai-ps-orders__detail-links a:hover { text-decoration: underline; }
.contai-ps-orders__detail-empty { font-size: 13px; color: #94a3b8; font-style: italic; margin: 0; }
.contai-ps-orders__detail-footer { padding-top: 10px; margin-top: 10px; border-top: 1px solid #f1f5f9; }
.contai-ps-orders__detail-ext-link { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: #64748b; text-decoration: none; }
.contai-ps-orders__detail-ext-link:hover { color: var(--ps-primary, #00a32a); }
.contai-ps-orders__detail-ext-link .dashicons { font-size: 14px; width: 14px; height: 14px; }

/* ── 21. Connection Settings ── */
.contai-ps-settings { border: 1px solid #e2e8f0; border-radius: 10px; background: #fafbfc; }
.contai-ps-settings__summary { display: flex; align-items: center; gap: 8px; padding: 14px 20px; font-size: 14px; font-weight: 600; color: #475569; cursor: pointer; list-style: none; user-select: none; }
.contai-ps-settings__summary::-webkit-details-marker { display: none; }
.contai-ps-settings__summary::before { content: "\25B8"; font-size: 12px; color: #94a3b8; transition: transform 0.2s; }
.contai-ps-settings[open] > .contai-ps-settings__summary::before { transform: rotate(90deg); }
.contai-ps-settings__summary .dashicons { color: #94a3b8; font-size: 16px; width: 16px; height: 16px; }
.contai-ps-settings__body { padding: 0 20px 16px; }

/* ── 22. Responsive ── */
@media (max-width: 768px) {
    .contai-ps-orders__header { flex-direction: column; align-items: flex-start; }
    .contai-ps-orders__tabs-nav { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .contai-ps-orders__tab { padding: 10px 14px; font-size: 12px; }
    .contai-ps-orders__card-meta { grid-template-columns: 1fr; }
    .contai-ps-orders__action-form--url { flex-direction: column; }
    .contai-ps-orders__url-input { min-width: 100%; }
}
