/* ==========================================================================
   /tools/maternity-payments
   Inherits base from maternity-bag.css (hero, FAQ, tips, etc.)
   ========================================================================== */
@import url("/assets/css/maternity-bag.css");

/* ---------- Page & Hero overrides ---------- */
.mp-page {
  background: #f5f7fc !important;
}

.mp-hero {
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.55) 0%,
      rgba(227, 220, 240, 0.78) 100%
    ),
    url("/assets/images/calc-pregnancy-hero.webp") center / cover no-repeat,
    linear-gradient(180deg, #ffffff 0%, #e3dcf0 100%) !important;
  border-bottom-color: #d6cfe0 !important;
}

.mp-hero .mb-hero-title span::after {
  background: linear-gradient(
    90deg,
    rgba(124, 140, 248, 0.5),
    rgba(177, 156, 217, 0.4)
  );
}

/* ==========================================================================
   FORM SECTION
   ========================================================================== */
.mp-form-card {
  background: #fff;
  border: 1px solid #e2eaf0;
  border-radius: 20px;
  padding: 32px 36px;
  margin: 0 0 12px;
  box-shadow: 0 4px 20px rgba(17, 17, 17, 0.04);
}

.mp-form-title {
  font-family: "Montserrat", sans-serif;
  font-size: 22px;
  font-weight: 700;
  margin: 0 0 24px !important;
  color: var(--main-bg-color);
}

.mp-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}

.mp-field label {
  display: block;
  font-family: "Montserrat", sans-serif;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--main-bg-color);
  margin-bottom: 8px;
}

.mp-field input,
.mp-field select {
  width: 100%;
  padding: 14px 16px;
  border: 2px solid #e2eaf0;
  border-radius: 12px;
  font-family: "Nunito", sans-serif;
  font-size: 16px;
  color: var(--main-bg-color);
  background: #fafbfc;
  transition: border-color 0.2s, box-shadow 0.2s;
  appearance: none;
  -webkit-appearance: none;
}

.mp-field select {
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23999' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}

.mp-field input:focus,
.mp-field select:focus {
  outline: none;
  border-color: #7C8CF8;
  box-shadow: 0 0 0 3px rgba(124, 140, 248, 0.15);
}

.mp-field-hint {
  display: block;
  margin-top: 6px;
  font-size: 12.5px;
  color: var(--dark-text-color);
}

/* --- Calculate button --- */
.mp-calc-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 16px 32px;
  background: var(--gold-color);
  color: #fff;
  border: none;
  border-radius: 14px;
  font-family: "Montserrat", sans-serif;
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}

.mp-calc-btn:hover {
  background: #a88f00;
  transform: translateY(-1px);
}

.mp-calc-btn:active {
  transform: translateY(0);
}

/* ==========================================================================
   RESULTS SECTION
   ========================================================================== */
.mp-results {
  animation: mp-fadeIn 0.4s ease;
}

.mp-results[hidden] {
  display: none;
}

@keyframes mp-fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.mp-results-title {
  font-family: "Montserrat", sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--main-bg-color);
  margin: 0 0 20px !important;
  text-align: center;
}

/* --- Total card --- */
.mp-total-card {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  border-radius: 20px;
  padding: 32px 36px;
  text-align: center;
  margin-bottom: 24px;
  box-shadow: 0 8px 32px rgba(17, 17, 17, 0.12);
}

.mp-total-label {
  font-family: "Montserrat", sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.mp-total-amount {
  font-family: "Montserrat", sans-serif;
  font-size: 42px;
  font-weight: 800;
  color: var(--gold-color);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.mp-total-hint {
  margin-top: 8px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.45);
}

/* --- Result cards grid --- */
.mp-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 28px;
}

.mp-card {
  background: #fff;
  border: 1px solid #e2eaf0;
  border-top: 4px solid var(--mp-accent);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 16px rgba(17, 17, 17, 0.03);
}

.mp-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--mp-accent) 12%, transparent);
  color: var(--mp-accent);
  margin-bottom: 14px;
}

.mp-card h3 {
  font-family: "Montserrat", sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--main-bg-color);
  margin: 0 0 12px !important;
  line-height: 1.3;
}

.mp-card-amount {
  font-family: "Montserrat", sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: var(--main-bg-color);
  margin-bottom: 14px;
  letter-spacing: -0.02em;
}

.mp-card-amount small {
  font-size: 14px;
  font-weight: 600;
  color: var(--dark-text-color);
}

.mp-card-details {
  list-style: none;
  padding: 0;
  margin: 0;
}

.mp-card-details li {
  font-size: 13.5px;
  color: var(--dark-text-color);
  padding: 4px 0;
  line-height: 1.4;
}

.mp-card-details li strong {
  color: var(--main-bg-color);
  font-weight: 700;
}

/* --- Reference table --- */
.mp-ref-table {
  background: #fff;
  border: 1px solid #e2eaf0;
  border-radius: 16px;
  padding: 24px 28px;
  margin-bottom: 32px;
  box-shadow: 0 4px 16px rgba(17, 17, 17, 0.03);
}

.mp-ref-table h3 {
  font-family: "Montserrat", sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--main-bg-color);
  margin: 0 0 16px !important;
}

.mp-ref-table table {
  width: 100%;
  border-collapse: collapse;
}

.mp-ref-table td {
  padding: 10px 0;
  font-size: 14px;
  border-bottom: 1px solid #f0f4f8;
}

.mp-ref-table tr:last-child td {
  border-bottom: none;
}

.mp-ref-table td:first-child {
  color: var(--dark-text-color);
}

.mp-ref-table td:last-child {
  text-align: right;
  color: var(--main-bg-color);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 700px) {
  .mp-form-card {
    padding: 24px 20px;
  }
  .mp-form-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .mp-total-amount {
    font-size: 32px;
  }
  .mp-total-card {
    padding: 24px 20px;
  }
  .mp-cards {
    grid-template-columns: 1fr;
  }
  .mp-card-amount {
    font-size: 22px;
  }
  .mp-ref-table {
    padding: 20px 18px;
  }
  .mp-ref-table td {
    font-size: 13px;
  }
}

@media (max-width: 480px) {
  .mp-form-title {
    font-size: 18px;
  }
  .mp-results-title {
    font-size: 20px;
  }
  .mp-total-amount {
    font-size: 26px;
  }
}
