@charset "utf-8";
/* PURCHASE PACKAGE - ADMIN CONSOLE STYLES
   (c) 2026 Andres Lazaro Perez Cardoso. All rights reserved. */

:root{--red:#c9141d;--red2:#a90e16;--blue:#0b4c7c;--navy:#18232d;--ink:#18232d;--muted:#65717c;--line:#cbd4dc;--bg:#e9edf1;--field:#f3f8fc}
*{box-sizing:border-box}
body{margin:0;background:var(--bg);font-family:Arial,Helvetica,sans-serif;color:var(--ink);min-height:100vh;display:flex;flex-direction:column}

/* Header */
.header{background:var(--navy);color:#fff;padding:14px 20px;position:sticky;top:0;z-index:100;box-shadow:0 2px 10px #0004}
.header-inner{max-width:1680px;margin:auto;display:flex;align-items:center;justify-content:space-between;gap:18px}
.logo{font-size:24px;font-weight:900}.logo span{color:#e21a23}
.subtitle{font-size:11px;opacity:.8;margin-top:2px;letter-spacing:1px}
.toolbar{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.user-chip{background:#ffffff22;border:1px solid #ffffff44;border-radius:99px;padding:7px 13px;font-size:12px;font-weight:800}
.logout-btn{background:#ffffff22;border:1px solid #ffffff44;color:#fff;border-radius:99px;padding:7px 14px;font-size:12px;font-weight:800;display:inline-flex;align-items:center;gap:7px}
.logout-btn:hover{background:#ffffff38}

/* Buttons */
button{font:inherit;font-weight:700;border:0;border-radius:6px;padding:9px 13px;cursor:pointer}
.btn-red{background:var(--red);color:#fff}.btn-red:hover{background:var(--red2)}
.btn-blue{background:var(--blue);color:#fff}
.btn-light{background:#eef2f5;color:var(--ink)}
.btn-block{width:100%;margin-top:12px;height:44px;font-size:15px}
.btn-sm{padding:6px 10px;font-size:12px;margin-right:5px}

/* Status */
.status{max-width:1680px;margin:12px auto 0;padding:10px 14px;border-radius:6px;background:#eaf7eb;color:#216b28;display:none;width:100%}
.status.error{background:#fff0f0;color:#9b1d25}

/* Login */
.login-wrap{flex:1;display:flex;align-items:center;justify-content:center;padding:40px 16px}
.login-card{background:#fff;border-radius:12px;box-shadow:0 8px 30px #0002;padding:28px;max-width:400px;width:100%}
.login-card h1{margin:0 0 6px;font-size:22px}
.muted{color:var(--muted);font-size:13px;margin:0 0 16px;line-height:1.5}
.login-card label{font-size:11px;font-weight:800;color:#3e4b57;display:block;margin:12px 0 4px;text-transform:uppercase}
.error-msg{background:#fff0f0;color:#9b1d25;border:1px solid #f3c1c4;border-radius:6px;padding:10px 12px;font-size:13px;font-weight:700;margin-top:12px}
.fineprint{font-size:11px;color:var(--muted);margin:14px 0 0;line-height:1.5}

/* Layout */
.container{max-width:1680px;margin:12px auto 45px;padding:0 20px;width:100%;flex:1}
.nav{display:flex;gap:2px;flex-wrap:wrap;margin:6px 0 0;background:#fff;border:1px solid var(--line);border-radius:10px;box-shadow:0 2px 10px #18232d12;padding:0 10px}
.nav button{background:transparent;border:0;border-bottom:3px solid transparent;border-radius:0;color:#3e4b57;padding:12px 13px 9px;font-weight:600;font-size:15px}
.nav button:hover{color:var(--ink);background:#f7fafc}
.nav button.active{background:transparent;color:var(--ink);border-bottom-color:var(--red);font-weight:800}
.sheet{background:#fff;border-radius:10px;box-shadow:0 2px 14px #00000012;margin:14px 0 18px;overflow:hidden}
.sheet-header{padding:12px 16px;background:linear-gradient(90deg,var(--navy),#273541);color:#fff;display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap}
.sheet-header h2{margin:0;font-size:16px}
.header-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.inline-select{width:auto;height:36px;text-transform:none}
.inline-search{width:180px;height:36px;padding:0 10px;border:1px solid #d1d5db;border-radius:6px;font-size:14px;text-transform:none}
.section-body{padding:14px 16px}
.note{font-size:12px;color:var(--muted);line-height:1.55;margin:0 0 14px}
.field-note{font-size:11.5px;color:var(--muted);line-height:1.5;margin:2px 0 6px}

/* Tables */
.table-wrap{overflow-x:auto;scrollbar-width:thin;scrollbar-color:#ccd6de transparent}
.table-wrap::-webkit-scrollbar{height:6px;width:6px}
.table-wrap::-webkit-scrollbar-thumb{background:#ccd6de;border-radius:99px}
.table-wrap::-webkit-scrollbar-track{background:transparent}
.grid-table{width:100%;border-collapse:collapse;font-size:13px}
.grid-table th{text-align:left;font-size:11px;text-transform:uppercase;color:#3e4b57;background:#edf1f4;padding:9px 10px;border-bottom:2px solid var(--line);white-space:nowrap}
.grid-table td{padding:9px 10px;border-bottom:1px solid #e6ebef;vertical-align:middle}
.grid-table tr:hover td{background:#f7fafc}
.pill{display:inline-block;padding:3px 10px;border-radius:99px;font-size:11px;font-weight:800}
.pill.on{background:#e4f5e7;color:#1e6b2a}
.pill.off{background:#fbe4e5;color:#9b1d25}
.pill.admin{background:#e3eefb;color:#0b4c7c}
.pill.mgr{background:#efe7fb;color:#4b2a85}
.pill.sp{background:#e3eefb;color:#0b4c7c}
.pill.lead{background:#fdf0d7;color:#7a5210}
.pill.console{background:#e8edf2;color:#40536a}
.row-actions{white-space:nowrap;text-align:right}

/* Forms */
label{font-size:11px;font-weight:800;color:#3e4b57;display:block;margin:10px 0 4px;text-transform:uppercase}
input,select,textarea{width:100%;border:1px solid #bfcbd5;background:var(--field);border-radius:5px;padding:8px 9px;font-size:13px;color:#17212a}
select{appearance:none;-webkit-appearance:none;background-image:url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%235a6b7c' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 10px center;padding-right:28px}
input,select{height:36px}textarea{min-height:70px;resize:vertical;font-family:inherit}
input:focus,select:focus,textarea:focus{outline:2px solid #c7e0f3;border-color:#5a99c4;background:#fff}
input[type=checkbox]{width:auto;height:auto}
.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:0 14px;margin-bottom:14px}
.form-grid .span2{grid-column:1/-1}
.checkline{display:flex;align-items:flex-start;gap:9px;margin-top:14px;font-size:13.5px;font-weight:600;text-transform:none;letter-spacing:0;color:var(--ink)}
.perm-toggle-main{text-transform:none;letter-spacing:0}
.perm-toggle-main .note{font-size:12.5px}
.badge-opt{text-transform:none;letter-spacing:0}
input[type="checkbox"]{accent-color:var(--blue)}
.checkline input{width:18px;height:18px}
.checkline-inline{display:inline-flex;align-items:center;gap:7px;font-size:13px;font-weight:600;white-space:nowrap;cursor:pointer;color:#fff;text-transform:none}
.checkline-inline input{width:16px;height:16px;cursor:pointer}

/* Modal */
.modal-backdrop{position:fixed;inset:0;background:#0009;display:flex;align-items:center;justify-content:center;z-index:200;padding:16px}
.modal{background:#fff;border-radius:12px;max-width:560px;width:100%;max-height:92vh;display:flex;flex-direction:column;box-shadow:0 18px 60px #0006}
.modal-wide{max-width:720px}
.modal-xwide{max-width:1120px}
.badge-opts{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:8px;margin:4px 0 10px}
.badge-opt{border:1.5px solid var(--line);border-radius:10px;padding:8px;cursor:pointer;display:flex;flex-direction:column;gap:6px}
.badge-opt input{margin:0}
.badge-opt.sel{border-color:var(--blue);box-shadow:0 0 0 2px rgba(11,76,124,.22)}
.badge-opt-bar{background:#18232d;border-radius:6px;padding:10px;display:flex;justify-content:center}
.badge-opt-head{display:flex;align-items:center;gap:8px}
.badge-opt-head input{flex:none;width:16px;height:16px}
.badge-opt-bar .badge-chip{min-height:38px;padding:6px 14px}
.badge-opt-bar .badge-chip img{max-height:34px}
.badge-bar .badge-chip{min-height:46px;padding:8px 18px}
.badge-bar .badge-chip img{max-height:40px}
.badge-opt-label{font-weight:700;font-size:13px}
.badge-opt-desc{font-size:12px;color:#5a6672}
.badge-chip{display:inline-flex;align-items:center;justify-content:center;padding:6px 12px;min-height:30px;max-width:100%}
.badge-chip img{max-height:40px;max-width:190px;object-fit:contain}
.badge-chip-name{font-weight:700;font-size:12px;color:#18232d;white-space:nowrap}
.badge-classic{background:#fff;border-radius:2px}
.badge-silver{background:linear-gradient(180deg,#fff,#cbd3db);border-radius:12px}
.badge-fade{background:#fff;border-radius:16px;box-shadow:0 0 16px 8px rgba(255,255,255,.65)}
.badge-border{background:linear-gradient(180deg,#fff,#d6dce2);border-radius:12px;border:1.5px solid #8c96a0}
.badge-preview{margin-top:2px}
.badge-preview-title{font-weight:700;font-size:13px;margin-bottom:6px}
.badge-bar{background:#18232d;border-radius:8px;padding:16px;display:flex;justify-content:center}
.modal-head{display:flex;justify-content:space-between;align-items:center;padding:14px 18px;border-bottom:1px solid var(--line)}
.modal-head h3{margin:0;font-size:16px}
.modal-body{padding:6px 18px 26px;overflow-y:auto;flex:1 1 auto;min-height:0;scroll-padding:12px 0}
.modal-foot{display:flex;justify-content:flex-end;gap:8px;padding:14px 18px;border-top:1px solid var(--line)}
.dlg-backdrop{z-index:400}
.dlg-modal{max-width:440px}
.import-preview{margin-top:12px;font-size:12px;max-height:180px;overflow-y:auto;background:#f4f8fb;border:1px solid var(--line);border-radius:6px;padding:10px;display:none}

/* License */
.license-title{margin:22px 0 8px;font-size:14px}
.license-box{background:#f7fafc;border:1px solid var(--line);border-radius:8px;padding:16px;font-size:13px;line-height:1.7;white-space:pre-wrap}

/* Footer */
.footer{padding:16px;text-align:center;font-size:11px;color:#697681;background:#fff;border-top:1px solid var(--line)}

@media(max-width:800px){
  .header-inner{flex-direction:column;align-items:flex-start}
  .form-grid{grid-template-columns:1fr}
  .sheet-header{flex-direction:column;align-items:flex-start}
}

/* Loading spinner */
.spinner{width:36px;height:36px;border:3px solid rgba(255,255,255,.2);border-top-color:#fff;border-radius:50%;animation:spin .8s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}

/* Modal save button spinner */
.btn-spinner{display:inline-block;width:14px;height:14px;border:2px solid rgba(255,255,255,.35);border-top-color:#fff;border-radius:50%;animation:spin .7s linear infinite;vertical-align:-2px;margin-right:6px}
/* More prominent status toast */
.status{position:sticky;top:0;z-index:50;margin:0 0 12px;padding:12px 16px;border-radius:8px;font-size:14px;font-weight:600;box-shadow:0 2px 12px rgba(0,0,0,.18)}
.status:not(.error){background:#e6f4ea;color:#137333;border:1px solid #a3d9b1}
.status.error{background:#fce8e6;color:#a50e0e;border:1px solid #f5a39e}

/* Dashboard */
.dash-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(160px,1fr));gap:14px;margin-top:8px;padding:16px}
.dash-card{background:#f8fafc;border:1px solid #e2e8f0;border-radius:10px;padding:16px 12px;text-align:center;min-height:96px;display:flex;flex-direction:column;justify-content:center}
.dash-num{font-size:28px;font-weight:800;color:#1d5c8f;line-height:1.2}
.dash-label{font-size:12px;color:#64748b;margin-top:6px;font-weight:600}

/* Force light styling on password/PIN fields (fixes dark autofill rendering) */
input[type=password]{
  background:#fff !important;
  color:#1a1a1a !important;
  -webkit-text-fill-color:#1a1a1a !important;
  caret-color:#1a1a1a;
}
input[type=password]:-webkit-autofill,
input[type=password]:-webkit-autofill:hover,
input[type=password]:-webkit-autofill:focus{
  -webkit-box-shadow:0 0 0 1000px #fff inset !important;
  -webkit-text-fill-color:#1a1a1a !important;
  background:#fff !important;
}

/* Tab nav: keep on one line with horizontal scroll instead of awkward wrapping */
.nav{display:flex;flex-wrap:nowrap;overflow-x:auto;gap:2px;padding-bottom:0;-webkit-overflow-scrolling:touch;scrollbar-width:none}
.nav button{flex-shrink:0;white-space:nowrap}
.nav::-webkit-scrollbar{height:0;width:0;display:none}

/* Welcome banner: breathing room from tabs */
#status{margin:14px 0}

/* Prevent phone numbers from wrapping mid-value in the Banks table */
#banksTable td:nth-child(3){white-space:nowrap}

/* Dealership-style signing screen */
.dealership-signin {
  min-height: 70vh;
  background: #0a0e14 url('front_page_art.jpg') center/cover no-repeat;
  display: flex; align-items: center; justify-content: center;
  padding: 20px; position: relative;
  border-radius: 12px; overflow: hidden;
}
.dealership-signin::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(8,14,22,.72) 0%, rgba(8,14,22,.55) 50%, rgba(8,14,22,.78) 100%);
}
.dealership-signin-card {
  position: relative; z-index: 1; text-align: center;
  background: rgba(20,28,38,.82);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,.1);
  padding: 48px 60px; border-radius: 20px;
  box-shadow: 0 24px 70px rgba(0,0,0,.5);
  max-width: 420px; width: 100%;
}
.dealership-brand { font-size: 13px; font-weight: 800; letter-spacing: 3px; color: #fff; margin-bottom: 6px; }
.dealership-brand span { color: #d71920; }
.dealership-sub { font-size: 11px; letter-spacing: 2px; color: rgba(255,255,255,.5); text-transform: uppercase; margin-bottom: 26px; }
.dealership-dots { display: flex; gap: 10px; justify-content: center; margin: 0 auto 22px; }
.dealership-dots div {
  width: 14px; height: 14px; border-radius: 50%; background: #d71920;
  animation: dealership-bounce 1.2s ease-in-out infinite;
  box-shadow: 0 0 12px rgba(215,25,32,.6);
}
.dealership-dots div:nth-child(2) { animation-delay: .15s; }
.dealership-dots div:nth-child(3) { animation-delay: .3s; }
@keyframes dealership-bounce {
  0%,100% { transform: translateY(0); opacity: .5; }
  50% { transform: translateY(-12px); opacity: 1; }
}
.dealership-title { font-size: 22px; font-weight: 800; color: #fff; }
.dealership-note { font-size: 13px; color: rgba(255,255,255,.6); margin-top: 8px; }

/* Admin login matching purchase site front-gate style */
.admin-gate {
  min-height: 100vh;
  background: #0a0e14 url('front_page_art.jpg') center/cover no-repeat;
  display: flex; align-items: center; justify-content: center;
  padding: 24px; position: relative;
}
.admin-gate::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(8,14,22,.68) 0%, rgba(8,14,22,.5) 50%, rgba(8,14,22,.75) 100%);
}
.admin-gate-content { position: relative; z-index: 1; width: 100%; max-width: 520px; }
.admin-gate-copy { text-align: center; }
.admin-gate-title { font-size: 42px; font-weight: 900; color: #fff; line-height: 1.05; margin: 0 0 10px; letter-spacing: -1px; }
.admin-gate-title span { color: #d71920; }
.admin-gate-lead { font-size: 16px; color: rgba(255,255,255,.75); margin: 0 0 28px; }
.admin-form-card {
  background: rgba(255,255,255,.22);
  -webkit-backdrop-filter: blur(26px) saturate(1.4);
  backdrop-filter: blur(26px) saturate(1.4);
  border: 1px solid rgba(255,255,255,.35);
  border-radius: 16px; padding: 32px 30px;
  box-shadow: 0 18px 46px rgba(0,0,0,.4);
  text-align: left; color: #fff;
}
.admin-form-title { font-size: 22px; font-weight: 800; color: #fff; margin: 0 0 4px; text-shadow: 0 1px 8px rgba(0,0,0,.4); }
.admin-form-sub { font-size: 13px; color: rgba(255,255,255,.85); margin: 0 0 20px; }
.admin-form-card label { font-size: 11px; font-weight: 800; color: rgba(255,255,255,.92); display: block; margin: 14px 0 6px; text-transform: uppercase; text-shadow: 0 1px 6px rgba(0,0,0,.35); }
.admin-form-card input[type="text"],
.admin-form-card input[type="password"] {
  width: 100%; padding: 12px 14px; font-size: 15px;
  border: 1px solid rgba(255,255,255,.35); border-radius: 8px;
  background: rgba(255,255,255,.15); color: #fff; outline: none;
}
.admin-form-card input::placeholder { color: rgba(255,255,255,.6); }
.admin-form-card input:focus { border-color: #fff; box-shadow: 0 0 0 3px rgba(255,255,255,.15); background: rgba(255,255,255,.22); }
/* Override browser autofill white background */
.admin-form-card input:-webkit-autofill,
.admin-form-card input:-webkit-autofill:hover,
.admin-form-card input:-webkit-autofill:focus {
  -webkit-text-fill-color: #fff;
  -webkit-box-shadow: 0 0 0 1000px rgba(255,255,255,.15) inset;
  transition: background-color 5000s ease-in-out 0s;
}
/* Sign-in card: the PIN field must match the glassy username field —
   the global white password rule above would otherwise win on !important */
.admin-form-card input[type="password"] {
  background: rgba(255,255,255,.15) !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  caret-color: #fff;
}
.admin-form-card input[type="password"]:-webkit-autofill,
.admin-form-card input[type="password"]:-webkit-autofill:hover,
.admin-form-card input[type="password"]:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px rgba(255,255,255,.15) inset !important;
  -webkit-text-fill-color: #fff !important;
}
.admin-form-card .btn-block { width: 100%; margin-top: 18px; padding: 13px; font-size: 16px; }
.admin-form-card .fineprint { font-size: 11px; color: rgba(255,255,255,.7); text-align: center; margin-top: 14px; }
.admin-form-card .fineprint a { color: #7fb3e8; }
@media(max-width:600px){
  .admin-gate-title { font-size: 32px; }
  .admin-form-card { padding: 24px 20px; }
}

/* ---------- Website tab (super admin) ---------- */
#tab-website .form-grid textarea{width:100%;border:1px solid #c9d6e2;border-radius:7px;padding:10px 12px;font-size:14px;font-family:inherit;background:#fff;color:#17212a}
#tab-website .form-grid input{width:100%}
.ws-toggles{display:flex;flex-wrap:wrap;gap:10px 22px;margin:6px 0 4px}
.ws-toggles label{display:flex;align-items:center;gap:7px;font-size:14px;font-weight:600;cursor:pointer}
.ws-toggles input{width:16px;height:16px}
.ws-faq-row{display:flex;gap:10px;align-items:flex-start;margin-bottom:10px}
.ws-faq-row .ws-faq-q{flex:0 0 34%;border:1px solid #c9d6e2;border-radius:7px;padding:10px 12px;font-size:14px}
.ws-faq-row .ws-faq-a{flex:1;border:1px solid #c9d6e2;border-radius:7px;padding:10px 12px;font-size:14px;font-family:inherit}
.ws-faq-row .ws-faq-del{flex:0 0 auto}

/* ---------- Billing tab (super admin) ---------- */
.bill-stripe-bar{display:flex;align-items:center;gap:14px;border:1px solid #e2e9f0;border-radius:12px;padding:16px 18px;background:#fbfcfe;margin-bottom:20px;flex-wrap:wrap}
.bill-dot{width:11px;height:11px;border-radius:50%;background:#c9d6e2;flex:0 0 auto}
.bill-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:14px;margin-bottom:22px}
.bill-card{border:1px solid #e2e9f0;border-radius:12px;padding:16px;background:#fbfcfe}
.bill-n{font-size:28px;font-weight:800;color:#0f2a43}
.bill-l{font-size:11px;letter-spacing:1px;text-transform:uppercase;color:#5a6b7c;margin-top:2px}
.bill-card.warn .bill-n{color:#d71920}
.bill-pill{display:inline-block;padding:3px 10px;border-radius:999px;font-size:12px;font-weight:700;white-space:nowrap}
.bp-active{background:#e2f4e2;color:#1e7a1e}
.bp-pilot{background:#e3ecfd;color:#2456a6}
.bp-pastdue{background:#fde3e3;color:#b3261e}
.bp-readonly{background:#fdeeda;color:#9a6206}
.bp-internal{background:#eceff3;color:#5a6b7c}
.bill-editor td{background:#f7fafc}
.bill-ed-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:12px;margin-bottom:12px}
.bill-ed-grid label{display:block;font-size:12px;font-weight:600;color:#33475c;margin-bottom:4px}
.bill-ed-grid input,.bill-ed-grid select{width:100%;padding:9px 10px;border:1px solid #c9d6e2;border-radius:7px;font-size:14px;background:#fff}
.bill-ed-actions{display:flex;gap:8px;flex-wrap:wrap}

.btn-sm.danger{color:#b30f16;border-color:#e3b7b9}
.btn-sm.danger:hover{background:#fdf0f0}
.del-list{margin:8px 0 10px 18px}
.del-list li{margin:3px 0}

/* Purchases log */
.purch-toolbar{display:flex;gap:10px 8px;align-items:center;flex-wrap:wrap;margin-bottom:12px}
#sourcesTable th:first-child{width:38%}
#sourcesTable th:nth-child(2){width:30%}
.sheet.tab-page:has(.ux-savebar){padding-bottom:64px}
.seg{display:inline-flex;border:1px solid var(--line);border-radius:8px;overflow:hidden}
.seg button{background:#fff;border-radius:0;padding:8px 12px;font-size:13px;border-right:1px solid var(--line)}
.seg button:last-child{border-right:0}
.seg button.on{background:var(--navy);color:#fff}
.inline-date{height:36px;padding:0 8px;border:1px solid #d1d5db;border-radius:6px;font-size:14px}
.grid-table td.num,.grid-table th.num{text-align:right}
.grid-table tfoot td{font-weight:800;background:#f2f6f9;border-top:2px solid var(--line);padding:9px 10px}
.grid-table th.sortable{cursor:pointer;user-select:none}
.grid-table th.sortable:hover{background:#dfe7ee;color:#17212a}
.grid-table th[draggable="true"]{cursor:grab}
.grid-table th[draggable="true"]:active{cursor:grabbing}
.sort-arrow{color:var(--red);font-size:10px;margin-left:2px}
.purch-empty{color:var(--muted);text-align:center;padding:22px 10px !important}
.empty-state{border:1.5px dashed #c3ced8;border-radius:12px;padding:34px 22px;text-align:center;color:var(--muted);font-size:14px;background:#fbfcfe;margin:6px 0 4px}
.purch-group h4{margin:14px 0 6px;font-size:12px;text-transform:uppercase;color:#3e4b57}
.purch-checks{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:5px 14px}
.purch-checks label{font-size:13px;font-weight:600;display:flex;gap:7px;align-items:center;cursor:pointer}
.purch-yours{margin-top:16px;background:#f7fafc;border:1px solid var(--line);border-radius:8px;padding:10px 14px}
.purch-yours ol{margin:6px 0 2px;padding-left:20px;font-size:13px}

/* Teams (Phase 3) */
.scope-banner{border-radius:8px;padding:11px 14px;font-size:13px;margin-bottom:12px;display:flex;gap:9px;align-items:center;background:#e8f1fb;border:1px solid #b9d2ef;color:#144a7a}
.lock-tag{font-size:11px;color:#8a5a00;background:#fef3e2;border:1px solid #f0d9a8;border-radius:6px;padding:3px 8px;font-weight:700;white-space:nowrap}
.teams-card{border:1px solid var(--line);border-radius:10px;padding:14px 16px;margin-bottom:14px;background:#fbfcfd}
.teams-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:6px}
.teams-head h3{margin:0;font-size:15px}
.teams-head-title{display:flex;align-items:baseline;gap:9px}
.teams-head-btns{display:flex;gap:8px}
/* Drafts admin tab */
.draft-stats{display:flex;gap:12px;flex-wrap:wrap;margin:0 0 14px}
.draft-stat{flex:1;min-width:150px;border:1px solid #e3e8ef;border-radius:10px;padding:11px 14px;background:#fbfcfe}
.draft-stat b{font-size:22px;display:block}
.draft-stat span{font-size:11.5px;color:#5b6b7f;text-transform:uppercase;letter-spacing:.6px;font-weight:600}
.draft-stat.warn b{color:#c62828}
.age-badge{display:inline-block;padding:2.5px 9px;border-radius:999px;font-size:12px;font-weight:700;white-space:nowrap}
#dlgMsg{white-space:pre-line;line-height:1.5}
.age-fresh{background:#e6f4ea;color:#1e7a2e}
.age-aging{background:#fff4e0;color:#9a6200}
.age-stale{background:#fdecea;color:#b3261e}
.dash-draft-note{border:1.5px dashed #d9a400;background:#fffdf4;border-radius:10px;padding:14px 18px;margin:0 16px 16px}
.dash-draft-note b{font-size:15px}
.dash-draft-note p{font-size:13.5px;color:#5b6b7f;margin-top:5px;line-height:1.5}
.dash-draft-note a{color:#c62828;font-weight:700;text-decoration:none;cursor:pointer}
.team-card{border:1px solid var(--line);border-radius:10px;padding:12px 14px;margin-top:10px;background:#fff}
.team-card-head{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;flex-wrap:wrap}
.team-members{display:flex;flex-wrap:wrap;gap:6px;margin-top:9px}
.team-members .m{background:#eef3f7;border-radius:14px;padding:4px 11px;font-size:12.5px;font-weight:600}
.team-tag{display:inline-block;font-size:11px;font-weight:700;border-radius:11px;padding:2px 9px;background:#e8f1fb;color:#144a7a;margin-top:3px}

/* Permissions tab (presets, policies, people) */
.perm-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:14px;margin:14px 0}
.perm-card{border:1px solid var(--line);border-radius:10px;padding:14px;background:#fff;display:flex;flex-direction:column}
.perm-card-head{font-size:15px}
.perm-names{margin:4px 0;font-size:13px;font-weight:600;color:var(--ink)}
.perm-lines{margin:8px 0;padding-left:18px;font-size:13px;color:var(--ink)}
.perm-lines li{margin:3px 0}
.perm-card-foot{display:flex;justify-content:space-between;align-items:center;gap:8px;margin-top:auto;padding-top:10px}
.perm-group{border:1px solid var(--line);border-radius:10px;padding:12px 14px;margin-top:12px;background:#fff}
.perm-group h4{margin:0 0 6px;font-size:14px}
.perm-toggle{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;padding:11px 0;border-bottom:1px solid #edf1f4}
.perm-toggle-side{flex:0 0 172px;display:flex;flex-direction:column;align-items:flex-end;gap:6px;padding-top:1px}
.form-section{border:1px solid var(--line);border-radius:12px;padding:6px 14px 12px;margin-top:14px;background:#fbfcfd}
.form-section>h4{margin:10px 0 2px;font-size:12px;letter-spacing:.7px;text-transform:uppercase;color:var(--blue)}
.sheet-sub{font-size:13px;font-weight:600;color:var(--muted);letter-spacing:0;text-transform:none}
.sheet-header .sheet-sub{color:#b9c8d4}
.sheet-header .sel-cap{color:#c3d2de}
.sel-cap{font-size:11px;font-weight:800;text-transform:uppercase;color:#3e4b57;margin-right:2px}
.ux-toggle-label{display:block;text-align:center;font-size:9.5px;font-weight:800;letter-spacing:.7px;text-transform:uppercase;opacity:.75;margin-bottom:2px}
.load-veil{position:absolute;inset:0;background:rgba(255,255,255,.82);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;z-index:5;border-radius:10px;font-weight:700;color:#43566a}
.perm-names-label{font-weight:700;color:#3e4b57}
.perm-toggle:last-child{border-bottom:0}
.perm-toggle-main{display:flex;gap:9px;align-items:flex-start;cursor:pointer;flex:1}
.perm-toggle-main input{margin-top:3px;width:16px;height:16px;accent-color:var(--blue)}
.perm-toggle-side{display:flex;flex-direction:column;align-items:flex-end;gap:5px;white-space:nowrap}
.perm-badge{font-size:11px;font-weight:700;border-radius:11px;padding:2px 9px;background:#eef3f7;color:#5a6a76}
.perm-badge.custom{background:#fdf6e0;color:#7a5b00;border:1px solid #eed88a}
.perm-lock{font-size:11.5px;font-weight:700;color:#6e4200}
.perm-warn{background:#fdf6e0;border:1px solid #eed88a;border-radius:10px;padding:10px 14px;color:#5c4a08;font-size:13px;margin:10px 0}
.perm-person-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;flex-wrap:wrap;margin-bottom:6px}
.perm-people{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}

/* Reports tab */
.rep-h{margin:16px 0 10px;font-size:13px;text-transform:uppercase;letter-spacing:.6px;color:#43566a}
.rep-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:12px;margin-bottom:6px}
.rep-card{border:1px solid var(--line);border-radius:10px;padding:13px 14px;background:#fff}
.rep-card.starter{background:#fbfcfd}
.rep-card h4{margin:6px 0 4px;font-size:14.5px}
.rep-card p{margin:0 0 6px;font-size:12.5px;color:var(--muted)}
.rep-meta{font-size:12px;color:var(--muted);margin-bottom:10px}
.rep-tag{display:inline-block;font-size:10.5px;font-weight:800;text-transform:uppercase;letter-spacing:.5px;border-radius:9px;padding:2px 8px}
.rep-tag.mine{background:var(--navy);color:#fff}
.rep-tag.starter{background:#eef3f7;color:#43566a;border:1px solid var(--line)}
.rep-builder-card{border:1px solid var(--line);border-radius:10px;padding:14px 16px;margin-top:18px;background:#fbfcfd}
.rep-fld{display:flex;flex-direction:column;gap:3px}
.rep-fld span{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.5px;color:#43566a}
.rep-measures{display:flex;gap:8px 18px;align-items:center;flex-wrap:wrap}
.rep-measures-label{font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.5px;color:#43566a}
.rep-measures label{font-size:13px;font-weight:600;display:flex;gap:7px;align-items:center;cursor:pointer}
.rep-measures input{width:15px;height:15px;accent-color:var(--blue)}
.rep-result-head{display:flex;justify-content:space-between;align-items:baseline;gap:10px;flex-wrap:wrap;margin-bottom:8px}
.rep-result-head h3{margin:0;font-size:16px}
.rep-table td.num,.rep-table th.num{text-align:right}
.rep-bars{margin-top:18px;max-width:760px}
.rep-bars h4{margin:0 0 10px;font-size:12px;text-transform:uppercase;letter-spacing:.6px;color:#43566a}
.rep-bar-row{display:flex;align-items:center;gap:10px;margin:5px 0;font-size:13px}
.rep-bar-name{width:180px;text-align:right;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.rep-bar{height:16px;background:var(--red);border-radius:3px;min-width:2px}
.rep-bar-val{font-weight:700;white-space:nowrap}


/* Dashboard widget wall (2026-10-15) */
.dash-controls{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin:4px 0 10px}
.dash-controls .seg button{white-space:nowrap}
.dash-custom-range{display:inline-flex;gap:10px;align-items:center}
.dash-custom-range label,.dash-filter{display:inline-flex;gap:6px;align-items:center;font-size:13px;font-weight:600;color:#43566a}
.dash-widget-grid{display:grid;grid-template-columns:repeat(12,1fr);gap:14px;margin-top:10px;align-items:start;grid-auto-flow:dense}
.dash-widget{background:#fff;border:1px solid #e2e8f0;border-radius:10px;padding:14px 16px;min-width:0;display:flex;flex-direction:column;position:relative}
.dash-widget.span12{grid-column:span 12}
.dash-widget.span8{grid-column:span 8}
.dash-widget.span7{grid-column:span 7}
.dash-widget.span6{grid-column:span 6}
.dash-widget.span5{grid-column:span 5}
.dash-widget.span4{grid-column:span 4}
.dash-widget.span3{grid-column:span 3}
/* Adjustable widget sizes (2026-10-20): customize-mode steppers
   in the widget header + a bottom-right drag grip. */
.dash-size-tools{display:inline-flex;align-items:center;gap:6px}
.dash-size-label{font-size:11px;font-weight:800;color:#1d5c8f;min-width:38px;text-align:center}
.dash-resize-grip{position:absolute;right:0;bottom:0;width:22px;height:22px;cursor:nwse-resize;z-index:3;touch-action:none;background:linear-gradient(135deg,transparent 50%,#b8c6d4 50%,#b8c6d4 60%,transparent 60%,transparent 70%,#b8c6d4 70%,#b8c6d4 80%,transparent 80%);border-radius:0 0 10px 0}
.dash-widget-grid.customizing .dash-widget{outline:2px dashed var(--line);outline-offset:-2px}
.dash-widget-head{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap}
.dash-widget-head h3{margin:0;font-size:15px;color:var(--ink)}
.dash-widget-sub{margin:3px 0 10px;font-size:12px;color:var(--muted)}
.dash-widget-body{min-width:0}
.dash-widget-body .dash-grid{padding:2px 0;margin-top:0}
.dash-grid-5{grid-template-columns:repeat(5,1fr)}
.dash-delta{font-size:11px;font-weight:700;margin-top:5px}
.dash-delta.up{color:#137333}
.dash-delta.down{color:#b3261e}
.dash-delta.flat,.dash-delta.na{color:var(--muted);font-weight:600}
.dash-dir-line{margin:10px 0 4px}
.dash-chart{width:100%;height:170px;display:block}
.dash-chart-axis{display:flex;justify-content:space-between;font-size:11px;color:var(--muted);margin-top:2px}
.dash-mini-seg button{padding:4px 8px;font-size:11px}
.dash-trend{display:flex;align-items:flex-end;gap:6px;height:158px;overflow-x:auto;padding-top:14px}
.dash-trend-col{flex:1 1 0;min-width:42px;height:100%;display:flex;flex-direction:column;justify-content:flex-end;align-items:stretch;text-align:center}
.dash-trend-val{font-size:10px;font-weight:700;color:#43566a;white-space:nowrap;overflow:hidden}
.dash-trend-bar{background:var(--blue);border-radius:3px 3px 0 0;min-height:2px}
.dash-trend-label{font-size:10px;color:var(--muted);white-space:nowrap;overflow:hidden;margin-top:3px}
.dash-widget th.sortable{cursor:pointer}
/* Dashboard tables (polish 2026-10-15): breathing room, row
   dividers, numeric columns right-aligned with their headers.
   Scoped to .dash-widget - Purchases/Reports tables keep the
   console's shared look. */
.dash-widget .data-table{width:100%;border-collapse:collapse}
.dash-widget .data-table th,.dash-widget .data-table td{padding:10px 12px;border-bottom:1px solid #eef2f5;text-align:left;vertical-align:top}
.dash-widget .data-table thead th{border-bottom:2px solid var(--line);white-space:nowrap;color:#43566a}
.dash-widget .data-table tbody tr:last-child td{border-bottom:0}
.dash-widget .data-table .num{text-align:right}
.dash-widget .data-table td.dash-date-cell{white-space:nowrap}
/* Dashboard bars: the bar lives in a flex track so the value
   label always sits outside the bar, even at 100% width. */
.dash-bar-track{flex:1 1 auto;min-width:30px}
/* Money invested: peak label anchored top-right of the chart
   instead of floating over the axis line. */
.dash-chart-wrap{position:relative}
.dash-chart-peak{position:absolute;top:4px;right:6px;font-size:11px;font-weight:700;color:#0b4c7c;background:rgba(255,255,255,.82);padding:1px 6px;border-radius:4px}
/* Dashboard segmented controls: dividers strong enough to read
   against both the white and the active (navy) pill. */
.dash-controls .seg,.dash-widget-tools .seg{border-color:#9fb0c1}
.dash-controls .seg button,.dash-widget-tools .seg button{border-right-color:#9fb0c1}
.dash-donuts{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.dash-donut-cell{text-align:center;min-width:0}
.dash-donut-cell h4{margin:0 0 8px;font-size:12px;text-transform:uppercase;letter-spacing:.6px;color:#43566a}
.dash-donut{width:118px;height:118px;border-radius:50%;margin:0 auto;display:flex;align-items:center;justify-content:center}
.dash-donut span{background:#fff;width:62px;height:62px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:19px;font-weight:800;color:var(--ink)}
.dash-legend{margin-top:8px;font-size:12px;text-align:left;display:inline-block}
.dash-legend-row{margin:2px 0}
.dash-swatch{display:inline-block;width:10px;height:10px;border-radius:2px;margin-right:6px}
.dash-activity{display:flex;flex-direction:column}
.dash-act-row{display:flex;gap:9px;align-items:flex-start;padding:7px 0;border-bottom:1px solid #eef2f5;font-size:13px}
.dash-act-row:last-child{border-bottom:0}
.dash-act-dot{width:8px;height:8px;border-radius:50%;background:var(--blue);margin-top:5px;flex:none}
.dash-act-text{flex:1;min-width:0}
.dash-act-time{color:var(--muted);font-size:11px;white-space:nowrap}
.dash-custom-panel{border:1px solid var(--line);border-radius:10px;background:#f7fafc;padding:12px 14px;margin:8px 0 4px}
.dash-cat-row{display:flex;align-items:center;gap:10px;padding:7px 4px;border-bottom:1px solid #e6edf2;background:transparent}
.dash-cat-row:last-child{border-bottom:0}
.dash-cat-handle{cursor:grab;color:var(--muted);font-size:15px}
.dash-cat-title{flex:1;font-weight:600;font-size:13px}
.dash-cat-show{font-size:12px;font-weight:600;color:#43566a;display:inline-flex;gap:5px;align-items:center}
.dash-cat-move button{margin-left:4px}
.dash-custom-actions{margin-top:10px}
@media(max-width:1100px){
  .dash-widget.span7,.dash-widget.span6,.dash-widget.span5{grid-column:span 12}
  .dash-grid-5{grid-template-columns:repeat(3,1fr)}
}
@media(max-width:640px){
  .dash-grid-5{grid-template-columns:repeat(2,1fr)}
  .dash-donuts{grid-template-columns:1fr}
  .dash-trend-col{min-width:34px}
}

/* Button family (refresh 2026-10-16): same pill system as the purchase
   website — red reserved for the primary action, light pills on content. */
.btn-red, .btn-blue, .btn-light { border-radius: 99px; }
input[type="file"]{height:auto;padding:7px 9px}
input[type="file"]::file-selector-button{font:inherit;font-size:13px;font-weight:700;border:0;border-radius:99px;padding:8px 14px;background:var(--blue);color:#fff;cursor:pointer;margin-right:10px}
.btn-light { border: 1px solid #c3ced6; }
.btn-light:hover { border-color: #93a5b3; }
.btn-red:hover { background: #a90e16; }

/* Template Mapper (2026-10-16) */
.tm-source{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-bottom:6px}
.tm-source #tmSourceLabel{font-weight:600;color:var(--navy)}
.tm-grid{display:flex;gap:16px;align-items:flex-start;margin-top:10px}
.tm-pages{display:flex;flex-direction:column;gap:4px;width:238px;max-height:600px;overflow:auto;flex:none}
.tm-page{display:flex;gap:8px;align-items:baseline;text-align:left;background:#f4f7fa;border:1px solid var(--line);border-radius:8px;padding:6px 9px;font-size:12.3px;cursor:pointer;width:100%}
.tm-page.sel{background:#e8f0e9;border-color:#9db98f}
.tm-page .tm-pno{font-weight:700;color:var(--navy);min-width:20px}
.tm-page .tm-pid{flex:1;color:var(--ink)}
.tm-page .tm-pz{color:var(--muted);font-size:11.3px;white-space:nowrap}
.tm-page .tm-pz-same{color:#146c2e;font-weight:700}
.tm-copy-label{font-size:12.5px;font-weight:700;color:#40536a}
#tmCopyPicker{border:1px solid #d5dce4;border-radius:10px;padding:10px 14px;margin:8px 0;background:#fbfcfe}
.tm-pickhead{font-weight:700;color:#0f2a43;margin-bottom:4px;font-size:13.5px}
.tm-pickrow{display:flex;gap:8px;align-items:center;padding:5px 0;border-bottom:1px solid #eef2f5;font-size:13px;cursor:pointer}
.tm-pickrow input{width:auto}
.tm-pickrep{margin-left:auto;color:#9a5a00;font-weight:700;font-size:11.5px;white-space:nowrap}
.tm-pickhas{margin-left:auto;color:#71869c;font-size:11.5px;white-space:nowrap}
.tm-pickfoot{display:flex;gap:8px;justify-content:flex-end;margin-top:10px}
.tm-right{flex:1;min-width:0}
.tm-stage{position:relative;display:inline-block;background:#fff;border:1px solid var(--line);border-radius:8px;overflow:hidden;line-height:0}
.tm-stage canvas{display:block}
.tm-zone{position:absolute;border:2.5px solid #d81a26;background:rgba(216,26,38,.10);cursor:move;outline:none;box-sizing:border-box}
.tm-zone.tm-temp{border-style:dashed;cursor:crosshair}
.tm-handle{position:absolute;right:-9px;bottom:-9px;width:16px;height:16px;background:#d81a26;border-radius:4px;cursor:nwse-resize}
.tm-idline{margin:10px 0 6px;font-size:13.5px}
.tm-ev{color:var(--muted);font-size:12.3px}
.tm-controls{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:6px 0}
.tm-controls label{font-size:12.3px;color:var(--muted);display:flex;gap:4px;align-items:center}
.tm-controls input{width:64px;padding:5px 7px;border:1px solid var(--line);border-radius:7px;font-size:12.5px}
.tm-warn{color:#9a6a00;font-weight:600}
.tm-active{background:#0f2a43 !important;color:#fff !important}
@media (max-width:900px){.tm-grid{flex-direction:column}.tm-pages{width:100%;max-height:220px}}

/* Resizable table columns (2026-10-18): drag handles on header
   cells; widths remembered per table (see admin.js colw*). */
table.colw-on{table-layout:fixed}
table.colw-on th{position:relative;overflow:hidden;text-overflow:ellipsis}
.colw-handle{position:absolute;top:0;right:-5px;width:11px;height:100%;cursor:col-resize;z-index:6;touch-action:none}
table.colw-ready th{position:relative}
table.colw-ready th:hover{box-shadow:inset -2px 0 0 rgba(11,76,124,.35)}
.colw-handle:hover{background:rgba(11,76,124,.18)}
body.colw-dragging,body.colw-dragging *{cursor:col-resize !important;user-select:none !important}

.team-members .m.m-off{opacity:.55}

/* ================= UX PASS (2026-10-21, Andres-approved mockups) ================= */
/* Scope banner */
.ux-scope{display:flex;align-items:center;gap:10px;padding:8px 14px;font-size:13px;border-radius:10px;margin:0 0 12px;border:1px solid var(--line,#d5dde3)}
.ux-scope .dot{width:9px;height:9px;border-radius:50%;flex:none}
.ux-scope.one{background:#eef6ee}.ux-scope.one .dot{background:#067647}
.ux-scope.all{background:#fffaeb}.ux-scope.all .dot{background:#b54708}
.ux-scope small{color:#697681}
.ux-scope .sw{margin-left:auto;font-size:12.5px;color:#1f6fb2;font-weight:600;white-space:nowrap}
/* Header tools */
.ux-tools{display:inline-flex;align-items:center;gap:8px;margin-right:10px}
.ux-find-btn{background:#ffffff22;border:1px solid #ffffff44;color:#fff;border-radius:99px;padding:7px 13px;font-size:12px;font-weight:700;cursor:pointer}
.ux-find-btn:hover{background:#ffffff38}
.ux-toggle{display:inline-flex;border:1px solid #ffffff44;border-radius:99px;overflow:hidden}
.ux-toggle button{background:transparent;border:0;color:#dbe7f2;font-size:11.5px;font-weight:700;padding:6px 10px;cursor:pointer}
.ux-toggle button.on{background:#fff;color:#0F2A43}
/* Finder palette */
.ux-finder{position:fixed;inset:0;background:rgba(43,58,71,.55);z-index:2000;display:flex;align-items:flex-start;justify-content:center;padding:9vh 14px 14px}
.ux-pal{background:#fff;border-radius:14px;box-shadow:0 18px 50px rgba(10,25,40,.35);width:100%;max-width:560px;overflow:hidden}
.ux-pal .pin{display:flex;align-items:center;gap:10px;padding:13px 16px;border-bottom:1px solid #d5dde3}
.ux-pal .pin input{border:0;outline:0;font-size:15.5px;flex:1;color:#1c2b3a;background:transparent}
.ux-pal .esc{font-size:11px;color:#697681;border:1px solid #d5dde3;border-radius:5px;padding:1px 6px}
.ux-pal .results{max-height:46vh;overflow:auto;padding:6px 8px 8px}
.ux-pal h4{margin:8px 8px 4px;font-size:11px;letter-spacing:.08em;color:#697681;text-transform:uppercase}
.ux-pal .row{display:flex;align-items:center;gap:10px;padding:8px 10px;border-radius:8px;font-size:13.5px;cursor:pointer;color:#1c2b3a}
.ux-pal .row.sel{background:#eaf3fb}
.ux-pal .row .tag{margin-left:auto;font-size:11.5px;color:#697681;white-space:nowrap}
.ux-pal .row .ic{width:24px;height:24px;border-radius:6px;background:#eef2f5;display:flex;align-items:center;justify-content:center;font-size:12px;flex:none}
.ux-pal .none{padding:14px 10px;color:#697681;font-size:13px}
.ux-pal .pfoot{display:flex;gap:16px;padding:9px 16px;border-top:1px solid #d5dde3;color:#697681;font-size:11.8px;background:#fafbfc}
.ux-pal .kbd{background:#fff;border:1px solid #d5dde3;border-bottom-width:2px;border-radius:5px;padding:0 5px;font-size:11px}
/* Sticky save bar (Website tab) */
.ux-savebar{position:sticky;bottom:12px;display:flex;align-items:center;gap:12px;background:rgba(255,255,255,.97);border:1px solid #d5dde3;border-radius:12px;padding:10px 14px;box-shadow:0 8px 24px rgba(16,42,67,.13);margin-top:16px;z-index:5}
.ux-savebar .unsaved{display:none;align-items:center;gap:7px;font-size:12.8px;color:#b54708;font-weight:700}
.ux-savebar .unsaved i{width:8px;height:8px;border-radius:50%;background:#f79009;display:inline-block}
.ux-savebar.dirty .unsaved{display:flex}
.ux-savebar .hint{font-size:12.3px;color:#697681}
.ux-savebar .sp{margin-left:auto;display:flex;gap:8px}
/* Saved views (Purchases) */
.ux-views{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:10px 0 2px}
.ux-views label{font-size:12.3px;color:#697681;font-weight:600}
/* Density */
body.ux-compact table.grid-table td{padding-top:3.5px;padding-bottom:3.5px;font-size:12.8px}
body.ux-compact table.grid-table th{padding-top:4px;padding-bottom:4px}
/* Skeletons */
.ux-skel td{padding:10px}
.ux-skel .bar{height:12px;border-radius:6px;background:linear-gradient(90deg,#e8edf1 25%,#f5f8fa 50%,#e8edf1 75%);background-size:200% 100%;animation:uxshim 1.2s infinite}
@keyframes uxshim{to{background-position:-200% 0}}
/* Row flash (finder jump target) */
tr.ux-flash td{background:#fff3cd !important;transition:background 1.2s}
tr.ux-settle td{background:transparent !important}
/* Inline edit */
.ux-pencil{color:#b6c2cc;font-size:12px;margin-left:6px;cursor:pointer;background:none;border:0;padding:0}
tr:hover .ux-pencil{color:#1f6fb2}
.ux-editcell{display:inline-flex;gap:6px;align-items:center}
.ux-editcell input{border:1.5px solid #1f6fb2;border-radius:7px;padding:4px 7px;font-size:12.8px;width:132px;outline:0}
.ux-mini{width:24px;height:24px;border-radius:7px;border:1px solid #d5dde3;background:#fff;cursor:pointer;font-size:12px;line-height:1}
.ux-mini.ok{background:#067647;border-color:#067647;color:#fff}
/* Solid panels (accessibility): kill the glass on the sign-in cards */
body.ux-solid .admin-form-card,body.ux-solid .dealership-signin-card{backdrop-filter:none;-webkit-backdrop-filter:none;background:#12314d;border-color:#12314d}
/* Drafts filter label: it was white on a light toolbar (invisible) */
#tab-drafts .checkline-inline{color:#1c2b3a}
/* Button discipline: one press feel everywhere */
.btn-red,.btn-blue,.btn-light,.btn-ghost{transition:background .12s,transform .05s}
.btn-red:active,.btn-blue:active,.btn-light:active,.btn-ghost:active{transform:translateY(1px)}
button:disabled{opacity:.55;cursor:not-allowed}

/* Button audit 2026-10-21 — breathing room before destructive actions */
td .btn-light.danger:not(:first-child), td .btn-red:not(:first-child){margin-left:12px}
.row-actions .btn-light.danger{margin-left:10px}
#uxViewDel{margin-left:12px}
.remove-map{margin-left:10px}
/* Button audit 2026-10-21 — inline-edit pencils: visible, bigger hit area */
.ux-pencil{font-size:13px;padding:2px 7px;margin-left:6px;border:1px solid var(--line);border-radius:99px;background:#eef4f8;color:var(--blue);cursor:pointer;vertical-align:1px;line-height:1.4}
.ux-pencil:hover{background:#dbe9f3;border-color:#b9cfdd}

/* Button audit 2026-10-21 — searches sit in the sheet header everywhere */
.header-actions .inline-search{width:230px}
#uxSavebar,#mySavebar{display:none}

/* Logo upload card (2026-10-22) — compact, matches the console card language */
.logo-card{display:flex;gap:18px;align-items:flex-start;border:1px solid var(--line);border-radius:12px;padding:14px 16px;background:#fbfcfd;max-width:680px;margin-top:10px}
.logo-card.drag{outline:2px dashed var(--blue);outline-offset:-6px;background:#eef4fa}
.logo-card-thumb{flex:none}
.logo-card-main{flex:1;min-width:0}
.logo-card-row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.logo-card-row input[type=file]{flex:1 1 220px;width:auto;min-width:0}

/* Logo URL option (2026-10-22) — My Dealership */
.logo-url-row{max-width:680px;margin-top:14px}
.logo-url-row label{display:block;font-weight:700;font-size:13px;margin-bottom:5px}
.logo-url-row input{width:100%}

/* Field Mapping (Custom Form Templates, 2026-10-22) */
.fm-profiles{display:grid;grid-template-columns:1fr 1fr;gap:12px;max-width:680px}
/* Selection cards restyled 2026-10-30 (Andres-approved mockup): the global
   label rule was forcing these cards into 11px bold ALL-CAPS — they now opt
   out (text-transform:none) and carry the console navy/blue treatment:
   tinted selected card + custom radio + a small check badge. */
.fm-profile{position:relative;display:flex;gap:11px;align-items:flex-start;margin:0;padding:14px 38px 14px 16px;border:1.5px solid #cbd4dc;border-radius:14px;background:linear-gradient(180deg,#fff,#f7fafc);box-shadow:0 1px 2px rgba(24,35,45,.05);cursor:pointer;text-transform:none;letter-spacing:0;transition:border-color .15s ease,box-shadow .15s ease,background .15s ease}
.fm-profile:hover{border-color:#9db8cc;box-shadow:0 3px 10px rgba(11,76,124,.10)}
.fm-profile.sel{border-color:#0b4c7c;background:linear-gradient(180deg,#eef5fb,#e2edf7);box-shadow:0 0 0 1px #0b4c7c inset,0 4px 14px rgba(11,76,124,.14)}
.fm-profile.sel::after{content:"✓";position:absolute;top:10px;right:12px;width:20px;height:20px;border-radius:50%;background:#0b4c7c;color:#fff;font-size:11px;font-weight:700;display:flex;align-items:center;justify-content:center}
.fm-profile input{appearance:none;-webkit-appearance:none;flex:0 0 auto;width:20px;height:20px;margin:1px 0 0;padding:0;border:2px solid #a7b6c2;border-radius:50%;background:#fff;cursor:pointer;position:relative;transition:border-color .15s ease}
.fm-profile input:checked{border-color:#0b4c7c}
.fm-profile input:checked::after{content:"";position:absolute;inset:3px;border-radius:50%;background:#0b4c7c}
.fm-profile input:focus-visible{outline:2px solid #0b4c7c;outline-offset:2px}
.fm-profile b{color:#18232d;font-size:14px;font-weight:700}
.fm-profile .note{display:block;margin-top:3px;color:#65717c;font-size:12.5px;font-weight:400;line-height:1.5}
.fm-tpl{margin-top:10px;max-width:680px}
.fm-tpl .row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.fm-filewrap input[type="file"]{max-width:230px}
.fm-tools{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin:10px 0}
.fm-tools input[type="text"]{min-width:200px}
.fm-progress{font-weight:700;color:#0b4c7c}
.fm-series{border:1px solid #d4dbe3;border-left:4px solid #0b4c7c;border-radius:8px;padding:10px 12px;margin:10px 0;background:#f7fafc}
.fm-series-label{font-weight:700}
.fm-series-note{font-size:12px;color:#5a6a78;margin:2px 0 6px}
.fm-rows{max-height:60vh;overflow:auto;border:1px solid #e2e8ee;border-radius:8px;padding:6px 10px}
.fm-pagehead{font-weight:800;color:#0b4c7c;margin:10px 0 4px;font-size:12px;text-transform:uppercase;letter-spacing:.04em}
.fm-row{display:grid;grid-template-columns:minmax(170px,1.1fr) minmax(190px,1fr) minmax(380px,1.9fr);gap:10px;align-items:center;padding:5px 0;border-bottom:1px solid #eef2f5}
.fm-fname{font-weight:600;word-break:break-word}
.fm-type{display:inline-block;margin-left:6px;font-size:11px;font-weight:700;color:#5a6a78;background:#eef2f5;border-radius:20px;padding:1px 8px}
.fm-extra{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.fm-extra select,.fm-extra input[type="text"]{max-width:100%}
.fm-x{font-size:12px;color:#40536a;display:inline-flex;gap:4px;align-items:center}
.fm-x input[type="number"]{width:64px}
.fm-stdtable{width:100%;border-collapse:collapse}
.fm-stdtable th,.fm-stdtable td{border-bottom:1px solid #e2e8ee;padding:5px 8px;text-align:left;font-size:13px}
@media (max-width:760px){.fm-row{grid-template-columns:1fr}.fm-profiles{grid-template-columns:1fr}}

/* Field Mapping Round 2 (2026-10-23): page print conditions + form choices hint */
.fm-pagehead { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.fm-pagerule-wrap { font-weight: 400; font-size: 12px; color: #5b6b7f; display: inline-flex; align-items: center; gap: 6px; }
.fm-pagerule { padding: 3px 6px; border: 1px solid #c8d2dc; border-radius: 6px; background: #fff; font-size: 12px; }
.fm-choices { display: block; font-size: 11px; color: #7a8794; margin-top: 2px; }

/* Field mapper two-pane layout (2026-10-24): page rail on the
   left (same pattern as the Template Mapper), the selected
   page's fields on the right, the print condition as the page's
   own headline card. */
.fm-grid{display:flex;border:1px solid #e2e8ee;border-radius:8px;overflow:hidden}
.fm-rail{width:252px;flex:none;background:#f8fafc;border-right:1px solid #e2e8ee;max-height:60vh;overflow:auto;padding:8px;display:flex;flex-direction:column;gap:4px}
.fm-panel{border:none;border-radius:0;flex:1;min-width:0}
.fm-pagebtn{text-align:left;border:1px solid transparent;background:transparent;border-radius:8px;padding:8px 10px;cursor:pointer;font:inherit;width:100%}
.fm-pagebtn:hover{background:#eef4fa}
.fm-pagebtn.sel{background:#fff;border-color:#bcd2e8;box-shadow:0 1px 3px rgba(15,42,67,.08)}
.fm-pagebtn.dim{opacity:.45}
.fm-pgbtn-name{display:block;font-size:13px;font-weight:600;color:#22384f;line-height:1.3}
.fm-pgbtn-meta{display:flex;gap:6px;align-items:center;margin-top:4px;flex-wrap:wrap}
.fm-pgbtn-count{font-size:11.5px;color:#71869c}
.fm-chip{font-size:10.5px;font-weight:700;padding:2px 7px;border-radius:9px;background:#fdf0e2;color:#9a5a00;border:1px solid #f3d3a4;white-space:nowrap}
.fm-chip-never{background:#eceff3;color:#5a6a7a;border-color:#d5dce4}
.fm-pagetitle{font-weight:700;color:#0f2a43;font-size:15px;margin:8px 0 8px}
.fm-rulecard{display:flex;gap:14px;align-items:center;background:#fdf8ef;border:1px solid #f3d3a4;border-radius:10px;padding:10px 14px;margin-bottom:12px;flex-wrap:wrap}
.fm-rulecard-label{font-size:12px;font-weight:700;letter-spacing:.03em;color:#7a5200;display:inline-flex;align-items:center;gap:8px;white-space:nowrap}
.fm-rulecard .fm-pagerule{font-size:13px;padding:6px 8px}
.fm-rulewhy{font-size:12.5px;color:#6a5a33;flex:1;min-width:200px}
.fm-bar{display:inline-block;width:130px;height:7px;background:#e4eaf0;border-radius:4px;overflow:hidden;vertical-align:middle;margin-right:8px}
.fm-bar i{display:block;height:100%;background:#0b4c7c}
.fm-format{width:300px;flex:none}
.fm-when{width:118px;flex:none}
.fm-x{white-space:nowrap}
@media (max-width:760px){.fm-grid{flex-direction:column}.fm-rail{width:100%;max-height:200px;border-right:none;border-bottom:1px solid #e2e8ee}}

/* Purchase Package Setup card (2026-10-23): one card, four
   numbered steps — form, logo, logo placement, field mapping —
   in My Dealership and the Companies editor. */
.setup-steps { margin-top: 6px; }
.setup-step { display: flex; gap: 14px; padding: 16px 0; border-top: 1px solid #e6ecf2; }
.setup-step:first-child { border-top: none; padding-top: 6px; }
.setup-num { flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%; background: #0b4c7c; color: #fff; font-weight: 700; font-size: 15px; display: flex; align-items: center; justify-content: center; margin-top: 2px; }
.setup-body { flex: 1 1 auto; min-width: 0; }
.setup-trow { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.setup-title { font-weight: 600; font-size: 15px; color: #0F2A43; }
.setup-chip { font-size: 12px; font-weight: 600; border-radius: 999px; padding: 3px 10px; }
.setup-chip.done { background: #e2f2e4; color: #1e6b2e; }
.setup-chip.review { background: #fdf0d9; color: #8a5d00; }
.setup-chip.todo { background: #e8edf3; color: #43536a; }

/* Administrator menu + header Version B (2026-10-23): the Density /
   Panels toggles live in a white card under the user chip, so the
   bar itself is one row of pills at one height. */
.user-menu-wrap{position:relative;display:inline-block}
.user-chip{cursor:pointer;font-family:inherit;color:#fff}
.um-chev{font-size:10px;opacity:.8}
.user-menu{position:absolute;top:calc(100% + 8px);right:0;width:332px;background:#fff;color:var(--ink);border:1px solid var(--line);border-radius:12px;box-shadow:0 14px 34px #0003;padding:14px 16px 10px;z-index:200;text-align:left}
.um-head{font-size:13.5px;font-weight:800}
.um-role{display:block;font-size:11px;font-weight:600;color:var(--muted);margin-top:1px}
.um-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:11px 0;border-top:1px solid #e5eaee;margin-top:10px}
.um-row label{font-size:13px;font-weight:700;text-transform:none;letter-spacing:0}
.um-row small{display:block;font-size:11px;color:var(--muted);font-weight:500;text-transform:none;letter-spacing:0;white-space:nowrap;margin-top:1px}
.user-menu .ux-toggle{border-color:var(--line);flex:none}
.user-menu .ux-toggle button{color:var(--ink);white-space:nowrap}
.user-menu .ux-toggle button.on{background:var(--navy);color:#fff}
.header kbd, .ux-find-btn kbd{font-family:inherit;font-size:10.5px;font-weight:700;background:#ffffff14;border:1px solid #ffffff45;border-bottom-width:2px;border-radius:5px;padding:1px 5px;color:#fff}
/* Field-mapper page names keep their natural case (2026-10-23):
   the all-caps header style made long bookmark names shout. */
.fm-pgname{text-transform:none;letter-spacing:0;font-weight:700}
/* Combine fields builder (2026-10-24) */
.fm-parts{margin:2px 0 4px}
.fm-parts-rows{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:6px}
.fm-part{display:inline-flex;gap:3px;align-items:center;background:#f4f7fa;border:1px solid #dbe3ec;border-radius:8px;padding:3px 4px}
.fm-part select,.fm-part input{width:auto;font-size:12.3px;padding:3px 5px}
.fm-part-text{width:90px}
.fm-partbtn{background:#fff;border:1px solid #c4cfda;border-radius:6px;width:22px;height:22px;font-size:11px;line-height:1;cursor:pointer;color:#40536a;padding:0}
.fm-parts-foot{display:flex;gap:7px;align-items:center;flex-wrap:wrap}
.fm-partprev{font-size:12.3px;color:#40536a}
.fm-partprev b{color:#0f2a43}

/* Website customizer (Phase 1, 2026-10-24) */
.sc-grid{display:grid;grid-template-columns:1.25fr 1fr;gap:18px;align-items:start}
@media (max-width:900px){.sc-grid{grid-template-columns:1fr}}
.sc-block{border:1px solid #d8e0e8;border-radius:10px;padding:10px 12px;margin-bottom:12px}
.sc-block h4{margin:2px 0 8px;font-size:13.5px;color:#0b4c7c}
.sc-block label{display:block;font-size:12px;font-weight:600;margin:8px 0 4px}
.sc-swrow{display:flex;gap:6px;align-items:center}
.sc-swatch{width:26px;height:26px;border-radius:50%;border:2px solid #fff;box-shadow:0 0 0 1px #b9c6d2;cursor:pointer;padding:0}
.sc-swatch.sel{box-shadow:0 0 0 2px #0b4c7c}
.sc-color{width:38px;height:28px;border:1px solid #b9c6d2;border-radius:6px;padding:1px;background:#fff;cursor:pointer}
.sc-seg{display:inline-flex;border:1px solid #b9c6d2;border-radius:8px;overflow:hidden}
.sc-segbtn{border:0;background:#fff;padding:6px 10px;font-size:12.5px;cursor:pointer}
.sc-segbtn.sel{background:#0b4c7c;color:#fff}
.sc-row{display:grid;grid-template-columns:40px 1fr 172px 112px 74px;gap:8px;align-items:center;padding:5px 0;border-top:1px solid #eef2f5}
.sc-row.off{opacity:.55}
.sc-moves{display:inline-flex;gap:2px}
.sc-mv{border:1px solid #cbd4dc;background:#f4f7f9;border-radius:5px;width:18px;height:22px;line-height:1;cursor:pointer;padding:0}
.sc-name{font-size:13px}
.sc-core{font-size:10.5px;background:#eef4ea;color:#4c7a3f;border-radius:8px;padding:1px 6px;margin-left:4px}
.sc-fmt{width:172px!important}
.sc-size{width:112px!important}
.sc-nofmt{font-size:12px;color:#8494a3}
.sc-vis{font-size:12.5px;font-weight:500!important;margin:0!important}
.sc-prevwrap{position:sticky;top:8px}
.sc-prev{border:1px solid #d8e0e8;border-radius:12px;overflow:hidden;background:#fff;padding-bottom:12px}
.sc-phead{display:flex;justify-content:space-between;align-items:center;padding:10px 14px;font-size:14px}
.sc-phead span{font-size:11.5px;opacity:.75}
.sc-pband{color:#fff;font-weight:700;font-size:12.5px;padding:6px 14px;margin-top:10px}
.sc-pgrid{display:grid;grid-template-columns:repeat(12,1fr);gap:8px;padding:10px 14px 2px}
.sc-pfield label{display:block;font-size:11px;font-weight:600;color:#41505e;margin-bottom:3px}
.sc-pinput{border:1px solid #cbd4dc;border-radius:6px;background:#f3f8fc;padding:6px 8px;font-size:12.5px;min-height:16px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sc-pbtn{display:block;margin:12px 14px 0 auto;border:0;color:#fff;border-radius:8px;padding:8px 18px;font-size:13px;cursor:pointer}

/* Your-fields builder (Phase 2, 2026-10-24) */
.sc-count{font-size:11.5px;color:#8494a3;font-weight:600}
.sc-defrow{display:flex;gap:8px;align-items:center;padding:5px 0;border-top:1px solid #eef2f5;font-size:13px}
.sc-defname{flex:1;font-weight:600}
.sc-defkey{display:block;font-weight:500;font-size:11.5px;color:#8494a3}
.sc-deftype{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.4px;background:#fdf0e0;color:#8a5a00;border-radius:10px;padding:2px 8px}
.sc-defreq{font-size:10.5px;font-weight:800;color:#b00020}
.sc-addform{background:#f7fafc;border:1px dashed #b9c9d8;border-radius:8px;padding:10px 12px;margin-top:10px}
.sc-addgrid{display:flex;gap:10px;align-items:end;flex-wrap:wrap}
.sc-addgrid label{display:block;font-size:11.5px;font-weight:700;color:#40536a;margin:0 0 4px}
.sc-addgrid input[type=text]{width:190px}
.sc-addgrid select{width:auto!important}
.sc-yourtag{font-size:10px;font-weight:800;letter-spacing:.4px;background:#fdf0e0;color:#8a5a00;border-radius:8px;padding:1px 6px;margin-left:4px}
