/* HEADER */
.map-tools-header {
    padding: 10px 18px;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

/* BODY */
.map-tools-body {
    padding: 14px 18px 18px 18px;
    transition: all 0.3s ease;
}

/* ROW */
.map-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: end;
    margin-bottom: 10px;
}

/* GROUP */
.map-group {
    display: flex;
    flex-direction: column;
    font-size: 11px;
    color: #666;
}

.map-group input,
.map-group select {
    margin-top: 4px;
}

/* INPUT */
.map-row input,
.map-row select {
    padding: 7px 10px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    font-size: 13px;
    background: white;
}

/* CHECKBOX */
.map-row label {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 4px;
    color: #555;
}

/* BUTTON */
.map-row button {
    border: none;
    padding: 7px 12px;
    border-radius: 8px;
    font-size: 13px;
    cursor: pointer;
    transition: 0.2s ease;
}

.btn-primary {
    background: #0d6efd;
    color: white;
}

.btn-success {
    background: #198754;
    color: white;
}

.btn-warning {
    background: #ffc107;
}

.btn-soft {
    background: #f1f3f5;
}

.map-row button:hover {
    transform: translateY(-1px);
}

.map-tools-body.collapsed {
    display: none;
}

.map-tools {
    position: absolute;
    top: 70px;
    left: 50%;
    transform: translateX(-50%);
    width: 94%;
    max-width: 1250px;

    backdrop-filter: blur(12px);
    background: rgba(255, 255, 255, 0.75);

    border-radius: 20px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);

    z-index: 3000;
    font-family: Inter, sans-serif;

    transition: all 0.35s ease;
}

/* Khi mở thì nổi hơn */
.map-tools.active {
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.9);
}

/* HEADER */
.map-tools-header {
    padding: 12px 20px;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Header đổi màu nhẹ khi active */
.map-tools.active .map-tools-header {
    background: rgba(13, 110, 253, 0.06);
}

/* Mũi tên */
.arrow {
    transition: transform 0.4s cubic-bezier(.34, 1.56, .64, 1);
    font-size: 14px;
}

/* BODY */
.map-tools-body {
    overflow: hidden;
    padding: 16px 20px 20px 20px;

    max-height: 600px;
    opacity: 1;
    transform: translateY(0);

    transition:
        max-height 0.5s cubic-bezier(.4, 0, .2, 1),
        opacity 0.3s ease,
        transform 0.4s ease,
        padding 0.3s ease;
}

/* Khi đóng */
.map-tools-body.collapsed {
    max-height: 0;
    opacity: 0;
    transform: translateY(-15px);
    padding-top: 0;
    padding-bottom: 0;
}

/* Bounce nhẹ khi mở */
.map-tools-body.opening {
    animation: bounceOpen 0.45s ease;
}

@keyframes bounceOpen {
    0% {
        transform: translateY(-20px);
    }

    60% {
        transform: translateY(5px);
    }

    100% {
        transform: translateY(0);
    }
}

/* MOBILE */
@media(max-width:768px) {
    .map-row {
        flex-direction: column;
        align-items: stretch;
    }

    .map-row input,
    .map-row select,
    .map-row button {
        width: 100%;
    }
}

.menu-link {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    display: block;
}

.left-toolbar {

    position: absolute;

    top: 120px;

    left: 15px;

    display: flex;

    flex-direction: column;

    gap: 12px;

    z-index: 1500;

}

.circle-btn {

    width: 46px;

    height: 46px;

    border: none;

    border-radius: 50%;

    background: white;

    cursor: pointer;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 18px;

    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);

    transition: 0.2s;

}

.circle-btn:hover {

    background: #f2f2f2;

    transform: scale(1.05);

}

.circle-btn i {

    color: #333;

}

.pointLabel {
    background: red;
    color: white;
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.edgeLabel {
    background: yellow;
    padding: 2px 4px;
    font-size: 12px;
}

.areaLabel {
    background: blue;
    color: white;
    padding: 4px 6px;
    border-radius: 5px;
    font-weight: bold;
}

.infoBox {
    position: absolute;
    right: 20px;
    top: 20px;
    background: white;
    padding: 10px;
    border-radius: 6px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
    z-index: 999;
}

.menu-item {
    cursor: pointer;
}

a {
    text-decoration: none;
    color: inherit;
}

.login-popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99999;

    display: none;
    align-items: center;
    justify-content: center;
}

.popup-box {
    background: #fff;
    padding: 25px;
    border-radius: 12px;
    width: 340px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    position: relative;
}

.popup-close {
    margin-top: 15px;
    border: none;
    background: #eee;
    padding: 6px 14px;
    border-radius: 6px;
    cursor: pointer;
}

.popup-close:hover {
    background: #ddd;
}

.popup-icon {
    font-size: 40px;
    color: #ff5a5a;
    margin-bottom: 10px;
}

.popup-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
}

.btn-login {
    background: #4f46e5;
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
}

.btn-register {
    background: #10b981;
    color: white;
    padding: 8px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
}

.popup-close {
    margin-top: 15px;
    border: none;
    background: none;
    color: #666;
    cursor: pointer;
}

@keyframes popupFade {
    from {
        transform: scale(0.8);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.map-toolbox {

    position: absolute;

    right: 15px;
    bottom: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;

    z-index: 8;

}

/* nút chính */

.toolbox-main {

    width: 40px;
    height: 40px;

    border-radius: 50%;

    border: none;

    background: #1a73e8;

    color: white;

    font-size: 22px;

    cursor: pointer;

    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);

}

/* menu */

.toolbox-menu {

    display: flex;
    flex-direction: column;

    gap: 2px;

    margin-bottom: 10px;

    background: white;

    padding: 2px;

    border-radius: 16px;

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);

    /* hidden */

    opacity: 0;

    transform: translateY(60px);

    pointer-events: none;

    transition: all .3s ease;

}

/* open */

.toolbox-menu.active {

    opacity: 1;

    transform: translateY(0);

    pointer-events: auto;

}

/* button */

.toolbox-menu button {

    width: 42px;
    height: 42px;

    border-radius: 12px;

    border: none;

    background: #f5f6f8;

    cursor: pointer;

    font-size: 16px;

    display: flex;
    align-items: center;
    justify-content: center;

    transition: .2s;

}

.toolbox-menu button:hover {

    background: #e8f0fe;

    transform: scale(1.08);

}

.toolbox-menu button {

    width: 55px;

    border: none;
    background: none;

    display: flex;
    flex-direction: column;

    align-items: center;

    padding: 6px;

    cursor: pointer;

    border-radius: 10px;

    transition: 0.2s;

}

.toolbox-menu button:hover {

    background: #f3f6ff;

}

/* icon */

.toolbox-menu i {

    font-size: 18px;

}

/* chữ */

.toolbox-menu span {

    font-size: 10px;

    margin-top: 2px;

    color: #666;

    font-weight: 500;

}


.search-panel {

    margin-top: 10px;

    background: #fff;

    border-radius: 12px;

    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);

    overflow: hidden;

}

.search-header {

    padding: 10px 14px;

    background: #f5f6f8;

    display: flex;

    justify-content: space-between;

    align-items: center;

    cursor: pointer;

    font-weight: 600;

    font-size: 14px;

}

.search-header:hover {

    background: #eef1f5;

}

.search-body {

    padding: 12px;

    transition: all .25s ease;

}

.search-body.collapsed {

    display: none;

}

.search-grid {

    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 10px;

}

.search-card {

    background: #fafafa;

    border-radius: 10px;

    padding: 10px;

    border: 1px solid #eee;

}

.search-title {

    font-size: 13px;

    font-weight: 600;

    margin-bottom: 6px;

}


.search-row {

    display: flex;

    gap: 6px;

    margin-bottom: 6px;

}

.search-row input {

    flex: 1;

    padding: 6px;

    font-size: 12px;

    border: 1px solid #ddd;

    border-radius: 6px;

}

.search-btn {

    width: 100%;

    border: none;

    background: #1a73e8;

    color: white;

    padding: 6px;

    border-radius: 6px;

    font-size: 12px;

    cursor: pointer;

}

.search-btn:hover {

    background: #0d5ed7;

}

/* =========================
RESPONSIVE
========================= */

/* Tablet */
@media (max-width: 992px) {

    .search-grid {
        grid-template-columns: 1fr;
    }

}

/* Mobile */
@media (max-width: 576px) {

    .search-header {
        font-size: 13px;
        padding: 8px 10px;
    }

    .search-card {
        padding: 8px;
    }

    .search-title {
        font-size: 12px;
    }

    .search-row input {
        font-size: 11px;
        padding: 5px;
    }

    .search-btn {
        font-size: 11px;
        padding: 5px;
    }

}

.measure-toast {

    position: absolute;

    top: 50%;
    left: 50%;

    transform: translate(-50%, -50%) scale(.8);

    background: white;

    padding: 18px 24px;

    border-radius: 14px;

    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.25);

    display: flex;

    flex-direction: column;

    align-items: center;

    gap: 8px;

    font-size: 14px;

    opacity: 0;

    pointer-events: none;

    transition: .35s;

    z-index: 9999;

}

.measure-toast.show {

    opacity: 1;

    transform: translate(-50%, -50%) scale(1);

}

/* loading spinner */

.toast-loading {

    width: 28px;
    height: 28px;

    border: 3px solid #eee;

    border-top: 3px solid #1a73e8;

    border-radius: 50%;

    animation: spin 1s linear infinite;

}

/* success icon */

.toast-success {

    font-size: 28px;

    color: #28a745;

}

@keyframes spin {

    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }

}

.export-actions {
    position: absolute;
    right: 16px;
    top: 70px; /* chỉnh lại theo thanh menu của bạn */
    display: flex;
    gap: 8px;
    align-items: center;
    z-index: 999;
}

.export-btn {
    background: #e53935;
    color: #fff;
    border: none;
    padding: 8px 12px;
    border-radius: 10px;
    font-size: 14px;
    cursor: pointer;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    display: none;
    white-space: nowrap;
}

.export-btn:hover {
    background: #c62828;
}

a {
    text-decoration: none;
}

.search-body.collapsed {
    display: none;
}

.hide {
    display: none;
}

@media (max-width: 768px) {
    .export-actions {
        right: 10px;
        top: 64px;
        gap: 6px;
        flex-wrap: wrap;
        justify-content: flex-end;
        max-width: calc(100vw - 20px);
    }

    .export-btn {
        font-size: 9px;
        padding: 5px 3px;
        border-radius: 8px;
    }
}

/* BODY PANEL MAP TOOLS */

.map-tools-body {

    max-height: 70vh;
    /* chiều cao tối đa */
    overflow-y: auto;
    /* cho phép scroll */
    padding-right: 4px;

}

/* thanh scroll đẹp hơn */

.map-tools-body::-webkit-scrollbar {
    width: 6px;
}

.map-tools-body::-webkit-scrollbar-thumb {
    background: #c9c9c9;
    border-radius: 10px;
}

.map-tools-body::-webkit-scrollbar-thumb:hover {
    background: #999;
}

.logo-wrap{
    display:flex;
    align-items:center;
    gap:10px;
    text-decoration:none;
}

/* LOGO ICON */
.site-logo{
    width:34px;
    height:34px;
    object-fit:cover;
    border-radius:8px;
    box-shadow:0 2px 6px rgba(0,0,0,0.15);
}

/* TEXT */
.logo-text{
    font-size:18px;
    font-weight:600;
    color:#1f2937;
    letter-spacing:0.2px;
}

/* HEADER BAR */
.top-bar{
    height:56px;
    padding:0 16px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    background:#fff;
    box-shadow:0 1px 4px rgba(0,0,0,0.08);
}

/* LOGO WRAP */
.logo-wrap{
    display:flex;
    align-items:center;
    gap:8px;
    text-decoration:none;
}

/* ICON */
.site-logo{
    width:28px;
    height:28px;
    object-fit:contain;
    border-radius:6px;
}

/* TEXT */
.logo-text{
    font-size:16px;
    font-weight:500;
    color:#202124; /* giống Google */
}

/* HEADER */
.top-bar{
    height:56px;
    padding:0 16px;
    display:flex;
    align-items:center;
    justify-content:space-between;
    background:#fff;
    border-bottom:1px solid #e5e7eb;
}

.logo-text{
    font-size:16px;
    font-weight:700;
    letter-spacing:0.3px;
    background:linear-gradient(
        90deg,
        #1e3a8a,
        #2563eb,
        #0ea5e9,
        #f59e0b,
        #2563eb,
        #1e3a8a
    );
    background-size:300% auto;
    -webkit-background-clip:text;
    -webkit-text-fill-color:transparent;
    background-clip:text;
    animation:logoShine 4s linear infinite;
}

@keyframes logoShine{
    0%{
        background-position:0% center;
    }
    100%{
        background-position:300% center;
    }
}


#savedMapBtn.saved-map-btn {
    position: fixed;
    left: 14px;
    bottom: 120px;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: #dbe7cf;
    color: #1f2937;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.18);
    cursor: pointer;
    z-index: 2000;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#savedMapBtn.saved-map-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

#savedMapBtn.saved-map-btn i {
    font-size: 23px;
}

.saved-map-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.22);
    opacity: 0;
    visibility: hidden;
    transition: 0.25s ease;
    z-index: 9998;
}

.saved-map-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.gm-sheet {
    position: fixed;
    left: 16px;
    bottom: 88px;
    top: auto;
    width: min(390px, calc(100vw - 32px));
    max-height: 68vh;
    background: #fff;
    border-radius: 22px;
    box-shadow: 0 18px 46px rgba(0, 0, 0, 0.24);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.96);
    transition: 0.25s ease;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.gm-sheet.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.gm-sheet-handle {
    width: 52px;
    height: 5px;
    border-radius: 999px;
    background: #d1d5db;
    margin: 10px auto 2px;
    flex: 0 0 auto;
}

.gm-sheet-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px 10px;
    border-bottom: 1px solid #edf1f5;
}

.gm-sheet-title {
    font-size: 22px;
    font-weight: 700;
    color: #1f2937;
    line-height: 1.15;
}

.gm-sheet-subtitle {
    margin-top: 4px;
    font-size: 13px;
    color: #6b7280;
}

.gm-sheet-close {
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 999px;
    background: #f3f4f6;
    color: #111827;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    flex: 0 0 auto;
}

.gm-sheet-close:hover {
    background: #e5e7eb;
}

.gm-layer-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 12px 16px;
    border-bottom: 1px solid #edf1f5;
}

.gm-chip input {
    display: none;
}

.gm-chip span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    background: #f1f3f4;
    color: #3c4043;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s ease;
}

.gm-chip input:checked + span {
    background: #e8f0fe;
    color: #1967d2;
    box-shadow: inset 0 0 0 1px #c6dafc;
}

.gm-sheet-body {
    padding: 14px 16px 16px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.gm-group {
    border-top: 1px solid #eef2f7;
    padding-top: 14px;
}

.gm-group:first-child {
    border-top: 0;
    padding-top: 0;
}

.gm-group-title {
    font-size: 17px;
    font-weight: 700;
    color: #374151;
    margin-bottom: 12px;
}

.gm-scroll-row {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x proximity;
}

.gm-scroll-row::-webkit-scrollbar {
    height: 6px;
}

.gm-scroll-row::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 999px;
}

.gm-map-card {
    min-width: 85px;
    max-width: 85px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    padding: 12px;
    cursor: pointer;
    transition: 0.18s ease;
    scroll-snap-align: start;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.04);
}

.gm-map-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
    border-color: #d0d7de;
}

.gm-thumb {
    height: 10px;
    border-radius: 4px;
    background: linear-gradient(135deg, #dbeafe, #fef3c7);
    display: flex;
    align-items: center;
    font-size: 22px;
    margin-bottom: 10px;
    justify-content: space-evenly;

}

.gm-map-name {
    font-size: 8px;
    line-height: 1.35;
    font-weight: 700;
    color: #202124;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 38px;
    word-break: break-word;
}

.gm-map-meta {
    margin-top: 5px;
    font-size: 13px;
    color: #060606;
}

.gm-sheet-footer {
    border-top: 1px solid #edf1f5;
    padding: 12px 16px 14px;
    display: flex;
    justify-content: flex-end;
}

.gm-footer-btn {
    min-width: 110px;
    height: 42px;
    border: 0;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.gm-footer-btn.primary {
    background: #1a73e8;
    color: #fff;
}

.saved-map-empty {
    text-align: center;
    color: #6b7280;
    font-size: 14px;
    padding: 22px 10px;
}
.load-map-btn {
    position: relative;
    min-height: 42px;
    border-radius: 12px;
    font-weight: 700;
    transition: all .2s ease;
    box-shadow: 0 6px 18px rgba(13, 110, 253, .18);
}

.load-map-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(13, 110, 253, .22);
}

.load-btn-inner {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.load-btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.35);
    border-top-color: #fff;
    border-radius: 50%;
    display: none;
    animation: loadBtnSpin .8s linear infinite;
}

.load-map-btn.is-loading {
    pointer-events: none;
    opacity: .92;
}

.load-map-btn.is-loading .load-btn-spinner {
    display: inline-block;
}

.load-map-btn.is-loading .load-btn-text {
    content: "Đang tải...";
}

.load-map-btn:disabled {
    cursor: not-allowed;
    opacity: .85;
}

@keyframes loadBtnSpin {
    to {
        transform: rotate(360deg);
    }
}
@media (max-width: 640px) {
    #savedMapBtn.saved-map-btn {
        left: 14px;
        bottom: 120px;
        width: 45px;
        height: 45px;
    }

    .gm-sheet {
        left: 12px;
        bottom: 80px;
        width: calc(100vw - 24px);
        max-height: 70vh;
        border-radius: 20px;
    }

    .gm-sheet-title {
        font-size: 20px;
    }

    .gm-map-card {
        min-width: 146px;
        max-width: 146px;
    }

    .gm-thumb {
        height: 50px;
        font-size: 28px;
    }
}

.gm-area-filter {
    padding: 12px 10px 8px;
    border-top: 1px solid #e9ecef;
    margin-top: 10px;
}

.gm-area-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #374151;
}

.gm-area-select {
    width: 100%;
    border: 1px solid #d0d7de;
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 14px;
    outline: none;
    background: #fff;
}

.gm-map-meta {
    font-size: 5px;
    line-height: 1.5;
    color: #6b7280;
}

.gm-card-actions {
    margin-top: 0px;
    display: flex;
    justify-content: space-around;
}
.gm-delete-btn {
    border: none;
    background: #fff1f2;
    color: #e11d48;
    padding: 6px 10px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}


.upgrade-vip-box {
    margin-top: 12px;
    padding: 12px;
    border-radius: 12px;
    background: #fff4e6;
    border: 1px solid #ffd8a8;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

.upgrade-vip-text {
    font-size: 13px;
    font-weight: 700;
    color: #9c4f00;
}

.upgrade-vip-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: linear-gradient(135deg, #ff922b, #f76707);
    color: #fff !important;
    text-decoration: none;
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(247, 103, 7, .22);
}

.upgrade-vip-btn:hover {
    color: #fff !important;
    opacity: .95;
}
/* =========================
   PARCEL SEARCH UI
========================= */

.parcel-panel {
    width: 100%;
    margin-top: 12px;
    font-family: Arial, sans-serif;
}

.parcel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 16px;
    font-weight: 600;
    color: #2b2b2b;
    margin-bottom: 7px;
    cursor: pointer;
    user-select: none;
}

.parcel-header span:first-child {
    display: flex;
    align-items: center;
    gap: 8px;
}

#parcelArrow {
    font-size: 16px;
    color: #444;
    transition: transform 0.2s ease;
}

.parcel-body {
    background: #f8f8f8;
    border: 1px solid #ececec;
    border-radius: 18px;
    padding: 16px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

.parcel-body.collapsed {
    display: none;
}

/* Hàng input */
.parcel-filter {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 16px;
}

.parcel-filter input {
    width: 100%;
    height: 40px;
    padding: 0 20px;
    border: 1px solid #d9d9d9;
    border-radius: 18px;
    background: #fff;
    font-size: 14px;
    color: #333;
    outline: none;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.parcel-filter input::placeholder {
    color: #8c8c8c;
    font-weight: 400;
}

.parcel-filter input:focus {
    border-color: #2b7cff;
    box-shadow: 0 0 0 4px rgba(43,124,255,0.10);
    background: #fff;
}

/* Vùng danh sách */
#parcelList {
    max-height: 360px;
    overflow-y: auto;
    padding-right: 6px;
}

/* Mỗi dòng kết quả */
.parcel-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

/* Ô thông tin */
.parcel-row > div {
     min-height: 40px;       /* ↓ giảm chiều cao */
    padding: 8px 12px;      /* ↓ giảm padding */
    font-size: 14px;  
    background: #fff;
    border: 1px solid #e2e2e2;
    border-radius: 16px;
   
    display: flex;
    align-items: center;
   
    color: #2f2f2f;
    line-height: 1.4;
    box-sizing: border-box;
    word-break: break-word;
}

/* label đậm */
.parcel-row > div b {
    margin-right: 6px;
    color: #111;
}

/* hover đẹp */
.parcel-row:hover > div {
    background: #f4f8ff;
    border-color: #cfe0ff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(43,124,255,0.08);
}

/* dòng đang chọn nếu muốn dùng thêm class active */
.parcel-row.active > div {
    background: #eaf2ff;
    border-color: #2b7cff;
}

/* scrollbar */
#parcelList::-webkit-scrollbar {
    width: 8px;
}

#parcelList::-webkit-scrollbar-track {
    background: transparent;
}

#parcelList::-webkit-scrollbar-thumb {
    background: #c8c8c8;
    border-radius: 10px;
}

#parcelList::-webkit-scrollbar-thumb:hover {
    background: #aaaaaa;
}

/* responsive */
@media (max-width: 1200px) {
    .parcel-filter,
    .parcel-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .parcel-filter,
    .parcel-row {
        grid-template-columns: 1fr;
    }

    .parcel-filter input,
    .parcel-row > div {
        min-height: 54px;
        height: auto;
        font-size: 16px;
    }

    .parcel-header {
        font-size: 18px;
    }
}
