/* Content Error Reporter - Frontend Styles */

/* 報告ボタンのスタイル */
.cer-report-button {
    display: inline-block;
    color: #999999 !important;
    text-decoration: underline !important;
    font-size: 12px;
    font-weight: normal;
    transition: color 0.3s ease;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
    text-align: right;
    float: right;
    clear: both;
}

.cer-report-button::before {
    content: "\f227";
    font-family: dashicons;
    font-size: 12px;
    margin-right: 4px;
    vertical-align: middle;
    text-decoration: none !important;
    opacity: 0.8;
}

.cer-report-button:hover::before {
    opacity: 1;
}

.cer-report-button:hover {
    color: #666666 !important;
    text-decoration: underline !important;
}

.cer-report-button:focus {
    outline: 1px dotted #999999;
    outline-offset: 2px;
}

/* 報告ボタンのコンテナ */
.cer-report-button-container {
    text-align: right;
    margin: 10px 0;
    clear: both;
}

.cer-report-button-container .cer-report-button {
    float: none;
    display: inline;
}

/* 自動挿入された報告リンクのスタイル */
.cer-reporter-container {
    text-align: right;
    margin: 15px 0;
    clear: both;
}

.cer-reporter-link {
    display: inline-block;
    color: #999999 !important;
    text-decoration: underline !important;
    font-size: 12px;
    font-weight: normal;
    transition: color 0.3s ease;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
}

.cer-reporter-link::before {
    content: "\f227";
    font-family: dashicons;
    font-size: 12px;
    margin-right: 4px;
    vertical-align: middle;
    text-decoration: none !important;
    opacity: 0.8;
}

.cer-reporter-link:hover::before {
    opacity: 1;
}

.cer-reporter-link:hover {
    color: #666666 !important;
    text-decoration: underline !important;
}

.cer-reporter-link:focus {
    outline: 1px dotted #999999;
    outline-offset: 2px;
}

/* モーダルのスタイル */
.cer-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease;
}

.cer-modal.show {
    display: block;
}

.cer-modal-content {
    background-color: #ffffff;
    margin: 5% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease;
}

.cer-modal-header {
    padding: 20px 24px 16px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cer-modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333333;
}

.cer-modal-close {
    font-size: 24px;
    font-weight: bold;
    color: #999999;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
    transition: color 0.2s ease;
}

.cer-modal-close:hover {
    color: #666666;
}

.cer-modal-body {
    padding: 24px;
}

/* 注意事項のスタイル */
.cer-notice {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 16px;
    margin-bottom: 20px;
}

.cer-notice h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    font-weight: 600;
    color: #495057;
}

.cer-notice p {
    margin: 0 0 8px 0;
    font-size: 13px;
    line-height: 1.5;
    color: #6c757d;
}

.cer-notice p:last-child {
    margin-bottom: 0;
}

/* フォームのスタイル */
.cer-form-group {
    margin-bottom: 20px;
}

.cer-form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #333333;
    font-size: 14px;
}

.cer-form-group .required {
    color: #ff6b6b;
}

.cer-form-group .optional {
    color: #999999;
    font-weight: normal;
    font-size: 11px;
}

.cer-form-group input[type="email"],
.cer-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #d0d0d0;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
}

.cer-form-group input[type="email"]:focus,
.cer-form-group textarea:focus {
    outline: none;
    border-color: #4a90e2;
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.cer-form-group textarea {
    resize: vertical;
    min-height: 100px;
}

/* ボタンのスタイル */
.cer-form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
}

.cer-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.cer-btn-cancel {
    background-color: #f5f5f5;
    color: #666666;
}

.cer-btn-cancel:hover {
    background-color: #e8e8e8;
}

.cer-btn-submit {
    background-color: #4a90e2;
    color: #ffffff;
}

.cer-btn-submit:hover {
    background-color: #357abd;
}

.cer-btn-submit:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

/* メッセージのスタイル */
.cer-message {
    padding: 12px 16px;
    border-radius: 4px;
    margin-bottom: 16px;
    font-size: 14px;
}

.cer-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.cer-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ローディングのスタイル */
.cer-loading {
    text-align: center;
    padding: 20px;
}

.cer-loading p {
    margin: 0;
    color: #666666;
    font-size: 14px;
}

/* reCAPTCHAのスタイル調整 */
.cer-form-group .g-recaptcha {
    margin-top: 8px;
}

/* アニメーション */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .cer-modal-content {
        margin: 10px;
        width: calc(100% - 20px);
        max-width: none;
    }
    
    .cer-modal-header,
    .cer-modal-body {
        padding: 16px;
    }
    
    .cer-form-actions {
        flex-direction: column;
    }
    
    .cer-btn {
        width: 100%;
        margin-bottom: 8px;
    }
    
    .cer-notice {
        padding: 12px;
        margin-bottom: 16px;
    }
    
    .cer-notice h4 {
        font-size: 13px;
    }
    
    .cer-notice p {
        font-size: 12px;
    }
}

/* アクセシビリティ対応 */
@media (prefers-reduced-motion: reduce) {
    .cer-modal,
    .cer-modal-content,
    .cer-report-button,
    .cer-btn {
        animation: none;
        transition: none;
    }
} 