/* 株主優待申込システム - フロントエンド用CSS */

/* リセット */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Helvetica', 'Arial', 'Hiragino Kaku Gothic ProN', 'Meiryo', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

/* コンテナ */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    background-color: #fff;
    min-height: 100vh;
}

/* ヘッダー */
.header {
    text-align: center;
    padding: 20px 0;
    border-bottom: 2px solid #4CAF50;
    margin-bottom: 30px;
}

.header-title {
    margin: 0;
    font-size: 1.8em;
    color: #333;
}

/* メインコンテンツ */
.main-content {
    padding: 20px 0;
}

/* 画面名表示 */
.screen-title {
    font-size: 1.5em;
    margin-bottom: 20px;
    color: #050a4e;
}

/* フッター */
.footer {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid #ddd;
    margin-top: 30px;
    color: #666;
    font-size: 0.9em;
}

/* アラート */
.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
}

.alert-error {
    background-color: #ffebee;
    color: #c62828;
    border: 1px solid #ef9a9a;
}

.alert-success {
    background-color: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #a5d6a7;
}

.alert-warning {
    background-color: #fff3e0;
    color: #e65100;
    border: 1px solid #ffcc80;
}

.alert-info {
    background-color: #e3f2fd;
    color: #1565c0;
    border: 1px solid #90caf9;
}

/* フォーム */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.required::after {
    content: ' *';
    color: #c62828;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="password"],
select,
textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #4CAF50;
    box-shadow: 0 0 5px rgba(76, 175, 80, 0.3);
}

input.error,
select.error,
textarea.error {
    border-color: #c62828;
}

.error-message {
    color: #c62828;
    font-size: 0.85em;
    margin-top: 5px;
}

.help-text {
    color: #666;
    font-size: 0.85em;
    margin-top: 5px;
}

/* ボタン */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1em;
    text-decoration: none;
    text-align: center;
    transition: background-color 0.3s ease;
}

.btn-primary {
    background-color: #4CAF50;
    color: white;
}

.btn-primary:hover {
    background-color: #45a049;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #5a6268;
}

.btn-danger {
    background-color: #f44336;
    color: white;
}

.btn-danger:hover {
    background-color: #d32f2f;
}

.btn-block {
    display: block;
    width: 100%;
}

.btn:disabled,
.btn.disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* 商品選択 */
.goods-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.goods-item {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    cursor: pointer;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.goods-item:hover {
    border-color: #4CAF50;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.goods-item.selected {
    border-color: #4CAF50;
    background-color: #e8f5e9;
}

.goods-item input[type="radio"] {
    display: none;
}

.goods-image {
    width: 100%;
    max-width: 300px;
    height: auto;
    margin-bottom: 15px;
    border-radius: 5px;
}

.goods-name {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 10px;
}

.goods-info {
    color: #666;
    font-size: 0.9em;
}

/* 確認画面 */
.confirm-section {
    margin-bottom: 30px;
}

.confirm-section h3 {
    font-size: 1.1em;
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
    margin-bottom: 15px;
}

.confirm-table {
    width: 100%;
}

.confirm-table th {
    text-align: left;
    padding: 10px;
    background-color: #f5f5f5;
    width: 30%;
    vertical-align: top;
}

.confirm-table td {
    padding: 10px;
}

/* 完了画面 */
.complete-message {
    text-align: center;
    padding: 40px 20px;
}

.complete-icon {
    font-size: 4em;
    color: #4CAF50;
    margin-bottom: 20px;
}

.complete-title {
    font-size: 1.5em;
    margin-bottom: 20px;
}

.complete-text {
    color: #666;
    margin-bottom: 30px;
}

/* 照会画面 */
.inquiry-section {
    background-color: #f9f9f9;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.inquiry-section h3 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 1.1em;
}

/* モーダル */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal {
    background-color: #fff;
    border-radius: 8px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    font-size: 1.2em;
    font-weight: bold;
    margin-bottom: 20px;
}

.modal-body {
    margin-bottom: 20px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ステップインジケーター */
.step-indicator {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 30px;
}

.step {
    display: flex;
    align-items: center;
}

.step-number {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #ddd;
    color: #666;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
}

.step.active .step-number {
    background-color: #4CAF50;
    color: white;
}

.step.completed .step-number {
    background-color: #4CAF50;
    color: white;
}

.step-label {
    margin-left: 8px;
    font-size: 0.9em;
    color: #666;
}

.step.active .step-label {
    color: #333;
    font-weight: bold;
}

.step-connector {
    width: 50px;
    height: 2px;
    background-color: #ddd;
    margin: 0 10px;
}

.step-connector.completed {
    background-color: #4CAF50;
}

/* ユーティリティ */
.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.mt-10 {
    margin-top: 10px;
}

.mt-20 {
    margin-top: 20px;
}

.mb-10 {
    margin-bottom: 10px;
}

.mb-20 {
    margin-bottom: 20px;
}

.hidden {
    display: none;
}

/* レスポンシブ対応 */
@media (max-width: 600px) {
    .container {
        padding: 15px;
    }

    .header-title {
        font-size: 1.4em;
    }

    .step-label {
        display: none;
    }

    .step-connector {
        width: 30px;
    }

    .confirm-table th,
    .confirm-table td {
        display: block;
        width: 100%;
    }

    .confirm-table th {
        border-bottom: none;
        padding-bottom: 5px;
    }

    .confirm-table td {
        padding-top: 0;
        padding-bottom: 15px;
    }
}
