/* Buyer & renter requests: the full list (requests.php) and a request's own
   page (request.php). The same look as the homepage's Latest Requests board
   (index.php keeps its own inline copy): navy cards, a coloured kind badge,
   gold actions. Cards grow with their text and stack on a phone, with the
   action under the content. */

.hbrq {
    --rq-panel: linear-gradient(160deg, rgba(20, 38, 66, 0.96), rgba(11, 23, 42, 0.98));
    --rq-line: rgba(140, 186, 248, 0.26);
    --rq-text: #eaf1fb;
    --rq-soft: #b8c7da;
    --rq-dim: #8ea3bd;
    --rq-gold: #f3c34f;
    --rq-gold-tint: rgba(243, 195, 79, 0.08);
    --rq-gold-ring: rgba(243, 195, 79, 0.55);
    --rq-gold-btn: linear-gradient(135deg, #ffe08a, #f0bb43);
    --rq-ink: #1b1400;
    max-width: 1080px;
    margin: 0 auto;
    padding: 34px 16px 64px;
    color: var(--rq-text);
    font-family: 'Outfit', 'Lexend', system-ui, sans-serif;
}

.hbrq * { box-sizing: border-box; }

.hbrq-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 20px; margin: 0 0 18px; }
.hbrq-title { margin: 0; font-size: clamp(26px, 3vw, 34px); font-weight: 700; line-height: 1.1; color: #fff; }
.hbrq-sub { margin: 6px 0 0; color: var(--rq-soft); font-size: 16px; }
.hbrq-newest { margin: 2px 0 0; color: var(--rq-dim); font-size: 14px; }

.hbrq-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.hbrq-card {
    display: flex; flex-direction: column; gap: 10px; min-width: 0;
    padding: 16px 18px; border: 1px solid var(--rq-line); border-radius: 14px;
    background: var(--rq-panel); box-shadow: 0 10px 26px rgba(0, 0, 0, 0.24);
}
.hbrq-cardhead { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; min-width: 0; }
.hbrq-tag {
    padding: 4px 14px; border-radius: 999px; background: var(--tag, #f58a84); color: var(--tag-ink, #2a0909);
    font-size: 13.5px; font-weight: 700; letter-spacing: 0.04em; line-height: 1.35; text-transform: uppercase; white-space: nowrap;
}
.hbrq-sample {
    padding: 3px 11px; border: 1px solid rgba(196, 181, 253, 0.55); border-radius: 999px;
    background: rgba(196, 181, 253, 0.12); color: #d9cffd; font-size: 12.5px; font-weight: 700; letter-spacing: 0.03em; line-height: 1.35; white-space: nowrap;
}
.hbrq-place { display: inline-flex; align-items: center; gap: 6px; min-width: 0; color: var(--rq-soft); font-size: 15px; }
.hbrq-place svg { flex: 0 0 auto; color: #9fb3cc; }
.hbrq-date { color: var(--rq-dim); }
.hbrq-place .hbrq-date::before { content: "\00b7"; margin: 0 7px 0 1px; }
.hbrq-say {
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
    margin: 0; color: var(--rq-text); font-size: 17px; line-height: 1.45; overflow-wrap: anywhere;
}
.hbrq-meta { margin: 0; color: var(--rq-dim); font-size: 14.5px; line-height: 1.45; }
.hbrq-cta, .hbrq-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; align-self: flex-end;
    min-height: 44px; padding: 0 18px 0 22px; border: 1px solid var(--rq-gold-ring); border-radius: 999px;
    background: var(--rq-gold-tint); color: var(--rq-gold) !important; font-size: 16px; font-weight: 700;
    text-decoration: none !important; white-space: nowrap; cursor: pointer;
    transition: background .2s ease, color .2s ease, transform .2s ease;
}
.hbrq-cta:hover, .hbrq-btn:hover { background: var(--rq-gold-btn); color: var(--rq-ink) !important; transform: translateY(-1px); }
.hbrq-btn.is-solid { background: var(--rq-gold-btn); color: var(--rq-ink) !important; border-color: transparent; }
.hbrq-btn[disabled] { opacity: .55; cursor: default; transform: none; }

.hbrq-more { display: block; margin: 20px auto 0; min-height: 46px; padding: 0 30px; border: 1px solid rgba(243, 195, 79, .6); border-radius: 999px; background: rgba(243, 195, 79, .06); color: var(--rq-gold); font-size: 16px; font-weight: 700; cursor: pointer; }
.hbrq-more[hidden] { display: none; }
.hbrq-empty { padding: 26px 20px; border: 1px dashed var(--rq-line); border-radius: 14px; color: var(--rq-soft); text-align: center; }
.hbrq-samples { margin-top: 38px; padding-top: 10px; border-top: 1px dashed var(--rq-line); }

/* ── a request's own page ───────────────────────────────────────────── */
.hbrq-detail { max-width: 820px; }
.hbrq-panel { padding: 22px 22px 24px; border: 1px solid var(--rq-line); border-radius: 16px; background: var(--rq-panel); box-shadow: 0 14px 34px rgba(0, 0, 0, .3); }
.hbrq-h1 { margin: 14px 0 6px; font-size: clamp(22px, 2.6vw, 28px); font-weight: 700; line-height: 1.2; color: #fff; }
.hbrq-note {
    margin: 14px 0 0; padding: 12px 14px; border-left: 3px solid #c4b5fd; border-radius: 8px;
    background: rgba(196, 181, 253, .10); color: #e6defe; font-size: 15px; line-height: 1.5;
}
.hbrq-desc { margin: 18px 0 0; color: var(--rq-text); font-size: 17.5px; line-height: 1.6; white-space: pre-line; overflow-wrap: anywhere; }
.hbrq-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin: 20px 0 0; padding: 0; }
.hbrq-facts div { padding: 10px 12px; border: 1px solid var(--rq-line); border-radius: 10px; background: rgba(255, 255, 255, .03); }
.hbrq-facts dt { color: var(--rq-dim); font-size: 12.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.hbrq-facts dd { margin: 3px 0 0; color: var(--rq-text); font-size: 15.5px; }
.hbrq-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 22px; }
.hbrq-actions .hbrq-btn { align-self: auto; }
.hbrq-help { margin: 8px 0 0; color: var(--rq-dim); font-size: 14px; }
.hbrq-links { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 18px 0 0; font-size: 15px; }
.hbrq-links a { color: var(--rq-gold) !important; }

/* the inquiry form and conversation */
.hbrq-form { display: grid; gap: 12px; margin-top: 18px; }
.hbrq-form[hidden] { display: none; }
.hbrq-form label { display: grid; gap: 6px; color: var(--rq-soft); font-size: 14.5px; font-weight: 600; }
.hbrq-form input, .hbrq-form textarea {
    width: 100%; padding: 11px 13px; border: 1px solid var(--rq-line); border-radius: 10px;
    background: rgba(5, 14, 28, .75); color: var(--rq-text); font: inherit; font-size: 16px; font-weight: 400;
}
.hbrq-form textarea { min-height: 120px; resize: vertical; }
.hbrq-form .is-bad { border-color: #f87171; }
.hbrq-msg { min-height: 1.2em; margin: 0; font-size: 14.5px; color: #fca5a5; }
.hbrq-msg.is-ok { color: #86efac; }
.hbrq-thread { display: grid; gap: 10px; margin-top: 16px; }
.hbrq-bubble { max-width: 92%; padding: 11px 14px; border-radius: 12px; font-size: 15.5px; line-height: 1.5; white-space: pre-line; overflow-wrap: anywhere; }
.hbrq-bubble small { display: block; margin-bottom: 4px; color: var(--rq-dim); font-size: 12.5px; font-weight: 700; letter-spacing: .03em; }
.hbrq-bubble.is-visitor { justify-self: end; background: rgba(140, 186, 248, .14); border: 1px solid rgba(140, 186, 248, .3); }
.hbrq-bubble.is-team { justify-self: start; background: rgba(243, 195, 79, .08); border: 1px solid rgba(243, 195, 79, .35); }
.hbrq-status { display: inline-block; margin-left: 8px; padding: 2px 9px; border-radius: 999px; background: rgba(255, 255, 255, .08); color: var(--rq-soft); font-size: 12.5px; font-weight: 700; }

@media (max-width: 720px) {
    .hbrq-grid { grid-template-columns: 1fr; }
    .hbrq-cta { align-self: stretch; }
    .hbrq-panel { padding: 18px 16px 20px; }
    .hbrq-actions .hbrq-btn { width: 100%; }
}
