/* Pure Mail competitive productivity layer */
.pm-mail-tools{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
.list-tools:has(#pmMailTools){flex-wrap:wrap}
#pmMailTools{flex:1 1 100%;min-width:0;flex-wrap:nowrap;overflow-x:auto;padding-bottom:2px;scrollbar-width:thin}
#pmMailTools .small-btn{white-space:nowrap;flex:none}
.pm-mail-badge{display:inline-flex;vertical-align:middle;margin-right:5px;padding:2px 5px;border-radius:999px;font-size:7px;font-weight:900;letter-spacing:.02em}
.pm-mail-badge.focused{background:#eaf3ff;color:#1768d8;border:1px solid #d0e2fb}
.pm-mail-badge.priority{background:#fff1d9;color:#98600f;border:1px solid #f1d6a8}
.pm-reader-buttons{display:inline-flex;gap:4px;margin-left:4px}
.pm-trust-bar{display:flex;gap:6px;align-items:center;flex-wrap:wrap;padding:9px 18px;border-top:1px solid var(--line);border-bottom:1px solid var(--line);background:#fbfcfe}
.pm-trust,.pm-external,.pm-internal,.pm-trusted{display:inline-flex;align-items:center;min-height:23px;padding:0 7px;border-radius:999px;font-size:7.5px;font-weight:850;letter-spacing:.025em;border:1px solid #dfe6ef;background:#fff;color:#64748b}
.pm-trust.pass,.pm-trusted,.pm-internal{background:#edf9f2;border-color:#cce8d7;color:#227451}
.pm-trust.fail,.pm-trust.softfail,.pm-external{background:#fff2f2;border-color:#f1caca;color:#a33a45}
.pm-trust.unknown,.pm-trust.none,.pm-trust.neutral{background:#f6f8fb;color:#64748b}
.pm-reader-workbench{margin:0 18px 18px;padding:14px;border:1px solid #dfe6ef;border-radius:15px;background:#fff;box-shadow:0 5px 18px rgba(23,35,56,.04)}
.pm-work-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}
.pm-work-head span{display:block;color:var(--blue);font-size:7.5px;font-weight:950;letter-spacing:.08em}
.pm-work-head b{display:block;margin-top:2px;color:var(--ink);font-size:12px}
.pm-work-actions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px}
.pm-work-actions button{display:grid;grid-template-columns:auto 1fr;grid-template-rows:auto auto;column-gap:7px;text-align:left;align-items:center;min-height:60px;padding:9px;border:1px solid #e1e7ef;border-radius:11px;background:#fafcff;color:var(--blue);cursor:pointer}
.pm-work-actions button:hover{background:#f3f8ff;border-color:#b9d0ef;transform:translateY(-1px)}
.pm-work-actions button>b{color:var(--ink);font-size:9px}.pm-work-actions button>span{grid-column:2;color:var(--muted);font-size:7.5px}
.pm-summary-box{margin-top:10px;padding:12px;border:1px solid #d4e4f8;border-radius:11px;background:#f7fbff;color:var(--ink);font-size:10px;line-height:1.6}
.pm-summary-head{display:flex;align-items:center;justify-content:space-between}.pm-summary-head b{font-size:10px}.pm-summary-head span{font-size:7px;color:var(--blue);font-weight:900}
.pm-note-area{width:100%;min-height:150px;box-sizing:border-box;padding:11px;border:1px solid var(--line);border-radius:10px;background:var(--card);color:var(--ink);resize:vertical;font:inherit}
.pm-action-sheet{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.pm-action-sheet button{min-height:48px;padding:10px;border:1px solid var(--line);border-radius:10px;background:var(--card);color:var(--ink);font-weight:800;text-align:left;cursor:pointer}
.pm-action-sheet button:hover{background:var(--soft);border-color:#a8c3e8}
.pm-snooze-grid,.pm-schedule-presets{display:grid;grid-template-columns:repeat(3,1fr);gap:7px;margin-bottom:12px}
.pm-snooze-grid button{min-height:44px;border:1px solid var(--line);border-radius:10px;background:var(--soft);color:var(--ink);font-weight:800;cursor:pointer}
.pm-undo-bar{position:fixed;left:50%;bottom:24px;z-index:300;transform:translateX(-50%);display:flex;align-items:center;gap:18px;min-width:330px;max-width:calc(100vw - 28px);padding:11px 12px 11px 16px;border-radius:13px;background:#172338;color:#fff;box-shadow:0 18px 50px rgba(10,23,43,.27);font-size:10px;font-weight:700}
.pm-undo-bar button{border:0;border-radius:9px;padding:8px 12px;background:#fff;color:#1768d8;font-weight:900;cursor:pointer}
.pm-list{display:flex;flex-direction:column;gap:7px;max-height:44vh;overflow:auto}
.pm-list-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px;border:1px solid var(--line);border-radius:10px;background:var(--card)}
.pm-list-row>div:first-child{min-width:0}.pm-list-row b{display:block;color:var(--ink);font-size:10px}.pm-list-row span{display:block;margin-top:2px;color:var(--muted);font-size:8px;line-height:1.45}
.pm-row-actions{display:flex;gap:5px;flex:none}
.pm-search-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.pm-saved-searches{margin-top:14px;padding-top:12px;border-top:1px solid var(--line)}
.pm-section-title{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}
.pm-run-search{flex:1;min-width:0;border:0;background:transparent;text-align:left;cursor:pointer}
.pm-rule-builder{padding:12px;border:1px solid #dbe6f4;border-radius:12px;background:#f8fbff}.pm-rule-builder h3,.pm-rule-list h3{margin:0 0 9px;font-size:11px}.pm-rule-builder h3:not(:first-child){margin-top:12px}
.pm-rule-checks{display:flex;gap:14px;flex-wrap:wrap;margin:10px 0}.pm-rule-checks label{font-size:9px;font-weight:750;color:var(--ink)}
.pm-rule-list{margin-top:14px}.pm-context-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}.pm-context-grid>div{padding:11px;border:1px solid var(--line);border-radius:10px;background:var(--soft)}
.pm-context-grid small,.pm-context-grid b,.pm-context-grid span{display:block}.pm-context-grid small{font-size:7px;color:var(--muted);text-transform:uppercase;font-weight:900}.pm-context-grid b{font-size:13px;color:var(--ink);margin:3px 0}.pm-context-grid span{font-size:8px;color:var(--muted)}
.pm-context-mails{margin-top:10px;display:flex;flex-direction:column;gap:5px}.pm-context-mails button{display:flex;justify-content:space-between;gap:10px;border:1px solid var(--line);border-radius:9px;background:var(--card);padding:9px;text-align:left;cursor:pointer}.pm-context-mails b{font-size:9px;color:var(--ink)}.pm-context-mails span{font-size:8px;color:var(--muted)}
.pm-onboard-steps{display:grid;grid-template-columns:1fr 1fr;gap:9px}.pm-onboard-steps>div{padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--soft)}
.pm-onboard-steps span{display:grid;place-items:center;width:24px;height:24px;border-radius:8px;background:var(--blue-soft);color:var(--blue);font-size:9px;font-weight:950}.pm-onboard-steps b{display:block;margin-top:8px;font-size:11px;color:var(--ink)}.pm-onboard-steps p{margin:4px 0 0;font-size:8.5px;color:var(--muted);line-height:1.5}
.pm-onboard-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:12px}
.pm-team-settings{display:flex;flex-direction:column;gap:9px}.pm-team-settings label{display:flex;align-items:center;gap:8px;min-height:38px;padding:8px 10px;border:1px solid var(--line);border-radius:9px;background:var(--soft);font-size:9px;font-weight:750}
.pm-team-unread{display:grid;place-items:center;min-width:18px;height:18px;margin-left:auto;padding:0 5px;border-radius:999px;background:#1768d8;color:#fff;font-size:7px;font-style:normal;font-weight:950}
.pm-read-receipt{display:block;margin-top:4px;text-align:right;color:var(--blue);font-size:7px;font-weight:850}
.pm-offline-pending{opacity:.62}
html[data-theme="dark"] .pm-reader-workbench,html[data-theme="dark"] .pm-list-row,html[data-theme="dark"] .pm-context-mails button{background:var(--card)}
html[data-theme="dark"] .pm-trust-bar,html[data-theme="dark"] .pm-rule-builder{background:var(--soft)}
@media(max-width:1200px){.pm-work-actions{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:700px){
  .pm-mail-tools{width:100%;overflow-x:auto;flex-wrap:nowrap;padding-bottom:2px}.pm-mail-tools .small-btn{white-space:nowrap}
  .pm-work-actions,.pm-onboard-steps,.pm-search-grid,.pm-context-grid{grid-template-columns:1fr}
  .pm-snooze-grid,.pm-schedule-presets{grid-template-columns:1fr}
  .pm-reader-workbench{margin:0 10px 12px}
  .pm-trust-bar{padding:8px 10px}
  .pm-action-sheet{grid-template-columns:1fr}
  .pm-undo-bar{left:12px;right:12px;bottom:74px;transform:none;min-width:0;justify-content:space-between}
}

.pm-stream-list{display:flex;flex-direction:column;gap:7px;max-height:52vh;overflow:auto}
.pm-stream-row{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;padding:11px;border:1px solid var(--line);border-radius:10px;background:var(--card);text-align:left;cursor:pointer}
.pm-stream-row:hover{border-color:#b6ccea;background:var(--soft)}.pm-stream-row b{display:block;color:var(--ink);font-size:10px}.pm-stream-row span{display:block;margin-top:2px;color:var(--muted);font-size:8px}.pm-stream-row i{flex:none;color:var(--blue);font-size:8px;font-style:normal;font-weight:850}
.pm-stream-people{display:grid;grid-template-columns:1fr 1fr;gap:7px;max-height:45vh;overflow:auto}.pm-stream-people label{display:flex;align-items:center;gap:8px;padding:9px;border:1px solid var(--line);border-radius:9px;background:var(--soft);cursor:pointer}.pm-stream-people span,.pm-stream-people b,.pm-stream-people small{display:block}.pm-stream-people b{font-size:9px;color:var(--ink)}.pm-stream-people small{margin-top:2px;font-size:7.5px;color:var(--muted)}
.pm-stream-snapshot{padding:12px;border:1px solid #d9e5f4;border-radius:12px;background:#f8fbff}.pm-stream-snapshot>span{font-size:7px;font-weight:950;letter-spacing:.08em;color:var(--blue)}.pm-stream-snapshot h3{margin:4px 0 7px;font-size:13px;color:var(--ink)}.pm-stream-snapshot p,.pm-stream-snapshot small{font-size:8.5px;line-height:1.5;color:var(--muted)}.pm-stream-snapshot blockquote{margin:9px 0;padding:9px 11px;border-left:3px solid #a9c8ef;background:#fff;border-radius:0 8px 8px 0;color:var(--ink);font-size:9px;line-height:1.55}
.pm-stream-comments{display:flex;flex-direction:column;gap:7px;max-height:32vh;overflow:auto;margin:12px 0}.pm-stream-comment{max-width:88%;padding:9px 10px;border:1px solid var(--line);border-radius:11px;background:var(--soft)}.pm-stream-comment.mine{align-self:flex-end;background:#eef5ff;border-color:#cfe0f7}.pm-stream-comment b{font-size:8.5px;color:var(--ink)}.pm-stream-comment span{float:right;font-size:7px;color:var(--muted)}.pm-stream-comment p{margin:5px 0 0;font-size:9px;line-height:1.5;color:var(--ink)}
.pm-stream-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:8px}
html[data-theme="dark"] .pm-stream-snapshot,html[data-theme="dark"] .pm-stream-comment.mine{background:var(--soft)}
html[data-theme="dark"] .pm-stream-snapshot blockquote{background:var(--card)}
@media(max-width:700px){.pm-stream-people{grid-template-columns:1fr}}

.pm-policy-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.pm-policy-card{padding:13px;border:1px solid var(--line);border-radius:12px;background:var(--soft)}.pm-policy-card h3{margin:0 0 10px;font-size:12px;color:var(--ink)}
.pm-policy-toggle{display:flex;align-items:flex-start;gap:8px;padding:9px 0;border-top:1px solid var(--line)}.pm-policy-toggle input{margin-top:3px}.pm-policy-toggle span,.pm-policy-toggle b,.pm-policy-toggle small{display:block}.pm-policy-toggle b{font-size:9px;color:var(--ink)}.pm-policy-toggle small{margin-top:2px;font-size:7.5px;color:var(--muted);line-height:1.45}
.pm-enterprise-section{margin-top:14px;padding-top:12px;border-top:1px solid var(--line)}.pm-section-title>div span{display:block;margin-top:2px;color:var(--muted);font-size:8px}
.pm-audit-list{display:flex;flex-direction:column;gap:5px;max-height:220px;overflow:auto}.pm-audit-list>div{padding:8px 10px;border:1px solid var(--line);border-radius:9px;background:var(--card)}.pm-audit-list b,.pm-audit-list span{display:block}.pm-audit-list b{font-size:8.5px;color:var(--ink)}.pm-audit-list span{margin-top:2px;font-size:7px;color:var(--muted)}
@media(max-width:800px){.pm-policy-grid{grid-template-columns:1fr}}

.pm-reply-ideas{display:flex;flex-direction:column;gap:8px}.pm-reply-ideas>button{padding:11px;border:1px solid var(--line);border-radius:11px;background:var(--card);text-align:left;cursor:pointer}.pm-reply-ideas>button:hover{border-color:#abc5e8;background:var(--soft)}.pm-reply-ideas>button span{display:block;color:var(--blue);font-size:7px;font-weight:950;letter-spacing:.07em}.pm-reply-ideas>button p{margin:5px 0;color:var(--ink);font-size:9px;line-height:1.55}.pm-reply-ideas>button b{display:block;color:var(--blue);font-size:8px}
.pm-followup{padding:11px;border:1px solid #e7d9ad;border-radius:11px;background:#fff9e9}.pm-followup b{font-size:9px;color:#7c5b18}.pm-followup p{font-size:8.5px;color:#6e6044;line-height:1.5}
.pm-detected-meeting{margin-bottom:10px;padding:9px 10px;border:1px solid #cce8d7;border-radius:9px;background:#effaf4;color:#267552;font-size:8.5px;font-weight:850}
.pm-free-slots,.pm-related-events{margin-top:11px;padding-top:10px;border-top:1px solid var(--line)}.pm-free-slots>b,.pm-related-events>b{display:block;margin-bottom:7px;color:var(--ink);font-size:9px}.pm-free-slots>div{display:flex;gap:6px;flex-wrap:wrap}
.pm-related-event{display:flex;align-items:center;justify-content:space-between;gap:9px;padding:8px;border:1px solid var(--line);border-radius:8px;background:var(--soft);margin-top:5px}.pm-related-event b{font-size:8.5px;color:var(--ink)}.pm-related-event span{font-size:7.5px;color:var(--muted)}


/* =========================================================
   Progressive workspace guide
========================================================= */
.pm-tour{position:fixed;inset:0;z-index:3000;animation:pmTourFade .2s ease both}
.pm-tour.is-leaving{animation:pmTourOut .18s ease both}
.pm-tour-shade{position:absolute;inset:0;background:rgba(8,23,46,.56);backdrop-filter:blur(2px)}
.pm-tour-card{
  position:fixed;
  z-index:3110;
  width:min(620px,calc(100vw - 32px));
  max-height:calc(100vh - 32px);
  overflow:auto;
  border:1px solid rgba(205,219,238,.96);
  border-radius:22px;
  background:#fff;
  color:var(--ink);
  box-shadow:0 30px 90px rgba(5,23,49,.28);
  animation:pmTourCardIn .28s cubic-bezier(.2,.75,.25,1) backwards;
  transition:left .24s ease,top .24s ease,transform .24s ease;
}
.pm-tour-card.is-welcome{width:min(760px,calc(100vw - 40px))}
.pm-tour-top{
  display:flex;align-items:center;justify-content:space-between;gap:16px;
  padding:18px 20px 14px;border-bottom:1px solid #e8edf4;
  background:linear-gradient(180deg,#fbfdff,#f7faff)
}
.pm-tour-brand{display:flex;align-items:center;gap:11px;min-width:0}
.pm-tour-logo{display:grid;place-items:center;width:42px;height:42px;border-radius:13px;background:linear-gradient(135deg,#1768d7,#5a85ed);color:#fff;font-size:19px;box-shadow:0 9px 22px rgba(23,104,215,.22)}
.pm-tour-brand small,.pm-tour-brand b{display:block}
.pm-tour-brand small{font-size:8px;font-weight:950;letter-spacing:.11em;color:#1768d7}
.pm-tour-brand b{margin-top:3px;font-size:10px;color:#64748b}
.pm-tour-close{width:38px;height:38px;border:1px solid #e1e7ef;border-radius:11px;background:#fff;color:#65748a;font-size:22px;line-height:1;cursor:pointer}
.pm-tour-close:hover{background:#f2f6fb;color:#172338}
.pm-tour-progress{height:4px;background:#edf2f8;overflow:hidden}
.pm-tour-progress i{display:block;height:100%;width:0;background:linear-gradient(90deg,#1768d7,#67a2f5);transition:width .28s ease}
.pm-tour-content{padding:24px 24px 18px}
.pm-tour-step-icon{display:grid;place-items:center;width:52px;height:52px;margin-bottom:15px;border-radius:15px;background:#edf4ff;color:#1768d7;font-size:23px;font-weight:950;animation:pmTourPulseSoft 2s ease-in-out infinite}
.pm-tour-eyebrow{font-size:8px;font-weight:950;letter-spacing:.12em;color:#1768d7}
.pm-tour-content h2{margin:5px 0 10px;font-size:27px;line-height:1.12;letter-spacing:-.035em;color:#172338}
.pm-tour-content>p{margin:0;color:#5f6e83;font-size:13px;line-height:1.72;max-width:680px}
.pm-tour-bullets{display:flex;flex-wrap:wrap;gap:7px 9px;margin:16px 0 0;padding:0;list-style:none}
.pm-tour-bullets li{display:flex;align-items:center;gap:6px;padding:7px 9px;border:1px solid #dfe7f2;border-radius:999px;background:#f9fbfe;color:#435169;font-size:9px;font-weight:800}
.pm-tour-bullets li span{display:grid;place-items:center;width:16px;height:16px;border-radius:50%;background:#e8f7ee;color:#18714f;font-size:8px}
.pm-tour-map{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin-top:20px}
.pm-tour-map div{display:flex;align-items:center;gap:9px;min-height:58px;padding:10px;border:1px solid #dfe7f2;border-radius:13px;background:#fafcff}
.pm-tour-map b{display:grid;place-items:center;width:32px;height:32px;border-radius:10px;background:#edf4ff;color:#1768d7;font-size:15px}
.pm-tour-map span{font-size:10px;font-weight:850;color:#26364e}
.pm-tour-tip{margin-top:16px;padding:11px 12px;border-radius:11px;border:1px solid #d6e6fb;background:#f5f9ff;color:#54657c;font-size:9px;line-height:1.55}
.pm-tour-footer{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 18px 17px;border-top:1px solid #e8edf4;background:#fbfcfe}
.pm-tour-dont{display:flex;align-items:center;gap:8px;color:#5f6e83;font-size:9px;font-weight:750;cursor:pointer}
.pm-tour-dont input{width:16px;height:16px;accent-color:#1768d7}
.pm-tour-controls{display:flex;gap:7px;align-items:center;flex-wrap:wrap;justify-content:flex-end}
.pm-tour-controls .small-btn{min-width:80px;justify-content:center}
.pm-tour-controls .small-btn:disabled{opacity:.42;cursor:not-allowed;transform:none!important}
.pm-tour-arrow{position:fixed;z-index:3108;color:#fff;font-size:35px;font-weight:950;line-height:1;text-shadow:0 5px 16px rgba(6,26,55,.45);pointer-events:none;animation:pmTourArrow 1s ease-in-out infinite}
.pm-tour-surface{z-index:3105!important}
.pm-tour-target{
  z-index:3107!important;
  position:relative!important;
  pointer-events:none!important;
  color:#fff!important;
  background:#1768d7!important;
  box-shadow:0 0 0 5px #fff,0 0 0 10px rgba(68,143,239,.45),0 15px 34px rgba(10,44,92,.28)!important;
  animation:pmTourTarget 1.45s ease-in-out infinite!important
}
@keyframes pmTourFade{from{opacity:0}to{opacity:1}}
@keyframes pmTourOut{to{opacity:0}}
@keyframes pmTourCardIn{from{opacity:0;transform:translateY(12px) scale(.985)}to{opacity:1;transform:none}}
@keyframes pmTourArrow{0%,100%{filter:brightness(1);margin-left:0}50%{filter:brightness(1.2);margin-left:5px}}
@keyframes pmTourTarget{0%,100%{filter:brightness(1)}50%{filter:brightness(1.08)}}
@keyframes pmTourPulseSoft{0%,100%{transform:scale(1)}50%{transform:scale(1.045)}}

html[data-theme="dark"] .pm-tour-card{background:#172338;border-color:#344259;color:#eef4ff}
html[data-theme="dark"] .pm-tour-top,html[data-theme="dark"] .pm-tour-footer{background:#1d2a3d;border-color:#344259}
html[data-theme="dark"] .pm-tour-content h2{color:#f4f8ff}
html[data-theme="dark"] .pm-tour-content>p,html[data-theme="dark"] .pm-tour-dont{color:#afbdd0}
html[data-theme="dark"] .pm-tour-map div,html[data-theme="dark"] .pm-tour-bullets li{background:#1d2a3d;border-color:#344259;color:#dbe5f2}
html[data-theme="dark"] .pm-tour-map span{color:#e5edf8}
html[data-theme="dark"] .pm-tour-tip{background:#182b45;border-color:#2c4f79;color:#b9cae0}

@media(max-width:700px){
  .pm-tour-card{max-height:calc(100vh - 98px);border-radius:18px}
  .pm-tour-card.is-welcome{width:calc(100vw - 24px)}
  .pm-tour-top{padding:14px 15px 12px}
  .pm-tour-content{padding:18px 16px 14px}
  .pm-tour-content h2{font-size:22px}
  .pm-tour-content>p{font-size:11px}
  .pm-tour-map{grid-template-columns:repeat(2,minmax(0,1fr))}
  .pm-tour-footer{align-items:flex-start;flex-direction:column;padding:12px 14px}
  .pm-tour-controls{width:100%;display:grid;grid-template-columns:1fr 1fr 1fr}
  .pm-tour-controls .small-btn{min-width:0;width:100%}
  .pm-tour-arrow{font-size:31px}
}
@media(prefers-reduced-motion:reduce){
  .pm-tour,.pm-tour-card,.pm-tour-arrow,.pm-tour-target,.pm-tour-step-icon{animation:none!important;transition:none!important}
}
