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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
    background: #ffffff;
    min-height: 100vh;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.container {
    max-width: 600px;
    width: 100%;
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px 30px;
    text-align: center;
}

.header h1 {
    font-size: 24px;
    margin-bottom: 10px;
    line-height: 1.4;
}

.price-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    padding: 10px 20px;
    border-radius: 20px;
    margin-top: 15px;
    backdrop-filter: blur(10px);
}

.price-badge .label {
    font-size: 12px;
    opacity: 0.9;
    margin-bottom: 5px;
}

.price-badge .amount {
    font-size: 32px;
    font-weight: bold;
}

.form-content {
    padding: 40px 30px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
}

.form-group label .required {
    color: #e74c3c;
    margin-left: 4px;
}

.form-group input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 16px;
    transition: all 0.3s ease;
}

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

.name-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* カード支払いセクション */
.payment-section {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 25px;
}

.payment-section h3 {
    font-size: 16px;
    color: #333;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-brands {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.card-brands span {
    font-size: 12px;
    color: #666;
    margin-right: 5px;
}

.card-brand-icon {
    width: 45px;
    height: 30px;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
    color: #666;
}

.card-brand-icon.visa {
    color: #1A1F71;
    background: linear-gradient(135deg, #f7f8fa 0%, #ffffff 100%);
}

.card-brand-icon.mastercard {
    color: #EB001B;
    background: linear-gradient(135deg, #f7f8fa 0%, #ffffff 100%);
}

.card-brand-icon.amex {
    color: #006FCF;
    background: linear-gradient(135deg, #f7f8fa 0%, #ffffff 100%);
}

.card-brand-icon.jcb {
    color: #0E4C96;
    background: linear-gradient(135deg, #f7f8fa 0%, #ffffff 100%);
}

.card-brand-icon.diners {
    color: #0079BE;
    background: linear-gradient(135deg, #f7f8fa 0%, #ffffff 100%);
}

.card-brand-icon.discover {
    color: #FF6000;
    background: linear-gradient(135deg, #f7f8fa 0%, #ffffff 100%);
}

#card-element {
    background: white;
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

#card-element:focus-within {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

#card-errors {
    color: #e74c3c;
    font-size: 13px;
    margin-top: 5px;
    min-height: 20px;
}

.submit-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

.submit-btn:active {
    transform: translateY(0);
}

.submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.info-box {
    background: #f8f9fa;
    border-left: 4px solid #667eea;
    padding: 15px;
    margin-bottom: 25px;
    border-radius: 4px;
}

.info-box p {
    font-size: 14px;
    color: #555;
    line-height: 1.6;
}

@media (max-width: 600px) {
    .name-group {
        grid-template-columns: 1fr;
    }

    .header h1 {
        font-size: 20px;
    }

    .price-badge .amount {
        font-size: 28px;
    }

    .form-content {
        padding: 30px 20px;
    }
}

.error {
    color: #e74c3c;
    font-size: 13px;
    margin-top: 5px;
    display: none;
}

.form-group.has-error input {
    border-color: #e74c3c;
}

.form-group.has-error .error {
    display: block;
}

.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 6px;
}

.alert-error {
    background-color: #fee;
    border-left: 4px solid #e74c3c;
    color: #c33;
}

.alert-success {
    background-color: #d4edda;
    border-left: 4px solid #27ae60;
    color: #155724;
}

.secure-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #666;
    margin-top: 15px;
    justify-content: center;
}

.secure-badge::before {
    content: "\1F512";
    font-size: 14px;
}

.test-mode-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #f39c12;
    color: white;
    text-align: center;
    padding: 12px 20px;
    font-weight: bold;
    font-size: 16px;
    z-index: 10000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.test-mode-banner::before {
    content: "\1F9EA ";
}

body.test-mode {
    padding-top: 70px;
}
