/* Generated from the homepage styles, scoped under .tool-ui so it cannot affect the rest of the site.
   Shared by the route planner and calculator pages. */
.tool-ui{--primary-green:#10b981;--primary-dark:#047857;--electric-blue:#3b82f6;--vibrant-purple:#8b5cf6;--card-bg:rgba(255,255,255,0.98);--card-border:#e2e8f0;--text-main:#0f172a;--text-muted:#475569;--shadow-sm:0 2px 4px rgba(0,0,0,0.04);--shadow-md:0 10px 25px -5px rgba(16,185,129,0.15);--shadow-lg:0 20px 35px -10px rgba(15,23,42,0.1)}
@keyframes dropFade{from{opacity:0;transform:translate(-50%,6px)}to{opacity:1;transform:translate(-50%,0)}}
.tool-ui .page-section{display:none;width:100%;min-width:0;min-height:85vh;padding:95px 5% 60px;max-width:1280px;margin:0 auto}
.tool-ui .page-section.active{display:block;animation:fadeIn .2s ease-out}
@keyframes fadeIn{from{opacity:0;transform:translateY(4px)}to{opacity:1;transform:translateY(0)}}
@keyframes calculatorFocus{0%{box-shadow:0 0 0 4px rgba(37,99,235,.20),var(--shadow-sm);}100%{box-shadow:var(--shadow-sm);}}
.tool-ui .content-card{background:#fff;border:1px solid var(--card-border);border-radius:24px;padding:28px;box-shadow:var(--shadow-sm);margin-bottom:25px;scroll-margin-top:100px}
.tool-ui .form-row-3col{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin-bottom:16px}
.tool-ui .form-row-2col{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-bottom:16px}
.tool-ui .form-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:16px;margin-bottom:18px}
.tool-ui .form-group{display:flex;flex-direction:column;gap:6px}
.tool-ui label{font-size:13px;font-weight:800;color:#334155}
.tool-ui .input-wrapper{position:relative;display:flex;align-items:center;width:100%}
.tool-ui .input-icon{position:absolute;left:14px;font-size:16px;pointer-events:none}
.tool-ui .hub-input, .tool-ui .hub-select{width:100%;min-height:46px;padding:11px 14px 11px 42px;border:1.5px solid #cbd5e1;border-radius:12px;font-size:14.5px;font-family:inherit;color:#0f172a;background:#fff;font-weight:600}
.tool-ui .hub-input:focus, .tool-ui .hub-select:focus{outline:none;border-color:var(--primary-green)}
.tool-ui .toggle-txt{font-size:12px;color:#2563eb;cursor:pointer;font-weight:800;background:#eff6ff;padding:4px 10px;border-radius:8px;border:1px solid #bfdbfe;user-select:none;display:inline-block;}
.tool-ui .btn-action{width:100%;min-height:46px;padding:12px 18px;border-radius:12px;font-size:14.5px;font-weight:800;cursor:pointer;border:none;display:inline-flex;align-items:center;justify-content:center;gap:8px;transition:transform .1s;text-decoration:none}
.tool-ui .btn-action:active{transform:scale(.98)}
.tool-ui .btn-action.purple{background:linear-gradient(135deg,#8b5cf6,#6d28d9);color:#fff;box-shadow:0 4px 12px rgba(139,92,246,0.25)}
.tool-ui .btn-action.blue{background:linear-gradient(135deg,#3b82f6,#1d4ed8);color:#fff;box-shadow:0 4px 12px rgba(59,130,246,0.25)}
.tool-ui .btn-action.red{background:linear-gradient(135deg,#ef4444,#dc2626);color:#fff;box-shadow:0 4px 12px rgba(239,68,68,0.25)}
.tool-ui .btn-action.green{background:linear-gradient(135deg,#10b981,#059669);color:#fff;box-shadow:0 4px 12px rgba(16,185,129,0.25)}
.tool-ui .btn-action.outline{background:#fff;color:var(--text-main);border:1.5px solid #cbd5e1}
.tool-ui .icon-btn-group{display:flex;gap:10px;align-items:center}
.tool-ui .btn-pdf-badge{background:#fee2e2;color:#dc2626;border:1.5px solid #fca5a5;border-radius:10px;padding:8px 14px;font-size:13px;font-weight:800;display:inline-flex;align-items:center;gap:6px;cursor:pointer;transition:all .2s}
.tool-ui .btn-pdf-badge:hover{background:#fecaca;transform:translateY(-1px)}
.tool-ui .btn-clear-badge{background:#f1f5f9;color:#64748b;border:1.5px solid #cbd5e1;border-radius:10px;padding:8px 12px;font-size:13px;font-weight:800;cursor:pointer;transition:all .2s}
.tool-ui .btn-clear-badge:hover{background:#e2e8f0;color:#0f172a}
.tool-ui .calc-results-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:14px;margin-top:22px}
.tool-ui .calc-result-card{border-radius:16px;padding:18px 14px;text-align:center;border:1.5px solid transparent}
.tool-ui .card-green{background:#ecfdf5;border-color:#a7f3d0}
.tool-ui .card-green .value{color:#059669}
.tool-ui .card-red{background:#fef2f2;border-color:#fecaca}
.tool-ui .card-red .value{color:#dc2626}
.tool-ui .card-solid-cyan{background:linear-gradient(135deg,#0284c7,#0369a1);border:none}
.tool-ui .card-solid-cyan h4, .tool-ui .card-solid-cyan .value, .tool-ui .card-solid-cyan .subtext{color:#fff!important}
.tool-ui .calc-result-card h4{margin:0 0 5px;font-size:11.5px;text-transform:uppercase;color:var(--text-muted);font-weight:800}
.tool-ui .calc-result-card .value{font-size:22px;font-weight:800;margin:0 0 2px}
.tool-ui .calc-result-card .subtext{font-size:11.5px;color:#64748b;font-weight:600}
.tool-ui .modal-overlay{display:none;position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(15,23,42,0.6);backdrop-filter:blur(4px);z-index:2000;align-items:center;justify-content:center;padding:16px}
.tool-ui .modal-overlay.open{display:flex}
.tool-ui .modal-box{background:#fff;border-radius:20px;max-width:650px;width:100%;padding:28px;box-shadow:var(--shadow-lg);max-height:85vh;overflow-y:auto}
.tool-ui .close-btn{background:#f1f5f9;border:none;font-size:18px;font-weight:800;width:34px;height:34px;border-radius:50%;cursor:pointer;float:right}
@media(max-width:700px){
  .tool-ui .modal-overlay{align-items:flex-start;justify-content:center;padding:74px 12px 12px;overflow-y:auto}
  .tool-ui .modal-box{width:100%;max-width:100%;max-height:calc(100vh - 88px);padding:22px 18px;border-radius:18px;margin:0}
  .tool-ui .modal-box h3{font-size:19px!important;line-height:1.3}
}
.tool-ui #pdfGeneratingOverlay{display:none;position:fixed;top:0;left:0;width:100vw;height:100vh;background:rgba(248,250,252,0.98);z-index:999999;flex-direction:column;align-items:center;justify-content:center;text-align:center}
@media (max-width:900px){
  .tool-ui .form-grid, .tool-ui .form-row-3col, .tool-ui .form-row-2col{grid-template-columns:1fr}
}
.tool-ui .status-error{display:block!important;background:#fff1f2;border:1px solid #fecaca;border-left:4px solid #ef4444;color:#991b1b;border-radius:12px;padding:12px 14px;line-height:1.55;font-weight:700;box-shadow:0 4px 14px rgba(239,68,68,.06)}
.tool-ui .status-error:focus{outline:3px solid rgba(239,68,68,.18);outline-offset:2px}
.tool-ui .calc-results-grid .value{white-space:nowrap}
.tool-ui .finance-good .value{color:#059669!important}
.tool-ui .finance-bad .value{color:#dc2626!important}
.tool-ui .calc-error{display:none;margin:10px 0 2px;padding:11px 14px;border:1px solid #fecaca;background:#fff1f2;color:#991b1b;border-radius:12px;font-size:12.5px;line-height:1.5;font-weight:700;white-space:pre-line}
.tool-ui .calc-error.show{display:block}
.tool-ui .input-invalid{border-color:#ef4444!important;box-shadow:0 0 0 3px rgba(239,68,68,.10)}
.tool-ui .calc-main-btn{white-space:nowrap}
.tool-ui .calc-error ul{margin:5px 0 0 18px;padding:0}
.tool-ui .calc-error li{margin:2px 0}
.tool-ui .global-loader{position:fixed;inset:0;z-index:99999;display:none;align-items:center;justify-content:center;background:rgba(248,250,252,.74);backdrop-filter:blur(3px);-webkit-backdrop-filter:blur(3px);padding:20px}
.tool-ui .global-loader.show{display:flex}
.tool-ui .loading-active{overflow:hidden}
.tool-ui .global-loader-card{width:min(300px,calc(100vw - 32px));background:#fff;border:1px solid #dbe3ec;border-radius:18px;box-shadow:0 18px 50px rgba(15,23,42,.16);padding:20px;text-align:center}
.tool-ui .ev-loader-ring{width:48px;height:48px;border:4px solid #dbeafe;border-top-color:#2563eb;border-radius:50%;animation:evSpin .8s linear infinite;margin:0 auto 12px;display:flex;align-items:center;justify-content:center}
.tool-ui .ev-loader-ring span{font-size:20px;animation:evPulse 1s ease-in-out infinite}
.tool-ui .global-loader-title{font-size:14px;font-weight:800;color:#0f172a}
.tool-ui .global-loader-text{font-size:12px;color:#64748b;margin-top:4px;line-height:1.4}
@keyframes evSpin{to{transform:rotate(360deg)}}
@keyframes evPulse{50%{transform:scale(.8);opacity:.65}}
.tool-ui .btn-action:focus-visible, .tool-ui .hub-input:focus-visible, .tool-ui .hub-select:focus-visible{outline:3px solid rgba(37,99,235,.25);outline-offset:2px}
.tool-ui .charge-assumption-note{margin-top:12px;padding:10px 12px;border:1px solid #dbeafe;background:#f8fbff;border-radius:12px;color:#475569;font-size:11.5px;line-height:1.5}
.tool-ui .charge-assumption-note b{color:#1e3a8a}
@media(max-width:1100px){
  .tool-ui .page-section{width:100%!important;max-width:100%!important;min-width:0!important;margin-left:0!important;margin-right:0!important}
  .tool-ui .page-section{width:100%;max-width:none;min-width:0;padding:82px 16px 42px}
  .tool-ui .content-card{width:100%;max-width:100%;min-width:0;padding:20px;border-radius:20px}
  .tool-ui .form-row-3col, .tool-ui .form-row-2col{gap:12px}
}
@media(max-width:1100px) and (orientation:portrait){
  .tool-ui .page-section{width:100%!important;max-width:100%!important}
}
@media(max-width:1100px) and (orientation:landscape){
  .tool-ui .page-section{width:100%!important;max-width:100%!important}
}
@media(max-width:700px){
  .tool-ui .page-section{width:100%;max-width:none;min-width:0;padding:76px 12px 34px}
  .tool-ui .content-card{width:100%;max-width:100%;min-width:0;padding:15px;border-radius:17px}
  .tool-ui .form-row-3col, .tool-ui .form-row-2col, .tool-ui .form-grid{grid-template-columns:1fr;gap:11px;margin-bottom:12px}
  .tool-ui .hub-input, .tool-ui .hub-select{min-height:48px;font-size:14px}
  .tool-ui .btn-action{min-height:48px;font-size:13.5px;padding:11px 14px}
  .tool-ui .icon-btn-group{flex-direction:column;align-items:stretch}
  .tool-ui .btn-pdf-badge, .tool-ui .btn-clear-badge{width:100%;justify-content:center;min-height:44px}
  .tool-ui .calc-results-grid{grid-template-columns:1fr 1fr;gap:9px;margin-top:16px}
  .tool-ui .calc-result-card{padding:14px 9px;min-width:0}
  .tool-ui .calc-result-card .value{font-size:18px;overflow-wrap:anywhere}
  .tool-ui .calc-result-card .subtext{font-size:10.5px}
  .tool-ui .global-loader-card{padding:18px}
  .tool-ui .ev-loader-ring{width:44px;height:44px}
  .tool-ui .calc-main-btn{white-space:normal}
}
@media(max-width:380px){
  .tool-ui .page-section{padding-left:9px;padding-right:9px}
  .tool-ui .content-card{padding:12px}
  .tool-ui .calc-results-grid{grid-template-columns:1fr}
  .tool-ui .global-loader-card{padding:15px}
  .tool-ui .global-loader-text{font-size:11.5px}
}
@media(prefers-reduced-motion:reduce){
  .tool-ui .page-section.active{animation:none}
  .tool-ui .ev-loader-ring, .tool-ui .ev-loader-ring span{animation:none}
}
.tool-ui .content-card, .tool-ui .page-section, .tool-ui .modal-box{overflow-wrap:anywhere}
@media(max-width:700px){
  .tool-ui .page-section{width:100%!important;max-width:none!important;padding-left:8px!important;padding-right:8px!important;}
  .tool-ui .content-card{width:100%!important;max-width:none!important;}
}
.tool-ui .calc-card-header > div:first-child{min-width:0;flex:1;}
.tool-ui .calc-card-header .icon-btn-group{flex:0 0 auto;align-self:flex-start;}
.tool-ui .calc-card-header .btn-pdf-badge, .tool-ui .calc-card-header .btn-clear-badge{white-space:nowrap;}
@media(max-width:700px){
  .tool-ui .calc-card-header{align-items:flex-start!important;gap:8px!important;margin-bottom:16px!important;}
  .tool-ui .calc-card-header > div:first-child{min-width:0;flex:1;}
  .tool-ui .calc-card-header .icon-btn-group{display:flex!important;flex-direction:row!important;align-items:center!important;gap:6px!important;width:auto!important;}
  .tool-ui .calc-card-header .btn-pdf-badge, .tool-ui .calc-card-header .btn-clear-badge{width:40px!important;min-width:40px!important;max-width:40px!important;height:40px!important;min-height:40px!important;
        padding:0!important;border-radius:10px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;
        font-size:0!important;line-height:1!important;flex:0 0 40px!important;}
  .tool-ui .calc-card-header .btn-pdf-badge::before{content:'📄';font-size:18px;line-height:1;}
  .tool-ui .calc-card-header .btn-clear-badge::before{content:'🗑️';font-size:17px;line-height:1;}
  .tool-ui .calc-card-header .btn-pdf-badge:hover, .tool-ui .calc-card-header .btn-clear-badge:hover{transform:none;}
  .tool-ui .calc-card-header h3{font-size:20px!important;line-height:1.25!important;}
  .tool-ui .calc-card-header span{font-size:11px!important;line-height:1.45!important;display:block;margin-top:4px;}
}
.tool-ui .calc-action-row{display:flex;align-items:center;gap:10px;margin-top:16px;width:100%;min-width:0;}
.tool-ui .calc-action-row .calc-main-btn{flex:1 1 auto;min-width:0;width:auto!important;max-width:none!important;white-space:nowrap;}
.tool-ui .calc-action-row .icon-btn-group{display:flex;align-items:center;gap:8px;flex:0 0 auto;}
.tool-ui .calc-action-row .btn-pdf-badge, .tool-ui .calc-action-row .btn-clear-badge{height:44px;min-width:44px;}
.tool-ui .desktop-action-label{display:inline;}
@media(min-width:1101px){
  .tool-ui .calc-action-row .btn-pdf-badge, .tool-ui .calc-action-row .btn-clear-badge{min-width:auto;padding:8px 14px;white-space:nowrap;}
}
@media(max-width:700px){
  .tool-ui .calc-action-row{gap:6px;margin-top:14px;}
  .tool-ui .calc-action-row .icon-btn-group{gap:5px;}
  .tool-ui .calc-action-row .btn-pdf-badge, .tool-ui .calc-action-row .btn-clear-badge{width:40px!important;min-width:40px!important;max-width:40px!important;height:40px!important;min-height:40px!important;
        padding:0!important;border-radius:10px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;
        font-size:0!important;line-height:1!important;flex:0 0 40px!important;}
  .tool-ui .calc-action-row .btn-pdf-badge::before{content:'📄';font-size:18px;line-height:1;}
  .tool-ui .calc-action-row .btn-clear-badge::before{content:'🗑️';font-size:17px;line-height:1;}
  .tool-ui .calc-action-row .btn-pdf-badge:hover, .tool-ui .calc-action-row .btn-clear-badge:hover{transform:none;}
  .tool-ui .calc-action-row .calc-main-btn{min-width:0!important;padding-left:10px!important;padding-right:10px!important;font-size:13px!important;}
}
.tool-ui .calc-action-row{display:flex!important;flex-direction:row!important;align-items:center!important;width:100%!important;min-width:0!important;gap:8px!important;}
.tool-ui .calc-action-row .calc-main-btn{display:block!important;flex:1 1 auto!important;min-width:0!important;width:auto!important;max-width:none!important;}
.tool-ui .calc-action-row .icon-btn-group{display:flex!important;flex-direction:row!important;align-items:center!important;justify-content:flex-end!important;gap:6px!important;flex:0 0 auto!important;width:auto!important;}
.tool-ui .calc-action-row .btn-pdf-badge, .tool-ui .calc-action-row .btn-clear-badge{display:inline-flex!important;flex:0 0 40px!important;width:40px!important;min-width:40px!important;max-width:40px!important;height:40px!important;min-height:40px!important;padding:0!important;align-items:center!important;justify-content:center!important;font-size:0!important;line-height:1!important;white-space:nowrap!important;}
.tool-ui .calc-action-row .btn-pdf-badge::before{content:'📄';font-size:18px!important;line-height:1!important;}
.tool-ui .calc-action-row .btn-clear-badge::before{content:'🗑️';font-size:17px!important;line-height:1!important;}
@media(max-width:700px){
  .tool-ui .calc-action-row{gap:6px!important;margin-top:14px!important;}
  .tool-ui .calc-action-row .icon-btn-group{flex-direction:row!important;gap:5px!important;}
  .tool-ui .calc-action-row .calc-main-btn{font-size:12.5px!important;padding:10px 8px!important;}
}
@media(max-width:1100px){
  .tool-ui .calc-action-row .desktop-action-label{display:none!important;}
  .tool-ui .calc-action-row .btn-pdf-badge, .tool-ui .calc-action-row .btn-clear-badge{width:44px!important;min-width:44px!important;padding:8px!important;justify-content:center;gap:0;}
}
@media (min-width:701px){
  .tool-ui .calc-action-row .desktop-action-label{display:inline!important;}
  .tool-ui .calc-action-row .btn-pdf-badge, .tool-ui .calc-action-row .btn-clear-badge{width:auto!important;
        min-width:auto!important;
        max-width:none!important;
        flex:0 0 auto!important;
        height:44px!important;
        min-height:44px!important;
        padding:8px 14px!important;
        font-size:13px!important;
        line-height:1.2!important;
        white-space:nowrap!important;
        gap:6px!important;}
  .tool-ui .calc-action-row .btn-pdf-badge::before, .tool-ui .calc-action-row .btn-clear-badge::before{content:none!important;}
  .tool-ui .calc-action-row .icon-btn-group{display:flex!important;
        flex-direction:row!important;
        align-items:center!important;
        gap:8px!important;
        flex:0 0 auto!important;}
}
@media (max-width:700px){
  .tool-ui .calc-action-row .desktop-action-label{display:none!important;}
}
.tool-ui #map{width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;display:block;position:relative;overflow:hidden;}
.tool-ui #map{width:100%!important;height:100%!important;min-width:0!important;min-height:0!important;max-width:100%!important;display:block!important;position:relative!important;overflow:hidden!important;}
@media(max-width:1100px){
  .tool-ui .page-section{scroll-margin-top:calc(78px + env(safe-area-inset-top, 0px));padding-bottom:calc(72px + env(safe-area-inset-bottom, 0px))!important;}
}
@media(max-width:700px){
  .tool-ui .page-section{padding-top:calc(76px + env(safe-area-inset-top, 0px))!important;padding-bottom:calc(88px + env(safe-area-inset-bottom, 0px))!important;}
}
@media(max-width:380px){
  .tool-ui .page-section{padding-bottom:calc(96px + env(safe-area-inset-bottom, 0px))!important;}
}
.tool-ui .calculator-panel{display:none!important;}
.tool-ui .calculator-panel.active{display:block!important;animation:fadeIn .2s ease-out;}
.tool-ui #rangeError{margin-top:10px;line-height:1.4;overflow-wrap:anywhere}
.tool-ui #rangeError{scroll-margin-top:90px;}
.tool-ui .calc-guide-link:focus-visible{outline:3px solid #93c5fd;outline-offset:3px;border-radius:4px}
.tool-ui #guides{max-width:1320px;padding-top:112px}
@media(max-width:560px){
  .tool-ui #guides{padding-top:82px}
}

/* Standalone pages have their own sticky site header, so drop the homepage's header-sized top padding. */
.tool-ui .page-section{min-height:0!important;padding:8px 0 24px!important}

/* Loading overlay: close (×) and Cancel controls */
.tool-ui .global-loader-card{position:relative}
.tool-ui .global-loader-close{position:absolute;top:8px;right:8px;width:36px;height:36px;border-radius:50%;border:0;background:#f1f5f9;color:#475569;font-size:22px;line-height:1;cursor:pointer;display:flex;align-items:center;justify-content:center}
.tool-ui .global-loader-close:hover{background:#e2e8f0;color:#0f172a}
.tool-ui .global-loader-cancel{margin-top:14px;min-height:40px;padding:8px 22px;border-radius:999px;border:1px solid #cbd5e1;background:#fff;color:#334155;font:inherit;font-weight:700;font-size:13px;cursor:pointer}
.tool-ui .global-loader-cancel:hover{border-color:#2563eb;color:#2563eb}
.tool-ui .global-loader-close:focus-visible,.tool-ui .global-loader-cancel:focus-visible{outline:3px solid #93c5fd;outline-offset:2px}
.tool-ui .global-loader-close[hidden],.tool-ui .global-loader-cancel[hidden]{display:none}
/* charger result cards: "View in Google Maps" and "Directions" share one row; connector badge never breaks */
.st-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}
.tool-ui .st-actions .btn-action{width:auto;min-width:0;min-height:42px;padding:9px 8px;font-size:12.5px;text-decoration:none;white-space:nowrap;justify-content:center}
.st-source{grid-column:1/-1;font-size:10px;color:#94a3b8}
.st-conn{flex:none;white-space:nowrap;font-size:11px;font-weight:800;background:#eef2ff;padding:5px 9px;border-radius:10px}
@media(max-width:480px){.lbl-long{display:none}}
/* calculator pages: the page title above already names the tool, so the repeated card title/description is hidden
   (the "how is this calculated" link is kept) */
.tool-ui .calc-card-header h3,.tool-ui .calc-card-header>div>span:not(.calc-guide-link){display:none}
.tool-ui .calc-card-header{margin-bottom:6px!important}
.tool-ui .calc-card-header:not(:has(.calc-guide-link)){display:none!important}
.tool-ui .calc-card-header .calc-guide-link{display:inline-flex!important;margin-top:0!important}
@media(max-width:700px){.tool-ui .charge-assumption-note,.tool-ui .calc-card-header+*+.charge-assumption-note{font-size:12.5px;line-height:1.55}.tool-ui [class*="note"]{font-size:max(12px,1em)}}
