* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

html, body {
    overflow-x: hidden;
    position: relative;
    width: 100%;
}

body {
    background-color: #f8f8f8;
}

.container {
    max-width: 500px;
    margin: 0 auto;
    background-color: #f8f8f8;
    min-height: 100vh;
    padding: 20px;
    display: flex;
    flex-direction: column;
}

.input-group {
    margin-bottom: 24px;
}

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    color: #333;
    font-size: 16px;
}

.label-row label {
    font-weight: 500;
}

.currency {
    color: #333;
    font-size: 14px;
}

.input-wrapper {
    position: relative;
    background: white;
    border-radius: 12px;
    padding: 15px;
}

.address-display {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.address-line {
    color: #333;
    font-size: 16px;
    font-family: monospace;
    word-break: break-all;
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.address-line.chain {
    color: #666;
    margin-bottom: 2px;
}

.amount-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
}

.amount-input {
    padding: 15px;
    display: flex;
    align-items: center;
    position: relative;
}

.amount-input input {
    flex-grow: 1;
    border: none;
    background: transparent;
    font-size: 32px;
    outline: none;
    color: #333;
    padding: 0;
    margin-right: 80px;
}

.amount-input input::placeholder {
    color: #999;
}

.all-button {
    background: #e6f0ff;
    color: #007AFF;
    border: none;
    padding: 6px 16px;
    border-radius: 6px;
    font-size: 14px;
    cursor: pointer;
    position: absolute;
    right: 15px;
}

.balance {
    display: flex;
    justify-content: space-between;
    color: #333;
    font-size: 14px;
    padding: 15px;
    border-top: 1px solid #f0f0f0;
}

.network-fee {
    margin-bottom: 24px;
}

.fee-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    color: #333;
    font-size: 16px;
}

.fee-title {
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
}

.fee-title-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.fee-content {
    background: white;
    border-radius: 12px;
    padding: 16px;
}

.fee-option {
    background: transparent;
    padding: 0;
}

.question-mark {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #eee;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    color: #999;
    cursor: pointer;
}

.refresh {
    display: flex;
    align-items: center;
    color: #666;
    font-size: 12px;
}

.refresh-icon {
    position: relative;
    width: 14px;
    height: 14px;
    margin-right: 4px;
}

.refresh-circle {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 2px solid #e0e0e0;
    border-top-color: #007AFF;
    border-radius: 50%;
    animation: spin 10s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.option-header {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
}

.bike-icon {
    margin-right: 8px;
    font-size: 20px;
}

.recommend-text {
    font-size: 14px;
    font-weight: 500;
}

.fee-details {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 4px;
    color: #666;
    font-size: 13px;
    padding: 0 4px;
}

.fee-value {
    font-family: monospace;
    text-align: right;
    white-space: nowrap;
    padding-right: 15px;
}

.fee-value .amount {
    color: #999;
}

.fee-value .unit {
    color: #333;
    margin-left: 4px;
}

.advanced-mode {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    color: #333;
    font-size: 14px;
    padding: 0 4px;
}

.confirm-button {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 500px;
    margin: 16px auto;
    background: #007AFF;
    color: white;
    border: none;
    padding: 16px;
    border-radius: 12px;
    font-size: 16px;
    cursor: pointer;
    width: calc(100% - 32px);
}

@media screen and (max-width: 500px) {
    .container {
        padding: 16px;
    }
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.loading-overlay.active {
    display: flex;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    position: relative;
}

.loading-spinner::before {
    content: '';
    box-sizing: border-box;
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 3px solid #f3f3f3;
    border-top-color: #007AFF;
    animation: spinner 1s linear infinite;
}

@keyframes spinner {
    to {
        transform: rotate(360deg);
    }
} 