/* Product Requests — Main Street Asian Market
   Matches site conventions: Montserrat, brand red #E8231A, no inline styles. */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;900&family=JetBrains+Mono:wght@500;700&display=swap');

:root {
    --brand-red: #E8231A;
    --ink: #000000;
    --ink-soft: #766F68;
    --cream: #FFFFFF;
    --light-grey: #F8F7F6;
    --card: #FFFFFF;
    --line: #E9E2D8;
    --green: #3CAB30;
    --amber: #C97A2B;
    --blue: #3B7DD8;
    --gray: #8A8A8A;
    --radius: 10px;
    --admin-topbar-height: 64px;
}

* { box-sizing: border-box; }

.pr-page {
    margin: 0;
    background: var(--cream);
    color: var(--ink);
    font-family: 'Montserrat', sans-serif;
    line-height: 1.5;
}

.pr-wrap {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    padding: 48px 20px 0;
}

@media screen and (max-width: 736px) {
	.pr-wrap {
		position: relative;
		margin: 0 auto;
		padding: 18px 0px 0px;
	}

	.pr-wrap-admin {
		padding-left: 20px;
		padding-right: 20px;
	}
}

.pr-header {
    text-align: center;
    margin-bottom: 40px;
}

.pr-header h1 {
    font-size: 2rem;
    font-weight: 900;
    text-transform: uppercase;
    margin: 0 0 8px;
    letter-spacing: 0.02em;
}

.pr-header p {
    color: var(--ink-soft);
    font-size: 1rem;
    max-width: 480px;
    margin: 0 auto;
}

/* ── Submission form ───────────────────────────────── */

.pr-form {
    background: var(--brand-red);
    border-radius: var(--radius);
    padding: 50px;
    margin-bottom: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}

.pr-form h2 {
    font-size: 1.3rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin: 0 0 16px;
    color: #fff;
}

.pr-field {
    margin-bottom: 32px;
}

.pr-field label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #fff;
}

.pr-page .pr-field input,
.pr-page .pr-field textarea {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: auto;
    line-height: normal;
    margin: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: 400;
    text-align: left;
    text-transform: none;
    letter-spacing: normal;
    white-space: normal;
    padding: 16px 18px;
    border: none !important;
    border-radius: 6px;
    background: #fff !important;
    color: var(--ink) !important;
    box-shadow: none !important;
}

.pr-field input:focus,
.pr-field textarea:focus {
    outline: 3px solid #000000;
    outline-offset: 0;
}

.pr-field textarea {
    min-height: 70px;
    resize: vertical;
}

.pr-page .pr-submit {
    display: inline-block;
    -webkit-appearance: none;
    appearance: none;
    background-color: transparent !important;
    outline: 2px solid #ffffff !important;
    box-shadow: none !important;
    color: #ffffff !important;
    font-family: 'Montserrat', sans-serif;
    font-weight: 900;
    font-size: 0.9rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    text-align: center;
    text-decoration: none;
    white-space: nowrap;
    border: none !important;
    border-radius: 12px;
    height: auto;
    line-height: normal;
    margin: 0;
    padding: 14px 28px;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

.pr-page .pr-submit:hover {
    outline: 2px solid #ffffff !important;
    transform: translateY(-0.25em);
    box-shadow: 4px 8px 0 0 #ffffff !important;
}

.pr-page .pr-submit:active {
    transform: translate(0.15em, 0.35em);
    box-shadow: 0 2px 0 0 #ffffff !important;
}

.pr-note {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 10px;
}

.pr-status-card {
    font-size: 0.95rem;
    font-weight: 600;
    padding: 24px;
    border-radius: var(--radius);
    margin-bottom: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    animation: prFadeInUp 0.35s ease both;
}

.pr-status-card-success {
    background: var(--green);
    color: #fff;
    overflow: hidden;
    animation: prFadeInUp 0.35s ease 0.5s both, prAutoFadeOut 1.2s ease 10.5s forwards;
}

.pr-status-card-error {
    background: var(--brand-red);
    color: #fff;
}

/* ── Request list ──────────────────────────────────── */

.pr-collapsible-section {
    margin-bottom: 32px;
}

.pr-list-heading {
    list-style: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--ink);
    margin-bottom: 24px;
}

.pr-list-heading::-webkit-details-marker {
    display: none;
}

.pr-list-heading::before {
    content: '▸';
    display: inline-block;
    font-size: 0.7em;
    transition: transform 0.2s ease;
}

.pr-collapsible-section[open] .pr-list-heading::before {
    transform: rotate(90deg);
}

.pr-search-wrap {
    position: relative;
    width: 50%;
    margin-bottom: 30px;
}

.pr-search-icon {
    position: absolute;
    left: 23px;
    top: 50%;
    transform: translateY(-50%);
    color: #DDDDDD;
    font-size: 1.1rem;
    pointer-events: none;
    transition: color 0.15s ease;
}

.pr-search-clear {
    position: absolute;
    right: 23px;
    top: 50%;
    transform: translateY(-50%);
    color: #DDDDDD;
    font-size: 1.1rem;
    cursor: pointer;
    transition: color 0.15s ease;
}

.pr-search-clear:hover {
    color: #000000;
}

.pr-page .pr-search-input {
    -webkit-appearance: none;
    appearance: none;
    display: block;
    width: 100%;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 28px 50px 28px 50px;
    margin-bottom: 0;
    border: 2px solid #DDDDDD !important;
    border-radius: 10px;
    background: #fff !important;
    color: var(--ink) !important;
    box-shadow: none !important;
    transition: border-color 0.15s ease;
}

.pr-page .pr-search-input::placeholder {
    color: #DDDDDD;
    font-weight: 400;
}

.pr-page .pr-search-input:focus {
    outline: none;
    border-color: #000000 !important;
}

.pr-page .pr-search-input:focus ~ .pr-search-icon {
    color: #000000;
}

.pr-page .pr-search-input:focus ~ .pr-search-clear {
    color: #000000;
}

.pr-page .pr-search-input:focus ~ .pr-search-clear:hover {
    color: #DDDDDD;
}

.pr-hidden {
    display: none !important;
}

.pr-empty {
    color: var(--ink-soft);
    font-size: 0.95rem;
    text-align: center;
    padding: 30px 0;
}

/* Signature element: shelf-tag card, notched like a price tag,
   with the vote count set like a shelf price in a mono face. */
@keyframes prFadeInUp {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes prAutoFadeOut {
    0% { opacity: 1; max-height: 100px; margin-bottom: 40px; padding-top: 24px; padding-bottom: 24px; }
    100% { opacity: 0; max-height: 0; margin-bottom: 0; padding-top: 0; padding-bottom: 0; }
}

@keyframes prHighlightPulse {
    0% { box-shadow: 0 0 0 3px rgba(232, 35, 26, 0.4), 0 1px 2px rgba(0, 0, 0, 0.09), 0 2px 8px rgba(0, 0, 0, 0.13); }
    100% { box-shadow: 0 1px 2px rgba(0, 0, 0, 0.09), 0 2px 8px rgba(0, 0, 0, 0.13); }
}

.pr-tag {
    position: relative;
    display: flex;
    align-items: stretch;
    background: var(--card);
    border-radius: var(--radius);
    margin-bottom: 28px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.09), 0 2px 8px rgba(0, 0, 0, 0.13);
    transition: box-shadow 0.15s ease, transform 0.15s ease;
    animation: prFadeInUp 0.4s ease both;
}

.pr-tag:nth-child(1) { animation-delay: 0.02s; }
.pr-tag:nth-child(2) { animation-delay: 0.06s; }
.pr-tag:nth-child(3) { animation-delay: 0.10s; }
.pr-tag:nth-child(4) { animation-delay: 0.14s; }
.pr-tag:nth-child(5) { animation-delay: 0.18s; }
.pr-tag:nth-child(6) { animation-delay: 0.22s; }
.pr-tag:nth-child(n+7) { animation-delay: 0.24s; }

.pr-tag-new {
    animation: prFadeInUp 0.4s ease both, prHighlightPulse 1.8s ease 0.4s;
}

.pr-tag:hover {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.11), 0 6px 16px rgba(0, 0, 0, 0.17);
    transform: translateY(-2px) scale(1.015);
}

.pr-vote {
    flex: 0 0 84px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    background: var(--light-grey);
    padding: 30px;
}

.pr-vote-count {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--brand-red);
}

.pr-page .pr-vote-btn {
    -webkit-appearance: none;
    appearance: none;
    display: inline-block;
    height: auto;
    line-height: normal;
    margin: 0;
    white-space: nowrap;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    text-align: center;
    text-decoration: none;
    letter-spacing: 0.03em;
    color: #000000 !important;
    background: #fff !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 20px;
    padding: 4px 10px;
    cursor: pointer;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.pr-page .pr-vote-btn:hover {
    background: var(--brand-red) !important;
    color: #fff !important;
}

.pr-page .pr-vote-btn[disabled] {
    color: var(--ink-soft) !important;
    border: none !important;
    background: #E4E2DF !important;
    cursor: default;
}

.pr-body {
    flex: 1;
    padding: 30px;
}

.pr-body-top {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.pr-name {
    font-weight: 600;
    font-size: 1rem;
}

.pr-date {
    font-size: 0.75rem;
    color: var(--ink-soft);
    white-space: nowrap;
}

.pr-user-note {
    font-size: 0.88rem;
    color: var(--ink-soft);
    margin-top: 4px;
}

.pr-status {
    display: inline-block;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 3px 8px;
    border-radius: 4px;
    margin-top: 10px;
}

.pr-status.pending { background: #F5E9E8; color: var(--brand-red); }
.pr-status.have_it { background: #E3F6E0; color: var(--green); }
.pr-status.looking { background: #E5EFFB; color: var(--blue); }
.pr-status.ordering { background: #FBEEDC; color: var(--amber); }
.pr-status.not_carrying { background: #EBEBEB; color: var(--gray); }

.pr-reply {
    margin-top: 10px;
    padding: 10px 12px;
    background: var(--light-grey);
    border-left: 3px solid var(--brand-red);
    border-radius: 0 6px 6px 0;
    font-size: 0.88rem;
}

.pr-reply strong {
    display: block;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--brand-red);
    margin-bottom: 3px;
}

/* ── Admin page ────────────────────────────────────── */

.pr-admin-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    height: var(--admin-topbar-height);
    background: #000000;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.pr-admin-topbar-inner {
    max-width: 760px;
    height: 100%;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.pr-wrap-admin {
    padding-top: 48px;
}

.pr-admin-nav {
    display: flex;
    gap: 8px;
}

.pr-admin-nav-link {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.7);
    background: rgba(255, 255, 255, 0.1);
    padding: 8px 16px;
    border-radius: 20px;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.pr-admin-nav-link:hover {
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
}

.pr-admin-nav-active {
    background: var(--brand-red);
    color: #fff;
}

.pr-admin-nav-active:hover {
    background: #c91d15;
    color: #fff;
}

.pr-header-admin-full {
    background: var(--brand-red);
    padding: calc(var(--admin-topbar-height) + 32px) 20px 40px;
    text-align: left;
}

.pr-header-admin-inner {
    max-width: 760px;
    margin: 0 auto;
    display: flex;
    align-items: flex-start;
    gap: 24px;
}

.pr-header-admin-icon {
    display: none;
    flex: 0 0 auto;
    width: auto;
    height: 57px;
    margin-top: 6px;
    fill: #ffffff;
}

@media (min-width: 640px) {
    .pr-header-admin-icon {
        display: block;
    }
}

.pr-header-admin-text h1 {
    font-size: 2rem;
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin: 0 0 8px;
    color: #ffffff;
}

.pr-header-admin-text p {
    margin: 0;
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
}

.pr-saved-note {
    color: var(--green);
    font-weight: 600;
    font-size: 0.9rem;
    margin: 0 0 16px;
}

.pr-admin-row {
    background: var(--card);
    border-radius: var(--radius);
    border-top: 4px solid #000000;
    padding: 16px;
    margin-bottom: 40px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.16), 0 10px 24px rgba(0, 0, 0, 0.22);
}

.pr-admin-collapsible {
    margin-bottom: 0;
}

.pr-admin-collapsible-divider {
    border: none;
    border-top: 1px solid var(--line);
    margin: 24px 0;
}

.pr-admin-collapsible summary {
    list-style: none;
    cursor: pointer;
}

.pr-admin-collapsible[open] summary {
    margin-bottom: 16px;
}

.pr-admin-collapsible summary::-webkit-details-marker {
    display: none;
}

.pr-admin-collapsible summary::before {
    content: '▸';
    display: inline-block;
    margin-right: 8px;
    font-size: 0.8em;
    transition: transform 0.2s ease;
}

.pr-admin-collapsible[open] summary::before {
    transform: rotate(90deg);
}

.pr-admin-collapsible:not([open]) summary {
    color: var(--ink-soft) !important;
    transition: color 0.15s ease;
}

.pr-admin-collapsible:not([open]) summary:hover {
    color: var(--ink) !important;
}

.pr-admin-collapsible[open] .pr-admin-list-heading-new {
    color: var(--brand-red);
}

.pr-admin-new-row {
    border: 2px dashed var(--brand-red);
    border-top: 8px solid var(--brand-red);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.14), 0 8px 18px rgba(0, 0, 0, 0.18);
    margin-bottom: 32px;
    margin-top: 12px;
}

.pr-admin-list-heading {
    font-size: 1.05rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--ink);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pr-admin-list-heading-muted {
    color: var(--ink-soft);
}

.pr-admin-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 24px;
    padding: 0 7px;
    border-radius: 20px;
    background: var(--brand-red);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
}

.pr-admin-list-heading-muted .pr-admin-count {
    background: var(--green);
}

.pr-admin-collapsible:not([open]) .pr-admin-count {
    background: var(--gray) !important;
}

.pr-admin-row-muted {
    background: var(--card);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.12), 0 8px 18px rgba(0, 0, 0, 0.16);
    border: 1px solid #E9E7E4;
    border-top: 4px solid #000000;
    margin-bottom: 40px;
    opacity: 0.85;
    transition: opacity 0.15s ease;
}

.pr-admin-row-muted:hover {
    opacity: 1;
}

.pr-admin-section-label {
    font-size: 0.7rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--brand-red);
    margin-bottom: 12px;
}

.pr-admin-section-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.pr-admin-view .pr-status {
    margin-top: 0;
}

.pr-admin-section-label-row .pr-admin-section-label {
    margin-bottom: 0;
}

.pr-admin-edit-toggle {
    background: none;
    border: none;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    text-decoration: underline;
    color: var(--ink-soft);
    cursor: pointer;
}

.pr-admin-edit-toggle:hover {
    color: var(--ink);
}

.pr-admin-view-name {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--ink);
    margin-bottom: 4px;
}

.pr-admin-view-meta {
    font-size: 0.85rem;
    color: var(--ink-soft);
}

.pr-admin-view-reply {
    margin-top: 8px;
}

.pr-admin-divider {
    border-top: 1px solid var(--line);
    margin: 14px 0;
}

.pr-admin-edit-form .pr-field {
    margin-bottom: 10px;
}

.pr-admin-edit-form .pr-field:last-child {
    margin-bottom: 0;
}

.pr-admin-edit-form .pr-field label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--ink-soft);
    margin-bottom: 5px;
}

.pr-field-product-name input {
    font-size: 1.1rem !important;
    font-weight: 700;
    padding: 10px 12px !important;
}

.pr-admin-new-row-spacer {
    height: 24px;
}

.pr-admin-meta-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 10px;
}

.pr-admin-row .pr-admin-edit-form input[type="text"],
.pr-admin-row .pr-admin-edit-form input[type="number"],
.pr-admin-row .pr-admin-edit-form input[type="datetime-local"],
.pr-admin-row .pr-admin-edit-form select,
.pr-admin-row .pr-admin-edit-form textarea {
    width: 100%;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    padding: 8px 10px;
    border: 1px solid #D8D6D3 !important;
    border-radius: 6px;
    background: var(--light-grey) !important;
    color: var(--ink) !important;
}

.pr-admin-edit-form textarea {
    min-height: 44px;
    resize: vertical;
}

.pr-admin-edit-form textarea[name="admin_reply"],
.pr-admin-edit-form textarea[name="new_admin_reply"] {
    min-height: 110px;
}

.pr-admin-row .pr-admin-edit-form input:focus,
.pr-admin-row .pr-admin-edit-form select:focus,
.pr-admin-row .pr-admin-edit-form textarea:focus {
    outline: 2px solid var(--brand-red);
    outline-offset: 0;
    border-color: var(--brand-red) !important;
}

.pr-admin-save {
    display: inline-block;
    margin-top: 12px;
    background: var(--brand-red);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 11px 26px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.pr-admin-save:hover {
    background: #c91d15;
}

.pr-admin-delete-form {
    margin-top: 10px;
}

.pr-admin-delete {
    background: none;
    border: none;
    padding: 0;
    color: var(--ink-soft);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
}

.pr-admin-delete:hover {
    color: var(--brand-red);
}

.pr-login {
    max-width: 340px;
    margin: 80px auto;
    background: var(--card);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06), 0 2px 8px rgba(0, 0, 0, 0.10);
}

.pr-login .pr-field label {
    color: var(--ink);
}

.pr-login .pr-field input {
    border: 1px solid var(--line) !important;
}

.pr-login .pr-submit {
    background-color: var(--brand-red) !important;
    outline: none !important;
    box-shadow: none !important;
    color: #ffffff !important;
    width: 100%;
}

.pr-login .pr-submit:hover {
    background-color: #c91d15 !important;
    transform: none;
    box-shadow: none !important;
}

.pr-login .pr-submit:active {
    background-color: #a8160f !important;
    transform: none;
    box-shadow: none !important;
}

.pr-login h1 {
    font-size: 1.2rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin: 0 0 16px;
}

.pr-error {
    color: var(--brand-red);
    font-size: 0.85rem;
    margin-bottom: 10px;
}

.pr-logout {
    font-size: 0.82rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.15s ease;
}

.pr-logout:hover {
    color: #ffffff;
    text-decoration: underline;
}

input.pr-field-narrow {
    width: 60%;
}


@media (max-width: 480px) {
	
    .pr-tag { flex-direction: column; }
    .pr-vote { flex-direction: row; gap: 14px; }
    input.pr-field-narrow { width: 100%; }
    .pr-form { padding: 30px; }
    .pr-search-wrap { width: 100%; }
    .pr-header-admin-inner { gap: 14px; }
	
}
