:root {
	--wp-accent: #e0704f;
	--wp-accent-ink: #fff;
	--wp-ink: #1f2933;
	--wp-muted: #6b7280;
	--wp-bg: #f6f1ea;
	--wp-card: #fff;
	--wp-line: #e5ddd2;
	--wp-radius: 16px;
}
.wp-locked, .wp-locked body { overflow: hidden; }

.wowpapy-cta, .wp-btn {
	font: inherit; cursor: pointer; border-radius: 999px; border: 1px solid var(--wp-line);
	padding: .8em 1.4em; background: var(--wp-card); color: var(--wp-ink);
}
.wowpapy-cta, .wp-btn-primary { background: var(--wp-accent); color: var(--wp-accent-ink); border-color: var(--wp-accent); font-weight: 600; }
.wp-btn-dark { background: var(--wp-ink); color: #fff; border-color: var(--wp-ink); font-weight: 600; width: 100%; }
.wp-btn[disabled] { opacity: .45; cursor: not-allowed; }

.wp-overlay { position: fixed; inset: 0; z-index: 99999; background: rgba(20,20,20,.45); display: grid; place-items: center; padding: 16px; }
.wp-modal { position: relative; width: 100%; max-width: 460px; background: var(--wp-card); color: var(--wp-ink); border-radius: var(--wp-radius); padding: 24px; display: grid; gap: 10px; }
.wp-modal h2 { margin: 0; font-size: 1.35rem; }
.wp-modal input[type=text] { font: inherit; padding: .75em 1em; border: 1px solid var(--wp-line); border-radius: 12px; }
.wp-modal input[type=text]:focus { outline: 2px solid var(--wp-accent); border-color: transparent; }
.wp-label { font-weight: 600; margin-top: 6px; }
.wp-modal label[for] { font-weight: 600; }
.wp-chips { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.wp-chip { font: inherit; padding: .7em .5em; border-radius: 12px; border: 1px solid var(--wp-line); background: var(--wp-card); cursor: pointer; }
.wp-chip.is-on { border-color: var(--wp-accent); box-shadow: inset 0 0 0 1px var(--wp-accent); }
.wp-consent { display: flex; gap: 8px; align-items: flex-start; font-size: .9rem; color: var(--wp-muted); }
.wp-x { position: absolute; top: 12px; right: 12px; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--wp-line); background: var(--wp-card); font-size: 20px; line-height: 1; cursor: pointer; }
.wp-muted { color: var(--wp-muted); }
.wp-small { font-size: .85rem; text-align: center; }

.wp-app { position: fixed; inset: 0; z-index: 99998; background: var(--wp-bg); color: var(--wp-ink); display: flex; flex-direction: column; }
.wp-head { position: relative; display: flex; justify-content: space-between; align-items: center; padding: 12px 64px 12px 16px; background: var(--wp-card); border-bottom: 1px solid var(--wp-line); }
.wp-pages { flex: 1; overflow-y: auto; padding: 16px; display: grid; gap: 20px; justify-items: center; align-content: start; }
.wp-page { width: 100%; max-width: 520px; }
.wp-page-label { text-align: center; font-size: .85rem; color: var(--wp-muted); margin-bottom: 6px; }
.wp-cover-art { position: relative; aspect-ratio: 1; border-radius: var(--wp-radius); overflow: hidden; background: linear-gradient(135deg, #ffe7d6, #d9f0ff); display: grid; place-items: center; }
.wp-cover-art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.wp-cover-title { position: relative; font-size: clamp(1.6rem, 7vw, 2.6rem); font-weight: 800; color: #fff; text-align: center; padding: 0 16px; text-shadow: 0 2px 0 var(--wp-accent), 0 4px 12px rgba(0,0,0,.25); }
.wp-slot { position: relative; aspect-ratio: 1; border-radius: var(--wp-radius); background: var(--wp-card); border: 2px dashed var(--wp-line); display: grid; place-items: center; color: var(--wp-muted); text-align: center; padding: 16px; }
.wp-slot.is-over { border-color: var(--wp-accent); }
.wp-slot.has-img { border-style: solid; padding: 0; overflow: hidden; }
.wp-slot.has-img img { width: 100%; height: 100%; object-fit: contain; }
.wp-slot.has-error { border-color: #d64545; color: #d64545; }
.wp-slot.is-loading { display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 10px; }
.wp-tools { position: absolute; top: 10px; left: 10px; right: 10px; display: flex; justify-content: space-between; }
.wp-icon { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--wp-line); background: rgba(255,255,255,.92); cursor: pointer; font-size: 16px; }
.wp-spin { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--wp-line); border-top-color: var(--wp-accent); animation: wp-spin .8s linear infinite; }
@keyframes wp-spin { to { transform: rotate(360deg); } }
.wp-add { width: 100%; max-width: 520px; }
.wp-bar { background: var(--wp-card); border-top: 1px solid var(--wp-line); padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); display: grid; gap: 8px; }
.wp-bar-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
/* Keep header and close button below the WordPress admin bar. */
.admin-bar .wp-app, .admin-bar .wp-overlay { top: 32px; }
@media (max-width: 782px) { .admin-bar .wp-app, .admin-bar .wp-overlay { top: 46px; } }
.wp-notice { text-align: center; font-size: .9rem; color: var(--wp-ink); }
.wp-notice.is-error { color: #d64545; }
.wp-toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 99999; max-width: calc(100% - 32px); background: var(--wp-ink); color: #fff; border-radius: 14px; padding: 14px 56px 14px 18px; box-shadow: 0 8px 30px rgba(0,0,0,.2); }
.wp-toast.is-error { background: #8a2c2c; }
.wp-toast .wp-x { top: 50%; transform: translateY(-50%); right: 10px; width: 30px; height: 30px; font-size: 16px; }
@media (prefers-reduced-motion: reduce) { .wp-spin { animation: none; } }
