.location-section {
    background: white;
    padding: 20px 30px;
    margin: 20px 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 15px;
}

.location-select {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.tabs {
    display: flex;
    gap: 5px;
    padding: 0 30px;
    margin-bottom: 20px;
}

.tab-button {
    flex: 1;
    padding: 12px 20px;
    border: 1px solid #ddd;
    background: white;
    cursor: pointer;
    border-radius: 5px 5px 0 0;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s;
}

.tab-button:hover {
    background: #f5f5f5;
}

.tab-button.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

.tab-content {
    display: none;
    padding: 30px;
}

.tab-content.active {
    display: block;
}

.manual-update-section,
.csv-update-section,
.auto-update-section,
.order-upload-section {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.search-box {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.search-results {
    margin-top: 20px;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 5px;
    margin-bottom: 10px;
}

.result-item-info {
    flex: 1;
}

.result-item-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.quantity-input {
    width: 80px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    text-align: center;
}

.file-upload-area {
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 40px;
    text-align: center;
    margin-bottom: 20px;
    transition: all 0.3s;
}

.file-upload-area:hover {
    border-color: #667eea;
    background: #f9f9f9;
}

.file-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.file-icon {
    font-size: 48px;
}

.file-name {
    margin-top: 10px;
    color: #666;
}

.csv-preview {
    margin-top: 20px;
    max-height: 300px;
    overflow-y: auto;
}

.csv-preview table {
    width: 100%;
    border-collapse: collapse;
}

.csv-preview th,
.csv-preview td {
    padding: 8px;
    border: 1px solid #e0e0e0;
    text-align: left;
}

.update-results {
    margin-top: 20px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 5px;
}

.update-history-section {
    margin: 20px 30px;
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.history-list {
    margin-top: 20px;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 5px;
    margin-bottom: 10px;
}

.location-form {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.location-list {
    margin-top: 20px;
}

.location-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 5px;
    margin-bottom: 10px;
}

.bulk-location-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 20px;
}

.bulk-location-form label {
    font-weight: 600;
    color: #333;
}

.bulk-search-results {
    margin-top: 20px;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 5px;
    max-height: 300px;
    overflow-y: auto;
}

.bulk-products-list {
    margin-top: 10px;
}

.bulk-product-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: white;
    border-radius: 5px;
    margin-bottom: 8px;
}

.bulk-product-item .stock-info {
    font-weight: 600;
    color: #667eea;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.no-history {
    text-align: center;
    color: #999;
    padding: 20px;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.history-filename {
    font-weight: 600;
    color: #333;
}

.history-date {
    color: #666;
    font-size: 0.9em;
}

.history-stats {
    display: flex;
    gap: 15px;
    color: #666;
    font-size: 0.9em;
}

.history-stats .unmatched {
    color: #e74c3c;
}

.history-stats .warning-text {
    color: #b36b00;
}

.update-result-item.warning {
    background: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
}

/* 一括移動CSV関連 */
.bulk-move-csv-section h3 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #333;
}

.csv-preview pre {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    border: 1px solid #ddd;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: monospace;
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
}

.csv-preview-error {
    background: #ffe6e6;
    padding: 15px;
    border-radius: 5px;
    border: 1px solid #ff9999;
    margin-top: 10px;
    color: #c33;
}

/* ボタンとリンクのスタイル改善 */
.order-upload-section .btn,
.csv-update-section .btn {
    font-size: 14px;
    padding: 10px 20px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
}

.order-upload-section .btn-secondary,
.csv-update-section .btn-secondary {
    background: #6c757d;
    color: white;
}

.order-upload-section .btn-secondary:hover,
.csv-update-section .btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.order-upload-section .btn-success,
.csv-update-section .btn-success {
    background: #66bb6a;
    color: white;
}

.order-upload-section .btn-success:hover,
.csv-update-section .btn-success:hover {
    background: #43a047;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.order-upload-section .btn:disabled,
.csv-update-section .btn:disabled {
    background: #bdc3c7;
    cursor: not-allowed;
    opacity: 0.6;
}

/* テキストの可読性向上 */
.order-upload-section,
.csv-update-section {
    color: #333;
    line-height: 1.6;
}

.order-upload-section h2,
.csv-update-section h2,
.order-upload-section h3,
.csv-update-section h3 {
    color: #333;
    font-weight: 600;
    margin-bottom: 15px;
}

.order-upload-section p,
.csv-update-section p {
    color: #555;
    margin-bottom: 10px;
}

.order-upload-section ul,
.csv-update-section ul {
    color: #555;
}

.order-upload-section li,
.csv-update-section li {
    margin-bottom: 8px;
}
