/* ============================= */
/* DASHBOARD LAYOUT */
/* ============================= */
.page-id-222375 #main-header,
.page-id-222375 #main-footer {
    display: none !important;
}

.page-id-222375 .main_title {
    display: none !important;
}

p.adsm-blocked-user {
    display: grid;
    background: #e6e7e7;
    justify-content: center;
    align-items: center;
    height: 200px;
    border-radius: 12px;
    font-size: 20px;
    font-weight: 600;
}


.adsm-dashboard {
    display: flex;
    background: #f2f3f5;
    gap: 16px;
    padding: 20px;
    border-radius: 10px;
    min-height: 798px;
}

.adsm-sidebar-logo {
    height: 28px;
    width: auto;
    display: block;
}

/* ============================= */
/* SIDEBAR */
/* ============================= */

.adsm-dashboard-sidebar {
    width: 260px;
    background: linear-gradient(180deg, #ededed, #e2e2e2);
    padding: 24px 18px;
    display: flex;
    flex-direction: column;
    border-radius: 12px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.06);
    border: 2px solid rgba(0, 0, 0, 0.04);
}

.adsm-sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.adsm-logo {
    font-size: 25px;
    font-weight: 700;
    margin-bottom: 15px;
}

.adsm-menu-toggle {
    display: none;
    font-size: 22px;
    cursor: pointer;
    user-select: none;
}

.adsm-dashboard-sidebar ul {
    list-style: none !important;
    padding: 0;
    margin-top: 27px;
}

.adsm-dashboard-sidebar li {
    margin-bottom: 8px;
}

.adsm-dashboard-sidebar li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 10px;
    color: #111;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: background 0.25s ease, box-shadow 0.25s ease;
}

.adsm-dashboard-sidebar li a::before {
    font-size: 22px;
    width: 30px;
    text-align: center;
    opacity: 0.75;
}

.adsm-dashboard-sidebar a[href*="overview"]::before {
    content: "🏠";
}

.adsm-dashboard-sidebar a[href*="tracking"]::before {
    content: "🔍";
}

.adsm-dashboard-sidebar a[href*="shipments"]::before {
    content: "📦";
}

.adsm-dashboard-sidebar a[href*="prealerts"]::before {
    content: "⚠️";
}

.adsm-dashboard-sidebar a[href*="mailbox"]::before {
    content: "📬";
}

.adsm-dashboard-sidebar a[href*="notifications"]::before {
    content: "🔔";
}

.adsm-dashboard-sidebar a[href*="authorized-users"]::before {
    content: "🚚";
}

.adsm-dashboard-sidebar a[href*="profile"]::before {
    content: "⚙️";
}

.adsm-dashboard-sidebar .adsm-logout-link::before {
    content: "↩️";
}

.adsm-dashboard-sidebar li a:hover {
    background: rgba(255, 255, 255, 0.6);
}

.adsm-dashboard-sidebar li.active a {
    background: #ffffff;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
}

.adsm-logout-link {
    color: #b00020 !important;
}

.adsm-logout-link::before {
    color: #b00020;
}

.adsm-badge {
    margin-left: auto;
    background: #e45a02;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 1px 12px;
    border-radius: 20px;
}

/* ============================= */
/* CONTENT */
/* ============================= */

.adsm-dashboard-content {
    flex: 1;
    padding: 28px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.05);
}

.adsm-dashboard-content h2 {
    font-weight: 700;
}

/* ============================= */
/* PROFILE FORM  */
/* ============================= */

.adsm-profile-form {
    max-width: 100%;
    background: #e5e9ed;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

.adsm-profile-form .adsm-label {
    display: block;
    margin-bottom: 16px;
    font-weight: 600;
    font-size: 13px;
    color: #333;
}

.adsm-profile-form input,
.adsm-profile-form select {
    width: 100%;
    padding: 12px 14px !important;
    margin-top: 6px;
    border-radius: 6px;
    border: 1px solid #dcdfe4;
    font-size: 14px;
    background: #fff;
}

.adsm-profile-form input:focus,
.adsm-profile-form select:focus {
    border-color: #0b5ed7;
    outline: none;
}

.adsm-readonly-box {
    background: #ffffff;
    padding: 14px;
    border-radius: 6px;
    margin-bottom: 18px;
    font-size: 14px;
}

.adsm-form-message {
    margin-top: 12px;
    font-size: 14px;
}



/* ============================= */
/* AUTHORIZED PICKUPS / GRID */
/* ============================= */

.adsm-page-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
}

.adsm-grid {
    display: grid;
    gap: 25px;
}

.adsm-card {
    background: #e5e9ed;
    border-radius: 10px;
    padding: 22px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.06);
    margin-top: 10px;
}

.adsm-dashboard-content .adsm-card p {
    padding-bottom: 0em !important;
}

.adsm-card-form {
    background: #e5e9ed;
}

.adsm-card-form .adsm-label {
    display: block;
    margin-bottom: 16px;
    font-weight: 600;
    font-size: 13px;
    color: #333;
}

.adsm-card-form input,
.adsm-card-form select {
    width: 100%;
    padding: 12px 14px !important;
    margin-top: 6px;
    border-radius: 6px;
    border: 1px solid #dcdfe4;
    font-size: 14px;
    background: #fff;
}

.adsm-modal-content .adsm-label {
    display: block;
    margin-bottom: 16px;
    font-weight: 600;
    font-size: 13px;
    color: #333;
}

.adsm-modal-content .adsm-label input,
.adsm-modal-content .adsm-label select {
    width: 100%;
    padding: 12px 14px !important;
    margin-top: 6px;
    border-radius: 6px;
    border: 1px solid #dcdfe4;
    font-size: 14px;
    background: #fff;
}

/* ============================= */
/* TABLES */
/* ============================= */

.adsm-table {
    width: 100%;
    border-collapse: collapse;
}

.adsm-table th,
.adsm-table td {
    padding: 12px;
    border-bottom: 4px solid #e45a02;
}

/* ============================= */
/* BUTTONS */
/* ============================= */

.adsm-btn {
    padding: 8px 12px;
    background: #e45a02;
    color: #fff;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    margin-top: 10px;
}

.adsm-btn-danger {
    background: #e45a02;
}

.adsm-btn-secondary {
    background: #6c757d;
}

/* ============================= */
/* MODALS */
/* ============================= */

.adsm-modal,
.adsm-modal-pickup {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
}

.adsm-modal.active,
.adsm-modal-pickup.adsm-show {
    opacity: 1;
    visibility: visible;
}

.adsm-modal-content,
.adsm-modal-content-pickup {
    background: #fff;
    padding: 25px;
    border-radius: 10px;
    max-width: 420px;
    width: 100%;
}

.adsm-logout-modal-content {
    text-align: center;
}

.adsm-logout-title {
    margin: 0;
    text-align: center;
}

.adsm-logout-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.adsm-delete-modal-content {
    text-align: center;
}

.adsm-delete-title {
    margin-top: 0;
}

.adsm-modal-actions {
    margin-top: 10px;
}

select#adsm-new-location-pickup {
    width: 100%;
    border-radius: 10px;
    padding: 10px 15px;
}


.adsm-invoice-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: .25s ease;
    z-index: 9999;
}

.adsm-invoice-modal.show {
    opacity: 1;
    visibility: visible;
}

.adsm-invoice-modal-content {
    background: #fff;
    padding: 24px;
    border-radius: 10px;
    max-width: 380px;
    width: 90%;
    text-align: center;
}

.adsm-invoice-modal-actions {
    margin-top: 15px;
    display: flex;
    justify-content: center;
}


/* ============================= */
/* REQUEST STATUS */
/* ============================= */

.adsm-request-status {
    margin: 15px 0;
    padding: 12px;
    background: #f8fafc;
    border-radius: 6px;
    font-size: 14px;
}

.adsm-status {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.adsm-status-pending {
    background: #fff3cd;
    color: #856404;
}

.adsm-status-approved {
    background: #d4edda;
    color: #155724;
}

.adsm-status-rejected {
    background: #f8d7da;
    color: #721c24;
}

/* ============================= */
/* CUSTOMER NOTIFICATIONS */
/* ============================= */

.adsm-notification-card {
    margin-bottom: 15px;
}

.adsm-notification-card h4 {
    margin: 0 0 8px;
    font-size: 16px;
    font-weight: 700;
}

.adsm-notification-card p {
    margin: 0 0 10px;
    font-size: 14px;
    color: #333;
    font-weight: 400;
}

.adsm-notification-card small {
    color: #777;
}

/* ============================= */
/* MOBILE (SAFE, NON-DESTRUCTIVE) */
/* ============================= */

@media (max-width: 768px) {

    .adsm-dashboard {
        flex-direction: column;
        padding-bottom: 12px;
    }

    .adsm-dashboard-sidebar {
        width: 100%;
    }

    .adsm-grid {
        display: flow-root;
        grid-template-columns: 1fr;
    }

    .adsm-profile-form {
        max-width: 100%;
    }

    .adsm-dashboard-content {
        padding: 20px;
    }

    .adsm-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

/* ================================================= */
/* RESPONSIVE + HAMBURGER (SAFE ENHANCEMENT) */
/* ================================================= */

/* ---------- TABLET ---------- */
@media (max-width: 1024px) {

    .adsm-dashboard {
        gap: 12px;
        padding: 12px;
    }

    .adsm-dashboard-content {
        padding: 24px;
    }

    .adsm-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}


/* ---------- MOBILE ---------- */
@media (max-width: 768px) {

    /* Show hamburger */
    .adsm-menu-toggle {
        display: block;
    }

    /* Sidebar header stays visible - must be positioned */
    .adsm-dashboard-sidebar {
        width: 100%;
        padding: 14px 16px;
        position: relative;
        z-index: 1001;
        box-shadow: none;
        border: none;
    }

    .adsm-sidebar-header {
        position: relative;
        z-index: 1003;
    }

    .adsm-logo {
        margin-bottom: 0;
        font-size: 16px;
    }

    /* Hide menu by default */
    .adsm-dashboard-sidebar ul {
        position: fixed;
        top: 42px;
        /* 🔴 FIX: push menu below logo */
        left: calc(-280px - 56px);
        margin-left: 15px;
        width: 260px;
        max-height: calc(100vh - 104px);
        /* 🔴 FIX */

        background: linear-gradient(180deg, #ededed, #e2e2e2);
        padding: 24px !important;

        display: flex;
        flex-direction: column;
        gap: 6px;

        transition: left 0.3s ease;
        z-index: 1002;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;

        box-shadow: 2px 2px 12px rgba(0, 0, 0, 0.15);
        border-radius: 12px;
    }

    .adsm-dashboard-sidebar {
        background: #f2f3f5;
    }

    /* Open menu */
    #adsm-menu-toggle:checked~.adsm-dashboard-sidebar ul {
        left: 0;
    }

    /* Overlay */
    .adsm-sidebar-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.45);
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.3s ease;
        z-index: 1000;
        pointer-events: none;
    }

    #adsm-menu-toggle:checked~.adsm-sidebar-overlay {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    /* Sidebar items spacing */
    .adsm-dashboard-sidebar li {
        margin-bottom: 6px;
    }

    .adsm-dashboard-sidebar li a {
        padding: 12px 14px;
    }

    /* Content stays clean */
    .adsm-dashboard-content {
        padding: 20px;
        border-radius: 10px;
    }

    /* Forms */
    .adsm-profile-form {
        max-width: 100%;
        padding: 20px;
    }

    /* Cards */
    .adsm-card {
        padding: 18px;
    }

    /* Tables */
    .adsm-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    /* Status blocks */
    .adsm-request-status {
        font-size: 13px;
    }
}

/* ===== PRE-ALERT FORM GRID ===== */

.adsm-label-pre-alerts {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 14px;
}

/*.adsm-label-pre-alerts input {*/
/*    width: 100%;*/
/*    border-radius: 6px;*/
/*    border: 1px solid #bababb;*/
/*}*/

.adsm-label-pre-alerts.required::before {
    content: " *";
    color: #e63946;
}

/*.adsm-grid-form {*/
/*    display: grid;*/
/*    grid-template-columns: 1fr 1fr;*/
/*    gap: 25px;*/
/*    margin-top: 15px;*/
/*}*/

.adsm-form-col {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.adsm-form-actions {
    grid-column: 1 / -1;
    margin-top: 10px;
}

.adsm-form-actions .adsm-btn {
    padding: 10px 18px;
}

.adsm-prealert-form {
    max-width: 100%;
    background: #e5e9ed;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

.adsm-label-pre-alerts input {
    width: 100%;
    padding: 12px 14px !important;
    margin-top: 6px;
    border-radius: 6px;
    border: 1px solid #b3b3b3;
    font-size: 14px;
    background: #fff;
}

.adsm-prealert-form input:focus,
.adsm-prealert-form select:focus {
    border-color: #0b5ed7;
    outline: none;
}

/* ===== REAL MOBILE FIX PATCH ===== */

@media (max-width: 768px) {

    .adsm-dashboard {
        min-height: auto !important;
        height: auto !important;
    }

    .adsm-grid {
        display: grid !important;
        grid-template-columns: 1fr;
    }

    .adsm-dashboard-sidebar ul {
        left: -100%;
    }

    html,
    body {
        overflow-x: hidden;
    }
}

/* ============================= */
/* TRACKING TIMELINE MODAL */
/* ============================= */

/* Status Badge */
.adsm-status-badge {
    display: inline-block;
    padding: 2px 12px;
    background: #fff3cd;
    color: #856404;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* Tracking Modal */
.adsm-tracking-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.adsm-tracking-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.adsm-tracking-modal-content {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    max-width: 600px;
    width: 90%;
    max-height: 85vh;
    overflow-y: auto;
    padding: 32px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    z-index: 2;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.adsm-tracking-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: transparent;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.adsm-tracking-modal-close:hover {
    background: #f3f4f6;
    color: #111827;
}

.adsm-tracking-modal-title {
    font-size: 24px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 20px 0;
}

.adsm-tracking-info {
    background: #f9fafb;
    padding: 16px;
    border-radius: 10px;
    margin-bottom: 30px;
    border-left: 4px solid #e45a02;
}

.adsm-tracking-info p {
    margin: 8px 0;
    font-size: 14px;
    color: #374151;
}

.adsm-tracking-info strong {
    color: #111827;
    font-weight: 600;
}

/* Timeline */
.adsm-tracking-timeline {
    position: relative;
    padding: 10px 0;
}

.adsm-timeline-item {
    display: flex;
    gap: 20px;
    position: relative;
    padding-bottom: 32px;
}

.adsm-timeline-item:last-child {
    padding-bottom: 0;
}

.adsm-timeline-marker {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.adsm-timeline-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

/* Pending Status */
.adsm-timeline-item.pending .adsm-timeline-icon {
    background: #e5e7eb;
    border: 3px solid #d1d5db;
}

.adsm-timeline-item.pending .adsm-step-number {
    display: block;
    color: #9ca3af;
    font-weight: 600;
    font-size: 14px;
}

.adsm-timeline-item.pending .adsm-check-icon {
    display: none;
}

.adsm-timeline-item.pending .adsm-timeline-status {
    color: #9ca3af;
}

.adsm-timeline-item.pending .adsm-timeline-description {
    color: #d1d5db;
}

/* Completed Status */
.adsm-timeline-item.completed .adsm-timeline-icon {
    background: #10b981;
    border: 3px solid #059669;
}

.adsm-timeline-item.completed .adsm-step-number {
    display: none;
}

.adsm-timeline-item.completed .adsm-check-icon {
    display: block;
}

.adsm-timeline-item.completed .adsm-timeline-status {
    color: #059669;
    font-weight: 600;
}

.adsm-timeline-item.completed .adsm-timeline-description {
    color: #6b7280;
}

.adsm-timeline-item.completed .adsm-timeline-line {
    background: #10b981;
}

/* Current Status */
.adsm-timeline-item.current .adsm-timeline-icon {
    background: #e45a02;
    border: 3px solid #ff7a00;
    box-shadow: 0 0 0 4px rgba(228, 90, 2, 0.2);
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 0 0 4px rgba(228, 90, 2, 0.2);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(228, 90, 2, 0.1);
    }
}

.adsm-timeline-item.current .adsm-step-number {
    display: block;
    color: #ffffff;
    font-weight: 700;
    font-size: 14px;
}

.adsm-timeline-item.current .adsm-check-icon {
    display: none;
}

.adsm-timeline-item.current .adsm-timeline-status {
    color: #e45a02;
    font-weight: 700;
}

.adsm-timeline-item.current .adsm-timeline-description {
    color: #374151;
    font-weight: 500;
}

/* Timeline Line */
.adsm-timeline-line {
    width: 3px;
    height: 100%;
    background: #e5e7eb;
    position: absolute;
    top: 40px;
    transform: translateX(-50%);
    transition: background 0.3s ease;
}

/* Timeline Content */
.adsm-timeline-content {
    flex: 1;
    padding-top: 8px;
}

.adsm-timeline-status {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 6px 0;
    color: #111827;
}

.adsm-timeline-description {
    font-size: 13px;
    color: #6b7280;
    margin: 0;
    line-height: 1.5;
}

/* View Tracking Button */
.adsm-btn-view-tracking {
    background: #e45a02;
    color: #fff;
    padding: 8px 10px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.adsm-btn-view-tracking:hover {
    background: #ff7a00;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(228, 90, 2, 0.3);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .adsm-tracking-modal-content {
        width: 95%;
        padding: 24px 20px;
        max-height: 84vh;
    }

    .adsm-tracking-modal-title {
        font-size: 20px;
    }

    .adsm-timeline-item {
        gap: 16px;
    }

    .adsm-timeline-icon {
        width: 36px;
        height: 36px;
    }

    .adsm-timeline-status {
        font-size: 15px;
    }

    .adsm-timeline-description {
        font-size: 12px;
    }

    .adsm-tracking-info {
        padding: 12px;
    }
}