.stanloop-marketplace-studio,
.stanloop-marketplace-public,
.stanloop-marketplace-advertiser-applications,
.stanloop-marketplace-enquiry-preview {
    --sl-market-green: #3cae22;
    --sl-market-green-dark: #267817;
    --sl-market-orange: #ff7317;
    --sl-market-ink: #111827;
    --sl-market-muted: #667085;
    --sl-market-line: #dce8d6;
    --sl-market-soft: #f5faef;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--sl-market-ink);
}

.stanloop-marketplace-studio {
    margin: 28px 0;
    padding: 28px;
    border: 1px solid var(--sl-market-line);
    border-radius: 26px;
    background: linear-gradient(145deg, rgba(244, 251, 237, .96), rgba(255, 248, 238, .96));
    box-shadow: 0 18px 45px rgba(29, 65, 20, .08);
}

.stanloop-marketplace-heading,
.stanloop-marketplace-section-head {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    justify-content: space-between;
}

.stanloop-marketplace-heading > div:first-child,
.stanloop-marketplace-section-head > div:first-child {
    flex: 1 1 auto;
}

.stanloop-marketplace-heading span,
.stanloop-marketplace-section-head > div > span,
.stanloop-marketplace-application-card header > div:nth-child(2) > span {
    color: var(--sl-market-green-dark);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.stanloop-marketplace-heading h2,
.stanloop-marketplace-section-head h2,
.stanloop-marketplace-section-head h3 {
    margin: 4px 0 6px;
    color: var(--sl-market-ink);
    font-weight: 900;
    line-height: 1.08;
}

.stanloop-marketplace-heading h2 { font-size: clamp(26px, 3vw, 38px); }
.stanloop-marketplace-section-head h2,
.stanloop-marketplace-section-head h3 { font-size: 26px; }

.stanloop-marketplace-heading p,
.stanloop-marketplace-section-head p {
    margin: 0;
    color: var(--sl-market-muted);
    line-height: 1.6;
}

.stanloop-marketplace-stat {
    flex: 0 0 auto;
    min-width: 94px;
    padding: 12px 14px;
    border: 1px solid var(--sl-market-line);
    border-radius: 16px;
    background: #fff;
    text-align: center;
}

.stanloop-marketplace-stat strong {
    display: block;
    color: var(--sl-market-green-dark);
    font-size: 24px;
    line-height: 1;
}

.stanloop-marketplace-stat span {
    color: var(--sl-market-muted);
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.stanloop-marketplace-notice {
    margin: 20px 0;
    padding: 14px 16px;
    border-radius: 14px;
    font-weight: 800;
}

.stanloop-marketplace-notice.is-success {
    border: 1px solid #9fd88c;
    background: #e9f9e4;
    color: #205f16;
}

.stanloop-marketplace-notice.is-error {
    border: 1px solid #f2b6a8;
    background: #fff0ec;
    color: #a33722;
}

.stanloop-marketplace-create {
    margin-top: 24px;
    border: 1px solid var(--sl-market-line);
    border-radius: 20px;
    background: rgba(255,255,255,.9);
    overflow: hidden;
}

.stanloop-marketplace-create > summary {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 2px 12px;
    align-items: center;
    padding: 18px 20px;
    cursor: pointer;
    list-style: none;
}

.stanloop-marketplace-create > summary::-webkit-details-marker,
.stanloop-marketplace-apply > summary::-webkit-details-marker,
.stanloop-marketplace-admin-actions details > summary::-webkit-details-marker {
    display: none;
}

.stanloop-marketplace-create > summary > span {
    grid-row: 1 / span 2;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 13px;
    background: #eaf8e4;
    color: var(--sl-market-green-dark);
    font-size: 22px;
}

.stanloop-marketplace-create > summary strong { font-size: 17px; }
.stanloop-marketplace-create > summary small { color: var(--sl-market-muted); }

.stanloop-marketplace-opportunity-form {
    padding: 22px;
    border-top: 1px solid var(--sl-market-line);
    background: #fff;
}

.stanloop-marketplace-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.stanloop-marketplace-form-grid > label,
.stanloop-marketplace-platforms {
    display: grid;
    gap: 7px;
    margin: 0;
}

.stanloop-marketplace-form-grid .is-wide { grid-column: 1 / -1; }

.stanloop-marketplace-form-grid label > span,
.stanloop-marketplace-platforms legend,
.stanloop-marketplace-status-form label > span {
    color: #263238;
    font-size: 13px;
    font-weight: 800;
}

.stanloop-marketplace-form-grid input,
.stanloop-marketplace-form-grid textarea,
.stanloop-marketplace-form-grid select,
.stanloop-marketplace-status-form select {
    width: 100%;
    min-height: 46px;
    padding: 11px 13px;
    border: 1px solid #cfe0c8;
    border-radius: 12px;
    background: #fff;
    color: var(--sl-market-ink);
    font: inherit;
}

.stanloop-marketplace-form-grid textarea { min-height: 100px; resize: vertical; }

.stanloop-marketplace-form-grid input:focus,
.stanloop-marketplace-form-grid textarea:focus,
.stanloop-marketplace-form-grid select:focus,
.stanloop-marketplace-status-form select:focus {
    outline: 3px solid rgba(60,174,34,.16);
    border-color: var(--sl-market-green);
}

.stanloop-marketplace-platforms {
    padding: 14px;
    border: 1px solid #dce8d6;
    border-radius: 14px;
}

.stanloop-marketplace-platforms legend { padding: 0 6px; }

.stanloop-marketplace-platforms label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 4px 12px 4px 0;
    font-size: 13px;
}

.stanloop-marketplace-platforms input { width: 16px; min-height: 16px; }

.stanloop-marketplace-primary,
.stanloop-marketplace-status-form button,
.stanloop-marketplace-admin-actions button,
.stanloop-marketplace-admin-actions summary,
.stanloop-marketplace-apply > summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 10px 16px;
    border: 0;
    border-radius: 12px;
    background: var(--sl-market-green);
    color: #fff;
    font: inherit;
    font-weight: 850;
    text-decoration: none;
    cursor: pointer;
}

.stanloop-marketplace-currency-warning {
    margin: 0;
    padding: 11px 13px;
    border: 1px solid #f1d39a;
    border-radius: 12px;
    background: #fff8e6;
    color: #8a5a00;
    font-size: 12px;
    font-weight: 750;
    line-height: 1.5;
}

.stanloop-marketplace-form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-top: 18px;
}

.stanloop-marketplace-form-actions .stanloop-marketplace-primary {
    flex: 0 0 auto;
    align-self: flex-start;
    width: auto !important;
    height: auto !important;
    min-height: 42px !important;
    margin: 0;
}


.stanloop-marketplace-section-head {
    margin-top: 32px;
    padding-top: 26px;
    border-top: 1px solid rgba(74,120,55,.16);
}

.stanloop-marketplace-opportunity-admin-list,
.stanloop-marketplace-inbox,
.stanloop-marketplace-advertiser-list {
    display: grid;
    gap: 16px;
    margin-top: 16px;
}

.stanloop-marketplace-admin-card,
.stanloop-marketplace-application-card,
.stanloop-marketplace-advertiser-list article {
    border: 1px solid var(--sl-market-line);
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(31,71,22,.05);
}

.stanloop-marketplace-admin-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    padding: 20px;
}

.stanloop-marketplace-admin-card h4,
.stanloop-marketplace-application-card h4,
.stanloop-marketplace-advertiser-list h3,
.stanloop-marketplace-public-card h3 {
    margin: 8px 0 8px;
    color: var(--sl-market-ink);
    font-weight: 900;
}

.stanloop-marketplace-admin-card p { margin: 0; color: var(--sl-market-muted); line-height: 1.55; }

.stanloop-marketplace-meta,
.stanloop-marketplace-tags,
.stanloop-marketplace-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.stanloop-marketplace-meta span,
.stanloop-marketplace-tags span {
    padding: 7px 10px;
    border: 1px solid #d7e8d0;
    border-radius: 999px;
    background: #f5faef;
    color: #315f27;
    font-size: 12px;
    font-weight: 800;
}

.stanloop-marketplace-admin-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-end;
}

.stanloop-marketplace-admin-actions > form { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.stanloop-marketplace-admin-actions button,
.stanloop-marketplace-admin-actions summary { min-height: 36px; padding: 8px 12px; font-size: 12px; }
.stanloop-marketplace-admin-actions button.is-danger { background: #fff0ed; color: #b23b24; border: 1px solid #f0beb3; }

.stanloop-marketplace-inline-editor {
    position: relative;
    z-index: 2;
    width: min(760px, calc(100vw - 80px));
    margin-top: 10px;
    border: 1px solid var(--sl-market-line);
    border-radius: 16px;
    box-shadow: 0 18px 45px rgba(14,40,8,.14);
    overflow: hidden;
}

.stanloop-marketplace-inline-editor .stanloop-marketplace-opportunity-form {
    display: block;
    border-top: 0;
}


.stanloop-marketplace-status {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 6px 9px;
    border-radius: 999px;
    background: #edf7e8;
    color: #2b751e;
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.stanloop-marketplace-status.is-paused,
.stanloop-marketplace-status.is-reviewing { background: #fff2dc; color: #9a5a00; }
.stanloop-marketplace-status.is-closed,
.stanloop-marketplace-status.is-declined { background: #f1f3f5; color: #59636e; }
.stanloop-marketplace-status.is-shortlisted { background: #fff4d1; color: #8a5a00; }
.stanloop-marketplace-status.is-accepted { background: #e1f7dd; color: #1e6c17; }
.stanloop-marketplace-status.is-received { background: #e8f1ff; color: #245b9f; }

.stanloop-marketplace-application-card { padding: 20px; }

.stanloop-marketplace-application-card > header {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
}

.stanloop-marketplace-brand-mark {
    display: grid;
    place-items: center;
    width: 50px;
    height: 50px;
    border: 1px solid var(--sl-market-line);
    border-radius: 14px;
    background: var(--sl-market-soft);
    overflow: hidden;
    color: var(--sl-market-orange);
}

.stanloop-marketplace-brand-mark img { width: 100%; height: 100%; object-fit: cover; }
.stanloop-marketplace-application-card header h4 { margin: 2px 0; font-size: 20px; }
.stanloop-marketplace-application-card header small { color: var(--sl-market-muted); }

.stanloop-marketplace-application-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 12px;
    margin-top: 18px;
}

.stanloop-marketplace-application-grid > div,
.stanloop-marketplace-message {
    padding: 14px;
    border: 1px solid #e3eadf;
    border-radius: 13px;
    background: #fbfdf9;
}

.stanloop-marketplace-application-grid span,
.stanloop-marketplace-message span {
    color: var(--sl-market-green-dark);
    font-size: 11px;
    font-weight: 900;
    text-transform: uppercase;
}

.stanloop-marketplace-application-grid p,
.stanloop-marketplace-message p { margin: 6px 0 0; color: #3f4a55; line-height: 1.5; }
.stanloop-marketplace-message { margin-top: 12px; }

.stanloop-marketplace-links a {
    color: var(--sl-market-green-dark);
    font-size: 13px;
    font-weight: 800;
}

.stanloop-marketplace-status-form {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e4ebdf;
}

.stanloop-marketplace-status-form label { display: grid; gap: 6px; min-width: 190px; }
.stanloop-marketplace-status-form button { background: var(--sl-market-orange); }

.stanloop-marketplace-empty {
    padding: 24px;
    border: 1px dashed #bfd4b5;
    border-radius: 18px;
    background: rgba(255,255,255,.72);
    text-align: center;
}

.stanloop-marketplace-empty strong { display: block; font-size: 18px; }
.stanloop-marketplace-empty p { margin: 6px auto 14px; max-width: 680px; color: var(--sl-market-muted); }

.stanloop-marketplace-public {
    margin: 30px 0;
    padding: 28px;
    border: 1px solid #dfead9;
    border-radius: 24px;
    background: linear-gradient(150deg, #f6fbed, #fff8ef);
}

.stanloop-marketplace-public-grid { display: grid; gap: 18px; margin-top: 20px; }

.stanloop-marketplace-public-card {
    padding: 22px;
    border: 1px solid #dbe8d5;
    border-radius: 19px;
    background: #fff;
}

.stanloop-marketplace-public-card header > div { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.stanloop-marketplace-type { color: var(--sl-market-orange); font-size: 12px; font-weight: 900; text-transform: uppercase; }
.stanloop-marketplace-public-card h3 { font-size: 24px; }
.stanloop-marketplace-public-card header p { color: #4b5563; line-height: 1.6; }

.stanloop-marketplace-public-card dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 10px;
    margin: 18px 0 0;
}

.stanloop-marketplace-public-card dl > div {
    padding: 12px;
    border: 1px solid #e1eadc;
    border-radius: 12px;
    background: #fbfdf9;
}

.stanloop-marketplace-public-card dt { color: var(--sl-market-muted); font-size: 11px; font-weight: 850; text-transform: uppercase; }
.stanloop-marketplace-public-card dd { margin: 4px 0 0; color: var(--sl-market-ink); font-weight: 800; }

.stanloop-marketplace-deliverables { margin-top: 16px; padding: 14px; border-left: 4px solid var(--sl-market-green); background: #f5faef; border-radius: 0 12px 12px 0; }
.stanloop-marketplace-deliverables p { margin: 6px 0 0; color: #4b5563; line-height: 1.55; }

.stanloop-marketplace-apply { margin-top: 18px; }
.stanloop-marketplace-apply > summary { background: var(--sl-market-orange); }
.stanloop-marketplace-apply[open] > summary { margin-bottom: 14px; }
.stanloop-marketplace-apply .stanloop-wwm-enquiry { margin: 0; box-shadow: none; }

.stanloop-marketplace-applied,
.stanloop-marketplace-owner-preview {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
    padding: 14px;
    border-radius: 13px;
    background: #edf8e8;
    color: #2a6f20;
}

.stanloop-marketplace-applied small { margin-left: auto; color: var(--sl-market-muted); }
.stanloop-marketplace-owner-preview { background: #fff4e8; color: #92521b; }


.stanloop-marketplace-enquiry-preview {
    margin: 26px 0;
    padding: 28px;
    border: 1px solid #f0d8ba;
    border-radius: 22px;
    background: linear-gradient(145deg, #fffaf2, #f5faef);
    box-shadow: 0 16px 38px rgba(58, 79, 45, .07);
}

.stanloop-marketplace-enquiry-preview > span {
    color: var(--sl-market-orange);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.stanloop-marketplace-enquiry-preview h2 {
    margin: 7px 0 10px;
    color: var(--sl-market-ink);
    font-size: clamp(25px, 3vw, 36px);
    font-weight: 900;
    line-height: 1.08;
}

.stanloop-marketplace-enquiry-preview p {
    max-width: 760px;
    margin: 0;
    color: var(--sl-market-muted);
    font-size: 16px;
    line-height: 1.65;
}

.stanloop-marketplace-enquiry-preview > div {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 18px;
    padding: 13px 15px;
    border: 1px solid #cfe4c7;
    border-radius: 13px;
    background: #fff;
    color: var(--sl-market-green-dark);
}

.stanloop-marketplace-enquiry-preview > div b {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #e9f8e3;
}

.stanloop-marketplace-profile-note {
    margin: 14px 0 0;
    color: var(--sl-market-muted);
    font-size: 13px;
}
.stanloop-marketplace-profile-note a { color: var(--sl-market-green-dark); font-weight: 800; }

.stanloop-marketplace-advertiser-applications {
    margin-top: 28px;
    padding: 26px;
    border: 1px solid var(--sl-market-line);
    border-radius: 24px;
    background: #fff;
}

.stanloop-marketplace-advertiser-applications .stanloop-marketplace-section-head { margin: 0; padding: 0; border: 0; }
.stanloop-marketplace-advertiser-list { grid-template-columns: repeat(2, minmax(0,1fr)); }
.stanloop-marketplace-advertiser-list article { position: relative; padding: 18px; }
.stanloop-marketplace-advertiser-list article > .stanloop-marketplace-status { position: absolute; top: 16px; right: 16px; }
.stanloop-marketplace-advertiser-list article > div:first-child { padding-right: 110px; }
.stanloop-marketplace-advertiser-list h3 { font-size: 18px; }
.stanloop-marketplace-advertiser-list p { color: var(--sl-market-muted); line-height: 1.5; }

.stanloop-notice--warning { border-color: #f2d39b; background: #fff8e5; color: #8a5a00; }
.stanloop-notice--error { border-color: #efb5aa; background: #fff0ed; color: #a83e29; }

@media (max-width: 900px) {
    .stanloop-marketplace-heading,
    .stanloop-marketplace-section-head { flex-wrap: wrap; }
    .stanloop-marketplace-admin-card { grid-template-columns: 1fr; }
    .stanloop-marketplace-admin-actions { align-items: stretch; }
    .stanloop-marketplace-admin-actions > form { justify-content: flex-start; }
    .stanloop-marketplace-inline-editor { width: 100%; }
    .stanloop-marketplace-advertiser-list { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
    .stanloop-marketplace-studio,
    .stanloop-marketplace-public,
    .stanloop-marketplace-advertiser-applications,
    .stanloop-marketplace-enquiry-preview { padding: 18px; border-radius: 18px; }
    .stanloop-marketplace-form-grid,
    .stanloop-marketplace-application-grid,
    .stanloop-marketplace-public-card dl { grid-template-columns: 1fr; }
    .stanloop-marketplace-form-grid .is-wide { grid-column: auto; }
    .stanloop-marketplace-application-card > header { grid-template-columns: 46px minmax(0,1fr); }
    .stanloop-marketplace-application-card > header > .stanloop-marketplace-status { grid-column: 1 / -1; }
    .stanloop-marketplace-status-form { align-items: stretch; flex-direction: column; }
    .stanloop-marketplace-status-form label { min-width: 0; }
    .stanloop-marketplace-advertiser-list article > .stanloop-marketplace-status { position: static; margin-bottom: 8px; }
    .stanloop-marketplace-advertiser-list article > div:first-child { padding-right: 0; }
    .stanloop-marketplace-applied small { width: 100%; margin-left: 0; }
}
