/**
 * beta-page.css - βテスト関連ページ共通スタイル
 *
 * 使用するページ:
 * - beta_ja.html, beta_en.html
 * - beta-register_ja.html, beta-register_en.html
 * - beta-terms_ja.html, beta-terms_en.html
 * - beta-feedback_ja.html, beta-feedback_en.html
 * - survey_ja.html, survey_en.html
 * - glossary_ja.html, glossary_en.html
 */

/* ベーススタイル */
body {
    margin: 0;
    padding: 0;
    font-family: 'Helvetica Neue', Arial, 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    background-color: var(--color-bg, #f5f5f5);
    color: var(--color-text, #333);
    line-height: 1.6;
}

/* コンテナ */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    padding-top: 10px;
}

/* パンくずリスト */
.breadcrumb {
    background: var(--color-card-bg, white);
    padding: 12px 20px;
    font-size: 0.9rem;
    border-bottom: 1px solid var(--color-border, #e2e8f0);
}

.breadcrumb a {
    color: var(--color-primary, #4a90e2);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb span {
    color: var(--color-text-secondary, #718096);
    margin: 0 8px;
}

/* ナビゲーション（ページヘッダー） */
nav {
    position: relative !important;
    background: linear-gradient(135deg, #059669 0%, #047857 50%, #065f46 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 10px;
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.4);
}

nav h1 {
    margin: 10px 0 5px 0;
    font-size: 1.5rem;
}

nav .subtitle {
    margin: 0;
    font-size: 0.9rem;
    opacity: 0.9;
}

nav .lead {
    margin: 5px 0 0 0;
    font-size: 0.95rem;
    opacity: 0.9;
}

nav .lang-switch {
    position: absolute;
    top: 15px;
    right: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

nav .lang-switch select {
    padding: 5px 10px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.1);
    color: inherit;
    width: auto;
}

nav .lang-switch select option {
    background: white;
    color: #333;
}

/* コンテナ直下の言語切り替え（navがないページ用） */
.container > .lang-switch {
    position: absolute;
    top: 15px;
    right: 35px;
}

.container > .lang-switch select {
    padding: 5px 10px;
    border-radius: 4px;
    border: 1px solid var(--color-border, #e2e8f0);
    background: var(--color-card-bg, white);
    color: var(--color-text, #333);
}

/* フォーム */
form {
    background: var(--color-card-bg, white);
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 12px;
    padding: 24px;
    margin-top: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="date"],
.form-group input[type="password"],
.form-group input[type="number"] {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 6px;
    font-size: 1rem;
    box-sizing: border-box;
    background: var(--color-card-bg, white);
}

.form-group input:focus {
    outline: none;
    border-color: var(--color-primary, #4a90e2);
}

/* パスワード表示トグル用のラッパー */
.password-wrapper {
    position: relative;
}

.password-wrapper input {
    padding-right: 45px;
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--color-text-secondary, #718096);
    font-size: 18px;
}

.password-toggle:hover {
    color: var(--color-text, #333);
}

select {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 6px;
    font-size: 16px;
    background: white;
    cursor: pointer;
}

select:focus {
    outline: none;
    border-color: var(--color-primary, #4a90e2);
}

textarea {
    width: 100%;
    min-height: 100px;
    padding: 12px;
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    box-sizing: border-box;
}

textarea:focus {
    outline: none;
    border-color: var(--color-primary, #4a90e2);
}

/* ボタン */
.btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: white;
    display: block;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.4);
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(5, 150, 105, 0.5);
}

.btn.secondary {
    background: white;
    color: var(--color-primary, #4a90e2);
    border: 1px solid var(--color-border, #e2e8f0);
    margin-top: 10px;
}

.btn.secondary:hover {
    background: #f8f9fa;
}

/* チェックボックスグループ */
.checkbox-group {
    margin: 20px 0;
}

.checkbox-group label {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 0;
    cursor: pointer;
    font-weight: normal;
}

.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    flex-shrink: 0;
}

/* 必須マーク・注釈 */
.required {
    color: #dc2626;
}

.note {
    font-size: 0.85rem;
    color: var(--color-text-secondary, #718096);
    margin-top: 4px;
}

/* ボックス類 */
.important-box {
    background: linear-gradient(135deg, #fff7ed 0%, #ffedd5 100%);
    border: 1px solid #fdba74;
    border-radius: 8px;
    padding: 16px;
    margin: 20px 0;
}

.important-box strong {
    color: #c2410c;
}

.info-box {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border: 1px solid #93c5fd;
    border-radius: 8px;
    padding: 16px;
    margin: 20px 0;
}

.info-box strong {
    color: #1d4ed8;
}

.success-message {
    display: none;
    background: #d1fae5;
    border: 1px solid #34d399;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    margin: 20px 0;
}

.success-message.show {
    display: block;
}

.error-message {
    color: #dc2626;
    font-size: 0.85rem;
    margin-top: 4px;
    display: none;
}

.error-message.show {
    display: block;
}

/* カード */
.card {
    background: var(--color-card-bg, white);
    border: 1px solid var(--color-border, #e2e8f0);
    border-radius: 12px;
    padding: 24px;
    margin: 20px 0;
}

/* セクション見出し */
h2 {
    color: var(--color-text, #333);
    border-bottom: 2px solid var(--color-primary, #4a90e2);
    padding-bottom: 8px;
    margin-top: 30px;
    margin-bottom: 15px;
}

h3 {
    color: var(--color-text, #333);
    margin-top: 25px;
    margin-bottom: 10px;
}

/* 最終更新日 */
.last-updated {
    color: var(--color-text-secondary, #718096);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

/* フッター */
footer {
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    color: white;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.3);
}

footer a {
    color: #a7f3d0;
}

footer a:hover {
    color: #bae6fd;
}

footer p {
    margin: 5px 0;
}

/* リスト */
ul, ol {
    margin: 10px 0;
    padding-left: 25px;
}

li {
    margin: 5px 0;
}

/* テーブル */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

th, td {
    padding: 10px;
    border: 1px solid var(--color-border, #e2e8f0);
    text-align: left;
}

th {
    background: var(--color-bg, #f5f5f5);
    font-weight: 600;
}

/* リンク */
a {
    color: var(--color-primary, #4a90e2);
}

a:hover {
    text-decoration: underline;
}

/* レスポンシブ */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    nav {
        padding: 12px 15px;
    }

    nav h1 {
        font-size: 1.3rem;
        padding-right: 80px;
    }

    nav .lang-switch {
        top: 12px;
        right: 12px;
    }

    form {
        padding: 16px;
    }

    .card {
        padding: 16px;
    }
}

/* ========================================
   βテスター募集ページ専用スタイル
   ======================================== */

/* ハイライトテキスト */
.highlight {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #1f2937;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 600;
}

/* 特典バッジ風 - beta_ja.html / beta_en.html では .beta-recruit クラスを付与 */
nav.beta-recruit h1::before {
    content: "🌲 ";
}

nav.beta-recruit h1::after {
    content: " 🌲";
}

/* 特典セクションの強調 */
.hero .card:first-child {
    border: 2px solid #34d399;
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
}

/* info-boxの色を明るく */
.info-box {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 1px solid #34d399;
    border-left: 4px solid #059669;
}

.info-box h3 {
    color: #047857;
    margin-top: 0;
}

/* カードのホバーエフェクト */
.card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* CTAセクション */
.section .card[style*="text-align:center"] {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 2px solid #34d399;
}

/* FAQセクションのアコーディオン */
.faq details {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: box-shadow 0.2s;
}

.faq details:hover {
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.15);
}

.faq details[open] {
    border-color: #34d399;
}

.faq summary {
    padding: 12px 16px;
    cursor: pointer;
    font-weight: 500;
    list-style: none;
}

.faq summary::-webkit-details-marker {
    display: none;
}

.faq summary::before {
    content: "▶ ";
    font-size: 0.8em;
    margin-right: 8px;
    transition: transform 0.2s;
    display: inline-block;
}

.faq details[open] summary::before {
    transform: rotate(90deg);
}

.faq details p {
    padding: 0 16px 12px 16px;
    margin: 0;
    color: #4b5563;
}

/* テーブルヘッダーの色 */
th {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    color: #047857;
}

/* セクション見出しの下線を鮮やかに */
h2 {
    border-bottom: 3px solid;
    border-image: linear-gradient(90deg, #10b981, #059669, #047857) 1;
}

/* ========================================
   β掲示板フィードバック表示スタイル
   ======================================== */

/* フィードバック一覧（並び順セレクトとの間隔） */
.feedback-list {
    margin-top: 20px;
}

/* フィードバックカード */
.feedback-card {
    margin-bottom: 20px;
    padding: 15px;
}

/* フィードバックヘッダー（タイトル・メタ情報） */
.feedback-header {
    margin-bottom: 15px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--color-border, #e2e8f0);
}

/* フィードバックタイトル */
.feedback-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 6px;
}

/* フィードバックメタ情報（カテゴリ・ステータス・投稿者・日時） */
.feedback-info {
    font-size: 0.9rem;
    color: var(--color-text-secondary, #718096);
}

/* フィードバックコンテンツ（改行を保持） */
.feedback-content {
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.7;
    padding: 12px 15px;
    background: var(--color-bg, #f9fafb);
    border-radius: 6px;
    margin-top: 5px;
}

/* 運営からの返信（控えめなスタイル - テスター投稿が主役） */
.admin-response {
    margin-top: 12px;
    margin-left: 30px;
    padding: 10px 14px;
    background: var(--color-bg, #f5f5f5);
    border-left: 2px solid #d1d5db;
    border-radius: 0 4px 4px 0;
}

.admin-response-header {
    font-weight: 500;
    color: var(--color-text-secondary, #6b7280);
    margin-bottom: 6px;
    font-size: 0.8rem;
}

.admin-response-content {
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.5;
    color: var(--color-text-secondary, #555);
    font-size: 0.9rem;
}

/* 返信へのいいねボタン */
.admin-response-actions {
    margin-top: 8px;
    display: flex;
    gap: 8px;
}

.vote-btn.small {
    padding: 2px 8px;
    font-size: 0.75rem;
    border-radius: 12px;
}

/* 獲得ポイント表示 */
.earned-points {
    display: inline-block;
    padding: 2px 8px;
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
    color: #92400e;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 10px;
    border: 1px solid #fcd34d;
    cursor: help;
}

/* ========================================
   画像アップロードUI
   ======================================== */

/* 画像アップロードエリア */
.image-upload-area {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-start;
    padding: 16px;
    background: var(--color-bg, #f9fafb);
    border: 2px dashed var(--color-border, #e2e8f0);
    border-radius: 8px;
    min-height: 100px;
}

/* プレビューコンテナ */
.image-preview-container {
    display: contents;
}

/* 個別のプレビュー */
.image-preview {
    position: relative;
    width: 100px;
    height: 100px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.image-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 削除ボタン */
.image-remove-btn {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.image-remove-btn:hover {
    background: #dc2626;
}

/* 回転ボタン */
.image-rotate-btn {
    position: absolute;
    top: 4px;
    left: 4px;
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    font-size: 14px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.image-rotate-btn:hover {
    background: #2563eb;
}

/* 画像追加ボタン */
.image-add-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100px;
    height: 100px;
    border: 2px dashed var(--color-border, #cbd5e0);
    border-radius: 8px;
    background: var(--color-card-bg, white);
    color: var(--color-text-secondary, #718096);
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
}

.image-add-btn:hover {
    border-color: var(--color-primary, #4a90e2);
    color: var(--color-primary, #4a90e2);
}

.image-add-btn span {
    font-size: 0.85rem;
    text-align: center;
}

/* ドラッグオーバー時のスタイル */
.image-upload-area.drag-over {
    border-color: var(--color-primary, #4a90e2);
    background: rgba(74, 144, 226, 0.1);
}

.image-upload-area.drag-over .image-add-btn {
    border-color: var(--color-primary, #4a90e2);
    color: var(--color-primary, #4a90e2);
    background: rgba(74, 144, 226, 0.05);
}

/* ========================================
   フィードバック詳細の画像サムネイル
   ======================================== */

/* 画像サムネイルコンテナ */
.feedback-images {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

/* サムネイル画像 */
.feedback-thumbnail {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid var(--color-border, #e2e8f0);
}

.feedback-thumbnail:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ========================================
   画像モーダル（拡大表示）
   ======================================== */

.image-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    justify-content: center;
    align-items: center;
}

.image-modal.show {
    display: flex;
}

.image-modal img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    border-radius: 4px;
}

.image-modal-close {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 40px;
    color: white;
    cursor: pointer;
    background: none;
    border: none;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.image-modal-close:hover {
    opacity: 1;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .image-upload-area {
        padding: 12px;
    }

    .image-preview,
    .image-add-btn {
        width: 80px;
        height: 80px;
    }

    .feedback-thumbnail {
        width: 60px;
        height: 60px;
    }
}
