/* Artist page /@username: standalone "link in bio" layout (views/color4u/en/users/profile.php),
   plus the "Meet our artists" cards and the sample-page phone mockup on /artist-community.
   Themes are .pfx--{key}; the keys match ARTIST_THEMES in includes/artist_profile.php. */

.pfx {
  --pfx-ink: #1a2238;
  --pfx-ink-2: #4a5375;
  --pfx-ink-3: #7e87a6;
  --pfx-btn: #ffffff;
  --pfx-btn-ink: #1a2238;
  --pfx-btn-line: rgba(26, 34, 56, .08);
  --pfx-spot: oklch(56% 0.18 256);
  --pfx-spot-ink: #ffffff;
  --pfx-chip: rgba(255, 255, 255, .7);
  --pfx-bg: linear-gradient(160deg, #dfe6ff 0%, #f4ecff 45%, #fde4ef 100%);
  --pfx-blob-1: rgba(255, 214, 102, .55);
  --pfx-blob-2: rgba(244, 143, 177, .45);
  --pfx-blob-3: rgba(128, 203, 180, .45);
  position: relative;
  margin: 0;
  min-height: 100vh;
  color: var(--pfx-ink);
  font-family: "Nunito Sans", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  background: #f4f1fb;
}
.pfx *, .pfx *::before, .pfx *::after { box-sizing: border-box; }
/* zero specificity, so every component's own color wins */
:where(.pfx) a { color: inherit; }

/* themes */
.pfx--sunset { --pfx-bg: linear-gradient(160deg, #ffe7cc 0%, #ffd0bf 50%, #ffb3a7 100%); --pfx-spot: #e2553f; --pfx-blob-1: rgba(255, 196, 0, .4); --pfx-blob-2: rgba(255, 112, 67, .35); --pfx-blob-3: rgba(255, 255, 255, .5); }
.pfx--mint { --pfx-bg: linear-gradient(160deg, #e3f8ef 0%, #c8eedf 55%, #a7e0cb 100%); --pfx-spot: #138a6b; --pfx-blob-1: rgba(255, 255, 255, .55); --pfx-blob-2: rgba(77, 182, 172, .35); --pfx-blob-3: rgba(174, 213, 129, .45); }
.pfx--lavender { --pfx-bg: linear-gradient(160deg, #f1ebff 0%, #e0d4ff 55%, #cbb8f7 100%); --pfx-spot: #6b4fd8; --pfx-blob-1: rgba(255, 255, 255, .55); --pfx-blob-2: rgba(186, 104, 200, .3); --pfx-blob-3: rgba(121, 134, 203, .35); }
.pfx--midnight {
  --pfx-ink: #f5f6fb; --pfx-ink-2: #c9cde0; --pfx-ink-3: #9aa0bd;
  --pfx-btn: rgba(255, 255, 255, .08); --pfx-btn-ink: #ffffff; --pfx-btn-line: rgba(255, 255, 255, .16);
  --pfx-spot: #ffd166; --pfx-spot-ink: #1b2140; --pfx-chip: rgba(255, 255, 255, .12);
  --pfx-bg: linear-gradient(160deg, #141a35 0%, #241f4f 60%, #3a2f6b 100%);
  --pfx-blob-1: rgba(255, 209, 102, .18); --pfx-blob-2: rgba(239, 71, 111, .18); --pfx-blob-3: rgba(6, 214, 160, .14);
  background: #141a35;
}
.pfx--art { --pfx-bg: #f6f5f2; --pfx-spot: #1a2238; --pfx-blob-1: transparent; --pfx-blob-2: transparent; --pfx-blob-3: transparent; }

.pfx-bg { position: fixed; inset: 0; z-index: 0; background: var(--pfx-bg); overflow: hidden; }
.pfx-bg::before, .pfx-bg::after { content: ""; position: absolute; border-radius: 50%; filter: blur(2px); }
.pfx-bg::before { width: 46vmax; height: 46vmax; left: -14vmax; top: -16vmax; background: radial-gradient(circle, var(--pfx-blob-1) 0 60%, transparent 61%); }
.pfx-bg::after { width: 40vmax; height: 40vmax; right: -12vmax; bottom: -14vmax; background: radial-gradient(circle, var(--pfx-blob-2) 0 60%, transparent 61%), radial-gradient(circle at 10% 10%, var(--pfx-blob-3) 0 30%, transparent 31%); }
.pfx--art .pfx-bg::before { width: auto; height: auto; inset: 0; border-radius: 0; filter: none; background: var(--pfx-art) center / 260px repeat; opacity: .09; }
.pfx--art .pfx-bg::after { display: none; }

/* top bar */
.pfx-top { position: relative; z-index: 2; display: flex; justify-content: space-between; align-items: center; max-width: 640px; margin: 0 auto; padding: 16px 16px 0; }
.pfx-top__r { display: flex; gap: 8px; }
.pfx-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--pfx-btn-line); background: var(--pfx-chip); color: var(--pfx-ink); cursor: pointer; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); transition: transform .15s; }
.pfx-icon:hover { transform: scale(1.06); }
.pfx-chip { display: inline-flex; align-items: center; height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--pfx-btn-line); background: var(--pfx-chip); color: var(--pfx-ink); font: inherit; font-weight: 800; font-size: 14px; text-decoration: none; cursor: pointer; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.pfx-chip:hover { text-decoration: none; filter: brightness(1.03); }

/* column */
.pfx-col { position: relative; z-index: 1; max-width: 640px; margin: 0 auto; padding: 8px 20px 32px; }
.pfx-id { text-align: center; }
.pfx-avatar { width: 128px; height: 128px; border-radius: 50%; object-fit: cover; display: grid; place-items: center; margin: 0 auto 16px; border: 5px solid #fff; box-shadow: 0 12px 32px rgba(20, 30, 60, .18); background: #ece9ff; color: #5b4bd6; font-family: "Quicksand", system-ui, sans-serif; font-weight: 700; font-size: 52px; }
.pfx-name { margin: 0; font-family: "Quicksand", system-ui, sans-serif; font-weight: 700; font-size: clamp(28px, 6vw, 36px); line-height: 1.15; letter-spacing: -.01em; overflow-wrap: anywhere; }
.pfx-verified { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--pfx-spot); color: var(--pfx-spot-ink); font-size: 13px; font-weight: 800; vertical-align: 4px; }
.pfx-headline { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; margin: 8px 0 0; font-weight: 700; color: var(--pfx-ink-2); font-size: 16px; }
.pfx-loc { display: inline-flex; align-items: center; gap: 4px; color: var(--pfx-ink-3); font-weight: 600; }
.pfx-bio { margin: 14px auto 0; max-width: 52ch; }
.pfx-bio p { margin: 0 0 8px; font-size: 16px; line-height: 1.6; color: var(--pfx-ink-2); }
.pfx-bio p:last-child { margin-bottom: 0; }
.pfx-social { display: flex; justify-content: center; gap: 10px; margin-top: 18px; }
.pfx-social a { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; background: var(--pfx-btn); color: var(--pfx-btn-ink); border: 1px solid var(--pfx-btn-line); box-shadow: 0 2px 8px rgba(20, 30, 60, .06); transition: transform .15s; }
.pfx-social a:hover { transform: translateY(-2px); }

/* link buttons */
.pfx-links { display: grid; gap: 12px; margin-top: 26px; }
.pfx-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px; position: relative;
  min-height: 58px; padding: 12px 52px; border-radius: 18px;
  background: var(--pfx-btn); color: var(--pfx-btn-ink); border: 1px solid var(--pfx-btn-line);
  box-shadow: 0 2px 10px rgba(20, 30, 60, .06);
  font: inherit; font-weight: 800; font-size: 16px; text-align: center; text-decoration: none; cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}
.pfx .pfx-btn, .pfx .pfx-btn:hover { text-decoration: none; }
.pfx-btn:hover { transform: translateY(-2px) scale(1.01); box-shadow: 0 10px 24px rgba(20, 30, 60, .12); }
.pfx-btn svg:first-child:not(:last-child) { position: absolute; left: 20px; opacity: .7; }
.pfx-btn--spot { background: var(--pfx-spot); color: var(--pfx-spot-ink); border-color: transparent; min-height: 64px; font-size: 17px; box-shadow: 0 10px 26px color-mix(in srgb, var(--pfx-spot) 40%, transparent); }
.pfx-btn--spot svg { position: absolute; right: 22px; }

/* owner strip */
.pfx-owner { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-top: 18px; padding: 12px 14px 12px 18px; border-radius: 16px; background: rgba(255, 220, 120, .55); color: #5a4300; font-weight: 700; font-size: 14px; }
.pfx--midnight .pfx-owner { background: rgba(255, 209, 102, .16); color: #ffe7a6; }
.pfx-owner .pfx-chip { background: #fff; color: #1a2238; }

/* coloring pages */
.pfx-pages { margin-top: 40px; }
.pfx-pages__head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.pfx-pages__head h2 { margin: 0; font-family: "Quicksand", system-ui, sans-serif; font-weight: 700; font-size: 22px; }
.pfx-pages__head span { font-size: 14px; font-weight: 700; color: var(--pfx-ink-3); }
.pfx-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.pfx-card { display: flex; flex-direction: column; border-radius: 16px; overflow: hidden; background: #fff; color: #1a2238; text-decoration: none; box-shadow: 0 2px 10px rgba(20, 30, 60, .07); transition: transform .15s, box-shadow .15s; }
.pfx-card:hover { transform: translateY(-3px); box-shadow: 0 12px 26px rgba(20, 30, 60, .14); text-decoration: none; color: #1a2238; }
.pfx-card.is-more { display: none; }
.pfx-card__img { aspect-ratio: 4 / 5; padding: 8px; overflow: hidden; background: #fff; }
.pfx-card__img img { width: 100%; height: 100%; object-fit: contain; display: block; }
.pfx-card__img.is-missing { background: #f4f5f9 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 24 24' fill='none' stroke='%23c3c9dc' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='18' height='18' rx='2'/%3E%3Ccircle cx='8.5' cy='8.5' r='1.5'/%3E%3Cpolyline points='21 15 16 10 5 21'/%3E%3C/svg%3E") center / 40px no-repeat; }
.pfx-card__b { padding: 8px 10px 10px; border-top: 1px solid #f0f2f8; display: flex; flex-direction: column; gap: 2px; }
.pfx-card__b strong { font-size: 13px; line-height: 1.3; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.pfx-card__b span { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; color: #7e87a6; }
.pfx-more { width: 100%; margin-top: 14px; min-height: 50px; }
.pfx-empty { text-align: center; padding: 34px 20px; border-radius: 20px; background: var(--pfx-btn); border: 2px dashed var(--pfx-btn-line); color: var(--pfx-ink-2); }
.pfx-empty b { display: block; font-family: "Quicksand", system-ui, sans-serif; font-size: 19px; color: var(--pfx-ink); margin-bottom: 4px; }

/* footer: the only Color4U branding on the page */
.pfx-foot { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 12px 20px 36px; text-align: center; }
.pfx-made { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; background: #fff; color: #4a5375; font-size: 13px; font-weight: 700; text-decoration: none; box-shadow: 0 2px 10px rgba(20, 30, 60, .08); }
.pfx-made img { height: 22px; width: auto; display: block; }
.pfx-join { font-size: 14px; font-weight: 700; color: var(--pfx-ink-2); }
.pfx-legal { display: flex; gap: 14px; font-size: 12px; }
.pfx-legal a { color: var(--pfx-ink-3); text-decoration: none; }
.pfx-legal a:hover { text-decoration: underline; }

/* QR dialog + toast */
.pfx-qr { border: 0; border-radius: 24px; padding: 26px; width: min(340px, calc(100vw - 32px)); text-align: center; color: #1a2238; box-shadow: 0 30px 80px rgba(20, 30, 60, .3); }
.pfx-qr::backdrop { background: rgba(20, 26, 53, .55); backdrop-filter: blur(3px); }
.pfx-qr h2 { margin: 0 0 16px; font-family: "Quicksand", system-ui, sans-serif; font-size: 20px; }
.pfx-qr__code { display: grid; place-items: center; min-height: 220px; }
.pfx-qr__code img, .pfx-qr__code canvas { margin: 0 auto; }
.pfx-qr p { margin: 12px 0 16px; font-weight: 700; color: #4a5375; }
.pfx-qr__a { display: flex; gap: 8px; justify-content: center; }
.pfx-qr .pfx-chip { background: #f1f3f9; color: #1a2238; border-color: #e6e8f2; }
.pfx-toast { position: fixed; left: 50%; bottom: 24px; z-index: 60; transform: translate(-50%, 16px); opacity: 0; pointer-events: none; background: #1a2238; color: #fff; padding: 10px 18px; border-radius: 999px; font-weight: 800; font-size: 14px; transition: opacity .2s, transform .2s; }
.pfx-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 520px) {
  .pfx-col { padding: 4px 16px 24px; }
  .pfx-avatar { width: 112px; height: 112px; font-size: 44px; }
  .pfx-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .pfx-btn { padding: 12px 46px; }
}
@media (prefers-reduced-motion: reduce) { .pfx * { transition: none !important; } }

/* ── /artist-community ─────────────────────────────────── */
.ac-artists { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; margin-top: 18px; }
.ac-artist { display: flex; flex-direction: column; gap: 14px; padding: 18px; background: var(--paper); border: 1px solid var(--line); border-radius: 20px; color: inherit; text-decoration: none; transition: transform .15s, box-shadow .15s; }
.ac-artist:hover { transform: translateY(-3px); box-shadow: var(--shadow); color: inherit; text-decoration: none; }
.ac-artist__top { display: flex; align-items: center; gap: 12px; }
.ac-artist__av { width: 60px; height: 60px; border-radius: 50%; object-fit: cover; flex: none; display: grid; place-items: center; background: var(--primary-soft); color: var(--primary); font-family: var(--font-display); font-weight: 700; font-size: 24px; border: 3px solid #fff; box-shadow: 0 4px 12px rgba(20, 30, 60, .12); }
.ac-artist__top strong { display: block; font-size: 17px; color: var(--ink); }
.ac-artist__top small { color: var(--ink-3); font-weight: 600; }
.ac-artist__thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ac-artist__thumbs span { aspect-ratio: 4 / 5; border-radius: 10px; border: 1px solid var(--line-2); background: #fff; display: grid; place-items: center; overflow: hidden; }
.ac-artist__thumbs img { width: 92%; height: 92%; object-fit: contain; }
.ac-artist__soon { grid-column: 1 / -1; aspect-ratio: auto !important; padding: 18px; font-size: 13px; font-weight: 600; color: var(--ink-3); background: var(--bg) !important; border-style: dashed !important; }
.ac-artist__foot { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 12px; flex-wrap: wrap; margin-top: auto; }
.ac-artist__stats { font-size: 13px; font-weight: 600; color: var(--ink-3); }
.ac-artist__more { font-size: 14px; font-weight: 700; color: var(--primary-ink); }

.ac-sample { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: center; margin-top: 18px; }
.ac-sample__copy ul { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.ac-sample__copy li { display: flex; gap: 10px; color: var(--ink-2); line-height: 1.5; }
.ac-sample__copy li::before { content: "✓"; flex: none; width: 24px; height: 24px; border-radius: 50%; background: oklch(95% 0.04 165); color: oklch(42% 0.09 165); display: grid; place-items: center; font-weight: 800; font-size: 13px; }
.ac-sample__themes { display: flex; align-items: center; gap: 8px; margin-top: 20px; flex-wrap: wrap; font-size: 14px; font-weight: 700; color: var(--ink-3); }
.ac-sample__themes button { width: 32px; height: 32px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); cursor: pointer; padding: 0; }
.ac-sample__themes button[aria-pressed="true"] { box-shadow: 0 0 0 3px var(--primary); }

/* phone mockup holding a scaled-down page */
.ac-phone { position: relative; width: 300px; max-width: 100%; margin: 0 auto; padding: 10px; border-radius: 44px; background: #1a2238; box-shadow: 0 30px 60px rgba(20, 30, 60, .25); }
.ac-phone__tag { position: absolute; top: -12px; right: -8px; z-index: 3; background: #ffd166; color: #1a2238; font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; padding: 5px 12px; border-radius: 999px; transform: rotate(4deg); box-shadow: 0 6px 14px rgba(20, 30, 60, .2); }
.ac-phone .pfx { min-height: 0; height: 560px; overflow: hidden; border-radius: 34px; }
.ac-phone .pfx-bg { position: absolute; }
/* background circles sized to the phone frame, not the browser window */
.ac-phone .pfx-bg::before { width: 230px; height: 230px; left: -90px; top: -100px; }
.ac-phone .pfx-bg::after { width: 260px; height: 260px; right: -110px; bottom: -110px; }
.ac-phone .pfx-top { padding: 12px 12px 0; }
.ac-phone .pfx-icon { width: 32px; height: 32px; }
.ac-phone .pfx-icon svg { width: 14px; height: 14px; }
.ac-phone .pfx-col { padding: 0 14px; }
.ac-phone .pfx-avatar { width: 76px; height: 76px; font-size: 30px; border-width: 4px; margin-bottom: 10px; }
.ac-phone .pfx-name { font-size: 22px; }
.ac-phone .pfx-headline { font-size: 13px; margin-top: 4px; }
.ac-phone .pfx-bio { margin-top: 8px; }
.ac-phone .pfx-bio p { font-size: 12.5px; line-height: 1.5; }
.ac-phone .pfx-social { margin-top: 10px; gap: 8px; }
.ac-phone .pfx-social span { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; background: var(--pfx-btn); color: var(--pfx-btn-ink); border: 1px solid var(--pfx-btn-line); }
.ac-phone .pfx-links { margin-top: 14px; gap: 8px; }
.ac-phone .pfx-btn { min-height: 40px; padding: 8px 30px; font-size: 13px; border-radius: 13px; }
.ac-phone .pfx-btn--spot { min-height: 44px; font-size: 13.5px; }
.ac-phone .pfx-btn svg { width: 13px; height: 13px; }
.ac-phone .pfx-btn svg:first-child:not(:last-child) { left: 12px; }
.ac-phone .pfx-btn--spot svg { right: 14px; }
.ac-phone .pfx-pages { margin-top: 16px; }
.ac-phone .pfx-pages__head h2 { font-size: 15px; }
.ac-phone .pfx-pages__head span { font-size: 11px; }
.ac-phone .pfx-grid { gap: 6px; }
.ac-phone .pfx-card { border-radius: 10px; }
.ac-phone .pfx-card__img { padding: 4px; }
@media (max-width: 860px) { .ac-sample { grid-template-columns: 1fr; gap: 28px; } }
