:root{--pt-blue:#3f9de0;--pt-dark:#267fbf;--pt-bg:#f5f6f7;--pt-text:#263238;--pt-muted:#7d878d;--pt-line:#dfe7eb;--pt-soft:#eaf5fd;--pt-red:#ef6f7c;--pt-green:#38a66b}
.pttm,.pttm *{box-sizing:border-box}.pttm{font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:var(--pt-text);background:transparent;width:100%;font-size:14px}.pttm button,.pttm input,.pttm select{font:inherit}.pttm button{cursor:pointer}.pttm-head{display:flex;align-items:flex-start;justify-content:space-between;gap:24px;margin-bottom:18px}.pttm-head h2{font-size:30px!important;line-height:1.1!important;margin:3px 0 8px!important;color:var(--pt-text)!important;font-weight:600!important}.pttm-head p,.pttm-cardhead p{margin:0;color:var(--pt-muted);line-height:1.55}.pttm-eyebrow{font-size:11px;letter-spacing:.13em;color:var(--pt-blue);font-weight:600;text-transform:uppercase}.pttm-head-actions,.pttm-actions,.pttm-inline{display:flex;gap:9px;align-items:center}.pttm-btn{border:0;border-radius:12px;min-height:42px;padding:10px 14px;font-weight:600;transition:.15s ease}.pttm-btn:hover{transform:translateY(-1px)}.pttm-btn-primary{background:var(--pt-blue);color:#fff}.pttm-btn-soft{background:var(--pt-soft);color:var(--pt-dark);border:1px solid #cce5f5}.pttm-btn-ghost{background:#fff;color:var(--pt-text);border:1px solid var(--pt-line)}.pttm-wide{width:100%;margin-top:10px}.pttm-tabs{display:flex;gap:7px;padding:6px;background:#fff;border:1px solid var(--pt-line);border-radius:15px;margin-bottom:16px;box-shadow:0 5px 20px rgba(40,67,80,.05)}.pttm-tabs button{flex:1;border:0;background:transparent;border-radius:10px;padding:11px;color:var(--pt-muted);font-weight:600}.pttm-tabs button.is-active{background:var(--pt-soft);color:var(--pt-dark)}.pttm-panel{display:none}.pttm-panel.is-active{display:block}.pttm-grid{display:grid;grid-template-columns:minmax(260px,320px) minmax(0,1fr);gap:16px}.pttm-card{background:#fff;border:1px solid var(--pt-line);border-radius:20px;padding:20px;box-shadow:0 8px 30px rgba(40,67,80,.06)}.pttm-card h3,.pttm-modalbox h2{margin:0 0 14px!important;color:var(--pt-text)!important;font-weight:600!important}.pttm-controls label,.pttm-modalbox>label{display:block;font-size:12px;color:var(--pt-muted);font-weight:600;margin:15px 0 7px}.pttm select,.pttm input{width:100%;min-height:43px;border:1px solid #d8e1e6;border-radius:11px;background:#f8fafb;padding:9px 11px;color:var(--pt-text);outline:0}.pttm input:focus,.pttm select:focus{border-color:var(--pt-blue);box-shadow:0 0 0 3px rgba(63,157,224,.12)}.pttm-two{display:grid;grid-template-columns:1fr 1fr;gap:10px}.pttm-segment{display:grid;grid-template-columns:1fr 1fr;gap:5px;background:#f3f6f8;padding:5px;border-radius:12px}.pttm-segment button{border:0;background:transparent;border-radius:9px;padding:9px;color:var(--pt-muted);font-weight:600}.pttm-segment button.is-active{background:#fff;color:var(--pt-dark);box-shadow:0 2px 8px rgba(30,60,80,.08)}.pttm-cardhead{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:15px}.pttm-cardhead h3,.pttm-cardhead h2{margin:0 0 4px!important}.pttm-empty{display:grid;place-items:center;min-height:280px;border:1px dashed #cbd8df;border-radius:15px;color:var(--pt-muted);background:#fbfcfd}.pttm-tablewrap{overflow:auto;border:1px solid var(--pt-line);border-radius:14px}.pttm-table{width:100%;border-collapse:collapse;min-width:720px}.pttm-table th,.pttm-table td{padding:11px 10px;border-bottom:1px solid #edf1f3;text-align:left;vertical-align:middle}.pttm-table th{font-size:11px;color:var(--pt-muted);background:#f8fafb;white-space:nowrap}.pttm-table td{font-size:13px}.pttm-score{display:flex;align-items:center;gap:5px;flex-wrap:wrap}.pttm-set{display:flex;align-items:center;gap:3px;background:#f5f7f8;border-radius:8px;padding:3px}.pttm-set input{width:38px!important;min-height:32px!important;padding:3px!important;text-align:center;border-radius:6px}.pttm-playerlist{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}.pttm-player{display:grid;grid-template-columns:34px 1fr 34px;gap:8px;align-items:center;padding:8px;border:1px solid var(--pt-line);border-radius:13px;background:#fafcfd}.pttm-avatar{width:30px;height:30px;border-radius:50%;background:var(--pt-soft);position:relative}.pttm-avatar:after{content:"";position:absolute;width:8px;height:8px;border-radius:50%;background:var(--pt-blue);left:11px;top:6px}.pttm-iconbtn,.pttm-x{border:0;background:#f1f4f6;color:#6d7a81;border-radius:9px;width:34px;height:34px;font-size:20px}.pttm-diagnostics{display:flex;flex-wrap:wrap;gap:7px;margin-top:12px}.pttm-pill{padding:7px 10px;border-radius:999px;background:#fff;border:1px solid var(--pt-line);color:var(--pt-muted);font-size:11px}.pttm-modal[hidden]{display:none!important}.pttm-modal{position:fixed;inset:0;z-index:2147482000;background:rgba(31,48,58,.48);backdrop-filter:blur(6px);display:flex;align-items:center;justify-content:center;padding:20px}.pttm-modalbox{position:relative;width:min(520px,100%);max-height:90vh;overflow:auto;background:#fff;border-radius:22px;padding:26px;box-shadow:0 25px 80px rgba(25,45,60,.24)}.pttm-modal-wide{width:min(820px,100%)}.pttm-modal-xl{width:min(1100px,100%)}.pttm-x{position:absolute;right:15px;top:15px}.pttm-guide{display:grid;grid-template-columns:1fr 1fr;gap:10px}.pttm-guide article{padding:14px;background:#f8fafb;border:1px solid var(--pt-line);border-radius:13px}.pttm-guide p{margin:5px 0 0;color:var(--pt-muted);line-height:1.5}.pttm-note{margin:15px 0 0;padding:12px;border-radius:12px;background:var(--pt-soft);color:#55707f;line-height:1.5}.pttm-check{width:18px!important;min-height:18px!important}.pttm-daytitle{white-space:nowrap}.pttm-bye{color:var(--pt-muted);font-style:italic}
@media(max-width:820px){.pttm-head{flex-direction:column}.pttm-head-actions{width:100%}.pttm-head-actions .pttm-btn{flex:1}.pttm-grid{grid-template-columns:1fr}.pttm-playerlist{grid-template-columns:1fr}.pttm-guide{grid-template-columns:1fr}.pttm-cardhead{flex-direction:column}.pttm-actions{width:100%}.pttm-actions .pttm-btn{flex:1}}
@media(max-width:520px){.pttm-head h2{font-size:24px!important}.pttm-card{padding:14px;border-radius:16px}.pttm-two{grid-template-columns:1fr 1fr}.pttm-tabs button{padding:10px 5px;font-size:12px}.pttm-modal{padding:10px}.pttm-modalbox{padding:22px 15px}.pttm-score{flex-wrap:nowrap}.pttm-set input{width:34px!important}}
@media print{body *{visibility:hidden!important}.pttm.pttm-print-schedule,.pttm.pttm-print-schedule *,.pttm.pttm-print-standings,.pttm.pttm-print-standings *{visibility:visible!important}.pttm.pttm-print-schedule,.pttm.pttm-print-standings{position:absolute;left:0;top:0;width:100%;background:#fff}.pttm.pttm-print-schedule>*:not(main),.pttm.pttm-print-schedule [data-panel]:not([data-panel="schedule"]),.pttm.pttm-print-schedule .pttm-controls,.pttm.pttm-print-schedule .pttm-actions,.pttm.pttm-print-schedule .pttm-diagnostics,.pttm.pttm-print-standings>*:not(main),.pttm.pttm-print-standings [data-panel]:not([data-panel="standings"]),.pttm.pttm-print-standings .pttm-actions{display:none!important}.pttm .pttm-card{box-shadow:none;border:0;padding:0}.pttm .pttm-tablewrap{overflow:visible;border:0}.pttm .pttm-table{min-width:0}.pttm .pttm-score input{border:0;padding:0}.pttm .pttm-score{font-size:10px}}

.pttm-courts{display:grid;grid-template-columns:repeat(6,1fr);gap:5px}.pttm-courts button{border:1px solid var(--pt-line);background:#fff;border-radius:9px;min-height:36px;font-weight:600;color:var(--pt-muted)}.pttm-courts button.is-active{background:var(--pt-soft);border-color:var(--pt-blue);color:var(--pt-dark)}.pttm-three{grid-template-columns:repeat(3,1fr);margin-top:6px}.pttm-help{font-size:11px;color:var(--pt-muted);line-height:1.45;margin:7px 0 0}.pttm-importbar{display:flex;gap:8px;margin-bottom:12px}.pttm-playerlist{grid-template-columns:1fr}.pttm-player{grid-template-columns:minmax(160px,1.5fr) 110px 80px 110px 110px 34px;align-items:end}.pttm-player>div small{display:block;font-size:10px;color:var(--pt-muted);font-weight:600;margin:0 0 4px}.pttm-daterow{display:grid;grid-template-columns:1fr 40px;gap:8px;margin:8px 0}.pttm-csvexample{white-space:pre;overflow:auto;background:#f5f8fa;border:1px solid var(--pt-line);border-radius:12px;padding:14px;color:#334b58}.pttm-kpis{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;margin-bottom:12px}.pttm-kpi{padding:12px;background:#f8fafb;border:1px solid var(--pt-line);border-radius:12px}.pttm-kpi small{display:block;color:var(--pt-muted);font-size:10px}.pttm-kpi b{font-size:18px}
@media(max-width:900px){.pttm-player{grid-template-columns:1fr 1fr 1fr}.pttm-player .pttm-iconbtn{align-self:end}.pttm-courts{grid-template-columns:repeat(4,1fr)}}@media(max-width:560px){.pttm-player{grid-template-columns:1fr 1fr}.pttm-player>div:first-child{grid-column:1/-1}.pttm-kpis{grid-template-columns:1fr 1fr}}

/* v1.2 interaction hierarchy */
.pttm-primary-tools{display:flex;gap:10px;align-items:stretch}.pttm-btn-settings,.pttm-btn-guide{min-height:48px;padding:11px 17px;border-radius:14px;font-weight:600;border:1px solid transparent;box-shadow:0 5px 15px rgba(40,80,105,.08)}.pttm-btn-settings{background:var(--pt-blue);color:#fff}.pttm-btn-guide{background:#fff;color:var(--pt-dark);border-color:#bcdff4}.pttm-btn-settings span,.pttm-btn-guide span{display:inline-grid;place-items:center;width:24px;height:24px;border-radius:50%;margin-right:5px;background:rgba(255,255,255,.18)}.pttm-btn-guide span{background:var(--pt-soft)}
.pttm-iconbtn[data-action="remove-player"]{background:#fff0f1!important;color:#d94f5e!important;border:1px solid #ffd2d7!important;font-weight:600}.pttm-iconbtn[data-action="remove-player"]:hover{background:var(--pt-red)!important;color:#fff!important;border-color:var(--pt-red)!important}
.pttm-btn-primary{box-shadow:0 5px 15px rgba(63,157,224,.18)}.pttm-controls>.pttm-btn-primary{min-height:48px;font-size:14px}.pttm-actions .pttm-btn{font-weight:600}.pttm-empty[hidden]{display:none!important}
.pttm-scheduler-note{margin-top:10px;padding:11px 12px;border-radius:12px;background:#f8fafb;border:1px solid var(--pt-line);font-size:11px;color:var(--pt-muted);line-height:1.5}
@media(max-width:820px){.pttm-primary-tools{width:100%}.pttm-primary-tools .pttm-btn{flex:1}}

/* v1.3 compact menu + mobile-first refinements */
.pttm-btn-danger{background:#fff0f1!important;color:#d94f5e!important;border:1px solid #ffd2d7!important}.pttm-btn-danger:hover{background:var(--pt-red)!important;color:#fff!important;border-color:var(--pt-red)!important}
.pttm-drawer-backdrop[hidden]{display:none!important}.pttm-drawer-backdrop{position:fixed;inset:0;z-index:2147481000;background:rgba(31,48,58,.38);backdrop-filter:blur(4px)}
.pttm-drawer{position:fixed;z-index:2147481100;top:0;right:0;width:min(390px,92vw);height:100dvh;background:#fff;box-shadow:-18px 0 55px rgba(25,45,60,.18);transform:translateX(105%);transition:transform .22s ease;display:flex;flex-direction:column}.pttm-drawer.is-open{transform:translateX(0)}
.pttm-drawer-head{display:flex;align-items:center;justify-content:space-between;padding:20px;border-bottom:1px solid var(--pt-line)}.pttm-drawer-head small{font-size:10px;letter-spacing:.12em;color:var(--pt-blue);font-weight:600}.pttm-drawer-head h3{margin:2px 0 0!important;font-size:22px!important}.pttm-drawer-body{padding:16px;overflow:auto;-webkit-overflow-scrolling:touch}
.pttm-menu-card{width:100%;display:grid;grid-template-columns:42px 1fr 18px;gap:10px;align-items:center;text-align:left;border:1px solid #cfe6f5;background:var(--pt-soft);border-radius:15px;padding:13px;color:var(--pt-text)}.pttm-menu-card b,.pttm-menu-card small{display:block}.pttm-menu-card small{margin-top:3px;color:var(--pt-muted);font-size:11px;line-height:1.35}.pttm-menu-card i{font-size:24px;color:var(--pt-blue);font-style:normal}.pttm-menu-icon{width:38px;height:38px;display:grid;place-items:center;border-radius:11px;background:#fff;color:var(--pt-blue);font-weight:600}
.pttm-menu-section{margin-top:14px;padding:14px;border:1px solid var(--pt-line);border-radius:15px;background:#fafcfd}.pttm-menu-section>label,.pttm-menu-section>b{display:block;margin:0 0 9px;font-size:12px}.pttm-menu-section ul{padding-left:18px;margin:8px 0 0;color:var(--pt-muted);font-size:11px;line-height:1.6}
html.pttm-menu-open,body.pttm-menu-open{overflow:hidden!important}
@media(max-width:680px){
 .pttm{font-size:14px}.pttm-head{gap:12px;margin-bottom:12px}.pttm-head h2{font-size:23px!important}.pttm-head p{font-size:13px}.pttm-primary-tools{width:100%}.pttm-btn-settings{width:100%;min-height:46px}
 .pttm-tabs{position:sticky;top:4px;z-index:20;margin-bottom:10px}.pttm-tabs button{min-height:44px}
 .pttm-card{padding:13px;border-radius:15px}.pttm-grid{gap:10px}.pttm-controls label{margin-top:12px}
 .pttm input,.pttm select,.pttm-btn{min-height:46px;font-size:16px}.pttm-btn{font-size:14px}
 .pttm-two{grid-template-columns:1fr}.pttm-courts{grid-template-columns:repeat(4,1fr);gap:7px}.pttm-courts button{min-height:44px}
 .pttm-segment button{min-height:42px;padding:8px 5px}.pttm-three{grid-template-columns:1fr}.pttm-three button{min-height:42px}
 .pttm-player{grid-template-columns:1fr 1fr;gap:7px;padding:10px}.pttm-player>div:first-child{grid-column:1/-1}.pttm-player .pttm-iconbtn{width:100%;min-height:42px;grid-column:1/-1}
 .pttm-importbar{display:grid;grid-template-columns:1fr 1fr}.pttm-cardhead{gap:9px}.pttm-cardhead .pttm-btn-primary{width:100%}
 .pttm-tablewrap{border-radius:11px;margin-left:-3px;margin-right:-3px}.pttm-table th,.pttm-table td{padding:9px 7px}.pttm-score{display:grid;grid-template-columns:repeat(3,max-content);gap:4px}.pttm-score>select{grid-column:1/-1;width:100%}
 .pttm-set input{width:38px!important;min-height:38px!important;font-size:16px!important}.pttm-diagnostics{gap:5px}.pttm-pill{font-size:10px;padding:6px 8px}
 .pttm-modal{align-items:flex-end;padding:0}.pttm-modalbox,.pttm-modal-wide,.pttm-modal-xl{width:100%;max-height:92dvh;border-radius:20px 20px 0 0;padding:22px 14px 18px}.pttm-x{width:42px;height:42px}
 .pttm-drawer{width:min(360px,94vw)}.pttm-drawer-head{padding:16px}.pttm-drawer-body{padding:12px}
}

/* v1.4: compact left toolbar, tactiekbord-style */
.pttm{position:relative}
.pttm-toolrail{position:fixed;left:14px;top:50%;transform:translateY(-50%);z-index:2147480900;width:50px;padding:7px 0;display:flex;flex-direction:column;gap:9px;align-items:center;border-radius:22px;background:rgba(245,247,248,.94);box-shadow:0 12px 38px rgba(35,60,75,.09);backdrop-filter:blur(8px)}
.pttm-toolbtn{position:relative;width:48px;height:48px;min-height:48px!important;padding:0!important;border:1px solid #edf1f3!important;border-radius:15px!important;background:#fff!important;color:#315064!important;display:grid!important;place-items:center!important;box-shadow:0 5px 14px rgba(40,67,80,.07)!important;overflow:visible}
.pttm-toolbtn:hover{transform:translateY(-1px);border-color:#cfe3ef!important;color:var(--pt-blue)!important}
.pttm-toolicon{font-size:20px;line-height:1;font-weight:500}.pttm-tool-label{position:absolute;left:58px;top:50%;transform:translateY(-50%);white-space:nowrap;padding:7px 9px;border-radius:8px;background:#263238;color:#fff;font-size:11px;opacity:0;pointer-events:none;transition:.15s}.pttm-toolbtn:hover .pttm-tool-label{opacity:1}
.pttm-tool-danger{background:#fff0f1!important;color:#d94f5e!important;border-color:#ffd2d7!important}.pttm-tool-danger:hover{background:var(--pt-red)!important;color:#fff!important;border-color:var(--pt-red)!important}
.pttm-settingsrail{position:fixed;z-index:2147480800;left:72px;top:50%;transform:translate(-18px,-50%);width:min(350px,calc(100vw - 95px));max-height:82dvh;overflow:hidden;background:#fff;border:1px solid var(--pt-line);border-radius:20px;box-shadow:0 18px 55px rgba(25,45,60,.16);opacity:0;visibility:hidden;pointer-events:none;transition:opacity .18s ease,transform .18s ease;display:flex;flex-direction:column}
.pttm-settingsrail.is-open{opacity:1;visibility:visible;pointer-events:auto;transform:translate(0,-50%)}
.pttm-settingsrail-head{display:flex;align-items:center;justify-content:space-between;padding:16px;border-bottom:1px solid var(--pt-line)}.pttm-settingsrail-head small{font-size:10px;letter-spacing:.12em;color:var(--pt-blue);font-weight:600}.pttm-settingsrail-head h3{font-size:20px!important;margin:2px 0 0!important}.pttm-settingsrail-body{padding:12px;overflow:auto;-webkit-overflow-scrolling:touch}
.pttm-toolbtn[data-action="toggle-menu"].is-active{background:var(--pt-soft)!important;color:var(--pt-blue)!important;border-color:#c5e3f6!important}
@media(max-width:760px){
 .pttm-toolrail{left:7px;top:auto;bottom:12px;transform:none;width:auto;max-width:calc(100vw - 14px);height:58px;flex-direction:row;padding:5px 7px;border-radius:18px;gap:7px}
 .pttm-toolbtn{width:46px;height:46px;min-height:46px!important;border-radius:13px!important}.pttm-tool-label{display:none}
 .pttm-settingsrail{left:7px;bottom:78px;top:auto;transform:translateY(14px);width:calc(100vw - 14px);max-height:65dvh;border-radius:18px}.pttm-settingsrail.is-open{transform:translateY(0)}
 .pttm{padding-bottom:72px}
}

/* v1.5: the real "Toernooi instellen" block is collapsed by default */
.pttm-grid{grid-template-columns:minmax(0,1fr)!important}
.pttm-controls[data-role="main-settings"]{display:none!important}
.pttm.is-settings-open .pttm-grid{grid-template-columns:minmax(260px,320px) minmax(0,1fr)!important}
.pttm.is-settings-open .pttm-controls[data-role="main-settings"]{display:block!important}
.pttm-toolbtn[data-action="toggle-menu"].is-active{background:var(--pt-soft)!important;color:var(--pt-blue)!important;border-color:#c5e3f6!important}

/* remove obsolete v1.4 flyout visually even if theme/cache leaves a stale node */
.pttm-settingsrail{display:none!important}

@media(max-width:820px){
 .pttm.is-settings-open .pttm-grid{grid-template-columns:1fr!important}
 .pttm.is-settings-open .pttm-controls[data-role="main-settings"]{display:block!important}
 .pttm-controls[data-role="main-settings"]{order:-1}
}

/* v1.6: full-width workspace + overlay settings */
.pttm-grid,.pttm.is-settings-open .pttm-grid{grid-template-columns:minmax(0,1fr)!important;gap:0!important}
.pttm-work{width:100%!important;min-width:0}
.pttm-controls[data-role="main-settings"]{display:block!important;position:fixed!important;z-index:2147480850;left:76px;top:50%;transform:translate(-16px,-50%);width:min(320px,calc(100vw - 100px));max-height:88dvh;overflow:auto;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .18s ease,transform .18s ease;box-shadow:0 22px 65px rgba(25,45,60,.20)!important}
.pttm.is-settings-open .pttm-controls[data-role="main-settings"]{display:block!important;opacity:1;visibility:visible;pointer-events:auto;transform:translate(0,-50%)}
.pttm-toolrail{left:8px!important}
.pttm{width:100%!important;max-width:none!important;margin-left:0!important;margin-right:0!important}
.pttm-panel,.pttm-card,.pttm-work{max-width:none!important}

/* redesigned guide */
.pttm-guidebox{width:min(940px,96vw)!important;max-height:92dvh!important;padding:0!important;overflow:hidden!important}
.pttm-guidehero{display:flex;gap:16px;align-items:center;padding:25px 28px 20px;background:linear-gradient(135deg,#eaf5fd,#fff);border-bottom:1px solid var(--pt-line)}
.pttm-guidehero-icon{width:52px;height:52px;flex:0 0 52px;display:grid;place-items:center;border-radius:16px;background:var(--pt-blue);color:#fff;font-size:25px;font-weight:600;box-shadow:0 8px 22px rgba(63,157,224,.22)}
.pttm-guidehero span{font-size:10px;letter-spacing:.13em;color:var(--pt-blue);font-weight:600}.pttm-guidehero h2{margin:3px 0 5px!important;font-size:25px!important}.pttm-guidehero p{margin:0;color:var(--pt-muted);line-height:1.45}
.pttm-guidequick{display:grid;grid-template-columns:repeat(5,1fr);gap:7px;padding:12px 28px;border-bottom:1px solid var(--pt-line);background:#fff}
.pttm-guidequick button{border:1px solid var(--pt-line);background:#fafcfd;border-radius:11px;padding:8px 7px;color:var(--pt-text)}.pttm-guidequick b{display:block;color:var(--pt-blue);font-size:10px}.pttm-guidequick span{font-size:11px;font-weight:600}
.pttm-guidecontent{padding:8px 28px 20px;overflow:auto;max-height:58dvh;scroll-behavior:smooth}
.pttm-guidecontent section{display:grid;grid-template-columns:42px 1fr;gap:14px;padding:20px 0;border-bottom:1px solid #edf1f3}.pttm-guidecontent section:last-child{border-bottom:0}
.pttm-stepno{width:38px;height:38px;display:grid;place-items:center;border-radius:12px;background:var(--pt-soft);color:var(--pt-blue);font-weight:600}
.pttm-guidecontent h3{margin:1px 0 7px!important;font-size:17px!important}.pttm-guidecontent p{margin:0 0 10px;color:#65747c;line-height:1.6}
.pttm-guide-tip{display:grid;gap:3px;padding:12px 14px;border-radius:12px;background:#f3f9fd;border-left:3px solid var(--pt-blue)}.pttm-guide-tip b{font-size:12px}.pttm-guide-tip span{font-size:11px;color:var(--pt-muted);line-height:1.5}
.pttm-guide-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.pttm-guide-grid>div{padding:11px;border:1px solid var(--pt-line);border-radius:11px;background:#fafcfd}.pttm-guide-grid b,.pttm-guide-grid span{display:block}.pttm-guide-grid b{font-size:12px}.pttm-guide-grid span{font-size:11px;color:var(--pt-muted);margin-top:3px;line-height:1.4}
.pttm-rulelist{list-style:none!important;padding:0!important;margin:10px 0!important;display:grid;grid-template-columns:1fr 1fr;gap:7px}.pttm-rulelist li{display:flex;gap:8px;padding:9px 10px;border-radius:10px;background:#f8fafb;color:#60717c;font-size:11px;line-height:1.4}.pttm-rulelist i{font-style:normal;color:var(--pt-green);font-weight:600}
.pttm-guide-score{display:flex;gap:5px;align-items:center;margin:10px 0 12px}.pttm-guide-score span{display:grid;place-items:center;width:34px;height:34px;border-radius:9px;background:var(--pt-soft);color:var(--pt-dark);font-weight:600}.pttm-guide-score em{font-style:normal;color:var(--pt-muted)}
.pttm-guidefooter{display:flex;align-items:center;justify-content:space-between;gap:15px;padding:13px 28px;border-top:1px solid var(--pt-line);background:#fafcfd}.pttm-guidefooter span{font-size:11px;color:var(--pt-muted)}
@media(max-width:760px){
 .pttm-controls[data-role="main-settings"]{left:7px;right:7px;bottom:78px;top:auto;transform:translateY(14px);width:auto;max-height:72dvh;border-radius:18px!important}
 .pttm.is-settings-open .pttm-controls[data-role="main-settings"]{transform:translateY(0)}
 .pttm-guidebox{width:100%!important;max-height:94dvh!important;border-radius:20px 20px 0 0!important}
 .pttm-guidehero{padding:20px 15px 15px}.pttm-guidehero-icon{width:44px;height:44px;flex-basis:44px;border-radius:13px}.pttm-guidehero h2{font-size:20px!important}
 .pttm-guidequick{grid-template-columns:repeat(5,minmax(64px,1fr));overflow-x:auto;padding:9px 14px}.pttm-guidequick button{min-height:52px}
 .pttm-guidecontent{padding:4px 14px 15px;max-height:62dvh}.pttm-guidecontent section{grid-template-columns:34px 1fr;gap:9px;padding:16px 0}.pttm-stepno{width:32px;height:32px;border-radius:9px}
 .pttm-guide-grid,.pttm-rulelist{grid-template-columns:1fr}.pttm-guidefooter{padding:11px 14px;flex-direction:column;align-items:stretch}.pttm-guidefooter .pttm-btn{width:100%}
}

/* v1.7: use the full viewport width, toolbar overlays instead of reserving page space */
.pttm{
  width:100vw!important;
  max-width:none!important;
  position:relative!important;
  left:50%!important;
  right:50%!important;
  margin-left:-50vw!important;
  margin-right:-50vw!important;
  padding:0 18px 0 72px!important;
}
.pttm-head,
.pttm-tabs,
.pttm-panel{
  width:100%!important;
  max-width:none!important;
  margin-left:0!important;
  margin-right:0!important;
}
.pttm-grid,
.pttm-work,
.pttm-card{
  width:100%!important;
  max-width:none!important;
}
.pttm-grid{display:block!important}
.pttm-work{margin:0!important}
.pttm-toolrail{left:8px!important}
@media(max-width:760px){
 .pttm{
   width:100vw!important;
   left:50%!important;
   right:50%!important;
   margin-left:-50vw!important;
   margin-right:-50vw!important;
   padding:0 10px 72px!important;
 }
 .pttm-head,.pttm-tabs,.pttm-panel,.pttm-grid,.pttm-work{width:100%!important;max-width:none!important}
}

/* v1.8: compact settings overlay, always above Avada header, invisible scrollbars */
.pttm-controls[data-role="main-settings"]{
  position:fixed!important;
  z-index:2147483646!important;
  left:72px!important;
  top:76px!important;
  bottom:18px!important;
  transform:translateX(-14px)!important;
  width:320px!important;
  max-width:calc(100vw - 92px)!important;
  height:auto!important;
  max-height:none!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
  overscroll-behavior:contain;
}
.pttm-controls[data-role="main-settings"]::-webkit-scrollbar{display:none!important;width:0!important;height:0!important}
.pttm.is-settings-open .pttm-controls[data-role="main-settings"]{
  transform:translateX(0)!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
}
.pttm-toolrail{
  z-index:2147483647!important;
}
.pttm-modal{
  z-index:2147483647!important;
}
.pttm-modalbox,.pttm-guidebox{
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.pttm-modalbox::-webkit-scrollbar,.pttm-guidebox::-webkit-scrollbar,
.pttm-guidecontent::-webkit-scrollbar,.pttm-drawer-body::-webkit-scrollbar{
  display:none!important;width:0!important;height:0!important
}
.pttm-guidecontent,.pttm-modalbox,.pttm-guidebox{
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
@media(max-width:760px){
 .pttm-controls[data-role="main-settings"]{
   left:8px!important;
   right:8px!important;
   top:72px!important;
   bottom:78px!important;
   width:auto!important;
   max-width:none!important;
   transform:translateY(12px)!important;
   border-radius:18px!important;
 }
 .pttm.is-settings-open .pttm-controls[data-role="main-settings"]{transform:translateY(0)!important}
}

/* v1.9: settings is a true top-layer panel */
.pttm-controls[data-role="main-settings"]{
  position:fixed!important;
  z-index:2147483647!important;
  left:72px!important;
  top:18px!important;
  bottom:18px!important;
  width:320px!important;
  max-width:calc(100vw - 92px)!important;
  margin:0!important;
  padding:0 18px 18px!important;
  border-radius:20px!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
  overscroll-behavior:contain!important;
}
.admin-bar .pttm-controls[data-role="main-settings"]{top:40px!important}
.pttm-controls[data-role="main-settings"]::-webkit-scrollbar,
.pttm-controls[data-role="main-settings"] *::-webkit-scrollbar{display:none!important;width:0!important;height:0!important}
.pttm-settings-head{
  position:sticky;top:0;z-index:5;
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  margin:0 -18px 10px;padding:16px 14px 12px 18px;
  background:rgba(255,255,255,.97);backdrop-filter:blur(8px);
  border-bottom:1px solid #edf1f3;border-radius:20px 20px 0 0
}
.pttm-settings-head small{display:block;font-size:9px;letter-spacing:.13em;color:var(--pt-blue);font-weight:600;margin-bottom:2px}
.pttm-settings-head h3{margin:0!important;font-size:18px!important}
.pttm-settings-close{
  flex:0 0 38px;width:38px;height:38px;min-height:38px!important;padding:0!important;
  display:grid!important;place-items:center;border:1px solid #e6ecef!important;border-radius:12px!important;
  background:#f7f9fa!important;color:#60717c!important;font-size:25px!important;line-height:1!important;cursor:pointer
}
.pttm-settings-close:hover{background:#fff0f1!important;color:#d94f5e!important;border-color:#ffd2d7!important}
.pttm-modal{position:fixed!important;inset:0!important;z-index:2147483647!important}
.pttm-guidebox{position:relative!important;z-index:2147483647!important}
.pttm-guidecontent,.pttm-modalbox,.pttm-tablewrap{
  scrollbar-width:none!important;-ms-overflow-style:none!important
}
.pttm-guidecontent::-webkit-scrollbar,.pttm-modalbox::-webkit-scrollbar,.pttm-tablewrap::-webkit-scrollbar{
  display:none!important;width:0!important;height:0!important
}
@media(max-width:760px){
 .pttm-controls[data-role="main-settings"]{
   left:8px!important;right:8px!important;top:8px!important;bottom:76px!important;
   width:auto!important;max-width:none!important;padding:0 14px 16px!important
 }
 .admin-bar .pttm-controls[data-role="main-settings"]{top:38px!important}
 .pttm-settings-head{margin:0 -14px 10px;padding:13px 10px 11px 14px}
}

/* v2.0: follow the normal website content width instead of viewport/full-bleed */
.pttm{
  width:100%!important;
  max-width:100%!important;
  position:relative!important;
  left:auto!important;
  right:auto!important;
  margin-left:0!important;
  margin-right:0!important;
  padding:0!important;
  box-sizing:border-box!important;
}
.pttm-head,
.pttm-tabs,
.pttm-panel,
.pttm-grid,
.pttm-work{
  width:100%!important;
  max-width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
  box-sizing:border-box!important;
}
.pttm-grid{display:block!important}
.pttm-work{margin:0!important}
.pttm-toolrail{
  left:max(8px,calc((100vw - min(100vw, var(--site_width, 1200px)))/2 + 8px))!important;
}
@media(max-width:760px){
 .pttm{
   width:100%!important;
   max-width:100%!important;
   left:auto!important;
   right:auto!important;
   margin-left:0!important;
   margin-right:0!important;
   padding:0 8px 72px!important;
 }
 .pttm-toolrail{left:7px!important}
}

/* v2.1: toolbar beside the site-width content; settings may overlay it */
.pttm{
  --pt-toolbar-space:64px;
  overflow:visible!important;
}
.pttm-head,
.pttm-tabs,
.pttm-panel{
  width:calc(100% - var(--pt-toolbar-space))!important;
  max-width:calc(100% - var(--pt-toolbar-space))!important;
  margin-left:var(--pt-toolbar-space)!important;
  margin-right:0!important;
}
.pttm-toolrail{
  position:absolute!important;
  left:0!important;
  top:244px!important;
  transform:none!important;
  z-index:50!important;
  width:50px!important;
}
.pttm-controls[data-role="main-settings"]{
  position:fixed!important;
  z-index:2147483647!important;
  left:max(12px,calc((100vw - 1200px)/2 + 12px))!important;
  top:18px!important;
  bottom:18px!important;
  width:320px!important;
  max-width:calc(100vw - 24px)!important;
}
.admin-bar .pttm-controls[data-role="main-settings"]{top:40px!important}

/* Close button must always remain visible and clickable */
.pttm-settings-head{
  position:sticky!important;
  top:0!important;
  z-index:2147483647!important;
}
.pttm-settings-close{
  position:relative!important;
  z-index:2147483647!important;
  display:grid!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
}
.pttm-settings-close::after{content:"";position:absolute;inset:-6px}

/* Never let decorative/site layers cover the plugin controls */
.pttm.is-settings-open .pttm-controls[data-role="main-settings"],
.pttm.is-settings-open .pttm-settings-head,
.pttm.is-settings-open .pttm-settings-close{pointer-events:auto!important}

@media(max-width:1240px){
 .pttm-controls[data-role="main-settings"]{left:12px!important}
}
@media(max-width:760px){
 .pttm{--pt-toolbar-space:0px;padding:0 8px 72px!important}
 .pttm-head,.pttm-tabs,.pttm-panel{width:100%!important;max-width:100%!important;margin-left:0!important}
 .pttm-toolrail{
   position:fixed!important;left:7px!important;bottom:12px!important;top:auto!important;
   transform:none!important;width:auto!important;z-index:2147483646!important
 }
 .pttm-controls[data-role="main-settings"]{
   left:8px!important;right:8px!important;top:8px!important;bottom:78px!important;width:auto!important;max-width:none!important
 }
 .admin-bar .pttm-controls[data-role="main-settings"]{top:38px!important}
}

/* v2.2: both overlays deliberately start BELOW the website header */
:root{--pttm-overlay-top:120px}
.admin-bar{--pttm-overlay-top:152px}

/* Settings panel */
.pttm-controls[data-role="main-settings"]{
  top:var(--pttm-overlay-top)!important;
  bottom:18px!important;
  z-index:999999!important;
}
.pttm-settings-head{
  position:sticky!important;
  top:0!important;
  z-index:10!important;
  min-height:58px!important;
  background:#fff!important;
}
.pttm-settings-close{
  position:absolute!important;
  right:12px!important;
  top:10px!important;
  width:38px!important;
  height:38px!important;
  display:grid!important;
  place-items:center!important;
  z-index:20!important;
  pointer-events:auto!important;
  cursor:pointer!important;
}

/* Guide and all other modal popups: leave a clear header-safe area above */
.pttm-modal{
  position:fixed!important;
  inset:var(--pttm-overlay-top) 0 0 0!important;
  height:calc(100dvh - var(--pttm-overlay-top))!important;
  padding:16px!important;
  align-items:flex-start!important;
  z-index:999998!important;
  overflow:hidden!important;
}
.pttm-modalbox,.pttm-guidebox{
  position:relative!important;
  margin:0 auto!important;
  max-height:calc(100dvh - var(--pttm-overlay-top) - 32px)!important;
  overflow:auto!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.pttm-modalbox::-webkit-scrollbar,.pttm-guidebox::-webkit-scrollbar{display:none!important;width:0!important;height:0!important}
.pttm-guidebox>.pttm-x{
  position:absolute!important;
  right:14px!important;
  top:14px!important;
  width:40px!important;
  height:40px!important;
  display:grid!important;
  place-items:center!important;
  z-index:100!important;
  background:#fff!important;
  border:1px solid #e5ebee!important;
  border-radius:12px!important;
  box-shadow:0 5px 14px rgba(30,55,70,.10)!important;
  color:#60717c!important;
  font-size:26px!important;
  pointer-events:auto!important;
  cursor:pointer!important;
}
.pttm-guidebox>.pttm-x:hover{background:#fff0f1!important;color:#d94f5e!important;border-color:#ffd2d7!important}

@media(max-width:760px){
 :root{--pttm-overlay-top:92px}
 .admin-bar{--pttm-overlay-top:124px}
 .pttm-controls[data-role="main-settings"]{
   top:var(--pttm-overlay-top)!important;
   bottom:78px!important;
 }
 .pttm-modal{
   inset:var(--pttm-overlay-top) 0 0!important;
   height:calc(100dvh - var(--pttm-overlay-top))!important;
   padding:8px 8px 0!important;
 }
 .pttm-modalbox,.pttm-guidebox{
   max-height:calc(100dvh - var(--pttm-overlay-top) - 8px)!important;
   border-radius:18px 18px 0 0!important;
 }
}

/* v2.3 definitive close controls.
   The X buttons are viewport-positioned, so they cannot scroll out of view. */
.pttm-floating-close{
  position:fixed!important;
  left:350px!important;
  top:130px!important;
  z-index:2147483647!important;
  width:42px!important;
  height:42px!important;
  min-width:42px!important;
  min-height:42px!important;
  margin:0!important;
  padding:0!important;
  display:grid!important;
  place-items:center!important;
  border:1px solid #dfe7eb!important;
  border-radius:13px!important;
  background:#fff!important;
  color:#455a64!important;
  box-shadow:0 7px 22px rgba(27,48,61,.18)!important;
  font:400 28px/1 Arial,sans-serif!important;
  cursor:pointer!important;
  pointer-events:auto!important;
  visibility:visible!important;
  opacity:1!important;
}
.admin-bar .pttm-floating-close{top:162px!important}
.pttm-floating-close:hover{background:#fff0f1!important;color:#d94f5e!important;border-color:#ffcbd1!important}

/* Hide the older duplicate close in the settings heading; the fixed X above is authoritative. */
.pttm-settings-close{display:none!important}

/* Guide: its close control is also fixed relative to the viewport, below the header. */
.pttm-guide-floating-close{
  position:fixed!important;
  top:132px!important;
  right:max(28px,calc((100vw - 940px)/2 + 20px))!important;
  z-index:2147483647!important;
  width:42px!important;
  height:42px!important;
  min-width:42px!important;
  min-height:42px!important;
  display:grid!important;
  place-items:center!important;
  background:#fff!important;
  color:#455a64!important;
  border:1px solid #dfe7eb!important;
  border-radius:13px!important;
  box-shadow:0 7px 22px rgba(27,48,61,.18)!important;
  pointer-events:auto!important;
  visibility:visible!important;
  opacity:1!important;
  cursor:pointer!important;
}
.admin-bar .pttm-guide-floating-close{top:164px!important}

/* The settings body starts below its fixed close control and remains independently scrollable. */
.pttm-controls[data-role="main-settings"]{
  top:120px!important;
  padding-top:62px!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.admin-bar .pttm-controls[data-role="main-settings"]{top:152px!important}
.pttm-controls[data-role="main-settings"]::-webkit-scrollbar{display:none!important}

/* Don't show a redundant sticky settings header; title stays, old close is hidden. */
.pttm-settings-head{position:static!important;margin-top:-46px!important;padding-top:0!important;background:transparent!important}

/* Guide remains below site header and scrolls internally without a visible scrollbar. */
.pttm-modal[data-modal="guide"]{
  top:120px!important;
  bottom:0!important;
  height:auto!important;
}
.admin-bar .pttm-modal[data-modal="guide"]{top:152px!important}
.pttm-guidecontent{scrollbar-width:none!important;-ms-overflow-style:none!important}
.pttm-guidecontent::-webkit-scrollbar{display:none!important}

@media(max-width:760px){
 .pttm-floating-close{
   left:auto!important;
   right:18px!important;
   top:102px!important;
 }
 .admin-bar .pttm-floating-close{top:134px!important}
 .pttm-guide-floating-close{
   right:18px!important;
   top:102px!important;
 }
 .admin-bar .pttm-guide-floating-close{top:134px!important}
 .pttm-controls[data-role="main-settings"]{
   top:92px!important;
   padding-top:62px!important;
 }
 .admin-bar .pttm-controls[data-role="main-settings"]{top:124px!important}
 .pttm-modal[data-modal="guide"]{top:92px!important}
 .admin-bar .pttm-modal[data-modal="guide"]{top:124px!important}
}

/* v2.4: visible in-panel close button + transparent toolbar background */

/* The toolbar itself no longer has a grey capsule/background. */
.pttm-toolrail{
  background:transparent!important;
  box-shadow:none!important;
  backdrop-filter:none!important;
  -webkit-backdrop-filter:none!important;
  border:0!important;
}

/* Keep the individual icon buttons white, but no grey block around them. */
.pttm-toolbtn{
  background:#fff!important;
}

/* Put the settings close button INSIDE the visible top-right corner of the panel. */
.pttm-floating-close{
  position:absolute!important;
  left:auto!important;
  right:12px!important;
  top:12px!important;
  z-index:2147483647!important;
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  min-height:40px!important;
  display:grid!important;
  place-items:center!important;
  margin:0!important;
  padding:0 0 3px!important;
  background:#fff!important;
  color:#455a64!important;
  border:1px solid #dfe7eb!important;
  border-radius:12px!important;
  box-shadow:0 4px 12px rgba(27,48,61,.10)!important;
  font:400 27px/1 Arial,sans-serif!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  cursor:pointer!important;
}

/* Reserve room for X and make the heading itself normal/stable. */
.pttm-controls[data-role="main-settings"]{
  position:fixed!important;
  padding-top:0!important;
}
.pttm-settings-head{
  position:sticky!important;
  top:0!important;
  z-index:100!important;
  min-height:68px!important;
  margin:0 -18px 10px!important;
  padding:16px 64px 12px 18px!important;
  background:#fff!important;
  border-bottom:1px solid #edf1f3!important;
  border-radius:20px 20px 0 0!important;
}
.pttm-settings-close{display:none!important}

/* On mobile the X stays inside the same panel corner. */
@media(max-width:760px){
 .pttm-floating-close{
   position:absolute!important;
   right:10px!important;
   top:10px!important;
 }
 .pttm-settings-head{
   margin:0 -14px 10px!important;
   padding:14px 58px 11px 14px!important;
 }
}

/* v2.5: close controls belong to the popup header, not the scroll/body area */
.pttm-controls[data-role="main-settings"]{
  position:fixed!important;
}
.pttm-settings-head{
  position:sticky!important;
  top:0!important;
  z-index:500!important;
  min-height:64px!important;
  margin:0 -18px 10px!important;
  padding:15px 64px 12px 18px!important;
  background:#fff!important;
  border-bottom:1px solid #edf1f3!important;
  border-radius:20px 20px 0 0!important;
}
.pttm-floating-close{
  position:fixed!important;
  /* panel left + panel width - close width - inset */
  left:calc(max(12px, (100vw - 1200px)/2 + 12px) + 320px - 52px)!important;
  right:auto!important;
  top:calc(var(--pttm-overlay-top) + 11px)!important;
  z-index:2147483647!important;
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  min-height:40px!important;
  margin:0!important;
  padding:0 0 2px!important;
}
.admin-bar .pttm-floating-close{top:calc(var(--pttm-overlay-top) + 11px)!important}

/* Guide X is pinned to the actual top-right of the guide card. */
.pttm-guidebox{
  position:relative!important;
}
.pttm-guide-floating-close{
  position:absolute!important;
  top:14px!important;
  right:14px!important;
  left:auto!important;
  z-index:2147483647!important;
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  min-height:40px!important;
  margin:0!important;
  padding:0 0 2px!important;
}
.admin-bar .pttm-guide-floating-close{top:14px!important}

/* Make sure neither close button inherits a theme transform/float. */
.pttm-floating-close,.pttm-guide-floating-close{
  transform:none!important;
  float:none!important;
  clear:none!important;
  box-sizing:border-box!important;
}

@media(max-width:1240px){
 .pttm-floating-close{
   left:280px!important; /* 12 + 320 - 52 */
 }
}
@media(max-width:760px){
 .pttm-floating-close{
   position:fixed!important;
   left:auto!important;
   right:18px!important;
   top:calc(var(--pttm-overlay-top) + 10px)!important;
 }
 .admin-bar .pttm-floating-close{top:calc(var(--pttm-overlay-top) + 10px)!important}
 .pttm-guide-floating-close{
   position:absolute!important;
   right:12px!important;
   top:12px!important;
 }
}

/* v2.6: definitive structural fix — X lives inside the settings header */
.pttm-floating-close{display:none!important}

.pttm-settings-head{
  position:sticky!important;
  top:0!important;
  z-index:9999!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:12px!important;
  min-height:68px!important;
  margin:0 -18px 10px!important;
  padding:14px 12px 12px 18px!important;
  background:#fff!important;
  border-bottom:1px solid #edf1f3!important;
  border-radius:20px 20px 0 0!important;
  overflow:visible!important;
}

.pttm-settings-head > div:first-child{
  min-width:0!important;
  padding-right:8px!important;
}

.pttm-settings-close{
  position:relative!important;
  inset:auto!important;
  top:auto!important;
  right:auto!important;
  left:auto!important;
  flex:0 0 40px!important;
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  min-height:40px!important;
  margin:0!important;
  padding:0 0 2px!important;
  display:grid!important;
  place-items:center!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  transform:none!important;
  float:none!important;
  border:1px solid #dfe7eb!important;
  border-radius:12px!important;
  background:#fff!important;
  color:#455a64!important;
  box-shadow:0 4px 12px rgba(27,48,61,.10)!important;
  font:400 27px/1 Arial,sans-serif!important;
  cursor:pointer!important;
  z-index:10000!important;
}

.pttm-settings-close:hover{
  background:#fff0f1!important;
  color:#d94f5e!important;
  border-color:#ffcbd1!important;
}

/* Undo the old extra top padding that was only needed for the floating X. */
.pttm-controls[data-role="main-settings"]{
  padding-top:0!important;
}

@media(max-width:760px){
 .pttm-settings-head{
   margin:0 -14px 10px!important;
   padding:12px 10px 11px 14px!important;
 }
 .pttm-settings-close{
   flex-basis:40px!important;
   width:40px!important;
   height:40px!important;
 }
}


/* ==========================================================
   v2.7.0 — TOP LAYER POPUPS
   Uses the browser Popover top layer. This is above Avada's
   header regardless of parent stacking contexts / transforms.
   ========================================================== */

/* Settings: native top-layer panel, while remaining inside .pttm in DOM. */
.pttm-controls[data-role="main-settings"][popover]{
  margin:0!important;
  inset:auto!important;
  position:fixed!important;
  left:72px!important;
  top:18px!important;
  bottom:18px!important;
  width:320px!important;
  max-width:calc(100vw - 92px)!important;
  max-height:calc(100dvh - 36px)!important;
  padding:0 18px 18px!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  border:1px solid var(--pt-line)!important;
  border-radius:20px!important;
  background:#fff!important;
  box-shadow:0 24px 70px rgba(24,48,62,.25)!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.pttm-controls[data-role="main-settings"][popover]::-webkit-scrollbar{display:none!important}
.pttm-controls[data-role="main-settings"][popover]:popover-open{
  display:block!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  transform:none!important;
}
.pttm-controls[data-role="main-settings"][popover]::backdrop{
  background:transparent!important;
}

/* Header + close button always visible at the top of settings. */
.pttm-controls[data-role="main-settings"][popover] .pttm-settings-head{
  position:sticky!important;
  top:0!important;
  z-index:10!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  min-height:68px!important;
  margin:0 -18px 10px!important;
  padding:14px 12px 12px 18px!important;
  background:#fff!important;
  border-bottom:1px solid #edf1f3!important;
  border-radius:20px 20px 0 0!important;
}
.pttm-controls[data-role="main-settings"][popover] .pttm-settings-close{
  position:static!important;
  display:grid!important;
  place-items:center!important;
  flex:0 0 40px!important;
  width:40px!important;
  height:40px!important;
  min-width:40px!important;
  min-height:40px!important;
  margin:0!important;
  padding:0 0 2px!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  transform:none!important;
  border:1px solid #dfe7eb!important;
  border-radius:12px!important;
  background:#fff!important;
  color:#455a64!important;
  box-shadow:0 4px 12px rgba(27,48,61,.10)!important;
  font:400 27px/1 Arial,sans-serif!important;
}

/* Guide + other modals: full viewport top-layer backdrop. */
.pttm-modal[popover]{
  margin:0!important;
  inset:0!important;
  width:100vw!important;
  height:100dvh!important;
  max-width:none!important;
  max-height:none!important;
  padding:20px!important;
  border:0!important;
  background:rgba(31,48,58,.48)!important;
  backdrop-filter:blur(6px)!important;
  overflow:hidden!important;
  align-items:center!important;
  justify-content:center!important;
}
.pttm-modal[popover]:popover-open{display:flex!important}
.pttm-modal[popover]::backdrop{background:transparent!important}
.pttm-modal[popover] .pttm-modalbox{
  position:relative!important;
  max-height:calc(100dvh - 40px)!important;
  scrollbar-width:none!important;
  -ms-overflow-style:none!important;
}
.pttm-modal[popover] .pttm-modalbox::-webkit-scrollbar{display:none!important}
.pttm-guide-modal[popover] .pttm-guide-floating-close{
  position:absolute!important;
  top:14px!important;
  right:14px!important;
  display:grid!important;
  visibility:visible!important;
  opacity:1!important;
  pointer-events:auto!important;
  z-index:50!important;
}

/* Mobile: still ABOVE the header, but inset so the complete popup header + X is visible. */
@media(max-width:760px){
 .pttm-controls[data-role="main-settings"][popover]{
   left:8px!important;
   right:8px!important;
   top:8px!important;
   bottom:76px!important;
   width:auto!important;
   max-width:none!important;
   max-height:calc(100dvh - 84px)!important;
   border-radius:18px!important;
 }
 .pttm-modal[popover]{
   padding:8px 8px 76px!important;
   align-items:flex-start!important;
 }
 .pttm-modal[popover] .pttm-modalbox{
   width:100%!important;
   max-width:none!important;
   max-height:calc(100dvh - 84px)!important;
   margin:0!important;
   border-radius:18px!important;
 }
}

/* v2.9.0 — alleen voorwaarden/verantwoordelijkheid; bestaande layout verder intact */
.pttm-terms-note{margin:14px 2px 0!important;padding:0!important;color:#879198!important;font-size:11px!important;line-height:1.45!important;font-weight:400!important;text-align:center!important}
.pttm-terms-link{appearance:none!important;border:0!important;background:transparent!important;padding:0!important;margin:0!important;color:#6f7e87!important;font:inherit!important;font-weight:600!important;text-decoration:underline!important;text-underline-offset:2px!important;cursor:pointer!important}
.pttm-terms-link:hover{color:var(--pt-blue)!important}
.pttm-guide-legal strong{color:var(--pt-text)!important}


/* v5.1.0 — e-mailtoegang Instellingen. Geïsoleerd van de bestaande Tournament Maker UI. */
.pttm-access-gate{position:fixed;inset:0;box-sizing:border-box;width:100vw;height:100dvh;max-width:none;max-height:none;margin:0;border:0;padding:24px;background:rgba(28,43,52,.48);backdrop-filter:blur(7px);-webkit-backdrop-filter:blur(7px);align-items:center;justify-content:center;overflow:auto}
.pttm-access-gate:popover-open{display:flex}
.pttm-access-card{box-sizing:border-box;width:min(460px,calc(100vw - 32px));background:#fff;border:1px solid #dce8ef;border-radius:24px;box-shadow:0 24px 70px rgba(25,58,78,.24);padding:30px;position:relative;color:#263238;font-family:Inter,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
.pttm-access-close{position:absolute;right:16px;top:16px;width:38px;height:38px;border:0!important;border-radius:50%!important;background:#f3f6f8!important;color:#64727a!important;display:grid;place-items:center;cursor:pointer;font:400 24px/1 Inter,system-ui,sans-serif!important;padding:0!important;margin:0!important}
.pttm-access-icon{width:52px;height:52px;border-radius:16px;background:#eaf5fd;color:#3f9de0;display:grid;place-items:center;font-size:25px;margin-bottom:18px}
.pttm-access-card h2{font:600 24px/1.2 Inter,system-ui,sans-serif!important;color:#263238!important;margin:0 44px 9px 0!important}
.pttm-access-card>p{font:400 14px/1.6 Inter,system-ui,sans-serif!important;color:#7d878d!important;margin:0 0 20px!important}
.pttm-access-form{margin:0!important}
.pttm-access-fields{display:flex;gap:10px;padding:8px;background:#f5f6f7;border:1px solid #e2e8ec;border-radius:16px}
.pttm-access-fields input[type=email]{box-sizing:border-box;min-width:0;flex:1;height:auto!important;border:0!important;outline:0!important;box-shadow:none!important;background:transparent!important;padding:11px 10px!important;color:#263238!important;font:400 14px/1.4 Inter,system-ui,sans-serif!important;margin:0!important}
.pttm-access-submit{border:0!important;border-radius:11px!important;background:#3f9de0!important;color:#fff!important;font:600 14px/1.2 Inter,system-ui,sans-serif!important;padding:12px 17px!important;cursor:pointer;white-space:nowrap;margin:0!important;min-height:42px}
.pttm-access-submit:hover{background:#267fbf!important}.pttm-access-submit:disabled{opacity:.65;cursor:wait}
.pttm-access-note{font-size:11px!important;margin:12px 2px 0!important;color:#8a969c!important;line-height:1.45!important}
.pttm-access-message{display:none;margin:12px 0 0;padding:10px 12px;border-radius:11px;font:600 12px/1.4 Inter,system-ui,sans-serif}
.pttm-access-message.error{display:block;background:#fff0f1;color:#b84f59}.pttm-access-message.success{display:block;background:#eef9f3;color:#278056}
.pttm-access-hp{position:absolute!important;left:-99999px!important;width:1px!important;height:1px!important;opacity:0!important}
@media(max-width:560px){.pttm-access-gate{padding:14px}.pttm-access-card{padding:24px 18px 20px;border-radius:20px}.pttm-access-fields{flex-direction:column}.pttm-access-submit{width:100%}}

.pttm-access-wide{width:100%!important;margin-top:8px!important}
.pttm-access-secondary{width:100%;border:0!important;background:transparent!important;color:#3f9de0!important;font:600 13px/1.3 Inter,system-ui,sans-serif!important;padding:12px!important;margin:5px 0 0!important;cursor:pointer}
.pttm-access-wait>p{font:400 14px/1.6 Inter,system-ui,sans-serif!important;color:#7d878d!important;margin:0 0 18px!important}
.pttm-access-wait h2{font:600 24px/1.2 Inter,system-ui,sans-serif!important;color:#263238!important;margin:0 44px 9px 0!important}

/* v5.3 mobile match cards */
@media(max-width:760px){
.pttm [data-role="schedule-wrap"]{overflow:visible!important;border:0!important}
.pttm [data-role="schedule-wrap"] .pttm-table{display:block!important;min-width:0!important;width:100%!important}
.pttm [data-role="schedule-wrap"] .pttm-table thead{display:none!important}
.pttm [data-role="schedule-wrap"] .pttm-table tbody{display:grid!important;gap:12px!important}
.pttm [data-role="schedule-wrap"] .pttm-table tr{display:grid!important;grid-template-columns:1fr 1fr!important;gap:6px 12px!important;padding:14px!important;border:1px solid #dbe7ef!important;border-radius:14px!important;background:#fff!important}
.pttm [data-role="schedule-wrap"] .pttm-table td{display:block!important;min-width:0!important;border:0!important;padding:2px 0!important;overflow-wrap:anywhere!important}
.pttm [data-role="schedule-wrap"] .pttm-table td:nth-child(1)::before{content:"Wedstrijd # "!important;font-weight:600}
.pttm [data-role="schedule-wrap"] .pttm-table td:nth-child(2)::before{content:"Tijd: "!important;font-weight:600}
.pttm [data-role="schedule-wrap"] .pttm-table td:nth-child(3)::before{content:"Baan: "!important;font-weight:600}
.pttm [data-role="schedule-wrap"] .pttm-table td:nth-child(4)::before{content:"Team 1: "!important;font-weight:600}
.pttm [data-role="schedule-wrap"] .pttm-table td:nth-child(5)::before{content:"Team 2: "!important;font-weight:600}
.pttm [data-role="schedule-wrap"] .pttm-table td:last-child{grid-column:1/-1!important;border-top:1px solid #edf1f4!important;margin-top:6px!important;padding-top:12px!important}
.pttm [data-role="schedule-wrap"] .pttm-score{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:6px!important;width:100%!important;min-width:0!important}
.pttm [data-role="schedule-wrap"] .pttm-set{display:flex!important;flex-wrap:wrap!important;justify-content:center!important;gap:3px!important;min-width:0!important;padding:7px 3px!important}
.pttm [data-role="schedule-wrap"] .pttm-set::before{content:attr(data-set-label)!important;display:block!important;width:100%!important;text-align:center!important;font-size:11px!important;font-weight:600!important;color:#4d6678!important}
.pttm [data-role="schedule-wrap"] .pttm-set input{flex:1 1 28px!important;width:calc(50% - 9px)!important;min-width:0!important;max-width:48px!important;min-height:40px!important;padding:4px 1px!important;font-size:16px!important}
.pttm [data-role="schedule-wrap"] .pttm-score>select{grid-column:1/-1!important;width:100%!important;min-width:0!important}
}
