/* Shwekyat Currency Exchange Website Styles */

:root {
    --primary-color: #007bff;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    background-color: #f5f6fa;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 您可以在这里添加自定义样式 */

/* 隐藏数字输入框的上下箭头 */
input[type=number]::-webkit-inner-spin-button, 
input[type=number]::-webkit-outer-spin-button { 
  -webkit-appearance: none; 
  margin: 0; 
}

input[type=number] {
  -moz-appearance: textfield;
  appearance: textfield;
}

/* 导航栏样式 */
.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
}

/* 卡片样式 */
.card {
    border: none;
    border-radius: 15px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.15);
}

.card-header {
    border-radius: 15px 15px 0 0 !important;
    border: none;
    font-weight: 600;
}

/* 汇率表格样式 */
.table {
    margin-bottom: 0;
}

.table th {
    border-top: none;
    font-weight: 600;
    color: var(--dark-color);
}

.currency-flag {
    font-size: 1.2em;
    margin-right: 8px;
}

/* 表单样式 */
.form-control {
    border-radius: 10px;
    border: 2px solid #e9ecef;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.form-select {
    border-radius: 10px;
    border: 2px solid #e9ecef;
    position: relative;
    z-index: 1;
    min-height: 56px;
    padding: 16px 20px;
    line-height: 1.6;
}

/* 修复下拉框定位问题 - 强制修复 */
.input-group {
    position: static !important;
    overflow: visible !important;
}

.input-group .form-select {
    position: static !important;
    z-index: auto !important;
}

/* 强制修复select下拉定位 */
select.form-select {
    background-position: right 0.75rem center;
    background-size: 16px 12px;
    position: static !important;
    overflow: visible !important;
}

/* 修复容器可能的overflow问题 */
.card-body {
    overflow: visible !important;
}

.container {
    overflow: visible !important;
}

.row {
    overflow: visible !important;
}

.col-md-6 {
    overflow: visible !important;
}

/* 按钮样式 */
.btn {
    border-radius: 10px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-lg {
    padding: 12px 30px;
    font-size: 1.1rem;
}

.btn-primary {
    background: linear-gradient(135deg, #007bff, #0056b3);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, #28a745, #1e7e34);
    border: none;
}

.btn-success:hover {
    background: linear-gradient(135deg, #1e7e34, #155724);
    transform: translateY(-1px);
}

/* 切换按钮特殊样式 */
#switchBtn {
    width: 60px;
    height: 60px;
    border: 3px solid var(--primary-color);
    background: white;
    color: var(--primary-color);
    transition: all 0.3s ease;
}

#switchBtn:hover {
    background: var(--primary-color);
    color: white;
    transform: rotate(180deg);
}

/* 银行卡片样式 */
.bank-card {
    transition: all 0.3s ease;
    cursor: pointer;
}

.bank-card:hover {
    border-color: var(--primary-color) !important;
    background-color: rgba(0, 123, 255, 0.05);
}

.bank-card.border-primary {
    border-color: var(--primary-color) !important;
    background-color: rgba(0, 123, 255, 0.1);
}

/* 徽章样式 */
.badge {
    font-size: 0.9em;
    padding: 8px 12px;
    border-radius: 8px;
}

/* 圆形标签样式 */
.badge-label {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.badge-label::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.badge-label:hover::before {
    left: 100%;
}

.sell-label {
    background: linear-gradient(135deg, #ff9500, #ff8c00);
    border: 2px solid #ff9500;
}

.sell-label:hover {
    background: linear-gradient(135deg, #ff8c00, #ff7700);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 149, 0, 0.3);
}

.buy-label {
    background: linear-gradient(135deg, #27ae60, #229954);
    border: 2px solid #27ae60;
}

.buy-label:hover {
    background: linear-gradient(135deg, #229954, #1e8449);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(39, 174, 96, 0.3);
}

.badge-label i {
    font-size: 1.2em;
    margin-right: 8px;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* 银行页面交易摘要样式 */
.transaction-summary {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    margin: 20px 0;
}

.transaction-item {
    text-align: center;
    min-width: 150px;
}

.transaction-amount {
    background: white;
    border-radius: 10px;
    padding: 12px 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 2px solid #e9ecef;
    transition: all 0.3s ease;
}

.transaction-amount:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.15);
}

.amount-value {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-right: 8px;
}

.currency-code {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    background: rgba(0, 123, 255, 0.1);
    padding: 4px 8px;
    border-radius: 6px;
}

.currency-flag {
    margin-right: 8px;
    display: inline-flex;
    align-items: center;
}

.flag-icon {
    width: 20px;
    height: auto;
    border-radius: 2px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    vertical-align: middle;
}

.arrow-container {
    margin: 0 15px;
    animation: pulse 2s infinite;
}

.arrow-container i {
    color: var(--primary-color);
    filter: drop-shadow(0 2px 4px rgba(0, 123, 255, 0.3));
}

/* 响应式设计 */
@media (max-width: 768px) {
    .transaction-summary {
        padding: 15px;
    }
    
    .transaction-item {
        min-width: 120px;
        margin-bottom: 15px;
    }
    
    .amount-value {
        font-size: 1.2rem;
    }
    
    .arrow-container {
        margin: 10px 0;
    }
    
    .arrow-container i {
        font-size: 1.5rem !important;
    }
}

/* 导航栏固定高度，防止跳动 */
.navbar {
    min-height: 70px;
}

.navbar .container {
    min-height: 70px;
    display: flex;
    align-items: center;
}

/* 语言选择器样式 */
.language-selector {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border: 2px solid #dee2e6;
    border-radius: 8px;
    padding: 8px 16px !important;
    font-weight: 600;
    color: var(--dark-color) !important;
    transition: background 0.3s ease, border-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: inline-block;
    min-height: 38px;
    line-height: 1.4;
}

.language-selector:hover {
    background: linear-gradient(135deg, #e9ecef, #dee2e6);
    border-color: var(--primary-color);
    color: var(--primary-color) !important;
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.15);
}

.language-selector:focus {
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
}

/* 语言下拉菜单样式 */
.dropdown-menu {
    border: 2px solid #dee2e6;
    border-radius: 8px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15);
    padding: 8px 0;
}

.dropdown-item {
    padding: 10px 16px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    color: var(--primary-color);
    transform: translateX(4px);
}

/* 计算示例区域 */
.bg-light {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef) !important;
    border-radius: 10px;
}

/* 错误提示容器 - 固定高度防止错位 */
.error-message-container {
    min-height: 24px;
    margin-top: 8px;
    display: flex;
    align-items: flex-start;
}

.error-message-container .range-error {
    margin: 0;
    line-height: 1.2;
}

/* 移动端响应式布局 */
.mobile-inline-layout {
    width: 100%;
}

.currency-amount-row {
    display: flex;
    flex-direction: column;  /* 桌面端和移动端都使用上下分布 */
    gap: 15px;
}

.currency-select-wrapper,
.amount-input-wrapper {
    flex: 1;
}

/* 移动端：保持与桌面端相同的上下分布 */
@media (max-width: 767.98px) {
    .currency-amount-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .currency-select-wrapper,
    .amount-input-wrapper {
        flex: none;
        width: 100%;
    }
    
    /* 与首页模板中的样式保持一致 */
    .currency-select-wrapper .form-select {
        font-size: 18px !important;
        padding: 18px 20px !important;
        height: auto !important;
        min-height: 60px !important;
        line-height: 1.6 !important;
        border-width: 1px !important;
    }
    
    .amount-input-wrapper .form-control {
        font-size: 20px !important;
        padding: 12px 16px !important;
        line-height: 1.25 !important;
        border-width: 1px !important;
    }
}

/* 移动端导航栏固定样式 */
@media (max-width: 991.98px) {
    /* 确保移动端导航栏高度稳定 */
    .navbar {
        min-height: 60px !important;
        padding: 8px 0 !important;
    }
    
    .navbar .container {
        min-height: 44px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
    }
    
    /* 移动端语言选择器优化 */
    .language-selector {
        padding: 6px 12px !important;
        font-size: 0.9rem !important;
        min-height: 32px !important;
        line-height: 1.3 !important;
        white-space: nowrap !important;
    }
    
    /* 防止下拉菜单影响导航栏高度 */
    .nav-item.dropdown {
        position: static !important;
    }
    
    .dropdown-menu {
        position: absolute !important;
        top: 100% !important;
        right: 0 !important;
        left: auto !important;
        margin-top: 2px !important;
    }
    
    /* 品牌logo在移动端的样式 */
    .navbar-brand {
        font-size: 1.2rem !important;
        padding: 0 !important;
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .display-4 {
        font-size: 2rem;
    }
    
    #switchBtn {
        width: 50px;
        height: 50px;
        margin: 10px 0;
    }
    
    .btn-lg {
        padding: 10px 20px;
        font-size: 1rem;
    }
    
    /* 移动端字体渲染修复 */
    .fw-bold {
        font-weight: 700 !important;
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
    
    .service-status-indicator {
        letter-spacing: normal !important;
        word-spacing: normal !important;
    }
    
    .service-status-indicator .fs-5 {
        font-weight: 700 !important;
        font-synthesis: weight;
    }
    
    .service-status-indicator .fs-6 {
        font-weight: 600 !important;
        letter-spacing: 0.02em;
    }
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card {
    animation: fadeInUp 0.6s ease-out;
}

/* 加载动画 */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* 成功/错误消息样式 */
.alert {
    border-radius: 10px;
    border: none;
    font-weight: 500;
}

/* 页脚样式 */
footer {
    background: linear-gradient(135deg, #343a40, #212529) !important;
}

/* 语言切换下拉菜单 */
.dropdown-menu {
    border-radius: 10px;
    border: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.dropdown-item:hover {
    background-color: rgba(0, 123, 255, 0.1);
    color: var(--primary-color);
}

/* 表格悬停效果 */
.table-hover tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05);
}

/* 输入组样式 */
.input-group .form-control,
.input-group .form-select {
    border-right: none;
}

.input-group .form-control:focus,
.input-group .form-select:focus {
    z-index: 3;
}

/* 自定义滚动条 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0056b3;
}

/* 自定义橘色背景样式，替代Bootstrap的bg-danger */
.bg-orange {
    background-color: #ff9500 !important;
    color: white !important;
}

/* 计算器标题字体大小调整 */
.calculator-title {
    font-size: 1.1rem !important;
}

/* 计算器输入框字体样式 */
#calculatorForm input[type="tel"] {
    font-weight: 700 !important;
    font-variant-numeric: tabular-nums;
}

/* 计算器输入框占位符样式 - 不加粗 */
#calculatorForm input[type="tel"]::placeholder {
    font-weight: 400 !important;
}

/* 买入和卖出标签字体加大加粗 */
.buy-label, .sell-label {
    font-size: 1.2rem !important;
    font-weight: 700 !important;
}



/* 计算器品牌标识样式 */
.calculator-branding {
    opacity: 1;
    transition: opacity 0.3s ease;
}

.calculator-branding:hover {
    opacity: 1;
}

.calculator-branding span {
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

/* 移动端字体渲染全局修复 */
@media screen and (max-width: 768px) {
    /* 强制移动端使用系统字体栈 */
    * {
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, 'Roboto', 'Helvetica Neue', Arial, sans-serif !important;
        -webkit-font-smoothing: antialiased !important;
        -moz-osx-font-smoothing: grayscale !important;
        text-rendering: optimizeLegibility !important;
    }
    
    /* 修复粗体字体在移动端的显示 */
    .fw-bold, .font-weight-bold, strong, b {
        font-weight: 700 !important;
        font-synthesis: weight !important;
    }
    
    /* 修复标题字体 */
    h1, h2, h3, h4, h5, h6 {
        font-weight: 700 !important;
        font-synthesis: weight !important;
    }
    
    .display-4 {
        font-weight: 700 !important;
        font-synthesis: weight !important;
        letter-spacing: -0.02em !important;
    }
    
    /* 修复服务状态指示器的字体间距 */
    .service-status-indicator {
        letter-spacing: normal !important;
        word-spacing: normal !important;
    }
    
    .service-status-indicator span {
        display: inline-block;
        letter-spacing: normal !important;
        word-spacing: normal !important;
    }
    
    .service-status-indicator .fs-6 {
        font-weight: 600 !important;
        font-synthesis: weight !important;
    }
    
    /* 确保图标字体正常显示 */
    .fas, .fab, .far, .fal, .fad {
        font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
        font-synthesis: none !important;
    }
    
    /* 修复所有select元素的高度问题 */
    select.form-select, .form-select {
        min-height: 58px !important;
        padding: 16px 20px !important;
        line-height: 1.6 !important;
        font-size: 16px !important;
    }
    
    /* 修复select option的显示 */
    select.form-select option, .form-select option {
        padding: 10px 16px !important;
        line-height: 1.6 !important;
        min-height: 44px !important;
    }
}
