#td-pwsg *{box-sizing:border-box}
#td-pwsg{margin:0;background:#f2f6fb;color:#172943;font:16px/1.65 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
#td-pwsg button,#td-pwsg input,#td-pwsg select{font:inherit}
#td-pwsg button{cursor:pointer}
#td-pwsg a{color:#1264a3}
#td-pwsg button:focus-visible,#td-pwsg a:focus-visible,#td-pwsg input:focus-visible,#td-pwsg select:focus-visible{outline:3px solid #e8a72e;outline-offset:3px}
#td-pwsg button:disabled{opacity:.45;cursor:not-allowed}
#td-pwsg button{border:1px solid #cfdae8;border-radius:10px;padding:9px 14px;background:#fff;color:#20364e;font-weight:650}
#td-pwsg button:hover:not(:disabled){border-color:#27836d;background:#edf9f4}
#td-pwsg .mast{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:10px clamp(12px,3vw,42px);background:#fff;border-bottom:1px solid #dce5ef;position:sticky;top:0;z-index:5;min-height:74px}
#td-pwsg .brand{display:flex;align-items:center;gap:12px;text-decoration:none;color:#233d58;font-weight:800;line-height:1.2}
#td-pwsg .brand img{width:55px;height:55px;object-fit:contain}
#td-pwsg .mark{font-size:27px}
#td-pwsg .mast nav{display:flex;gap:7px;flex-wrap:wrap}
#td-pwsg .mast nav button[aria-selected=true]{background:#164c42;color:white;border-color:#164c42}
#td-pwsg .layout{display:grid;grid-template-columns:315px minmax(0,1fr);max-width:1600px;margin:0 auto;align-items:start}
#td-pwsg .sidebar{position:sticky;top:76px;height:calc(100dvh - 76px);background:white;border-right:1px solid #dce5ef;display:flex;flex-direction:column;min-height:0;padding:20px 14px 12px}
#td-pwsg .sidebar h2{font-size:18px;margin:0 0 12px}
#td-pwsg .search{width:100%;border:1px solid #bbcddd;border-radius:9px;background:#f8fbff;padding:10px;color:#172943}
#td-pwsg .progress{margin:12px 0;padding:12px 13px;border:1px solid #d8e8e1;border-radius:12px;background:#f1faf6}
#td-pwsg .progress-top{display:flex;justify-content:space-between;font-size:13px;font-weight:700}
#td-pwsg .progressbar{height:8px;background:#d9e7df;border-radius:12px;overflow:hidden;margin:7px 0}
#td-pwsg .progressbar span{display:block;background:linear-gradient(90deg,#16816b,#54b477);height:100%;width:0;transition:width .25s}
#td-pwsg .muted{font-size:13px;color:#526881}
#td-pwsg .lesson-nav{overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;min-height:0;flex:1}
#td-pwsg .group{margin:16px 0 5px;font-size:12px;letter-spacing:.06em;text-transform:uppercase;font-weight:800;color:#526881;padding:0 8px}
#td-pwsg .lesson-btn{border:0;background:transparent;display:flex;gap:8px;align-items:center;width:100%;text-align:left;font-weight:500;font-size:13.5px;padding:9px 8px;border-radius:8px;line-height:1.35}
#td-pwsg .lesson-btn[aria-current=step]{background:#e5f5ee;color:#125941;font-weight:750;border-left:3px solid #1f9975}
#td-pwsg .number{width:25px;flex-shrink:0;color:#60738b;font-variant-numeric:tabular-nums}
#td-pwsg .check{margin-left:auto;color:#17744f}
#td-pwsg .content{min-width:0;padding:clamp(14px,3vw,36px);max-width:1250px;width:100%;margin:auto}
#td-pwsg .hero{position:relative;overflow:hidden;background:linear-gradient(120deg,#153b46,#176650 75%,#205d83);border-radius:20px;color:white;padding:28px clamp(20px,4vw,36px);display:grid;grid-template-columns:1fr auto;gap:20px;align-items:center;box-shadow:0 10px 25px #164b4220}
#td-pwsg .eyebrow{font-size:12px;font-weight:800;letter-spacing:.12em;text-transform:uppercase;color:#b9f1d3}
#td-pwsg .hero h1{font-size:clamp(24px,3vw,39px);line-height:1.13;margin:10px 0}
#td-pwsg .hero p{margin:0;color:#dceee9;max-width:650px}
#td-pwsg .hero-art{display:flex;gap:8px;align-items:center}
#td-pwsg .tile{width:56px;height:56px;display:grid;place-items:center;font-size:22px;font-weight:900;border-radius:12px;box-shadow:0 5px 18px #0003;transform:rotate(-6deg)}
#td-pwsg .tile:nth-child(1){background:#f5db54;color:#1e293b}
#td-pwsg .tile:nth-child(2){background:#2678c9;color:white;transform:rotate(5deg)}
#td-pwsg .tile:nth-child(3){background:#dcfce7;color:#17664c;transform:rotate(-3deg)}
#td-pwsg .stats{display:flex;gap:8px;flex-wrap:wrap;margin-top:16px}
#td-pwsg .stats span{background:#ffffff19;border:1px solid #ffffff35;padding:4px 10px;border-radius:20px;font-size:12px}
#td-pwsg .crumb{font-size:13px;color:#526881;margin:22px 0 8px;display:flex;justify-content:space-between;gap:10px;flex-wrap:wrap}
#td-pwsg .card{background:#fff;border:1px solid #dce5ef;border-radius:16px;padding:clamp(16px,3vw,28px);margin:0 0 18px;box-shadow:0 4px 14px #233c5810;min-width:0}
#td-pwsg .card h2{font-size:clamp(22px,3vw,29px);line-height:1.25;margin:8px 0 15px}
#td-pwsg .card h3{font-size:19px;margin:0 0 10px}
#td-pwsg .card p{margin:0 0 12px}
#td-pwsg .tag{display:inline-block;font-size:12px;font-weight:750;color:#15644c;background:#e9f8ef;border-radius:20px;padding:4px 10px}
#td-pwsg .diagram{display:flex;align-items:stretch;justify-content:center;gap:9px;flex-wrap:wrap;padding:20px 10px;background:linear-gradient(120deg,#f1faf8,#edf3ff);border:1px solid #d5e6e6;border-radius:12px;margin-top:15px}
#td-pwsg .node{border:1px solid #adccc8;border-radius:11px;background:#fff;color:#164c42;padding:13px 12px;min-width:95px;max-width:240px;text-align:center;font-weight:750;font-size:13px;flex:1;overflow-wrap:anywhere}
#td-pwsg .arr{align-self:center;color:#2b8878;font-size:22px;font-weight:800}
#td-pwsg .steps{padding-left:25px;margin:0}
#td-pwsg .steps li{padding:4px 0}
#td-pwsg .codebox{border-radius:12px;overflow:hidden;background:#11243b;margin:12px 0}
#td-pwsg .codebar{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:9px 12px;color:#c8d8e8;font-size:12px;border-bottom:1px solid #31465b}
#td-pwsg .codebar button{background:#213b53;color:#fff;border-color:#547087;font-size:12px;padding:5px 9px}
#td-pwsg pre{color:#e4efff;margin:0;padding:17px;overflow:auto;font:13px/1.7 ui-monospace,SFMono-Regular,Consolas,monospace;tab-size:2;white-space:pre}
#td-pwsg .tip{background:#fff7e5;border:1px solid #f4dca5;border-radius:11px;padding:13px 15px;margin-top:14px;color:#654c15}
#td-pwsg .expected{background:#eff8f3;color:#1c6346;padding:12px 15px;border-radius:10px;overflow-wrap:anywhere}
#td-pwsg .quiz-options{display:grid;gap:8px;margin:12px 0}
#td-pwsg .quiz-option{text-align:left;font-weight:500}
#td-pwsg .quiz-option.correct{background:#e4f6e8;border-color:#56ac76;color:#17603c}
#td-pwsg .quiz-option.incorrect{background:#fff0ee;border-color:#e4a09a;color:#9a3029}
#td-pwsg .feedback{min-height:1.5em;font-size:14px}
#td-pwsg .primary{background:#146b51;color:white;border-color:#146b51}
#td-pwsg .primary:hover:not(:disabled){background:#0d543f;color:white}
#td-pwsg .bottomnav{display:flex;justify-content:space-between;gap:9px;flex-wrap:wrap}
#td-pwsg .related{display:flex;flex-wrap:wrap;gap:9px 18px}
#td-pwsg .related a{font-weight:600}
#td-pwsg .shot{margin:12px 0}
#td-pwsg .shot img{display:block;max-width:100%;height:auto;border:1px solid #dce5ef;border-radius:12px;margin:auto}
#td-pwsg .shot figcaption{font-size:13px;margin-top:7px;color:#536b83}
#td-pwsg .mobile-toggle{display:none}
#td-pwsg .mobile-toggle button{width:100%}
#td-pwsg .foot{text-align:center;color:#60738b;font-size:13px;padding:20px 5px}
#td-pwsg .lab-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px}
#td-pwsg .lab-grid>section{min-width:0}
#td-pwsg .workspace{scroll-margin-top:88px}
#td-pwsg .demo input:not([type=checkbox]),#td-pwsg .demo select{border:1px solid #b4c4d5;border-radius:8px;padding:9px;width:100%;background:white;color:#172943}
#td-pwsg .demo label{display:block;margin:12px 0 4px}
#td-pwsg .demo .tasklist{padding-left:20px}
#td-pwsg .demo .tasklist li{padding:4px;overflow-wrap:anywhere}
#td-pwsg .demo output{display:block;min-height:28px;color:#17603c;margin-top:9px}
#td-pwsg .demo .primary{margin-top:10px}
#td-pwsg .workspace[hidden]{display:none!important}
#td-pwsg .skip{position:absolute;left:8px;top:-100px;background:white;padding:10px;z-index:20}
#td-pwsg .skip:focus{top:8px}
#td-pwsg .error{color:#9d302a}
#td-pwsg .index-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px}
#td-pwsg .index-grid button{text-align:left}
#td-pwsg .index-grid small{display:block;color:#617489}
#td-pwsg .shot-fallback{padding:16px;background:#eff5fb;border-radius:10px}
#td-pwsg .command{font-family:monospace}
#td-pwsg .chapter-head{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
#td-pwsg .mini{font-size:12px}
#td-pwsg .filter-row{display:flex;gap:6px;align-items:center;margin-top:8px}
#td-pwsg .filter-row label{font-size:12px;color:#526881}
#td-pwsg .filter-row select{max-width:100%;min-width:0;border:1px solid #cbd8e6;background:white;color:#172943;border-radius:8px;padding:6px;font-size:12px}
#td-pwsg .nav-foot{display:flex;justify-content:space-between;gap:6px;margin-top:8px}
#td-pwsg .nav-foot button{font-size:11px;padding:5px 8px}
#td-pwsg .track-summary{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin-top:14px}
#td-pwsg .track-summary>div{background:#f4f8fc;border:1px solid #dee6ef;padding:12px;border-radius:10px}
#td-pwsg .track-summary strong{display:block;font-size:22px}
#td-pwsg .track-summary span{font-size:13px}
#td-pwsg .status{font-size:13px;color:#526881;min-height:1.3em}
#td-pwsg .lab-actions{display:flex;gap:8px;flex-wrap:wrap}
#td-pwsg .lab-actions button{font-size:13px}
#td-pwsg .photo-local{width:100%;max-width:700px}
#td-pwsg .sub{font-size:13px;color:#536b83}
#td-pwsg .sidebar .progress strong{font-variant-numeric:tabular-nums}
@media (max-width:850px){#td-pwsg .mast{position:static;flex-wrap:wrap;min-height:auto}
#td-pwsg .layout{display:block}
#td-pwsg .sidebar{display:none;position:static;height:auto;border-bottom:1px solid #dce5ef;border-right:0}
#td-pwsg .sidebar.open{display:flex}
#td-pwsg .lesson-nav{max-height:54vh}
#td-pwsg .mobile-toggle{display:block;padding:10px 14px;background:#fff}
#td-pwsg .content{padding:14px}
#td-pwsg .hero{grid-template-columns:1fr}
#td-pwsg .hero-art{display:none}
#td-pwsg .lab-grid{grid-template-columns:minmax(0,1fr)}
#td-pwsg .workspace{scroll-margin-top:8px}
#td-pwsg .mast nav{width:100%}
#td-pwsg .mast nav button{flex:1;font-size:13px;padding:8px 7px}
#td-pwsg .brand img{width:44px;height:44px}
#td-pwsg .bottomnav button{flex:1}
#td-pwsg .diagram .node{min-width:78px}
#td-pwsg .arr{font-size:17px}}
@media (max-width:400px){#td-pwsg .diagram{flex-direction:column}
#td-pwsg .node{max-width:none}
#td-pwsg .arr{transform:rotate(90deg);text-align:center}
#td-pwsg .track-summary{grid-template-columns:1fr}
#td-pwsg .hero{padding:18px}
#td-pwsg .card{padding:15px}
#td-pwsg .bottomnav{flex-direction:column}
#td-pwsg .mast nav button{font-size:12px}}
@media (prefers-reduced-motion:reduce){#td-pwsg *{scroll-behavior:auto!important;transition:none!important;animation:none!important}}
#td-pwsg{width:100%;max-width:100%;min-width:0;overflow-wrap:anywhere}#td-pwsg [hidden]{display:none!important}#td-pwsg .lesson-btn,#td-pwsg .tab-link,#td-pwsg .index-grid a,#td-pwsg .nav-link{color:#20364e;text-decoration:none;border:1px solid #cfdae8;border-radius:10px;background:white;padding:9px 14px;font-weight:650}#td-pwsg .lesson-btn{display:grid;grid-template-columns:28px minmax(0,1fr) auto;text-align:left;width:100%;padding:8px;border:0;border-radius:8px;font-size:14px}#td-pwsg .lesson-btn[aria-current=step],#td-pwsg .tab-link[aria-selected=true]{background:#164c42;color:white}#td-pwsg .index-grid a{display:block;min-width:0}#td-pwsg .index-grid small{display:block}#td-pwsg .nav-link[aria-disabled=true]{opacity:.45}#td-pwsg .mast,#td-pwsg .sidebar{position:relative;top:auto}#td-pwsg .sidebar{height: min(800px,85vh)}#td-pwsg .card{min-width:0}#td-pwsg pre{white-space:pre;overflow:auto;max-width:100%}#td-pwsg .hero h1{font-size:clamp(24px,3vw,40px)}@media(max-width:850px){#td-pwsg .sidebar{height:auto;max-height:70vh}}
/* 2.2.0: spacious chapter navigation, responsive to the actual theme content width. */
#td-pwsg{container-type:inline-size;container-name:td-pwsg-guide}
#td-pwsg .layout{grid-template-columns:clamp(340px,32%,440px) minmax(0,1fr);max-width:1800px}
#td-pwsg .sidebar{min-width:0;padding:22px 18px 14px;height:auto;min-height:1400px;max-height:none;align-self:stretch}
#td-pwsg .sidebar h2{font-size:22px;line-height:1.3}
#td-pwsg .search{font-size:16px;min-height:44px;padding:10px 12px}
#td-pwsg .filter-row{gap:10px;flex-wrap:wrap}
#td-pwsg .filter-row label,#td-pwsg .filter-row select{font-size:14px}
#td-pwsg .progress-top,#td-pwsg .progress .muted{font-size:14px}
#td-pwsg .lesson-nav{scrollbar-width:auto;scrollbar-gutter:stable;flex:1 1 0;min-height:1000px}
#td-pwsg .group{font-size:13px;line-height:1.5;margin:18px 0 8px;padding:0 10px}
#td-pwsg .lesson-btn{grid-template-columns:30px minmax(0,1fr) auto;gap:10px;font-size:16px;line-height:1.45;min-height:48px;padding:11px 10px;font-weight:550;white-space:normal;margin-bottom:2px}
#td-pwsg .lesson-btn span:nth-child(2){min-width:0;overflow-wrap:anywhere}
#td-pwsg .lesson-btn[aria-current=step]{font-weight:750}
#td-pwsg .lesson-btn[aria-current=step] .number,#td-pwsg .lesson-btn[aria-current=step] .check{color:#d3f3e6}
#td-pwsg .lesson-btn:hover:not([aria-current=step]){background:#eef7f3;color:#164c42}
#td-pwsg .nav-foot{flex-wrap:wrap;gap:8px}
#td-pwsg .nav-foot button{flex:1 1 auto;font-size:14px;min-height:42px;padding:8px 10px}
#td-pwsg .mast nav button,#td-pwsg .mast nav a{font-size:15px;min-height:44px}
#td-pwsg .mobile-toggle button{font-size:16px;min-height:48px}
@media(max-width:850px){#td-pwsg .sidebar{height:auto;min-height:0;max-height:none;padding:18px 14px}#td-pwsg .lesson-nav{max-height:1200px;min-height:0;flex:0 1 auto}#td-pwsg .mast nav button,#td-pwsg .mast nav a{font-size:14px;min-height:44px}}
/* A narrow WordPress content column must use the same collapsible navigation, even on desktop. */
@container td-pwsg-guide (max-width:899px){
#td-pwsg .layout{display:block}
#td-pwsg .sidebar{display:none;position:static;height:auto;min-height:0;max-height:none;border-right:0;border-bottom:1px solid #dce5ef;padding:18px 14px}
#td-pwsg .sidebar.open{display:flex}
#td-pwsg .lesson-nav{max-height:1200px;min-height:0;flex:0 1 auto}
#td-pwsg .mobile-toggle{display:block;padding:10px 14px;background:#fff}
#td-pwsg .mast{flex-wrap:wrap;min-height:auto}
#td-pwsg .mast nav{width:100%}
#td-pwsg .mast nav button,#td-pwsg .mast nav a{flex:1;font-size:14px;padding:8px 7px}
#td-pwsg .hero{grid-template-columns:minmax(0,1fr)}
#td-pwsg .hero-art{display:none}
#td-pwsg .content{padding:14px}
#td-pwsg .lab-grid{grid-template-columns:minmax(0,1fr)}
}

/* 2.3.0: full lesson-height desktop sidebar and expanded mobile chapter list. */
#td-pwsg .sidebar > :not(.lesson-nav){flex-shrink:0}
/* TestingDocs Playwright guide: theme-safe heading colors */
#td-pwsg .hero {
  background: linear-gradient(120deg, #102c47 0%, #164c42 65%, #174b68 100%) !important;
  color: #ffffff !important;
}
#td-pwsg .hero h1,
#td-pwsg .hero h1 span:first-child {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  text-shadow: none !important;
  background: none !important;
}
#td-pwsg .hero h1 .td-guide-subtitle {
  color: #a7f3d0 !important;
  -webkit-text-fill-color: #a7f3d0 !important;
}
#td-pwsg .hero .eyebrow {
  color: #b9f1d3 !important;
}
#td-pwsg .hero p {
  color: #e8f3f7 !important;
}
#td-pwsg .hero .stats span {
  color: #ffffff !important;
  background: #ffffff10 !important;
  border-color: #ffffff55 !important;
}

/* v2.3.2: Remove theme sidebars only on configured study guide pages.
   Do not target the guide's own #td-pwsg .sidebar or footer widget areas. */
body.td-pwsg-fullwidth :is(#secondary, #sidebar, #right-sidebar, #left-sidebar, #sidebar-primary, #sidebar-secondary):not(#td-pwsg *) {display:none!important}
body.td-pwsg-fullwidth :is(#content, .site-content, .site-main-wrap) :is(.widget-area, .sidebar-main, .site-sidebar, .right-sidebar, .left-sidebar, .sidebar):not(#td-pwsg *):not(footer *) {display:none!important}
body.td-pwsg-fullwidth :is(#primary, .content-area, .site-main, .main-content):not(#td-pwsg *) {width:100%!important;max-width:100%!important;min-width:0!important;float:none!important;margin-left:0!important;margin-right:0!important;flex:1 1 100%!important;grid-column:1/-1!important}
body.td-pwsg-fullwidth :is(#content, .site-content) > :is(.col-full, .ast-container, .container, .content-wrap, .site-content-inner) {grid-template-columns:minmax(0,1fr)!important}
body.td-pwsg-fullwidth :is(#content, .site-content) {grid-template-columns:minmax(0,1fr)!important}

/* v2.3.3: Explicit, high-contrast code colors, isolated from theme styles. */
#td-pwsg .codebox {
  background: #11243b !important;
  color: #e4efff !important;
  min-width: 0;
  max-width: 100%;
  color-scheme: dark;
}
#td-pwsg .codebox .codebar {
  background: #1d344d !important;
  color: #e4efff !important;
  border-color: #46617d !important;
  flex-wrap: wrap;
}
#td-pwsg .codebox .codebar span {
  color: #e4efff !important;
  -webkit-text-fill-color: #e4efff !important;
}
#td-pwsg .codebox .codebar button {
  background: #294763 !important;
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  border-color: #7190ac !important;
}
#td-pwsg .codebox .codebar button:hover:not(:disabled) {
  background: #385b7a !important;
}
#td-pwsg .codebox pre {
  display: block !important;
  background: #11243b !important;
  color: #e4efff !important;
  -webkit-text-fill-color: #e4efff !important;
  text-shadow: none !important;
  border: 0 !important;
  margin: 0 !important;
  padding: 16px !important;
  font: 14px/1.7 ui-monospace, SFMono-Regular, Consolas, 'Liberation Mono', monospace !important;
  white-space: pre !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
  overflow-x: auto !important;
  max-width: 100% !important;
  tab-size: 2;
}
#td-pwsg .codebox pre code,
#td-pwsg .codebox pre code * {
  background: transparent !important;
  color: #e4efff !important;
  -webkit-text-fill-color: #e4efff !important;
  text-shadow: none !important;
  border: 0 !important;
  box-shadow: none !important;
  font: inherit !important;
  white-space: inherit !important;
  overflow-wrap: normal !important;
  word-break: normal !important;
}
#td-pwsg .codebox pre code {
  display: inline !important;
  padding: 0 !important;
  margin: 0 !important;
}
#td-pwsg :not(pre) > code:not(.codebox code) {
  color: #173c54 !important;
  -webkit-text-fill-color: #173c54 !important;
  background: #e7eff7 !important;
  text-shadow: none !important;
  border-radius: 4px;
  padding: 2px 4px;
  font-family: ui-monospace, SFMono-Regular, Consolas, 'Liberation Mono', monospace;
  overflow-wrap: anywhere;
}
#td-pwsg .codebox pre::selection,
#td-pwsg .codebox pre code::selection {
  background: #a7f3d0 !important;
  color: #11243b !important;
  -webkit-text-fill-color: #11243b !important;
}
