/* ========================================
   履歴書作成フォーム専用スタイル
   ======================================== */

/* カラースキーム */
:root {
    --primary-color: #FF6B35;
    --secondary-color: #F7931E;
    --accent-color: #4ECDC4;
    --success-color: #10b981;
    --text-color: #2C3E50;
    --border-color: #e0e0e0;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
}

/* 基本スタイル */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.resume-form-page {
    font-family: 'Noto Sans JP', sans-serif;
    background: linear-gradient(180deg, #fff8f0 0%, #ffffff 100%);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========================================
   ヘッダー
   ======================================== */
.header {
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    border-bottom: 3px solid var(--primary-color);
    padding: 20px 0;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 900;
    margin-bottom: 5px;
}

.logo h1 a {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-decoration: none;
}

.tagline {
    font-size: 0.9rem;
    color: #666;
    font-weight: 600;
}

.nav a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 25px;
    transition: all 0.3s ease;
}

.nav a:hover {
    background: linear-gradient(135deg, rgba(255, 107, 53, 0.1) 0%, rgba(247, 147, 30, 0.1) 100%);
    color: var(--primary-color);
}

/* ========================================
   メインコンテンツ
   ======================================== */
.main-content {
    flex: 1;
    padding: 40px 0;
}

/* プログレスステップ */
.progress-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 50px;
    position: relative;
}

.progress-steps::before {
    content: '';
    position: absolute;
    top: 30px;
    left: 10%;
    right: 10%;
    height: 3px;
    background: var(--border-color);
    z-index: 0;
}

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

.step-number {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: white;
    border: 3px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    color: #999;
    transition: all 0.3s ease;
}

.step-label {
    font-weight: 600;
    color: #999;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.step.active .step-number {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-color: var(--primary-color);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
}

.step.active .step-label {
    color: var(--primary-color);
    font-weight: 700;
}

.step.completed .step-number {
    background: var(--success-color);
    border-color: var(--success-color);
    color: white;
}

.step.completed .step-label {
    color: var(--success-color);
}

/* フォームコンテナ */
.form-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.08);
    padding: 50px;
}

.form-step {
    display: none;
}

.form-step.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

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

.section-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.section-title i {
    color: var(--accent-color);
}

/* ========================================
   顔写真アップロード
   ======================================== */
.photo-upload-section {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    margin-bottom: 40px;
    padding: 30px;
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.05) 0%, rgba(149, 225, 211, 0.05) 100%);
    border-radius: 15px;
    border: 2px dashed var(--accent-color);
}

.photo-preview {
    width: 150px;
    height: 200px;
    border: 3px solid var(--border-color);
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: white;
    overflow: hidden;
    position: relative;
}

.photo-preview i {
    font-size: 4rem;
    color: #ccc;
}

.photo-preview p {
    font-size: 0.8rem;
    color: #999;
    text-align: center;
    margin-top: 10px;
}

.photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-upload-controls {
    flex: 1;
}

.btn-upload,
.btn-remove {
    padding: 12px 25px;
    border: none;
    border-radius: 25px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    margin-right: 10px;
    margin-bottom: 15px;
}

.btn-upload {
    background: linear-gradient(135deg, var(--accent-color) 0%, var(--success-color) 100%);
    color: white;
}

.btn-upload:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(78, 205, 196, 0.3);
}

.btn-remove {
    background: #e74c3c;
    color: white;
}

.btn-remove:hover {
    background: #c0392b;
}

.upload-hint {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.6;
}

.upload-hint i {
    color: var(--accent-color);
}

/* ========================================
   フォーム要素
   ======================================== */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    margin-bottom: 30px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-color);
    font-size: 0.95rem;
}

.required {
    color: #e74c3c;
    font-weight: 700;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(78, 205, 196, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* サブセクション */
.subsection {
    margin-bottom: 40px;
    padding: 30px;
    background: var(--bg-light);
    border-radius: 15px;
}

.subsection h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 3px solid var(--accent-color);
}

/* タイムラインエントリー */
.timeline-entry {
    display: grid;
    grid-template-columns: 180px 1fr auto;
    gap: 15px;
    align-items: start;
    margin-bottom: 15px;
    padding: 20px;
    background: white;
    border-radius: 10px;
    border-left: 4px solid var(--accent-color);
}

.btn-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: #e74c3c;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    background: #c0392b;
    transform: scale(1.1);
}

.btn-add {
    padding: 10px 20px;
    border: 2px dashed var(--accent-color);
    background: white;
    color: var(--accent-color);
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 10px;
}

.btn-add:hover {
    background: rgba(78, 205, 196, 0.1);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* ========================================
   フォームアクション
   ======================================== */
.form-actions {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 40px;
}

.form-actions.center {
    justify-content: center;
}

.btn-back,
.btn-next,
.btn-download {
    padding: 15px 40px;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-back {
    background: #95a5a6;
    color: white;
}

.btn-back:hover {
    background: #7f8c8d;
    transform: translateY(-2px);
}

.btn-next,
.btn-download {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    box-shadow: 0 5px 20px rgba(255, 107, 53, 0.3);
}

.btn-next:hover,
.btn-download:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(255, 107, 53, 0.4);
}

/* ========================================
   プレビューコンテナ
   ======================================== */
.preview-container {
    background: white;
    border: 3px solid var(--border-color);
    border-radius: 15px;
    padding: 50px;
    margin-bottom: 30px;
    min-height: 400px;
}

.resume-preview {
    background: white;
    padding: 40px;
    font-family: 'Noto Sans JP', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', 'Meiryo', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    position: relative;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100%;
    min-width: 600px;
    max-width: 900px;
    margin: 0 auto;
}

.resume-preview h1 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 30px;
    color: #FF6B35;
}

.resume-preview h2 {
    font-size: 1.5rem;
    color: #4ECDC4;
    margin-bottom: 15px;
    margin-top: 30px;
}

.resume-preview table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.resume-preview td {
    padding: 10px;
    border: 1px solid #ddd;
}

.resume-preview img {
    display: block;
}

.download-section {
    padding: 30px;
    background: linear-gradient(135deg, rgba(255, 230, 109, 0.1) 0%, rgba(247, 147, 30, 0.1) 100%);
    border-radius: 15px;
    border: 2px solid var(--secondary-color);
}

.download-info {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 30px;
}

.download-info i {
    font-size: 2rem;
    color: var(--primary-color);
    flex-shrink: 0;
}

.download-info h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.download-info ol {
    margin-left: 20px;
    line-height: 1.8;
}

.download-info strong {
    color: var(--primary-color);
}

/* ========================================
   フッター
   ======================================== */
.footer {
    background: #2c3e50;
    color: white;
    text-align: center;
    padding: 20px 0;
    margin-top: 50px;
}

/* ========================================
   レスポンシブ対応
   ======================================== */
@media (max-width: 768px) {
    .form-container {
        padding: 30px 20px;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .photo-upload-section {
        flex-direction: column;
        align-items: center;
    }

    .timeline-entry {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .form-actions {
        flex-direction: column;
    }

    .btn-back,
    .btn-next,
    .btn-download {
        width: 100%;
        justify-content: center;
    }

    .progress-steps {
        overflow-x: auto;
        padding-bottom: 10px;
    }

    .step {
        min-width: 100px;
    }

    .step-number {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }

    .step-label {
        font-size: 0.8rem;
    }

    .download-info {
        flex-direction: column;
    }

    .preview-container {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .header-content {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .logo h1 {
        font-size: 1.4rem;
    }

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

    .section-title {
        font-size: 1.3rem;
        gap: 10px;
    }

    .subsection {
        padding: 20px 15px;
    }

    .btn-upload,
    .btn-remove {
        width: 100%;
        margin-right: 0;
    }
}
