Files
cbsnexora/src/app/deposits/recurring-deposits/recurring-deposits-account-stepper/recurring-deposits-account-interest-rate-chart-step/recurring-deposits-account-interest-rate-chart-step.component.scss
T

1158 lines
20 KiB
SCSS

/**
* Copyright since 2025 Mifos Initiative
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
$border: #e2e8f0;
$gray-50: #f8f9fa;
$gray-100: #f1f5f9;
$gray-200: #e8eaed;
$gray-600: #64748b;
$gray-700: #334155;
$gray-900: #0f172a;
$blue: #2563eb;
$blue-light: #dbeafe;
$green: #16a34a;
$green-light: #dcfce7;
$amber: #d97706;
$amber-light: #fef3c7;
$purple: #7c3aed;
$purple-light: #ede9fe;
$red: #dc2626;
$red-light: #fee2e2;
.fdrc-wrapper {
display: flex;
flex-direction: column;
gap: 16px;
}
// ── Chart Header Card ──────────────────────────────────────────────────────
.fdrc-header-card {
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 16px;
background: #fff;
border: 1px solid $border;
border-radius: 12px;
padding: 16px 20px;
flex-wrap: wrap;
&__left {
display: flex;
align-items: center;
gap: 12px;
min-width: 0;
}
&__icon {
display: inline-flex;
align-items: center;
justify-content: center;
width: 40px;
height: 40px;
border-radius: 10px;
background: $blue-light;
color: $blue;
font-size: 18px;
flex-shrink: 0;
}
&__title {
font-size: 15px;
font-weight: 700;
color: $gray-900;
}
&__desc {
font-size: 12px;
color: $gray-600;
margin-top: 2px;
}
&__meta {
display: flex;
flex-direction: column;
align-items: flex-end;
gap: 8px;
}
&__dates {
display: flex;
gap: 12px;
flex-wrap: wrap;
justify-content: flex-end;
}
}
.fdrc-meta-item {
display: flex;
align-items: center;
gap: 5px;
font-size: 12px;
color: $gray-700;
i {
color: $gray-600;
}
strong {
color: $gray-900;
}
}
// ── Pills ──────────────────────────────────────────────────────────────────
.fdrc-pill {
display: inline-flex;
align-items: center;
gap: 5px;
padding: 3px 10px;
border-radius: 999px;
font-size: 11px;
font-weight: 700;
letter-spacing: 0.03em;
white-space: nowrap;
&--type {
background: #f1f5f9;
color: $gray-700;
}
&--single {
background: $amber-light;
color: $amber;
}
&--double {
background: $purple-light;
color: $purple;
}
&--special {
background: $green-light;
color: $green;
}
&--amount {
background: $blue-light;
color: $blue;
}
&--active {
background: $green-light;
color: $green;
border: 1px solid rgba($green, 0.3);
}
&--inactive {
background: $red-light;
color: $red;
border: 1px solid rgba($red, 0.3);
}
}
// ── Calculator Card ────────────────────────────────────────────────────────
.fdrc-calc-card {
background: #fff;
border: 1px solid $border;
border-radius: 12px;
overflow: hidden;
&__header {
display: flex;
align-items: center;
justify-content: space-between;
padding: 14px 20px;
background: $gray-50;
border-bottom: 1px solid $gray-200;
}
&__header-left {
display: flex;
align-items: center;
gap: 12px;
}
&__title {
font-size: 14px;
font-weight: 700;
color: $gray-900;
display: block;
}
&__sub {
font-size: 12px;
color: $gray-600;
display: block;
margin-top: 1px;
}
&__body {
padding: 20px;
}
}
.fdrc-calc-icon {
display: inline-flex;
align-items: center;
justify-content: center;
width: 36px;
height: 36px;
border-radius: 8px;
background: $blue-light;
color: $blue;
font-size: 16px;
flex-shrink: 0;
}
.fdrc-calc-inputs {
display: flex;
flex-wrap: wrap;
gap: 16px;
align-items: flex-end;
}
.fdrc-calc-field {
display: flex;
flex-direction: column;
gap: 6px;
flex: 1 1 220px;
min-width: 180px;
}
.fdrc-calc-label {
font-size: 12px;
font-weight: 600;
color: $gray-700;
letter-spacing: 0.04em;
text-transform: uppercase;
}
.fdrc-calc-optional {
font-weight: 400;
text-transform: none;
letter-spacing: 0;
color: $gray-600;
}
.fdrc-tenure-row {
display: flex;
align-items: center;
gap: 8px;
}
.fdrc-tenure-input {
height: 42px;
border: 1.5px solid $border;
border-radius: 8px;
padding: 0 12px;
font-size: 15px;
font-weight: 600;
color: $gray-900;
background: #fff;
width: 130px;
transition: border-color 0.15s;
&:focus {
outline: none;
border-color: $blue;
}
&--amount {
width: 180px;
}
}
.fdrc-period-badge {
display: inline-flex;
align-items: center;
padding: 0 14px;
height: 42px;
background: $gray-100;
border: 1.5px solid $border;
border-radius: 8px;
font-size: 13px;
font-weight: 700;
color: $gray-700;
}
.fdrc-period-tabs {
display: flex;
border: 1.5px solid $border;
border-radius: 8px;
overflow: hidden;
}
.fdrc-period-tab {
height: 42px;
padding: 0 14px;
font-size: 13px;
font-weight: 600;
border: none;
background: #fff;
color: $gray-600;
cursor: pointer;
transition:
background 0.15s,
color 0.15s;
& + & {
border-left: 1px solid $border;
}
&--active {
background: $blue;
color: #fff;
}
}
.fdrc-amount-row {
display: flex;
align-items: center;
}
.fdrc-amount-prefix {
display: inline-flex;
align-items: center;
justify-content: center;
width: 40px;
height: 42px;
background: $gray-100;
border: 1.5px solid $border;
border-right: none;
border-radius: 8px 0 0 8px;
font-size: 15px;
font-weight: 700;
color: $gray-700;
}
.fdrc-amount-row .fdrc-tenure-input {
border-radius: 0 8px 8px 0;
}
.fdrc-calc-hint {
font-size: 11px;
color: $amber;
display: flex;
align-items: center;
gap: 4px;
}
.fdrc-calc-actions {
display: flex;
align-items: center;
gap: 10px;
flex: 0 0 100%;
}
.fdrc-calc-btn {
display: inline-flex;
align-items: center;
gap: 7px;
height: 42px;
padding: 0 22px;
background: $blue;
color: #fff;
border: none;
border-radius: 8px;
font-size: 14px;
font-weight: 700;
cursor: pointer;
transition: background 0.15s;
&:hover {
background: #1d4ed8;
}
}
.fdrc-calc-reset {
display: inline-flex;
align-items: center;
gap: 6px;
height: 42px;
padding: 0 16px;
background: transparent;
color: $gray-600;
border: 1.5px solid $border;
border-radius: 8px;
font-size: 13px;
font-weight: 600;
cursor: pointer;
transition:
border-color 0.15s,
color 0.15s;
&:hover {
border-color: $red;
color: $red;
}
}
// ── Alert ─────────────────────────────────────────────────────────────────
.fdrc-alert {
display: flex;
align-items: flex-start;
gap: 10px;
padding: 12px 16px;
border-radius: 8px;
margin-top: 16px;
font-size: 13px;
i {
margin-top: 1px;
flex-shrink: 0;
}
&--warn {
background: $amber-light;
color: #b45309;
border: 1px solid rgba($amber, 0.4);
}
}
// ── Tenure Banner (inside result card) ───────────────────────────────────
.fdrc-tenure-banner {
display: flex;
align-items: center;
gap: 12px;
padding: 10px 14px;
background: #fff;
border: 1.5px solid rgba($green, 0.4);
border-radius: 8px;
margin-bottom: 14px;
> i {
font-size: 18px;
color: $green;
flex-shrink: 0;
}
&__content {
display: flex;
flex-direction: column;
gap: 1px;
flex: 1;
}
&__label {
font-size: 10px;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.06em;
color: $gray-600;
}
&__value {
font-size: 20px;
font-weight: 800;
color: $gray-900;
line-height: 1.2;
}
&__saved {
display: inline-flex;
align-items: center;
gap: 5px;
padding: 4px 10px;
background: $green-light;
color: $green;
border-radius: 999px;
font-size: 11px;
font-weight: 700;
white-space: nowrap;
flex-shrink: 0;
}
}
// ── Result Card ───────────────────────────────────────────────────────────────
.fdrc-result-card {
margin-top: 16px;
padding: 18px 20px;
background: $green-light;
border: 1.5px solid rgba($green, 0.35);
border-radius: 12px;
&__body {
display: flex;
flex-direction: column;
gap: 12px;
}
}
// ── Senior Citizen Status Banner ──────────────────────────────────────────
.fdrc-sc-status {
display: flex;
align-items: center;
gap: 10px;
padding: 10px 14px;
border-radius: 8px;
font-size: 13px;
font-weight: 600;
&--applied {
background: #ede9fe;
border: 1.5px solid #a78bfa;
color: #4c1d95;
}
&--notice {
background: #fef3c7;
border: 1.5px solid #fcd34d;
color: #78350f;
}
&__icon {
font-size: 16px;
flex-shrink: 0;
}
&__text {
flex: 1;
}
&__bonus {
margin-left: auto;
flex-shrink: 0;
background: #7c3aed;
color: #fff;
padding: 3px 10px;
border-radius: 999px;
font-size: 12px;
font-weight: 700;
}
}
// ── Rate Comparison Block (Normal → Senior) ───────────────────────────────
.fdrc-rate-compare {
display: flex;
align-items: flex-end;
gap: 16px;
flex-wrap: wrap;
&__block {
display: flex;
flex-direction: column;
gap: 3px;
&--sc {
// senior block styling via child classes
}
}
&__tag {
display: inline-flex;
align-items: center;
gap: 4px;
padding: 2px 8px;
background: $gray-200;
color: $gray-600;
border-radius: 999px;
font-size: 10px;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.05em;
white-space: nowrap;
width: fit-content;
&--sc {
background: #ede9fe;
color: #5b21b6;
}
}
&__val {
font-size: 30px;
font-weight: 800;
line-height: 1;
&--strike {
color: $gray-600;
text-decoration: line-through;
}
&--sc {
color: #5b21b6;
}
}
&__sub {
font-size: 11px;
color: $gray-600;
}
&__arrow {
font-size: 22px;
color: $gray-600;
padding-bottom: 8px;
flex-shrink: 0;
}
}
// ── SC Tag (maturity card header) ─────────────────────────────────────────
.fdrc-sc-tag {
display: inline-flex;
align-items: center;
gap: 4px;
margin-left: auto;
padding: 3px 10px;
background: #ede9fe;
color: #5b21b6;
border-radius: 999px;
font-size: 11px;
font-weight: 700;
white-space: nowrap;
}
// ── SC Maturity Row ───────────────────────────────────────────────────────
.fdrc-maturity-row--sc {
.fdrc-maturity-row__label {
color: #5b21b6;
font-weight: 600;
}
.fdrc-maturity-row__value {
color: #5b21b6;
font-weight: 700;
}
}
.fdrc-result-rate {
display: flex;
align-items: baseline;
gap: 8px;
margin-bottom: 10px;
&__value {
font-size: 28px;
font-weight: 800;
color: $green;
line-height: 1;
}
&__label {
font-size: 13px;
color: #166534;
font-weight: 600;
}
}
.fdrc-result-meta {
display: flex;
flex-direction: column;
gap: 5px;
&__item {
display: flex;
align-items: center;
gap: 7px;
font-size: 12px;
color: $gray-700;
i {
color: $green;
font-size: 11px;
}
strong {
color: $gray-900;
}
}
}
// ── Maturity Card ────────────────────────────────────────────────────────────
.fdrc-maturity-card {
margin-top: 16px;
background: #fff;
border: 1.5px solid rgba($green, 0.2);
border-radius: 10px;
overflow: hidden;
&__header {
background: rgba($green, 0.05);
padding: 8px 14px;
border-bottom: 1px solid rgba($green, 0.1);
display: flex;
align-items: center;
gap: 8px;
font-size: 12px;
font-weight: 700;
color: #166534;
i {
font-size: 14px;
}
}
&__body {
padding: 12px 14px;
display: flex;
flex-direction: column;
gap: 8px;
}
}
.fdrc-maturity-row {
display: flex;
align-items: center;
justify-content: space-between;
gap: 20px;
&__label {
font-size: 12px;
color: $gray-600;
}
&__value {
font-size: 13px;
font-weight: 700;
color: $gray-900;
&--highlight {
color: $green;
}
&--big {
font-size: 16px;
color: $green;
}
}
&--interest {
padding-top: 4px;
margin-top: 4px;
border-top: 1px dashed $border;
}
&--total {
padding-top: 8px;
margin-top: 4px;
border-top: 1.5px solid $gray-200;
}
}
.fdrc-payout-hint {
display: flex;
align-items: center;
gap: 8px;
margin-top: 12px;
font-size: 12px;
color: $gray-600;
font-style: italic;
i {
color: $amber;
}
}
// ── Rate Chart Table Card ─────────────────────────────────────────────────
.fdrc-table-card {
background: #fff;
border: 1px solid $border;
border-radius: 12px;
overflow: hidden;
&__header {
display: flex;
align-items: center;
justify-content: space-between;
padding: 14px 20px;
background: $gray-50;
border-bottom: 1px solid $gray-200;
flex-wrap: wrap;
gap: 8px;
}
&__title-row {
display: flex;
align-items: center;
gap: 10px;
i {
color: $blue;
}
}
&__title {
font-size: 14px;
font-weight: 700;
color: $gray-900;
}
}
.fdrc-slab-count {
display: inline-flex;
align-items: center;
padding: 2px 8px;
background: $blue-light;
color: $blue;
border-radius: 999px;
font-size: 11px;
font-weight: 700;
}
.fdrc-highlight-note {
font-size: 12px;
color: $green;
font-weight: 600;
display: flex;
align-items: center;
gap: 5px;
}
.fdrc-table-wrap {
overflow-x: auto;
}
.fdrc-table {
width: 100%;
min-width: 600px;
}
.fdrc-th {
font-size: 11px !important;
font-weight: 700 !important;
text-transform: uppercase;
letter-spacing: 0.06em;
color: $gray-700 !important;
background: $gray-50;
padding: 10px 16px !important;
}
.fdrc-td {
padding: 12px 16px !important;
font-size: 13px;
color: $gray-700;
vertical-align: middle;
&--period {
display: flex;
flex-direction: column;
gap: 2px;
}
&--na {
color: #94a3b8;
}
}
.fdrc-period-range {
font-weight: 700;
color: $gray-900;
font-size: 13px;
}
.fdrc-period-type {
font-size: 11px;
color: $gray-600;
}
.fdrc-rate-badge {
display: inline-flex;
align-items: center;
padding: 3px 10px;
background: $blue-light;
color: $blue;
border-radius: 999px;
font-size: 13px;
font-weight: 700;
}
.fdrc-rate-badge--senior {
background: #ede9fe;
color: #5b21b6;
}
// ── Senior Citizen Rate Comparison View ───────────────────────────────────
.fdrc-senior-rate-view {
margin-bottom: 12px;
&__row {
display: flex;
align-items: center;
gap: 14px;
margin-bottom: 10px;
flex-wrap: wrap;
}
&__normal {
display: flex;
flex-direction: column;
align-items: flex-start;
gap: 4px;
opacity: 0.65;
}
&__senior {
display: flex;
flex-direction: column;
align-items: flex-start;
gap: 4px;
}
&__badge {
display: inline-flex;
align-items: center;
gap: 4px;
padding: 2px 8px;
background: $gray-200;
color: $gray-600;
border-radius: 999px;
font-size: 10px;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.05em;
white-space: nowrap;
&--sr {
background: #ede9fe;
color: #5b21b6;
}
}
&__strike {
font-size: 24px;
font-weight: 700;
color: $gray-600;
text-decoration: line-through;
line-height: 1;
}
&__applied {
font-size: 32px;
font-weight: 800;
color: #5b21b6;
line-height: 1;
}
&__arrow {
font-size: 18px;
color: $gray-600;
flex-shrink: 0;
align-self: center;
margin-top: 16px;
}
&__bonus {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 5px 14px;
background: #ede9fe;
color: #5b21b6;
border-radius: 8px;
font-size: 12px;
font-weight: 700;
i {
font-size: 13px;
}
}
}
.fdrc-senior-badge {
display: inline-flex;
align-items: center;
gap: 4px;
margin-left: 8px;
padding: 2px 8px;
background: #ede9fe;
color: #5b21b6;
border-radius: 999px;
font-size: 11px;
font-weight: 700;
}
.fdrc-calc-field--senior {
flex: 0 0 100%;
display: flex;
align-items: center;
}
.fdrc-senior-label {
display: inline-flex;
align-items: center;
gap: 8px;
cursor: pointer;
user-select: none;
[type='checkbox'] {
width: 16px;
height: 16px;
accent-color: #6366f1;
cursor: pointer;
}
}
.fdrc-senior-text {
display: inline-flex;
align-items: center;
gap: 5px;
font-weight: 600;
color: #4338ca;
font-size: 13px;
i {
color: #6366f1;
}
}
.fdrc-senior-hint {
font-size: 11px;
color: #94a3b8;
}
.fdrc-incentive-btn {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 4px 12px;
height: 32px;
background: transparent;
border: 1.5px solid $border;
border-radius: 6px;
font-size: 12px;
font-weight: 600;
color: $gray-700;
cursor: pointer;
transition:
border-color 0.15s,
color 0.15s;
&:hover {
border-color: $blue;
color: $blue;
}
}
.fdrc-header-row {
background: $gray-50;
}
.fdrc-data-row {
transition: background 0.15s;
&:hover td {
background: $gray-50;
}
&--matched td {
background: $green-light !important;
border-left: 3px solid $green;
}
}
.fdrc-incentives-row {
height: 0;
}
.fdrc-incentives-cell {
padding: 0 !important;
}
.fdrc-incentives-wrap {
overflow: hidden;
}
.fdrc-incentives-inner {
padding: 16px 20px;
background: $gray-50;
border-bottom: 1px solid $border;
}
.fdrc-incentives-title {
font-size: 12px;
font-weight: 700;
color: $gray-700;
margin-bottom: 12px;
display: flex;
align-items: center;
gap: 8px;
i {
color: $amber;
}
}
.fdrc-incentives-table {
width: 100%;
background: #fff;
border: 1px solid $border;
border-radius: 8px;
overflow: hidden;
th {
font-size: 10px !important;
padding: 8px 12px !important;
background: $gray-100;
}
td {
font-size: 12px;
padding: 8px 12px !important;
}
}
.fdrc-empty {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
padding: 40px;
color: $gray-600;
gap: 12px;
i {
font-size: 32px;
opacity: 0.3;
}
span {
font-size: 14px;
}
}
.fdrc-credits {
margin-top: 8px;
font-size: 12px;
summary {
cursor: pointer;
font-weight: 600;
color: #2563eb;
}
&__table {
width: 100%;
margin-top: 6px;
border-collapse: collapse;
th,
td {
padding: 3px 6px;
border-bottom: 1px solid #e2e8f0;
text-align: left;
}
.text-right {
text-align: right;
}
}
}