/* =============================================================
   Kalkulator wynagrodzeń · Vertia
   Bazuje na stylach głównych (styles.css)
   ============================================================= */

/* ---------- HERO ---------- */
.calc-hero {
  background:
    radial-gradient(1100px 360px at 80% -10%, rgba(197, 139, 46, 0.10), transparent 60%),
    radial-gradient(900px 320px at 0% 0%, rgba(19, 41, 75, 0.08), transparent 55%),
    var(--bg);
  padding: 56px 0 32px;
  border-bottom: 1px solid var(--line-soft);
}
.calc-hero-inner {
  text-align: center;
  max-width: 820px;
}
.calc-hero .eyebrow {
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-h);
}
.calc-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0 0 16px;
  color: var(--ink);
}
.calc-title-accent {
  display: inline-block;
  color: var(--primary);
  background: linear-gradient(180deg, transparent 62%, rgba(197, 139, 46, 0.28) 62%, rgba(197, 139, 46, 0.28) 92%, transparent 92%);
  padding: 0 6px;
}
.calc-lead {
  font-size: 1.05rem;
  color: var(--ink-soft);
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.65;
}

/* ---------- KALKULATOR LAYOUT ---------- */
.calc-section {
  padding: 36px 0 64px;
}
.calc-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}
@media (max-width: 960px) {
  .calc-grid { grid-template-columns: 1fr; gap: 22px; }
}

/* ---------- FORMULARZ ---------- */
.calc-form {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px;
  box-shadow: var(--shadow-md);
  position: sticky;
  top: 24px;
}
@media (max-width: 960px) {
  .calc-form { position: static; padding: 22px; }
}
.calc-form-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.5rem;
  margin: 0 0 22px;
  color: var(--primary);
}
.field { margin-bottom: 22px; }
.field:last-child { margin-bottom: 0; }
.field-fieldset { border: 0; padding: 0; margin: 0 0 22px; }
.field-label {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
  margin-bottom: 10px;
}
legend.field-label { padding: 0; margin-bottom: 12px; }
.field-hint {
  margin: 8px 0 0;
  font-size: 0.85rem;
  color: var(--muted);
}

/* INPUT */
.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.input-wrap input[type="text"] {
  width: 100%;
  font: inherit;
  font-size: 1.25rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  padding: 14px 50px 14px 16px;
  border-radius: 12px;
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.input-wrap input[type="text"]:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(197, 139, 46, 0.15);
}
.input-suffix {
  position: absolute;
  right: 16px;
  color: var(--muted);
  font-weight: 600;
  pointer-events: none;
}

/* RADIO */
.radio-group {
  display: grid;
  gap: 8px;
}
.radio,
.check {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.radio:hover, .check:hover { border-color: #D8C9A7; }
.radio input, .check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.radio-mark, .check-mark {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  border: 1.5px solid var(--line);
  background: #fff;
  position: relative;
  transition: border-color 0.15s, background 0.15s;
}
.radio-mark { border-radius: 50%; }
.check-mark { border-radius: 5px; }
.radio input:checked ~ .radio-mark {
  border-color: var(--accent);
  background: #fff;
}
.radio input:checked ~ .radio-mark::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: var(--accent);
}
.check input:checked ~ .check-mark {
  background: var(--accent);
  border-color: var(--accent);
}
.check input:checked ~ .check-mark::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 6px;
  height: 11px;
  border-right: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(45deg);
}
.radio:has(input:checked),
.check:has(input:checked) {
  border-color: var(--accent);
  background: #FFF9EC;
  box-shadow: 0 0 0 3px rgba(197, 139, 46, 0.08);
}
.radio input:focus-visible ~ .radio-mark,
.check input:focus-visible ~ .check-mark {
  box-shadow: 0 0 0 3px rgba(197, 139, 46, 0.25);
}
.radio-text, .check-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  line-height: 1.4;
}
.radio-text strong, .check-text strong {
  font-weight: 600;
  color: var(--ink);
  font-size: 0.95rem;
}
.radio-text small, .check-text small {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.form-note {
  margin: 20px 0 0;
  padding: 12px 14px;
  background: #F8F2E2;
  border-left: 3px solid var(--accent);
  border-radius: 6px;
  font-size: 0.82rem;
  color: var(--ink-soft);
  line-height: 1.55;
}

/* ---------- WYNIKI ---------- */
.calc-result {
  display: grid;
  gap: 16px;
}
.result-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 22px;
  box-shadow: var(--shadow-sm);
}
.result-hero {
  background: linear-gradient(135deg, #13294B 0%, #1B3F73 100%);
  border-color: transparent;
  color: #fff;
  text-align: center;
  padding: 28px 22px;
  position: relative;
  overflow: hidden;
}
.result-hero::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(197,139,46,0.25), transparent 70%);
  pointer-events: none;
}
.result-kicker {
  margin: 0 0 8px;
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
  font-weight: 600;
}
.result-netto {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.4rem, 6vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
.result-netto #r-netto { color: #F2C879; }
.result-currency {
  font-size: 0.55em;
  margin-left: 8px;
  color: rgba(255,255,255,0.85);
  font-weight: 400;
}
.result-monthly {
  margin: 6px 0 0;
  color: rgba(255,255,255,0.75);
  font-size: 0.92rem;
}
.result-mini {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,0.15);
  position: relative;
}
.result-mini > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
}
.mini-label {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
}
.mini-value {
  font-weight: 600;
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
  color: #fff;
}

.result-h {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.15rem;
  margin: 0 0 14px;
  color: var(--primary);
}
.result-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}
.result-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line-soft);
}
.result-list li:last-child { border-bottom: 0; }
.rl-label {
  color: var(--ink-soft);
  font-size: 0.93rem;
}
.rl-label small {
  color: var(--muted);
  font-size: 0.8rem;
  margin-left: 4px;
}
.rl-value {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
  white-space: nowrap;
}
.rl-sum {
  margin-top: 4px;
  padding-top: 10px !important;
  border-top: 1.5px solid var(--line) !important;
  border-bottom: 0 !important;
}
.rl-sum .rl-label { font-weight: 600; color: var(--ink); }
.rl-sum .rl-value { color: var(--primary); font-size: 1.05rem; }

.result-info {
  margin: 12px 0 0;
  font-size: 0.82rem;
  color: var(--muted);
  font-style: italic;
}
.result-info.warning {
  color: var(--accent-h);
  font-style: normal;
  background: #FFF9EC;
  padding: 8px 12px;
  border-radius: 8px;
  border-left: 3px solid var(--accent);
}

/* hide chorobowa row when unchecked */
.calc-result.no-chorobowa #r-chor-row { display: none; }

/* ---------- INFO / METODOLOGIA ---------- */
.section-soft {
  background: var(--surface);
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}
.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 28px;
}
.info-card {
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px;
  box-shadow: var(--shadow-sm);
}
.info-card h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.1rem;
  margin: 0 0 10px;
  color: var(--primary);
}
.info-card p {
  margin: 0 0 10px;
  color: var(--ink-soft);
  font-size: 0.93rem;
  line-height: 1.6;
}
.info-card ul {
  margin: 8px 0;
  padding-left: 18px;
  color: var(--ink-soft);
  font-size: 0.92rem;
  line-height: 1.7;
}
.info-card .info-foot {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--line-soft);
  font-size: 0.86rem;
  color: var(--muted);
}

/* ---------- CTA ---------- */
.section-cta {
  background: linear-gradient(180deg, var(--bg) 0%, var(--surface) 100%);
  padding: 56px 0;
}
.cta-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) auto;
  gap: 32px;
  align-items: center;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 32px;
  box-shadow: var(--shadow-md);
}
@media (max-width: 800px) {
  .cta-inner { grid-template-columns: 1fr; }
}
.cta-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  margin: 0 0 10px;
  color: var(--primary);
  line-height: 1.2;
}
.cta-lead {
  margin: 0;
  color: var(--ink-soft);
  font-size: 1rem;
  line-height: 1.6;
}
.cta-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
}
@media (max-width: 800px) {
  .cta-actions { flex-direction: column; }
}

/* ---------- aria-current --------- */
.primary-nav a[aria-current="page"],
.mobile-menu a[aria-current="page"] {
  color: var(--primary);
  font-weight: 600;
}
.primary-nav a[aria-current="page"]::after {
  content: "";
  display: block;
  height: 2px;
  background: var(--accent);
  margin-top: 4px;
  border-radius: 2px;
}
