/* ==========================================================================
   Personal Finance & Liquidity Simulation Styles
   Route: /personal-finance-10000-sar/
   ========================================================================== */

.finance-main {
  width: min(1160px, calc(100% - 40px));
  margin-inline: auto;
  padding-block: 2.5rem 4rem;
}

/* Hero Section */
.finance-hero {
  margin-bottom: 2.5rem;
}

.finance-hero .hero-copy {
  max-width: 820px;
}

.finance-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.9rem;
  border-radius: 999px;
  background: rgba(11, 94, 67, 0.12);
  color: var(--green);
  font-size: 0.88rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.finance-title {
  font-family: "Noto Kufi Arabic", sans-serif;
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  line-height: 1.35;
  color: var(--green-deep);
  margin-bottom: 1rem;
}

.finance-lead {
  font-size: 1.15rem;
  line-height: 1.85;
  color: var(--ink);
  margin-bottom: 1.5rem;
}

.finance-trust-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 1.5rem;
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.finance-trust-list li {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.finance-trust-list li::before {
  content: "✓";
  color: var(--green);
  font-weight: 700;
}

/* Calculator Container Card */
.calculator-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(1.5rem, 4vw, 2.5rem);
  margin-bottom: 2.5rem;
}

.calculator-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 2rem;
}

.calculator-header h2 {
  font-family: "Noto Kufi Arabic", sans-serif;
  font-size: 1.35rem;
  color: var(--green-deep);
  margin: 0;
}

.calc-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.75rem;
  background: rgba(177, 138, 66, 0.12);
  color: var(--gold);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
}

/* Controls: Input & Slider */
.calc-controls {
  display: grid;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.calc-input-group {
  display: grid;
  gap: 0.5rem;
}

.calc-input-group label {
  font-weight: 700;
  color: var(--green-deep);
  font-size: 1rem;
}

.calc-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.calc-number-input {
  width: 100%;
  padding: 0.85rem 1rem 0.85rem 4.5rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--green-deep);
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: 14px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.calc-number-input:focus {
  border-color: var(--green);
  outline: none;
  box-shadow: 0 0 0 4px rgba(11, 94, 67, 0.15);
}

.calc-currency-label {
  position: absolute;
  left: 1.25rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--muted);
  pointer-events: none;
}

/* Slider */
.calc-slider-wrapper {
  display: grid;
  gap: 0.5rem;
}

.calc-range-slider {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background: var(--line);
  outline: none;
  accent-color: var(--green);
  cursor: pointer;
}

.calc-range-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--muted);
}

/* Quick Presets */
.calc-presets {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
}

.calc-presets-label {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--muted);
  margin-left: 0.5rem;
}

.preset-pill {
  padding: 0.45rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 700;
  transition: all 0.2s ease;
}

.preset-pill:hover {
  background: var(--green-soft);
  border-color: var(--green);
  color: var(--green);
}

.preset-pill.is-active {
  background: var(--green);
  border-color: var(--green);
  color: #fff;
  box-shadow: 0 4px 12px rgba(11, 94, 67, 0.25);
}

/* Allocation Bar */
.allocation-bar-section {
  margin-bottom: 2rem;
}

.allocation-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 0.65rem;
}

.allocation-bar-track {
  display: flex;
  height: 18px;
  border-radius: 999px;
  overflow: hidden;
  background: var(--line);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.06);
}

.bar-segment-emergency {
  background: linear-gradient(135deg, #0b5e43, #10b981);
  transition: width 0.3s ease;
}

.bar-segment-liquidity {
  background: linear-gradient(135deg, #b18a42, #d4af37);
  transition: width 0.3s ease;
}

.bar-segment-savings {
  background: linear-gradient(135deg, #2563eb, #3b82f6);
  transition: width 0.3s ease;
}

/* Three Buckets Grid */
.buckets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.bucket-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.bucket-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(7, 31, 23, 0.06);
}

.bucket-card-emergency {
  border-top: 4px solid #10b981;
}

.bucket-card-liquidity {
  border-top: 4px solid #b18a42;
}

.bucket-card-savings {
  border-top: 4px solid #3b82f6;
}

.bucket-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.bucket-badge {
  font-size: 0.8rem;
  font-weight: 700;
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
}

.badge-emergency {
  background: rgba(16, 185, 129, 0.15);
  color: #0b5e43;
}

.badge-liquidity {
  background: rgba(177, 138, 66, 0.15);
  color: #8b6826;
}

.badge-savings {
  background: rgba(59, 130, 246, 0.15);
  color: #1d4ed8;
}

.bucket-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--green-deep);
  margin: 0;
}

.bucket-amount-wrap {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  margin-block: 0.35rem;
}

.bucket-amount {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--green-deep);
  font-variant-numeric: tabular-nums;
}

.bucket-currency {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--muted);
}

.bucket-desc {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--muted);
  margin: 0;
}

.bucket-feature {
  margin-top: auto;
  padding-top: 0.85rem;
  border-top: 1px dashed var(--line);
  font-size: 0.84rem;
  color: var(--ink);
  font-weight: 600;
}

/* Calculator Action Footer */
.calc-action-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}

.calc-note {
  font-size: 0.88rem;
  color: var(--muted);
}

/* Statutory CMA Disclaimer Card */
.cma-statutory-disclaimer {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(177, 138, 66, 0.35);
  border-right: 5px solid var(--gold);
  border-radius: 16px;
  padding: 1.5rem 1.75rem;
  margin-bottom: 2.5rem;
  box-shadow: 0 4px 16px rgba(7, 31, 23, 0.04);
}

.disclaimer-header {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
  color: var(--green-deep);
}

.disclaimer-icon {
  font-size: 1.25rem;
}

.disclaimer-header strong {
  font-family: "Noto Kufi Arabic", sans-serif;
  font-size: 1.05rem;
}

.cma-statutory-disclaimer p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.85;
  color: #3b4b44;
  text-align: justify;
}

/* Community CTA Section */
.finance-community-card {
  background: linear-gradient(135deg, #071f17, #0b5e43);
  color: #fff;
  border-radius: var(--radius);
  padding: clamp(1.75rem, 5vw, 3rem);
  margin-bottom: 2.5rem;
  box-shadow: var(--shadow);
}

.community-content {
  max-width: 800px;
}

.community-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #e5c97b;
  margin-bottom: 0.75rem;
}

.community-title {
  font-family: "Noto Kufi Arabic", sans-serif;
  font-size: clamp(1.4rem, 3.2vw, 2rem);
  line-height: 1.4;
  margin-bottom: 1rem;
  color: #fff;
}

.community-desc {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #dceee5;
  margin-bottom: 1.5rem;
}

.community-points {
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  display: grid;
  gap: 0.65rem;
  color: #ecfdf5;
  font-size: 0.95rem;
}

.community-points li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.community-points li::before {
  content: "✦";
  color: #e5c97b;
  font-size: 0.9rem;
}

/* WhatsApp CTA Button */
.whatsapp-cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1.1rem 2.25rem;
  border-radius: 999px;
  background: #25d366;
  color: #071f17;
  font-size: 1.15rem;
  font-weight: 700;
  text-decoration: none;
  border: none;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.35);
  transition: all 0.2s ease;
  cursor: pointer;
}

.whatsapp-cta-button:hover {
  background: #20ba59;
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(37, 211, 102, 0.45);
}

.whatsapp-cta-button:active {
  transform: translateY(0);
}

.whatsapp-cta-button svg {
  width: 26px;
  height: 26px;
  fill: currentColor;
}

/* Optional Lead Drawer in Finance Page */
.finance-lead-drawer {
  margin-top: 1.75rem;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  padding: 1rem 1.25rem;
}

.finance-lead-drawer summary {
  color: #e5c97b;
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 700;
}

.finance-lead-drawer .lead-capture-form {
  margin-top: 1rem;
}

.finance-lead-drawer label {
  color: #ecfdf5;
}

.finance-lead-drawer input[type="tel"] {
  background: rgba(255, 255, 255, 0.95);
  color: var(--green-deep);
}

/* Responsive adjustments */
@media (max-width: 640px) {
  .finance-main {
    padding-block: 1.5rem 3rem;
  }
  .calculator-card {
    padding: 1.25rem;
  }
  .buckets-grid {
    grid-template-columns: 1fr;
  }
  .calc-action-bar {
    flex-direction: column;
    align-items: stretch;
  }
  .whatsapp-cta-button {
    width: 100%;
    font-size: 1.05rem;
  }
}
