/**
 * ファイル名: assets/css/style.css
 * 屋根修理診断フォーム CSS 完全版（画像フォールバック対応）
 * 
 * 機能:
 * - 吹き出しタイトルデザイン
 * - レスポンシブ対応
 * - プログレスバー・ステップインジケーター
 * - 選択肢グリッド
 * - ファイルアップロード
 * - フォーム要素
 * - ボタンスタイル
 * - 画像アイコンとFontAwesomeフォールバック対応
 * 
 * 使用制限:
 * - 絵文字使用禁止
 * - アイコンはFontAwesome使用
 */

/* ===============================
   メインコンテナ
   =============================== */
.roof-repair-container {
    max-width: 100%;
    font-family: 'Hiragino Sans', 'ヒラギノ角ゴシック', 'Yu Gothic', 'メイリオ', sans-serif;
    position: relative;
    z-index: 1;
    background-color: #ffffff;
    color: #333;
    border-radius: 6px;
    border: 1px solid #42A9BB; /* 修正: #e0e0e0 から #42A9BB に変更 */
    margin: 0 0 25px 0;
}

/* iOS Safari ダークモード対策 */
@media (prefers-color-scheme: dark) {
    .roof-repair-container {
        background-color: #ffffff !important;
        color: #333 !important;
    }
    
    .roof-repair-container .question-step {
        background-color: #ffffff !important;
        color: #333 !important;
    }
}

/* iOS Safari 専用対策 */
@supports (-webkit-touch-callout: none) {
    .roof-repair-container {
        background-color: #ffffff !important;
        color: #333 !important;
    }
    
    .question-step {
        background-color: #ffffff !important;
    }
}

/* ===============================
   フォームカード
   =============================== */
.form-card {
    background: #fff;
    border-radius: 10px;
    padding: 25px;
    margin: 15px 0;
    position: relative;
    z-index: 2;
}

/* ===============================
   ヘッダー・タイトル（シンプルスタイル）
   =============================== */
.form-header {
    text-align: center;
    margin-bottom: 25px;
}

.form-title {
    background-color: #42A9BB;
    color: #fff;
    font-size: 30px;
    font-weight: bold;
    padding: 15px 20px;
    border-radius: 0;
    display: block;
    text-shadow: none;
}

/* 【カンタン1分】部分の色指定 - 最優先 */
.roof-repair-container .form-card .form-header .form-title span.highlight {
    color: #FFFF73 !important;
}

/* アイコンスタイル */
.form-title i {
    color: #42A9BB;
}

/* エリア名の色 */
.form-title .area-name {
    color: #FFD700;
    font-weight: bold;
}

/* ヘッダーテキスト */
.form-header p {
    color: #666;
    font-size: 16px;
}

/* ヘッダーテキストのレスポンシブ表示切り替え */
.header-text-pc {
    display: block;
}

.header-text-mobile {
    display: none;
}

/* ===============================
   プログレス関連
   =============================== */
.progress-container {
    margin-bottom: 10px;
}

.step-indicator {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.step {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e0e0e0;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    position: relative;
    font-size: 14px;
    transition: all 0.3s ease;
}

.step:not(:last-child)::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 100%;
    width: 20px;
    height: 2px;
    background: #e0e0e0;
    transform: translateY(-50%);
    z-index: -1;
}

.step.completed:not(:last-child)::before {
    background: #42A9BB;
}

.step.active {
    background: #42A9BB;
    color: white;
    transform: scale(1.1);
}

.step.completed {
    background: #42A9BB;
    color: white;
}

.step.completed::after {
    display: none;
}

.progress-bar {
    height: 8px;
    background: #e0e0e0;
    border-radius: 10px;
    position: relative;
    overflow: hidden;
    margin: 0 10px;
}

.progress-bar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: linear-gradient(90deg, #42A9BB, #369fb1);
    border-radius: 10px;
    transition: width 0.3s ease;
    width: var(--progress, 0%);
}

/* ===============================
   質問ステップ
   =============================== */
.question-step {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
    background-color: #ffffff;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 15px;
}

.question-step.active {
    display: block;
    padding: 0px 0px 30px 0px;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.step-title,
.question-title {
    font-size: 24px;
    color: #2c5aa0;
    margin-bottom: 10px;
    text-align: center;
    font-weight: bold;
}

.step-description {
    font-size: 16px;
    color: #666;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* ===============================
   選択肢グリッド
   =============================== */
.options-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.option {
    padding: 20px;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    position: relative;
    z-index: 1;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100px;
    justify-content: center;
}

.option:hover {
    border-color: #42A9BB;
    background: linear-gradient(135deg, rgba(66, 169, 187, 0.1), rgba(54, 159, 177, 0.1));
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(66, 169, 187, 0.3);
    color: #2c5aa0;
}

.option:active {
    transform: translateY(0px);
    box-shadow: 0 2px 8px rgba(66, 169, 187, 0.2);
    background: linear-gradient(135deg, rgba(66, 169, 187, 0.15), rgba(54, 159, 177, 0.15));
}

.option:hover i,
.option:hover .option-icon i,
.option:hover .option-icon img {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

.option:hover div:last-child,
.option:hover .option-text {
    font-weight: bold;
    transition: font-weight 0.2s ease;
}

.option.selected {
    border-color: #42A9BB;
    background: linear-gradient(135deg, #42A9BB, #369fb1);
    color: white;
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 3px 10px rgba(66, 169, 187, 0.25);
}

.option-icon {
    font-size: 32px;
    margin-bottom: 10px;
    opacity: 0.8;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 40px;
}

.option-icon img {
    width: 32px;
    height: 32px;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.option-icon i {
    font-size: 32px;
    transition: transform 0.2s ease;
}

.option:hover .option-icon img,
.option:hover .option-icon i {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

/* ボタン内のアイコン用スタイル */
.button-icon {
    display: inline-flex !important;
    margin-right: 8px;
    vertical-align: middle;
}

.button-icon img {
    width: 20px !important;
    height: 20px !important;
}

.button-icon i {
    font-size: 20px !important;
}

/* 結果画面のアイコン用スタイル */
.result-icon-img {
    justify-content: center;
    margin-bottom: 20px;
}

.result-icon-img img {
    width: 48px !important;
    height: 48px !important;
}

.result-icon-img i {
    font-size: 48px !important;
    color: #42A9BB;
}

/* ファイルアップロードのアイコン用スタイル */
.upload-icon {
    margin-bottom: 10px !important;
}

.upload-icon img {
    width: 48px !important;
    height: 48px !important;
}

.upload-icon i {
    font-size: 48px !important;
    color: #42A9BB;
}

.option-text {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.3;
}

.option-description {
    font-size: 14px;
    opacity: 0.8;
    margin-top: 5px;
}

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

.form-label {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 6px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: bold;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select,
.form-input {
    width: 100%;
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
    background-color: #ffffff;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus,
.form-input:focus {
    border-color: #42A9BB;
    outline: none;
    box-shadow: 0 0 0 3px rgba(66, 169, 187, 0.1);
}

.form-group textarea,
.form-textarea {
    min-height: 100px;
    resize: vertical;
    font-family: inherit;
}

.form-select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6,9 12,15 18,9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 20px;
    padding-right: 40px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* ===============================
   ファイルアップロード
   =============================== */
.file-upload {
    position: relative;
    margin-bottom: 20px;
}

.file-upload input[type="file"] {
    position: absolute;
    opacity: 0;
    width: 0.1px;
    height: 0.1px;
    overflow: hidden;
    z-index: -1;
}

.file-upload label,
.file-upload-label {
    display: block;
    padding: 30px;
    border: 2px dashed #e0e0e0;
    border-radius: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fafafa;
    position: relative;
    z-index: 1;
    -webkit-tap-highlight-color: rgba(66, 169, 187, 0.3);
    user-select: none;
    -webkit-user-select: none;
    color: #6c757d;
}

.file-upload:hover label,
.file-upload-label:hover,
.file-upload-label:focus,
.file-upload-label:active {
    border-color: #42A9BB;
    background: #f8fdfe;
    outline: none;
}

.file-upload label i,
.file-upload-label i,
.file-upload label img,
.file-upload-label img {
    font-size: 24px;
    width: 24px;
    height: 24px;
    margin-bottom: 10px;
    display: block;
    color: #42A9BB;
    transition: transform 0.2s ease;
}

.file-upload:hover label i,
.file-upload-label:hover i,
.file-upload:hover label img,
.file-upload-label:hover img {
    transform: scale(1.1);
}

.file-upload.has-files label,
.file-upload.has-files .file-upload-label {
    border-color: #42A9BB;
    background: linear-gradient(135deg, rgba(66, 169, 187, 0.1), rgba(54, 159, 177, 0.1));
    color: #2c5aa0;
}

.file-upload.has-files label i,
.file-upload.has-files .file-upload-label i {
    color: #42A9BB;
}

.uploaded-files {
    margin-top: 15px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.uploaded-files h4 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #28a745;
}

.uploaded-file {
    padding: 5px 0;
    color: #6c757d;
    font-size: 14px;
}

/* ===============================
   ボタンスタイル
   =============================== */
.btn {
    padding: 12px 30px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    position: relative;
    z-index: 3;
    user-select: none;
    -webkit-user-select: none;
    text-align: center;
    justify-content: center;
    align-items: center;
    gap: 8px;
    min-width: 120px;
}

.btn:active {
    transform: translateY(1px);
}

.btn-primary {
    background: linear-gradient(135deg, #42A9BB, #369fb1);
    color: white;
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #369fb1, #2a8b9c);
    transform: translateY(-2px);
}

.btn-secondary {
    background: #f8f9fa;
    color: #6c757d;
    border: 2px solid #e0e0e0;
}

.btn-secondary:hover {
    background: #e2e6ea;
    border-color: #dae0e5;
    transform: translateY(-1px);
}

.btn-submit {
    background: linear-gradient(135deg, #42A9BB, #369fb1);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 18px;
    border-radius: 50px;
}

.btn-submit:hover {
    background: linear-gradient(135deg, #369fb1, #2a8b9c);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 169, 187, 0.3);
}

.btn:disabled {
    background: #ccc !important;
    cursor: not-allowed;
    transform: none !important;
    opacity: 0.6;
}

.button-container,
.form-navigation {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin-top: 25px;
    gap: 15px;
}

.btn-outline {
    background: white;
    color: #42A9BB;
    border: 2px solid #42A9BB;
    padding: 15px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-outline:hover {
    background: #42A9BB;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 169, 187, 0.3);
}

.btn-disabled {
    background: #e9ecef !important;
    color: #6c757d !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

/* ===============================
   結果画面
   =============================== */
.result-screen,
#resultScreen,
#diagnosisComplete,
#finalResult {
    display: none;
    text-align: center;
    padding: 60px 20px;
    background-color: #ffffff;
    border-radius: 12px;
}

.result-screen.active,
#resultScreen.active,
#diagnosisComplete.active,
#finalResult.active {
    display: block;
    animation: fadeIn 0.5s ease-in;
}

.result-icon {
    font-size: 48px;
    color: #42A9BB;
    margin-bottom: 20px;
}

.result-title {
    color: #2c5aa0;
    font-size: 28px;
    margin-bottom: 15px;
    font-weight: bold;
}

.result-message {
    font-size: 18px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
}

.result-screen p {
    color: #666;
    font-size: 16px;
    line-height: 1.6;
}

.completion-message {
    text-align: center;
    margin: 30px 0;
}

.completion-icon {
    font-size: 80px;
    color: #42A9BB;
    margin-bottom: 20px;
}

.completion-message p {
    color: #666;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 30px;
}

.action-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin: 40px 0;
    flex-wrap: wrap;
}

/* ===============================
   見積もりフォーム
   =============================== */
#quoteForm {
    display: none;
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 25px;
    margin-top: 20px;
    border-left: 4px solid #42A9BB;
}

.quote-title {
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 20px;
    text-align: center;
}

.quote-form {
    margin-top: 40px;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 15px;
    border: 2px solid #e0e0e0;
}

.form-separator {
    display: flex;
    align-items: center;
    margin: 20px 0 30px 0;
}

.separator-line {
    flex: 1;
    height: 1px;
    background: #ddd;
}

.separator-text {
    padding: 0 20px;
    color: #666;
    font-weight: bold;
    font-size: 14px;
}

.quote-form-buttons {
    margin-top: 30px;
    text-align: center;
}

#submitQuoteBtn {
    width: 100%;
    max-width: 400px;
    padding: 15px 30px;
    font-size: 16px;
    border-radius: 50px;
    transition: all 0.3s ease;
    display: inline-block;
    border: 2px solid #6c757d;
}

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

#submitQuoteBtn.btn-primary:hover {
    background: #5a6268;
    border-color: #5a6268;
}

#submitQuoteBtn.btn-submit {
    background: linear-gradient(135deg, #42A9BB, #369fb1) !important;
    color: white !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(66, 169, 187, 0.3);
}

#submitQuoteBtn.btn-submit:hover {
    background: linear-gradient(135deg, #369fb1, #2a8b9c) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(66, 169, 187, 0.4);
}

#submitQuoteBtn:disabled {
    background: #ccc !important;
    cursor: not-allowed;
    transform: none;
    border-color: #ccc !important;
}

/* ===============================
   エラー表示
   =============================== */
.form-input.error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1) !important;
}

.error-message {
    display: block;
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
    font-weight: 500;
}

/* ===============================
   その他のユーティリティ
   =============================== */
.file-upload-label.drag-over {
    border-color: #42A9BB !important;
    background: linear-gradient(135deg, rgba(66, 169, 187, 0.2), rgba(54, 159, 177, 0.2)) !important;
    transform: scale(1.02);
}

.option.touch-active {
    background: linear-gradient(135deg, rgba(66, 169, 187, 0.1), rgba(54, 159, 177, 0.1));
    transform: scale(1.0);
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.loading-overlay.active {
    opacity: 1;
    visibility: visible;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e3f2fd;
    border-top: 4px solid #42A9BB;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===============================
   カスタムスクロールバー
   =============================== */
.form-textarea::-webkit-scrollbar {
    width: 8px;
}

.form-textarea::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.form-textarea::-webkit-scrollbar-thumb {
    background: #42A9BB;
    border-radius: 4px;
}

.form-textarea::-webkit-scrollbar-thumb:hover {
    background: #369fb1;
}

/* ===============================
   アクセシビリティ
   =============================== */
html {
    scroll-behavior: smooth;
}

.option:focus,
.btn:focus,
.file-upload-label:focus {
    outline: 3px solid rgba(66, 169, 187, 0.5);
    outline-offset: 2px;
}

/* 動きを減らす設定に対応 */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .option:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
}

/* ===============================
   iOS Safari専用対策
   =============================== */
@supports (-webkit-touch-callout: none) {
    .file-upload-label {
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        touch-action: manipulation;
    }
    
    .file-upload input[type="file"] {
        position: absolute;
        left: -9999px;
        top: -9999px;
        visibility: hidden;
    }
}

/* ===============================
   レスポンシブ対応 - タブレット
   =============================== */
@media (max-width: 768px) {
    /* ヘッダーテキストの表示切り替え */
    .header-text-pc {
        display: none;
    }
    
    .header-text-mobile {
        display: block;
    }
    
    /* コンテナ調整 */
    .roof-repair-container {
        padding: 5px;
        margin: 0 0 20px 0;
    }
    
    .form-card {
        padding: 10px;
        margin: 0;
        border-radius: 0;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
        background: #fff;
    }
    
    /* タイトル調整 */
    .form-header {
        margin-bottom: 20px;
    }
    
    .form-title {
        font-size: 20px;
        padding: 12px 16px;
        margin-bottom: 6px;
    }
    
    .form-title .area-name {
        color: #FFD700;
    }
    
    .form-header p {
        font-size: 14px;
        color: #666;
    }
    
    /* プログレス調整 */
    .progress-container {
        margin-bottom: 15px;
    }
    
    /* 質問ステップ調整 */
    .question-step {
        padding: 10px;
        margin-bottom: 5px;
    }
    
    .step-title,
    .question-title {
        font-size: 18px;
        margin-bottom: 7px;
    }
    
    .step-description {
        font-size: 14px;
        margin-bottom: 20px;
    }
    
    /* 選択肢グリッド調整 */
    .options-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        margin-bottom: 15px;
    }
    
    .option {
        padding: 10px;
        margin-bottom: 0;
        min-height: 70px;
    }
    
    .option:active {
        background: rgba(66, 169, 187, 0.1);
        transform: none;
        box-shadow: none;
    }
    
    .option-icon {
        font-size: 20px;
        margin-bottom: 5px;
    }
    
    .option-icon img {
        width: 20px;
        height: 20px;
    }
    
    .option-icon i {
        font-size: 20px;
    }
    
    .button-icon img {
        width: 16px !important;
        height: 16px !important;
    }
    
    .button-icon i {
        font-size: 16px !important;
    }
    
    .result-icon-img img {
        width: 40px !important;
        height: 40px !important;
    }
    
    .result-icon-img i {
        font-size: 40px !important;
    }
    
    .option-text {
        font-size: 14px;
    }
    
    .option-description {
        font-size: 12px;
        margin-top: 3px;
    }
    
    /* ステップインジケーター調整 */
    .step-indicator {
        gap: 3px;
        margin-bottom: 10px;
    }
    
    .step {
        margin: 1px;
        width: 24px;
        height: 24px;
        font-size: 11px;
    }
    
    .step:not(:last-child)::before {
        width: 8px;
    }
    
    /* フォーム要素調整 */
    .form-group {
        margin-bottom: 12px;
    }
    
    .form-group input,
    .form-group textarea,
    .form-group select {
        padding: 10px;
    }
    
    /* ボタン調整 */
    .button-container,
    .form-navigation {
        flex-direction: column;
        gap: 8px;
        margin-top: 15px;
        justify-content: flex-end;
        align-items: flex-end;
    }
    
    .btn {
        width: 100%;
        padding: 12px 20px;
        font-size: 14px;
    }
    
    /* ファイルアップロード調整 */
    .file-upload-label {
        padding: 12px 8px;
        min-height: 50px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }
    
    .file-upload-label i,
    .file-upload-label img,
    .upload-icon i,
    .upload-icon img {
        font-size: 18px;
        width: 18px;
        height: 18px;
        margin-bottom: 3px;
    }
    
    .file-upload-label small {
        font-size: 11px;
        line-height: 1.3;
    }
    
    /* 結果画面調整 */
    #resultScreen,
    #diagnosisComplete,
    #finalResult {
        padding: 15px 10px;
    }
    
    .result-icon {
        font-size: 40px;
    }
    
    .result-title {
        font-size: 20px;
    }
    
    .result-message {
        font-size: 14px;
    }
    
    .action-buttons {
        flex-direction: column;
        align-items: center;
        gap: 8px;
        margin: 15px 0;
    }
    
    .btn-outline,
    .action-buttons .btn {
        width: 100%;
        max-width: 300px;
        text-align: center;
        justify-content: center;
        padding: 10px 15px;
        font-size: 14px;
    }
    
    .quote-form {
        padding: 10px;
        margin-top: 15px;
    }
    
    .completion-icon {
        font-size: 50px;
    }
    
    #quoteForm {
        padding: 10px;
        margin-top: 10px;
    }
}

/* ===============================
   レスポンシブ対応 - スマホ
   =============================== */
@media (max-width: 480px) {
    /* コンテナ調整 */
    .roof-repair-container {
        padding: 3px;
        margin: 0 0 15px 0;
    }
    
    .form-card {
        padding: 0;
        margin: 0;
        border-radius: 0;
        background: white;
    }
    
    /* タイトル調整 */
    .form-header {
        margin-bottom: 15px;
    }
    
    .form-title {
        font-size: 18px;
        padding: 10px 12px;
    }
    
    .form-header p {
        font-size: 13px;
    }
    
    /* 質問ステップ調整 */
    .question-step {
        margin: 5px;
        padding: 8px;
    }
    
    .step-title,
    .question-title {
        font-size: 16px;
        margin-bottom: 10px;
    }
    
    .step-description {
        font-size: 13px;
        margin-bottom: 15px;
    }
    
    /* 選択肢調整 */
    .option {
        padding: 8px;
        min-height: 60px;
    }
    
    .option-icon {
        font-size: 18px;
    }
    
    .option-icon img {
        width: 18px;
        height: 18px;
    }
    
    .option-icon i {
        font-size: 18px;
    }
    
    .button-icon img {
        width: 14px !important;
        height: 14px !important;
    }
    
    .button-icon i {
        font-size: 14px !important;
    }
    
    /* フォーム要素調整 */
    .form-group input,
    .form-group textarea,
    .form-group select {
        padding: 10px;
        font-size: 16px; /* iOSのズーム防止 */
    }
    
    /* ボタン調整 */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
    
    .btn-submit {
        padding: 12px 25px;
        font-size: 16px;
    }
    
    /* ファイルアップロード調整 */
    .file-upload-label {
        padding: 15px 8px;
        min-height: 60px;
    }
    
    .file-upload-label i,
    .file-upload-label img,
    .upload-icon i,
    .upload-icon img {
        font-size: 20px;
        width: 20px;
        height: 20px;
    }
    
    /* その他調整 */
    .action-buttons {
        gap: 10px;
    }
    
    .btn-outline,
    .action-buttons .btn {
        padding: 10px 15px;
        font-size: 14px;
    }
    
    .completion-message p {
        font-size: 14px;
    }
    
    .progress-container {
        margin-bottom: 10px;
    }
    
    #resultScreen,
    #diagnosisComplete,
    #finalResult {
        margin: 5px;
    }
}

/* ===============================
   タッチデバイス専用
   =============================== */
@media (pointer: coarse) {
    .option {
        padding: 18px;
        min-height: 60px;
    }
    
    .option:hover {
        transform: none;
        box-shadow: none;
        background: white;
        border-color: #e0e0e0;
        color: inherit;
    }
    
    .option:active {
        background: linear-gradient(135deg, rgba(66, 169, 187, 0.1), rgba(54, 159, 177, 0.1));
        transform: none;
        box-shadow: none;
    }
    
    .file-upload-label {
        min-height: 90px;
        padding: 20px;
    }
    
    .btn {
        min-height: 44px;
        padding: 12px 30px;
    }
}

/* ===============================
   印刷スタイル
   =============================== */
@media print {
    .roof-repair-container {
        box-shadow: none;
        padding: 0;
    }
    
    .form-card {
        box-shadow: none;
        border: 1px solid #ccc;
    }
    
    .btn,
    .form-navigation {
        display: none;
    }
}


/* ===============================
   スマホ版改行対応
   =============================== */

/* PC版では改行を非表示 */
.mobile-break {
    display: none;
}

/* タブレット以下で改行を表示 */
@media (max-width: 768px) {
    .mobile-break {
        display: block;
    }
}

/* スマホ版では改行を表示 */
@media (max-width: 480px) {
    .mobile-break {
        display: block;
    }
    
    /* タイトルの行間調整 */
    .form-title {
        line-height: 1.3;
    }
}