/* Dexpix Color Palette Generator v3.0 */

:root {
  --dp: #1b5e8c;
  --dpd: #134a6e;
  --dpl: #e8f4fd;
  --dpt: #1e293b;
  --dpm: #64748b;
  --dpbg: #f8fafc;
  --dpw: #ffffff;
  --dpb: #e2e8f0;
  --dp-success: #10b981;
  --dp-warning: #f59e0b;
  --dp-error: #ef4444;
  --dp-body: #475569;
  --dp-shadow: 0 1px 3px rgba(0,0,0,0.06);
  --dp-shadow-hover: 0 8px 25px rgba(27,94,140,0.12);
  --dp-transition: 0.2s ease;
}

.pl-app *,
.pl-app *::before,
.pl-app *::after { box-sizing: border-box; margin: 0; padding: 0; }
.pl-app { font-family: system-ui, -apple-system, sans-serif; color: var(--dpt); background: var(--dpbg); padding: 32px 16px 48px; -webkit-font-smoothing: antialiased; outline: none; }

.pl-header { text-align: center; margin-bottom: 32px; max-width: 1100px; margin-left: auto; margin-right: auto; }
.pl-header h2 { font-size: 22px; font-weight: 600; color: var(--dpt); margin-bottom: 8px; }
.pl-header p { color: var(--dp-body); font-size: 16px; line-height: 1.75; }

.pl-layout { display: grid; grid-template-columns: 1fr 320px; gap: 24px; max-width: 1100px; margin: 0 auto; }
@media (max-width: 900px) { .pl-layout { grid-template-columns: 1fr; } }

.pl-card { background: var(--dpw); border: 1px solid var(--dpb); border-radius: 12px; padding: 20px; box-shadow: var(--dp-shadow); }
.pl-card-title { font-size: 14px; font-weight: 600; color: var(--dpt); margin-bottom: 14px; }
.pl-section-label { font-size: 12px; font-weight: 600; color: var(--dpm); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 10px; display: flex; align-items: center; gap: 6px; }
.pl-section-hint { font-weight: 400; text-transform: none; letter-spacing: 0; opacity: 0.7; }
.pl-main-panel { background: var(--dpw); border: 1px solid var(--dpb); border-radius: 12px; padding: 24px; box-shadow: var(--dp-shadow); }

/* Spacebar hint */
.pl-space-hint { text-align: center; padding: 8px; margin-bottom: 14px; background: var(--dpl); border-radius: 8px; font-size: 13px; color: var(--dp); font-weight: 500; }
.pl-space-hint kbd { display: inline-block; padding: 2px 8px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 4px; font-size: 12px; font-weight: 600; box-shadow: 0 1px 0 var(--dpb); }

/* Controls */
.pl-controls-row { display: flex; align-items: center; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.pl-action-btn { padding: 5px 12px; background: var(--dp); border: none; border-radius: 6px; color: #fff; font-family: system-ui, sans-serif; font-size: 12px; font-weight: 500; cursor: pointer; transition: background var(--dp-transition); }
.pl-action-btn:hover { background: var(--dpd); }
.pl-outline-btn { padding: 5px 12px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 6px; font-family: system-ui, sans-serif; font-size: 12px; font-weight: 500; color: var(--dpt); cursor: pointer; transition: all var(--dp-transition); }
.pl-outline-btn:hover { border-color: var(--dp); color: var(--dp); }
.pl-reset-btn { padding: 5px 12px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 6px; color: var(--dpt); font-family: system-ui, sans-serif; font-size: 12px; font-weight: 500; cursor: pointer; transition: all var(--dp-transition); margin-left: auto; }
.pl-reset-btn:hover { border-color: var(--dp-error); color: var(--dp-error); }

/* Style tabs */
.pl-style-tabs { display: flex; gap: 3px; flex-wrap: wrap; margin-bottom: 14px; }
.pl-style-tab { padding: 5px 10px; background: var(--dpbg); border: 1px solid var(--dpb); border-radius: 6px; font-family: system-ui, sans-serif; font-size: 12px; font-weight: 500; color: var(--dpm); cursor: pointer; transition: all var(--dp-transition); }
.pl-style-tab:hover { border-color: var(--dp); }
.pl-style-tab.active { background: var(--dp); color: #fff; border-color: var(--dp); }

/* Palette strip */
.pl-palette-strip { display: flex; border-radius: 12px; overflow: hidden; border: 1px solid var(--dpb); margin-bottom: 6px; }
.pl-palette-color { flex: 1; min-height: 110px; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding: 6px 2px; cursor: pointer; transition: flex 0.3s ease; position: relative; }
.pl-palette-color:hover { flex: 1.4; }
.pl-palette-role { font-size: 9px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; padding: 2px 5px; border-radius: 3px; margin-bottom: 3px; white-space: nowrap; }
.pl-palette-hex { font-family: 'Courier New', monospace; font-size: 10px; font-weight: 600; padding: 2px 5px; border-radius: 3px; margin-bottom: 3px; }
.pl-palette-lock { background: none; border: none; font-size: 13px; cursor: pointer; opacity: 0.5; transition: opacity 0.2s; padding: 2px; }
.pl-palette-lock:hover { opacity: 1; }
.pl-palette-lock.locked { opacity: 1; }
.pl-palette-copied { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 11px; font-weight: 600; color: #fff; background: rgba(0,0,0,0.5); padding: 3px 8px; border-radius: 6px; pointer-events: none; display: none; }

/* Per-color editor */
.pl-color-editor { background: var(--dpbg); border: 1px solid var(--dpb); border-radius: 8px; padding: 12px; margin-bottom: 14px; display: none; }
.pl-color-editor.active { display: block; }
.pl-editor-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.pl-editor-title { font-size: 12px; font-weight: 600; color: var(--dpt); }
.pl-editor-close { background: none; border: none; font-size: 16px; cursor: pointer; color: var(--dpm); }
.pl-editor-row { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.pl-editor-row:last-child { margin-bottom: 0; }
.pl-editor-label { font-size: 11px; font-weight: 600; color: var(--dpm); width: 14px; }
.pl-editor-slider { flex: 1; -webkit-appearance: none; appearance: none; height: 4px; background: var(--dpb); border-radius: 4px; outline: none; cursor: pointer; }
.pl-editor-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--dp); border: 2px solid var(--dpw); box-shadow: 0 1px 2px rgba(0,0,0,0.15); }
.pl-editor-slider::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--dp); border: 2px solid var(--dpw); }
.pl-editor-val { font-family: 'Courier New', monospace; font-size: 11px; font-weight: 600; color: var(--dpt); width: 30px; text-align: right; }

/* Context preview */
.pl-tpl-tabs { display: flex; gap: 3px; margin-bottom: 8px; flex-wrap: wrap; }
.pl-tpl-tab { padding: 4px 8px; background: var(--dpbg); border: 1px solid var(--dpb); border-radius: 6px; font-family: system-ui, sans-serif; font-size: 11px; font-weight: 500; color: var(--dpm); cursor: pointer; transition: all var(--dp-transition); }
.pl-tpl-tab:hover { border-color: var(--dp); }
.pl-tpl-tab.active { background: var(--dp); color: #fff; border-color: var(--dp); }
.pl-context { border: 1px solid var(--dpb); border-radius: 12px; overflow: hidden; margin-bottom: 4px; }
.pl-ctx-page { padding: 12px; animation: plFadeIn 0.3s ease; font-family: system-ui, sans-serif; }
@keyframes plFadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

/* Color legend */
.pl-color-legend { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 14px; }
.pl-legend-item { display: flex; align-items: center; gap: 3px; font-size: 9px; font-weight: 600; color: var(--dpm); text-transform: uppercase; }
.pl-legend-dot { width: 8px; height: 8px; border-radius: 2px; border: 1px solid rgba(0,0,0,0.1); }

/* Shared: navbar */
.pl-tpl-nav { display: flex; align-items: center; justify-content: space-between; padding: 6px 10px; border-radius: 6px; margin-bottom: 8px; }
.pl-tpl-nav-logo { font-size: 11px; font-weight: 700; }
.pl-tpl-nav-links { display: flex; gap: 8px; font-size: 9px; font-weight: 500; }
.pl-tpl-nav-cta { padding: 3px 10px; border: none; border-radius: 4px; font-size: 9px; font-weight: 600; }

/* Shared: input */
.pl-tpl-input { width: 100%; padding: 5px 8px; border: 1px solid; border-radius: 5px; font-size: 10px; background: transparent; outline: none; }
.pl-tpl-label { font-size: 9px; font-weight: 600; margin-bottom: 3px; display: block; }

/* Landing */
.pl-tpl-hero { text-align: center; padding: 6px 0; }
.pl-tpl-hero-badge { display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 9px; font-weight: 600; margin-bottom: 6px; }
.pl-tpl-hero-title { font-size: 16px; font-weight: 700; margin-bottom: 4px; line-height: 1.3; }
.pl-tpl-hero-sub { font-size: 11px; line-height: 1.5; margin-bottom: 8px; }
.pl-tpl-hero-actions { display: flex; gap: 6px; justify-content: center; }
.pl-tpl-btn { padding: 5px 14px; border: none; border-radius: 5px; font-size: 11px; font-weight: 600; cursor: default; }
.pl-tpl-btn-outline { padding: 5px 14px; border: 2px solid; border-radius: 5px; font-size: 11px; font-weight: 600; background: transparent; cursor: default; }
.pl-tpl-features { display: flex; gap: 6px; margin-top: 8px; }
.pl-tpl-feature { flex: 1; padding: 7px; border-radius: 6px; text-align: center; }
.pl-tpl-feature-icon { font-size: 14px; margin-bottom: 2px; }
.pl-tpl-feature-label { font-size: 9px; font-weight: 600; }
.pl-tpl-testimonial { margin-top: 8px; padding: 8px; border-radius: 6px; font-size: 10px; font-style: italic; line-height: 1.5; text-align: center; }
.pl-tpl-testimonial-author { font-style: normal; font-weight: 600; font-size: 9px; margin-top: 4px; }

/* Dashboard */
.pl-tpl-dash { display: flex; gap: 6px; }
.pl-tpl-sidebar { width: 40px; border-radius: 6px; padding: 6px 3px; display: flex; flex-direction: column; align-items: center; gap: 5px; flex-shrink: 0; }
.pl-tpl-nav-dot { width: 20px; height: 20px; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-size: 8px; }
.pl-tpl-main { flex: 1; display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.pl-tpl-stats { display: flex; gap: 4px; }
.pl-tpl-stat { flex: 1; padding: 6px; border-radius: 6px; }
.pl-tpl-stat-val { font-size: 14px; font-weight: 700; }
.pl-tpl-stat-label { font-size: 8px; font-weight: 500; }
.pl-tpl-chart-bar { display: flex; align-items: flex-end; gap: 2px; height: 32px; }
.pl-tpl-bar { flex: 1; border-radius: 2px 2px 0 0; }
.pl-tpl-table { width: 100%; border-collapse: collapse; font-size: 8px; }
.pl-tpl-table th { text-align: left; padding: 3px 4px; font-weight: 600; }
.pl-tpl-table td { padding: 3px 4px; }
.pl-tpl-table-badge { padding: 1px 5px; border-radius: 3px; font-size: 7px; font-weight: 600; }

/* Blog */
.pl-tpl-blog-layout { display: flex; gap: 8px; }
.pl-tpl-blog-main { flex: 1; }
.pl-tpl-blog-side { width: 80px; flex-shrink: 0; }
.pl-tpl-article-img { height: 40px; border-radius: 6px; margin-bottom: 6px; }
.pl-tpl-article-cat { font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 3px; }
.pl-tpl-article-title { font-size: 14px; font-weight: 700; line-height: 1.3; margin-bottom: 4px; }
.pl-tpl-article-meta { font-size: 9px; margin-bottom: 6px; }
.pl-tpl-article-body { font-size: 10px; line-height: 1.6; margin-bottom: 6px; }
.pl-tpl-article-quote { padding: 6px 8px; border-left: 3px solid; border-radius: 0 4px 4px 0; font-size: 10px; font-style: italic; line-height: 1.4; }
.pl-tpl-tag { display: inline-block; padding: 2px 6px; border-radius: 3px; font-size: 8px; font-weight: 600; margin: 1px; }

/* E-commerce */
.pl-tpl-shop-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.pl-tpl-shop-title { font-size: 13px; font-weight: 700; }
.pl-tpl-cart-icon { font-size: 14px; position: relative; }
.pl-tpl-cart-badge { position: absolute; top: -4px; right: -6px; font-size: 7px; font-weight: 700; padding: 1px 3px; border-radius: 6px; }
.pl-tpl-products { display: flex; gap: 5px; }
.pl-tpl-product { flex: 1; border-radius: 6px; overflow: hidden; }
.pl-tpl-product-img { height: 44px; position: relative; }
.pl-tpl-product-info { padding: 5px; }
.pl-tpl-product-name { font-size: 9px; font-weight: 600; margin-bottom: 1px; }
.pl-tpl-product-rating { font-size: 8px; margin-bottom: 2px; }
.pl-tpl-product-price { font-size: 11px; font-weight: 700; margin-bottom: 3px; }
.pl-tpl-product-btn { width: 100%; padding: 4px; border: none; border-radius: 4px; font-size: 8px; font-weight: 600; cursor: default; }

/* Login */
.pl-tpl-login { max-width: 200px; margin: 0 auto; }
.pl-tpl-login-title { font-size: 14px; font-weight: 700; text-align: center; margin-bottom: 3px; }
.pl-tpl-login-sub { font-size: 9px; text-align: center; margin-bottom: 10px; }
.pl-tpl-form-group { margin-bottom: 6px; }
.pl-tpl-login-forgot { font-size: 8px; text-align: right; margin-bottom: 8px; }
.pl-tpl-login-divider { display: flex; align-items: center; gap: 6px; margin: 8px 0; font-size: 8px; }
.pl-tpl-login-divider::before, .pl-tpl-login-divider::after { content: ''; flex: 1; height: 1px; }
.pl-tpl-social-btns { display: flex; gap: 4px; }
.pl-tpl-social-btn { flex: 1; padding: 4px; border: 1px solid; border-radius: 4px; font-size: 9px; font-weight: 500; text-align: center; background: transparent; }

/* Pricing */
.pl-tpl-pricing { display: flex; gap: 5px; align-items: flex-start; }
.pl-tpl-price-card { flex: 1; border-radius: 6px; padding: 8px; text-align: center; }
.pl-tpl-price-card.featured { transform: scale(1.04); position: relative; z-index: 1; }
.pl-tpl-price-name { font-size: 9px; font-weight: 700; text-transform: uppercase; margin-bottom: 3px; }
.pl-tpl-price-amount { font-size: 18px; font-weight: 800; margin-bottom: 1px; }
.pl-tpl-price-period { font-size: 8px; margin-bottom: 6px; }
.pl-tpl-price-features { font-size: 8px; line-height: 1.8; margin-bottom: 6px; text-align: left; padding: 0 4px; }
.pl-tpl-price-btn { width: 100%; padding: 4px; border: none; border-radius: 4px; font-size: 9px; font-weight: 600; cursor: default; }
.pl-tpl-price-btn-outline { width: 100%; padding: 4px; border: 2px solid; border-radius: 4px; font-size: 9px; font-weight: 600; background: transparent; cursor: default; }
.pl-tpl-popular-badge { font-size: 7px; font-weight: 700; padding: 1px 6px; border-radius: 3px; display: inline-block; margin-bottom: 4px; }

/* Portfolio */
.pl-tpl-portfolio-filters { display: flex; gap: 3px; margin-bottom: 6px; }
.pl-tpl-filter { padding: 2px 7px; border-radius: 4px; font-size: 8px; font-weight: 600; cursor: default; }
.pl-tpl-portfolio-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 4px; }
.pl-tpl-portfolio-item { border-radius: 5px; overflow: hidden; }
.pl-tpl-portfolio-img { height: 36px; position: relative; }
.pl-tpl-portfolio-info { padding: 4px; }
.pl-tpl-portfolio-name { font-size: 8px; font-weight: 600; }
.pl-tpl-portfolio-cat { font-size: 7px; }

/* Settings */
.pl-tpl-settings { display: flex; gap: 8px; }
.pl-tpl-settings-nav { width: 70px; flex-shrink: 0; }
.pl-tpl-settings-link { display: block; padding: 4px 6px; border-radius: 4px; font-size: 8px; font-weight: 500; margin-bottom: 2px; cursor: default; }
.pl-tpl-settings-link.active { font-weight: 700; }
.pl-tpl-settings-main { flex: 1; }
.pl-tpl-settings-title { font-size: 12px; font-weight: 700; margin-bottom: 6px; }
.pl-tpl-toggle-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 5px; }
.pl-tpl-toggle-label { font-size: 9px; font-weight: 500; }
.pl-tpl-toggle { width: 24px; height: 13px; border-radius: 7px; position: relative; }
.pl-tpl-toggle-dot { width: 9px; height: 9px; border-radius: 50%; background: #fff; position: absolute; top: 2px; }
.pl-tpl-avatar { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; margin-bottom: 6px; }

/* Code */
.pl-code-output { margin-top: 14px; background: var(--dpt); border-radius: 8px; overflow: hidden; }
.pl-code-header { display: flex; align-items: center; justify-content: space-between; padding: 6px 12px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.pl-code-tabs { display: flex; gap: 2px; }
.pl-code-tab { padding: 3px 8px; background: rgba(255,255,255,0.08); border: none; border-radius: 4px; font-family: 'Courier New', monospace; font-size: 11px; color: rgba(255,255,255,0.4); cursor: pointer; }
.pl-code-tab.active { background: var(--dp); color: #fff; }
.pl-copy-btn { display: inline-flex; align-items: center; gap: 6px; background: var(--dp); border: none; color: #fff; font-family: system-ui, sans-serif; font-size: 13px; font-weight: 500; padding: 6px 14px; border-radius: 6px; cursor: pointer; }
.pl-copy-btn:hover { background: var(--dpd); }
.pl-copy-btn.copied { background: var(--dp-success); }
.pl-copy-btn svg { width: 14px; height: 14px; }
.pl-code-body { padding: 12px; font-family: 'Courier New', monospace; font-size: 12px; line-height: 1.75; color: #e2e8f0; white-space: pre-wrap; word-break: break-all; max-height: 160px; overflow-y: auto; }
.pl-code-prop { color: #7dd3fc; }
.pl-code-val { color: #86efac; }
.pl-code-punc { color: rgba(255,255,255,0.4); }

/* Share */
.pl-share-section { margin-top: 14px; }
.pl-share-url-row { display: flex; gap: 8px; margin-bottom: 12px; }
.pl-share-url-input { flex: 1; background: var(--dpbg); border: 1px solid var(--dpb); border-radius: 6px; padding: 6px 12px; font-family: 'Courier New', monospace; font-size: 13px; color: var(--dpt); outline: none; min-width: 0; }
.pl-share-copy-btn { display: inline-flex; align-items: center; background: var(--dp); border: none; color: #fff; font-family: system-ui, sans-serif; font-size: 13px; font-weight: 500; padding: 6px 14px; border-radius: 6px; cursor: pointer; white-space: nowrap; }
.pl-share-copy-btn:hover { background: var(--dpd); }
.pl-share-copy-btn.copied { background: var(--dp-success); }
.pl-share-socials { display: flex; gap: 8px; }
.pl-share-social-btn { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 6px; padding: 6px; font-family: system-ui, sans-serif; font-size: 13px; font-weight: 500; color: var(--dpt); cursor: pointer; text-decoration: none; transition: all var(--dp-transition); }
.pl-share-social-btn:hover { border-color: var(--dp); color: var(--dp); }
.pl-share-social-btn svg { width: 14px; height: 14px; }

/* Right panel */
.pl-controls { display: flex; flex-direction: column; gap: 14px; }

/* Image */
.pl-img-drop { border: 2px dashed var(--dpb); border-radius: 8px; padding: 14px; text-align: center; cursor: pointer; transition: all var(--dp-transition); }
.pl-img-drop:hover { border-color: var(--dp); background: var(--dpl); }
.pl-img-drop-text { font-size: 12px; color: var(--dpm); line-height: 1.5; }
.pl-img-drop-text strong { color: var(--dp); }
.pl-img-preview { margin-top: 8px; border-radius: 8px; overflow: hidden; display: none; position: relative; }
.pl-img-preview img { width: 100%; display: block; }
.pl-img-remove { position: absolute; top: 4px; right: 4px; background: rgba(0,0,0,0.5); color: #fff; border: none; border-radius: 4px; padding: 2px 6px; font-size: 10px; cursor: pointer; }
.pl-img-colors { display: flex; gap: 3px; margin-top: 8px; display: none; }
.pl-img-color { flex: 1; height: 30px; border-radius: 4px; cursor: pointer; border: 1px solid var(--dpb); display: flex; align-items: center; justify-content: center; transition: all var(--dp-transition); }
.pl-img-color:hover { transform: scale(1.08); }
.pl-img-color-label { font-family: 'Courier New', monospace; font-size: 8px; font-weight: 600; opacity: 0; transition: opacity 0.2s; }
.pl-img-color:hover .pl-img-color-label { opacity: 1; }

/* Contrast Grid */
.pl-grid-table { width: 100%; border-collapse: collapse; }
.pl-grid-table th { font-size: 9px; font-weight: 600; color: var(--dpm); padding: 3px; }
.pl-grid-cell { width: 100%; aspect-ratio: 1; display: flex; align-items: center; justify-content: center; font-family: 'Courier New', monospace; font-size: 9px; font-weight: 700; border-radius: 3px; margin: 1px; }

/* CB sim */
.pl-cb-strip { display: flex; border-radius: 6px; overflow: hidden; height: 24px; margin-bottom: 6px; }
.pl-cb-color { flex: 1; }
.pl-cb-label { font-size: 11px; color: var(--dpm); font-weight: 500; margin-bottom: 3px; }

@media (max-width: 900px) { .pl-app { padding: 24px 16px 48px; } }

/* Shade Scale */
.pl-shade-section { margin-bottom: 14px; }
.pl-shade-row { display: flex; gap: 1px; margin-bottom: 3px; }
.pl-shade-row-label { font-size: 8px; font-weight: 600; color: var(--dpm); width: 50px; display: flex; align-items: center; flex-shrink: 0; }
.pl-shade-cells { display: flex; gap: 1px; flex: 1; }
.pl-shade-cell { flex: 1; height: 24px; border-radius: 3px; cursor: pointer; position: relative; display: flex; align-items: center; justify-content: center; transition: transform 0.15s, box-shadow 0.15s; }
.pl-shade-cell:hover { transform: scale(1.15); z-index: 2; box-shadow: 0 2px 8px rgba(0,0,0,0.2); }
.pl-shade-cell-label { font-family: 'Courier New', monospace; font-size: 6px; font-weight: 700; opacity: 0; transition: opacity 0.15s; pointer-events: none; }
.pl-shade-cell:hover .pl-shade-cell-label { opacity: 1; }
.pl-shade-header { display: flex; gap: 1px; margin-bottom: 2px; padding-left: 50px; }
.pl-shade-header span { flex: 1; text-align: center; font-size: 7px; font-weight: 600; color: var(--dpm); }

/* Color name on strip */
.pl-palette-name { font-size: 8px; font-weight: 500; padding: 1px 4px; border-radius: 2px; margin-bottom: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 90px; }

/* History panel */
.pl-history { margin-top: 14px; }
.pl-history-list { display: flex; flex-direction: column; gap: 3px; max-height: 120px; overflow-y: auto; }
.pl-history-item { display: flex; border-radius: 4px; overflow: hidden; height: 18px; cursor: pointer; transition: transform 0.15s, box-shadow 0.15s; border: 1px solid var(--dpb); }
.pl-history-item:hover { transform: scale(1.02); box-shadow: var(--dp-shadow-hover); }
.pl-history-item.active { border-color: var(--dp); box-shadow: 0 0 0 1px var(--dp); }
.pl-history-color { flex: 1; }
.pl-history-controls { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.pl-undo-btn { padding: 3px 10px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 5px; font-family: system-ui, sans-serif; font-size: 11px; font-weight: 500; color: var(--dpt); cursor: pointer; transition: all var(--dp-transition); }
.pl-undo-btn:hover { border-color: var(--dp); color: var(--dp); }
.pl-undo-btn:disabled { opacity: 0.3; cursor: default; }
.pl-undo-btn.copied { background: var(--dp-success); color: #fff; border-color: var(--dp-success); }

/* Drag */
.pl-palette-color.dragging { opacity: 0.4; }
.pl-palette-color.drag-over { box-shadow: inset 0 0 0 2px var(--dp); }

/* History buttons in controls */
.pl-history-row { display: flex; gap: 2px; }
.pl-history-btn { padding: 3px 8px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 5px; font-size: 14px; cursor: pointer; color: var(--dpt); transition: all var(--dp-transition); line-height: 1; }
.pl-history-btn:hover:not(:disabled) { border-color: var(--dp); color: var(--dp); }
.pl-history-btn:disabled { opacity: 0.3; cursor: default; }

/* Export button */
.pl-export-btn { display: inline-flex; align-items: center; gap: 5px; padding: 6px 14px; background: var(--dp); border: none; border-radius: 6px; color: #fff; font-family: system-ui, sans-serif; font-size: 12px; font-weight: 500; cursor: pointer; transition: background var(--dp-transition); }
.pl-export-btn:hover { background: var(--dpd); }
.pl-export-btn svg { width: 14px; height: 14px; }

/* Gradient generator */
.pl-gradient-list { display: flex; flex-direction: column; gap: 6px; }
.pl-gradient-item { border-radius: 8px; overflow: hidden; cursor: pointer; transition: transform 0.15s, box-shadow 0.15s; }
.pl-gradient-item:hover { transform: scale(1.02); box-shadow: var(--dp-shadow-hover); }
.pl-gradient-preview { height: 32px; border-radius: 6px 6px 0 0; }
.pl-gradient-info { display: flex; align-items: center; justify-content: space-between; padding: 4px 8px; background: var(--dpbg); border: 1px solid var(--dpb); border-top: none; border-radius: 0 0 6px 6px; }
.pl-gradient-css { font-family: 'Courier New', monospace; font-size: 9px; color: var(--dpt); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; }
.pl-gradient-copy { font-size: 9px; font-weight: 600; color: var(--dp); flex-shrink: 0; margin-left: 6px; }
.pl-gradient-copy.copied { color: var(--dp-success); }

/* Accessibility score */
.pl-a11y-score { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.pl-a11y-badge { padding: 4px 12px; border-radius: 6px; font-size: 14px; font-weight: 800; letter-spacing: 0.05em; }
.pl-a11y-label { font-size: 11px; color: var(--dpt); line-height: 1.4; }
.pl-a11y-detail { font-size: 10px; color: var(--dpm); }
.pl-a11y-pairs { display: flex; flex-direction: column; gap: 3px; }
.pl-a11y-pair { display: flex; align-items: center; gap: 6px; font-size: 10px; }
.pl-a11y-swatch { width: 14px; height: 14px; border-radius: 3px; border: 1px solid rgba(0,0,0,0.1); flex-shrink: 0; }
.pl-a11y-ratio { font-family: 'Courier New', monospace; font-weight: 600; font-size: 10px; width: 36px; }
.pl-a11y-pass { color: var(--dp-success); font-weight: 600; }
.pl-a11y-fail { color: var(--dp-error); font-weight: 600; }

/* Typography preview */
.pl-typo-tabs { display: flex; gap: 3px; margin-bottom: 8px; }
.pl-typo-tab { padding: 3px 8px; background: var(--dpbg); border: 1px solid var(--dpb); border-radius: 5px; font-size: 10px; font-weight: 500; color: var(--dpm); cursor: pointer; transition: all var(--dp-transition); }
.pl-typo-tab:hover { border-color: var(--dp); }
.pl-typo-tab.active { background: var(--dp); color: #fff; border-color: var(--dp); }
.pl-typo-preview { padding: 12px; border: 1px solid var(--dpb); border-radius: 8px; }
.pl-typo-heading { margin-bottom: 4px; line-height: 1.3; }
.pl-typo-sub { margin-bottom: 8px; line-height: 1.3; }
.pl-typo-body { line-height: 1.7; margin-bottom: 6px; }
.pl-typo-link { text-decoration: underline; font-weight: 600; }
.pl-typo-btn { display: inline-block; padding: 4px 14px; border-radius: 5px; font-size: 11px; font-weight: 600; border: none; }
.pl-typo-meta { font-size: 9px; color: var(--dpm); margin-top: 8px; }

/* Fullscreen mockup */
.pl-fullscreen-overlay { position: fixed; inset: 0; z-index: 99999; background: rgba(0,0,0,0.6); display: none; justify-content: center; align-items: center; padding: 20px; }
.pl-fullscreen-overlay.active { display: flex; }
.pl-fullscreen-inner { width: 100%; max-width: 900px; max-height: 90vh; overflow-y: auto; border-radius: 12px; box-shadow: 0 25px 50px rgba(0,0,0,0.25); position: relative; }
.pl-fullscreen-close { position: absolute; top: 10px; right: 14px; background: rgba(0,0,0,0.4); color: #fff; border: none; border-radius: 50%; width: 28px; height: 28px; font-size: 16px; cursor: pointer; z-index: 10; display: flex; align-items: center; justify-content: center; }
.pl-fs-nav { display: flex; align-items: center; justify-content: space-between; padding: 12px 24px; }
.pl-fs-logo { font-size: 18px; font-weight: 800; }
.pl-fs-links { display: flex; gap: 20px; font-size: 13px; font-weight: 500; }
.pl-fs-hero { text-align: center; padding: 40px 24px; }
.pl-fs-hero h1 { font-size: 32px; font-weight: 800; line-height: 1.2; margin-bottom: 10px; }
.pl-fs-hero p { font-size: 15px; line-height: 1.6; max-width: 500px; margin: 0 auto 20px; }
.pl-fs-hero-btns { display: flex; gap: 10px; justify-content: center; }
.pl-fs-btn { padding: 10px 24px; border: none; border-radius: 8px; font-size: 14px; font-weight: 600; cursor: default; }
.pl-fs-btn-outline { padding: 10px 24px; border: 2px solid; border-radius: 8px; font-size: 14px; font-weight: 600; background: transparent; cursor: default; }
.pl-fs-features { display: flex; gap: 16px; padding: 24px; }
.pl-fs-feature { flex: 1; padding: 20px; border-radius: 10px; text-align: center; }
.pl-fs-feature-icon { font-size: 24px; margin-bottom: 6px; }
.pl-fs-feature-title { font-size: 14px; font-weight: 700; margin-bottom: 4px; }
.pl-fs-feature-desc { font-size: 12px; line-height: 1.5; }
.pl-fs-footer { text-align: center; padding: 16px; font-size: 12px; }

/* Compare */
.pl-compare { display: none; }
.pl-compare.active { display: block; }
.pl-compare-row { display: flex; gap: 8px; margin-bottom: 8px; }
.pl-compare-side { flex: 1; }
.pl-compare-label { font-size: 10px; font-weight: 600; color: var(--dpm); text-transform: uppercase; margin-bottom: 4px; }
.pl-compare-strip { display: flex; border-radius: 6px; overflow: hidden; height: 36px; margin-bottom: 4px; }
.pl-compare-color { flex: 1; }
.pl-compare-info { font-size: 9px; color: var(--dpt); }
.pl-compare-btn { padding: 5px 12px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 6px; font-family: system-ui, sans-serif; font-size: 11px; font-weight: 500; color: var(--dpt); cursor: pointer; transition: all var(--dp-transition); }
.pl-compare-btn:hover { border-color: var(--dp); color: var(--dp); }
.pl-compare-btn.active { background: var(--dp); color: #fff; border-color: var(--dp); }

/* Shade Scale */
.pl-shade-section { margin-top: 8px; }
.pl-shade-row { margin-bottom: 6px; }
.pl-shade-label { font-size: 9px; font-weight: 600; color: var(--dpm); margin-bottom: 2px; }
.pl-shade-strip { display: flex; border-radius: 6px; overflow: hidden; height: 24px; }
.pl-shade-cell { flex: 1; position: relative; cursor: pointer; transition: flex 0.2s; }
.pl-shade-cell:hover { flex: 1.6; }
.pl-shade-tooltip { display: none; position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); background: var(--dpt); color: #fff; font-family: 'Courier New', monospace; font-size: 9px; padding: 2px 6px; border-radius: 3px; white-space: nowrap; margin-bottom: 2px; pointer-events: none; z-index: 5; }
.pl-shade-cell:hover .pl-shade-tooltip { display: block; }
.pl-shade-num { font-family: 'Courier New', monospace; font-size: 7px; font-weight: 600; opacity: 0; transition: opacity 0.2s; }
.pl-shade-cell:hover .pl-shade-num { opacity: 1; }

/* History */
.pl-history-row { display: flex; gap: 4px; align-items: center; }
.pl-history-btn { padding: 3px 8px; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 5px; font-size: 11px; cursor: pointer; color: var(--dpt); transition: all var(--dp-transition); }
.pl-history-btn:hover { border-color: var(--dp); color: var(--dp); }
.pl-history-btn:disabled { opacity: 0.3; cursor: default; }
.pl-history-count { font-size: 10px; color: var(--dpm); }

/* Drag-drop */
.pl-palette-color[draggable="true"] { cursor: grab; }
.pl-palette-color.dragging { opacity: 0.4; }
.pl-palette-color.drag-over { box-shadow: inset 0 0 0 2px var(--dp); }

/* Color name */
.pl-palette-name { font-size: 8px; font-weight: 500; padding: 1px 4px; border-radius: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 80px; }

/* Keyword search */
.pl-keyword-wrap { position: relative; margin-bottom: 14px; }
.pl-keyword-input { width: 100%; padding: 7px 10px 7px 28px; background: var(--dpbg); border: 1px solid var(--dpb); border-radius: 8px; font-family: system-ui, sans-serif; font-size: 12px; color: var(--dpt); outline: none; transition: border-color var(--dp-transition); }
.pl-keyword-input:focus { border-color: var(--dp); }
.pl-keyword-input::placeholder { color: var(--dpm); }
.pl-keyword-icon { position: absolute; left: 9px; top: 50%; transform: translateY(-50%); font-size: 13px; color: var(--dpm); pointer-events: none; }
.pl-keyword-results { position: absolute; top: 100%; left: 0; right: 0; background: var(--dpw); border: 1px solid var(--dpb); border-radius: 8px; margin-top: 4px; box-shadow: var(--dp-shadow-hover); z-index: 10; max-height: 160px; overflow-y: auto; display: none; }
.pl-keyword-results.open { display: block; }
.pl-keyword-item { display: flex; align-items: center; gap: 8px; padding: 6px 10px; cursor: pointer; transition: background var(--dp-transition); font-size: 12px; }
.pl-keyword-item:hover { background: var(--dpl); }
.pl-keyword-dots { display: flex; gap: 2px; }
.pl-keyword-dot { width: 10px; height: 10px; border-radius: 2px; }
.pl-keyword-name { font-weight: 500; color: var(--dpt); }
.pl-keyword-style { font-size: 10px; color: var(--dpm); }
