/* PaletteNex: generator (full screen), palette cards, Explore, palette / color pages, visualizer mockups, library. */

/* ---------------- hero */
.pn-hero { padding: 46px 0 30px; background: radial-gradient(900px 360px at 85% -10%, color-mix(in srgb, var(--accent) 18%, transparent), transparent), radial-gradient(900px 360px at 0% 0%, color-mix(in srgb, var(--primary) 14%, transparent), transparent); }
.pn-hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 40px; align-items: center; }
.pn-hero h1 { font-size: clamp(34px, 5vw, 60px); line-height: 1.04; letter-spacing: -.04em; margin: 14px 0; }
.pn-hero .lead { color: var(--text-2); font-size: 17px; max-width: 560px; }
.pn-hero-cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.pn-hero-hint { margin-top: 14px; }
.pn-hero-hint kbd, .pn-gbar kbd { font: 600 11px var(--font-mono); background: var(--surface-2); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; }
.pn-hero-demo { display: flex; height: 340px; border-radius: 22px; overflow: hidden; box-shadow: var(--shadow-pop), 0 30px 60px -30px rgba(15, 23, 42, .35); text-decoration: none !important; }
.pn-hero-demo span { flex: 1; background: var(--c); color: var(--t, #fff); display: flex; align-items: flex-end; justify-content: center; padding-bottom: 18px; transition: background .5s var(--ease), flex .3s var(--ease); }
.pn-hero-demo span:hover { flex: 1.5; }
.pn-hero-demo b { font: 700 15px var(--font-mono); letter-spacing: .02em; }

/* ---------------- palette cards */
.pn-sec { margin-top: 26px; }
.pn-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
.pn-grid-lg { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.pn-grid.loading { opacity: .45; pointer-events: none; }
.pn-card { display: flex; flex-direction: column; gap: 8px; color: inherit; text-decoration: none !important; min-width: 0; }
.pn-strip { display: flex; height: 112px; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-card); outline: 1px solid color-mix(in srgb, var(--text) 8%, transparent); outline-offset: -1px; }
.pn-grid-lg .pn-strip { height: 128px; }
.pn-strip i { flex: 1; background: var(--c); position: relative; transition: flex .2s var(--ease); display: flex; align-items: center; justify-content: center; font-style: normal; }
.pn-strip i:hover { flex: 2.2; }
.pn-strip em { font: 700 12px var(--font-mono); font-style: normal; color: var(--t, #fff); opacity: 0; transition: opacity .15s; cursor: copy; padding: 4px; }
.pn-strip i:hover em { opacity: 1; }
.pn-meta { display: flex; align-items: center; gap: 6px; min-width: 0; padding: 0 2px; }
.pn-meta b { flex: 1; min-width: 0; font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pn-likes, .pn-more, .pn-lib-act { display: inline-flex; align-items: center; gap: 4px; border: 0; background: none; color: var(--muted); font-size: 12.5px; padding: 4px 6px; border-radius: 8px; cursor: pointer; }
.pn-likes:hover, .pn-more:hover, .pn-lib-act:hover { background: var(--surface-2); color: var(--text); }
.pn-likes.on { color: #e11d48; }
.pn-likes.on .ico { fill: currentColor; }
.pn-tagrow { justify-content: flex-start; margin-top: 18px; flex-wrap: wrap; }
.pn-tagrow .chip.on { background: var(--text); color: var(--bg); border-color: var(--text); }
.pn-empty { grid-column: 1 / -1; text-align: center; padding: 40px 10px; }

/* ---------------- features */
.pn-feats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 30px auto; }
.pn-feat { display: flex; flex-direction: column; gap: 12px; padding: 16px; color: inherit; text-decoration: none !important; transition: transform .2s var(--ease), box-shadow .2s; }
.pn-feat:hover { transform: translateY(-3px); box-shadow: var(--shadow-pop); }
.pn-feat > span:last-child { display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; }
.pn-feat b { font-size: 16px; }
.pn-feat-art { height: 96px; border-radius: 12px; display: flex; overflow: hidden; gap: 4px; }
.pn-art-gen i { flex: 1; }
.pn-art-gen i:nth-child(1) { background: #264653; } .pn-art-gen i:nth-child(2) { background: #2a9d8f; } .pn-art-gen i:nth-child(3) { background: #e9c46a; } .pn-art-gen i:nth-child(4) { background: #f4a261; } .pn-art-gen i:nth-child(5) { background: #e76f51; }
.pn-art-explore { display: grid; grid-template-columns: repeat(3, 1fr); }
.pn-art-explore i { border-radius: 6px; }
.pn-art-explore i:nth-child(1) { background: linear-gradient(90deg, #ffadad 33%, #ffd6a5 33% 66%, #fdffb6 66%); } .pn-art-explore i:nth-child(2) { background: linear-gradient(90deg, #003049 33%, #d62828 33% 66%, #f77f00 66%); }
.pn-art-explore i:nth-child(3) { background: linear-gradient(90deg, #cdb4db 33%, #ffc8dd 33% 66%, #a2d2ff 66%); } .pn-art-explore i:nth-child(4) { background: linear-gradient(90deg, #606c38 33%, #283618 33% 66%, #dda15e 66%); }
.pn-art-explore i:nth-child(5) { background: linear-gradient(90deg, #0b090a 33%, #ba181b 33% 66%, #f5f3f4 66%); } .pn-art-explore i:nth-child(6) { background: linear-gradient(90deg, #8ecae6 33%, #219ebc 33% 66%, #ffb703 66%); }
.pn-art-vis { background: #f1faee; padding: 10px; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 20px 1fr; gap: 6px; }
.pn-art-vis i:nth-child(1) { grid-column: 1 / -1; background: #1d3557; border-radius: 4px; } .pn-art-vis i:nth-child(2) { background: #e63946; border-radius: 6px; } .pn-art-vis i:nth-child(3) { background: #a8dadc; border-radius: 6px; }
.pn-art-img { background: linear-gradient(135deg, #f8b195, #f67280 40%, #6c5b7b 70%, #355c7d); position: relative; }
.pn-art-img i { position: absolute; width: 18px; height: 18px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
.pn-art-img i:nth-child(1) { left: 14%; top: 22%; background: #f8b195; } .pn-art-img i:nth-child(2) { left: 40%; top: 55%; background: #f67280; } .pn-art-img i:nth-child(3) { left: 66%; top: 30%; background: #6c5b7b; } .pn-art-img i:nth-child(4) { left: 82%; top: 66%; background: #355c7d; }
.pn-home-search { margin: 26px 0 22px; max-width: 640px; }

/* ---------------- generator (full screen) */
body.pn-app { height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }
.pn-gbar { height: 56px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 14px; border-bottom: 1px solid var(--line); background: var(--elev); position: relative; z-index: 5; }
.pn-gbar .logo { gap: 8px; }
.pn-gbar-tools { display: flex; align-items: center; gap: 2px; }
.pn-gbar-tools .btn[disabled] { opacity: .35; }
.pn-sep { width: 1px; height: 24px; background: var(--line); margin: 0 6px; }
.pn-gbar-hint { white-space: nowrap; }
.pn-gbar-ad { max-width: 360px; margin: 0; font-size: 12px; }
.pn-gbar-ad .ad { padding: 4px 8px; min-height: 0; }
.pn-gen { flex: 1; display: flex; position: relative; min-height: 0; }
.pn-col { flex: 1; min-width: 0; background: var(--c); color: var(--t); display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding-bottom: 9vh; position: relative; cursor: pointer;
  transition: background-color .35s var(--ease), flex .25s var(--ease); user-select: none; }
.pn-col.pn-fresh { animation: pn-in .35s var(--ease); }
@keyframes pn-in { from { filter: saturate(.4) brightness(1.08); } }
.pn-col.dragging { z-index: 3; box-shadow: 0 0 0 3px color-mix(in srgb, var(--t) 40%, transparent) inset, 0 20px 40px rgba(0, 0, 0, .3); }
.pn-col-tools { display: flex; flex-direction: column; gap: 4px; margin-bottom: 24px; opacity: 0; transition: opacity .15s; }
.pn-col:hover .pn-col-tools, .pn-col:focus-within .pn-col-tools { opacity: 1; }
.pn-col-tools button { width: 44px; height: 44px; border: 0; border-radius: 10px; background: transparent; color: var(--t); cursor: pointer; display: grid; place-items: center; }
.pn-col-tools button:hover { background: color-mix(in srgb, var(--t) 14%, transparent); }
.pn-col-tools button[disabled] { opacity: .3; cursor: default; }
.pn-col-tools .ico { width: 20px; height: 20px; }
.pn-col.locked .pn-col-tools .pn-lock { opacity: 1; }
.pn-col.locked .pn-col-tools { opacity: 1; }
.pn-col.locked .pn-col-tools button:not(.pn-lock) { opacity: 0; }
.pn-col.locked:hover .pn-col-tools button:not(.pn-lock):not([disabled]) { opacity: 1; }
.pn-drag { cursor: grab !important; touch-action: none; }
.pn-col-hex { border: 0; background: none; color: var(--t); font: 700 clamp(18px, 2.4vw, 30px) var(--font-ui); letter-spacing: .01em; cursor: text; padding: 6px 10px; border-radius: 10px; }
.pn-col-hex:hover { background: color-mix(in srgb, var(--t) 12%, transparent); }
.pn-col-name { font-size: 13px; opacity: .72; margin-top: 2px; text-align: center; padding: 0 6px; }
.pn-add { position: absolute; top: 50% !important; transform: translate(-50%, -50%); width: 44px; height: 44px; border-radius: 50%; border: 0; background: #fff; color: #111;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .25); display: grid; place-items: center; cursor: pointer; opacity: 0; transition: opacity .15s, transform .15s; z-index: 4; }
.pn-gen:hover .pn-add { opacity: .0; }
.pn-add:hover, .pn-add:focus-visible { opacity: 1 !important; transform: translate(-50%, -50%) scale(1.08); }
.pn-col-shades { justify-content: stretch; padding: 0; cursor: default; }
.pn-shade-list { flex: 1; display: flex; flex-direction: column; width: 100%; }
.pn-shade-list button { flex: 1; border: 0; background: var(--c); color: var(--t); font: 600 12px var(--font-mono); cursor: pointer; display: flex; align-items: center; justify-content: center; opacity: 1; }
.pn-shade-list button span { opacity: 0; transition: opacity .1s; }
.pn-shade-list button:hover span, .pn-shade-list button.on span { opacity: 1; }
.pn-shade-list button.on { box-shadow: inset 0 0 0 3px var(--t); }
.pn-shade-close { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .9); color: #111; display: grid; place-items: center; cursor: pointer; }
.pn-vision-bar { position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); background: var(--elev); color: var(--text); border: 1px solid var(--line); border-radius: 14px;
  padding: 8px 10px 8px 14px; display: flex; gap: 10px; align-items: center; box-shadow: var(--shadow-pop); z-index: 6; font-size: 13.5px; max-width: calc(100% - 32px); }
.pn-pop { position: fixed; z-index: 50; width: 290px; background: var(--elev); color: var(--text); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-pop); padding: 14px; display: grid; gap: 10px; }
.pn-pop-head { display: flex; gap: 8px; }
.pn-pop-head input[type=color] { width: 46px; height: 42px; border: 1px solid var(--line); border-radius: 10px; padding: 2px; background: var(--elev); cursor: pointer; }
.pn-pop-head .input { text-transform: uppercase; }
.pn-pop .input.bad { border-color: var(--danger); }
.pn-sl { display: grid; gap: 2px; font-size: 12.5px; color: var(--text-2); }
.pn-sl input { width: 100%; accent-color: var(--primary); }
.pn-sl output { color: var(--muted); float: right; }
.pn-adjust { width: 320px; }

/* ---------------- export dialog */
.pn-exp { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 14px; }
.pn-exp-list { display: flex; flex-direction: column; gap: 2px; }
.pn-exp-list button { display: flex; align-items: center; gap: 8px; border: 0; background: none; padding: 8px 10px; border-radius: 8px; cursor: pointer; text-align: left; font-size: 13.5px; color: var(--text-2); }
.pn-exp-list button:hover { background: var(--surface-2); }
.pn-exp-list button.on { background: var(--primary-50); color: var(--primary); font-weight: 600; }
.pn-exp-main { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.pn-exp-prev { display: flex; height: 54px; border-radius: 10px; overflow: hidden; }
.pn-exp-prev i { flex: 1; }
.pn-exp-code { min-height: 210px; font-size: 12.5px; }
.pn-exp-file { padding: 18px; border: 1px dashed var(--line-2); border-radius: 10px; }

/* ---------------- explore */
.pn-ex-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.pn-ex-head .tn-h1 { margin: 0; }
.pn-ex-filters { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.pn-ex-search { flex: 1; min-width: 220px; }
.pn-ex-color { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: var(--r-md); padding: 0 10px; background: var(--elev); cursor: pointer; min-height: 42px; }
.pn-ex-color input { width: 28px; height: 28px; border: 0; padding: 0; background: none; cursor: pointer; }
.pn-x { border: 0; background: none; font-size: 18px; cursor: pointer; color: var(--muted); }
.pn-ex-size { width: auto; }
.pn-ex-families { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.pn-fam { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--elev); box-shadow: 0 0 0 1px var(--line-2); }
.pn-fam:hover, .pn-fam.on { box-shadow: 0 0 0 2px var(--text); }
.pn-fam-red { background: #e53935; } .pn-fam-orange { background: #fb8c00; } .pn-fam-yellow { background: #fdd835; } .pn-fam-green { background: #43a047; } .pn-fam-teal { background: #00897b; }
.pn-fam-blue { background: #1e88e5; } .pn-fam-purple { background: #8e24aa; } .pn-fam-pink { background: #ec407a; } .pn-fam-brown { background: #795548; } .pn-fam-beige { background: #e8d8b9; }
.pn-fam-gray { background: #9e9e9e; } .pn-fam-black { background: #111; } .pn-fam-white { background: #fff; }
.pn-ex-count { margin: 16px 0 10px; }
.pn-ex-more { text-align: center; margin: 26px 0; }

/* ---------------- palette page */
.pn-pal-title { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.pn-pal-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.pn-pal-big { display: flex; height: 300px; border-radius: 20px; overflow: hidden; margin: 18px 0 14px; box-shadow: var(--shadow-pop); }
.pn-pal-big a { flex: 1; background: var(--c); color: var(--t); display: flex; flex-direction: column; justify-content: flex-end; align-items: center; padding-bottom: 22px; text-decoration: none !important; transition: flex .2s var(--ease); }
.pn-pal-big a:hover { flex: 1.4; }
.pn-pal-big b { font: 700 20px var(--font-mono); }
.pn-pal-big span { font-size: 13px; opacity: .75; }
.pn-pal-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 18px; }
.pn-pal-actions .btn.on { color: #e11d48; }
.pn-pal-actions .btn.on .ico { fill: currentColor; }
.pn-pal-info { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.pn-info { overflow: hidden; }
.pn-info-sw { height: 70px; background: var(--c); }
.pn-info-body { padding: 10px 12px 12px; display: grid; gap: 2px; }
.pn-info-body b { margin-bottom: 4px; }
.pn-code { display: flex; gap: 8px; align-items: baseline; border: 0; background: none; padding: 3px 4px; border-radius: 6px; cursor: copy; text-align: left; color: inherit; min-width: 0; }
.pn-code:hover { background: var(--surface-2); }
.pn-code span { font-size: 11px; color: var(--muted); width: 44px; flex: none; }
.pn-code code { font: 12.5px var(--font-mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pn-codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 4px 16px; }
.pn-pal-sec { margin-top: 30px; }
.pn-pal-sec h2 { font-size: 20px; }
.pn-shades { display: grid; gap: 8px; }
.pn-shade-row { display: flex; border-radius: 10px; overflow: hidden; }
.pn-shade-row > * { flex: 1; height: 46px; background: var(--c); color: var(--t); border: 0; display: grid; place-items: center; font: 600 11px var(--font-mono); cursor: copy; text-decoration: none !important; }
.pn-shade-row > * span { opacity: 0; } .pn-shade-row > *:hover span, .pn-shade-row .base span { opacity: 1; }
.pn-shade-row .base { box-shadow: inset 0 0 0 3px var(--t); }
.pn-contrast { overflow-x: auto; }
.pn-ct { border-collapse: separate; border-spacing: 4px; }
.pn-ct th i { display: inline-block; width: 26px; height: 26px; border-radius: 50%; box-shadow: 0 0 0 1px var(--line-2); vertical-align: middle; }
.pn-ct td { width: 86px; height: 56px; border-radius: 8px; text-align: center; font-size: 13px; }
.pn-ct td b { display: block; font-size: 15px; }
.pn-ct td small { font-size: 10.5px; opacity: .85; }
.pn-ct td.na { color: var(--muted); }
.pn-ct-card { display: inline-flex; flex-direction: column; gap: 2px; padding: 14px 18px; border-radius: 12px; margin: 0 8px 8px 0; border: 1px solid var(--line); }
.pn-ct-card b { font-size: 28px; }
.pn-ct-card span { font-size: 12.5px; }
.pn-harm { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.pn-harm-row { display: flex; flex-direction: column; gap: 6px; color: inherit; text-decoration: none !important; padding: 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--elev); }
.pn-harm-row:hover { border-color: var(--primary); }
.pn-harm-row span { display: flex; height: 44px; border-radius: 8px; overflow: hidden; }
.pn-harm-row i { flex: 1; }
.pn-color-hero { background: var(--c); color: var(--t); border-radius: 20px; padding: 70px 28px 26px; margin: 16px 0 14px; box-shadow: var(--shadow-pop); }
.pn-color-hero h1 { margin: 0; font: 800 clamp(34px, 6vw, 64px) var(--font-mono); }
.pn-color-hero p { margin: 4px 0 0; opacity: .8; font-size: 17px; }

/* ---------------- visualizer */
.pn-vis-bar { padding: 12px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.pn-vis-sw { display: flex; border-radius: 10px; overflow: hidden; flex: 1; min-width: 240px; max-width: 560px; }
.pn-vis-sw label { flex: 1; height: 46px; background: var(--c); color: var(--t); display: grid; place-items: center; font: 600 11.5px var(--font-mono); cursor: pointer; position: relative; }
.pn-vis-sw input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.pn-vis-code { width: 260px; max-width: 100%; min-height: 32px; padding: 4px 10px; font-size: 12px; }
.pn-vis-bar .btn.on { background: var(--text); color: var(--bg); }
.pn-vis-tabs { margin-bottom: 14px; flex-wrap: wrap; }
.pn-vis-stage { border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-pop); border: 1px solid var(--line); }
.pn-vis-mini { border-radius: 16px; overflow: hidden; border: 1px solid var(--line); max-height: 460px; }

/* mockups use --bg --sf --pr --ac --tx --mu --opr --oac */
.pn-mock { background: var(--bg); color: var(--tx); font-family: var(--font-ui); min-height: 480px; }
.pn-mock .pn-m-logo { font-weight: 800; color: var(--pr); }
.pn-m-btn { display: inline-flex; align-items: center; padding: 11px 20px; border-radius: 10px; background: var(--pr); color: var(--opr); font-weight: 700; font-size: 14px; }
.pn-m-btn.ghost { background: transparent; color: var(--tx); box-shadow: inset 0 0 0 2px var(--mu); }
.pn-m-btn.sm { padding: 7px 14px; font-size: 13px; }
.pn-m-pill { display: inline-block; padding: 4px 10px; border-radius: 99px; background: var(--sf); color: var(--tx); font-size: 12px; font-weight: 600; }
.pn-m-bars { display: flex; align-items: flex-end; gap: 6px; height: 100%; }
.pn-m-bars i { flex: 1; border-radius: 6px 6px 0 0; }
.pn-m-land nav { display: flex; align-items: center; gap: 22px; padding: 18px 34px; font-size: 14px; }
.pn-m-land nav .pn-m-logo { flex: 1; font-size: 18px; }
.pn-m-heroa { display: grid; grid-template-columns: 1.1fr 1fr; gap: 34px; padding: 30px 34px 20px; align-items: center; }
.pn-m-heroa h3 { font-size: clamp(26px, 3.4vw, 44px); line-height: 1.05; letter-spacing: -.03em; margin: 14px 0 10px; }
.pn-m-heroa p { color: var(--mu); font-size: 15.5px; max-width: 420px; }
.pn-m-ctas { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.pn-m-shot { background: var(--sf); border-radius: 20px; height: 260px; padding: 26px 26px 0; position: relative; }
.pn-m-float { position: absolute; left: -16px; bottom: 26px; background: var(--ac); color: var(--oac); border-radius: 14px; padding: 12px 16px; font-weight: 800; font-size: 22px; box-shadow: 0 14px 30px rgba(0, 0, 0, .18); }
.pn-m-float small { display: block; font-size: 11px; font-weight: 600; opacity: .85; }
.pn-m-feats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 20px 34px 34px; }
.pn-m-feats div { background: var(--sf); border-radius: 14px; padding: 16px; display: grid; gap: 4px; font-size: 13px; }
.pn-m-feats span { color: var(--mu); }
.pn-m-feats i { width: 34px; height: 34px; border-radius: 10px; background: var(--pr); margin-bottom: 6px; }
.pn-m-feats i.f1 { background: var(--ac); } .pn-m-feats i.f2 { background: var(--tx); }
.pn-m-dash { display: grid; grid-template-columns: 190px 1fr; }
.pn-m-dash aside { background: var(--sf); padding: 22px 14px; display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; }
.pn-m-dash aside .pn-m-logo { font-size: 18px; margin: 0 8px 16px; }
.pn-m-dash aside span { padding: 9px 10px; border-radius: 8px; color: var(--mu); }
.pn-m-dash aside span.on { background: var(--pr); color: var(--opr); font-weight: 600; }
.pn-m-dash section { padding: 22px 26px; display: grid; gap: 16px; align-content: start; }
.pn-m-dash header { display: flex; justify-content: space-between; align-items: center; font-size: 20px; }
.pn-m-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.pn-m-kpis div { background: var(--sf); border-radius: 14px; padding: 14px; display: grid; }
.pn-m-kpis small { color: var(--mu); } .pn-m-kpis b { font-size: 24px; } .pn-m-kpis em { color: var(--ac); font-style: normal; font-weight: 700; font-size: 12.5px; }
.pn-m-chart { background: var(--sf); border-radius: 14px; padding: 18px 18px 0; height: 160px; }
.pn-m-table { display: grid; gap: 6px; }
.pn-m-table div { display: flex; align-items: center; gap: 10px; background: var(--sf); border-radius: 10px; padding: 10px 14px; font-size: 13.5px; }
.pn-m-table span:first-child { flex: 1; }
.pn-m-tag { padding: 3px 9px; border-radius: 99px; font-size: 11.5px; font-weight: 700; background: var(--pr); color: var(--opr); }
.pn-m-tag.t1 { background: var(--ac); color: var(--oac); }
.pn-m-app { display: flex; justify-content: center; gap: 30px; padding: 34px; flex-wrap: wrap; background: var(--sf); }
.pn-m-phone { width: 250px; min-height: 470px; background: var(--bg); border-radius: 34px; padding: 18px 16px; box-shadow: 0 0 0 8px var(--tx), 0 30px 60px rgba(0, 0, 0, .25); display: flex; flex-direction: column; gap: 10px; }
.pn-m-status { display: flex; justify-content: space-between; font-size: 11px; font-weight: 700; padding: 0 6px; }
.pn-m-phone h4 { margin: 4px 0 0; font-size: 17px; } .pn-m-phone h5 { margin: 6px 0 0; font-size: 13px; color: var(--mu); }
.pn-m-card { background: var(--pr); color: var(--opr); border-radius: 18px; padding: 16px; display: grid; gap: 2px; }
.pn-m-card b { font-size: 22px; } .pn-m-card small, .pn-m-card span { opacity: .8; font-size: 12px; }
.pn-m-row { display: flex; justify-content: space-between; }
.pn-m-row span { display: grid; justify-items: center; gap: 4px; font-size: 11px; }
.pn-m-row i { width: 40px; height: 40px; border-radius: 12px; background: var(--sf); }
.pn-m-row span:first-child i { background: var(--ac); }
.pn-m-item { display: flex; align-items: center; gap: 10px; font-size: 12.5px; }
.pn-m-item i { width: 32px; height: 32px; border-radius: 10px; background: var(--sf); }
.pn-m-item span { flex: 1; display: grid; } .pn-m-item small { color: var(--mu); }
.pn-m-phone nav { margin-top: auto; display: flex; justify-content: space-around; font-size: 11px; color: var(--mu); padding-top: 10px; border-top: 1px solid var(--sf); }
.pn-m-phone nav .on { color: var(--pr); font-weight: 700; }
.pn-m-hero2 { height: 150px; border-radius: 18px; background: linear-gradient(135deg, var(--pr), var(--ac)); }
.pn-m-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pn-m-grid2 i { height: 70px; border-radius: 14px; }
.pn-m-phone button { margin-top: auto; border: 0; border-radius: 14px; padding: 13px; background: var(--ac); color: var(--oac); font-weight: 700; }
.pn-m-poster { display: grid; grid-template-columns: 1fr 1fr; min-height: 520px; }
.pn-m-art { position: relative; overflow: hidden; background: var(--sf); }
.pn-m-art i { position: absolute; border-radius: 50%; width: calc(40% + var(--i) * 6%); aspect-ratio: 1; left: calc(var(--i) * 13% - 8%); top: calc(10% + var(--i) * 12%); mix-blend-mode: multiply; opacity: .92; }
.pn-m-art i:nth-child(even) { border-radius: 24px; transform: rotate(18deg); }
.pn-m-ptxt { padding: 40px 36px; display: flex; flex-direction: column; justify-content: center; gap: 12px; }
.pn-m-ptxt small { color: var(--ac); font-weight: 800; text-transform: uppercase; letter-spacing: .14em; }
.pn-m-ptxt h3 { font-size: clamp(34px, 4.6vw, 62px); line-height: .95; margin: 0; letter-spacing: -.04em; }
.pn-m-ptxt p { color: var(--mu); }
.pn-m-ptxt .pn-m-btn { align-self: flex-start; }
.pn-m-brand { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: auto auto auto; gap: 22px; padding: 34px; align-items: center; }
.pn-m-logo-big { grid-row: span 2; display: grid; justify-items: center; gap: 2px; background: var(--sf); border-radius: 20px; padding: 40px; }
.pn-m-logo-big span { font-size: 64px; color: var(--pr); line-height: 1; } .pn-m-logo-big b { font-size: 34px; letter-spacing: -.03em; } .pn-m-logo-big small { color: var(--mu); letter-spacing: .3em; text-transform: uppercase; }
.pn-m-bcard { background: var(--pr); color: var(--opr); border-radius: 14px; padding: 22px; aspect-ratio: 1.75; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; position: relative; overflow: hidden; box-shadow: 0 14px 30px rgba(0, 0, 0, .2); }
.pn-m-bcard small { opacity: .8; } .pn-m-bcard span { font-size: 11px; opacity: .85; margin-top: 8px; }
.pn-m-bcard i { position: absolute; right: -30px; top: -30px; width: 110px; height: 110px; border-radius: 50%; background: var(--ac); }
.pn-m-bcard2 { background: var(--tx); color: var(--bg); align-items: center; justify-content: center; }
.pn-m-bcard2 span { font-size: 34px; color: var(--ac); opacity: 1; margin: 0; }
.pn-m-sw { grid-column: 1 / -1; display: flex; gap: 10px; flex-wrap: wrap; }
.pn-m-sw span { display: grid; gap: 4px; font: 11px var(--font-mono); color: var(--mu); }
.pn-m-sw i { width: 64px; height: 64px; border-radius: 14px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .06); }
.pn-m-pattern svg { display: block; width: 100%; height: 520px; }

/* ---------------- library */
.pn-lib-tabs { margin: 16px 0; }
.pn-lib-colors { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.pn-lib-color { position: relative; height: 130px; border-radius: 14px; background: var(--c); color: var(--t); overflow: hidden; }
.pn-lib-color a { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 12px; color: var(--t); text-decoration: none !important; }
.pn-lib-color span { font-size: 12px; opacity: .8; }
.pn-lib-color button { position: absolute; top: 6px; right: 6px; border: 0; background: rgba(255, 255, 255, .85); border-radius: 8px; width: 28px; height: 28px; display: grid; place-items: center; cursor: pointer; color: #111; }

/* ---------------- responsive */
@media (max-width: 1600px) { .hide-xl { display: none !important; } }
@media (max-width: 1100px) { .pn-feats { grid-template-columns: repeat(2, 1fr); } .hide-md { display: none !important; } }
@media (max-width: 860px) {
  .pn-hero-grid { grid-template-columns: 1fr; }
  .pn-hero-demo { height: 220px; }
  .pn-m-heroa, .pn-m-poster, .pn-m-brand { grid-template-columns: 1fr; }
  .pn-m-dash { grid-template-columns: 1fr; } .pn-m-dash aside { flex-direction: row; overflow-x: auto; } .pn-m-dash aside .pn-m-logo { display: none; }
  .pn-m-feats, .pn-m-kpis { grid-template-columns: 1fr; }
  .pn-exp { grid-template-columns: 1fr; } .pn-exp-list { flex-direction: row; flex-wrap: wrap; }
}
@media (max-width: 700px) {
  .pn-gen { flex-direction: column; }
  .pn-col { flex-direction: row; justify-content: space-between; padding: 0 12px; }
  .pn-col-tools { flex-direction: row; margin: 0; opacity: 1; order: 3; }
  .pn-col-tools button { width: 34px; height: 34px; }
  .pn-col-tools [data-act="drag"], .pn-col-tools [data-act="save-color"] { display: none; }
  .pn-col.locked .pn-col-tools button:not(.pn-lock) { opacity: 1; }
  .pn-col-hex { font-size: 18px; }
  .pn-col-name { display: none; }
  .pn-add { display: none; }
  .pn-gbar { gap: 4px; padding: 0 6px; }
  .pn-gbar-tools { overflow-x: auto; }
  .pn-feats { grid-template-columns: 1fr; }
  .pn-pal-big { flex-direction: column; height: auto; } .pn-pal-big a { height: 70px; flex-direction: row; justify-content: space-between; padding: 0 16px; }
  .pn-m-phone2 { display: none; }
}

/* text on surface cards uses its own best-contrast colour */
.pn-m-pill, .pn-m-feats div, .pn-m-kpis div, .pn-m-table div, .pn-m-dash aside, .pn-m-logo-big, .pn-m-app { color: var(--osf); }
.pn-m-feats span, .pn-m-kpis small, .pn-m-dash aside span, .pn-m-logo-big small { color: var(--msf); }
.pn-vis-mini { max-height: none; }
.pn-m-phone { color: var(--tx); }
.pn-m-kpis em { color: var(--osf); opacity: .75; }
