/**
 * フロントエンド用スタイル
 */

.patent-invalidation-frontend,
.patent-simple-form,
.patent-history {
    max-width: 800px;
    margin: 20px 0;
}

.patent-section {
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
}

.patent-section h3 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
    border-bottom: 2px solid #2271b1;
    padding-bottom: 10px;
}

.patent-form .form-group {
    margin-bottom: 20px;
}

.patent-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.patent-form input[type="text"],
.patent-form input[type="file"],
.patent-form select,
.patent-form textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
}

.patent-form input[type="checkbox"] {
    margin-right: 8px;
}

.patent-form textarea {
    resize: vertical;
}

.patent-form .button {
    background: #2271b1;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 16px;
}

.patent-form .button:hover {
    background: #135e96;
}

.patent-form .button-primary {
    background: #46b450;
    font-size: 18px;
    padding: 12px 30px;
}

.patent-form .button-primary:hover {
    background: #3a9b44;
}

/* 引用文献 */
.reference-item {
    background: white;
    padding: 15px;
    margin-bottom: 10px;
    border: 1px solid #e0e0e0;
    border-radius: 3px;
}

.reference-item label {
    color: #666;
    font-size: 14px;
}

#add-reference {
    background: #666;
    color: white;
    font-size: 14px;
}

#add-reference:hover {
    background: #555;
}

/* 結果表示 */
#patent-result {
    background: #fff;
    border: 2px solid #46b450;
    border-radius: 5px;
    padding: 20px;
    margin-top: 30px;
}

#patent-result h3 {
    color: #46b450;
    margin-top: 0;
}

#result-content {
    margin: 20px 0;
    padding: 15px;
    background: #f0f8ff;
    border-left: 4px solid #2271b1;
    max-height: 400px;
    overflow-y: auto;
}

#download-link {
    background: #46b450;
    color: white;
    text-decoration: none;
    display: inline-block;
}

#download-link:hover {
    background: #3a9b44;
}

/* 履歴テーブル */
.patent-history-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.patent-history-table th {
    background: #2271b1;
    color: white;
    padding: 10px;
    text-align: left;
}

.patent-history-table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

.patent-history-table tr:hover {
    background: #f5f5f5;
}

.patent-history-table .button-small {
    padding: 5px 10px;
    font-size: 12px;
}

/* 通知 */
.patent-notice {
    background: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
    padding: 15px;
    border-radius: 5px;
    margin: 20px 0;
}

/* レスポンシブ */
@media (max-width: 600px) {
    .patent-invalidation-frontend,
    .patent-simple-form,
    .patent-history {
        padding: 10px;
    }
    
    .patent-section {
        padding: 15px;
    }
    
    .patent-history-table {
        font-size: 12px;
    }
    
    .patent-history-table th,
    .patent-history-table td {
        padding: 5px;
    }
}

/* ローディング */
.patent-loading {
    text-align: center;
    padding: 20px;
}

.patent-loading::after {
    content: "";
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #2271b1;
    border-radius: 50%;
    animation: patent-spin 1s linear infinite;
}

@keyframes patent-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}