/* ═══════════════════════════════════════════════════════════
   AIRBID — task-detail.css
═══════════════════════════════════════════════════════════ */

/* ── LAYOUT ── */
.td-main {
    background: #f3f4f6;
    padding: 36px 0 72px;
    min-height: calc(100vh - 200px);
}

.td-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--on-surface);
    text-decoration: none;
    background: #fff;
    border: 1px solid var(--outline-variant);
    border-radius: 99px;
    padding: 7px 16px;
    margin-bottom: 22px;
    transition: border-color 0.15s, color 0.15s;
}
.td-back-link:hover { border-color: var(--deep-teal); color: var(--deep-teal); }
.td-back-link .material-symbols-outlined { font-size: 16px; }

.td-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 24px;
    align-items: flex-start;
}
.td-panel-card {
    background: #fff;
    border: 1px solid var(--outline-variant);
    border-radius: var(--radius-xl);
    padding: 28px;
}

/* ── SIDEBAR — task info ── */
.td-sidebar { position: sticky; top: 84px; }

.td-task-card {
    background: #fff;
    border: 1px solid var(--outline-variant);
    border-radius: var(--radius-xl);
    padding: 28px;
}

.td-task-badges {
    display: flex;
    gap: 8px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.td-badge {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    border-radius: 99px;
    padding: 4px 12px;
}

.td-badge-open { background: rgba(76,195,155,0.13); color: #1e8a5e; }
.td-badge-reviewing { background: rgba(240,170,40,0.15); color: #9a6400; }
.td-badge-in-progress { background: rgba(23,62,75,0.10); color: var(--deep-teal); }
.td-badge-cat { background: rgba(23,62,75,0.08); color: var(--deep-teal); }

.td-task-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 20px;
    line-height: 1.35;
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Meta grid */
.td-task-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 20px;
}

.td-meta-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.td-meta-item > .material-symbols-outlined {
    font-size: 20px;
    color: var(--deep-teal);
    margin-top: 2px;
    flex-shrink: 0;
}

.td-meta-label {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    color: var(--outline);
    margin: 0 0 2px;
    text-transform: uppercase;
}

.td-meta-val {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0;
    font-family: 'Montserrat', sans-serif;
}

.td-meta-type {
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--outline);
}

.td-meta-address {
    font-size: 0.75rem;
    color: var(--outline);
    margin: 3px 0 0;
    line-height: 1.4;
    overflow-wrap: break-word;
    word-break: break-word;
}

.td-divider {
    height: 1px;
    background: var(--outline-variant);
    margin: 20px 0;
}

.td-section-heading {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 10px;
}

.td-desc {
    font-size: 0.875rem;
    color: var(--on-surface-variant);
    line-height: 1.65;
    margin: 0 0 10px;
}

/* Break long unbroken strings so free-text never overflows its card */
.td-desc-body,
.td-desc-body p,
.td-desc,
.td-qa-q,
.td-qa-a,
.td-bid-message {
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Q&A */
.td-qa-list { display: flex; flex-direction: column; gap: 10px; }

.td-qa-row {
    background: #f8f9fa;
    border-radius: var(--radius-md);
    padding: 10px 14px;
}

.td-qa-q {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--outline);
    margin: 0 0 3px;
}

.td-qa-a {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--on-surface);
    margin: 0;
}


/* ── BIDS PANEL ── */
.td-bids-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.td-bids-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 4px;
}

.td-bids-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0;
}

.td-bids-sub {
    font-size: 0.8125rem;
    color: var(--outline);
    margin: 3px 0 0;
}


/* ── BID CARD ── */
.td-bid-card {
    background: #fff;
    border: 1.5px solid var(--outline-variant);
    border-radius: var(--radius-xl);
    padding: 22px 24px;
    transition: border-color 0.15s, box-shadow 0.15s;
    position: relative;
}

.td-bid-card:hover {
    border-color: var(--deep-teal);
    box-shadow: 0 3px 16px rgba(23,62,75,0.09);
}

/* featured / recommended card */
.td-bid-featured {
    border-color: var(--deep-teal);
    background: linear-gradient(135deg, #fff 80%, rgba(23,62,75,0.03));
    /* leave a little room for the badge that straddles the top border */
    padding-top: 28px;
}

/* ── HIRED (selected) card — stands out as the winner ── */
.td-bid-hired {
    border-color: #4cc39b;
    border-width: 2px;
    background: linear-gradient(135deg, #fff 70%, rgba(76, 195, 155, 0.08));
    box-shadow: 0 4px 20px rgba(76, 195, 155, 0.16);
}
.td-bid-hired:hover {
    border-color: #4cc39b;
    box-shadow: 0 4px 20px rgba(76, 195, 155, 0.22);
}

/* ── PASSED (not selected) card — tinted grey so it reads as inactive ── */
.td-bid-passed {
    opacity: 0.8;
    background: #f1f3f4;
    border-color: #e0e3e5;
    box-shadow: none;
}
.td-bid-passed:hover {
    /* keep it muted even on hover — it's no longer actionable */
    border-color: #e0e3e5;
    box-shadow: none;
    opacity: 0.88;
}

/* ── BID BADGE ROW ── */
/* Recommended badge straddles the card's top border, on the right side. */
.td-bid-badges {
    position: absolute;
    top: 0;
    right: 18px;
    transform: translateY(-50%);
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    z-index: 1;
}

.td-bid-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    border-radius: 99px;
    padding: 4px 11px;
}

.td-bid-badge .material-symbols-outlined { font-size: 13px; }

.td-bbadge-recommended { background: var(--deep-teal); color: #fff; }
.td-bbadge-hired { background: #4cc39b; color: #fff; }
.td-bbadge-rejected { background: #e0e3e5; color: #6b7280; }

/* bid top row */
.td-bid-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.td-bidder-info {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    flex: 1;
    min-width: 0;
}

/* Avatar */
.td-avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
}

.td-avatar-teal    { background: var(--deep-teal); }
.td-avatar-coral   { background: var(--vibrant-coral); }
.td-avatar-emerald { background: var(--emerald-accent); color: #fff; }
.td-avatar-purple  { background: #7c3aed; }
.td-avatar-gold    { background: #d97706; }

.td-bidder-name {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 2px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.td-verified-badge .material-symbols-outlined {
    font-size: 16px;
    color: var(--deep-teal);
    font-variation-settings: 'FILL' 1;
}

.td-bidder-title {
    font-size: 0.8125rem;
    color: var(--outline);
    margin: 0 0 4px;
}

.td-bidder-email {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--deep-teal);
    text-decoration: none;
}

.td-bidder-email:hover {
    text-decoration: underline;
}

.td-bidder-email .material-symbols-outlined {
    font-size: 13px;
}

/* Stars */
.td-stars {
    display: flex;
    align-items: center;
    gap: 1px;
}

.td-star, .td-star-half {
    font-size: 14px;
    color: #f59e0b;
    font-variation-settings: 'FILL' 1;
}

.td-star-empty {
    font-size: 14px;
    color: #d1d5db;
}

.td-rating-text {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--on-surface);
    margin-left: 5px;
}

.td-review-count {
    font-weight: 400;
    color: var(--outline);
}

/* Bid amount block */
.td-bid-amount-wrap {
    text-align: right;
    flex-shrink: 0;
}

.td-bid-amount {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 2px;
    line-height: 1;
}

.td-bid-type {
    font-size: 0.75rem;
    color: var(--outline);
    margin: 0 0 6px;
}

.td-bid-delivery {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--deep-teal);
    background: rgba(23,62,75,0.07);
    border-radius: 99px;
    padding: 3px 10px;
    margin: 0;
}

.td-bid-delivery .material-symbols-outlined { font-size: 14px; }

/* Bid message */
.td-bid-message {
    font-size: 0.875rem;
    color: var(--on-surface-variant);
    line-height: 1.65;
    margin: 0 0 16px;
}

/* Bid actions */
.td-bid-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.td-hire-btn {
    background: var(--vibrant-coral);
    color: #fff;
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    border: none;
    border-radius: var(--radius-lg);
    padding: 10px 20px;
    cursor: pointer;
    transition: opacity 0.15s, transform 0.1s;
}
.td-hire-btn:hover { opacity: 0.87; transform: translateY(-1px); }

/* hired / not-selected status pills (shown after a bid is decided) */
.td-hired-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: #1e8a5e;
    background: rgba(76, 195, 155, 0.14);
    border-radius: 99px;
    padding: 8px 16px;
}
.td-hired-badge .material-symbols-outlined { font-size: 17px; }

.td-rejected-badge {
    display: inline-flex;
    align-items: center;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--outline);
    background: var(--surface-low);
    border-radius: 99px;
    padding: 8px 16px;
}


.td-profile-link {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--outline);
    text-decoration: none;
    margin-left: auto;
}
.td-profile-link:hover { color: var(--deep-teal); text-decoration: underline; }

/* ── HIRE MODAL ── */
.td-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.td-modal {
    background: #fff;
    border-radius: var(--radius-xl);
    padding: 36px 32px;
    max-width: 420px;
    width: 100%;
    text-align: center;
    box-shadow: 0 24px 60px rgba(0,0,0,0.18);
}

.td-modal-icon-wrap {
    width: 64px;
    height: 64px;
    background: rgba(23,62,75,0.08);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
}

.td-modal-icon {
    font-size: 32px;
    color: var(--deep-teal);
    font-variation-settings: 'FILL' 1;
}

.td-modal-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 10px;
}

.td-modal-body {
    font-size: 0.9rem;
    color: var(--on-surface-variant);
    line-height: 1.6;
    margin: 0 0 24px;
}

.td-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.td-modal-confirm {
    background: var(--vibrant-coral);
    color: #fff;
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.9375rem;
    font-weight: 700;
    border: none;
    border-radius: var(--radius-lg);
    padding: 13px;
    cursor: pointer;
    transition: opacity 0.15s;
}
.td-modal-confirm:hover { opacity: 0.87; }

.td-modal-cancel {
    background: transparent;
    color: var(--outline);
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    border: 1.5px solid var(--outline-variant);
    border-radius: var(--radius-lg);
    padding: 12px;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s;
}
.td-modal-cancel:hover { border-color: var(--deep-teal); color: var(--deep-teal); }

/* ── CHAT MODAL ── */
.td-modal--chat {
    max-width: 460px;
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 80vh;
}

.td-chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
    background: var(--deep-teal);
    color: #fff;
}

.td-chat-tasker {
    display: flex;
    align-items: center;
    gap: 10px;
}

.td-chat-avatar {
    font-size: 40px;
    opacity: 0.9;
}

.td-chat-header .td-modal-title {
    color: #fff;
    font-size: 1rem;
    margin: 0;
}

.td-chat-close {
    background: transparent;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.15s;
}

.td-chat-close:hover { background: rgba(255,255,255,0.15); }
.td-chat-close .material-symbols-outlined { font-size: 22px; }

.td-chat-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background: #f3f4f6;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.td-chat-msg {
    display: flex;
    flex-direction: column;
    max-width: 82%;
    gap: 4px;
}

.td-chat-msg--incoming {
    align-self: flex-start;
    align-items: flex-start;
}

.td-chat-msg--outgoing {
    align-self: flex-end;
    align-items: flex-end;
}

.td-chat-bubble {
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 0.875rem;
    line-height: 1.5;
    word-wrap: break-word;
}

.td-chat-msg--incoming .td-chat-bubble {
    background: #fff;
    color: var(--on-surface);
    border-bottom-left-radius: 4px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

.td-chat-msg--outgoing .td-chat-bubble {
    background: var(--deep-teal);
    color: #fff;
    border-bottom-right-radius: 4px;
}

.td-chat-time {
    font-size: 0.6875rem;
    color: var(--outline);
}

.td-chat-footer {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    background: #fff;
    border-top: 1px solid #e2e4e7;
}

.td-chat-input {
    flex: 1;
    border: 1.5px solid #e2e4e7;
    border-radius: 99px;
    padding: 10px 16px;
    font-family: 'Nunito Sans', sans-serif;
    font-size: 0.875rem;
    color: var(--on-surface);
    outline: none;
    transition: border-color 0.15s, background-color 0.15s;
}

.td-chat-input:focus { border-color: var(--deep-teal); }
.td-chat-input.input-error {
    border-color: #c0392b;
    background-color: rgba(192, 57, 43, 0.04);
}
.td-chat-input.input-error:focus { border-color: #c0392b; }

.td-chat-send {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--deep-teal);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: opacity 0.15s, transform 0.1s;
    flex-shrink: 0;
}

.td-chat-send:hover { opacity: 0.87; transform: translateY(-1px); }
.td-chat-send .material-symbols-outlined { font-size: 18px; }

/* ── CHAT ATTACHMENTS ── */
.td-chat-attach {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: transparent;
    color: var(--deep-teal);
    border: 1.5px solid var(--outline-variant);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    flex-shrink: 0;
}
.td-chat-attach:hover { background: rgba(23, 62, 75, 0.06); border-color: var(--deep-teal); }
.td-chat-attach .material-symbols-outlined { font-size: 20px; }

.td-chat-attachment-preview {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: #f8fafb;
    border-top: 1px solid #e2e4e7;
    font-size: 0.8125rem;
    color: var(--on-surface-variant);
}
.td-chat-attachment-preview .material-symbols-outlined { font-size: 18px; color: var(--deep-teal); }
.td-chat-attachment-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.td-chat-attachment-remove {
    background: none;
    border: none;
    color: var(--outline);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
}
.td-chat-attachment-remove:hover { color: #c0392b; }

.td-chat-attachment {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
    padding: 6px 10px;
    border-radius: 8px;
    background: rgba(255,255,255,0.2);
    color: inherit;
    font-size: 0.8125rem;
    text-decoration: none;
    word-break: break-all;
}
.td-chat-msg--incoming .td-chat-attachment { background: var(--deep-teal-10, rgba(23,62,75,0.08)); color: var(--deep-teal); }
.td-chat-attachment .material-symbols-outlined { font-size: 16px; }

.td-chat-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--outline);
    padding: 30px 20px;
}
.td-chat-empty h6 { margin: 12px 0 4px; color: var(--on-surface); }
.td-chat-empty p { margin: 0; }

/* ── CHAT VALIDATION BAR ── */
.td-chat-validation-bar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    padding: 6px 16px 10px;
    background: #fff;
    border-top: 1px solid #f0f1f3;
    font-size: 0.78rem;
    min-height: 28px;
}
.td-chat-counter {
    color: var(--outline);
    font-weight: 600;
    transition: color 0.15s;
    white-space: nowrap;
}
.td-chat-counter.is-limit { color: #c0392b; }
.td-chat-error {
    color: #c0392b;
    font-weight: 600;
    text-align: right;
    flex: 1;
    min-width: 0;
    line-height: 1.3;
}
.td-chat-error:empty { display: none; }

/* ── RESPONSIVE ── */
@media (max-width: 1199.98px) {
    .td-layout { grid-template-columns: 300px 1fr; }
}

/* tablet: stack sidebar above bids */
@media (max-width: 991.98px) {
    .td-layout { grid-template-columns: 1fr; }
    .td-sidebar { position: static; }
    .td-task-meta { grid-template-columns: repeat(2, 1fr); }
    .td-bids-head { flex-direction: column; align-items: flex-start; }
}

/* large mobile */
@media (max-width: 767.98px) {
    .td-main { padding: 24px 0 56px; }
    .td-task-card { padding: 22px; }
    .td-bid-card { padding: 20px; }
    .td-bid-amount { font-size: 1.2rem; }
    .td-modal { padding: 28px 20px; }
    .td-bid-actions { flex-wrap: wrap; gap: 8px; }
    .td-profile-link { margin-left: 0; }
}

@media (max-width: 575.98px) {
    .td-task-card { padding: 16px; }
    .td-task-meta { grid-template-columns: 1fr; gap: 10px; }
    .td-bid-card { padding: 16px; }
    .td-bid-top { flex-direction: column; gap: 12px; }
    .td-bid-amount-wrap { text-align: left; }
    .td-bid-actions { flex-direction: column; align-items: stretch; }
    .td-hire-btn { text-align: center; }
    .td-profile-link { margin-left: 0; text-align: center; }
    .td-bidder-info { flex-wrap: wrap; }
    .td-qa-list { gap: 8px; }
    .td-task-title { font-size: 1rem; }
    .td-bid-badges { gap: 5px; }
    .td-bid-badge { font-size: 0.625rem; padding: 3px 9px; }
}

@media (max-width: 374.98px) {
    .td-main { padding: 16px 0 48px; }
    .td-task-card { padding: 14px; }
    .td-bid-card { padding: 14px; }
    .td-avatar { width: 38px; height: 38px; font-size: 0.75rem; }
    .td-bid-amount { font-size: 1.125rem; }
    .td-modal { padding: 24px 16px; }
    .td-back-link { font-size: 0.8125rem; padding: 6px 12px; }
}


/* ═══════════════════════════════════════════════════════════
   TASK DETAIL — DESIGN ENHANCEMENTS
═══════════════════════════════════════════════════════════ */

/* ── FIX META ICONS ── */
.td-meta-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(23, 62, 75, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.td-meta-icon .material-symbols-outlined {
    font-size: 18px;
    color: var(--deep-teal);
}

/* ── TASK CARD CATEGORY LEFT BORDER ── */
.td-task-card[data-category="development"] { border-left: 4px solid var(--deep-teal); }
.td-task-card[data-category="marketing"]   { border-left: 4px solid #4CC39B; }
.td-task-card[data-category="design"]      { border-left: 4px solid var(--vibrant-coral); }
.td-task-card[data-category="admin"]       { border-left: 4px solid #965AC8; }
.td-task-card[data-category="strategy"]    { border-left: 4px solid #28B4B4; }
.td-task-card[data-category="finance"]     { border-left: 4px solid #F0AA28; }

/* ── ENHANCED CLIENT CARD ── */
.td-client-card {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    background: linear-gradient(135deg, #f8fafb 0%, #ffffff 100%);
    border: 1.5px solid var(--outline-variant);
}
.td-client-avatar {
    width: 48px;
    height: 48px;
    font-size: 0.9375rem;
    box-shadow: 0 2px 6px rgba(23, 62, 75, 0.15);
}

/* Message button placed at the right of the client card */
.td-message-btn--client {
    margin-left: auto;
    flex-shrink: 0;
}

@media (max-width: 575.98px) {
    .td-message-btn--client {
        margin-left: 0;
        width: 100%;
        justify-content: center;
    }
}

/* ── ENHANCED COIN CHIP ── */
.td-coin-chip {
    background: linear-gradient(135deg, rgba(240,107,100,0.08) 0%, rgba(240,107,100,0.02) 100%);
    border: 1.5px solid rgba(240,107,100,0.25);
}
.td-coin-chip .material-symbols-outlined {
    font-size: 22px;
}

/* ── ENHANCED BID FORM ── */
.td-bid-form {
    background: linear-gradient(180deg, #ffffff 0%, #fafbfc 100%);
    border: 1.5px solid var(--outline-variant);
}

/* ── ENHANCED SUBMIT BUTTON ── */
.td-submit-btn {
    background: linear-gradient(135deg, var(--deep-teal) 0%, #1a3340 100%);
    box-shadow: 0 4px 14px rgba(23, 62, 75, 0.3);
}
.td-submit-btn:hover {
    opacity: 1;
    box-shadow: 0 6px 20px rgba(23, 62, 75, 0.4);
    transform: translateY(-2px);
}

/* ── POLISHED Q&A ROWS ── */
.td-qa-row {
    background: #fff;
    border: 1px solid var(--outline-variant);
    transition: border-color 0.15s, box-shadow 0.15s;
}
.td-qa-row:hover {
    border-color: var(--deep-teal);
    box-shadow: 0 2px 8px rgba(23, 62, 75, 0.06);
}

/* ── POLISHED SKILLS TAGS ── */
.td-skill-tag {
    border: 1px solid transparent;
    transition: background 0.15s, border-color 0.15s, transform 0.1s;
}
.td-skill-tag:hover {
    background: rgba(23, 62, 75, 0.12);
    border-color: rgba(23, 62, 75, 0.2);
    transform: translateY(-1px);
}

/* ── SECTION HEADER POLISH ── */
.td-section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}
.td-section-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-md);
    background: rgba(23, 62, 75, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--deep-teal);
    font-size: 18px !important;
}

/* ── ENTRANCE ANIMATIONS ── */
@keyframes td-fade-up {
    from { opacity: 0; transform: translateY(18px); }
    to   { opacity: 1; transform: translateY(0); }
}
.td-task-card {
    animation: td-fade-up 0.5s ease-out both;
}
.td-bid-form {
    animation: td-fade-up 0.5s ease-out 0.1s both;
}

/* ── BACK LINK POLISH ── */
.td-back-link {
    box-shadow: 0 1px 3px rgba(23, 62, 75, 0.06);
}

/* ── RESPONSIVE TWEAKS ── */
@media (max-width: 575.98px) {
    .td-task-card { border-left-width: 3px !important; }
    .td-meta-icon { width: 32px; height: 32px; }
    .td-meta-icon .material-symbols-outlined { font-size: 16px; }
}

/* ── Bid form validation errors ── */
.td-form-error {
    font-size: 0.78rem;
    color: #c0392b;
    margin: 4px 0 0;
    line-height: 1.3;
}
.td-form-input.input-error,
.td-form-textarea.input-error {
    border-color: #c0392b;
}

/* ── Submit button loading state ── */
.td-submit-btn.is-loading {
    opacity: 0.85;
    pointer-events: none;
    cursor: progress;
}
.td-spin {
    display: inline-block;
    animation: td-spin 0.8s linear infinite;
    vertical-align: middle;
}
@keyframes td-spin {
    to { transform: rotate(360deg); }
}

/* ═══════════════════════════════════════════════════════════
   TASKER PROFILE DETAILS (inside bid card)
   ═══════════════════════════════════════════════════════════ */

/* Avatar image override */
.td-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    display: block;
}

/* Rating review count */
.td-review-count {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--outline);
    margin-left: 4px;
}

/* Profile details panel */
.td-tasker-profile {
    background: #f8f9fa;
    border: 1px solid var(--outline-variant);
    border-radius: var(--radius-lg);
    padding: 18px 18px 14px;
    margin: 0 0 16px;
}

.td-tasker-profile-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 12px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.td-tasker-bio {
    font-size: 0.875rem;
    color: var(--on-surface-variant);
    line-height: 1.65;
    margin: 0 0 14px;
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Meta grid */
.td-tasker-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 14px;
}

.td-tasker-meta-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.td-tasker-meta-item > .material-symbols-outlined {
    font-size: 18px;
    color: var(--deep-teal);
    margin-top: 1px;
    flex-shrink: 0;
}

.td-tasker-meta-label,
.td-tasker-meta-value {
    display: block;
}

.td-tasker-meta-label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--outline);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 1px;
}

.td-tasker-meta-value {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--on-surface);
}

/* Categories */
.td-tasker-categories {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}

.td-tasker-categories-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--outline);
    margin-right: 2px;
}

.td-tasker-category-tag {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--deep-teal);
    background: rgba(23, 62, 75, 0.08);
    border: 1px solid rgba(23, 62, 75, 0.12);
    border-radius: 99px;
    padding: 3px 10px;
}

/* Company / business details */
.td-tasker-company {
    margin-bottom: 14px;
}

.td-tasker-company-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 8px;
}

.td-tasker-company-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.td-tasker-company-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.td-tasker-company-label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--outline);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.td-tasker-company-value {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--on-surface);
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Website link */
.td-tasker-website {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 14px;
}

.td-tasker-website .material-symbols-outlined {
    font-size: 18px;
    color: var(--deep-teal);
}

.td-tasker-website-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--deep-teal);
    text-decoration: none;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.td-tasker-website-link:hover {
    text-decoration: underline;
}

.td-tasker-website-link .material-symbols-outlined {
    font-size: 14px;
    flex-shrink: 0;
}

/* Verification badges */
.td-tasker-badges {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.td-tasker-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 99px;
    padding: 4px 10px;
}

.td-tasker-badge .material-symbols-outlined {
    font-size: 14px;
}

.td-tasker-badge--verified {
    color: #1e8a5e;
    background: rgba(76, 195, 155, 0.14);
}

/* Responsive tweaks for tasker profile panel */
@media (max-width: 575.98px) {
    .td-tasker-meta-grid,
    .td-tasker-company-grid {
        grid-template-columns: 1fr;
    }
}

/* ═══════════════════════════════════════════════════════════
   BID CARD REDESIGN — expanded, readable list
   ═══════════════════════════════════════════════════════════ */

/* Card wrapper */
.td-bid-card {
    padding: 26px 28px;
}

/* Summary row */
.td-bid-summary {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 24px;
}

/* Bidder info */
.td-bidder-info-compact {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.td-bidder-info-compact .td-avatar {
    width: 56px;
    height: 56px;
    font-size: 1rem;
}

.td-bidder-main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.td-bidder-name-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.td-bidder-name-row .td-bidder-name {
    margin: 0;
    font-size: 1rem;
}

.td-bidder-title {
    font-size: 0.875rem;
    margin: 0;
}

.td-bidder-email {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--deep-teal);
    text-decoration: none;
}

.td-bidder-email:hover {
    text-decoration: underline;
}

.td-bidder-email .material-symbols-outlined {
    font-size: 14px;
}

/* Quick stats block */
.td-bid-quick-stats {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    text-align: right;
    flex-shrink: 0;
}

.td-stars--compact {
    margin-bottom: 0;
}

.td-stars--compact .td-star,
.td-stars--compact .td-star-half,
.td-stars--compact .td-star-empty {
    font-size: 15px;
}

.td-bid-quick-stats .td-bid-amount-wrap {
    text-align: right;
}

.td-bid-quick-stats .td-bid-amount {
    font-size: 1.5rem;
    margin: 0 0 4px;
}

.td-bid-quick-stats .td-bid-delivery {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--deep-teal);
    background: rgba(23,62,75,0.07);
    border-radius: 99px;
    padding: 4px 10px;
    margin: 0;
}

/* Footer bar: View profile on left, Hire/status on right */
.td-bid-footer-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

/* Hire / status action aligned with View profile */
.td-bid-summary-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 0;
}

/* Bid message — visible without expanding */
.td-bid-card .td-bid-message {
    font-size: 0.9375rem;
    color: var(--on-surface-variant);
    line-height: 1.65;
    margin: 18px 0 14px;
    overflow-wrap: break-word;
    word-break: break-word;
}

/* Expand/collapse toggle */
.td-bid-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--deep-teal);
    background: rgba(23, 62, 75, 0.06);
    border: 1px solid rgba(23, 62, 75, 0.12);
    border-radius: var(--radius-lg);
    padding: 10px 18px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}

.td-bid-toggle:hover {
    background: rgba(23, 62, 75, 0.1);
    border-color: rgba(23, 62, 75, 0.2);
}

.td-bid-toggle[aria-expanded="true"] .td-bid-toggle-icon {
    transform: rotate(180deg);
}

.td-bid-toggle-icon {
    font-size: 20px;
    transition: transform 0.2s ease;
}

/* Expandable details panel */
.td-bid-details {
    margin-top: 20px;
}

.td-bid-details[hidden] {
    display: none;
}

/* Profile panel inside expanded details */
.td-tasker-profile-compact {
    background: #f8f9fa;
    border: 1px solid var(--outline-variant);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 18px;
}

.td-tasker-meta-grid-compact {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 28px;
    margin-bottom: 14px;
}

.td-tasker-meta-item-compact {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--on-surface-variant);
}

.td-tasker-meta-item-compact .material-symbols-outlined {
    font-size: 18px;
    color: var(--deep-teal);
}

.td-tasker-categories-compact {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
}

.td-tasker-categories-compact .td-tasker-category-tag {
    font-size: 0.8125rem;
    padding: 4px 12px;
}

.td-tasker-bio-compact {
    font-size: 0.9375rem;
    color: var(--on-surface-variant);
    line-height: 1.65;
    margin-bottom: 14px;
    overflow-wrap: break-word;
    word-break: break-word;
}

.td-tasker-compact-section {
    margin-bottom: 14px;
}

.td-tasker-compact-section h5 {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--on-surface);
    margin: 0 0 8px;
}

.td-tasker-compact-list {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.875rem;
    color: var(--on-surface-variant);
    line-height: 1.65;
}

.td-tasker-compact-list li {
    margin-bottom: 4px;
}

/* Responsive bid card */
@media (max-width: 767.98px) {
    .td-bid-summary {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .td-bid-quick-stats {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 12px;
        width: 100%;
    }

    .td-bid-summary-actions {
        margin-top: 0;
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 575.98px) {
    .td-bid-card {
        padding: 20px;
    }

    .td-bidder-info-compact {
        gap: 12px;
    }

    .td-bidder-info-compact .td-avatar {
        width: 48px;
        height: 48px;
        font-size: 0.875rem;
    }

    .td-bid-footer-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .td-bid-toggle {
        justify-content: center;
    }

    .td-bid-summary-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .td-bid-summary-actions .td-message-btn,
    .td-bid-summary-actions .td-hire-btn,
    .td-bid-summary-actions .td-hired-badge,
    .td-bid-summary-actions .td-rejected-badge,
    .td-bid-summary-actions .td-feedback-btn {
        justify-content: center;
        width: 100%;
    }
}

/* ── MESSAGE BUTTON (static placeholder) ── */
.td-message-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    color: var(--deep-teal);
    border: 1.5px solid var(--deep-teal);
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 0.8125rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}
.td-message-btn:hover {
    background: var(--deep-teal);
    color: #fff;
    text-decoration: none;
}
.td-message-btn .material-symbols-outlined { font-size: 16px; }

.td-message-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    background: #c0392b;
    color: #fff;
    font-size: 0.6875rem;
    font-weight: 700;
    line-height: 1;
    margin-left: 4px;
}
.td-message-badge.d-none { display: none; }

/* ── FEEDBACK BUTTON & MODAL ── */
.td-feedback-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--vibrant-coral);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 8px 14px;
    font-size: 0.8125rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.15s;
}
.td-feedback-btn:hover { opacity: 0.9; }
.td-feedback-btn .material-symbols-outlined { font-size: 16px; }

.td-modal--wide { max-width: 480px; }

.td-star-rating {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 16px 0;
}
.td-star-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: #d1d5db;
    transition: color 0.15s, transform 0.1s;
}
.td-star-btn:hover { transform: scale(1.1); }
.td-star-btn.is-selected { color: #fbbf24; }
.td-star-rating.is-invalid .td-star-btn { color: #ef4444; }
.td-star-btn .material-symbols-outlined { font-size: 36px; }

.td-rating-hint {
    text-align: center;
    font-size: 0.8125rem;
    color: var(--outline, #888);
    margin-top: 6px;
}
.td-rating-error {
    text-align: center;
    color: #dc2626;
    font-size: 0.8125rem;
    font-weight: 600;
    margin-top: 6px;
}

.td-form-label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--on-surface);
    margin-bottom: 6px;
}
.td-textarea {
    width: 100%;
    border: 1px solid var(--outline-variant);
    border-radius: 10px;
    padding: 12px;
    font-size: 0.875rem;
    resize: vertical;
    min-height: 100px;
}
.td-textarea:focus {
    outline: none;
    border-color: var(--deep-teal);
}

.td-char-count {
    text-align: right;
    font-size: 0.75rem;
    color: var(--outline, #888);
    margin-top: 6px;
}

/* ── CLIENT FEEDBACK BOX (tasker active job) ── */
.td-review-box {
    background: #f8fafb;
    border: 1px solid var(--outline-variant);
    border-radius: 12px;
    padding: 18px;
}
.td-review-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--on-surface);
    margin-bottom: 10px;
}
.td-review-stars {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 10px;
}
.td-review-stars .material-symbols-outlined {
    font-size: 20px;
}
.td-review-stars .td-star-filled { color: #fbbf24; }
.td-review-stars .td-star-empty { color: #d1d5db; }
.td-review-rating {
    margin-left: 6px;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--on-surface);
}
.td-review-comment {
    font-size: 0.9375rem;
    color: var(--on-surface);
    line-height: 1.5;
    margin-bottom: 10px;
    font-style: italic;
}
.td-review-meta {
    font-size: 0.75rem;
    color: var(--outline);
    margin-bottom: 0;
}

/* ── LOCATION MAP CARD ── */
.td-map-card {
    border: 1px solid var(--outline-variant);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: #fff;
    box-shadow: 0 1px 2px rgba(23, 62, 75, 0.04);
}

.td-map-address {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 12px 14px;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.5;
    color: var(--on-surface);
    background: #fff;
    border-bottom: 1px solid var(--outline-variant);
}

.td-map-address .material-symbols-outlined {
    font-size: 20px;
    color: var(--deep-teal);
    flex-shrink: 0;
    margin-top: 1px;
}

.td-map-wrap {
    position: relative;
    height: 240px;
    width: 100%;
    background: #eef2f4;
}

.td-map-frame {
    height: 100%;
    width: 100%;
}

.td-map-frame .leaflet-control-attribution {
    font-size: 9px !important;
    padding: 2px 6px !important;
    background: rgba(255, 255, 255, 0.85) !important;
    border-top-left-radius: 6px;
}

.td-map-frame .leaflet-control-attribution a {
    color: var(--outline) !important;
}

.td-map-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 450;
}

.td-map-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 13px;
    background: rgba(23, 62, 75, 0.88);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 999px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(4px);
    transition: transform .2s ease, background .2s ease;
}

.td-map-clickable:hover + .td-map-overlay .td-map-pill,
.td-map-wrap:hover .td-map-overlay .td-map-pill {
    background: var(--deep-teal);
    transform: translateY(-1px);
}

.td-map-pill .material-symbols-outlined {
    font-size: 16px;
}

.td-map-note {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    font-size: 0.78rem;
    color: var(--outline);
    background: #fff;
    border-top: 1px solid var(--outline-variant);
    margin: 0;
}

.td-map-note .material-symbols-outlined {
    font-size: 14px;
    flex-shrink: 0;
}

.td-map-actions {
    display: flex;
    gap: 10px;
    padding: 0 14px 14px;
    background: #fff;
}

.td-directions-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex: 1;
    padding: 11px 16px;
    border-radius: var(--radius-lg, 10px);
    background: var(--deep-teal, #173e4b);
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    transition: background .2s ease, transform .1s ease;
    border: none;
    cursor: pointer;
}

.td-directions-btn:hover {
    background: #1f5161;
    color: #fff;
    transform: translateY(-1px);
}

.td-directions-btn:active {
    transform: translateY(0);
}

.td-directions-btn .material-symbols-outlined {
    font-size: 1.1rem;
}

/* ── FULL-PAGE CHAT ── */
.chat-page-wrapper {
    max-width: 1320px;
}

.td-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--deep-teal);
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.15s;
}

.td-back-link:hover {
    color: var(--vibrant-coral);
    text-decoration: none;
}

.td-back-link .material-symbols-outlined { font-size: 18px; }

.td-chat-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(15,23,42,0.08);
    overflow: hidden;
}

.td-chat-card .td-chat-header {
    border-radius: 0;
    flex-shrink: 0;
}

.td-chat-task-meta {
    font-size: 0.8125rem;
    color: var(--text-muted, #64748b);
    font-weight: 400;
}

.td-chat-card .td-chat-body {
    flex: 1;
    min-height: 260px;
}

.td-chat-empty-icon {
    font-size: 48px;
    opacity: 0.3;
}

/* ── TASK DETAILS CARD INSIDE CHAT PAGE ── */
.td-task-card--chat {
    height: 100%;
    margin-bottom: 0;
}

.td-task-card--chat .td-task-title {
    font-size: 1.25rem;
    line-height: 1.35;
}

.td-task-card--chat .td-task-meta {
    grid-template-columns: 1fr;
    gap: 10px;
}

/* Desktop: fixed-height two-column layout */
@media (min-width: 992px) {
    .chat-page-wrapper .row {
        min-height: calc(100vh - 180px);
    }

    .chat-page-wrapper .td-chat-card {
        height: calc(100vh - 180px);
        min-height: 500px;
    }

    .chat-page-wrapper .td-chat-body {
        max-height: none;
    }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 991px) {
    .chat-page-wrapper .td-chat-card {
        min-height: 500px;
    }
}

/* Mobile */
@media (max-width: 767px) {
    .chat-page-wrapper {
        padding-left: 10px;
        padding-right: 10px;
        padding-top: 0.75rem;
        padding-bottom: 0.75rem;
    }

    .td-back-link {
        font-size: 0.8125rem;
    }

    .td-task-card--chat {
        padding: 1rem;
    }

    .td-task-card--chat .td-task-title {
        font-size: 1.1rem;
    }

    .td-task-card--chat .td-task-badges {
        margin-bottom: 0.75rem;
    }

    .td-task-card--chat .td-task-meta {
        gap: 8px;
        margin-bottom: 1rem;
    }

    .td-task-card--chat .td-meta-item {
        gap: 0.6rem;
    }

    .td-task-card--chat .td-meta-icon {
        width: 32px;
        height: 32px;
    }

    .td-task-card--chat .td-meta-icon .material-symbols-outlined {
        font-size: 18px;
    }

    .td-task-card--chat .td-meta-label {
        font-size: 0.6875rem;
    }

    .td-task-card--chat .td-meta-val {
        font-size: 0.8125rem;
    }

    .td-task-card--chat .td-section-header {
        margin-bottom: 0.5rem;
    }

    .td-task-card--chat .td-section-heading {
        font-size: 0.9375rem;
    }

    .td-task-card--chat .td-desc-body {
        font-size: 0.8125rem;
        line-height: 1.5;
    }

    .td-task-card--chat .td-desc-body p {
        display: -webkit-box;
        -webkit-line-clamp: 4;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .chat-page-wrapper .td-chat-card {
        min-height: 420px;
    }

    .td-chat-card .td-chat-header {
        padding: 0.875rem 1rem;
    }

    .td-chat-card .td-chat-tasker {
        gap: 0.6rem;
    }

    .td-chat-avatar {
        font-size: 2rem;
    }

    .td-chat-card .td-modal-title {
        font-size: 1rem;
    }

    .td-chat-card .td-chat-body {
        padding: 1rem;
        min-height: 220px;
    }

    .td-chat-card .td-chat-footer {
        padding: 0.75rem 1rem;
        gap: 0.5rem;
    }

    .td-chat-input {
        padding: 0.6rem 0.9rem;
        font-size: 0.875rem;
    }

    .td-chat-send,
    .td-chat-attach {
        width: 38px;
        height: 38px;
    }

    .td-chat-validation-bar {
        padding: 0.35rem 1rem;
    }

    .td-chat-attachment-preview {
        margin: 0 1rem 0.75rem;
    }
}
