.chain-qc-overlay{position:fixed;inset:0;z-index:100001;display:none;}
.chain-qc-overlay.open{display:block;}

.chain-qc-card{
  position:fixed;
  top:16px;
  left:50%;
  transform:translateX(-50%);
  width:min(420px,calc(100vw - 32px));
  max-height:calc(100dvh - 32px);
  background:#0a0f1a;
  border-radius:10px;
  overflow-y:auto;
  overscroll-behavior:contain;
  scrollbar-width:thin;
  z-index:501;
  transition:border-color .2s,box-shadow .2s;
}
.chain-qc-card.qc-up{
  border:2px solid var(--bull);
  box-shadow:0 0 24px rgba(0,224,96,.35),0 0 48px rgba(0,224,96,.12),0 8px 40px rgba(0,0,0,.8);
}
.chain-qc-card.qc-dn{
  border:2px solid var(--bear);
  box-shadow:0 0 24px rgba(232,0,45,.35),0 0 48px rgba(232,0,45,.12),0 8px 40px rgba(0,0,0,.8);
}

/* QC Header */
.qc-hd{display:flex;align-items:center;justify-content:space-between;padding:10px 14px;border-bottom:1px solid var(--border);background:rgba(0,0,0,.4);}
.qc-hd-left{display:flex;align-items:center;gap:10px;}
.qc-logo{width:36px;height:36px;border-radius:8px;background:#fff;display:flex;align-items:center;justify-content:center;overflow:hidden;flex-shrink:0;}
.qc-logo img{width:28px;height:28px;object-fit:contain;}
.qc-logo-fallback{font-size:13px;font-weight:900;color:#050508;}
.qc-hd-info{display:flex;flex-direction:column;gap:2px;}
.qc-underlying{font-size:15px;font-weight:900;color:#fff;letter-spacing:.02em;}
.qc-contract-label{font-size:11px;font-weight:700;color:var(--brand);letter-spacing:.04em;}
.qc-actions{display:flex;align-items:center;gap:8px;}
.qc-watchlist-btn{display:flex;align-items:center;gap:5px;font-size:11px;font-weight:800;color:#fff;background:rgba(0,224,96,.15);border:1px solid rgba(0,224,96,.4);padding:5px 10px;border-radius:4px;cursor:pointer;letter-spacing:.05em;font-family:'Inter',sans-serif;transition:all .12s;}
.qc-watchlist-btn:hover{background:rgba(0,224,96,.25);border-color:var(--bull);}
.qc-watchlist-btn.added{background:rgba(0,224,96,.25);border-color:var(--bull);color:var(--bull);}
.qc-close{font-size:18px;color:var(--grey);cursor:pointer;background:transparent;border:none;font-family:'Inter',sans-serif;line-height:1;padding:2px 4px;border-radius:3px;}
.qc-close:hover{color:#fff;background:rgba(255,255,255,.08);}

/* QC Body */
.chain-qc-card .qc-body{display:block;padding:14px;overflow:visible;}

/* Last price hero */
.qc-price-section{margin-bottom:14px;}
.qc-price-lbl{font-size:10px;font-weight:800;color:var(--grey);letter-spacing:.1em;margin-bottom:4px;}
.qc-price-row{display:flex;align-items:baseline;gap:10px;}
.chain-qc-card .qc-price{font-size:38px;font-weight:900;color:#fff;letter-spacing:-.02em;line-height:1;}
.qc-chg-col{display:flex;flex-direction:column;gap:2px;}
.qc-chg-up{font-size:14px;font-weight:800;color:var(--bull);}
.qc-chg-dn{font-size:14px;font-weight:800;color:var(--bear);}

/* Bid / Mid / Ask row */
.qc-bid-ask{display:flex;gap:6px;margin-bottom:12px;}
.qc-ba{flex:1;background:rgba(0,0,0,.3);border:1px solid var(--border);border-radius:5px;padding:8px 8px;text-align:center;}
.qc-ba-lbl{font-size:9px;font-weight:800;letter-spacing:.1em;margin-bottom:4px;}
.qc-ba-val{font-size:18px;font-weight:900;}
.qc-ba.bid .qc-ba-lbl{color:#fff;}
.qc-ba.bid .qc-ba-val{color:#fff;}
.qc-ba.mid .qc-ba-lbl{color:#fff;}
.qc-ba.mid .qc-ba-val{color:#fff;}
.qc-ba.ask .qc-ba-lbl{color:#fff;}
.qc-ba.ask .qc-ba-val{color:#fff;}

/* Greeks grid */
.qc-grid{display:grid;grid-template-columns:1fr 1fr 1fr;gap:6px;margin-bottom:10px;}
.qc-metric{background:rgba(0,0,0,.3);border:1px solid var(--border);border-radius:5px;padding:8px 10px;}
.qc-metric-lbl{font-size:9px;font-weight:800;color:var(--grey);letter-spacing:.1em;margin-bottom:3px;}
.qc-metric-val{font-size:15px;font-weight:800;color:#fff;}
.qc-metric-val.delta{color:#fff;}
.qc-metric-val.theta{color:#fff;}
.qc-metric-val.iv{color:#fff;}
.qc-metric-val.gamma-v{color:#fff;}

/* Vol / OI / Strike / Exp row */
.qc-vol-row{display:flex;justify-content:space-between;padding:8px 0;border-top:1px solid var(--border);border-bottom:1px solid var(--border);font-size:11px;color:var(--grey);margin-bottom:10px;}
.qc-vol-row div{display:flex;flex-direction:column;gap:2px;align-items:center;}
.qc-vol-row .qc-vr-lbl{font-size:9px;font-weight:800;letter-spacing:.08em;color:var(--grey);}
.qc-vol-row .qc-vr-val{font-size:13px;font-weight:800;color:#fff;}

/* Ad */
.qc-exchange-row{font-size:10px;color:rgba(255,255,255,.35);font-weight:600;letter-spacing:.04em;margin-top:2px;}
.qc-share-row{display:flex;gap:8px;margin:8px 0 4px;}
.qc-sfb{flex:1;font-family:'Inter',sans-serif;font-size:12px;font-weight:800;padding:8px 0;border-radius:5px;cursor:pointer;letter-spacing:.04em;text-align:center;background:#1E90FF;color:#ffffff;border:none;display:flex;align-items:center;justify-content:center;gap:6px;transition:background .15s;}
.qc-sfb:hover{background:#4DA6FF;}
.qc-ad{background:rgba(0,0,0,.3);border:1px solid var(--border);border-radius:4px;padding:8px 10px;text-align:center;font-size:11px;color:var(--grey);position:relative;display:flex;flex-direction:column;align-items:center;gap:6px;}
.qc-promo-slot{display:none;padding:10px 0;align-items:center;justify-content:center;background:linear-gradient(135deg,rgba(30,144,255,.08),rgba(0,68,204,.06));border:1px solid rgba(30,144,255,.2);border-radius:4px;margin-top:4px;}
.qc-promo-slot.active{display:flex;}
.qc-promo-inner{width:270px;height:250px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center;padding:0 16px;}
.qc-promo-eyebrow{font-size:13px;font-weight:800;color:#1E90FF;letter-spacing:.1em;}
.qc-promo-headline{font-size:22px;font-weight:900;color:#fff;line-height:1.25;}
.qc-ad-label{position:absolute;top:4px;right:6px;font-size:8px;font-weight:700;color:rgba(255,255,255,.2);letter-spacing:.06em;}
.qc-ad-unit{width:300px;height:250px;flex-shrink:0;}
.qc-disclaimer{font-size:9px;color:rgba(255,255,255,.2);text-align:center;margin-top:8px;font-style:italic;}


[data-options-chain]{min-width:0;color:#e6edf7}
[data-chain-controls] form{display:flex;align-items:end;flex-wrap:wrap;gap:12px}
[data-chain-controls] label{display:flex;flex-direction:column;gap:6px;font-size:13px}
[data-chain-controls] input,[data-chain-controls] select,[data-chain-controls] button{box-sizing:border-box;min-height:44px;max-width:100%;padding:10px 14px;border:1px solid #3974a6;border-radius:6px;background:#0b2841;color:#fff;font:inherit}
[data-chain-controls] input{width:200px}
[data-chain-controls] button{cursor:pointer;white-space:normal}
[data-chain-controls] [role=status],[data-chain-rows]>p{color:#9bafc8;font-size:13px;line-height:1.5}
[data-chain-rows]{min-width:0;overflow:hidden}
[data-chain-rows]>h3{font-size:18px;margin:12px 0}
.oc-table{max-width:100%;overflow-x:auto;border:1px solid #293e57;border-radius:6px;margin:14px 0}
.oc-table table{border-collapse:collapse;min-width:780px;width:100%;font-size:13px}
.oc-table th,.oc-table td{padding:12px;text-align:left;border-bottom:1px solid #26374c;white-space:nowrap}
.oc-mobile{margin:18px 12px;padding:14px;border:1px solid #293e57;border-radius:10px;background:#0d1320}
.oc-mobile h2{font-size:20px;margin:0 0 16px}
[data-options-chain] :focus-visible{outline:2px solid #83c5ff;outline-offset:2px}

[data-options-chain] [hidden]{display:none}[data-chain-rows] h4{font-size:14px;line-height:1.6;overflow-wrap:anywhere}.oc-table summary{min-height:44px;display:flex;align-items:center;cursor:pointer}.oc-table details p{font-size:12px;white-space:normal;min-width:240px;max-width:360px}

[data-chain-controls] .oc-locked::before{content:'🔒';margin-right:8px}

[data-chain-rows]>p{overflow-wrap:anywhere}
.oc-table:focus-visible{outline-offset:-2px}
.oc-table summary::after{content:'▾';margin-left:6px}
.oc-table details[open] summary::after{content:'▴'}
@media(min-width:900px){.oc-scroll-hint{display:none}}
/* Authored controls and paired calls/puts, with one semantic table per contract group. */
[data-chain-controls] .chain-search-form{display:flex;gap:12px;flex-wrap:wrap;align-items:center}
[data-chain-controls] .chain-search-wrap,[data-chain-controls] .chain-exp-wrap{display:flex;flex-direction:row;align-items:center;flex-wrap:wrap}
[data-chain-controls] .chain-search-lbl,[data-chain-controls] .chain-exp-lbl{font-size:10px;font-weight:800;letter-spacing:.1em}
[data-chain-controls] .chain-toggle{display:flex;flex-wrap:wrap}
[data-chain-controls] .chain-toggle-btn{min-height:44px;border-radius:0;padding:8px 12px;font-size:11px;font-weight:800}
[data-chain-controls] .chain-toggle-btn.active{background:#1e90ff}
.oc-table .chain-tables{display:table;min-width:1080px;table-layout:auto}
.oc-table .chain-row{display:table-row;height:auto;cursor:default}
.oc-table .chain-cell{display:table-cell;font-size:13px;text-align:right}
.oc-table .chain-table-hd th{text-align:center;font-size:17px;background:rgba(0,224,96,.06);color:#00e060}
.oc-table .chain-table-hd th[data-chain-side=put]{color:#e8002d;background:rgba(232,0,45,.06)}
.oc-table [data-chain-side=call]:last-of-type{border-right:1px solid #3974a6}
[data-chain-filter=call] [data-chain-side=put],[data-chain-filter=put] [data-chain-side=call]{display:none}
[data-chain-filter=call] .chain-tables,[data-chain-filter=put] .chain-tables{min-width:640px}
.chain-contract-action{min-height:44px;color:#fff;background:transparent;border:1px solid #3974a6;border-radius:4px;font:inherit;padding:8px;cursor:pointer}
#ucCard{flex-wrap:wrap;min-height:170px;border-color:#3974a6;background:#0d1320}
#ucCard .uc-left{box-sizing:border-box;max-width:100%;width:340px;padding:20px}
#ucCard .uc-mid{box-sizing:border-box;max-width:100%;width:auto;flex:1;min-width:220px;padding:20px}
#ucCard .uc-chg{font-size:13px;line-height:1.5;color:#9bafc8}
#ucCard .uc-stats-row{gap:30px;flex-wrap:wrap}
#chainQcOverlay[hidden]{display:none}
#chainQcOverlay{background:rgba(0,0,0,.65)}
#chainQcCard{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);max-height:calc(100dvh - 32px);max-width:calc(100vw - 24px);overflow-y:auto}
#chainQcCard .qc-actions{flex-wrap:wrap;gap:8px}
#chainQcCard .qc-alert-unavailable{font-size:10px;color:#9bafc8}
#chainQcCard .qc-contract-label,#chainQcCard .qc-exchange-row{white-space:normal;overflow-wrap:anywhere}
#chainQcCard button{min-height:44px;cursor:pointer}
#chainQcCard .qc-sfb{color:inherit;background:transparent;font:inherit}
#chainQcCard #qcActionStatus{font-size:12px;color:#9bafc8;line-height:1.5}
#chainQcCard :focus-visible{outline:2px solid #83c5ff;outline-offset:2px}

#chainQcCard .qc-hd-left,#chainQcCard .qc-hd-info{min-width:0}
#chainQcCard .qc-price-row{flex-wrap:wrap}
#chainQcCard .qc-price{font-size:clamp(20px,6vw,32px);overflow-wrap:anywhere;max-width:100%}
#chainQcCard .qc-ad{box-sizing:border-box;max-width:100%;padding:8px 0}
#chainQcCard .dt-popup-ad-unit,#chainQcCard .dt-popup-ad-unit ins{box-sizing:border-box;width:300px!important;min-width:0!important;max-width:100%!important;height:250px;position:relative;overflow:hidden}
#chainQcCard .dt-popup-house-ad{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;padding:16px;text-align:center;background:linear-gradient(135deg,#101f35,#0c192c);border:1px solid rgba(30,144,255,.35);border-radius:4px;box-sizing:border-box}
#chainQcCard .dt-popup-house-ad[hidden]{display:none}
#chainQcCard .dt-popup-house-ad img{width:132px;height:auto}
#chainQcCard .dt-popup-house-eyebrow{font-size:13px;font-weight:800;color:#1e90ff}
#chainQcCard .dt-popup-house-headline{font-size:22px;font-weight:900;color:#fff}

.oc-table .chain-strike-cell,.oc-table .chain-strike-hd{display:table-cell;min-width:70px;text-align:center;vertical-align:middle;border-left:1px solid #3974a6;border-right:1px solid #3974a6;font-weight:800;color:#9bafc8;background:rgba(30,144,255,.08)}

#ucCard #ucSelectedSource{font-size:12px;line-height:1.5;overflow-wrap:anywhere;color:#9bafc8}#ucCard .uc-stat{width:auto;min-width:100px}#ucCard .uc-stat-val{font-size:24px}#ucCard .uc-mid{min-width:0}

/* Restore the authored desktop chain density; mobile keeps its larger targets. */
@media(min-width:768px){
body[data-gamma-authored=desktop] [data-chain-controls] form{gap:12px;align-items:center}
body[data-gamma-authored=desktop] [data-chain-controls] label{gap:8px}
body[data-gamma-authored=desktop] [data-chain-controls] input,
body[data-gamma-authored=desktop] [data-chain-controls] select,
body[data-gamma-authored=desktop] [data-chain-controls] button{min-height:0;border-radius:3px;background:transparent;border-color:var(--border);padding:5px 12px;font-family:Inter,sans-serif}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-search-wrap{background:var(--card);border:1px solid rgba(30,144,255,.3);border-radius:5px;padding:6px 12px;min-width:180px}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-search-input{width:100px;border:0;padding:0;background:transparent;font-size:16px;font-weight:800;letter-spacing:.04em}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-search-btn{background:var(--brand);border:0;font-size:11px;font-weight:800;letter-spacing:.06em}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-exp-select{background:var(--card);border:1px solid rgba(255,255,255,.12);border-radius:4px;padding:6px 10px;font-size:13px;font-weight:700}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-search-lbl,
body[data-gamma-authored=desktop] [data-chain-controls] .chain-exp-lbl{color:var(--grey)}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-toggle-btn{padding:6px 14px;border:0;border-radius:0;color:var(--grey);font-size:11px;font-weight:800;letter-spacing:.06em}
body[data-gamma-authored=desktop] [data-chain-controls] .chain-toggle-btn.active{background:var(--brand);color:#fff}
body[data-gamma-authored=desktop] [data-chain-controls] p{margin:0;font-size:11px;color:var(--grey)}
body[data-gamma-authored=desktop] [data-chain-controls] p:empty{display:none}
body[data-gamma-authored=desktop] [data-chain-rows]>h3{font-size:12px;margin:6px 8px;color:var(--grey)}
body[data-gamma-authored=desktop] [data-chain-rows]>h4{font-size:10px;margin:8px;line-height:1.5;color:var(--grey);font-weight:600}
body[data-gamma-authored=desktop] .chain-source-details{margin:6px 8px;color:var(--grey);font-size:10px}
body[data-gamma-authored=desktop] .chain-source-details>summary{cursor:pointer}
body[data-gamma-authored=desktop] .chain-source-details p{font-size:11px;line-height:1.5;margin:6px 0}
body[data-gamma-authored=desktop] .oc-table{margin:8px 0 0;border:0;border-radius:0}
body[data-gamma-authored=desktop] .oc-table .chain-tables{min-width:900px;table-layout:fixed}
body[data-gamma-authored=desktop] .oc-table th,
body[data-gamma-authored=desktop] .oc-table td{padding:0 4px;border-bottom:1px solid rgba(255,255,255,.03);vertical-align:middle;text-align:right}
body[data-gamma-authored=desktop] .oc-table thead tr:first-child{height:42px}
body[data-gamma-authored=desktop] .oc-table thead tr:last-child{height:38px;background:rgba(0,0,0,.25)}
body[data-gamma-authored=desktop] .oc-table thead th{font-size:16px;font-weight:800;color:var(--grey);letter-spacing:.04em;border-bottom:1px solid rgba(255,255,255,.08)}
body[data-gamma-authored=desktop] .oc-table .chain-table-hd th{font-size:17px;font-weight:900;text-align:center;letter-spacing:.1em;color:var(--bull)}
body[data-gamma-authored=desktop] .oc-table .chain-table-hd th[data-chain-side=put]{color:var(--bear)}
body[data-gamma-authored=desktop] .oc-table .chain-row{height:44px}
body[data-gamma-authored=desktop] .oc-table .chain-cell{font-size:15px;font-weight:700;color:#fff}
body[data-gamma-authored=desktop] .oc-table [data-chain-field=volume]{color:var(--grey)}
body[data-gamma-authored=desktop] .oc-table td:first-child,
body[data-gamma-authored=desktop] .oc-table td:last-child{padding:2px 12px;text-align:left}
body[data-gamma-authored=desktop] .oc-table td:last-child{text-align:right}
body[data-gamma-authored=desktop] .chain-contract-action{display:block;min-height:0;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding:0;border:0;border-radius:0;font-size:11px;font-weight:700;line-height:18px}
body[data-gamma-authored=desktop] .oc-table td:last-child .chain-contract-action{margin-left:auto}
body[data-gamma-authored=desktop] .oc-table summary{min-height:0;line-height:16px;font-size:9px;color:var(--grey);justify-content:inherit}
body[data-gamma-authored=desktop] .oc-table td:last-child summary{justify-content:flex-end}
body[data-gamma-authored=desktop] .oc-table details p{font-size:10px;line-height:1.5;min-width:0;margin:4px 0}
body[data-gamma-authored=desktop] .oc-table .chain-strike-cell,
body[data-gamma-authored=desktop] .oc-table .chain-strike-hd{width:80px;min-width:80px;text-align:center;border-left:1px solid rgba(30,144,255,.15);border-right:1px solid rgba(30,144,255,.15);background:transparent;color:#6b7280;font-size:15px;font-weight:900}
body[data-gamma-authored=desktop] .oc-table .chain-strike-hd{background:rgba(0,0,0,.25);color:var(--grey);font-size:16px;font-weight:800}
body[data-gamma-authored=desktop] .oc-table .chain-strike-cell.atm{background:rgba(30,144,255,.12);color:var(--brand);font-size:14px}
body[data-gamma-authored=desktop] .oc-table [data-chain-side=call]:last-of-type{border-right:0}
body[data-gamma-authored=desktop] [data-chain-filter=call] .chain-tables,
body[data-gamma-authored=desktop] [data-chain-filter=put] .chain-tables{min-width:640px}
body[data-gamma-authored=desktop] #ucCard{min-height:210px;flex-wrap:nowrap;border-color:rgba(0,224,96,.6);background:radial-gradient(ellipse at top left,rgba(0,224,96,.18) 0%,rgba(0,224,96,.04) 45%,#0d1117 100%)}
body[data-gamma-authored=desktop] #ucCard.uc-dn{border-color:rgba(232,0,45,.6);background:radial-gradient(ellipse at top left,rgba(232,0,45,.18) 0%,rgba(232,0,45,.04) 45%,#0d1117 100%)}
body[data-gamma-authored=desktop] #ucCard.uc-unavailable{border-color:var(--border);background:#0d1117}
body[data-gamma-authored=desktop] #ucCard .uc-left{width:300px;padding:20px 36px}
body[data-gamma-authored=desktop] #ucCard .uc-mid{width:auto;min-width:0;flex:1;padding:20px 36px}
body[data-gamma-authored=desktop] #ucCard .uc-chg{font-size:20px;font-weight:700}
body[data-gamma-authored=desktop] #ucCard .uc-chg.up{color:var(--bull)}
body[data-gamma-authored=desktop] #ucCard .uc-chg.dn{color:var(--bear)}
body[data-gamma-authored=desktop] #ucCard .uc-stats-row{gap:clamp(12px,3vw,48px);flex-wrap:nowrap}
body[data-gamma-authored=desktop] #ucCard .uc-stat{width:auto;min-width:0}
body[data-gamma-authored=desktop] #ucCard .uc-stat-val{font-size:28px}
body[data-gamma-authored=desktop] #ucCard details>summary{min-height:0!important;display:block!important;font-size:10px;line-height:1.5}
body[data-gamma-authored=desktop] #ucCard #ucSelectedSource{font-size:10px}
}
@media(min-width:768px) and (max-width:1050px){body[data-gamma-authored=desktop] #ucCard{flex-wrap:wrap}body[data-gamma-authored=desktop] #ucCard .uc-left{width:260px}body[data-gamma-authored=desktop] #ucCard .uc-chart{flex:1;justify-content:center}}

@media(min-width:768px){body[data-gamma-authored=desktop] .oc-table .chain-strike-cell .atm-label{display:block;font-size:9px;font-weight:700;line-height:1;color:var(--brand);letter-spacing:.06em}}

/* The original mirrored ten fields flank the strike; value cells own their actions. */
@media(min-width:768px){
body[data-gamma-authored=desktop] .oc-table .chain-tables{min-width:900px}
body[data-gamma-authored=desktop] .oc-table thead tr:last-child th{font-size:clamp(9px,.9vw,16px);padding:0 3px;overflow-wrap:anywhere;white-space:normal}
body[data-gamma-authored=desktop] .oc-table thead th[data-chain-field=theoretical]{font-size:10px;letter-spacing:0}
body[data-gamma-authored=desktop] .oc-table .chain-cell{cursor:pointer;padding:0 4px}
body[data-gamma-authored=desktop] .oc-table .chain-contract-action{width:100%;min-height:44px;line-height:1.2;font-size:15px;font-weight:800;overflow:visible;text-overflow:clip;text-align:right}
body[data-gamma-authored=desktop] .oc-table [data-chain-field=theoretical]{font-weight:800}
body[data-gamma-authored=desktop] .oc-table .chain-strike-hd{vertical-align:bottom;padding-bottom:9px}
body[data-gamma-authored=desktop] #chainQcCard [data-chain-contract-source]{font-size:10px;color:var(--grey);margin:8px 0}
body[data-gamma-authored=desktop] #chainQcCard [data-chain-contract-source] p{line-height:1.5;overflow-wrap:anywhere}
}
