/* QEX Network Guide — Official brand theme v19.
   Visual overrides only. No JavaScript or simulator logic changed. */
:root {
 color-scheme:light;
 --bg:#ffffff;--panel:#ffffff;--panel2:#f6f6f4;--stroke:#e7e6ea;
 --fg:#16141d;--sub:#5c5964;--purple:#4c3f86;--blue:#2b91cc;--mint:#16876d;
 --card:#ffffff;--edge:#e7e6ea;--tx:#16141d;--dim:#5c5964;--accent:#4c3f86;--cyan:#278ec6;
 --text:#16141d;--muted:#5c5964;--surface:#ffffff;--surface2:#f6f6f4;--line:#e7e6ea;--violet:#4c3f86;--aqua:#278ec6;
}
html {color-scheme:light}
body {background:radial-gradient(ellipse at 85% 0%,#f6f6f4 0%,transparent 42%),#ffffff!important;color:#16141d!important}
a {color:#4c3f86}
:where(h1,h2,h3,h4,strong,b){color:#16141d}
:where(p,li,small){color:inherit}
:where(.intro,.lead,.muted,.muted-sm,.note,.fine,.mini,.disclaimer,.compare-explain,.compare-note,.cong-intro,.compare-intro,.value-lead,.value-disclaimer,.footer,.foot,.notice){color:#5c5964}
:where(.brand,.topnav a){color:#16141d}
.eyebrow,.tag,.stepmeta,.compare-progress {color:#4c3f86}
:where(.panel,.card,.box,.compare-card,.cong-lane,.status,.stage,.plan,.alternate,.reasonbox,.service,.accordion,.faq details,details,.step,.mini,.choice-panel,.branch,.node,.choice,.scenario-picker button,.tab,.compare-config select,.cong-grid,.value-answer,.reco-block,.value-panel,.check,.alert){
 color:#16141d;
 border-color:#e7e6ea;
 background:#fff;
 box-shadow:0 4px 18px rgba(41,33,71,.035)
}
.panel {background:#fff}
:where(.plan,.choice,.tab,.scenario-picker button,.compare-config select){background:#f6f6f4;color:#16141d}
:where(.plan:hover,.choice:hover,.tab:hover,.scenario-picker button:hover){background:#f5f8ed}
:where(.plan[aria-pressed="true"],.choice[aria-pressed="true"],.tab[aria-selected="true"],.scenario-picker button[aria-pressed="true"]){background:#f1f7e5;color:#382453;border-color:#7cb02c;box-shadow:inset 0 0 0 1px #7cb02c}
:where(.btn,.action,.link,.back){background:#f6f6f4;color:#4c3f86;border:1px solid #e7e6ea}
:where(.btn.primary,.action.primary){background:#16141d;color:white;border-color:#16141d}
:where(.btn.secondary,.action:not(.primary)){background:#fff;color:#4c3f86;border-color:#e7e6ea}
:where(.btn:focus-visible,button:focus-visible,a:focus-visible,summary:focus-visible){outline:3px solid #7cb02c;outline-offset:3px}
:where(.plan .type,.plan .tag,.chip.em,.compare-summary .box strong,.compare-verdict){color:#4c3f86}
:where(.plan .cost,.compare-card .cost,.node small,.stage p,.box p,.card p,.mini p,.step p,.choice small,.alternate p,.plan ul,.status p,.compare-actions .muted,.value-disclaimer){color:#5c5964}
:where(.note,.tip,.reasonbox){background:#f6f6f4;border-color:#c6addf;color:#555363}
:where(.alert,.warnpill){background:#fff7ed;border-color:#efd8b4;color:#8b5521}
:where(.pill,.chip,.tag){background:#f6f6f4;color:#4c3f86;border-color:#e7e6ea}
:where(.stage,.status,.alternate,.mini,.box,.choice-panel){background:#faf9fc}
:where(.stepnum){background:#f1f7e5;color:#4c3f86}
:where(.steps span,.meter){background:#e2dde9}
:where(.steps span.current){background:#7cb02c}
:where(.top){background:#ffffffeb;border-color:#e7e3ed}
:where(.back,.link){text-decoration:none}
:where(.node,.unit,.route-mini .symbol){background:#f0eef8;border-color:#cfc7de;color:#3b3449}
:where(.node.primary,.node.auth .unit){background:#f1f7e5;border-color:#ae8bd2}
:where(.node.active .unit,.route-mini .hop.on .symbol){background:#e9f6fc;border-color:#5db4da}
:where(.node.success .unit,.route-mini .hop.done .symbol){background:#e8f8f2;border-color:#6ac2a5}
:where(.node .unit svg){stroke:#6b6780}
:where(.diagram,.route-mini,.road){background:radial-gradient(ellipse at 45% 0,#f0edf8,#f9f9fc 78%);border-color:#ddd8e7}
:where(.connection){stroke:#bdc3d1}
:where(.route-mini .track){background:#bdc3d1}
:where(.cong-lane .subtitle,.compare-card .cost){color:#5c5964}
:where(.topnav a){color:#5f5771}
:where(input,select,textarea){color:#16141d;background:#fff;border-color:#d7d2df}
:where(footer,.footer,.foot){border-color:#e7e6ea;color:#5c5964}
/* Avoid dark legacy inline color declarations on ordinary explanatory text */
:where(.stage p,.compare-explain,.compare-verdict,.box p,.plan strong,.plan b,.card strong,.card b,.mini strong,.mini b,.node b,.node strong,.step strong,.flow .step strong,.choice strong,.alternate strong,.status strong){color:#16141d}
/* Main guide sections */
.value-panel,.value-answer,.reco-block{background:#fff;border-color:#e7e6ea}
.value-conclusion{background:#f3edf9;color:#4c3f86;border-color:#dbe9cc}
/* Responsive remains governed by the original CSS. */


/* QEX official brand alignment: white / ink / lime gradient / sparing purple. */
:root { --qex-white:#ffffff; --qex-alt:#f6f6f4; --qex-ink:#16141d; --qex-muted:#5c5964; --qex-line:#e7e6ea; --qex-green:#7cb02c; --qex-green-light:#a8d048; --qex-green-dark:#6fa82f; --qex-purple:#4c3f86; --qex-grad:linear-gradient(135deg,#a8d048 0%,#6fa82f 100%); }
body { background:#fff!important; color:var(--qex-ink)!important; font-family:'Noto Sans JP','Hiragino Kaku Gothic ProN','Yu Gothic',sans-serif!important; line-height:1.8; }
:where(.shell,.wrap) { color:var(--qex-ink); }
:where(.panel,.card,.box,.compare-card,.cong-lane,.stage,.status,.reco-block,.value-panel,.value-answer){box-shadow:none;border-color:var(--qex-line);}
:where(.panel,.card,.box,.compare-card,.cong-lane,.stage,.status,.reco-block,.value-panel,.value-answer){border-radius:7px;}
:where(.eyebrow,.stepmeta,.compare-progress,.sec-label){color:var(--qex-purple)!important;}
:where(.plan[aria-pressed="true"],.choice[aria-pressed="true"],.tab[aria-selected="true"],.scenario-picker button[aria-pressed="true"]){background:#f3f8e8!important;color:var(--qex-ink)!important;border-color:var(--qex-green-dark)!important;box-shadow:inset 0 0 0 1px var(--qex-green-dark)!important;}
:where(.btn.primary,.action.primary,button.primary,a.primary){background:var(--qex-ink)!important;border-color:var(--qex-ink)!important;color:#fff!important;}
:where(.btn.primary:hover,.action.primary:hover,button.primary:hover,a.primary:hover){background:var(--qex-green-dark)!important;border-color:var(--qex-green-dark)!important;color:#fff!important;}
:where(.btn.secondary,.action:not(.primary)){background:#fff;color:var(--qex-ink);border-color:var(--qex-ink);}
:where(.steps span.current){background:var(--qex-green-dark)}
:where(.chip.em,.tag,.pill){background:#f4f8ea;border-color:#d6e5c3;color:#4e7424}
:where(.stepnum){background:var(--qex-grad);color:#101014}
:where(.value-conclusion,.reasonbox){background:#f5f8ef;border-color:#d9e9c5;color:#2d4620}
:where(.diagram,.route-mini,.road){background:linear-gradient(180deg,#f6f6f4,#fff)!important;border-color:var(--qex-line)}
:where(.compare-config select,select,input,textarea){background:#fff;color:var(--qex-ink);border-color:var(--qex-line)}
:where(.brand){color:var(--qex-ink);letter-spacing:-.035em}
:where(.brand small){color:var(--qex-purple)}
:where(a){text-decoration-thickness:1px;text-underline-offset:3px}
:where(.footer,.foot){color:var(--qex-muted)}
/* Status colors intentionally remain blue/green/orange in the simulations. */
@media(max-width:640px){body{font-size:15px}:where(.panel,.card){padding:14px}}


/* QEX Guide v21 – accessible contrast and brand consistency.
   Loaded AFTER legacy inline styles, qex-brand.css and qex-header.css.
   Visual-only, no changes to the underlying interactive logic. */
:root { color-scheme: light; }
body { color: #16141d; }

/* Reusable high-contrast typography on white surfaces */
.intro,.lead,.compare-intro,.compare-explain,.compare-note,.detail-hint,
.value-lead,.value-disclaimer,.cong-intro,.why-lead,.why-note,.why-state,
.reco-sub,.reco-title,.structure-foot,.structure-price small,
.disclaimer,.fine,.mini,.notice,.guide-notice { color:#45434d !important; }
.value-title,.value-answer h3,.why-box h3,.structure-head strong,
.reco-title { color:#16141d !important; }

/* The primary choice cards were still dark because the inline CSS had
   stronger selectors than the former theme's :where() rules. */
.value-choices button,
.scenario-picker button,
.why-controls button,
.structure-controls button {
  background:#f6f6f4 !important;
  color:#16141d !important;
  border-color:#d7d6db !important;
}
.value-choices button b,
.value-choices button strong,
.scenario-picker button b,
.scenario-picker button strong,
.why-controls button b { color:#16141d !important; }
.value-choices button small {color:#5c5964 !important;}
.value-choices button .choice-mark {color:#4c3f86 !important;}
.value-choices button[aria-pressed="true"],
.scenario-picker button[aria-pressed="true"],
.why-controls button[aria-pressed="true"],
.structure-controls button[aria-pressed="true"] {
 background:#eef6e3 !important;
 border-color:#6fa82f !important;
 color:#16141d !important;
 box-shadow:inset 0 0 0 1px #6fa82f !important;
}
.value-choices button:hover,.scenario-picker button:hover,.why-controls button:hover {
 background:#f0f5e9 !important;
}

/* Recommendation / plan pricing display */
.value-panel,.value-answer,.reco-block,.value-item,
.why-box,.why-diff,.structure-pane,.structure-lesson,.structure-price,
.guide-notice {
 background:#ffffff !important;
 color:#16141d !important;
 border-color:#dedde1 !important;
}
.value-panel {background:#ffffff !important;}
.value-answer .main-copy,.value-item p,.why-box p,.why-diff,
.structure-pane p,.structure-lesson,.structure-price {color:#45434d !important;}
.value-item {background:#f6f6f4 !important;}
.value-item b,.why-diff b {color:#16141d !important;}
.value-item strong {color:#4c3f86 !important;}
.value-answer .mini-label,.why-diff strong {color:#4c3f86 !important;}
.value-conclusion {background:#f1f7e5 !important;color:#29451e !important;border-color:#c8dda9 !important;}
.value-go {color:#305d16 !important;}

/* Diagram and explanatory links – keep contrast without changing SVG statuses */
.why-svg {background:#f6f6f4 !important;}
.detail-links a,.node-detail-links a {
 background:#f6f6f4 !important;color:#342c5b !important;
 border-color:#d4cfdf !important;
}
.detail-links a:hover,.node-detail-links a:hover {
 background:#eef6e3 !important;border-color:#6fa82f !important;
}
.guide-notice {background:#f3f6ec !important;color:#324129 !important;border-color:#c9d9b7 !important;}
.guide-notice strong {color:#263a1e !important;}
.structure-foot,.structure-price small {color:#53515a !important;}

/* Self-check: buttons, progress, supporting labels */
.actions .btn:not(.secondary),
#nextBtn,#next-btn,button[data-next],button.next {
 background:#16141d !important;color:#fff !important;border-color:#16141d !important;
}
.actions .btn:not(.secondary):not(:disabled):hover,
#nextBtn:not(:disabled):hover,#next-btn:not(:disabled):hover {
 background:#486e20 !important;border-color:#486e20 !important;
}
.actions .btn.secondary {background:#fff !important;color:#16141d !important;border-color:#77737b !important;}
.actions .btn:disabled {
 background:#e7e6ea !important;color:#67636d !important;
 border-color:#d6d5dc !important;opacity:1 !important;cursor:not-allowed;
}
.meter {background:#e7e6ea !important;}
.meter span {background:linear-gradient(90deg,#a8d048,#6fa82f) !important;}
.step {color:#4c3f86 !important;}
.check {background:#fff !important;color:#16141d !important;border-color:#dedde1 !important;}
.compareline,.summary,.alternate p,.plan ul,.plan .price small {color:#55515c !important;}
.reasonbox {background:#f4f8ef !important;color:#29451e !important;border-color:#91bb57 !important;}

/* Preserve clear visible focus states for keyboard navigation */
.value-choices button:focus-visible,.choice:focus-visible,
.scenario-picker button:focus-visible,.actions .btn:focus-visible {
 outline:3px solid #6fa82f !important;outline-offset:3px;
}



/* ==========================================================
   QEX GUIDE v24 — Verified HTML classes and readable UI
   Consolidated stylesheet: replaces qex-brand and contrast-v21
   ========================================================== */
:root{color-scheme:light}
/* High-contrast light surfaces: never black text on navy cards */
body .status,body .stage,body .footcards .box,body .compare-summary .box,
body .cong-lane,body .cong-details,body .why-box,
body .structure-pane,body .structure-lesson,body .structure-price,
body .why-diff,body .reco-block,body .value-item {
  background:#f6f6f4!important;color:#16141d!important;
  border:1px solid #d7d6db!important;box-shadow:none!important;
}
body .stage h3,body .status strong,body .footcards .box h3,
body .compare-summary .box h3,body .cong-lane h3,
body .cong-details h3,body .why-box h3,body .value-item b,
body .structure-pane strong,body .structure-lesson h3 {
 color:#16141d!important;opacity:1!important;
}
body .stage p,body .status p,body .footcards .box p,
body .compare-summary .box p,body .cong-lane .subtitle,
body .cong-details p,body .cong-outcome,body .cong-outcome p,
body .cong-lane .way,body .structure-pane p,body .structure-foot,
body .structure-price p,body .structure-price small,body .why-box p,
body .value-item p,body .value-item small,
body .compare-card .cost,body .compare-explain,
body .compare-verdict,body .modehint,body .reco-sub {
 color:#45414d!important;opacity:1!important;
}
body .value-item strong,body .plan .cost{color:#4c3f86!important;opacity:1!important}
body .plan-note,body .plan-note *,body .plan .type {opacity:1!important}
body .plan-note{color:#45414d!important}
body .plan .type{color:#4c3f86!important}
body .plan .plan-badge{background:#e4efd3!important;color:#2d4620!important;border-color:#c6dca6!important}
body .plan-group.other{opacity:1!important}
body .reco-title,body .value-answer h3{color:#16141d!important}
body .purpose-bar{background:#f1f7e5!important;border-color:#bed7a0!important;color:#16141d!important}
body .purpose-bar b,body .purpose-bar span{color:#2d4620!important}
/* Buttons: visual states are identifiable without relying on transparency */
body .tabs .tab,body .scenario-picker button,
body .compare-actions .btn,body .controls .btn,
body .cong-footer .btn,body .why-controls button,
body .structure-controls button{
 color:#16141d!important;background:#f6f6f4!important;border:1px solid #c7c6cd!important;
}
body .tabs .tab[aria-selected="true"],body .tabs .tab[aria-pressed="true"],
body .scenario-picker button[aria-pressed="true"],
body .why-controls button[aria-pressed="true"],
body .structure-controls button[aria-pressed="true"]{
 background:#eef6df!important;color:#16141d!important;border-color:#6fa82f!important;
 box-shadow:inset 0 0 0 1px #6fa82f!important;
}
body .controls .btn.primary,body .compare-actions .btn.primary,
body .cong-footer .btn.primary{background:#16141d!important;color:#fff!important;border-color:#16141d!important}
body .btn:disabled{opacity:.58!important;color:#45414d!important;background:#e5e6e9!important}
body .stepmeta,body .compare-progress{color:#4c3f86!important}
body .stepnum{color:#16141d!important;background:#e1edcd!important}
/* Connection route diagram: icon tiles stay dark, labels remain legible */
body .diagram,body .route-mini{background:#fafafa!important;border-color:#cbd0d9!important}
body .node b,body .node small,body .route-mini .hop b{color:#16141d!important}
body .node .unit{background:#1c3050!important}
body .node .unit svg{stroke:#e5f0ff!important}
body .route-mini .symbol{background:#1c3050!important;color:#e5f0ff!important}
body .route-mini .symbol svg{stroke:currentColor!important}
body .compare-card{background:#f6f6f4!important;color:#16141d!important;border-color:#d7d6db!important}
body .compare-card h3,body .compare-card h4{color:#16141d!important}
body .compare-config select{background:#fff!important;color:#16141d!important;border-color:#c4c4ce!important}
/* 5: comparison grid was also broken by an extra closing tag: fixed in HTML */
body #congestion .cong-grid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:16px!important;align-items:stretch}
body #congestion .cong-lane{min-width:0}
body #congestion .cong-legend,body #congestion .cong-legend b{color:#16141d!important}
body #congestion .cong-lane .tag{background:#e4efd3!important;color:#2d4620!important;border-color:#c6dca6!important}
body #congestion .road{background:#fff!important;border-color:#d7d6db!important}
body #congestion .road .equip-title{color:#26334b!important}
body #congestion .cong-outcome{color:#45414d!important;border-color:#d7d6db!important}
body #congestion .cong-key{color:#45414d!important}
/* Additional text-on-light cases seen in the screenshots */
body .value-go,body .detail-links a,body .node-detail-links a{
 color:#4c3f86!important;opacity:1!important;
}
body .detail-links a,body .node-detail-links a{background:#f6f6f4!important;border-color:#d7d6db!important}
body .guide-notice{background:#f4f8ef!important;color:#2d4620!important;border-color:#b7d49f!important}
body .guide-notice strong{color:#16141d!important}
body .chip.em{color:#2d4620!important}
body .structure-price small{color:#45414d!important}
@media(max-width:770px){body #congestion .cong-grid{grid-template-columns:1fr!important}}
@media(max-width:600px){body .cong-lane{padding:13px!important}}

/* V24: その他のプランカードの視認性修正 */

#planRecommendations .plan-group.other {
    opacity: 1 !important;
}

#planRecommendations .plan-group.other .plan {
    background: #f6f6f4 !important;
    color: #16141d !important;
    border: 1px solid #d8d7dc !important;
}

#planRecommendations .plan-group.other .plan:hover {
    background: #f1f7e5 !important;
    border-color: #6fa82f !important;
}

#planRecommendations .plan-group.other .plan strong {
    color: #16141d !important;
}

#planRecommendations .plan-group.other .plan .type,
#planRecommendations .plan-group.other .plan .cost {
    color: #4c3f86 !important;
    opacity: 1 !important;
}

#planRecommendations .plan-group.other .plan .plan-note {
    color: #45414d !important;
    opacity: 1 !important;
}

#planRecommendations .plan-group.other .plan .plan-badge {
    background: #e4efd3 !important;
    color: #2d4620 !important;
}

#planRecommendations .plan-group.other .plan[aria-pressed="true"] {
    background: #f1f7e5 !important;
    border: 2px solid #6fa82f !important;
}

