/* ==========================================================================
   Art Hub Dashboard - Shared Styles
   Used by: art-hub-steve.html, ae-dashboard.html

   Theme colors set per-page via :root custom properties:
     --art-theme        Primary color (green #009900 or crimson #981e32)
     --art-theme-light  Light tint for backgrounds
     --art-theme-hover  Hover state for back-link
   ========================================================================== */

/* ---------- Base ---------- */
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    background-color: #f5f5f5;
}

/* ---------- Header ---------- */
.minimal-header {
    background: var(--art-theme);
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.logo {
    height: 40px;
    filter: brightness(0) invert(1);
}

.back-link {
    color: white;
    text-decoration: none;
    font-size: 14px;
    padding: 8px 16px;
    border: 1px solid white;
    border-radius: 4px;
    transition: all 0.3s;
}

.back-link:hover {
    background: white;
    color: var(--art-theme);
}

/* ---------- Tab Navigation ---------- */
.tab-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
}

.tab-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    background: white;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: relative;
    flex-wrap: wrap;
}

.tab-button {
    background: #f0f0f0;
    border: none;
    padding: 10px 16px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s;
    color: #333;
    white-space: nowrap;
}

.tab-button:hover {
    background: #e0e0e0;
}

.tab-button.active {
    background: var(--art-theme);
    color: white;
}

/* ---------- Tab Content ---------- */
.tab-content {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tab-pane {
    display: none;
    max-width: 100%;
}

.tab-pane.active {
    display: block;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.tab-title {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--art-theme);
}

/* ---------- Caspio Form Fixes ---------- */
.tab-pane #caspioform {
    max-width: 100% !important;
    overflow-x: auto !important;
}

#caspioform {
    position: relative;
    z-index: 1;
}

.cbFormModal,
.cbModalBackground,
[id*="cbModal"],
[class*="cbModal"] {
    z-index: 9999 !important;
}

/* ---------- Notes Slide-Out Panel ---------- */
.notes-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.35);
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.notes-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.notes-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 420px;
    height: 100vh;
    z-index: 10001;
    background: #fff;
    box-shadow: -4px 0 24px rgba(0,0,0,0.15);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.notes-panel.open {
    transform: translateX(0);
}

.notes-panel-header {
    background: linear-gradient(145deg, var(--art-theme), #2d6b3f);
    color: white;
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.notes-panel-header-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

#notes-panel-company {
    font-weight: 700;
    font-size: 1.05em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#notes-panel-id {
    font-size: 0.8em;
    opacity: 0.85;
}

.notes-panel-close {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
    padding: 0 4px;
    flex-shrink: 0;
    opacity: 0.85;
    transition: opacity 0.2s;
}

.notes-panel-close:hover {
    opacity: 1;
}

/* --- Notes Form --- */
.notes-panel-form {
    padding: 16px 20px;
    border-bottom: 1px solid #e5e7eb;
    flex-shrink: 0;
}

.notes-panel-form-title {
    margin: 0 0 10px;
    font-size: 0.9em;
    font-weight: 700;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

#note-type-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    color: #374151;
    background: #fff;
    margin-bottom: 8px;
    appearance: auto;
}

#note-type-select:focus {
    outline: none;
    border-color: var(--art-theme);
    box-shadow: 0 0 0 2px rgba(76,179,84,0.2);
}

#note-text {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    color: #374151;
    resize: vertical;
    min-height: 60px;
    font-family: inherit;
    margin-bottom: 8px;
    box-sizing: border-box;
}

#note-text:focus {
    outline: none;
    border-color: var(--art-theme);
    box-shadow: 0 0 0 2px rgba(76,179,84,0.2);
}

.notes-notify-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 10px;
    cursor: pointer;
    user-select: none;
}

.notes-notify-label input[type="checkbox"] {
    accent-color: var(--art-theme);
    width: 15px;
    height: 15px;
    cursor: pointer;
}

#note-submit-btn {
    width: 100%;
    padding: 9px 16px;
    background: var(--art-theme);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, opacity 0.2s;
}

#note-submit-btn:hover {
    background: #3a8a41;
}

#note-submit-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
}

/* --- Notes Timeline --- */
.notes-panel-divider {
    height: 1px;
    background: #e5e7eb;
    flex-shrink: 0;
}

.notes-panel-timeline-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px 8px;
    font-weight: 700;
    font-size: 0.9em;
    color: #374151;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex-shrink: 0;
}

.notes-count-badge {
    background: #e5e7eb;
    color: #374151;
    font-size: 0.8em;
    font-weight: 600;
    padding: 1px 8px;
    border-radius: 12px;
    min-width: 20px;
    text-align: center;
}

.notes-panel-timeline {
    flex: 1;
    overflow-y: auto;
    padding: 4px 20px 20px;
}

.notes-loading,
.notes-empty {
    text-align: center;
    padding: 40px 20px;
    color: #9ca3af;
    font-size: 14px;
}

.notes-loading {
    color: #6b7280;
}

.notes-error {
    text-align: center;
    padding: 24px 20px;
    color: #dc2626;
    font-size: 14px;
}

.notes-error button {
    margin-top: 8px;
    padding: 6px 16px;
    background: #dc2626;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    cursor: pointer;
}

.notes-error button:hover {
    background: #b91c1c;
}

/* --- Note Cards --- */
.note-card {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 8px;
}

.note-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.note-type-pill {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.72em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    white-space: nowrap;
}

.note-type-pill--status-update { background: #dbeafe; color: #1d4ed8; }
.note-type-pill--design-update { background: #ffedd5; color: #c2410c; }
.note-type-pill--art-time      { background: #dcfce7; color: #15803d; }
.note-type-pill--customer-feedback { background: #f3e8ff; color: #7c3aed; }
.note-type-pill--internal-note { background: #f3f4f6; color: #374151; }
.note-type-pill--default       { background: #f3f4f6; color: #6b7280; }
.note-type-pill--mockup-sent   { background: #fef3c7; color: #b45309; }

.note-card-text {
    font-size: 13px;
    color: #374151;
    line-height: 1.55;
    margin-bottom: 6px;
    white-space: pre-wrap;
    word-break: break-word;
}

.note-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #9ca3af;
}

.note-card-author {
    font-weight: 500;
}

.note-delete-btn {
    background: none;
    border: none;
    color: #d1d5db;
    font-size: 14px;
    cursor: pointer;
    padding: 2px 4px;
    line-height: 1;
    transition: color 0.2s;
}

.note-delete-btn:hover {
    color: #dc2626;
}

/* --- Notes Panel Responsive --- */
@media (max-width: 768px) {
    .notes-panel {
        width: 100vw;
    }
}

/* ---------- Info Message (AE) ---------- */
.info-message {
    background: #f0f4f8;
    border-left: 4px solid var(--art-theme);
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

.info-message p {
    margin: 0;
    color: #333;
    line-height: 1.6;
}

/* ---------- NEW Badge ---------- */
.new-badge {
    display: inline-block;
    background: #dc3545;
    color: white;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 6px;
    vertical-align: middle;
}

/* ---------- More Dropdown (AE) ---------- */
.more-dropdown {
    position: relative;
}

.more-button {
    background: #f0f0f0;
    border: none;
    padding: 10px 16px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s;
    color: #333;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.more-button:hover {
    background: #e0e0e0;
}

.more-button.active {
    background: var(--art-theme);
    color: white;
}

.more-button svg {
    transition: transform 0.3s;
}

.more-button.open svg {
    transform: rotate(180deg);
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 220px;
    z-index: 1000;
    overflow: hidden;
    animation: slideDown 0.2s ease-out;
}

.dropdown-menu.show {
    display: block;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.dropdown-category {
    padding: 8px 16px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #666;
    background: #f8f8f8;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    gap: 6px;
}

.dropdown-item {
    display: flex;
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: none;
    text-align: left;
    font-size: 15px;
    color: #333;
    cursor: pointer;
    transition: all 0.2s;
    align-items: center;
    gap: 10px;
}

.dropdown-item:hover {
    background: #f5f5f5;
    color: var(--art-theme);
}

.dropdown-item.active {
    background: #fff5f5;
    color: var(--art-theme);
    font-weight: 500;
}

.dropdown-item svg {
    flex-shrink: 0;
    opacity: 0.6;
}

/* ---------- Steve-specific: Table tab overflow ---------- */
#table-tab {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* ---------- Steve-specific: Mockup tab fixes ---------- */
#mockup-tab.tab-pane.active,
#sendmockup-tab.tab-pane.active {
    display: block !important;
}

#mockup-tab .tab-title,
#sendmockup-tab .tab-title {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--art-theme);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}

#mockup-tab .cbResultSetTable,
#mockup-tab table,
#mockup-tab form {
    position: relative;
    z-index: 1;
}

#mockup-iframe {
    width: 100%;
    min-height: 600px;
    height: auto;
    border: none;
}

/* ==========================================================================
   Requirements Tab — Billing Codes, File Requirements, Fee Structure
   Used by: art-hub-steve.html (Requirements & Fees tab)
   ========================================================================== */

/* ---------- Section Headers ---------- */
.req-section {
    margin-bottom: 40px;
}

.req-section-title {
    color: var(--art-theme);
    border-bottom: 2px solid var(--art-theme);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

/* ---------- Billing Codes Section ---------- */
.billing-codes-section {
    background: linear-gradient(135deg, var(--art-theme-light) 0%, #e0f2e0 100%);
    border: 2px solid var(--art-theme);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 12px rgba(0,153,0,0.1);
}

.billing-codes-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.billing-codes-icon {
    background: var(--art-theme);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.billing-codes-title {
    margin: 0;
    color: var(--art-theme);
    font-size: 20px;
    font-weight: 600;
}

.billing-codes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

/* ---------- Billing Code Cards (GRT-50, GRT-75) ---------- */
.billing-code-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.billing-code-header {
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.billing-code-header--green  { background: #4caf50; }
.billing-code-header--blue   { background: #2196f3; }

.billing-code-pn {
    font-size: 24px;
    font-weight: bold;
}

.billing-code-subtitle {
    font-size: 14px;
    opacity: 0.95;
    margin-top: 2px;
}

.billing-code-price {
    font-size: 28px;
    font-weight: bold;
}

.billing-code-body {
    padding: 20px;
}

.billing-code-body-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    font-size: 15px;
}

.billing-code-body-desc {
    color: #666;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
}

/* ---------- Callout Boxes ---------- */
.callout {
    padding: 10px 15px;
    border-radius: 4px;
    border-left: 3px solid;
}

.callout--blue {
    background: #f0f9ff;
    border-left-color: #2196f3;
}

.callout--amber {
    background: #fff8e1;
    border-left-color: #ffc107;
}

.callout--orange {
    background: #fff3e0;
    border-left-color: #ff9800;
}

.callout-label {
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 5px;
}

.callout-label--blue   { color: #1976d2; }
.callout-label--amber  { color: #f57c00; }
.callout-label--orange { color: #e65100; }

.callout ul {
    margin: 5px 0 0 0;
    padding-left: 20px;
    font-size: 13px;
    color: #555;
}

.callout--spaced {
    margin-top: 20px;
}

.callout-text {
    font-size: 13px;
    color: #666;
}

/* ---------- Billing Increments Grid ---------- */
.increments-grid {
    display: grid;
    grid-template-columns: auto auto;
    gap: 5px 15px;
    font-size: 13px;
    color: #555;
}

.increments-grid .amount {
    font-weight: 600;
}

/* ---------- Pro Tip / Important Note Boxes ---------- */
.pro-tip-box {
    margin-top: 20px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.pro-tip-inner {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pro-tip-text {
    font-size: 14px;
    color: #333;
}

.important-note {
    margin-top: 30px;
    padding: 20px;
    background: var(--art-theme-light);
    border: 2px solid var(--art-theme);
    border-radius: 8px;
}

.important-note-inner {
    display: flex;
    align-items: center;
    gap: 15px;
}

.important-note-icon {
    background: var(--art-theme);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.important-note-title {
    font-weight: 600;
    color: var(--art-theme);
    margin-bottom: 5px;
}

.important-note-text {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* ---------- Quick Navigation Buttons ---------- */
.quick-nav {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.quick-nav-btn {
    padding: 8px 16px;
    background: var(--art-theme);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
}

.quick-nav-btn:hover {
    opacity: 0.9;
}

/* ---------- File Requirements Cards ---------- */
.file-req-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.file-req-card {
    background: white;
    border: 2px solid var(--art-theme);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.file-req-card-header {
    background: var(--art-theme);
    color: white;
    padding: 12px;
    font-weight: bold;
    font-size: 18px;
}

.file-req-card-body {
    padding: 15px;
}

.file-req-card-body h4 {
    color: #333;
    margin: 0 0 10px 0;
    font-size: 14px;
    text-transform: uppercase;
}

.file-req-card-body ul {
    margin: 0 0 15px 0;
    padding-left: 20px;
    font-size: 14px;
    color: #555;
}

.file-req-highlight {
    margin: 10px 0;
    padding: 10px;
    background: #e3f2fd;
    border-left: 4px solid #2196f3;
    border-radius: 4px;
}

.file-req-highlight strong {
    color: #1976d2;
}

.file-req-item {
    margin: 10px 0;
    font-size: 14px;
    color: #555;
}

/* ---------- File Definitions Section ---------- */
.file-def-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.file-def-column-header {
    background: #53565a;
    color: white;
    padding: 10px;
    margin: 0 0 15px 0;
    border-radius: 4px;
}

.file-def-card {
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 15px;
}

.file-def-card:last-child {
    margin-bottom: 0;
}

.file-def-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.file-def-badge {
    color: white;
    padding: 2px 8px;
    border-radius: 3px;
    font-weight: bold;
    font-size: 12px;
}

.file-def-badge--png  { background: #4caf50; }
.file-def-badge--jpg  { background: #ff9800; }
.file-def-badge--psd  { background: #9c27b0; }
.file-def-badge--ai   { background: #ff5722; }
.file-def-badge--cdr  { background: #3f51b5; }
.file-def-badge--pdf  { background: #e91e63; }
.file-def-badge--eps  { background: #607d8b; }

.file-def-type-label {
    color: #666;
    font-size: 13px;
}

.vector-tag {
    background: #4caf50;
    color: white;
    padding: 1px 6px;
    border-radius: 10px;
    font-size: 11px;
}

.file-def-desc {
    margin: 0;
    font-size: 14px;
    color: #555;
    line-height: 1.5;
}

.highlight-blue {
    color: #2196f3;
    font-weight: bold;
}

.highlight-pink {
    color: #e91e63;
    font-weight: bold;
}

/* ---------- Fee Structure Section ---------- */
.fee-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.fee-card-primary {
    background: linear-gradient(135deg, var(--art-theme) 0%, #00b300 100%);
    border-radius: 12px;
    padding: 25px;
    color: white;
    box-shadow: 0 8px 16px rgba(0,153,0,0.2);
}

.fee-card-secondary {
    background: white;
    border: 2px solid var(--art-theme);
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

.fee-amount {
    font-size: 36px;
    font-weight: bold;
    margin-bottom: 15px;
}

.fee-card-secondary .fee-amount {
    color: var(--art-theme);
}

.fee-label {
    font-size: 18px;
    font-weight: 500;
    margin-bottom: 20px;
}

.fee-card-primary .fee-label {
    opacity: 0.95;
}

.fee-card-secondary .fee-label {
    color: #333;
}

.fee-card-secondary .fee-desc {
    font-size: 14px;
    color: #666;
    margin-bottom: 20px;
}

.fee-includes {
    font-size: 15px;
    line-height: 1.6;
    opacity: 0.9;
}

.fee-includes-title {
    margin-bottom: 12px;
}

.fee-includes-item {
    display: flex;
    align-items: start;
    gap: 10px;
    margin-bottom: 10px;
}

.fee-includes-item:last-child {
    margin-bottom: 0;
}

.numbered-circle {
    background: white;
    color: var(--art-theme);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
}

.fee-increments-box {
    background: #f5f5f5;
    border-radius: 8px;
    padding: 15px;
}

.fee-increments-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
}

.fee-increments-grid {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 8px 15px;
    font-size: 15px;
}

.fee-increments-grid .time-label {
    color: #666;
}

.fee-increments-grid .time-price {
    color: var(--art-theme);
    font-weight: bold;
}

/* ==========================================================================
   Gallery Tab — Caspio Card Layout
   Migrated from DataPage inline styles → external for maintainability
   Used by: art-hub-steve.html (Caspio "Artist Gallery- STEVE-2025")
   ========================================================================== */

/* --- Caspio Layout Fixes (hide default field labels/data) --- */
.cbResultSetPanelDataContainer > .cbResultSetListViewDataLabel,
.cbResultSetPanelDataContainer > .cbResultSetData[data-cb-kwn="true"],
.cbResultSetPanelDataContainer > .cbResultSetData.cbResultSetCalculatedField,
div[data-cb-name="RACtnr"] {
    display: none !important;
}

/* Extra-specificity hide for Caspio record action menus (three-dot icons).
   Caspio may re-inject styles after ours — this outranks via class + attribute. */
#gallery-tab .cbResultSetPanelColumnarRAContainer,
#gallery-tab div.cbResultSetPanelColumnarRAContainer[data-cb-name="RACtnr"],
#view-tab .cbResultSetPanelColumnarRAContainer,
#view-tab div.cbResultSetPanelColumnarRAContainer[data-cb-name="RACtnr"] {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
    overflow: hidden !important;
}

.cbResultSetListViewTableOddCell,
.cbResultSetListViewTableEvenCell {
    background: none !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important; /* Caspio adds margin-bottom:10px — remove for grid gap control */
}

/* --- Caspio Form Overflow Fix (prevent horizontal scrollbar) --- */
/* Caspio sets overflow-x:auto !important on #caspioform — must override */
#gallery-tab form#caspioform,
#view-tab form#caspioform {
    overflow-x: hidden !important;
}

/* --- Gallery Grid (scoped to Steve's gallery tab) --- */
/* minmax(0, 1fr) prevents grid blowout — plain 1fr respects min-content,
   which lets wide card content push columns past the container edge. */
#gallery-tab .cbColumnarReport {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    max-width: 1200px;
    margin: 0 auto;
}

#view-tab .cbColumnarReport {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 16px;
    max-width: 1200px;
    margin: 0 auto;
}

/* --- Navigation Centering --- */
nav[data-cb-name="cbNavigationTableBottom"] {
    max-width: 1200px;
    margin: 20px auto 0 auto;
}

/* --- Card Structure --- */
.card {
    border: 1px solid #dde1e6;
    border-radius: 10px;
    overflow: hidden;
    background-color: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06), 0 1px 3px rgba(0,0,0,0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
    /* No height:100% — let cards size naturally so short cards
       don't get 100+px of dead whitespace in a mixed-content row */
}

/* Card hover moved to Status Left Border section below */

.card-header {
    color: white;
    padding: 10px 14px;
}

.card-header-top {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
}

.card-header .company-name {
    font-size: 1.05em;
    font-weight: 700;
    margin: 0;
    color: white !important;
    min-width: 0;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.25;
    letter-spacing: 0.01em;
}

.card-header .design-num {
    font-size: 0.75em;
    opacity: 0.95;
    font-family: 'Courier New', monospace;
    background: rgba(255,255,255,0.18);
    padding: 2px 8px;
    border-radius: 4px;
    white-space: nowrap;
    letter-spacing: 0.03em;
}

.card-header-sub {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 3px;
    font-size: 0.8em;
    opacity: 0.85;
}

.card-header .id-design {
    font-size: 1em;
}

.card-header .rep-name {
    cursor: pointer;
}

.card-header .rep-name:hover {
    text-decoration: underline;
}

.card-body {
    padding: 12px 14px;
    flex-grow: 1;
}

/* --- Status & Due Date Pills --- */
.status-container {
    display: flex;
    gap: 6px;
    margin-bottom: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.due-date-actual {
    font-size: 0.78em;
    color: #888;
    margin-left: auto;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

.pill {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.78em;
    text-align: center;
    letter-spacing: 0.01em;
    white-space: nowrap;
}

.status-submitted        { background-color: #f3e8ff; color: #6f42c1; }
.status-inprogress       { background-color: #dbeafe; color: #1d4ed8; }
.status-awaitingapproval { background-color: #fef3c7; color: #b45309; }
.status-completed        { background-color: #dcfce7; color: #15803d; }
.status-cancel           { background-color: #fee2e2; color: #b91c1c; }
.status-revisionrequested { background-color: #ffedd5; color: #c2410c; }

.due-overdue   { background-color: #dc2626; color: white; }
.due-today     { background-color: #ef4444; color: white; }
.due-tomorrow  { background-color: #f59e0b; color: white; }
.due-in-2-days { background-color: #fbbf24; color: #292524; }
.due-soon      { background-color: #3b82f6; color: white; }
.due-upcoming  { background-color: #22c55e; color: white; }

/* --- Request Type Badges --- */
.badge--mockup {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.7em;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    background: #fef3c7;
    color: #b45309;
    border: 1px solid #fbbf24;
    margin-left: 6px;
    vertical-align: middle;
}

/* --- Info Grid --- */
.info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
    margin-bottom: 8px;
    font-size: 0.82em;
}

.info-item {
    background-color: #f7f8fa;
    padding: 5px 8px;
    border-radius: 5px;
    min-width: 0; /* prevent grid blowout from long text */
}

.info-item.art-charge {
    grid-column: 1 / -1;
}

.info-item.art-charge .value {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
}

.charge-separator {
    color: #bbb;
}

/* ── Dual Charge Display (Quoted vs Actual) ── */
.charge-line {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.9em;
}
.charge-label {
    font-size: 0.78em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    min-width: 48px;
}
.charge-line--quoted .charge-label { color: #9ca3af; }
.charge-line--quoted .charge-val,
.charge-line--quoted .charge-hrs { color: #6b7280; }
.charge-line--actual .charge-label { color: #0891b2; }
.charge-line--actual .charge-val { color: #0891b2; font-weight: 600; }
.charge-line--actual .charge-hrs { color: #0891b2; }
.charge-val--none { color: #9ca3af !important; font-style: italic; font-weight: 400 !important; }
.charge-sep { color: #d1d5db; }

.info-item .label {
    font-weight: 600;
    font-size: 0.85em;
    color: #888;
    display: block;
    margin-bottom: 2px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.info-item .value {
    color: #1a1a1a;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.info-item .value a {
    color: #007bff;
    font-weight: 600;
}

/* --- Image Gallery --- */
.image-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 6px;
    margin-top: 8px;
}

.image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 6px;
    aspect-ratio: 1 / 1;
    background-color: #f0f1f3;
}

.image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.image-wrapper img:hover {
    transform: scale(1.05);
}

/* --- Card Footer (base container for JS-injected buttons) --- */
.card-footer {
    padding: 0;
    background-color: #f8f9fa;
    border-top: 1px solid #eee;
}

/* --- Image Modal --- */
#imageModal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    align-items: center;
    justify-content: center;
}

#imageModal.show {
    display: flex;
}

#imageModal .modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    background: none;
    border: none;
    box-shadow: none;
    padding: 0;
    border-radius: 0;
    width: auto;
}

#imageModal .close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
}

/* --- Gallery Responsive --- */
@media (max-width: 900px) {
    #gallery-tab .cbColumnarReport {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 768px) {
    #gallery-tab .cbColumnarReport,
    #view-tab .cbColumnarReport {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
    }

    .card-header .company-name {
        font-size: 1.05em;
    }

    .info-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* ==========================================================================
   Gallery Tab — JS-Injected Elements (Status Bar, Quick Actions, Modals)
   Used by: art-hub-steve.js (dynamically created DOM elements)
   ========================================================================== */


/* ---------- Unified Card Footer Buttons ---------- */
.card-footer-buttons {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
    padding: 8px 12px;
    box-sizing: border-box;
}

/* Section row (STATUS, TIME) — label + buttons */
.footer-section {
    display: flex;
    align-items: center;
    gap: 6px;
}

.footer-section-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #9ca3af;
    min-width: 42px;
    flex-shrink: 0;
}

.footer-section-btns {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

/* Bottom info row (Notes + View Details) */
.footer-info-row {
    display: flex;
    align-items: center;
    gap: 6px;
    padding-top: 4px;
    border-top: 1px solid #f0f0f0;
}

.footer-info-separator {
    color: #d1d5db;
    font-size: 10px;
}

.footer-btn {
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    color: white;
    transition: opacity 0.15s, transform 0.15s;
    white-space: nowrap;
}
.footer-btn:hover { opacity: 0.88; transform: translateY(-1px); }
.footer-btn:active { transform: translateY(0); }

.footer-btn--notes    { background: #3b82f6; }
.footer-btn--working  { background: #2563eb; }
.footer-btn--done     { background: #16a34a; }
.footer-btn--approve  { background: #d97706; }

/* View Details — inline text link in info row */
.card-details-link {
    font-size: 11px;
    color: #9ca3af;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.15s;
}
.card-details-link:hover {
    color: var(--art-theme);
}

/* ---------- Status Left Border Colors (All Cards) ---------- */
.card--submitted          { border-left: 3px solid #7c3aed; }
.card--in-progress        { border-left: 3px solid #2563eb; }
.card--awaiting-approval  { border-left: 3px solid #d97706; }
.card--revision-requested { border-left: 3px solid #dc2626; }
.card--approved           { border-left: 3px solid #059669; }
.card--completed          { border-left: 3px solid #22c55e; opacity: 0.8; }
.card--cancel             { border-left: 3px solid #9ca3af; opacity: 0.65; }

/* ---------- Card Hover Lift + Status Glow ---------- */
.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12), 0 4px 10px rgba(0,0,0,0.08);
}
.card--submitted:hover          { box-shadow: 0 8px 25px rgba(124,58,237,0.2); }
.card--in-progress:hover        { box-shadow: 0 8px 25px rgba(37,99,235,0.2); }
.card--awaiting-approval:hover  { box-shadow: 0 8px 25px rgba(217,119,6,0.2); }
.card--revision-requested:hover { box-shadow: 0 8px 25px rgba(220,38,38,0.2); }
.card--approved:hover           { box-shadow: 0 8px 25px rgba(5,150,105,0.2); }
.card--completed:hover          { box-shadow: 0 8px 25px rgba(34,197,94,0.15); }

/* ---------- Staggered Card Entry Animation ---------- */
@keyframes fadeSlideUp {
    from { opacity: 0; transform: translateY(16px); }
    to   { opacity: 1; transform: translateY(0); }
}
.card {
    animation: fadeSlideUp 0.35s ease both;
}

/* ---------- Animated Status Badges ---------- */
@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(217,119,6,0.4); }
    50%      { box-shadow: 0 0 0 6px rgba(217,119,6,0); }
}
@keyframes gentleShake {
    0%, 100% { transform: translateX(0); }
    20%      { transform: translateX(-2px); }
    40%      { transform: translateX(2px); }
    60%      { transform: translateX(-1px); }
    80%      { transform: translateX(1px); }
}
.status-pill--awaiting { animation: pulseGlow 2s ease-in-out infinite; }
.due-pill--overdue     { animation: gentleShake 0.6s ease-in-out; animation-delay: 1s; }

/* ---------- Skeleton Loading ---------- */
@keyframes shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
.skeleton-card {
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    background: white;
    min-height: 220px;
}
.skeleton-header {
    height: 52px;
    background: linear-gradient(90deg, #e5e7eb 25%, #d1d5db 50%, #e5e7eb 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
}
.skeleton-body {
    padding: 14px;
}
.skeleton-line {
    height: 12px;
    border-radius: 4px;
    margin-bottom: 10px;
    background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
}
.skeleton-line--short  { width: 60%; }
.skeleton-line--medium { width: 80%; }
.skeleton-line--long   { width: 95%; }
.skeleton-line--pill   { width: 30%; height: 20px; border-radius: 10px; }

/* ---------- Thread Color Dots ---------- */
.thread-dots {
    display: flex;
    gap: 3px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid #f3f4f6;
}
.thread-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.15);
    flex-shrink: 0;
}
.thread-dots-label {
    font-size: 9px;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-right: 4px;
    font-weight: 600;
}

/* ---------- Modal Overlay ---------- */
.art-modal-overlay {
    position: fixed;
    z-index: 10000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4);
}

/* ---------- Modal Base ---------- */
.art-modal {
    position: fixed;
    z-index: 10001;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
    max-width: 90vw;
    overflow: hidden;
}

.art-modal--sm { width: 360px; }
.art-modal--md { width: 400px; }

/* ---------- Modal Header ---------- */
.art-modal-header {
    color: white;
    padding: 16px 20px;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.art-modal-header--green  { background: #28a745; }
.art-modal-header--orange { background: #e67e22; }

/* ---------- Modal Body ---------- */
.art-modal-body {
    padding: 20px;
}

.art-modal-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

/* ---------- Stepper (Art Time Modal) ---------- */
.stepper-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.stepper-btn {
    width: 36px;
    height: 36px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #f5f5f5;
    font-size: 18px;
    cursor: pointer;
}

.stepper-input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 18px;
    text-align: center;
}

.art-cost-display {
    font-size: 14px;
    color: #666;
    margin-bottom: 16px;
    text-align: center;
}

/* ---------- Modal Actions ---------- */
.art-modal-actions {
    display: flex;
    gap: 10px;
}

.art-modal-actions--spaced {
    margin-top: 12px;
}

.art-modal-btn-cancel {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #f5f5f5;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
}

.art-modal-btn-submit {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    color: white;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
}

.art-modal-btn-submit--green  { background: #28a745; }
.art-modal-btn-submit--orange { background: #e67e22; }

/* ---------- Send Back Textarea ---------- */
.send-back-textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    resize: vertical;
    box-sizing: border-box;
}

/* ---------- Modal Checkbox + Header Badge ---------- */
.art-modal-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #555;
    margin: 12px 0;
    cursor: pointer;
}

.art-modal-checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.art-modal-header-badge {
    font-size: 12px;
    background: rgba(255,255,255,0.25);
    padding: 3px 10px;
    border-radius: 12px;
    font-weight: 600;
}

.art-modal-label--spaced {
    margin-top: 14px;
}

/* ==========================================================================
   Caspio Theme Overrides — Gallery Cards
   Override hardcoded colors in Caspio DataPage CSS to use theme variables
   ========================================================================== */
.card-header {
    background: linear-gradient(145deg, var(--art-theme), var(--art-theme-dark, #006600)) !important;
}

/* Search bar: force inline layout and green button */
/* Caspio injects display:inline-grid + grid placement on children.
   Override to flex so label, input, and button sit in one centered row. */
.cbSearchSpa {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 15px !important;
    overflow: visible !important;
    padding: 15px 20px !important;
}

/* Caspio wraps search form in div[style="display: table;"] — scope override
   to only the form wrapper, not all divs on the page */
#caspioform > div[style="display: table;"] {
    display: block !important;
    width: 100% !important;
}

/* Prevent Caspio block classes from expanding flex children */
.cbSearchSpa .cbFormNestedTableContainer,
.cbSearchSpa .cbSearchButtonContainer {
    flex: 0 0 auto !important;
    width: auto !important;
}

/* Keep label + input side-by-side inside the nested container */
.cbSearchSpa .cbFormNestedTableContainer {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
}

.cbSearchSpa .cbFormLabelCell {
    flex-shrink: 0 !important;
    white-space: nowrap !important;
}

.cbSearchSpa .cbFormFieldCell {
    flex-shrink: 0 !important;
}

.cbSearchSpa input.cbFormTextField {
    width: 200px !important;
    min-width: 200px !important;
    box-sizing: border-box !important;
}

.cbSearchSpa .cbSearchButtonContainer {
    padding: 0 !important;
}

.cbSearchSpa input.cbSearchButton {
    margin: 0 !important;
}

input.cbSearchButton {
    background-color: var(--art-theme) !important;
    border: none !important;
    border-radius: 6px !important;
    color: white !important;
    padding: 0 25px !important;
    font-weight: bold !important;
    cursor: pointer !important;
    height: 42px !important;
    line-height: 42px !important;
    box-sizing: border-box !important;
    font-size: 16px !important;
}

/* =====================================================================
   Send for Approval Modal
   ===================================================================== */
.approval-modal {
    position: fixed;
    z-index: 10001;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
    width: 480px;
    max-width: 90vw;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.approval-modal-header {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.approval-modal-header-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
}

.approval-rev-badge {
    background: rgba(255,255,255,0.25);
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.approval-modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0.8;
}
.approval-modal-close:hover { opacity: 1; }

.approval-modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.approval-company {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.approval-section-label {
    font-size: 13px;
    font-weight: 600;
    color: #555;
    margin-bottom: 8px;
}

/* File thumbnail grid */
.approval-files-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.approval-file-card {
    position: relative;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.approval-file-card:hover {
    border-color: #fcd34d;
}

.approval-file-card.selected {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245,158,11,0.3);
}
.approval-file-card:not(.selected) {
    opacity: 0.55;
}
.approval-file-card:not(.selected):hover {
    opacity: 0.8;
}

.approval-file-card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
}

.approval-file-label {
    font-size: 10px;
    text-align: center;
    padding: 4px;
    background: #f9fafb;
    color: #666;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Hide checkbox input visually but keep accessible */
.mockup-checkbox {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

/* Checkmark badge — visible on selected cards */
.approval-selected-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    background: #f59e0b;
    color: white;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
}
.approval-file-card.selected .approval-selected-badge { display: flex; }

.approval-file-placeholder {
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    font-size: 12px;
}

.approval-no-files {
    background: #fef3c7;
    border: 1px solid #fcd34d;
    border-radius: 8px;
    padding: 14px;
    color: #92400e;
    font-size: 13px;
    text-align: center;
    margin-bottom: 16px;
}

/* ---------- Box File Picker (Send Mockup modal) ---------- */
.box-picker-loading {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px;
    color: #6b7280;
    font-size: 13px;
    justify-content: center;
}

.box-picker-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid #e5e7eb;
    border-top-color: #f59e0b;
    border-radius: 50%;
    animation: box-spin 0.6s linear infinite;
}

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

.box-picker-folder-label {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.box-picker-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-bottom: 16px;
    max-height: 220px;
    overflow-y: auto;
    padding: 2px;
}

.box-file-card {
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    padding: 6px;
    cursor: pointer;
    text-align: center;
    transition: border-color 0.15s, box-shadow 0.15s;
    position: relative;
    background: #fff;
}

.box-file-card:hover {
    border-color: #fbbf24;
    box-shadow: 0 1px 4px rgba(245,158,11,0.15);
}

.box-file-card.selected {
    border-color: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245,158,11,0.3);
    background: #fffbeb;
}

.box-file-card img {
    width: 100%;
    height: 72px;
    object-fit: contain;
    border-radius: 4px;
    background: #f9fafb;
}

.box-file-placeholder {
    width: 100%;
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    border-radius: 4px;
    color: #9ca3af;
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 600;
}

.box-file-name {
    font-size: 11px;
    color: #374151;
    margin-top: 4px;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.box-file-meta {
    font-size: 10px;
    color: #9ca3af;
    margin-top: 2px;
}

.box-file-check {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    background: #f59e0b;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}

.box-file-card.selected .box-file-check {
    display: flex;
}

.box-file-ext-badge {
    position: absolute;
    bottom: 46px;
    right: 4px;
    background: rgba(0,0,0,0.7);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    padding: 1px 5px;
    border-radius: 3px;
    letter-spacing: 0.3px;
    line-height: 1.4;
    pointer-events: none;
}

.box-picker-empty {
    background: #fef3c7;
    border: 1px solid #fcd34d;
    border-radius: 8px;
    padding: 14px;
    color: #92400e;
    font-size: 13px;
    text-align: center;
    margin-bottom: 12px;
}

.box-picker-error {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 8px;
    padding: 14px;
    color: #991b1b;
    font-size: 13px;
    text-align: center;
    margin-bottom: 12px;
}

.box-paste-fallback {
    margin-bottom: 16px;
}

.box-paste-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 13px;
    font-family: inherit;
    box-sizing: border-box;
}

.box-paste-input:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245,158,11,0.2);
}

/* Previously Sent section (smaller cards) */
.approval-files-grid--small {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 8px;
    margin-bottom: 16px;
}

.approval-files-grid--small .approval-file-card {
    opacity: 0.7;
    padding: 4px;
    cursor: pointer;
}
.approval-files-grid--small .approval-file-card:hover {
    opacity: 1;
    border-color: #fcd34d;
}
.approval-files-grid--small .approval-file-card.selected {
    opacity: 1;
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245,158,11,0.3);
}
.approval-files-grid--small .approval-file-card img {
    height: 56px;
}
.approval-file-check {
    display: none;
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #f59e0b;
    color: #fff;
    font-size: 12px;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}
.approval-file-card.selected .approval-file-check {
    display: flex;
}

.approval-section-label--muted {
    color: #9ca3af;
    font-size: 11px;
}

.approval-modal-body textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 16px;
    box-sizing: border-box;
}
.approval-modal-body textarea:focus {
    outline: none;
    border-color: #f59e0b;
    box-shadow: 0 0 0 2px rgba(245,158,11,0.2);
}

.approval-time-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #f9fafb;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}

.approval-time-input {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.approval-time-input label {
    font-size: 13px;
    font-weight: 500;
    color: #555;
    white-space: nowrap;
}

.approval-time-input input[type="number"] {
    width: 70px;
    padding: 6px 8px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    text-align: center;
}

.approval-cost {
    font-size: 14px;
    font-weight: 600;
    color: #b45309;
    white-space: nowrap;
}

.approval-modal-footer {
    padding: 14px 20px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.approval-btn-cancel {
    flex: 1;
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    background: #f5f5f5;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
}
.approval-btn-cancel:hover { background: #e5e7eb; }

.approval-btn-submit {
    flex: 2;
    padding: 10px;
    border: none;
    border-radius: 6px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: opacity 0.2s;
}
.approval-btn-submit:hover { opacity: 0.9; }
.approval-btn-submit:disabled { opacity: 0.5; cursor: not-allowed; }

/* ---------- Recipient + CC Row ---------- */
.approval-recipient {
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 13px;
    color: #065f46;
    margin-bottom: 12px;
}

.approval-cc-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 13px;
    flex-wrap: wrap;
}

.approval-cc-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
    color: #555;
    cursor: pointer;
    white-space: nowrap;
}

.approval-cc-label input[type="checkbox"] {
    width: 15px;
    height: 15px;
    cursor: pointer;
}

.approval-cc-checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.approval-cc-rep-label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    color: #374151;
    cursor: pointer;
}

.approval-cc-rep-label input[type="checkbox"] {
    width: 14px;
    height: 14px;
    cursor: pointer;
}

.approval-cc-rep-label input[type="checkbox"]:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

/* ---------- Hint Text ---------- */
.approval-hint {
    font-size: 12px;
    color: #9ca3af;
    font-style: italic;
    margin-bottom: 8px;
    margin-top: -4px;
}

/* ---------- Art Time Section (Send Mockup modal) ---------- */
.approval-time-section {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 14px;
}

.approval-time-section .approval-section-label {
    margin-bottom: 10px;
}

.approval-prev-time {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 10px;
}

.approval-session-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.approval-session-row label {
    font-size: 13px;
    font-weight: 500;
    color: #555;
    white-space: nowrap;
}

.stepper-row--inline {
    display: flex;
    align-items: center;
    gap: 6px;
}

.stepper-input--sm {
    width: 60px;
    padding: 6px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 15px;
    text-align: center;
}

.approval-new-total {
    font-size: 14px;
    font-weight: 600;
    color: #059669;
    padding-top: 10px;
    border-top: 1px dashed #d1d5db;
}

/* ---------- Time Log Button ---------- */
.footer-btn--timelog { background: #64748b; }
.footer-btn--timelog:hover { background: #475569; }

/* ---------- Time Log Modal ---------- */
.art-modal--timelog { width: 420px; max-height: 80vh; display: flex; flex-direction: column; }
.art-modal--timelog .art-modal-body { overflow-y: auto; flex: 1; }
.art-modal-header--slate { background: #64748b; }
.time-log-company { font-size: 0.85em; opacity: 0.85; margin-top: 2px; }
.time-log-summary {
    background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 8px;
    padding: 10px 14px; margin-bottom: 14px; text-align: center;
    font-weight: 600; color: #166534; font-size: 0.95em;
}
.time-log-entry {
    background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 8px;
    padding: 10px 12px; margin-bottom: 8px;
}
.time-log-entry-header {
    display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px;
}
.time-log-badge {
    font-size: 0.72em; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em;
    padding: 2px 8px; border-radius: 4px; color: white;
}
.time-log-badge--logtime { background: #0891b2; }
.time-log-badge--completion { background: #28a745; }
.time-log-badge--mockup { background: #f59e0b; }
.time-log-badge--default { background: #9ca3af; }
.time-log-date { font-size: 0.8em; color: #6b7280; }
.time-log-detail { font-size: 0.9em; color: #1e293b; font-weight: 500; }
.time-log-desc { font-size: 0.82em; color: #6b7280; margin-top: 3px; }
.time-log-running { font-size: 0.78em; color: #9ca3af; margin-top: 4px; }
.time-log-negative .time-log-detail { color: #dc2626; }
.time-log-empty { text-align: center; color: #9ca3af; font-style: italic; padding: 24px 0; }

/* ---------- Reopen Button (completed cards) ---------- */
.footer-btn--reopen { background: #f59e0b; }
.footer-btn--reopen:hover { background: #d97706; }

/* ---------- Log Time Button ---------- */
.footer-btn--logtime { background: #0891b2; }

/* ---------- Log Time Modal Overrides ---------- */
.art-modal-header--teal { background: #0891b2; }
.art-modal-btn-submit--teal { background: #0891b2; }

.art-prev-time {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 12px;
}

.art-new-total {
    font-size: 14px;
    font-weight: 600;
    color: #059669;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #d1d5db;
}

.art-modal-note-input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 13px;
    font-family: inherit;
    box-sizing: border-box;
}

@media (max-width: 768px) {
    .approval-modal { width: 95vw; }
    .approval-time-row { flex-direction: column; align-items: flex-start; }
    .approval-session-row { flex-wrap: wrap; }
    .approval-cc-row { flex-direction: column; align-items: flex-start; }
}

/* ========== Art Notification Toasts ========== */
#art-notif-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10010;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 400px;
    pointer-events: none;
}

.art-notif-toast {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-left: 4px solid #28a745;
    transform: translateX(120%);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    cursor: pointer;
    pointer-events: auto;
}

.art-notif-toast.show {
    transform: translateX(0);
    opacity: 1;
}

.art-notif-toast.removing {
    transform: translateX(120%);
    opacity: 0;
}

.art-notif-toast-content {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
}

.art-notif-toast-icon {
    font-size: 20px;
    flex-shrink: 0;
    line-height: 1;
}

.art-notif-toast-text {
    flex: 1;
    font-size: 13px;
    line-height: 1.4;
    color: #333;
}

.art-notif-toast-close {
    background: none;
    border: none;
    font-size: 18px;
    color: #999;
    cursor: pointer;
    padding: 0 2px;
    line-height: 1;
    flex-shrink: 0;
}

.art-notif-toast-close:hover {
    color: #333;
}

@media (max-width: 600px) {
    #art-notif-container {
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

/* ── Detail Form Styling (Semantic Markup) ─────────────────────────── */

.art-detail-form {
    max-width: 820px;
    margin: 0 auto;
    padding: 12px 0 20px;
}

/* Override Caspio's inline-grid — switch to block flow so section headers work naturally */
.art-detail-form section[data-cb-name="cbTable"] {
    display: block !important;
    width: 100% !important;
}

/* 3-column rows: nested containers that share a grid row display inline */
.art-detail-form .cbFormNestedTableContainer {
    display: inline-block;
    vertical-align: top;
    box-sizing: border-box;
}
/* Default: each nested container takes ~1/3 width for 3-col rows */
.art-detail-form .cbFormNestedTableContainer:not(.detail-full-row) {
    width: 33.33%;
}
/* Full-width single-column items */
.art-detail-form .detail-full-row {
    display: block !important;
    width: 100% !important;
}
.art-detail-form .detail-file-grid.detail-full-row {
    display: flex !important;
}

/* Left-label kv pairs: flex row containers */
.art-detail-form .detail-kv-row {
    display: flex;
    align-items: baseline;
    width: 100%;
    border-bottom: 1px solid #f1f5f9;
    min-height: 32px;
}
.art-detail-form .detail-kv-label {
    width: 160px;
    flex-shrink: 0;
    box-sizing: border-box;
}
.art-detail-form .detail-kv-value {
    flex: 1;
    box-sizing: border-box;
}

/* Section headers injected by JS — must span full grid in Caspio's inline-grid section */
.detail-section-header {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, #f0f4f8, #e8ecf1);
    padding: 10px 16px;
    font-weight: 700;
    font-size: 12px;
    color: #334155;
    border-left: 3px solid var(--art-theme, #009900);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin: 20px 0 6px;
    border-radius: 0 6px 6px 0;
}

.detail-section-header:first-child,
.art-detail-form section > .detail-section-header:first-child {
    margin-top: 4px;
}

.detail-section-header i {
    margin-right: 8px;
    color: var(--art-theme, #009900);
    font-size: 13px;
    width: 16px;
    text-align: center;
}

/* ── Nested field containers (3-column rows: Company/Due/Rep etc.) ── */
.art-detail-form .cbFormNestedTableContainer {
    padding: 6px 8px;
    border-bottom: 1px solid #f1f5f9;
}

.art-detail-form .cbFormNestedTableContainer .cbFormLabelCell {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    padding-bottom: 3px;
}

.art-detail-form .cbFormNestedTableContainer .cbFormLabelCell i {
    color: var(--art-theme, #009900);
    margin-right: 5px;
    font-size: 12px;
    width: 14px;
    text-align: center;
}

.art-detail-form .cbFormNestedTableContainer .cbFormFieldCell {
    padding: 2px 0 4px;
}

/* Inputs inside nested containers */
.art-detail-form .cbFormFieldCell input[type="text"],
.art-detail-form .cbFormFieldCell input[type="number"],
.art-detail-form .cbFormFieldCell select {
    width: 100%;
    padding: 7px 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    color: #1e293b;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.art-detail-form .cbFormFieldCell input[type="text"]:focus,
.art-detail-form .cbFormFieldCell input[type="number"]:focus,
.art-detail-form .cbFormFieldCell select:focus {
    border-color: var(--art-theme, #009900);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 153, 0, 0.12);
}

.art-detail-form .cbFormFieldCell textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    color: #1e293b;
    min-height: 70px;
    resize: vertical;
    font-family: inherit;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.art-detail-form .cbFormFieldCell textarea:focus {
    border-color: var(--art-theme, #009900);
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 153, 0, 0.12);
}

/* Static data display */
.art-detail-form .cbFormDataCell .cbFormData,
.art-detail-form .cbFormDataCellNumberDate .cbFormData {
    font-size: 14px;
    color: #1e293b;
    padding: 5px 0;
    display: inline-block;
}

/* Standalone data cells (not inside nested containers) should be block-level */
.art-detail-form > section > .cbFormDataCell:not(.detail-kv-value),
.art-detail-form > section > .cbFormDataCellNumberDate:not(.detail-kv-value) {
    display: block;
    width: 100%;
}

/* ── Left-label key-value rows (Order Type, Garment info, etc.) ── */
.art-detail-form .detail-kv-label {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    padding: 7px 12px;
}

.art-detail-form .detail-kv-label i {
    color: #94a3b8;
    margin-right: 6px;
    font-size: 12px;
    width: 14px;
    text-align: center;
}

.art-detail-form .detail-kv-value {
    font-size: 14px;
    color: #1e293b;
    padding: 7px 12px;
}

/* Hover effect on kv pairs */
.art-detail-form .detail-kv-row:hover {
    background: #f8fafc;
}

/* ── Status badge ── */
.art-detail-form .detail-status-badge.detail-status-badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.status-submitted {
    background: #ede9fe;
    color: #6b21a8;
}

.status-in-progress {
    background: #dbeafe;
    color: #1e40af;
}

.status-awaiting-approval {
    background: #fef3c7;
    color: #92400e;
}

.status-completed {
    background: #dcfce7;
    color: #166534;
}

.status-revision-requested {
    background: #fed7aa;
    color: #9a3412;
}

.status-cancelled {
    background: #fee2e2;
    color: #991b1b;
}

/* ── Hidden rows (empty garment groups, empty file slots) ── */
.detail-hidden-row,
.art-detail-form .detail-hidden-row.detail-full-row {
    display: none !important;
}

/* ── Swatch thumbnails ── */
.detail-swatch-img {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    border: 1px solid #d1d5db;
    object-fit: cover;
    vertical-align: middle;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

/* ── Garment model images ── */
.detail-garment-img {
    width: 100px;
    height: auto;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    cursor: pointer;
    transition: transform 0.15s, box-shadow 0.15s;
    vertical-align: middle;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    margin: 4px 0;
}

.detail-garment-img:hover {
    transform: scale(1.06);
    box-shadow: 0 4px 14px rgba(0,0,0,0.15);
}

/* ── Garment group cards (swatch + image + style/color inline) ── */
.art-detail-form .garment-card {
    display: flex !important;
    align-items: center;
    gap: 14px;
    padding: 10px 12px;
    border-bottom: 1px solid #f1f5f9;
}

.garment-card:hover {
    background: #f8fafc;
}

.garment-card-images {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.garment-card-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: 14px;
    color: #1e293b;
}

.garment-card-info .garment-card-label {
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-right: 6px;
}

/* ── File upload containers (original Caspio) ── */
.art-detail-form [class*="cbFormBlock"] img[width="200"],
.art-detail-form .cbFormNestedTableContainer img {
    max-width: 180px;
    height: auto;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    margin: 4px 0;
}

/* ── File upload grid (2x2 layout) ── */
.detail-file-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 12px;
}
.detail-file-card {
    flex: 0 0 calc(50% - 6px);
    box-sizing: border-box;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px;
    text-align: center;
    background: #fafbfc;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}
.detail-file-card.detail-file-empty {
    border-style: dashed;
    background: #f8fafc;
    color: #94a3b8;
}
.detail-file-name {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.detail-file-thumb {
    max-width: 100% !important;
    max-height: 150px !important;
    width: auto !important;
    height: auto !important;
    border-radius: 6px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06) !important;
    object-fit: contain;
    cursor: pointer;
}
.detail-file-download {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 4px;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    color: var(--art-theme, #009900);
    text-decoration: none;
    border: 1px solid var(--art-theme, #009900);
    border-radius: 6px;
    transition: background 0.15s;
}
.detail-file-download:hover {
    background: rgba(0, 153, 0, 0.06);
    text-decoration: none;
}
.detail-file-remove {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    color: #94a3b8;
    cursor: pointer;
    margin-top: 2px;
}
.detail-file-remove:hover {
    color: #ef4444;
}
.detail-file-upload {
    margin-top: 4px;
}
.detail-file-upload input[type="file"] {
    font-size: 11px;
    max-width: 100%;
}

/* File remove checkbox */
.art-detail-form input[type="checkbox"] {
    accent-color: var(--art-theme, #009900);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* ── UPDATE/BACK buttons ── */
.art-detail-form .cbBackButtonContainer {
    padding: 16px 8px;
    margin-top: 12px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    gap: 8px;
    justify-content: center;
}

.art-detail-form .cbUpdateButton,
.art-detail-form .cbBackButton {
    padding: 9px 28px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: 1px solid transparent;
    transition: background 0.15s, box-shadow 0.15s;
}

.art-detail-form .cbUpdateButton {
    background: var(--art-theme, #009900);
    color: #fff;
    border-color: var(--art-theme, #009900);
}

.art-detail-form .cbUpdateButton:hover {
    background: #007a00;
    box-shadow: 0 2px 8px rgba(0, 153, 0, 0.25);
}

.art-detail-form .cbBackButton {
    background: #f1f5f9;
    color: #334155;
    border-color: #d1d5db;
}

.art-detail-form .cbBackButton:hover {
    background: #e2e8f0;
}

/* Download PDF / Report links at top */
.art-detail-form .cbFormDownloadDetailsLink,
.art-detail-form .cbFormBackToReportActionLink {
    font-size: 13px;
    color: var(--art-theme, #009900);
    text-decoration: none;
    font-weight: 500;
}

.art-detail-form .cbFormDownloadDetailsLink:hover,
.art-detail-form .cbFormBackToReportActionLink:hover {
    text-decoration: underline;
}

/* Record navigation at bottom */
.art-detail-form .cbResultSetPaging,
.art-detail-form [class*="cbResultSet"] {
    font-size: 13px;
    color: #64748b;
    padding: 8px;
}

/* ── Responsive detail form ── */
@media (max-width: 768px) {
    .art-detail-form {
        max-width: 100%;
        padding: 8px 4px;
    }

    .art-detail-form .detail-kv-label {
        display: block;
        min-width: 0;
        padding-bottom: 2px;
        border-bottom: none;
    }

    .art-detail-form .detail-kv-value {
        display: block;
        padding-top: 0;
    }

    .art-detail-form .cbFormFieldCell input[type="text"],
    .art-detail-form .cbFormFieldCell input[type="number"],
    .art-detail-form .cbFormFieldCell select,
    .art-detail-form .cbFormFieldCell textarea {
        max-width: 100%;
    }

    .detail-garment-img {
        width: 80px;
    }

    .detail-section-header {
        margin: 14px 0 4px;
        padding: 8px 12px;
        font-size: 11px;
    }
}


/* ==========================================================================
   AE Art Request Cards — "My Art Requests" tab
   ========================================================================== */

.ae-art-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.ae-art-card {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08), 0 2px 8px rgba(0,0,0,0.04);
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.15s;
}

.ae-art-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.12), 0 2px 6px rgba(0,0,0,0.06);
    transform: translateY(-2px);
}

/* -- Card image -- */
.ae-art-card__image {
    position: relative;
    min-height: 120px;
    max-height: 320px;
    overflow: hidden;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ae-art-card__image img {
    width: 100%;
    max-height: 320px;
    object-fit: contain;
}

.ae-art-card__placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 120px;
    gap: 8px;
    color: #d1d5db;
}
.ae-art-card__placeholder-text {
    font-size: 11px;
    color: #d1d5db;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Shimmer loading effect while Box images load */
.ae-art-card__image--loading {
    background: linear-gradient(90deg, #f3f4f6 25%, #e5e7eb 50%, #f3f4f6 75%);
    background-size: 200% 100%;
    animation: ae-shimmer 1.5s infinite;
}
@keyframes ae-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* -- Image source label overlay -- */
.ae-art-card__image-label {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    z-index: 1;
}
.ae-art-card__image-label--mockup {
    background: rgba(5, 150, 105, 0.9);
    color: white;
}
.ae-art-card__image-label--artwork {
    background: rgba(107, 114, 128, 0.85);
    color: white;
}

/* -- File type badge for non-renderable files -- */
.ae-art-card__file-badge {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 120px;
}
.ae-art-card__file-ext {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: white;
}

/* -- Rep name line -- */
.ae-art-card__rep {
    font-size: 12px;
    color: #9ca3af;
    margin-top: -4px;
    margin-bottom: 6px;
}

/* -- Card body -- */
.ae-art-card__body {
    padding: 14px 16px 10px;
}

.ae-art-card__header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 8px;
}

.ae-art-card__company {
    font-weight: 600;
    font-size: 15px;
    color: #1f2937;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.ae-art-card__design-num {
    font-size: 13px;
    color: #6b7280;
    font-weight: 500;
    white-space: nowrap;
}

/* -- Status badge -- */
.ae-art-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.ae-art-card__status {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
}

.ae-status--completed {
    background: #dcfce7;
    color: #166534;
}

.ae-status--progress {
    background: #dbeafe;
    color: #1e40af;
}

.ae-status--awaiting {
    background: #fef3c7;
    color: #92400e;
}

.ae-status--revision {
    background: #fce7f3;
    color: #9d174d;
}

.ae-status--submitted {
    background: #f3f4f6;
    color: #4b5563;
}

.ae-status--cancelled {
    background: #fee2e2;
    color: #991b1b;
}

/* -- Type badge -- */
.ae-art-card__type {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.ae-art-card__type--mockup {
    background: #fef3c7;
    color: #92400e;
}

.ae-art-card__type--new {
    background: #ede9fe;
    color: #5b21b6;
}

/* -- Revision badge -- */
.ae-art-card__rev-badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    background: #fef3c7;
    color: #b45309;
    border: 1px solid #f59e0b;
}

/* -- Billing row -- */
.ae-art-card__billing {
    display: flex;
    justify-content: space-between;
    padding: 6px 0 0;
    margin-top: 6px;
    border-top: 1px solid #f3f4f6;
    font-size: 12px;
}
.ae-art-card__billing-quoted {
    color: #6b7280;
}
.ae-art-card__billing-actual {
    color: #059669;
    font-weight: 600;
}

/* -- Details row (due date, order #) -- */
.ae-art-card__details {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
    margin-bottom: 4px;
}

.ae-art-card__detail {
    font-size: 13px;
    color: #6b7280;
}

/* -- Card footer -- */
.ae-art-card__footer {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    border-top: 1px solid #f3f4f6;
    background: #fafafa;
}

.ae-art-card__link {
    font-size: 13px;
    color: var(--art-theme, #981e32);
    text-decoration: none;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.15s;
}

.ae-art-card__link:hover {
    color: var(--art-theme-hover, #7a1828);
    text-decoration: underline;
}

.ae-art-card__link--primary {
    font-weight: 600;
}

.ae-art-card__actions {
    display: flex;
    gap: 12px;
    margin-left: auto;
}

/* -- Responsive -- */
@media (max-width: 680px) {
    .ae-art-grid {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 14px 0;
    }
}

/* ── AE Dashboard Lightbox ───────────────────────────── */
.ae-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ae-lightbox-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.85);
}

.ae-lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ae-lightbox-close {
    position: absolute;
    top: -40px;
    right: -10px;
    background: none;
    border: none;
    color: white;
    font-size: 32px;
    cursor: pointer;
    line-height: 1;
    padding: 4px 8px;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.ae-lightbox-close:hover { opacity: 1; }

.ae-lightbox-img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 4px;
}

.ae-lightbox-label {
    color: rgba(255,255,255,0.85);
    font-size: 14px;
    margin-top: 12px;
    text-align: center;
}

/* ── Review Card Context (revision badge, timestamp, notes preview) ── */
.ae-art-card__rev-badge {
    display: inline-block;
    background: #d97706;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 1px 6px;
    border-radius: 9px;
    margin-left: 6px;
    vertical-align: middle;
}
.ae-art-card__sent {
    font-size: 12px;
    color: #9ca3af;
    margin-left: 8px;
}
.ae-art-card__notes-preview {
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
    padding: 4px 12px 0;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.4;
}

/* ── Tab Count Badges ────────────────────────────────────────────── */
.ae-tab-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    margin-left: 6px;
    border-radius: 9px;
    background: #dc2626;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    vertical-align: middle;
}

/* ── Mark Complete Warning Banner ────────────────────────────────── */
.art-modal-warning {
    background: #fef3cd;
    color: #856404;
    border-left: 4px solid #d97706;
    padding: 10px 14px;
    margin-bottom: 12px;
    border-radius: 4px;
    font-size: 13px;
    line-height: 1.5;
}

/* ── Share with Customer Button ─────────────────────────────────── */
.ard-btn-share-customer {
    background: #3b82f6;
    color: #fff;
    border: none;
    padding: 8px 18px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}
.ard-btn-share-customer:hover { background: #2563eb; }
.ard-btn-share-customer:disabled { opacity: 0.6; cursor: not-allowed; }

/* ── Share with Customer Modal ──────────────────────────────────── */
.share-customer-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    width: 480px;
    max-width: 94vw;
    max-height: 90vh;
    overflow-y: auto;
    z-index: 10001;
}
.share-customer-modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff;
    border-radius: 12px 12px 0 0;
    font-size: 16px;
    font-weight: 700;
}
.share-customer-modal__close {
    background: none;
    border: none;
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
}
.share-customer-modal__body {
    padding: 20px;
}
.share-customer-modal__field {
    margin-bottom: 14px;
}
.share-customer-modal__field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.share-customer-modal__input {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}
.share-customer-modal__input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
}
.share-customer-modal__textarea {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    box-sizing: border-box;
}
.share-customer-modal__textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
}
.share-customer-modal__preview {
    text-align: center;
    margin-bottom: 14px;
}
.share-customer-modal__preview-label {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}
.share-customer-modal__preview img {
    max-width: 100%;
    max-height: 200px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}
.share-customer-modal__rep-info {
    font-size: 12px;
    color: #9ca3af;
    text-align: center;
    padding-top: 8px;
    border-top: 1px solid #f3f4f6;
}
.share-customer-modal__footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 14px 20px;
    border-top: 1px solid #e5e7eb;
}
.share-customer-modal__btn-cancel {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
    padding: 9px 20px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
}
.share-customer-modal__btn-cancel:hover { background: #e5e7eb; }
.share-customer-modal__btn-send {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff;
    border: none;
    padding: 9px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.15s;
}
.share-customer-modal__btn-send:hover { opacity: 0.9; }
.share-customer-modal__btn-send:disabled { opacity: 0.6; cursor: not-allowed; }

/* ── Audit Badge (gallery card indicator) ── */
.audit-badge {
    display: inline-block;
    font-size: 9px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 3px;
    margin-left: 6px;
    vertical-align: middle;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}
.audit-badge--green { background: #ecfdf5; color: #059669; border: 1px solid #059669; }
.audit-badge--red { background: #fef2f2; color: #dc2626; border: 1px solid #dc2626; }
.audit-badge--amber { background: #fffbeb; color: #d97706; border: 1px solid #d97706; }

/* ── AE Gallery View (maroon theme overrides for shared DataPage) ── */

/* Card header gradient — use maroon variables */
.ae-gallery-view .card-header {
    background: linear-gradient(145deg, var(--art-theme), var(--art-theme-dark, #7a1828)) !important;
    border-bottom: 2px solid #7a1828;
}

/* Completed card left border */
.ae-gallery-view .card--completed { border-left-color: #981e32; }

/* View Details link */
.ae-gallery-view .card-details-link { color: #981e32; }
.ae-gallery-view .card-details-link:hover { color: #7a1828; }

/* Footer layout — space between when Reopen exists, centered otherwise */
.ae-gallery-view .footer-info-row {
    justify-content: center;
    padding: 10px 0;
    gap: 10px;
}
.card-reopen-btn {
    background: #f59e0b;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 5px 14px;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.card-reopen-btn:hover {
    background: #d97706;
}

/* Hide Caspio search download link on AE (cleaner look) */
.ae-gallery-view .cbResultSetDownloadLink { display: none !important; }

/* --- Art AE Gallery Cards (Steve Mockups - API-driven) --- */
.art-card .card-status-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 6px;
}

.card-due {
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 4px;
    background: #f3f4f6;
    color: #4b5563;
}
.card-due--overdue {
    background: #fef2f2;
    color: #dc2626;
    font-weight: 700;
}
.card-due--today {
    background: #fff7ed;
    color: #d97706;
    font-weight: 700;
}
.card-due--soon {
    background: #fffbeb;
    color: #b45309;
}

.card-meta-row {
    font-size: 13px;
    color: #374151;
    padding: 2px 0;
}
.card-meta-label {
    font-size: 10px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-right: 6px;
}

.card-art-charge {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #f3f4f6;
    font-size: 12px;
    color: #6b7280;
}
.card-art-label {
    font-size: 10px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.card-art-row {
    padding: 1px 0;
}
.card-art-quoted {
    font-size: 10px;
    font-weight: 600;
    color: #9ca3af;
    margin-right: 4px;
}
.card-art-actual {
    font-size: 10px;
    font-weight: 600;
    color: #059669;
    margin-right: 4px;
}

/* ==========================================================================
   Kanban Board View
   Toggle between grid (default) and board (kanban) layouts.
   Used by: art-hub-steve.html, art-hub-ruth.html
   ========================================================================== */

/* ---------- View Toggle ---------- */
.view-toggle {
    display: inline-flex;
    gap: 0;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    overflow: hidden;
    margin-left: auto;
}
.view-toggle-btn {
    padding: 7px 14px;
    font-size: 13px;
    font-weight: 600;
    border: none;
    background: white;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
    font-family: inherit;
}
.view-toggle-btn:not(:last-child) {
    border-right: 1px solid #d1d5db;
}
.view-toggle-btn:hover {
    background: #f3f4f6;
}
.view-toggle-btn.active {
    background: var(--art-theme);
    color: white;
    border-color: var(--art-theme);
}
.view-toggle-icon {
    font-size: 14px;
    line-height: 1;
}

/* Kanban styles moved to /shared_components/css/kanban.css */
