/* ===== S-Corp calculator page (scoped under .hcpa-scorp / .hcpa-faq) ===== */
.hcpa-scorp{
  --maroon:#8B1A1A; --gray:#6D6D6D; --lgray:#CCCCCC;
  --rowbg:#F5F0F0; --dark:#222222; --white:#FFFFFF;
  color:var(--dark);
  max-width:820px; margin:0 auto; padding:8px 0;
  box-sizing:border-box; line-height:1.45; text-align:left;
}
.hcpa-scorp *{box-sizing:border-box;}

/* Inputs */
.hcpa-scorp__inputs{
  display:grid; grid-template-columns:1fr 1fr 1fr; gap:20px;
  background:var(--rowbg); border:1px solid var(--lgray);
  border-radius:12px; padding:20px; margin-bottom:20px;
}
.hcpa-scorp__field label{
  display:block; font-weight:700; font-size:.85rem;
  color:var(--dark); margin-bottom:8px;
}
.hcpa-scorp__pctval{
  float:right; color:var(--maroon); font-size:1rem; font-weight:700;
}
.hcpa-scorp__inputwrap{
  display:flex; align-items:center; background:var(--white);
  border:1px solid var(--lgray); border-radius:8px; overflow:hidden;
}
.hcpa-scorp__inputwrap:focus-within{border-color:var(--maroon); box-shadow:0 0 0 2px rgba(139,26,26,.12);}
.hcpa-scorp__prefix{padding:0 6px 0 12px; color:var(--gray); font-weight:700;}
.hcpa-scorp__inputwrap input{
  border:0; outline:none; padding:11px 12px 11px 2px; width:100%;
  font-size:1.1rem; font-weight:700; color:var(--dark); background:transparent;
}
.hcpa-scorp__field input[type=range]{
  width:100%; margin:6px 0 4px; accent-color:var(--maroon); cursor:pointer;
}
.hcpa-scorp__hint{display:block; font-size:.78rem; color:var(--gray); margin-top:4px;}

/* Label row with the include/exclude switch */
.hcpa-scorp__field-head{
  display:flex; align-items:center; justify-content:space-between;
  gap:8px; margin-bottom:8px;
}
.hcpa-scorp__field-head label[for="hcpaCosts"]{ margin-bottom:0; }
.hcpa-scorp__switch-input{
  position:absolute; opacity:0; width:1px; height:1px; pointer-events:none;
}
/* higher specificity than `.hcpa-scorp__field label` so the block/bold
   label styling doesn't swallow the switch */
.hcpa-scorp__field .hcpa-scorp__switch{
  position:relative; display:inline-block; flex:none;
  width:38px; height:21px; margin:0; padding:0;
  background:var(--lgray); border-radius:999px; cursor:pointer;
  transition:background .2s ease;
}
.hcpa-scorp__switch-thumb{
  position:absolute; top:3px; left:3px; width:15px; height:15px;
  background:var(--white); border-radius:50%;
  box-shadow:0 1px 3px rgba(0,0,0,.3); transition:transform .2s ease;
}
.hcpa-scorp__switch-input:checked + .hcpa-scorp__switch{ background:var(--maroon); }
.hcpa-scorp__switch-input:checked + .hcpa-scorp__switch .hcpa-scorp__switch-thumb{
  transform:translateX(17px);
}
.hcpa-scorp__switch-input:focus-visible + .hcpa-scorp__switch{
  box-shadow:0 0 0 3px rgba(139,26,26,.32);
}
.hcpa-scorp__inputwrap--off{ opacity:.45; }

/* Service strip — the firm's determination service, right under the slider.
   Deliberately brand-free: the calculator sells Hopkins, never a product. */
.hcpa-scorp__service{
  background:var(--white); border:1px solid var(--lgray); border-left:4px solid var(--maroon);
  border-radius:8px; padding:9px 14px; margin:-8px 0 20px;
  font-size:.8rem; line-height:1.45; color:var(--dark);
}
.hcpa-scorp__service strong{ color:var(--maroon); }
.hcpa-scorp__sr{
  position:absolute; width:1px; height:1px; overflow:hidden;
  clip:rect(0 0 0 0); white-space:nowrap;
}

/* Reasonable-comp risk meter */
.hcpa-scorp__risk{display:block; margin-top:8px; font-size:.76rem; line-height:1.4;}
.hcpa-scorp__risk-pill{
  display:inline-block; font-weight:700; font-size:.68rem; letter-spacing:.02em;
  padding:2px 10px; border-radius:999px; color:#fff; margin-right:6px; vertical-align:baseline;
}
.risk--red{background:#C0392B;}
.risk--amber{background:#8F5A00;}
.risk--green{background:#2E7D32;}
.risk--gray{background:#6D6D6D;}
.hcpa-scorp__risk-msg{color:var(--gray);}

/* Election-deadline banner — animated border sweep (gold comet traveling a
   maroon border). Static maroon/gold gradient border where @property is
   unsupported or the visitor prefers reduced motion. */
@property --hcpa-angle{
  syntax:'<angle>'; initial-value:0deg; inherits:false;
}
.hcpa-scorp__deadline{
  border:3px solid transparent; border-radius:8px;
  padding:10px 14px; font-size:.82rem; color:var(--dark);
  margin:-12px 0 22px;
  background:
    linear-gradient(var(--rowbg), var(--rowbg)) padding-box,
    conic-gradient(from var(--hcpa-angle),
      #8B1A1A 0deg, #8B1A1A 235deg, #E4B70F 295deg,
      #FFD84D 328deg, #FFF6C9 342deg, #8B1A1A 348deg, #8B1A1A 360deg) border-box;
  box-shadow:0 0 18px rgba(255,216,77,.45), 0 2px 10px rgba(228,183,15,.30);
  animation:hcpa-border-spin 5s linear infinite;
}
@keyframes hcpa-border-spin{ to{ --hcpa-angle:360deg; } }
@media (prefers-reduced-motion: reduce){
  .hcpa-scorp__deadline{ animation:none; }
}

/* Headline */
.hcpa-scorp__headline{
  background:var(--maroon); color:var(--white);
  border-radius:12px; padding:22px 18px; text-align:center; margin-bottom:22px;
  position:relative;
}

/* Savings "explosion" — dollar signs scattering from the two money figures.
   Particles are created by scorp.js; trajectory comes in as custom props. */
.hcpa-scorp__burst{
  position:absolute; inset:0; pointer-events:none; overflow:visible; z-index:3;
}
.hcpa-scorp__coin{
  position:absolute; left:0; top:0;
  font-weight:800; line-height:1; opacity:0;
  text-shadow:0 1px 3px rgba(0,0,0,.55);
  will-change:transform, opacity;
  animation:hcpa-fly var(--dur,1100ms) cubic-bezier(.15,.65,.35,1) forwards;
}
@keyframes hcpa-fly{
  0%   { transform:translate(var(--x),var(--y)) scale(.35) rotate(0deg); opacity:0; }
  12%  { opacity:1; }
  70%  { opacity:1; }
  100% { transform:translate(calc(var(--x) + var(--dx)), calc(var(--y) + var(--dy)))
                   scale(var(--sc,1.2)) rotate(var(--rot,180deg)); opacity:0; }
}
.hcpa-scorp__pop{ animation:hcpa-pop 620ms cubic-bezier(.2,1.4,.35,1); }
@keyframes hcpa-pop{
  0%{transform:scale(1);} 28%{transform:scale(1.18);}
  55%{transform:scale(.97);} 100%{transform:scale(1);}
}
@media (prefers-reduced-motion: reduce){
  .hcpa-scorp__coin, .hcpa-scorp__pop{ animation:none; }
}
.hcpa-scorp__headline-label{
  text-transform:uppercase; letter-spacing:.06em; font-size:.74rem;
  opacity:.9; margin-bottom:6px;
}
.hcpa-scorp__headline-value{font-size:2.6rem; font-weight:800; line-height:1;}
.hcpa-scorp__headline-note{font-size:.82rem; opacity:.9; margin-top:8px;}

/* Five-year takeaway — the anchor number */
.hcpa-scorp__fiveyr{
  margin:16px auto 4px; max-width:430px;
  background:#E4B70F; color:#241C00;
  border-radius:10px; padding:12px 18px 14px;
  display:flex; flex-direction:column; align-items:center; gap:2px;
  box-shadow:0 2px 10px rgba(0,0,0,.18);
}
.hcpa-scorp__fiveyr[hidden]{display:none;}
.hcpa-scorp__fiveyr-label{
  font-size:.72rem; text-transform:uppercase; letter-spacing:.1em; font-weight:800;
}
.hcpa-scorp__fiveyr-value{font-size:2.3rem; font-weight:800; line-height:1; font-variant-numeric:tabular-nums;}

/* Cards */
.hcpa-scorp__cards{display:grid; grid-template-columns:1fr 1fr; gap:16px; margin-bottom:22px;}
.hcpa-scorp__card{
  border:1px solid var(--lgray); border-radius:12px; overflow:hidden; background:var(--white);
}
.hcpa-scorp__card--win{box-shadow:0 0 0 2px var(--maroon);}
.hcpa-scorp__card-head{
  padding:12px; font-weight:700; text-align:center; color:var(--white); font-size:1.02rem;
}
.hcpa-scorp__card-head--c{background:var(--gray);}
.hcpa-scorp__card-head--s{background:var(--maroon);}
.hcpa-scorp__card-body{padding:14px 16px 18px;}
.hcpa-scorp__row{
  display:flex; justify-content:space-between; gap:10px;
  font-size:.86rem; padding:7px 0; border-bottom:1px solid var(--rowbg);
}
.hcpa-scorp__row span:first-child{color:var(--gray);}
.hcpa-scorp__row span:last-child{font-weight:700; font-variant-numeric:tabular-nums; white-space:nowrap;}
.hcpa-scorp__row--total{border-bottom:0; border-top:2px solid var(--lgray); margin-top:4px; padding-top:10px; font-size:.95rem;}
.hcpa-scorp__row--total span:first-child{color:var(--dark); font-weight:700;}
.hcpa-scorp__row--total span:last-child{color:var(--maroon); font-size:1.1rem;}
.hcpa-scorp__bar{background:var(--rowbg); border-radius:6px; height:12px; margin-top:14px; overflow:hidden;}
.hcpa-scorp__bar-fill{height:100%; width:0; border-radius:6px; transition:width .35s ease;}
.hcpa-scorp__bar-fill--c{background:var(--gray);}
.hcpa-scorp__bar-fill--s{background:var(--maroon);}

/* CTA */
.hcpa-scorp__cta{text-align:center; margin-bottom:20px;}
.hcpa-scorp__btn{
  display:inline-block; background:var(--maroon); color:var(--white) !important;
  text-decoration:none; font-weight:700; padding:13px 26px; border-radius:8px;
  font-size:.95rem; transition:background .2s ease; margin:4px;
}
.hcpa-scorp__btn:hover{background:#6f1414;}
.hcpa-scorp__btn--ghost{background:var(--white); color:var(--maroon) !important; border:1px solid var(--maroon);}
.hcpa-scorp__btn--ghost:hover{background:var(--rowbg);}
.hcpa-scorp__cta-sub{color:var(--gray); font-size:.82rem; margin-top:10px;}

.hcpa-scorp__disclaimer{
  font-size:.72rem; color:var(--gray); line-height:1.5;
  border-top:1px solid var(--lgray); padding-top:14px; margin:0 0 8px;
}

/* FAQ */
.hcpa-faq details{border:1px solid #CCCCCC; border-radius:8px; padding:10px 14px; margin:8px 0; background:#fff;}
.hcpa-faq summary{font-weight:700; cursor:pointer; color:#8B1A1A;}
.hcpa-faq p{margin:8px 0 2px;}

@media (max-width:640px){
  .hcpa-scorp__inputs{grid-template-columns:1fr;}
  .hcpa-scorp__cards{grid-template-columns:1fr;}
  .hcpa-scorp__headline-value{font-size:2.1rem;}
  .hcpa-scorp__fiveyr-value{font-size:1.9rem;}
}
