/*
 * GuestPostPro Marketplace — dashboard and form styles.
 * Uses the GuestPostPro theme's variables when present, with fallbacks so
 * the dashboards also look tidy in other themes.
 */
.gpp-app {
	--a-ink: var(--gpp-ink, #0F1E3D);
	--a-muted: var(--gpp-muted, #5B6785);
	--a-border: var(--gpp-border, #E3E8F2);
	--a-border-strong: var(--gpp-border-strong, #D5DCEA);
	--a-subtle: var(--gpp-bg-subtle, #F5F7FB);
	--a-primary: var(--gpp-primary, #1F5EFF);
	--a-primary-50: var(--gpp-primary-50, #EEF3FF);
	display: flex; flex-direction: column; gap: 20px; color: var(--a-ink);
}
.gpp-app *, .gpp-register * { box-sizing: border-box; }

/* Fallbacks for themes without GuestPostPro styles (low specificity). */
:where(.gpp-app, .gpp-register) :where(.gpp-card) { background: #fff; border: 1px solid #E3E8F2; border-radius: 14px; }
:where(.gpp-app, .gpp-register) :where(.gpp-btn) { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px; border-radius: 10px; border: 1px solid transparent; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; }
:where(.gpp-app, .gpp-register) :where(.gpp-btn--primary) { background: #1F5EFF; color: #fff; }
:where(.gpp-app, .gpp-register) :where(.gpp-btn--outline) { background: #fff; color: #0F1E3D; border-color: #D5DCEA; }
:where(.gpp-app, .gpp-register) :where(.gpp-btn--sm) { min-height: 34px; padding: 0 12px; font-size: 14px; }
:where(.gpp-app, .gpp-register) :where(.gpp-input) { width: 100%; min-height: 44px; padding: 8px 12px; border: 1px solid #D5DCEA; border-radius: 8px; font: inherit; background: #fff; }
:where(.gpp-app, .gpp-register) :where(.gpp-badge) { display: inline-flex; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: #EEF1F6; }
:where(.gpp-app, .gpp-register) :where(.gpp-alert) { padding: 12px 16px; border-radius: 12px; background: #EAF1FE; }
:where(.gpp-app) :where(.gpp-muted) { color: #5B6785; }
:where(.gpp-app) :where(.gpp-small) { font-size: 13px; }

/* Extra button tones */
.gpp-btn--success { background: #16A34A; color: #fff; border-color: #16A34A; }
.gpp-btn--success:hover { background: #11833C; color: #fff; }
.gpp-btn--danger { background: #fff; color: #A61B1B; border-color: #F3C4C4; }
.gpp-btn--danger:hover { background: #FDECEC; color: #A61B1B; }
.gpp-text-bad { color: #A61B1B; }
.gpp-text-ok { color: #11733A; }

/* Page head */
.gpp-app__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; }
.gpp-app__title { font-size: 26px; margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; letter-spacing: -0.02em; }
.gpp-app__sub { margin: 4px 0 0; color: var(--a-muted); }
.gpp-app__h2 { font-size: 17px; margin: 0 0 12px; }
.gpp-app__h3 { font-size: 16px; margin: 0; }
.gpp-app__back { font-weight: 600; font-size: 14px; }
.gpp-app__alert { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 0; }
.gpp-app > .gpp-alert { margin: 0; }

/* Panels & layout */
.gpp-app__panel { overflow: hidden; }
.gpp-app__pad { padding: 22px; }
.gpp-app__panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--a-border); }
.gpp-app__panel-head .gpp-app__h2 { margin: 0; }
.gpp-app__panel-head p { margin: 0; }
.gpp-app__split { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.gpp-app__split > .gpp-app__col-main, .gpp-app__split > .gpp-app__panel--wide { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.gpp-app__split > .gpp-app__col-side, .gpp-app__split > .gpp-app__panel:not(.gpp-app__panel--wide):not(.gpp-app__col-main) { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.gpp-app__actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.gpp-inline-form { display: inline; margin: 0; }
.gpp-app__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.gpp-app__list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 0; border-top: 1px solid var(--a-border); }
.gpp-app__list li:first-child { border-top: 0; padding-top: 0; }
.gpp-app__pager { display: flex; gap: 12px; align-items: center; justify-content: center; }
.gpp-action-box { border-color: var(--a-primary); box-shadow: 0 0 0 1px var(--a-primary); }
.gpp-action-box > * + * { margin-top: 12px; }
.gpp-action-box--tint { background: var(--a-primary-50); border-radius: 12px; padding: 16px; margin-top: 14px; }
.gpp-subform { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--a-border); }
.gpp-subform[hidden] { display: none; }
.gpp-form-stack { display: flex; flex-direction: column; gap: 16px; }

/* Stats */
.gpp-stats { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.gpp-stat { padding: 18px 20px; display: flex; flex-direction: column; gap: 4px; }
.gpp-stat span { font-size: 13px; font-weight: 500; color: var(--a-muted); }
.gpp-stat strong { font-size: 28px; letter-spacing: -0.02em; line-height: 1.2; }
.gpp-stat strong.is-ok { color: #11733A; }
.gpp-stat strong.is-info { color: #1D4ED8; }
.gpp-stat em { font-style: normal; font-size: 12px; color: var(--a-muted); }

/* Tables */
.gpp-table-wrap { overflow-x: auto; position: relative; }
.gpp-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.gpp-table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--a-muted); font-weight: 600; padding: 12px 18px; background: #F7F9FC; border-bottom: 1px solid var(--a-border); white-space: nowrap; }
.gpp-table td { padding: 13px 18px; border-bottom: 1px solid #EEF1F6; vertical-align: middle; }
.gpp-table tr:last-child td { border-bottom: 0; }

/* Tabs + search */
.gpp-app__toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; align-items: center; }
.gpp-tabs { display: flex; flex-wrap: wrap; gap: 6px; }
.gpp-tab { display: inline-flex; align-items: center; gap: 4px; min-height: 38px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--a-border-strong); background: #fff; color: var(--a-ink); font-weight: 600; font-size: 13px; text-decoration: none; }
.gpp-tab span { color: var(--a-muted); font-weight: 500; }
.gpp-tab.is-current { background: var(--gpp-navy-900, #0B1B3F); border-color: var(--gpp-navy-900, #0B1B3F); color: #fff; }
.gpp-tab.is-current span { color: #C9D3EA; }
.gpp-tab:hover { text-decoration: none; }
.gpp-app__search { display: flex; gap: 8px; flex: 0 1 340px; }

/* Order steps */
.gpp-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.gpp-steps__item { position: relative; display: flex; flex-direction: column; gap: 4px; padding-top: 42px; font-size: 13px; }
.gpp-steps__dot { position: absolute; top: 0; left: 0; z-index: 1; width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--a-border-strong); background: #fff; display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--a-muted); }
.gpp-steps__item::before { content: ""; position: absolute; top: 15px; left: 32px; right: 0; height: 2px; background: var(--a-border-strong); }
.gpp-steps__item:last-child::before { display: none; }
.gpp-steps__item.is-done .gpp-steps__dot { background: var(--a-primary); border-color: var(--a-primary); color: #fff; }
.gpp-steps__item.is-done::before { background: var(--a-primary); }
.gpp-steps__item.is-current .gpp-steps__dot { border-color: var(--a-primary); color: var(--a-primary); }
.gpp-steps__item.is-stopped { opacity: .45; }
@media (max-width: 640px) {
	.gpp-steps { grid-template-columns: 1fr; gap: 12px; }
	.gpp-steps__item { padding: 4px 0 0 44px; min-height: 32px; }
	.gpp-steps__item::before { display: none; }
}

/* Key/value lists */
.gpp-kv { margin: 0; display: flex; flex-direction: column; }
.gpp-kv > div { display: grid; grid-template-columns: minmax(110px, 30%) 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid #EEF1F6; font-size: 14px; }
.gpp-kv > div:last-child { border-bottom: 0; }
.gpp-kv dt { color: var(--a-muted); }
.gpp-kv dd { margin: 0; overflow-wrap: anywhere; }
.gpp-kv--tight > div { grid-template-columns: 1fr auto; }
.gpp-kv--tight dd { text-align: right; }
.gpp-kv .is-total { font-size: 17px; font-weight: 700; border-top: 1px solid var(--a-border); }
.gpp-kv .is-total dt { color: var(--a-ink); }
.gpp-linkbox { padding: 12px 14px; background: #F7F9FC; border: 1px solid var(--a-border); border-radius: 10px; overflow-wrap: anywhere; margin: 0; }

/* Threads, history, feed */
.gpp-thread { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.gpp-thread li { align-self: flex-start; max-width: 85%; padding: 10px 14px; border-radius: 12px; background: #F2F4F8; }
.gpp-thread li.is-mine { align-self: flex-end; background: var(--a-primary-50); }
.gpp-thread p { margin: 0; }
.gpp-thread p + p { margin-top: 4px; }
.gpp-thread__form { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; }
.gpp-thread__form textarea { flex: 1 1 240px; }
.gpp-history { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.gpp-history li { display: flex; flex-direction: column; gap: 2px; padding-left: 14px; border-left: 2px solid var(--a-border-strong); }
.gpp-feed { list-style: none; margin: 0; padding: 4px 20px 12px; }
.gpp-feed li { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid #EEF1F6; }
.gpp-feed li:last-child { border-bottom: 0; }
.gpp-feed p { margin: 0; }
.gpp-feed__dot { width: 9px; height: 9px; border-radius: 50%; background: var(--a-border-strong); margin-top: 7px; flex: none; }
.gpp-feed .is-unread .gpp-feed__dot { background: var(--a-primary); }
.gpp-feed .is-unread p:first-child { font-weight: 600; }

/* Forms */
.gpp-listing-form { padding: 0; }
.gpp-form-section { border: 0; margin: 0; padding: 22px; border-bottom: 1px solid var(--a-border); display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.gpp-form-section legend { font-size: 17px; font-weight: 700; padding: 0; float: left; width: 100%; margin-bottom: 4px; }
.gpp-form-section legend + * { clear: both; }
.gpp-form-grid { display: grid; gap: 14px 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }
.gpp-form-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 10px; padding: 18px 22px; background: #F7F9FC; }
.gpp-field { display: flex; flex-direction: column; gap: 6px; }
.gpp-field--indent { margin-left: 28px; }
.gpp-input--file { padding: 9px 12px; }
.gpp-code { display: block; padding: 12px; background: #F7F9FC; border: 1px solid var(--a-border); border-radius: 8px; font-size: 13px; overflow-wrap: anywhere; }
.gpp-choice-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.gpp-choice { display: flex; justify-content: space-between; align-items: center; gap: 8px; min-height: 52px; padding: 12px 14px; border: 1px solid var(--a-border-strong); border-radius: 10px; color: var(--a-ink); text-decoration: none; }
.gpp-choice:hover { border-color: var(--a-primary); text-decoration: none; color: var(--a-ink); }
.gpp-choice.is-selected { border-color: var(--a-primary); background: #F4F7FF; box-shadow: 0 0 0 1px var(--a-primary); }
.gpp-checks { margin: 0; padding-left: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.gpp-checks li::before { content: "✓ "; color: #16A34A; font-weight: 700; }

/* Saved websites */
.gpp-saved-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); }
.gpp-saved { padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.gpp-saved p { margin: 0; }
.gpp-saved__head { display: flex; gap: 12px; align-items: center; }
.gpp-saved__thumb { width: 48px; height: 48px; border-radius: 10px; background: #E9EEF8; color: #1A4FD8; font-weight: 800; display: flex; align-items: center; justify-content: center; flex: none; }
.gpp-saved__price { font-size: 20px; }

/* Registration */
.gpp-segmented { border: 0; margin: 0; padding: 4px; display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: #EEF1F6; border-radius: 10px; }
.gpp-segmented label { position: relative; }
.gpp-segmented input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.gpp-segmented span { display: flex; align-items: center; justify-content: center; min-height: 42px; border-radius: 8px; font-weight: 600; color: #33405E; }
.gpp-segmented input:checked + span { background: var(--gpp-primary, #1F5EFF); color: #fff; }
.gpp-segmented input:focus-visible + span { box-shadow: 0 0 0 3px rgba(31, 94, 255, .35); }
.gpp-register:has(input[value="client"]:checked) .gpp-register__publisher { display: none; }
.gpp-strength { display: flex; gap: 4px; margin-top: 2px; }
.gpp-strength span { flex: 1; height: 4px; border-radius: 2px; background: #E3E8F2; }
.gpp-strength[data-score="1"] span:nth-child(-n+1) { background: #DC2626; }
.gpp-strength[data-score="2"] span:nth-child(-n+2) { background: #D97706; }
.gpp-strength[data-score="3"] span:nth-child(-n+3) { background: #16A34A; }
.gpp-strength[data-score="4"] span { background: #16A34A; }
.gpp-hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.gpp-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.gpp-btn--block + .gpp-btn--block { margin-top: 10px; }

/* Ownership verification + Google data panels */
.gpp-verify__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.gpp-verify__method { border: 1px solid var(--a-border); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.gpp-verify__title { margin: 0; font-size: 15px; font-weight: 700; }
.gpp-copy { display: flex; gap: 8px; align-items: stretch; flex-wrap: wrap; }
.gpp-copy .gpp-code { flex: 1 1 260px; margin: 0; min-width: 0; }
.gpp-verify__help summary { cursor: pointer; color: var(--a-primary, #2563EB); font-size: 14px; }
.gpp-verify__help ul { margin: 8px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.gpp-gdata { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }
.gpp-gdata__group { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.gpp-gdata__grid { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.gpp-gdata__grid div { background: #F7F9FC; border-radius: 10px; padding: 10px 12px; }
.gpp-gdata__grid dt { font-size: 12px; color: var(--a-muted); }
.gpp-gdata__grid dd { margin: 2px 0 0; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.gpp-source-note { margin-top: 14px; display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; border-radius: 10px; background: var(--a-primary-50); font-size: 14px; }
