/* 特許情報取得・分析プラグイン スタイルシート (更新版) */

/* 全体のレイアウト */
.patent-ai-container {
    max-width: 1200px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* フォーム関連スタイル */
.patent-ai-form {
    margin-bottom: 20px;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input[type="text"] {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1em;
    max-width: 300px;
}

.help-text {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
}

.submit-button {
    background-color: #0073aa;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1em;
}

.submit-button:hover {
    background-color: #005d87;
}

/* エラーとステータスメッセージ */
.error-message {
    padding: 15px;
    border-radius: 4px;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    margin-bottom: 20px;
}

.search-info {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #e9f7fe;
    border-radius: 4px;
    border: 1px solid #bee5eb;
}

.no-content {
    padding: 15px;
    text-align: center;
    color: #666;
    font-style: italic;
}

.no-documents-message {
    padding: 15px;
    text-align: center;
    color: #666;
    font-style: italic;
    border: 1px dashed #ddd;
    border-radius: 4px;
}

.no-timeline {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 15px 0;
}

/* 特許情報表示 */
.patent-info {
    margin-bottom: 30px;
}

.invention-title {
    margin-bottom: 15px;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

/* タイムライン表示 */
.timeline-container {
    margin-top: 20px;
    margin-bottom: 30px;
    overflow-x: auto;
}

.timeline-table {
    width: 100%;
    border-collapse: collapse;
}

.timeline-table th, .timeline-table td {
    padding: 10px;
    border: 1px solid #ddd;
    text-align: left;
}

.timeline-table th {
    background-color: #f8f9fa;
    font-weight: bold;
}

.timeline-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.timeline-table tr:hover {
    background-color: #f5f5f5;
}

.rejection-row {
    background-color: rgba(220, 53, 69, 0.1) !important;
}

.opinion-row {
    background-color: rgba(255, 193, 7, 0.1) !important;
}

.amendment-row {
    background-color: rgba(0, 123, 255, 0.1) !important;
}

/* 特許書類表示 */
.patent-documents {
    margin-bottom: 30px;
}

.document-section {
    margin-bottom: 30px;
}

.document-section h3 {
    margin-top: 0;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.document-container {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.document-header {
    padding: 10px 15px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.document-title {
    font-weight: bold;
    margin-bottom: 5px;
}

.document-number, .document-date {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 3px;
}

.document-content {
    padding: 15px;
    overflow: auto;
    max-height: 500px;
}

.document-content pre {
    white-space: pre-wrap;
    word-wrap: break-word;
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    font-family: monospace;
}

/* 特許請求の範囲表示 */
.latest-claims-section {
    margin-bottom: 30px;
}

.claims-container {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.claims-container h4 {
    margin: 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.claims-content {
    padding: 15px;
}

.claim-item {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.claim-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.claim-number {
    font-weight: bold;
    margin-bottom: 5px;
}

.claim-text {
    line-height: 1.6;
}

/* 引用文献一覧表示 */
.citations-section {
    margin-bottom: 30px;
}

.citations-container {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.citations-container h4 {
    margin: 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.citations-list {
    padding: 15px;
}

.citation-item {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.citation-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.citation-header {
    margin-bottom: 10px;
}

.citation-number {
    font-weight: bold;
}

.citation-text {
    display: inline-block;
}

/* 引用文献の原文表示 */
.citation-original {
    background-color: #f8f9fa;
    border-left: 3px solid #007bff;
    padding: 8px 12px;
    margin: 10px 0;
    font-size: 0.95em;
}

.citation-original-label {
    font-weight: bold;
    color: #0056b3;
    margin-right: 5px;
}

.citation-original-text {
    font-family: monospace;
}

.citation-actions {
    margin: 10px 0;
}

.fetch-patent-btn, .fetch-google-patent-btn, .upload-nonpatent-btn {
    background-color: #0073aa;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    margin-right: 10px;
}

.fetch-patent-btn:hover, .fetch-google-patent-btn:hover, .upload-nonpatent-btn:hover {
    background-color: #005d87;
}

.fetch-patent-btn:disabled, .fetch-google-patent-btn:disabled, .upload-nonpatent-btn:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
}

.patent-id {
    font-family: monospace;
    color: #666;
    font-size: 0.9em;
    margin-left: 10px;
}

.non-patent-file {
    margin-right: 10px;
    display: inline-block;
}

.upload-status {
    margin-top: 5px;
    font-size: 0.9em;
}

.upload-status .success {
    color: #28a745;
}

.upload-status .error {
    color: #dc3545;
}

.upload-status .info {
    color: #0073aa;
}

/* 引用文献内容表示エリア */
.citation-content {
    margin-top: 15px;
    padding: 15px;
    background-color: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 4px;
    overflow: hidden;
}

/* 特許文献表示の改善 */
.patent-details {
    padding: 15px;
}

.patent-details h4 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #333;
    border-bottom: 1px solid #eee;
    padding-bottom: 5px;
}

.patent-id-display {
    margin-bottom: 10px;
    font-family: monospace;
    color: #666;
}

/* データソース表示 - 新規追加 */
.patent-source {
    margin-bottom: 10px;
    padding: 5px 8px;
    background-color: #f0f8ff;
    border-left: 3px solid #4682b4;
    font-size: 0.9em;
    color: #4682b4;
}

.patent-abstract, .patent-pub-date, .patent-applicants {
    margin-bottom: 15px;
    line-height: 1.5;
}

.patent-claims {
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 10px;
}

.patent-claim {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px dotted #eee;
    line-height: 1.5;
}

.patent-claim:last-child {
    border-bottom: none;
}

/* 明細書表示コンテナ - 新規追加 */
.patent-description {
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 10px;
}

.description-container {
    max-height: 300px;
    overflow-y: auto;
    padding: 15px;
    border: 1px solid #eee;
    margin-top: 10px;
    background-color: #fcfcfc;
    line-height: 1.6;
    border-radius: 4px;
    font-family: system-ui, -apple-system, sans-serif;
    font-size: 0.95em;
}

/* PDFファイル情報 */
.pdf-info {
    padding: 15px;
    background-color: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 4px;
    font-style: italic;
    color: #666;
}

/* 生成AI分析セクション */
.ai-analysis-section {
    margin-bottom: 30px;
}

.ai-analysis-container {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.ai-analysis-container h3 {
    margin: 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.ai-model-selection {
    margin: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.ai-model-selection label {
    margin-right: 10px;
    font-weight: bold;
}

.ai-model-selection select {
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    min-width: 150px;
}

/* AIタブの改善 */
.ai-tabs {
    padding: 15px;
}

.ai-tabs .ui-tabs-nav {
    background: none;
    border: none;
    border-bottom: 1px solid #ddd;
    border-radius: 0;
    padding: 0;
}

.ai-tabs .ui-tabs-nav li {
    margin: 0 0 -1px 0;
    border-radius: 0;
}

.ai-tabs .ui-tabs-nav li a {
    padding: 10px 15px;
}

.ai-tabs .ui-tabs-panel {
    padding: 15px 0;
}

.tab-content {
    padding: 15px;
}

.generate-btn {
    background-color: #0073aa;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;/**
 * Patent AI Enhanced v2.5.0 - 追加CSSスタイル
 * 以下のスタイルを既存のCSSファイル(css/style.css)に追加してください
 */

/* =========================================
   1. 表示幅の調整
   ========================================= */

/* 経過情報セクション */
.patent-info-container {
    width: 100% !important;
    max-width: 1400px !important;
    margin: 0 auto;
}

/* 文書セクション全体 */
.patent-documents {
    width: 100% !important;
    max-width: 1400px !important;
    margin: 20px auto;
}

/* 各文書セクション */
.document-section {
    width: 100% !important;
    max-width: 1400px !important;
    margin-bottom: 30px;
    padding: 20px;
    background: #ffffff;
    border: 2px solid #0073aa;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* 拒絶理由通知書セクション */
.document-section.rejection {
    border-color: #dc3545;
}

.document-section.rejection h3 {
    color: #dc3545;
    border-bottom: 3px solid #dc3545;
    padding-bottom: 10px;
}

/* 意見書セクション */
.document-section.opinion {
    border-color: #28a745;
}

.document-section.opinion h3 {
    color: #28a745;
    border-bottom: 3px solid #28a745;
    padding-bottom: 10px;
}

/* 手続補正書セクション */
.document-section.amendment {
    border-color: #ffc107;
}

.document-section.amendment h3 {
    color: #856404;
    border-bottom: 3px solid #ffc107;
    padding-bottom: 10px;
}

/* 最新の特許請求の範囲セクション */
.claims-section {
    width: 100% !important;
    max-width: 1400px !important;
    margin: 20px auto;
    padding: 20px;
    background: #f8f9fa;
    border: 2px solid #0073aa;
    border-radius: 8px;
}

/* =========================================
   2. AIモデル選択の改善
   ========================================= */

.ai-model-selection {
    margin-bottom: 20px;
    padding: 15px;
    background: #f0f8ff;
    border: 2px solid #0073aa;
    border-radius: 5px;
}

.ai-model-selection label {
    font-weight: bold;
    font-size: 16px;
    margin-right: 10px;
    color: #0073aa;
}

.ai-model-selection select {
    padding: 8px 12px;
    font-size: 15px;
    border: 2px solid #0073aa;
    border-radius: 4px;
    min-width: 250px;
}

#selected-model-display {
    display: inline-block;
    margin-left: 15px;
    padding: 5px 10px;
    background: #0073aa;
    color: white;
    border-radius: 4px;
    font-weight: bold;
}

/* =========================================
   3. 引用文献表示の改善
   ========================================= */

.citations-container {
    width: 100% !important;
    max-width: 1400px !important;
    margin: 20px auto;
}

.citation-item {
    width: 100% !important;
    margin-bottom: 30px;
    border: 2px solid #0073aa;
    padding: 20px;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.citation-header {
    background: #0073aa;
    color: white;
    padding: 12px 15px;
    margin: -20px -20px 15px -20px;
    border-radius: 6px 6px 0 0;
}

.citation-number {
    font-size: 18px;
    font-weight: bold;
    margin-right: 10px;
}

.citation-text {
    font-size: 16px;
}

.citation-original {
    margin-bottom: 15px;
    padding: 12px;
    background: #f5f5f5;
    border-left: 4px solid #0073aa;
    border-radius: 4px;
}

.citation-original-label {
    font-weight: bold;
    color: #0073aa;
}

.citation-actions {
    margin-bottom: 15px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 5px;
    border: 1px solid #ddd;
}

.patent-upload-section {
    display: inline-block;
    margin-left: 15px;
    border-left: 2px solid #ddd;
    padding-left: 15px;
}

/* ボタンスタイル */
.fetch-patent-btn,
.fetch-google-patent-btn,
.upload-patent-btn,
.upload-nonpatent-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s ease;
}

.fetch-patent-btn {
    background: #0073aa;
    color: white;
}

.fetch-patent-btn:hover {
    background: #005a87;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.fetch-google-patent-btn {
    background: #4285f4;
    color: white;
}

.fetch-google-patent-btn:hover {
    background: #3367d6;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.upload-patent-btn,
.upload-nonpatent-btn {
    background: #28a745;
    color: white;
}

.upload-patent-btn:hover,
.upload-nonpatent-btn:hover {
    background: #218838;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* アップロードステータス */
.upload-status {
    margin-top: 10px;
    padding: 10px;
    border-radius: 4px;
}

.upload-status .success {
    color: #28a745;
    font-weight: bold;
}

.upload-status .error {
    color: #dc3545;
    font-weight: bold;
}

.upload-status .uploading {
    color: #ffc107;
    font-weight: bold;
}

/* =========================================
   4. 文献内容表示エリア
   ========================================= */

.citation-content-container {
    width: 100%;
    margin-top: 15px;
}

.citation-content {
    max-height: 600px;
    overflow-y: auto;
    padding: 15px;
    border: 1px solid #ccc;
    background: white;
    border-radius: 5px;
}

/* 図面表示 */
.patent-drawings {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 5px;
}

.patent-drawings h4 {
    color: #0073aa;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #0073aa;
}

.drawings-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.drawing-item {
    border: 1px solid #ddd;
    padding: 10px;
    border-radius: 5px;
    background: white;
    text-align: center;
    transition: transform 0.2s ease;
}

.drawing-item:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.drawing-item img {
    max-width: 300px;
    max-height: 300px;
    cursor: pointer;
    border-radius: 3px;
}

/* 図面リンク */
.drawings-link {
    display: inline-block;
    padding: 10px 20px;
    background: #4285f4;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background 0.3s ease;
}

.drawings-link:hover {
    background: #3367d6;
}

/* =========================================
   5. レスポンシブデザイン
   ========================================= */

@media (max-width: 1200px) {
    .patent-info-container,
    .patent-documents,
    .document-section,
    .claims-section,
    .citations-container {
        max-width: 95% !important;
    }
}

@media (max-width: 768px) {
    .citation-actions {
        flex-direction: column;
    }
    
    .patent-upload-section {
        border-left: none;
        border-top: 2px solid #ddd;
        margin-left: 0;
        margin-top: 10px;
        padding-left: 0;
        padding-top: 10px;
    }
    
    .drawing-item img {
        max-width: 100%;
    }
    
    .ai-model-selection select {
        min-width: 200px;
    }
}

/* =========================================
   6. その他の改善
   ========================================= */

/* ローディング表示 */
.loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-size: 16px;
}

.loading::before {
    content: "⏳ ";
}

/* エラー表示 */
.error {
    color: #dc3545;
    padding: 15px;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 5px;
    margin: 10px 0;
}

/* 成功表示 */
.success {
    color: #28a745;
    padding: 15px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 5px;
    margin: 10px 0;
}

/* 情報表示 */
.info {
    color: #0073aa;
    padding: 15px;
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    border-radius: 5px;
    margin: 10px 0;
}
