/* MTS Premium UI System
 * Shared visual layer for PTM public, client, provider, driver and admin surfaces.
 * Runtime behavior remains owned by the existing templates and scripts.
 */
:root {
    --mts-ui-navy: #06182e;
    --mts-ui-navy-soft: #0f3555;
    --mts-ui-ink: #172b3d;
    --mts-ui-muted: #697886;
    --mts-ui-gold: #d19a36;
    --mts-ui-gold-soft: #ebc878;
    --mts-ui-white: #ffffff;
    --mts-ui-ivory: #f8f7f4;
    --mts-ui-border: #dfe5e9;
    --mts-ui-success: #27745b;
    --mts-ui-warning: #a16a1c;
    --mts-ui-danger: #a34040;
    --mts-ui-info: #2e678d;
    --mts-ui-radius: 10px;
    --mts-ui-radius-sm: 6px;
    --mts-ui-shadow: 0 14px 34px rgba(6, 24, 46, .10);
    --mts-ui-shadow-strong: 0 24px 60px rgba(6, 24, 46, .16);
    --mts-ui-focus: 0 0 0 3px rgba(235, 200, 120, .38);
    --mts-ui-font: "Lato", "Segoe UI", Arial, sans-serif;
    --mts-ui-font-arabic: "Noto Sans Arabic", "Segoe UI", Arial, sans-serif;
    --mts-ui-display: clamp(2rem, 4vw, 2.5rem);
    --mts-ui-heading: clamp(1.5rem, 3vw, 2rem);
    --mts-ui-title: 1.25rem;
    --mts-ui-body: 1rem;
    --mts-ui-label: .8125rem;
    --mts-ui-meta: .75rem;
    --mts-ui-leading: 1.58;
    --mts-ui-measure: 68ch;
    --mts-ui-ease: cubic-bezier(.16, 1, .3, 1);
    --mts-ui-motion-fast: 140ms var(--mts-ui-ease);
    --mts-ui-motion: 220ms var(--mts-ui-ease);
}

/* Shared public page reading rhythm. The selector stays below the homepage layer. */
body:not(.home) .page-wrapper .entry-content,
body:not(.home) .content-area {
    color: var(--mts-ui-ink);
}

body:not(.home) .page-wrapper .entry-content h1,
body:not(.home) .page-wrapper .entry-content h2,
body:not(.home) .page-wrapper .entry-content h3,
body:not(.home) .page-wrapper .entry-content h4 {
    color: var(--mts-ui-navy);
    letter-spacing: 0;
}

body:not(.home) .page-wrapper .entry-content h1 {
    margin-bottom: 18px;
    font-weight: 800;
}

body:not(.home) .page-wrapper .entry-content h2 {
    margin-top: 36px;
    margin-bottom: 14px;
    font-weight: 800;
}

body:not(.home) .page-wrapper .entry-content a {
    color: var(--mts-ui-navy-soft);
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

body:not(.home) .page-wrapper .entry-content a:hover {
    color: var(--mts-ui-gold);
}

/* Public PTM shell and forms. */
body .ptm-booking-wrapper,
body #ptm-form-container,
body .ptm-form-container,
body .ptm-service-selector,
body .ptm-client-portal,
body .ptm-driver-portal,
body .ptm-company-provider-dashboard,
body .ptm-dashboard {
    color: var(--mts-ui-ink);
    font-family: inherit;
}

body .ptm-booking-wrapper,
body #ptm-form-container,
body .ptm-form-container {
    max-width: 980px !important;
    padding: clamp(18px, 3vw, 38px) !important;
    background: var(--mts-ui-ivory);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
    box-shadow: var(--mts-ui-shadow);
}

body .ptm-form-container .ptm-form,
body #ptm-form-container .ptm-form,
body .ptm-booking-wrapper .ptm-form {
    max-width: none !important;
}

body .ptm-service-selector {
    max-width: 1080px;
    margin: 0 auto 28px;
    padding: 18px 0;
}

body .ptm-service-selector h2,
body .ptm-form h2 {
    color: var(--mts-ui-navy);
    font-size: 38px;
    font-weight: 800;
    line-height: 1.14;
    letter-spacing: 0;
}

body .ptm-form h2 {
    text-align: start;
}

body .ptm-form-step h3 {
    margin: 28px 0 22px;
    padding-bottom: 12px;
    color: var(--mts-ui-navy);
    border-bottom: 1px solid var(--mts-ui-border);
    font-size: 20px;
    font-weight: 800;
}

body .ptm-form-group {
    margin-bottom: 18px;
}

body .ptm-form-group label {
    margin-bottom: 7px;
    color: var(--mts-ui-ink);
    font-size: 13px;
    font-weight: 800;
}

body .ptm-form-group input[type="text"],
body .ptm-form-group input[type="email"],
body .ptm-form-group input[type="tel"],
body .ptm-form-group input[type="number"],
body .ptm-form-group input[type="date"],
body .ptm-form-group input[type="time"],
body .ptm-form-group input[type="datetime-local"],
body .ptm-form-group select,
body .ptm-form-group textarea,
body .ptm-client-portal input,
body .ptm-client-portal select,
body .ptm-client-portal textarea {
    min-height: 46px;
    padding: 11px 13px;
    color: var(--mts-ui-ink);
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius-sm);
    box-shadow: none;
    transition: border-color var(--mts-ui-motion), box-shadow var(--mts-ui-motion), background-color var(--mts-ui-motion);
}

body .ptm-form-group textarea,
body .ptm-client-portal textarea {
    min-height: 116px;
    resize: vertical;
}

body .ptm-form-group input:focus,
body .ptm-form-group select:focus,
body .ptm-form-group textarea:focus,
body .ptm-client-portal input:focus,
body .ptm-client-portal select:focus,
body .ptm-client-portal textarea:focus {
    border-color: var(--mts-ui-gold);
    outline: 0;
    box-shadow: var(--mts-ui-focus);
}

body .ptm-form-group input:disabled,
body .ptm-form-group select:disabled,
body .ptm-form-group textarea:disabled,
body .ptm-btn:disabled,
body .ptm-client-portal button:disabled {
    cursor: not-allowed;
    opacity: .58;
}

body .ptm-form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 26px;
}

body .ptm-btn,
body .ptm-btn-primary,
body .ptm-btn-next,
body .ptm-btn-calculate,
body .ptm-btn-submit,
body .ptm-btn-quote,
body .ptm-btn-check-availability,
body .ptm-btn-select-vehicle,
body .ptm-btn-return,
body .ptm-btn-secondary,
body .ptm-client-portal button,
body .ptm-driver-portal button,
body .ptm-company-provider-dashboard button {
    min-height: 46px;
    padding: 12px 18px;
    color: var(--mts-ui-navy) !important;
    background: var(--mts-ui-gold) !important;
    border: 1px solid var(--mts-ui-gold) !important;
    border-radius: var(--mts-ui-radius-sm);
    box-shadow: 0 8px 18px rgba(185, 128, 37, .16);
    font-size: 14px;
    font-weight: 800;
    line-height: 1.2;
    text-transform: none;
    letter-spacing: 0;
    cursor: pointer;
    transition: background-color var(--mts-ui-motion), border-color var(--mts-ui-motion), color var(--mts-ui-motion), box-shadow var(--mts-ui-motion), transform var(--mts-ui-motion);
}

body .ptm-btn:hover,
body .ptm-btn:focus-visible,
body .ptm-btn-primary:hover,
body .ptm-btn-primary:focus-visible,
body .ptm-btn-next:hover,
body .ptm-btn-next:focus-visible,
body .ptm-btn-calculate:hover,
body .ptm-btn-calculate:focus-visible,
body .ptm-btn-submit:hover,
body .ptm-btn-submit:focus-visible,
body .ptm-btn-quote:hover,
body .ptm-btn-quote:focus-visible,
body .ptm-btn-check-availability:hover,
body .ptm-btn-check-availability:focus-visible,
body .ptm-btn-select-vehicle:hover,
body .ptm-btn-select-vehicle:focus-visible,
body .ptm-btn-return:hover,
body .ptm-btn-return:focus-visible,
body .ptm-client-portal button:hover,
body .ptm-client-portal button:focus-visible,
body .ptm-driver-portal button:hover,
body .ptm-driver-portal button:focus-visible,
body .ptm-company-provider-dashboard button:hover,
body .ptm-company-provider-dashboard button:focus-visible {
    color: var(--mts-ui-navy) !important;
    background: var(--mts-ui-gold-soft) !important;
    border-color: var(--mts-ui-gold-soft) !important;
    box-shadow: 0 11px 24px rgba(185, 128, 37, .22);
    transform: translateY(-1px);
}

body .ptm-btn-secondary,
body .ptm-btn-prev,
body .ptm-btn-return {
    color: var(--mts-ui-navy) !important;
    background: var(--mts-ui-white) !important;
    border-color: var(--mts-ui-border) !important;
    box-shadow: none;
}

body .ptm-btn-secondary:hover,
body .ptm-btn-secondary:focus-visible,
body .ptm-btn-prev:hover,
body .ptm-btn-prev:focus-visible,
body .ptm-btn-return:hover,
body .ptm-btn-return:focus-visible {
    color: var(--mts-ui-navy) !important;
    background: var(--mts-ui-ivory) !important;
    border-color: var(--mts-ui-gold) !important;
}

body .ptm-btn:focus-visible,
body .ptm-client-portal button:focus-visible,
body .ptm-driver-portal button:focus-visible,
body .ptm-company-provider-dashboard button:focus-visible,
body .ptm-form a:focus-visible,
body .ptm-service-card:focus-visible,
body .ptm-vehicle-option:focus-within,
body .ptm-client-portal a:focus-visible,
body .ptm-driver-portal a:focus-visible,
body .ptm-company-provider-dashboard a:focus-visible {
    outline: 3px solid var(--mts-ui-gold-soft);
    outline-offset: 3px;
}

/* Cards, options and offer states. */
body .ptm-service-grid,
body .ptm-vehicles-grid,
body .ptm-available-vehicles,
body .ptm-tour-vehicle-grid {
    gap: 14px;
}

body .ptm-service-card,
body .ptm-vehicle-card,
body .vehicle-card,
body .ptm-tour-vehicle-card-inner,
body .ptm-vehicle-option {
    color: var(--mts-ui-ink);
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
    box-shadow: 0 5px 16px rgba(6, 24, 46, .05);
    transition: border-color var(--mts-ui-motion), box-shadow var(--mts-ui-motion), transform var(--mts-ui-motion), background-color var(--mts-ui-motion);
}

body .ptm-service-card:hover,
body .ptm-vehicle-card:hover,
body .vehicle-card:hover,
body .ptm-tour-vehicle-card-inner:hover,
body .ptm-vehicle-option:hover {
    border-color: var(--mts-ui-gold);
    box-shadow: var(--mts-ui-shadow);
    transform: translateY(-2px);
}

body .ptm-service-card h3,
body .ptm-vehicle-name,
body .ptm-vehicle-card h3,
body .ptm-tour-vehicle-info strong,
body .ptm-vehicle-option strong {
    color: var(--mts-ui-navy);
    font-weight: 800;
}

body .ptm-service-card p,
body .ptm-vehicle-card p,
body .ptm-vehicle-option span,
body .ptm-inline-help,
body .ptm-rental-step-note {
    color: var(--mts-ui-muted);
}

body .ptm-price-display,
body .ptm-notice,
body .ptm-success-message,
body .ptm-error-message,
body .ptm-client-portal .ptm-notice,
body .ptm-driver-portal .ptm-notice {
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
    box-shadow: none;
}

body .ptm-price-display {
    background: #f5f8fa;
    border-color: #cbd9e2;
    border-top-color: var(--mts-ui-gold);
}

body .ptm-price-display h4,
body .price-amount,
body .total-price span {
    color: var(--mts-ui-navy);
}

body .price-amount {
    font-weight: 900;
}

body .ptm-success-message {
    color: #1d5d48;
    background: #edf7f1;
    border-color: #b9dfca;
}

body .ptm-error-message {
    color: #7f3030;
    background: #fff3f2;
    border-color: #e9bcbc;
}

body .ptm-notice-info {
    color: #234f6d;
    background: #eef6fb;
    border-color: #bfd9e9;
}

body .ptm-status-badge,
body .ptm-status-pill,
body .tier-badge-1,
body .tier-badge-2,
body .tier-badge-3 {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 4px 9px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    line-height: 1.1;
}

body .tier-badge-3 {
    color: #6b4b0c;
    background: #fbf4e5;
    border-color: #e6c26e;
}

body .tier-badge-2 {
    color: var(--mts-ui-navy);
    background: #eaf1f6;
    border-color: #bfd0dc;
}

body .tier-badge-1,
body .ptm-status-pill.is-muted {
    color: var(--mts-ui-muted);
    background: #f0f2f3;
    border-color: var(--mts-ui-border);
}

body .ptm-loading[aria-busy="true"],
body [aria-busy="true"] {
    cursor: progress;
}

/* Client, driver and provider surfaces: consistent operational hierarchy. */
body .ptm-client-portal,
body .ptm-driver-portal,
body .ptm-company-provider-dashboard,
body .ptm-dashboard {
    max-width: 1180px;
    margin: 0 auto;
    padding: clamp(18px, 3vw, 34px);
    background: var(--mts-ui-ivory);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
}

body .ptm-client-portal h1,
body .ptm-client-portal h2,
body .ptm-driver-portal h1,
body .ptm-driver-portal h2,
body .ptm-company-provider-dashboard h1,
body .ptm-company-provider-dashboard h2,
body .ptm-dashboard h1,
body .ptm-dashboard h2 {
    color: var(--mts-ui-navy);
    font-weight: 800;
}

body .ptm-client-portal > section,
body .ptm-driver-portal > section,
body .ptm-company-provider-dashboard > section,
body .ptm-dashboard > section,
body .ptm-client-portal .card,
body .ptm-driver-portal .card,
body .ptm-company-provider-dashboard .card,
body .ptm-dashboard .card {
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
    box-shadow: 0 5px 16px rgba(6, 24, 46, .05);
}

body .ptm-client-portal table,
body .ptm-driver-portal table,
body .ptm-company-provider-dashboard table,
body .ptm-dashboard table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius-sm);
}

body .ptm-client-portal th,
body .ptm-client-portal td,
body .ptm-driver-portal th,
body .ptm-driver-portal td,
body .ptm-company-provider-dashboard th,
body .ptm-company-provider-dashboard td,
body .ptm-dashboard th,
body .ptm-dashboard td {
    padding: 12px 14px;
    border-bottom: 1px solid var(--mts-ui-border);
    text-align: start;
    vertical-align: top;
}

body .ptm-client-portal th,
body .ptm-driver-portal th,
body .ptm-company-provider-dashboard th,
body .ptm-dashboard th {
    color: var(--mts-ui-navy);
    background: #f5f8fa;
    font-size: 12px;
    font-weight: 800;
}

body .ptm-client-portal tr:last-child td,
body .ptm-driver-portal tr:last-child td,
body .ptm-company-provider-dashboard tr:last-child td,
body .ptm-dashboard tr:last-child td {
    border-bottom: 0;
}

/* First-value guidance appears only when the current role has no work yet. */
body .ptm-onboarding-empty {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
    margin: 18px 0 24px;
    padding: 24px;
    color: var(--mts-ui-ink);
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
}

body .ptm-onboarding-mark {
    position: relative;
    display: block;
    width: 52px;
    height: 52px;
    border: 1px solid var(--mts-ui-gold);
    border-radius: 50%;
}

body .ptm-onboarding-mark::before,
body .ptm-onboarding-mark::after,
body .ptm-onboarding-mark > span {
    position: absolute;
    display: block;
    content: '';
    background: var(--mts-ui-gold);
}

body .ptm-onboarding-mark::before { top: 14px; left: 15px; width: 20px; height: 2px; transform: rotate(-32deg); }
body .ptm-onboarding-mark::after { right: 13px; bottom: 14px; width: 13px; height: 2px; transform: rotate(38deg); }
body .ptm-onboarding-mark > span { top: 11px; left: 12px; width: 7px; height: 7px; border-radius: 50%; box-shadow: 20px 10px 0 var(--mts-ui-gold), 28px 24px 0 var(--mts-ui-gold); }

body .ptm-onboarding-copy { max-width: 68ch; }
body .ptm-onboarding-copy > strong { display: block; margin: 1px 0 7px; color: var(--mts-ui-navy); font-size: 20px; line-height: 1.25; }
body .ptm-onboarding-copy > p { margin: 0; color: var(--mts-ui-muted); line-height: 1.65; }
body .ptm-onboarding-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 17px; }

body .ptm-onboarding-action,
#wpbody-content .wrap .ptm-onboarding-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 11px 17px;
    color: var(--mts-ui-navy);
    background: var(--mts-ui-gold-soft);
    border: 1px solid var(--mts-ui-gold);
    border-radius: var(--mts-ui-radius-sm);
    font: inherit;
    font-weight: 800;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color var(--mts-ui-motion), border-color var(--mts-ui-motion), transform var(--mts-ui-motion);
}

body .ptm-onboarding-action:hover,
body .ptm-onboarding-action:focus-visible,
#wpbody-content .wrap .ptm-onboarding-action:hover,
#wpbody-content .wrap .ptm-onboarding-action:focus-visible {
    color: var(--mts-ui-navy);
    background: var(--mts-ui-white);
    border-color: var(--mts-ui-navy-soft);
    transform: translateY(-1px);
}

body .ptm-onboarding-action:focus-visible,
#wpbody-content .wrap .ptm-onboarding-action:focus-visible {
    outline: 3px solid var(--mts-ui-gold-soft);
    outline-offset: 3px;
}

body .ptm-onboarding-progress {
    margin: 20px 0 30px;
    padding: 24px;
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
}

body .ptm-onboarding-progress > header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 20px;
}

body .ptm-onboarding-progress h3 { margin: 0 0 7px; color: var(--mts-ui-navy); font-size: 20px; }
body .ptm-onboarding-progress header p { max-width: 68ch; margin: 0; color: var(--mts-ui-muted); }
body .ptm-onboarding-progress header > strong { flex: 0 0 auto; color: var(--mts-ui-navy-soft); font-size: 13px; }
body .ptm-onboarding-progress ol { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--mts-ui-border); }
body .ptm-onboarding-progress li { display: flex; gap: 10px; min-width: 0; padding: 18px 14px 0 0; }
body .ptm-onboarding-progress li + li { padding-left: 14px; border-left: 1px solid var(--mts-ui-border); }
body .ptm-onboarding-step-mark { display: inline-flex; flex: 0 0 30px; align-items: center; justify-content: center; width: 30px; height: 30px; color: var(--mts-ui-muted); border: 1px solid var(--mts-ui-border); border-radius: 50%; font-size: 12px; font-weight: 900; }
body .ptm-onboarding-progress li.is-complete .ptm-onboarding-step-mark { color: var(--mts-ui-white); background: var(--mts-ui-success); border-color: var(--mts-ui-success); }
body .ptm-onboarding-progress li > span:last-child { min-width: 0; }
body .ptm-onboarding-progress li strong,
body .ptm-onboarding-progress li small { display: block; }
body .ptm-onboarding-progress li strong { color: var(--mts-ui-navy); font-size: 13px; line-height: 1.35; }
body .ptm-onboarding-progress li small { margin-top: 3px; color: var(--mts-ui-muted); font-size: 11px; }
html[dir="rtl"] body .ptm-onboarding-progress li { padding-right: 0; padding-left: 14px; }
html[dir="rtl"] body .ptm-onboarding-progress li + li { padding-right: 14px; border-right: 1px solid var(--mts-ui-border); border-left: 0; }

/* Admin surfaces. */
#wpbody-content .wrap {
    color: var(--mts-ui-ink);
}

#wpbody-content .wrap > h1,
#wpbody-content .wrap > h2 {
    color: var(--mts-ui-navy);
    font-weight: 800;
    letter-spacing: 0;
}

#wpbody-content .wrap > h1 {
    margin-bottom: 20px;
}

#wpbody-content .wrap .form-table,
#wpbody-content .wrap .widefat,
#wpbody-content .wrap .wp-list-table,
#wpbody-content .wrap .ptm-admin-card,
#wpbody-content .wrap .ptm-dashboard-card {
    border-color: var(--mts-ui-border);
    border-radius: var(--mts-ui-radius-sm);
    box-shadow: 0 5px 16px rgba(6, 24, 46, .05);
}

#wpbody-content .wrap .widefat,
#wpbody-content .wrap .wp-list-table {
    border-collapse: separate;
    border-spacing: 0;
    overflow: hidden;
}

#wpbody-content .wrap .widefat th,
#wpbody-content .wrap .wp-list-table th {
    color: var(--mts-ui-navy);
    background: #f5f8fa;
    font-weight: 800;
}

#wpbody-content .wrap .widefat td,
#wpbody-content .wrap .widefat th,
#wpbody-content .wrap .wp-list-table td,
#wpbody-content .wrap .wp-list-table th {
    padding: 11px 12px;
    border-bottom-color: var(--mts-ui-border);
}

#wpbody-content .wrap input[type="text"],
#wpbody-content .wrap input[type="email"],
#wpbody-content .wrap input[type="number"],
#wpbody-content .wrap input[type="url"],
#wpbody-content .wrap input[type="date"],
#wpbody-content .wrap input[type="time"],
#wpbody-content .wrap select,
#wpbody-content .wrap textarea {
    min-height: 40px;
    border-color: var(--mts-ui-border);
    border-radius: var(--mts-ui-radius-sm);
    box-shadow: none;
}

#wpbody-content .wrap input:focus,
#wpbody-content .wrap select:focus,
#wpbody-content .wrap textarea:focus {
    border-color: var(--mts-ui-gold);
    box-shadow: var(--mts-ui-focus);
}

#wpbody-content .wrap .button,
#wpbody-content .wrap .button-primary {
    min-height: 38px;
    padding: 8px 14px;
    color: var(--mts-ui-navy);
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius-sm);
    box-shadow: none;
    font-weight: 800;
    line-height: 1.3;
}

#wpbody-content .wrap .button-primary {
    color: var(--mts-ui-navy);
    background: var(--mts-ui-gold);
    border-color: var(--mts-ui-gold);
}

#wpbody-content .wrap .button:hover,
#wpbody-content .wrap .button:focus-visible,
#wpbody-content .wrap .button-primary:hover,
#wpbody-content .wrap .button-primary:focus-visible {
    color: var(--mts-ui-navy);
    background: var(--mts-ui-gold-soft);
    border-color: var(--mts-ui-gold-soft);
}

#wpbody-content .wrap .button:focus-visible,
#wpbody-content .wrap .button-primary:focus-visible {
    outline: 3px solid var(--mts-ui-gold-soft);
    outline-offset: 2px;
}

.ptm-admin-card,
.ptm-dashboard-card {
    padding: 20px;
    background: var(--mts-ui-white);
}

.ptm-admin-grid,
.ptm-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.ptm-admin-card h2,
.ptm-admin-card h3,
.ptm-dashboard-card h2,
.ptm-dashboard-card h3 {
    margin-top: 0;
    color: var(--mts-ui-navy);
    font-weight: 800;
}

/* Mobile keeps operational actions visible and turns wide data into safe scrolling. */
@media (max-width: 900px) {
    .ptm-admin-grid,
    .ptm-dashboard-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    body .ptm-client-portal table,
    body .ptm-driver-portal table,
    body .ptm-company-provider-dashboard table,
    body .ptm-dashboard table,
    #wpbody-content .wrap .widefat,
    #wpbody-content .wrap .wp-list-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
}

@media (max-width: 640px) {
    body .ptm-service-selector h2,
    body .ptm-form h2 {
        font-size: 26px;
    }

    body .ptm-booking-wrapper,
    body #ptm-form-container,
    body .ptm-form-container,
    body .ptm-client-portal,
    body .ptm-driver-portal,
    body .ptm-company-provider-dashboard,
    body .ptm-dashboard {
        padding: 16px !important;
        border-radius: var(--mts-ui-radius-sm);
    }

    body .ptm-form-actions {
        align-items: stretch;
        flex-direction: column;
    }

    body .ptm-form-actions .ptm-btn,
    body .ptm-form-actions button,
    body .ptm-client-portal button,
    body .ptm-driver-portal button,
    body .ptm-company-provider-dashboard button {
        width: 100%;
    }

    .ptm-admin-grid,
    .ptm-dashboard-grid {
        grid-template-columns: 1fr;
    }

    body .ptm-onboarding-empty {
        grid-template-columns: 40px minmax(0, 1fr);
        gap: 13px;
        padding: 18px;
    }

    body .ptm-onboarding-mark { width: 40px; height: 40px; }
    body .ptm-onboarding-mark::before { top: 11px; left: 11px; width: 16px; }
    body .ptm-onboarding-mark::after { right: 9px; bottom: 10px; width: 11px; }
    body .ptm-onboarding-mark > span { top: 8px; left: 8px; box-shadow: 16px 8px 0 var(--mts-ui-gold), 22px 19px 0 var(--mts-ui-gold); }
    body .ptm-onboarding-copy > strong { font-size: 18px; }
    body .ptm-onboarding-action { width: 100%; }
    body .ptm-onboarding-progress { padding: 18px; }
    body .ptm-onboarding-progress > header { flex-direction: column; gap: 8px; }
    body .ptm-onboarding-progress ol { grid-template-columns: 1fr; }
    body .ptm-onboarding-progress li,
    html[dir="rtl"] body .ptm-onboarding-progress li { padding: 14px 0; border-bottom: 1px solid var(--mts-ui-border); }
    body .ptm-onboarding-progress li + li,
    html[dir="rtl"] body .ptm-onboarding-progress li + li { padding-right: 0; padding-left: 0; border-right: 0; border-left: 0; }
    body .ptm-onboarding-progress li:last-child { border-bottom: 0; }

    body .ptm-client-portal table,
    body .ptm-driver-portal table,
    body .ptm-company-provider-dashboard table,
    body .ptm-dashboard table {
        font-size: 13px;
    }
}

html[dir="rtl"] body .ptm-form-group input[type="date"],
html[dir="rtl"] body .ptm-form-group input[type="time"] {
    background-position: left 12px center;
    padding-right: 13px;
    padding-left: 40px;
}

html[dir="rtl"] body .ptm-price-display { border-color: #cbd9e2; border-top-color: var(--mts-ui-gold); }

/* Keep authenticated dashboard pages from inheriting off-canvas theme navigation width. */
html:has(.ptm-customer-dashboard),
html:has(.ptm-provider-dashboard),
html:has(.ptm-driver-interface),
html:has(.ptm-customer-dashboard) body,
html:has(.ptm-provider-dashboard) body,
html:has(.ptm-driver-interface) body {
    overflow-x: clip;
}

html:has(.ptm-customer-dashboard) body > a.skip-link.screen-reader-text:not(:focus),
html:has(.ptm-provider-dashboard) body > a.skip-link.screen-reader-text:not(:focus),
html:has(.ptm-driver-interface) body > a.skip-link.screen-reader-text:not(:focus) {
    left: 0;
    margin: 0;
    top: -10000px;
}

/* Impeccable final system pass: shared form and role-dashboard language. */
body :where(
    .ptm-booking-wrapper,
    .ptm-configurable-form-wrap,
    .ptm-client-portal,
    .ptm-driver-portal,
    .ptm-customer-dashboard,
    .ptm-provider-dashboard,
    .ptm-driver-interface,
    .ptm-company-provider-dashboard,
    .ptm-dashboard
) {
    font-family: var(--mts-ui-font);
    font-size: var(--mts-ui-body);
    line-height: var(--mts-ui-leading);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

html[dir="rtl"] body :where(
    .ptm-booking-wrapper,
    .ptm-configurable-form-wrap,
    .ptm-client-portal,
    .ptm-driver-portal,
    .ptm-customer-dashboard,
    .ptm-provider-dashboard,
    .ptm-driver-interface,
    .ptm-company-provider-dashboard,
    .ptm-dashboard
) { font-family: var(--mts-ui-font-arabic); }

body :where(.ptm-configurable-form-wrap, .ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) {
    width: min(1180px, calc(100% - 32px));
    max-width: 1180px;
    margin: 28px auto;
    color: var(--mts-ui-ink);
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) {
    padding: clamp(18px, 3vw, 32px);
    background: var(--mts-ui-ivory);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
}

body.woocommerce-account .woocommerce-MyAccount-content .ptm-customer-dashboard {
    width: 100%;
    max-width: none;
    margin: 0;
}

body.woocommerce-account .woocommerce-MyAccount-content .ptm-customer-dashboard > header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
}

body.woocommerce-account .woocommerce-MyAccount-content .ptm-customer-dashboard > header p {
    margin: 0;
    color: var(--mts-ui-muted);
    font-weight: 700;
}

/* Customer trip workspace: quiet hierarchy, route-first details, one card level. */
body.woocommerce-account .woocommerce-MyAccount-content .ptm-customer-dashboard {
    padding: clamp(22px, 4vw, 42px);
    background: #f8f7f4;
    border-color: #dfe5e9;
    border-radius: 12px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__header {
    align-items: flex-start;
    margin-bottom: 30px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--mts-ui-border);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__header h2 {
    margin: 0 0 8px;
    font-size: clamp(1.7rem, 3vw, 2.25rem);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__header > div > p {
    max-width: 58ch;
    color: var(--mts-ui-muted);
    font-weight: 400;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__welcome {
    display: grid;
    flex: 0 0 auto;
    gap: 2px;
    min-width: 150px;
    padding: 10px 0;
    text-align: end;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__welcome span {
    color: var(--mts-ui-muted);
    font-size: var(--mts-ui-label);
    font-weight: 700;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__welcome strong {
    color: var(--mts-ui-navy);
    font-size: 1rem;
}

body.woocommerce-account .ptm-customer-dashboard > .ptm-customer-bookings {
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking {
    margin: 0 0 18px;
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--mts-ui-border);
    border-radius: 12px;
    box-shadow: 0 10px 26px rgba(6, 24, 46, .08);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 20px 22px 18px;
    background: var(--mts-ui-navy);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__header h4 {
    margin: 0 0 5px;
    color: var(--mts-ui-white);
    font-size: 1.2rem;
    line-height: 1.25;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__reference {
    margin: 0;
    color: #d2dde6;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .02em;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__status {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 10px;
    color: #d8ecff;
    background: #173d5f;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 800;
    line-height: 1.2;
    text-align: center;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__status.is-success { color: #dff6ea; background: #185542; }
body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__status.is-warning { color: #fff0c9; background: #684a16; }
body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__status.is-error { color: #ffe6e6; background: #6e2929; }

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__content {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(220px, .8fr);
    gap: clamp(24px, 4vw, 48px);
    padding: 24px 22px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__route {
    position: relative;
    display: grid;
    gap: 20px;
    padding-inline-start: 30px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__route::before {
    position: absolute;
    inset-block: 13px;
    inset-inline-start: 8px;
    width: 1px;
    background: #bac8d2;
    content: "";
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__stop {
    position: relative;
    display: grid;
    gap: 3px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__stop::before {
    position: absolute;
    top: 7px;
    inset-inline-start: -27px;
    width: 11px;
    height: 11px;
    background: var(--mts-ui-white);
    border: 3px solid var(--mts-ui-gold);
    border-radius: 50%;
    content: "";
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__stop.is-destination::before {
    background: var(--mts-ui-navy);
    border-color: var(--mts-ui-navy);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__stop span,
body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__facts dt {
    color: var(--mts-ui-muted);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__stop strong {
    color: var(--mts-ui-ink);
    font-size: .98rem;
    line-height: 1.4;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__route-pending {
    margin: 0;
    color: var(--mts-ui-muted);
    font-weight: 400;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__facts {
    display: grid;
    grid-template-columns: 1fr;
    align-content: start;
    gap: 18px;
    margin: 0;
    padding-inline-start: 24px;
    border-inline-start: 1px solid var(--mts-ui-border);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__facts > div {
    display: grid;
    gap: 4px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__facts dd {
    margin: 0;
    color: var(--mts-ui-navy);
    font-size: .96rem;
    font-weight: 800;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-payment-notice {
    margin: 0 0 18px;
    padding: 13px 16px;
    color: var(--mts-ui-ink);
    background: #f5f8fa;
    border: 1px solid var(--mts-ui-border);
    border-radius: 8px;
    font-size: .9rem;
    line-height: 1.5;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-payment-notice.is-success {
    color: #185542;
    background: #edf7f2;
    border-color: #b7dcca;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-payment-notice.is-error {
    color: #7a2828;
    background: #fff4f4;
    border-color: #e6bcbc;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 22px;
    border-top: 1px solid #d8e2eb;
    background: #fff9ea;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer > div {
    display: grid;
    gap: 3px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer strong {
    color: #071d36;
    font-size: 17px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer span {
    color: #52677a;
    font-size: 14px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

body.woocommerce-account .ptm-customer-dashboard :is(.ptm-customer-booking__offer-accept, .ptm-customer-booking__offer-decline) {
    min-height: 44px;
    margin: 0;
    padding: 0 18px;
    border-radius: 8px;
    font-weight: 700;
    line-height: 1;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer-accept {
    border: 1px solid #071d36;
    color: #fff;
    background: #071d36;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer-decline {
    border: 1px solid #b8c5d1;
    color: #243b50;
    background: #fff;
}

body.woocommerce-account .ptm-customer-dashboard :is(.ptm-customer-booking__offer-accept, .ptm-customer-booking__offer-decline):focus-visible {
    outline: 3px solid rgba(212, 161, 48, .4);
    outline-offset: 2px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 22px;
    background: #f8f7f4;
    border-top: 1px solid var(--mts-ui-border);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment > div {
    display: grid;
    min-width: 0;
    gap: 3px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment strong {
    color: var(--mts-ui-navy);
    font-size: .95rem;
    line-height: 1.3;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment span {
    color: var(--mts-ui-muted);
    font-size: .82rem;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment-form {
    flex: 0 0 auto;
    margin: 0;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__pay-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 46px;
    margin: 0;
    padding: 11px 16px;
    color: var(--mts-ui-navy);
    background: var(--mts-ui-gold);
    border: 1px solid var(--mts-ui-gold);
    border-radius: 6px;
    font-size: .82rem;
    font-weight: 800;
    line-height: 1.2;
    white-space: normal;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__pay-button:hover {
    color: var(--mts-ui-navy);
    background: var(--mts-ui-gold-soft);
    border-color: var(--mts-ui-gold-soft);
    transform: translateY(-1px);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__pay-button:focus-visible {
    outline: 3px solid rgba(235, 200, 120, .55);
    outline-offset: 3px;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__pay-button span,
body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__pay-button bdi {
    color: inherit;
    font-size: inherit;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment.is-paid {
    background: #edf7f2;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment.is-paid strong,
body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment.is-paid .ptm-customer-booking__payment-mark {
    color: #185542;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment-mark {
    flex: 0 0 auto;
    padding: 5px 9px;
    background: #dcefe5;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 800;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline {
    border-top: 1px solid var(--mts-ui-border);
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline summary {
    position: relative;
    padding: 15px 48px 15px 22px;
    color: var(--mts-ui-navy);
    font-size: .86rem;
    font-weight: 800;
    cursor: pointer;
    list-style: none;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline summary::-webkit-details-marker { display: none; }

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline summary::after {
    position: absolute;
    top: 50%;
    right: 23px;
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    content: "";
    transform: translateY(-65%) rotate(45deg);
    transition: transform var(--mts-ui-motion-fast);
}

html[dir="rtl"] body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline summary { padding-right: 22px; padding-left: 48px; }
html[dir="rtl"] body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline summary::after { right: auto; left: 23px; }
body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline[open] summary::after { transform: translateY(-35%) rotate(225deg); }

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline ol {
    display: grid;
    gap: 13px;
    margin: 0;
    padding: 0 22px 20px;
    list-style: none;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline li {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding-inline-start: 18px;
    color: var(--mts-ui-ink);
    font-size: .84rem;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline li::before {
    position: absolute;
    width: 8px;
    height: 8px;
    margin-top: 6px;
    margin-inline-start: -18px;
    background: var(--mts-ui-success);
    border-radius: 50%;
    content: "";
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline time {
    flex: 0 0 auto;
    color: var(--mts-ui-muted);
    font-variant-numeric: tabular-nums;
}

body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline summary:focus-visible {
    outline: 3px solid rgba(235, 200, 120, .55);
    outline-offset: -3px;
}

@media (max-width: 640px) {
    body.woocommerce-account .woocommerce-MyAccount-content .ptm-customer-dashboard > header {
        display: block;
    }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment {
        align-items: stretch;
        flex-direction: column;
        gap: 14px;
        padding: 18px;
    }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer {
        align-items: stretch;
        flex-direction: column;
    }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__offer-actions,
    body.woocommerce-account .ptm-customer-dashboard :is(.ptm-customer-booking__offer-accept, .ptm-customer-booking__offer-decline) {
        width: 100%;
    }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment-form,
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__pay-button {
        width: 100%;
    }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__payment.is-paid {
        align-items: flex-start;
        flex-direction: row;
    }
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) > :is(header, h2) {
    margin-block: 0 24px;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) h2 {
    color: var(--mts-ui-navy);
    font-size: var(--mts-ui-heading);
    font-weight: 800;
    line-height: 1.16;
    letter-spacing: -.02em;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) h3 {
    margin-block: 28px 14px;
    color: var(--mts-ui-navy);
    font-size: var(--mts-ui-title);
    font-weight: 800;
    line-height: 1.25;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) :is(p, li, dd) {
    overflow-wrap: anywhere;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) > section,
body .ptm-provider-dashboard > article,
body .ptm-driver-summary,
body .ptm-driver-boundaries {
    margin-block: 16px;
    padding: clamp(16px, 2.4vw, 24px);
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
}

body :where(.ptm-customer-booking, .ptm-driver-offer, .ptm-driver-job) {
    margin-block: 12px;
    padding: 18px;
    background: var(--mts-ui-white);
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius);
    box-shadow: 0 5px 16px rgba(6, 24, 46, .05);
    transition: border-color var(--mts-ui-motion), box-shadow var(--mts-ui-motion), transform var(--mts-ui-motion);
}

body .ptm-provider-booking {
    margin-top: 12px;
    padding: 14px 0 0;
    border-top: 1px solid var(--mts-ui-border);
}

@media (hover: hover) and (pointer: fine) {
    body :where(.ptm-customer-booking, .ptm-driver-offer, .ptm-driver-job):hover {
        border-color: #cfb374;
        box-shadow: var(--mts-ui-shadow);
        transform: translateY(-2px);
    }
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) :is(h4, h5) {
    margin-block: 0 10px;
    color: var(--mts-ui-navy);
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.35;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) dl {
    display: grid;
    grid-template-columns: minmax(130px, .42fr) minmax(0, 1fr);
    gap: 8px 18px;
    margin: 0;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) dt {
    color: var(--mts-ui-muted);
    font-size: var(--mts-ui-label);
    font-weight: 700;
}

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) dd {
    margin: 0;
    color: var(--mts-ui-ink);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

body .ptm-driver-interface form {
    display: inline-flex;
    margin: 10px 8px 0 0;
}

html[dir="rtl"] body .ptm-driver-interface form { margin-right: 0; margin-left: 8px; }

body .ptm-driver-interface button,
body .ptm-customer-dashboard button,
body .ptm-provider-dashboard button {
    min-width: 112px;
    min-height: 46px;
    padding: 11px 17px;
    color: var(--mts-ui-navy);
    background: var(--mts-ui-gold);
    border: 1px solid var(--mts-ui-gold);
    border-radius: var(--mts-ui-radius-sm);
    font: inherit;
    font-size: var(--mts-ui-label);
    font-weight: 800;
    cursor: pointer;
    transition: transform var(--mts-ui-motion-fast), background-color var(--mts-ui-motion-fast), border-color var(--mts-ui-motion-fast);
}

body .ptm-driver-interface button:active,
body .ptm-customer-dashboard button:active,
body .ptm-provider-dashboard button:active { transform: scale(.985); }

body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) [data-ptm-state="empty"] {
    max-width: var(--mts-ui-measure);
    margin: 14px 0;
    padding: 16px;
    color: var(--mts-ui-muted);
    background: #f5f8fa;
    border: 1px dashed #bdcbd5;
    border-radius: var(--mts-ui-radius-sm);
}

body .ptm-configurable-form-wrap { font-size: var(--mts-ui-body); }

body .ptm-configurable-form {
    padding: clamp(18px, 3vw, 30px) !important;
    background: var(--mts-ui-white) !important;
    border: 1px solid var(--mts-ui-border) !important;
    border-radius: var(--mts-ui-radius);
    box-shadow: var(--mts-ui-shadow);
}

body .ptm-configurable-form > h2 {
    max-width: 22ch;
    margin: 0 0 8px;
    color: var(--mts-ui-navy);
    font-size: var(--mts-ui-heading);
    font-weight: 800;
    line-height: 1.16;
    letter-spacing: -.02em;
    text-wrap: balance;
}

body .ptm-configurable-form > p {
    max-width: var(--mts-ui-measure);
    color: var(--mts-ui-muted);
    line-height: var(--mts-ui-leading);
}

body .ptm-form-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 18px 20px !important;
    margin-top: 24px;
}

body .ptm-config-field { min-width: 0; gap: 7px !important; }

body .ptm-config-field > label,
body .ptm-config-field > legend {
    color: var(--mts-ui-ink);
    font-size: var(--mts-ui-label);
    font-weight: 800;
    line-height: 1.35;
}

body .ptm-config-field :is(input:not([type="radio"]):not([type="checkbox"]), select, textarea) {
    width: 100%;
    max-width: 100%;
    min-height: 48px;
    padding: 11px 13px !important;
    color: var(--mts-ui-ink);
    background: var(--mts-ui-white);
    border: 1px solid #c8d3db !important;
    border-radius: var(--mts-ui-radius-sm);
    box-shadow: none;
    font: inherit;
    font-size: var(--mts-ui-body);
    line-height: 1.35;
    transition: border-color var(--mts-ui-motion-fast), box-shadow var(--mts-ui-motion-fast), background-color var(--mts-ui-motion-fast);
}

body .ptm-config-field select[multiple] { min-height: 132px; padding-block: 7px !important; }
body .ptm-config-field textarea { min-height: 120px; resize: vertical; }

body .ptm-config-field :is(input, select, textarea):focus-visible {
    outline: 0;
    border-color: var(--mts-ui-gold) !important;
    box-shadow: var(--mts-ui-focus);
}

body .ptm-config-field small {
    max-width: var(--mts-ui-measure);
    color: var(--mts-ui-muted) !important;
    font-size: var(--mts-ui-label);
    line-height: 1.5;
}

body .ptm-option-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    min-width: 0;
}

body .ptm-inline-option {
    flex: 1 1 190px;
    min-height: 46px;
    margin: 0 !important;
    padding: 9px 12px;
    color: var(--mts-ui-ink);
    background: #f8fafb;
    border: 1px solid var(--mts-ui-border);
    border-radius: var(--mts-ui-radius-sm);
    font-size: var(--mts-ui-label);
    font-weight: 700;
    line-height: 1.35;
    cursor: pointer;
    transition: border-color var(--mts-ui-motion-fast), background-color var(--mts-ui-motion-fast), transform var(--mts-ui-motion-fast);
}

body .ptm-inline-option:has(input:checked) {
    background: #fff8e8;
    border-color: var(--mts-ui-gold);
}

body .ptm-inline-option:active { transform: scale(.99); }

body .ptm-inline-option input { width: 20px !important; height: 20px; accent-color: var(--mts-ui-gold); }

body .ptm-form-state {
    padding: 5px 9px;
    color: var(--mts-ui-navy);
    background: #fff8e8;
    border: 1px solid #e3c77f;
    border-radius: 999px;
    font-size: var(--mts-ui-meta);
    font-weight: 800;
}

body .ptm-form-success {
    position: relative;
    padding: 15px 18px 15px 46px;
    animation: ptmDispatchConfirm 360ms var(--mts-ui-ease) both;
}

body .ptm-form-success::before {
    position: absolute;
    top: 17px;
    left: 19px;
    width: 9px;
    height: 16px;
    border-right: 2px solid var(--mts-ui-success);
    border-bottom: 2px solid var(--mts-ui-success);
    content: "";
    transform: rotate(45deg);
}

html[dir="rtl"] body .ptm-form-success { padding-right: 46px; padding-left: 18px; }
html[dir="rtl"] body .ptm-form-success::before { right: 19px; left: auto; }

body .ptm-form-step.ptm-step-active { animation: ptmDispatchEnter 260ms var(--mts-ui-ease) both; }

body .ptm-loading[aria-busy="true"]::after {
    display: block;
    width: min(180px, 52vw);
    height: 2px;
    margin: 12px auto 0;
    background: linear-gradient(90deg, transparent 0 18%, var(--mts-ui-gold) 46% 54%, transparent 82% 100%);
    background-size: 220% 100%;
    content: "";
    animation: ptmDispatchRail 1s linear infinite;
}

@keyframes ptmDispatchEnter {
    from { opacity: .72; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes ptmDispatchConfirm {
    from { opacity: .78; box-shadow: 0 0 0 rgba(39, 116, 91, 0); }
    to { opacity: 1; box-shadow: 0 8px 22px rgba(39, 116, 91, .08); }
}

@keyframes ptmDispatchRail {
    from { background-position: 100% 0; }
    to { background-position: -120% 0; }
}

#wpbody-content .wrap :is(p, li, td) { line-height: 1.5; }
#wpbody-content .wrap .description { max-width: var(--mts-ui-measure); color: var(--mts-ui-muted); }
#wpbody-content .wrap :is(.widefat, .wp-list-table) { font-variant-numeric: tabular-nums; }

@media (max-width: 900px) {
    body .ptm-form-fields { grid-template-columns: 1fr !important; }
    body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) dl { grid-template-columns: 1fr; gap: 2px; }
    body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) dd { margin-bottom: 9px; }
}

@media (max-width: 640px) {
    body :where(.ptm-configurable-form-wrap, .ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) {
        width: min(100% - 16px, 1180px);
        margin-block: 8px 20px;
    }

    body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) {
        padding: 14px;
        border-radius: var(--mts-ui-radius-sm);
    }

    body :where(.ptm-customer-dashboard, .ptm-provider-dashboard, .ptm-driver-interface) > section,
    body .ptm-provider-dashboard > article,
    body .ptm-driver-summary,
    body .ptm-driver-boundaries,
    body :where(.ptm-customer-booking, .ptm-driver-offer, .ptm-driver-job) { padding: 15px; }

    body .ptm-inline-option { flex-basis: 100%; }
    body .ptm-driver-interface form { display: flex; width: 100%; margin: 8px 0 0; }
    body .ptm-driver-interface form button { width: 100%; }

    body.woocommerce-account .woocommerce-MyAccount-content .ptm-customer-dashboard { padding: 18px 14px; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__header { gap: 14px; margin-bottom: 20px; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-dashboard__welcome { min-width: 0; padding: 0; text-align: start; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__header { display: grid; padding: 18px; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__status { justify-self: start; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__content { grid-template-columns: 1fr; gap: 24px; padding: 20px 18px; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__facts { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-inline-start: 0; padding-top: 20px; border-inline-start: 0; border-top: 1px solid var(--mts-ui-border); }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline li { display: grid; gap: 2px; }
    body.woocommerce-account .ptm-customer-dashboard .ptm-customer-booking__timeline time { padding-inline-start: 0; }

    body.woocommerce-account .row.vertical-tabs > .large-3.col.col-border {
        padding-bottom: 8px;
        border: 0;
    }

    body.woocommerce-account .row.vertical-tabs > .large-3 .account-user { display: none; }

    body.woocommerce-account .row.vertical-tabs > .large-3 .account-nav {
        display: flex;
        flex-direction: row !important;
        gap: 8px;
        margin: 0 0 14px;
        padding: 0 0 8px;
        overflow-x: auto;
        border: 0;
        scrollbar-width: none;
    }

    body.woocommerce-account .row.vertical-tabs > .large-3 .account-nav::-webkit-scrollbar { display: none; }

    body.woocommerce-account .row.vertical-tabs > .large-3 .account-nav > li {
        flex: 0 0 auto;
        width: auto !important;
        border: 0;
    }

    body.woocommerce-account .row.vertical-tabs > .large-3 .account-nav > li > a {
        min-height: 44px;
        padding: 11px 14px;
        color: var(--mts-ui-navy);
        background: var(--mts-ui-white);
        border: 1px solid var(--mts-ui-border);
        border-radius: var(--mts-ui-radius-sm);
        line-height: 1.2;
    }

    body.woocommerce-account .row.vertical-tabs > .large-3 .account-nav > li.is-active > a {
        color: var(--mts-ui-navy);
        background: #fff8e8;
        border-color: var(--mts-ui-gold);
    }
}

@media (pointer: coarse) {
    body :where(.ptm-config-field input, .ptm-config-field select, .ptm-inline-option, .ptm-driver-interface button) { min-height: 48px; }
    #wpbody-content .wrap :is(.button, .button-primary, input, select) { min-height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
    body .ptm-form-step.ptm-step-active,
    body .ptm-form-success,
    body .ptm-loading[aria-busy="true"]::after { animation: none !important; }
    body .ptm-btn,
    body .ptm-service-card,
    body .ptm-vehicle-card,
    body .ptm-driver-offer,
    body .ptm-driver-job,
    body .ptm-customer-booking,
    body .ptm-provider-booking { transition: none !important; }
}
