/* Renewal layout (login page side-by-side) */
.login-container.renewal-visible {
    max-width: 860px;
}

.login-container.renewal-visible .login-split {
    display: flex;
    align-items: flex-start;
    gap: 0;
}

.login-container.renewal-visible .login-form-wrap {
    padding-right: 24px;
}

.info-message {
    display: none;
    background: transparent;
    border: none;
    text-align: center;
    font-weight: 700;
    font-size: 15px;
    padding: 16px 24px 0;
    margin: 0;
}

.info-message.banner-notice.show {
    display: block;
    width: 100%;
}

.info-message.banner-error {
    color: #e74c3c;
}

.info-message.banner-success {
    color: #27ae60;
}

.renewal-panel {
    display: none;
    text-align: center;
    flex: 1;
    min-width: 0;
}

.renewal-panel.show {
    display: block;
}

.login-container.renewal-visible .renewal-panel.show {
    border-left: 2px solid #f0f0f0;
    padding-left: 24px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.renewal-title {
    font-size: 18px;
    font-weight: 700;
    color: #8B1874;
    margin-bottom: 8px;
}

.renewal-meta {
    font-size: 14px;
    color: #555;
    margin-bottom: 16px;
    line-height: 1.5;
}

.renewal-pay-box {
    background: #fafafa;
    border: 2px dashed #ddd;
    border-radius: 12px;
    padding: 20px 16px;
    margin-bottom: 16px;
    text-align: center;
}

.renewal-qr-wrap {
    display: none;
}

.renewal-qr-wrap.show {
    display: block;
}

.renewal-qr-wrap canvas {
    width: 220px;
    height: 220px;
    max-width: 100%;
    border-radius: 8px;
    background: #fff;
    padding: 8px;
    border: 1px solid #eee;
}

.renewal-qr-amount {
    font-size: 22px;
    font-weight: 700;
    color: #8B1874;
    margin: 12px 0 6px;
}

.renewal-qr-timer {
    font-size: 12px;
    color: #888;
    margin-bottom: 8px;
}

.btn-pay {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #27ae60 0%, #1e8449 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(39, 174, 96, 0.3);
}

.btn-pay:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.renewal-hint {
    font-size: 12px;
    color: #777;
    margin-top: 12px;
    line-height: 1.5;
}

.renewal-status {
    font-size: 13px;
    color: #666;
    margin-bottom: 12px;
}

.renewal-status:empty {
    display: none;
    margin: 0;
}

.renewal-status.waiting {
    color: #d35400;
}

.renewal-id-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 16px;
}

.renewal-id-label {
    font-size: 14px;
    color: #555;
    font-weight: 600;
}

.id-stepper {
    display: flex;
    align-items: center;
    gap: 0;
    border: 2px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.id-stepper button {
    width: 40px;
    height: 40px;
    border: none;
    background: #f5f5f5;
    color: #8B1874;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    line-height: 1;
}

.id-stepper button:hover:not(:disabled) {
    background: #eee;
}

.id-stepper button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.id-stepper .id-count {
    min-width: 56px;
    width: 56px;
    text-align: center;
    font-size: 18px;
    font-weight: 700;
    color: #333;
    padding: 0 4px;
    border: none;
    outline: none;
    background: transparent;
    font-family: inherit;
    -moz-appearance: textfield;
}

.id-stepper .id-count::-webkit-outer-spin-button,
.id-stepper .id-count::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.id-stepper .id-count:focus {
    background: #faf5f9;
}

.renewal-price-line {
    font-size: 13px;
    color: #777;
    margin-bottom: 14px;
}

.renewal-test-banner {
    display: none;
    background: #fff8e6;
    border: 1px solid #f0c36d;
    color: #7a5a00;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 12px;
    line-height: 1.5;
    text-align: left;
    margin-bottom: 14px;
}

.renewal-test-banner.show {
    display: block;
}

.renewal-test-banner strong {
    color: #5c4300;
}

.renewal-test-banner code {
    background: #fff3cd;
    padding: 1px 4px;
    border-radius: 3px;
    font-size: 11px;
}

@media (max-width: 768px) {
    body.login-renewal-active {
        align-items: center;
        justify-content: center;
        min-height: 100dvh;
        padding: 16px;
        padding-top: max(16px, env(safe-area-inset-top));
        padding-bottom: max(16px, env(safe-area-inset-bottom));
        overflow-y: auto;
    }

    .login-container.renewal-visible {
        max-width: 420px;
        width: 100%;
        margin-left: auto;
        margin-right: auto;
        border-radius: 12px;
    }

    .login-container.renewal-visible .login-header {
        padding: 24px 16px;
    }

    .login-container.renewal-visible .login-header h1 {
        font-size: 24px;
    }

    .login-container.renewal-visible .login-body {
        padding: 16px;
    }

    .login-container.renewal-visible .login-split {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        width: 100%;
    }

    .login-container.renewal-visible .login-form-wrap {
        display: none;
    }

    .login-container.renewal-visible .renewal-panel.show {
        border-left: none;
        border-top: none;
        padding-left: 0;
        padding-top: 0;
        margin-top: 0;
        width: 100%;
        max-width: 100%;
    }

    .login-container.renewal-visible .login-footer {
        display: none;
    }

    .login-container.renewal-visible .info-message.banner-notice.show {
        padding: 12px 16px 0;
        font-size: 14px;
        text-align: center;
    }

    .renewal-panel.show {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
    }

    .renewal-panel.show > * {
        width: 100%;
        max-width: 100%;
    }
    .renewal-title {
        font-size: 20px;
        margin-bottom: 12px;
        text-align: center;
        width: 100%;
    }

    .renewal-meta {
        font-size: 13px;
        background: #faf5f9;
        border-radius: 10px;
        padding: 12px;
        margin-bottom: 18px;
        text-align: center;
    }

    .renewal-id-row {
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 10px;
        margin-bottom: 14px;
        width: 100%;
    }

    .renewal-id-label {
        font-size: 15px;
    }

    .id-stepper {
        width: 100%;
        max-width: 200px;
        margin-left: auto;
        margin-right: auto;
    }

    .id-stepper button {
        width: 48px;
        height: 48px;
        font-size: 22px;
    }

    .id-stepper .id-count {
        flex: 1;
        width: auto;
        min-width: 0;
        font-size: 20px;
        padding: 10px 0;
    }

    .renewal-price-line {
        font-size: 14px;
        margin-bottom: 16px;
        text-align: center;
    }

    .renewal-pay-box {
        padding: 16px 12px;
        margin-bottom: 12px;
        width: 100%;
    }

    .renewal-qr-wrap.show {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .renewal-qr-wrap.show canvas {
        width: min(220px, 72vw);
        height: auto;
        aspect-ratio: 1;
    }

    .btn-pay {
        padding: 16px;
        font-size: 17px;
    }

    .renewal-status {
        text-align: center;
        width: 100%;
    }

    .btn-secondary {
        padding: 14px;
        font-size: 15px;
    }
}
