/* solicitacoes.css — Página de solicitações
   Design: cards premium estilo GetNinjas/Workana, mobile-first, flat */

.requests-page {
    width: min(1000px, calc(100% - 48px));
    margin: 28px auto 0;
    min-height: calc(100vh - 180px);
}

.requests-page__header {
    margin-bottom: 28px;
}

.requests-page__header h1 {
    font-family: 'Sora', 'Manrope', sans-serif;
    font-size: 1.4rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.02em;
}

.requests-page__subtitle {
    margin-top: 4px;
    font-size: 0.88rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Toolbar */
.requests-page__toolbar {
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.search-field {
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.025);
    height: 46px;
    display: grid;
    grid-template-columns: 38px 1fr;
    align-items: center;
    padding: 0 16px;
    transition: border-color 0.2s, background 0.2s;
}

.search-field:focus-within {
    border-color: rgba(212, 175, 55, 0.35);
    background: rgba(255, 255, 255, 0.04);
}

.search-field .material-symbols-rounded {
    font-size: 1.15rem;
    color: var(--text-muted);
    justify-self: center;
}

.search-field input {
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
    font-size: 0.9rem;
    font-family: 'Manrope', 'Segoe UI', sans-serif;
}

.search-field input::placeholder {
    color: var(--text-muted);
}

.inbox-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pill {
    height: 34px;
    padding: 0 16px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.07);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Manrope', 'Segoe UI', sans-serif;
    transition: all 0.2s ease;
}

.pill:hover {
    border-color: rgba(255, 255, 255, 0.16);
    color: #fff;
}

.pill--active {
    background: rgba(212, 175, 55, 0.12);
    border-color: rgba(212, 175, 55, 0.35);
    color: var(--gold);
}

/* Lista de Cards */
.requests-list {
    display: grid;
    gap: 12px;
    grid-template-columns: 1fr;
}

@media (min-width: 700px) {
    .requests-list {
        grid-template-columns: 1fr 1fr;
    }
}

/* Card de Solicitação — Solid dark, matching chat style */
.request-card {
    display: grid;
    grid-template-columns: 52px 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 18px 22px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    background: #0f071a;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.request-card:hover {
    border-color: rgba(212, 175, 55, 0.2);
    background: #130a1e;
}

.request-card__avatar {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.18), rgba(212, 175, 55, 0.08));
    color: var(--gold);
    font-weight: 800;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 1px solid rgba(212, 175, 55, 0.15);
}

.request-card__info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.request-card__service {
    font-size: 0.92rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.01em;
    white-space: normal;
    overflow: visible;
    line-height: 1.3;
}

.request-card__name {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.request-card__meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 2px;
}

.request-card__price {
    font-size: 0.82rem;
    font-weight: 800;
    color: var(--gold);
}

.request-card__time {
    font-size: 0.73rem;
    color: var(--text-muted);
    font-weight: 500;
}

/* Status Pills */
.status-pill {
    display: inline-flex;
    align-items: center;
    height: 24px;
    padding: 0 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    background: rgba(212, 175, 55, 0.1);
    color: var(--gold);
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.status-pill--negociacao {
    background: rgba(106, 0, 255, 0.12);
    border-color: rgba(106, 0, 255, 0.25);
    color: #b380ff;
}

.status-pill--finalizado {
    background: rgba(52, 211, 153, 0.1);
    border-color: rgba(52, 211, 153, 0.25);
    color: #34d399;
}

.status-pill--cancelado {
    background: rgba(156, 163, 175, 0.1);
    border-color: rgba(156, 163, 175, 0.2);
    color: #9ca3af;
}

/* Actions no card */
.request-card__actions {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

.request-card__chat-btn {
    height: 40px;
    padding: 0 22px;
    border-radius: 12px;
    background: var(--gold);
    color: #140d05;
    border: none;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-family: 'Manrope', 'Segoe UI', sans-serif;
    transition: all 0.2s ease;
    white-space: nowrap;
    text-decoration: none;
    letter-spacing: -0.01em;
}

.request-card__chat-btn:hover {
    background: var(--gold-strong);
}

.request-card__chat-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.request-card__chat-btn .material-symbols-rounded {
    font-size: 1.05rem;
    line-height: 1;
}

/* Estado vazio */
.requests-empty {
    text-align: center;
    padding: 72px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.requests-empty__icon {
    width: 80px;
    height: 80px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 4px;
}

.requests-empty__icon .material-symbols-rounded {
    font-size: 2.2rem;
    color: var(--text-muted);
}

.requests-empty h2 {
    font-family: 'Sora', 'Manrope', sans-serif;
    font-size: 1.15rem;
    color: #fff;
    font-weight: 700;
}

.requests-empty p {
    font-size: 0.88rem;
    color: var(--text-muted);
    max-width: 420px;
    line-height: 1.65;
}

.requests-empty__actions {
    display: flex;
    gap: 12px;
    margin-top: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.requests-empty__actions .btn {
    height: 44px;
    padding: 0 20px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.requests-empty__actions .btn--primary {
    background: var(--gold);
    color: #140d05;
}

.requests-empty__actions .btn--outline {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #fff;
}

/* Toast */
.toast {
    position: fixed;
    right: 20px;
    bottom: 80px;
    background: rgba(22, 13, 36, 0.98);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 12px;
    color: #fff;
    padding: 14px 24px;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    z-index: 200;
    backdrop-filter: blur(12px);
    max-width: 360px;
}

/* Descrição truncada + expand */
.request-card__desc {
    font-size: 0.76rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin-top: 4px;
}
.request-card__expand {
    display: inline;
    background: none;
    border: none;
    color: var(--gold);
    font-weight: 700;
    font-size: 0.74rem;
    cursor: pointer;
    padding: 0;
    font-family: 'Manrope', 'Segoe UI', sans-serif;
}
.request-card__expand:hover { text-decoration: underline; }

/* Modal de detalhes */
.request-detail-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(4px);
}
.request-detail-modal {
    background: #1a0f2e;
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    animation: modalFadeIn 0.2s ease;
}
@keyframes modalFadeIn { from { opacity: 0; transform: scale(0.95); } to { opacity: 1; transform: scale(1); } }
.request-detail-modal__head {
    display: flex;
    gap: 14px;
    padding: 24px 24px 16px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    align-items: center;
}
.request-detail-modal__avatar {
    width: 52px; height: 52px;
    border-radius: 14px;
    background: rgba(212,175,55,0.15);
    color: var(--gold);
    font-weight: 800; font-size: 1.05rem;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.request-detail-modal__head h3 {
    font-family: 'Sora','Manrope',sans-serif;
    font-size: 1rem; font-weight: 800; color: #fff; margin: 0 0 4px;
}
.request-detail-modal__head p { font-size: 0.8rem; color: var(--text-muted); margin: 0; }
.request-detail-modal__head .status-pill { margin-top: 6px; }
.request-detail-modal__close {
    margin-left: auto; align-self: flex-start;
    background: none; border: 1px solid rgba(255,255,255,0.1);
    color: #fff; font-size: 1.2rem; width: 32px; height: 32px;
    border-radius: 8px; cursor: pointer; flex-shrink: 0;
}
.request-detail-modal__body { padding: 20px 24px 24px; }
.request-detail-modal__body h4 {
    font-family: 'Sora','Manrope',sans-serif; font-size: 0.85rem;
    font-weight: 700; color: #fff; margin-bottom: 10px;
}
.request-detail-modal__body p { font-size: 0.88rem; color: rgba(255,255,255,0.7); line-height: 1.6; }
.request-detail-modal__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 20px; padding-top: 16px; border-top: 1px solid rgba(255,255,255,0.06); }
.request-detail-modal__grid div span { display: block; font-size: 0.7rem; text-transform: uppercase; color: var(--text-muted); letter-spacing: 0.03em; margin-bottom: 4px; }
.request-detail-modal__grid div strong { font-size: 0.88rem; color: #fff; font-weight: 700; }

/* Skeleton loading cards */
.skeleton-card {
    pointer-events: none;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.skeleton-shimmer {
    background: linear-gradient(90deg, #1a0f2e 25%, #2a1845 50%, #1a0f2e 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s ease-in-out infinite;
    border-radius: 8px;
}

/* Mobile */
@media (max-width: 640px) {
    .requests-page {
        width: calc(100% - 20px);
        margin: 16px auto 36px;
    }

    .requests-page__header h1 {
        font-size: 1.2rem;
    }

    .request-card {
        grid-template-columns: 44px 1fr;
        padding: 16px;
        gap: 12px;
    }

    .request-card__avatar {
        width: 44px;
        height: 44px;
        font-size: 0.9rem;
        border-radius: 12px;
    }

    .request-card__name {
        font-size: 0.9rem;
    }

    .request-card__service {
        font-size: 0.8rem;
    }

    .request-card__actions {
        grid-column: 1 / -1;
        justify-content: stretch;
        margin-top: 4px;
    }

    .request-card__chat-btn {
        width: 100%;
        justify-content: center;
        height: 44px;
        font-size: 0.85rem;
    }
}