* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: #0F1115;
    color: #F5F5F5;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.app {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.topbar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 22px;
    border-bottom: 1px solid #1F2329;
    background: #14171C;
}

.brand-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    object-fit: cover;
    background: #1A1D22;
}

.brand-name {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.2px;
}

.content {
    flex: 1;
    padding: 22px 18px 10px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.card {
    background: #14171C;
    border: 1px solid #1F2329;
    border-radius: 18px;
    padding: 24px 20px;
}

.hidden {
    display: none !important;
}

.title {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 6px;
}

.subtitle {
    font-size: 13px;
    color: #9AA0A6;
    margin-bottom: 20px;
}

.denoms {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
}

.denom-btn {
    background: #1A1D22;
    border: 1px solid #262B33;
    color: #F5F5F5;
    padding: 14px 10px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.denom-btn:hover {
    border-color: #1FCB7A;
}

.denom-btn.active {
    background: #1FCB7A;
    border-color: #1FCB7A;
    color: #0F1115;
}

.custom-nominal {
    margin-bottom: 22px;
}

.custom-nominal label {
    display: block;
    font-size: 12px;
    color: #9AA0A6;
    margin-bottom: 8px;
}

.custom-nominal input {
    width: 100%;
    background: #1A1D22;
    border: 1px solid #262B33;
    color: #F5F5F5;
    padding: 14px;
    border-radius: 12px;
    font-size: 14px;
}

.custom-nominal input:focus {
    outline: none;
    border-color: #1FCB7A;
}

.btn-primary {
    width: 100%;
    background: #1FCB7A;
    color: #0F1115;
    border: none;
    padding: 15px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.15s ease;
}

.btn-primary:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.btn-secondary {
    width: 100%;
    background: transparent;
    color: #E0524B;
    border: 1px solid #3A2226;
    padding: 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 18px;
}

.btn-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.form-error {
    color: #E0524B;
    font-size: 12px;
    margin-top: 12px;
    min-height: 16px;
}

.qr-amount {
    font-size: 26px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 18px;
    color: #1FCB7A;
}

.qr-wrap {
    display: flex;
    justify-content: center;
    margin-bottom: 18px;
}

.qr-box {
    background: #FFFFFF;
    padding: 16px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 224px;
    min-height: 224px;
}

.qr-note {
    text-align: center;
    font-size: 12px;
    color: #9AA0A6;
    margin-bottom: 16px;
}

.qr-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #5C6168;
    padding-top: 14px;
    border-top: 1px solid #1F2329;
}

.status-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 800;
    margin: 0 auto 18px;
}

.status-icon.success {
    background: rgba(31, 203, 122, 0.14);
    color: #1FCB7A;
}

.status-icon.warning {
    background: rgba(224, 82, 75, 0.14);
    color: #E0524B;
}

#statusSection .title,
#statusSection .subtitle {
    text-align: center;
}

#statusSection .subtitle {
    margin-bottom: 22px;
}

.history-title {
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 14px;
}

.history-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.history-empty {
    font-size: 12px;
    color: #5C6168;
    text-align: center;
    padding: 10px 0;
}

.history-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #1A1D22;
    border-radius: 12px;
    padding: 12px 14px;
}

.history-left {
    display: flex;
    flex-direction: column;
}

.history-amount {
    font-size: 14px;
    font-weight: 700;
}

.history-date {
    font-size: 11px;
    color: #9AA0A6;
    margin-top: 3px;
}

.history-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 5px 10px;
    border-radius: 999px;
}

.history-badge.pending {
    background: rgba(154, 160, 166, 0.16);
    color: #9AA0A6;
}

.history-badge.paid {
    background: rgba(31, 203, 122, 0.16);
    color: #1FCB7A;
}

.history-badge.expired,
.history-badge.cancel {
    background: rgba(224, 82, 75, 0.16);
    color: #E0524B;
}

.footer {
    text-align: center;
    font-size: 11px;
    color: #5C6168;
    padding: 22px 18px 26px;
}

.footer a {
    color: #9AA0A6;
    text-decoration: none;
    font-weight: 600;
}

.footer a:hover {
    color: #1FCB7A;
}

.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(6, 7, 9, 0.72);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 100;
}

.modal-box {
    background: #14171C;
    border: 1px solid #1F2329;
    border-radius: 18px;
    padding: 30px 26px;
    max-width: 340px;
    width: 100%;
    text-align: center;
}

.modal-icon {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    background: rgba(31, 203, 122, 0.14);
    color: #1FCB7A;
    font-size: 28px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.modal-box h2 {
    font-size: 18px;
    margin-bottom: 10px;
}

.modal-amount {
    font-size: 24px;
    font-weight: 800;
    color: #1FCB7A;
    margin-bottom: 6px;
}

.modal-trx {
    font-size: 12px;
    color: #9AA0A6;
    margin-bottom: 22px;
}
