/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Navigation */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-menu a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: opacity 0.3s;
}

.nav-menu a:hover,
.nav-menu a.active {
    opacity: 0.8;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-block {
    display: block;
    width: 100%;
}

.btn-large {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5rem 0;
    text-align: center;
}

.hero-title {
    font-size: 3rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

.hero-subtitle {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Features Section */
.features {
    padding: 4rem 0;
    background: white;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: #333;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: #667eea;
}

/* How It Works */
.how-it-works {
    padding: 4rem 0;
    background: #f9f9f9;
}

.steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.step {
    text-align: center;
}

.step-number {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin: 0 auto 1rem;
}

/* CTA Section */
.cta {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.cta h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* Calculator Section */
.calculator-section {
    padding: 3rem 0;
    min-height: calc(100vh - 200px);
}

.page-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.page-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 3rem;
}

.calculator-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.calculator-form,
.calculator-result {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.calculator-form h2,
.calculator-result h2 {
    margin-bottom: 1.5rem;
    color: #667eea;
}

/* Form Styles */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: #666;
    font-size: 0.875rem;

.form-group textarea,
.form-group select {
    width: 100% !important;
    padding: 0.75rem !important;
    border: 2px solid #e0e0e0 !important;
    border-radius: 8px !important;
    font-size: 1rem !important;
    font-family: inherit !important;
    transition: border-color 0.3s !important;
    background-color: white !important;
}

.form-group textarea {
    resize: vertical !important;
    min-height: 120px !important;
    line-height: 1.6 !important;
}

.form-group select {
    cursor: pointer !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.75rem center !important;
    background-size: 12px !important;
    padding-right: 2.5rem !important;
    height: auto !important;
}

.form-group textarea:focus,
.form-group select:focus {
    outline: none !important;
    border-color: #667eea !important;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1) !important;
}

/* Additional specific selectors */
textarea#description {
    width: 100% !important;
    padding: 0.75rem !important;
    border: 2px solid #e0e0e0 !important;
    border-radius: 8px !important;
    font-size: 1rem !important;
    font-family: inherit !important;
    min-height: 120px !important;
    line-height: 1.6 !important;
    resize: vertical !important;
}

select#status {
    width: 100% !important;
    padding: 0.75rem !important;
    border: 2px solid #e0e0e0 !important;
    border-radius: 8px !important;
    font-size: 1rem !important;
    background-color: white !important;
    cursor: pointer !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23333' d='M6 9L1 4h10z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.75rem center !important;
    background-size: 12px !important;
    padding-right: 2.5rem !important;
}

}

/* Result Styles */
.result-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    margin-bottom: 2rem;
}

.result-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

.result-card .result-value {
    font-size: 2rem;
    font-weight: bold;
}

.result-details {
    background: #f9f9f9;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.result-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e0e0e0;
}

.result-item:last-child {
    border-bottom: none;
}

.result-item.highlight {
    background: #fff3cd;
    padding: 1rem;
    margin: 0.5rem -0.5rem;
    border-radius: 8px;
    border: none;
}

.result-label {
    font-weight: 600;
    color: #333;
}

.result-value {
    color: #667eea;
    font-weight: 600;
}

.result-info {
    background: #e7f3ff;
    padding: 1rem;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.result-info ul {
    margin-left: 1.5rem;
    margin-top: 0.5rem;
}

.result-placeholder {
    text-align: center;
    padding: 3rem 1rem;
    color: #999;
}

.placeholder-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

/* Alert */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.alert-error {
    background: #fee;
    color: #c33;
    border: 1px solid #fcc;
}

/* Login Page */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: white;
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header h1 {
    font-size: 2rem;
    color: #667eea;
    margin-bottom: 0.5rem;
}

.login-header h2 {
    font-size: 1.5rem;
    color: #333;
}

.login-form {
    margin-bottom: 1rem;
}

.login-footer {
    text-align: center;
    margin-top: 1.5rem;
}

.login-footer a {
    color: #667eea;
    text-decoration: none;
}

/* Dashboard */
.dashboard {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem 0;
}

.sidebar-header {
    padding: 0 1.5rem;
    margin-bottom: 2rem;
}

.sidebar-header h2 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.admin-name {
    opacity: 0.8;
    font-size: 0.9rem;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
}

.nav-item {
    padding: 1rem 1.5rem;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: background 0.3s;
}

.nav-item:hover,
.nav-item.active {
    background: rgba(255,255,255,0.1);
}

.main-content {
    flex: 1;
    padding: 2rem;
    background: #f5f5f5;
}

.content-header {
    margin-bottom: 2rem;
}

.content-header h1 {
    font-size: 2rem;
    color: #333;
    margin-bottom: 0.5rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-icon {
    font-size: 2.5rem;
}

.stat-info h3 {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.stat-info .stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: #667eea;
}

.content-section {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.content-section h2 {
    margin-bottom: 1.5rem;
    color: #333;
}

.table-container {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.data-table th {
    background: #f9f9f9;
    font-weight: 600;
    color: #333;
}

.empty-state {
    text-align: center;
    padding: 3rem;
    color: #999;
}

.quick-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.quick-link-card {
    background: #f9f9f9;
    padding: 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    color: #333;
    transition: transform 0.3s;
}

.quick-link-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.quick-link-card span {
    font-size: 2rem;
    display: block;
    margin-bottom: 0.5rem;
}

.quick-link-card h3 {
    color: #667eea;
    margin-bottom: 0.5rem;
}

/* Footer */
.footer {
    background: #333;
    color: white;
    padding: 2rem 0;
    text-align: center;
}

.footer p {
    margin: 0.5rem 0;
}

/* Error Page */
.error-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
}

.error-container {
    text-align: center;
    padding: 2rem;
}

.error-code {
    font-size: 6rem;
    color: #667eea;
    margin-bottom: 1rem;
}

.error-title {
    font-size: 2rem;
    color: #333;
    margin-bottom: 2rem;
}

.error-stack {
    background: #f9f9f9;
    padding: 1rem;
    border-radius: 8px;
    text-align: left;
    margin-bottom: 2rem;
    overflow-x: auto;
}

/* Responsive */
@media (max-width: 768px) {
    .calculator-container {
        grid-template-columns: 1fr;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .dashboard {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
    }
    
    .nav-menu {
        gap: 1rem;
    }
}

/* Made with Bob */


/* Banks Management */
.banks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
}

.bank-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s;
}

.bank-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.bank-card-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.bank-info {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.bank-logo {
    width: 50px;
    height: 50px;
    object-fit: contain;
    border-radius: 8px;
}

.bank-logo-placeholder {
    width: 50px;
    height: 50px;
    background: #f0f0f0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.bank-info h3 {
    margin: 0;
    font-size: 1.1rem;
    color: #333;
}

.bank-code {
    display: inline-block;
    background: #667eea;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 0.25rem;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-badge.active {
    background: #d4edda;
    color: #155724;
}

.status-badge.inactive {
    background: #f8d7da;
    color: #721c24;
}

.bank-card-body {
    padding: 1.5rem;
}

.bank-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.bank-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 1rem;
}

.stat-item {
    text-align: center;
}

.stat-item .stat-label {
    display: block;
    font-size: 0.75rem;
    color: #999;
    margin-bottom: 0.25rem;
}

.stat-item .stat-value {
    display: block;
    font-size: 1.25rem;
    font-weight: bold;
    color: #667eea;
}
.bank-website {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e0e0e0;
    font-size: 0.875rem;
    color: #666;
}

.bank-website a {
    color: #667eea;
    text-decoration: none;
    word-break: break-all;
}

.bank-website a:hover {
    text-decoration: underline;
}


.bank-card-footer {
    padding: 1rem 1.5rem;
    background: #f9f9f9;
    display: flex;
    gap: 0.5rem;
    justify-content: space-between;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
/* Bank Logo Styles for Table */
.bank-logo-small {
    width: 50px;
    height: 50px;
    object-fit: contain;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    background: white;
    padding: 4px;
    box-sizing: border-box;
}

.bank-logo-placeholder-small {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    font-size: 1.5rem;
}

.bank-code-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: #f0f0f0;
    border-radius: 4px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #666;
}

.bank-website-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.875rem;
}

.bank-website-link:hover {
    text-decoration: underline;
}

.stat-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: #e8f0fe;
    color: #1967d2;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.875rem;
}

.action-buttons {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Pagination Styles */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
    padding: 1rem 0;
}

.pagination-btn {
    padding: 0.5rem 1rem;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s;
}

.pagination-btn:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.pagination-numbers {
    display: flex;
    gap: 0.25rem;
}

.pagination-number {
    padding: 0.5rem 0.75rem;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    color: #333;
    text-decoration: none;
    min-width: 40px;
    text-align: center;
    transition: all 0.3s;
}

.pagination-number:hover {
    background: #f5f5f5;
    border-color: #667eea;
}

.pagination-number.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
    font-weight: 600;
}

.pagination-ellipsis {
    padding: 0.5rem 0.75rem;
    color: #999;
}

.pagination-info {
    text-align: center;
    color: #666;
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

}

/* Alert Messages */
.alert {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

/* Form Styles */
.form-container {
    max-width: 600px;
    margin: 0 auto;
}

.form-section {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

/* Bank Details */
.details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.detail-card {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.detail-card h3 {
    margin-bottom: 1rem;
    color: #667eea;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e0e0e0;
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-label {
    font-weight: 600;
    color: #666;
}

.detail-value {
    color: #333;
}

/* Products & Rates Tables */
.products-list,
.rates-list {
    margin-top: 1rem;
}

.product-item,
.rate-item {
    background: #f9f9f9;
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 0.75rem;
}

.product-item h4 {
    margin-bottom: 0.5rem;
    color: #333;
}

.product-item p {
    color: #666;
    font-size: 0.9rem;
}

.rate-item {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
}

.rate-field {
    display: flex;
    flex-direction: column;
}

.rate-field label {
    font-size: 0.75rem;
    color: #999;
    margin-bottom: 0.25rem;
}

.rate-field span {
    font-weight: 600;
    color: #333;
}

/* Logs Table */
.logs-table {
    width: 100%;
    margin-top: 1rem;
}

.logs-table th,
.logs-table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.logs-table th {
    background: #f9f9f9;
    font-weight: 600;
    color: #333;
}

.log-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.log-status.success {
    background: #d4edda;
    color: #155724;
}

.log-status.failed {
    background: #f8d7da;
    color: #721c24;
}

.log-status.partial {

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: slideDown 0.3s;
}

.custom-modal-large {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
}

.custom-modal-content-large {
    max-width: 1200px !important;
    width: 95% !important;
    margin: 0 !important;
    max-height: 90vh !important;
    overflow: hidden !important;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    margin: 0;
    color: #333;
    font-size: 1.5rem;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #999;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
}

.modal-close:hover {
    background: #f0f0f0;
    color: #333;
}

.modal-body {
    padding: 2rem;
}

.modal-body p {
    margin: 0 0 1rem 0;
    color: #666;
    line-height: 1.6;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
}

.modal-icon {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 1rem;
}

.modal-icon.info { color: #667eea; }
.modal-icon.success { color: #28a745; }
.modal-icon.error { color: #dc3545; }
.modal-icon.warning { color: #ffc107; }

/* Loading Spinner */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.7;
}

.btn-loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 1s ease-in-out infinite;
}
    background: #fff3cd;
    color: #856404;
}


/* ========================================
   CALCULATION RESULT STYLES
   ======================================== */

.calculation-result {
    display: none;
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-top: 2rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f0f0f0;
}

.result-header h2 {
    color: #667eea;
    font-size: 1.8rem;
    font-weight: 600;
}

/* Result Summary Cards */
.result-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    transition: transform 0.3s ease;
}

.summary-card:hover {
    transform: translateY(-5px);
}

.summary-card.highlight {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.summary-label {
    font-size: 0.9rem;
    opacity: 0.8;
    margin-bottom: 0.5rem;
}

.summary-card.highlight .summary-label {
    opacity: 0.9;
}

.summary-value {
    font-size: 1.8rem;
    font-weight: 700;
}

/* Result Details */
.result-details {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.detail-card {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 1.5rem;
    border-left: 4px solid #667eea;
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #dee2e6;
}

.detail-header h3 {
    color: #333;
    font-size: 1.3rem;
    font-weight: 600;
}

.period-badge {
    background: #667eea;
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.detail-content {
    display: grid;
    gap: 0.8rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem;
    background: white;
    border-radius: 6px;
}

.detail-row.highlight {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
}

.detail-label {
    color: #666;
}

.detail-row.highlight .detail-label {
    color: white;
    opacity: 0.9;
}

.detail-value {
    font-weight: 600;
    color: #333;
}

.detail-row.highlight .detail-value {
    color: white;
}

.detail-note {
    margin-top: 1rem;
    padding: 1rem;
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    border-radius: 6px;
    color: #856404;
    font-size: 0.9rem;
}

.detail-note i {
    margin-right: 0.5rem;
}

/* Input Summary */
.result-input-summary {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    margin-top: 2rem;
}

.result-input-summary h3 {
    color: #333;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

.input-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.input-item {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.input-label {
    font-size: 0.85rem;
    color: #666;
}

.input-value {
    font-weight: 600;
    color: #333;
    font-size: 1.1rem;
}

/* Spinner for loading state */
.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 768px) {
    .calculation-result {
        padding: 1.5rem;
    }

    .result-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }

    .result-header h2 {
        font-size: 1.5rem;
    }

    .result-summary {
        grid-template-columns: 1fr;
    }

    .summary-value {
        font-size: 1.5rem;
    }

    .detail-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .detail-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
    }

    .input-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .result-header h2 {
        font-size: 1.3rem;
    }

    .summary-value {
        font-size: 1.3rem;
    }

    .detail-header h3 {
        font-size: 1.1rem;
    }
}


/* Input Error Styling */
.input-error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

.error-message {
    color: #dc3545;
    font-size: 12px;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 5px;
}


/* DP Slider Styling */
.dp-slider-container {
    margin-top: 10px;
}

.dp-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    margin-bottom: 15px;
    color: white;
}

.dp-percentage {
    font-size: 32px;
    font-weight: 700;
}

.dp-amount {
    font-size: 18px;
    font-weight: 600;
    text-align: right;
}

.dp-slider {
    width: 100%;
    height: 8px;
    border-radius: 5px;
    background: #e0e0e0;
    outline: none;
    -webkit-appearance: none;
    margin: 10px 0;
}

.dp-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.dp-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.6);
}

.dp-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.dp-slider::-moz-range-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.6);
}

.dp-slider-labels {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}


/* Tier Card Styling for Fixed Berjenjang */
.tier-card {
    border-left: 4px solid #2196f3;
    background: linear-gradient(to right, #e3f2fd 0%, #ffffff 100%);
}

.tier-card:nth-child(even) {
    border-left-color: #4caf50;
    background: linear-gradient(to right, #e8f5e9 0%, #ffffff 100%);
}

.tier-card:nth-child(3n) {
    border-left-color: #ff9800;
    background: linear-gradient(to right, #fff3e0 0%, #ffffff 100%);
}

.tier-card .detail-header h3 {
    color: #1976d2;
}

/* ===================================
   COMPACT RATE CARD STYLES
   Minimalist, Informative & Elegant
   =================================== */

/* Rate Card Container */
.rate-card {
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.rate-card:hover {
    border-color: #6366f1;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.15);
    transform: translateY(-2px);
}

.rate-card.selected {
    border-color: #6366f1;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

/* Compact Header */
.rate-compact-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.rate-type-badge-compact {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 4px 10px;
    border-radius: 12px;
    text-transform: uppercase;
}

.rate-type-badge-compact.badge-fixed {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    color: #1e40af;
}

.rate-type-badge-compact.badge-floating {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
}

.rate-type-badge-compact.badge-tiered {
    background: linear-gradient(135deg, #ddd6fe 0%, #c4b5fd 100%);
    color: #5b21b6;
}

.rate-type-badge-compact.badge-fixed-cap {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    color: #065f46;
}

.rate-percentage-compact {
    font-size: 28px;
    font-weight: 800;
    color: #1e293b;
    line-height: 1;
}

/* Period Text */
.rate-period-compact {
    font-size: 13px;
    color: #64748b;
    margin-bottom: 12px;
    font-weight: 500;
}

/* Tiered Title */
.tiered-title-compact,
.fixed-cap-title-compact {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 10px;
    line-height: 1.3;
}

/* Tiers Container - Compact */
.tiers-container-compact {
    background: #f8fafc;
    border-radius: 8px;
    padding: 8px;
    margin-bottom: 12px;
}

.tier-item-compact {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 8px;
    background: white;
    border-radius: 6px;
    margin-bottom: 4px;
    border-left: 3px solid #6366f1;
}

.tier-item-compact:last-child {
    margin-bottom: 0;
}

.tier-badge-compact {
    font-size: 11px;
    font-weight: 600;
    color: #6366f1;
    min-width: 50px;
}

.tier-rate-compact {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    min-width: 60px;
    text-align: center;
}

.tier-period-compact {
    font-size: 11px;
    color: #64748b;
    text-align: right;
    flex: 1;
}

/* Fixed & Cap Periods Container */
.periods-container-compact {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f8fafc;
    border-radius: 8px;
    padding: 8px;
    margin-bottom: 12px;
}

.period-item-compact {
    flex: 1;
    background: white;
    border-radius: 6px;
    padding: 8px;
    text-align: center;
}

.period-badge-compact {
    display: block;
    font-size: 10px;
    font-weight: 600;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.period-badge-compact.fixed {
    color: #1e40af;
}

.period-badge-compact.cap {
    color: #065f46;
}

.period-rate-compact {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 2px;
}

.period-duration-compact {
    display: block;
    font-size: 10px;
    color: #64748b;
}

.period-separator-compact {
    font-size: 18px;
    color: #94a3b8;
    font-weight: 600;
}

/* Details Section - Compact 2 Column Layout */
.rate-details-compact {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.rate-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    line-height: 1.5;
}

.detail-label {
    color: #64748b;
    font-weight: 500;
    flex-shrink: 0;
}

.detail-value {
    color: #1e293b;
    font-weight: 600;
    text-align: right;
}

/* Responsive Design */
@media (max-width: 768px) {
    .rate-card {
        padding: 14px;
    }
    
    .rate-percentage-compact {
        font-size: 24px;
    }
    
    .tier-rate-compact,
    .period-rate-compact {
        font-size: 14px;
    }
    
    .rate-detail-row {
        font-size: 11px;
    }
}

/* ===================================
   INFO TOOLTIP STYLES
   =================================== */

.info-tooltip {
    display: inline-block;
    margin-left: 6px;
    font-size: 14px;
    cursor: help;
    position: relative;
    color: #6366f1;
    transition: transform 0.2s ease;
}

.info-tooltip:hover {
    transform: scale(1.2);
}

.info-tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background: #1e293b;
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 400;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 250px;
    white-space: normal;
    text-align: center;
    line-height: 1.4;
}

.info-tooltip::after {
    content: '';
    position: absolute;
    bottom: 115%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #1e293b;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.info-tooltip:hover::before,
.info-tooltip:hover::after {
    opacity: 1;
}

/* Mobile responsive tooltip */
@media (max-width: 768px) {
    .info-tooltip::before {
        max-width: 200px;
        font-size: 11px;
        padding: 6px 10px;
    }
}


/* Result actions */
.result-actions {
    margin-top: 30px;
    text-align: center;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.btn-detail {
    padding: 15px 30px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.btn-detail:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}
