/**
 * Contact Form 7 Custom Styles
 * 
 * Contact Form 7フォームと確認画面・完了画面のスタイル
 */

/* ==========================================================================
   Page Header & Layout Styles (Migrated from wpforms-custom.css)
   ========================================================================== */

.page-header {
    text-align: center;
    padding: 40px 20px;
    max-width: 800px;
    margin: 0 auto 40px;
}

.page-title {
    font-size: 32px;
    font-weight: bold;
    color: #333;
    margin-bottom: 16px;
}

.page-description {
    font-size: 16px;
    color: #666;
    line-height: 1.6;
}

.form-container {
    padding-bottom: 80px;
}

@media (max-width: 640px) {
    .page-header {
        padding: 20px;
        margin: 0;
    }

    .page-title {
        font-size: 24px;
    }

    .page-description {
        font-size: 14px;
    }

    .form-container {
        padding: 20px 20px 60px;
    }
}

/* ==========================================================================
   Confirmation Screen Styles
   ========================================================================== */

/* ==========================================================================
   Contact Form 7 Form Styles
   ========================================================================== */

.wpcf7-form {
    max-width: 640px;
    margin: 0 auto;
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
}

/* brタグを非表示にする（autop対策、レイアウト崩れ防止） */
.wpcf7-form br {
    display: none;
}


.wpcf7-form .form-row {
    margin-bottom: 32px;
}

/* ラベルスタイル */
.wpcf7-form label {
    display: block;
    font-weight: 700;
    margin-bottom: 12px;
    color: #333;
    font-size: 15px;
}

/* 必須マーク */
.wpcf7-form .required {
    color: #ff6b6b;
    font-size: 11px;
    margin-left: 8px;
    font-weight: normal;
    background: transparent;
    padding: 0;
    border-radius: 0;
}

/* 入力フィールド */
.wpcf7-form input[type="text"],
.wpcf7-form input[type="email"],
.wpcf7-form input[type="tel"],
.wpcf7-form select,
.wpcf7-form textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    transition: all 0.3s;
    background-color: #fff;
    box-sizing: border-box;
}

.wpcf7-form input[type="text"]:focus,
.wpcf7-form input[type="email"]:focus,
.wpcf7-form input[type="tel"]:focus,
.wpcf7-form select:focus,
.wpcf7-form textarea:focus {
    outline: none;
    border-color: var(--morian-gold);
    box-shadow: 0 0 0 2px rgba(139, 140, 77, 0.1);
}

.wpcf7-form textarea {
    min-height: 160px;
    resize: vertical;
}

/* プレースホルダー */
.wpcf7-form ::placeholder,
.wpcf7-form select.is-placeholder {
    color: #aaa;
}

/* プルダウン内の選択肢は通常色にする（Windows等への対策） */
.wpcf7-form select option {
    color: #333;
}

/* セレクトボックスの右側矢印 */
.wpcf7-form select {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

/* チェックボックス・ラジオボタン（カード型デザイン） */
.wpcf7-form .wpcf7-checkbox,
.wpcf7-form .wpcf7-radio {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.wpcf7-form .wpcf7-list-item {
    margin: 0;
}

/* 除外: 同意チェックボックスはカード型にしない */
.wpcf7-form .wpcf7-checkbox .wpcf7-list-item label,
.wpcf7-form .wpcf7-radio .wpcf7-list-item label {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    background-color: #fff; /* 画像では白背景 */
    border: 1px solid #eee;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: normal;
    margin: 0;
}

.wpcf7-form .wpcf7-checkbox .wpcf7-list-item label:hover,
.wpcf7-form .wpcf7-radio .wpcf7-list-item label:hover {
    border-color: #ccc;
    background-color: #fafafa;
}

.wpcf7-form .wpcf7-list-item input[type="checkbox"],
.wpcf7-form .wpcf7-list-item input[type="radio"] {
    margin-right: 16px;
    width: 20px;
    height: 20px;
    border: 1px solid #ccc;
    border-radius: 4px;
    accent-color: var(--morian-gold);
    flex-shrink: 0;
}

.wpcf7-form .wpcf7-list-item-label {
    font-size: 15px;
    color: #333;
}

/* 任意の注釈 */
.optional-note {
    font-size: 12px;
    font-weight: normal;
    color: #888;
    margin-left: 8px;
}

/* 同意エリア */
.wpcf7-form .wpcf7-acceptance {
    background-color: var(--morian-gold-light);
    border: 1px solid var(--morian-gold);
    padding: 30px;
    border-radius: 8px;
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

/* 同意チェックボックスのスタイルオーバーライド */
.wpcf7-form .wpcf7-acceptance .wpcf7-list-item {
    margin: 0;
    display: block;
}

.wpcf7-form .wpcf7-acceptance .wpcf7-list-item label {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    display: flex;
    align-items: center;
    font-weight: bold;
    font-size: 15px;
}

.wpcf7-form .wpcf7-acceptance input[type="checkbox"] {
    margin-right: 12px;
    width: 20px;
    height: 20px;
    accent-color: var(--morian-gold);
    background: #fff;
}

/* セキュリティ・プライバシー注釈 */
.wpcf7-form .wpcf7-acceptance::after {
    content: "🔒 入力された情報は暗号化され、採用選考以外には使用いたしません。";
    display: block;
    font-size: 11px;
    color: #888;
    padding-left: 32px;
}

/* その他の注釈（履歴書等） */
.form-note {
    font-size: 12px;
    color: #666;
    margin-top: 8px;
    margin-bottom: 24px;
}

/* 送信ボタン */
.wpcf7-form .wpcf7-submit {
    background-color: var(--morian-gold);
    color: white;
    padding: 18px 48px;
    border: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    display: block;
    margin: 40px auto 0;
    width: 100%;
    max-width: 320px;
    box-shadow: 0 4px 6px rgba(139, 140, 77, 0.2);
}

.wpcf7-form .wpcf7-submit:hover {
    background-color: var(--morian-gold);
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(139, 140, 77, 0.3);
}

/* バリデーションエラー */
.wpcf7-form .wpcf7-not-valid {
    border-color: #ff6b6b !important;
    background-color: #fff8f8;
}

.wpcf7-form .wpcf7-not-valid-tip {
    color: #ff6b6b;
    font-size: 13px;
    margin-top: 6px;
    font-weight: bold;
}

.wpcf7-form .wpcf7-response-output {
    margin: 24px 0;
    padding: 16px;
    border-radius: 6px;
    font-size: 14px;
}

.wpcf7-form .wpcf7-validation-errors {
    background-color: #fff8f8;
    border: 1px solid #ff6b6b;
    color: #ff6b6b;
}

.wpcf7-form .wpcf7-mail-sent-ok {
    background-color: #f0fdf4;
    border: 1px solid #27ae60;
    color: #27ae60;
}
.wpcf7-confirmation-screen {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.wpcf7-confirmation-content {
    background: white;
    border-radius: 8px;
    padding: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.wpcf7-confirmation-title {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
    text-align: center;
}

.wpcf7-confirmation-description {
    font-size: 16px;
    color: #666;
    margin-bottom: 32px;
    text-align: center;
}

.wpcf7-confirmation-table {
    margin-bottom: 32px;
}

.wpcf7-confirmation-row {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 24px;
    padding: 16px 0;
    border-bottom: 1px solid #eee;
}

.wpcf7-confirmation-row:last-child {
    border-bottom: none;
}

.wpcf7-confirmation-label {
    font-weight: 600;
    color: #333;
}

.wpcf7-confirmation-value {
    color: #666;
}

.wpcf7-confirmation-checkbox-item {
    margin-bottom: 4px;
}

.wpcf7-confirmation-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.wpcf7-confirmation-edit,
.wpcf7-confirmation-submit {
    padding: 16px 48px;
    border: none;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.wpcf7-confirmation-edit {
    background-color: #95a5a6;
    color: white;
}

.wpcf7-confirmation-edit:hover {
    background-color: #7f8c8d;
}

.wpcf7-confirmation-submit {
    background-color: #7c7d3c;
    color: white;
}

.wpcf7-confirmation-submit:hover {
    background-color: #6b6c2e;
}

/* ==========================================================================
   Application Complete Page Styles
   ========================================================================== */

.application-complete-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 20px;
}

.application-complete-content {
    background: white;
    border-radius: 8px;
    padding: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.application-complete-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    background-color: #27ae60;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.application-complete-icon::before {
    content: "✓";
    color: white;
    font-size: 48px;
    font-weight: bold;
}

.application-complete-title {
    font-size: 28px;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
}

.application-complete-message {
    font-size: 16px;
    color: #666;
    line-height: 1.8;
    margin-bottom: 32px;
}

.application-complete-next-steps {
    background-color: #f8f9fa;
    padding: 24px;
    border-radius: 4px;
    margin-bottom: 32px;
}

.application-complete-next-steps h3 {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 16px;
}

.application-complete-next-steps p {
    font-size: 16px;
    color: #666;
    line-height: 1.8;
}

.application-complete-button {
    display: inline-block;
    padding: 16px 48px;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 600;
    transition: background-color 0.3s;
}

.application-complete-button:hover {
    background-color: #2980b9;
}

/* ==========================================================================
   Process Flow (Completed State)
   ========================================================================== */

.process-flow.completed .process-step:first-child {
    background-color: #27ae60;
}

.process-flow.completed .process-step:first-child .step-icon {
    background-color: white;
    color: #27ae60;
}

.process-flow.completed .process-step:first-child::after {
    background-color: #f39c12;
}

.process-flow.completed .process-step:nth-child(2) {
    background-color: #f39c12;
}

.process-flow.completed .process-step:nth-child(2) .step-icon {
    background-color: white;
    color: #f39c12;
}

/* ==========================================================================
   Responsive Styles
   ========================================================================== */

@media (max-width: 768px) {
    .wpcf7-confirmation-row {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    
    .wpcf7-confirmation-label {
        font-size: 14px;
    }
    
    .wpcf7-confirmation-buttons {
        flex-direction: column;
    }
    
    .wpcf7-confirmation-edit,
    .wpcf7-confirmation-submit {
        width: 100%;
    }
    
    
    .application-complete-content {
        padding: 24px;
    }

    .wpcf7-form .wpcf7-list-item input[type="checkbox"],
    .wpcf7-form .wpcf7-list-item input[type="radio"] {
        margin-right: 6px;
    }
}

/* ==========================================================================
   Process Flow Alignment
   ========================================================================== */
.application-process-flow {
    padding: 60px 20px;
    background: #f8f8f8; /* 背景色確保 */
    margin-bottom: 60px;
}

.process-steps {
    display: flex;
    justify-content: center;
    align-items: stretch; /* 高さを揃える */
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
}

.process-step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #fff;
    padding: 30px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

/* アイコン位置の統一 */
.process-icon {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

/* タイトル位置の統一（2行分確保） */
.process-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    line-height: 1.5;
    width: 100%;
    text-align: center;
}

/* 説明文位置の統一（開始位置が揃う） */
.process-description {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    text-align: center;
    margin: 0;
    flex-grow: 1;
}

/* 矢印の位置調整 */
.process-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #7c7d3c;
    padding-bottom: 40px; /* 中心より少し上に調整 */
}

@media (max-width: 768px) {
    .application-process-flow {
        padding: 40px 60px;
    }

    .process-steps {
        flex-direction: column;
        align-items: center;
        gap: 0;
    }
    
    .process-arrow {
        transform: rotate(90deg);
        padding-bottom: 0;
        margin: 10px 0;
    }
    
    .process-step {
        width: 100%;
        max-width: 400px;
    }
    
    .process-title {
        min-height: auto; /* モバイルでは高さ固定解除 */
    }
}

/* フォーム内のリンクスタイル */
.wpcf7-form a {
    color: #8b8c4d;
    text-decoration: underline;
    transition: color 0.3s;
}

.wpcf7-form a:hover {
    color: #7c7d3c;
    text-decoration: none;
}

/* ==========================================================================
   Form Progress Bar Styles
   ========================================================================== */

.form-progress-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 600px;
    margin: 40px auto;
    padding: 0 20px;
}

.form-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    z-index: 1;
}

.step-number {
    width: 40px;
    height: 40px;
    background-color: #ddd;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
    margin-bottom: 8px;
    transition: background-color 0.3s;
}

.step-label {
    font-size: 14px;
    color: #999;
    font-weight: 600;
    transition: color 0.3s;
}

.step-line {
    flex-grow: 1;
    height: 2px;
    background-color: #ddd;
    margin: 0 10px 28px; /* labelの高さを考慮して上側に配置 */
    position: relative;
    top: -14px; /* numberの中心に合わせる */
    z-index: 0;
}

/* Active State */
.form-step.active .step-number {
    background-color: var(--morian-gold); /* テーマカラー */
}

.form-step.active .step-label {
    color: var(--morian-gold);
}

/* Completed State */
.form-step.completed .step-number {
    background-color: var(--morian-gold);
}

.form-step.completed .step-label {
    color: var(--morian-gold);
}

.step-line.completed {
    background-color: var(--morian-gold);
}

/* Responsive */
@media (max-width: 480px) {
    .step-number {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    
    .step-label {
        font-size: 12px;
    }
    
    .step-line {
        top: -12px;
    }

    .form-progress-bar {
        padding: 0 40px;
    }
}
