/* Shared colors, typography, header and footer come from styles.css. */
.simulation-page { --sim-unit: calc(100vw / 1440); }
.sim-inner { width: min(calc(var(--sim-unit) * 1024), calc(100% - 48px)); margin-inline: auto; }
.simulation-page input, .simulation-page textarea { font: inherit; }
.simulation-page :is(input, button, a) { scroll-margin-top: 110px; scroll-margin-bottom: 110px; }
.sim-breadcrumb { background: #f6f6f7; color: #777; }
.sim-breadcrumb ol { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; min-height: 38px; padding-block: 6px; font-size: 14px; font-weight: 700; }
.sim-breadcrumb li { display: flex; align-items: center; gap: 10px; }
.sim-breadcrumb li + li::before { content: ""; width: 9px; height: 9px; background: currentColor; mask: url("assets/simulation-chevron.svg") center / contain no-repeat; transform: rotate(-90deg); }
.sim-breadcrumb a:hover { text-decoration: underline; text-underline-offset: 3px; }
.sim-intro { padding: calc(var(--sim-unit) * 82) 0; text-align: center; background: #fff; }
.sim-intro h1 { margin: 0; font-size: clamp(28px, calc(var(--sim-unit) * 34), 48px); line-height: 1.5; font-weight: 900; letter-spacing: .04em; }
.sim-intro p { margin-top: 28px; font-size: clamp(14px, calc(var(--sim-unit) * 16), 22px); line-height: 1.9; }
.sim-content { padding: calc(var(--sim-unit) * 64) 0 calc(var(--sim-unit) * 80); background: var(--accent-surface); }
.sim-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
#simulation-form { min-width: 0; }
.sim-controls, .sim-payments, .sim-option-group, .sim-site-types { min-width: 0; border: 0; padding: 0; margin: 0; }
.sim-controls { display: grid; gap: 24px; }
.sim-step, .sim-summary { min-width: 0; padding: 28px; border-radius: 18px; background: #fff; }
.sim-step h2 { display: flex; align-items: center; gap: 12px; font-size: 21px; font-weight: 700; line-height: 1.5; }
.sim-step-number { display: grid; place-items: center; flex: none; width: 32px; height: 32px; border-radius: 50%; color: #fff; background: #000; font-size: 20px; line-height: 1; }
.sim-plan { margin-top: 24px; padding: 24px 12px; border: 1px solid #e4e4e4; border-radius: 10px; text-align: center; }
.sim-plan-label { font-size: 15px; font-weight: 700; }
.sim-plan-price { display: flex; align-items: baseline; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 6px; font-size: 18px; font-weight: 700; }
.sim-plan-price strong { color: var(--accent); font-size: 58px; line-height: 1.15; letter-spacing: -.03em; }
.sim-tax { font-size: 12px; font-weight: 400; }
.sim-setup { margin-top: 12px; font-size: 14px; }
.sim-setup strong { margin-left: 6px; font-size: 25px; font-weight: 700; }
.sim-step-note { margin-top: 18px; color: #555; font-size: 13px; line-height: 1.85; }
.sim-included { margin-top: 20px; padding: 18px 16px; border-radius: 8px; background: #f6f6f7; }
.sim-included h3 { font-size: 14px; font-weight: 700; line-height: 1.6; }
.sim-included > p { margin-top: 6px; color: #555; font-size: 12px; line-height: 1.8; }
.sim-included ul { display: grid; gap: 10px; margin-top: 14px; padding: 0; list-style: none; }
.sim-included li { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; font-size: 13px; line-height: 1.7; }
.sim-included li span { min-width: 0; overflow-wrap: anywhere; }
.sim-included strong { color: var(--accent-focus); font-size: 12px; white-space: nowrap; }
.sim-text-link { display: inline-block; margin-top: 12px; color: var(--accent-focus); font-size: 13px; text-decoration: underline; text-underline-offset: 4px; }
.sim-payments { display: grid; gap: 12px; margin-top: 24px; }
.sim-payment { display: grid; grid-template-columns: 19px minmax(0, 1fr) auto; align-items: center; gap: 14px; padding: 18px; border: 2px solid #e4e4e4; border-radius: 10px; cursor: pointer; }
.sim-payment:has(input:checked), .sim-option:has(input:checked), .sim-site-type:has(input:checked) { border-color: var(--accent); background: var(--accent-surface); }
.sim-payment:has(input:focus-visible), .sim-option:has(input:focus-visible), .sim-site-type:has(input:focus-visible) { outline: 3px solid var(--accent-focus); outline-offset: 3px; }
.sim-payment input, .sim-option input, .sim-site-type input { width: 19px; height: 19px; margin: 0; flex: none; accent-color: var(--accent); }
.sim-payment strong { display: block; font-size: 15px; font-weight: 700; line-height: 1.6; }
.sim-payment small { display: block; margin-top: 3px; color: #555; font-size: 12px; line-height: 1.6; }
.sim-payment-saving { display: inline-block; margin-top: 8px; padding: 2px 10px; border-radius: 999px; color: var(--accent-focus); background: var(--accent-soft); font-size: 12px; font-weight: 700; }
.sim-site-types { margin-top: 24px; }
.sim-site-types legend { width: 100%; padding: 0 0 12px; font-size: 16px; font-weight: 700; }
.sim-site-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sim-site-type { display: grid; grid-template-columns: 19px minmax(0, 1fr) auto; align-items: center; gap: 8px; min-width: 0; min-height: 64px; padding: 12px; border: 2px solid #e4e4e4; border-radius: 10px; font-size: 13px; font-weight: 700; line-height: 1.6; cursor: pointer; }
.sim-choice-state { display: inline-flex; align-items: center; justify-content: center; min-width: 34px; padding: 2px 5px; border-radius: 999px; background: #ededed; color: #666; font-size: 11px; font-weight: 700; line-height: 1.6; }
.sim-choice-state::after { content: "OFF"; }
input:checked ~ .sim-choice-state { background: var(--accent); color: #fff; }
input:checked ~ .sim-choice-state::after { content: "ON"; }
.sim-option-group { margin-top: 30px; }
.sim-option-group legend { float: none; width: 100%; padding: 0 0 12px; color: #000; font-size: 16px; font-weight: 700; }
.sim-option-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sim-option { display: flex; align-items: flex-start; gap: 10px; min-width: 0; padding: 14px 12px; border: 2px solid #e4e4e4; border-radius: 8px; cursor: pointer; }
.sim-option input { width: 18px; height: 18px; margin-top: 3px; }
.sim-option-copy { display: flex; flex-direction: column; justify-content: space-between; gap: 10px; align-self: stretch; min-width: 0; }
.sim-option-name { font-size: 13px; font-weight: 500; line-height: 1.7; overflow-wrap: anywhere; }
.sim-option-name small { font-size: 11px; color: #666; white-space: nowrap; }
.sim-option-price { font-size: 20px; font-weight: 700; line-height: 1.2; }
.sim-option-price span { margin-left: 3px; font-size: 12px; }
.sim-option:has(input:checked) .sim-option-price { color: var(--accent-focus); }
.sim-options-note { margin-top: 24px; color: #666; font-size: 12px; line-height: 1.8; }
.sim-reset { display: block; width: fit-content; min-height: 44px; margin: 12px 0 0 auto; padding: 8px 0; border: 0; background: transparent; color: #555; font-size: 13px; text-decoration: underline; text-underline-offset: 4px; }
.sim-reset:hover:not(:disabled) { color: var(--accent-focus); }
.sim-reset:disabled { color: #aaa; cursor: default; }
.sim-summary { position: sticky; top: 104px; max-height: calc(100dvh - 128px); overflow-y: auto; padding: 24px; scroll-margin-top: 104px; scrollbar-width: thin; }
.sim-summary-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.sim-summary-heading h2 { font-size: 22px; font-weight: 700; line-height: 1.5; }
.sim-summary-heading > span { color: #666; font-size: 11px; white-space: nowrap; }
.sim-selected-conditions { display: grid; gap: 6px; margin: 18px 0 0; padding: 12px; border-radius: 8px; background: var(--accent-surface); font-size: 12px; line-height: 1.7; }
.sim-selected-conditions > div { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; }
.sim-selected-conditions dt { color: #555; }
.sim-selected-conditions dd { margin: 0; text-align: right; font-weight: 700; overflow-wrap: anywhere; }
.sim-first { padding-block: 24px 20px; }
.sim-price-label { font-size: 14px; font-weight: 700; }
.sim-first-amount { display: flex; align-items: baseline; gap: 6px; color: var(--accent); font-size: 19px; font-weight: 700; }
.sim-first-amount strong { font-size: 50px; font-weight: 700; line-height: 1.25; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.sim-first-note { margin-top: 6px; color: #666; font-size: 11px; line-height: 1.7; }
.sim-monthly { padding: 14px 0 18px; border-top: 1px solid #e4e4e4; border-bottom: 1px solid #e4e4e4; }
.sim-monthly > p:first-child { color: #555; font-size: 12px; }
.sim-monthly > p:last-child { margin-top: 2px; font-size: 14px; font-weight: 700; }
.sim-monthly strong { font-size: 28px; line-height: 1.3; }
.sim-breakdown-heading { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 6px; margin-top: 22px; }
.sim-breakdown-heading h3 { margin: 0; font-size: 14px; font-weight: 700; }
.sim-breakdown-heading p { color: #666; font-size: 11px; }
.sim-breakdown-scroll { max-height: 230px; overflow: auto; margin-top: 8px; scrollbar-width: thin; }
.sim-breakdown { margin: 0; }
.sim-breakdown > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding-block: 10px; border-bottom: 1px solid #eee; font-size: 12px; line-height: 1.7; }
.sim-breakdown dt { overflow-wrap: anywhere; }
.sim-breakdown dd { margin: 0; text-align: right; white-space: nowrap; font-weight: 700; }
.sim-breakdown .sim-discount { color: var(--accent-focus); }
.sim-summary-note { margin-top: 18px; color: #666; font-size: 11px; line-height: 1.8; }
.sim-primary, .sim-secondary { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 54px; padding: 14px 16px; border: 2px solid var(--accent); border-radius: 999px; color: #fff; background: var(--accent); font-size: 15px; line-height: 1.6; font-weight: 700; text-align: center; }
.sim-primary:hover { border-color: var(--accent-hover); background: var(--accent-hover); }
.sim-summary .sim-primary { margin-top: 20px; }
.sim-secondary { border-color: #000; color: #000; background: #fff; }
.sim-secondary:hover { background: #f5f5f5; }
.sim-chevron { width: 12px; height: 12px; flex: none; background: currentColor; mask: url("assets/simulation-chevron.svg") center / contain no-repeat; transform: rotate(-90deg); }
.sim-apply { margin-top: 64px; text-align: center; }
.sim-apply h2 { font-size: clamp(22px, calc(var(--sim-unit) * 28), 38px); font-weight: 900; line-height: 1.6; text-wrap: balance; }
.sim-apply p { margin-top: 20px; font-size: 15px; line-height: 1.9; }
.sim-apply .sim-primary { max-width: 460px; min-height: 66px; margin: 26px auto 0; font-size: 17px; }
.sim-mobile-total { display: none; }
.sim-fallback { margin-bottom: 24px; padding: 18px; background: #fff; line-height: 1.8; }
.sim-fallback a { text-decoration: underline; }
.sim-dialog { width: min(620px, calc(100% - 32px)); max-height: calc(100dvh - 32px); padding: 28px; border: 0; border-radius: 18px; overflow: auto; color: var(--ink); background: #fff; }
.sim-dialog::backdrop { background: rgb(0 0 0 / 55%); }
.sim-dialog-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.sim-dialog-heading h2 { margin: 0; font-size: 21px; font-weight: 700; line-height: 1.5; }
.sim-dialog-heading button { width: 40px; height: 40px; flex: none; padding: 0; border: 1px solid #ddd; border-radius: 50%; background: #fff; font-size: 25px; line-height: 1; }
#sim-dialog-description { margin-top: 16px; color: #555; font-size: 14px; line-height: 1.8; }
.sim-copy-label { display: block; margin-top: 20px; font-size: 13px; font-weight: 700; }
#sim-estimate-text { display: block; width: 100%; min-height: 180px; margin-top: 8px; padding: 14px; border: 1px solid #ddd; border-radius: 8px; resize: vertical; background: #fafafa; color: #222; font-size: 13px; line-height: 1.8; }
.sim-copy-status { min-height: 1.8em; margin-top: 8px; color: #555; font-size: 12px; line-height: 1.8; }
.sim-dialog-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 18px; }
.simulation-page :is(.sim-primary, .sim-secondary, .sim-reset, .sim-text-link):focus-visible { outline: 3px solid var(--accent-focus); outline-offset: 4px; }
.simulation-page:has(#sim-consult-dialog[open]) { overflow: hidden; }
.simulation-page:has(dialog[open]) .sim-mobile-total { visibility: hidden; }
@media (min-width: 1100px) and (max-width: 1279px) {
  .sim-layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 18px; }
  .sim-step { padding: 22px; }
  .sim-option-grid { grid-template-columns: 1fr; }
  .sim-site-grid { grid-template-columns: 1fr; }
  .sim-summary { padding: 20px; }
  .sim-first-amount strong { font-size: 45px; }
}
@media (max-width: 1099px) {
  .sim-inner { width: min(800px, calc(100% - 48px)); }
  .sim-layout { grid-template-columns: 1fr; gap: 24px; }
  .sim-summary { position: static; max-height: none; overflow: visible; }
  .sim-breakdown-scroll { max-height: none; overflow: visible; }
  .sim-first-amount strong { font-size: 58px; }
  .sim-summary .sim-primary { max-width: 400px; margin-inline: auto; }
  .sim-mobile-total { position: fixed; z-index: 40; right: 0; bottom: 0; left: 0; display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 12px 24px calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid #ddd; background: #fff; box-shadow: 0 -4px 20px rgb(0 0 0 / 5%); }
  .sim-mobile-total > div > p:first-child { font-size: 11px; }
  .sim-mobile-amount { display: flex; align-items: baseline; gap: 5px; color: var(--accent); font-size: 13px; font-weight: 700; line-height: 1.1; }
  .sim-mobile-amount strong { font-size: 32px; font-weight: 700; letter-spacing: -.02em; }
  .sim-mobile-total button { display: flex; align-items: center; justify-content: center; gap: 8px; flex: none; min-height: 44px; padding: 10px 18px; border: 0; border-radius: 999px; background: #000; color: #fff; font-size: 13px; font-weight: 700; }
  .sim-mobile-total .sim-chevron { transform: none; }
}
@media (max-width: 699px) {
  .sim-inner { width: calc(100% - 32px); }
  .sim-breadcrumb ol { min-height: 34px; gap: 6px; font-size: 10px; }
  .sim-breadcrumb li { gap: 6px; }
  .sim-breadcrumb li + li::before { width: 7px; height: 7px; }
  .sim-intro { padding: 46px 0 48px; }
  .sim-intro h1 { font-size: clamp(22px, 6.6vw, 28px); letter-spacing: .01em; }
  .sim-intro p { margin-top: 22px; font-size: 14px; }
  .sim-content { padding: 32px 0 48px; }
  .sim-controls, .sim-layout { gap: 18px; }
  .sim-step, .sim-summary { padding: 24px 18px; border-radius: 16px; }
  .sim-step h2 { gap: 9px; font-size: 18px; }
  .sim-step-number { width: 28px; height: 28px; font-size: 18px; }
  .sim-plan { padding: 20px 8px; margin-top: 20px; }
  .sim-plan-price { gap: 5px; font-size: 15px; }
  .sim-plan-price strong { font-size: 50px; }
  .sim-plan-label { font-size: 13px; }
  .sim-tax { font-size: 10px; }
  .sim-setup { font-size: 12px; }
  .sim-setup strong { font-size: 23px; }
  .sim-payments { margin-top: 20px; }
  .sim-payment { padding: 16px 12px; gap: 10px; }
  .sim-payment strong { font-size: 14px; }
  .sim-site-grid { grid-template-columns: 1fr; }
  .sim-site-type { min-height: 54px; }
  .sim-option-grid { grid-template-columns: 1fr; gap: 10px; }
  .sim-option { align-items: center; gap: 12px; padding: 15px 12px; }
  .sim-option input { margin: 0; }
  .sim-option-copy { flex: 1; flex-direction: row; align-items: center; gap: 12px; }
  .sim-option-name { min-width: 0; font-size: 13px; }
  .sim-option-price { flex: none; font-size: 19px; white-space: nowrap; }
  .sim-option-name small { display: block; }
  .sim-step-note { font-size: 12px; }
  .sim-option-group legend { font-size: 15px; }
  .sim-summary-heading h2 { font-size: 21px; }
  .sim-first-amount strong { font-size: 54px; }
  .sim-breakdown > div { padding-block: 12px; font-size: 12px; }
  .sim-breakdown-heading h3 { font-size: 15px; }
  .sim-apply { margin-top: 42px; }
  .sim-apply h2 { font-size: 23px; }
  .sim-apply p { font-size: 13px; }
  .sim-apply .sim-primary { min-height: 60px; font-size: 15px; }
  .sim-mobile-total { gap: 8px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px)); }
  .sim-mobile-total button { padding-inline: 14px; font-size: 12px; }
  .sim-dialog { padding: 22px 18px; }
  .sim-dialog-heading h2 { font-size: 18px; }
  .sim-dialog-actions { grid-template-columns: 1fr; gap: 10px; }
}
@media (max-width: 359px) {
  .sim-step, .sim-summary { padding-inline: 14px; }
  .sim-step h2 { font-size: 16px; }
  .sim-option { gap: 8px; padding-inline: 10px; }
  .sim-option-copy { gap: 8px; }
  .sim-option-name { font-size: 12px; }
  .sim-option-price { font-size: 17px; }
  .sim-plan-price strong { font-size: 44px; }
  .sim-first-amount strong { font-size: 48px; }
  .sim-mobile-amount strong { font-size: 29px; }
  .sim-mobile-total button { padding-inline: 12px; }
}
