/* 共通スタイル */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
    margin: 0;
    padding: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* ヘッダー */
.header {
    background-color: #343a40;
    color: white;
    padding: 1rem 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-title {
/* 
    font-size: 1.5rem;
    font-weight: bold;
    text-decoration: none;
*/
    color: white;
}

.site-title:hover {
    color: #17a2b8;
    text-decoration: none;
}

.logo {
    width: 300px;
    height: auto;
}

.nav-links {
    display: flex;
    gap: 1rem;
}

.nav-links a {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.nav-links a:hover {
    background-color: #495057;
    text-decoration: none;
}

/* ログアウトリンクのスタイル */
.logout-link {
    color: #dc3545 !important;
    font-weight: bold;
}

.logout-link:hover {
    background-color: #dc3545 !important;
    color: white !important;
}

/* メインコンテンツ */
.main-content {
    padding: 2rem 0;
    min-height: calc(100vh - 200px);
}

/* カードレイアウト */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.card-header {
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}

.card-title {
    font-size: 1.25rem;
    font-weight: bold;
    color: #343a40;
    margin: 0;
}

/* 商品グリッド */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.product-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
    padding-left: 1rem;
    padding-right: 1rem;
}

.product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background-color: #f8f9fa;
}

.no-image-placeholder {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    font-size: 0.9rem;
    font-weight: 500;
}

.no-image-placeholder.hidden {
    display: none;
}

.product-info {
    padding-top: 0;
    padding-bottom: 1rem;
}

.product-name {
    font-size: 1.1rem;
    font-weight: bold;
    color: #343a40;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.product-description {
    color: #6c757d;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    line-height: 1.4;
}

.product-price {
    font-size: 1rem;
    color: #6c757d;
    vertical-align: top;
    line-height: 1;
    margin-bottom: 0;
    margin-top: 0;
}

.product-category {
    color: #6c757d;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

/* ボタン */
.btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.2s;
    font-size: 0.9rem;
    font-weight: 500;
}

.btn:hover {
    transform: translateY(-1px);
    text-decoration: none;
}

.btn-primary {
    background-color: #007bff;
    color: white;
}

.btn-primary:hover {
    background-color: #0056b3;
    color: white;
}

.btn-success {
    background-color: #28a745;
    color: white;
}

.btn-success:hover {
    background-color: #1e7e34;
    color: white;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background-color: #c82333;
    color: white;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #545b62;
    color: white;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.add-to-cart-btn {
    margin-left: auto;
    width: 37%;
    align-self: flex-start;
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
}

/* フォーム */
.form-group {
    margin-bottom: 1rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #343a40;
}

.form-control {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

.add-to-cart-form {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: 1rem;
}

/* テーブル */
.table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.table th,
.table td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
}

.table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #343a40;
}

.table tr:hover {
    background-color: #f8f9fa;
}

/* アラート */
.alert {
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 1rem;
}

.alert-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.alert-danger {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.alert-warning {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

/* フッター */
.footer {
    background-color: #343a40;
    color: white;
    text-align: center;
    padding: 1rem 0;
    margin-top: auto;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1rem;
    }
    
    .header .container {
        flex-direction: column;
        gap: 1rem;
    }
    
    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* ローディング状態 */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* トースト通知 */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    min-width: 300px;
    padding: 1rem;
    border-radius: 4px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    animation: slideIn 0.3s ease-out;
}

.toast-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.toast-error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* カテゴリフィルター */
.category-filter {
    margin-bottom: 2rem;
}

.category-buttons {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.category-btn {
    padding: 0.5rem 1rem;
    border: 1px solid #dee2e6;
    background-color: white;
    color: #6c757d;
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.3s;
}

.category-btn:hover,
.category-btn.active {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
    text-decoration: none;
}

/* 管理者画面用スタイル */
.stat-card {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.5rem;
    text-align: center;
    border: 1px solid #dee2e6;
}

.stat-card h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    color: #6c757d;
}

.stat-number {
    font-size: 2rem;
    font-weight: bold;
    margin: 0;
    color: #007bff;
}

.quick-action {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.5rem;
    text-align: center;
    border: 1px solid #dee2e6;
}

.quick-action h3 {
    margin: 0 0 0.5rem 0;
    color: #495057;
}

.quick-action p {
    margin: 0 0 1rem 0;
    color: #6c757d;
}

/* ステータス表示 */
.status-pending {
    background-color: #ffc107;
    color: #212529;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-weight: bold;
}

.status-preparing {
    background-color: #17a2b8;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-weight: bold;
}

.status-shipped {
    background-color: #28a745;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-weight: bold;
}

/* 追加のボタンスタイル */
.btn-warning {
    background-color: #ffc107;
    color: #212529;
}

.btn-warning:hover {
    background-color: #e0a800;
    color: #212529;
}

.btn-outline-secondary {
    background-color: transparent;
    color: #6c757d;
    border: 1px solid #6c757d;
}

.btn-outline-secondary:hover {
    background-color: #6c757d;
    color: white;
}

.btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* アラート追加 */
.alert-info {
    background-color: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

/* フォーム関連 */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: #495057;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    font-size: 1rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus {
    border-color: #86b7fe;
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.form-control.is-invalid {
    border-color: #dc3545;
}

.invalid-feedback {
    display: block;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: #dc3545;
}

.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #dee2e6;
}

/* テーブル関連 */
.table {
    width: 100%;
    margin-bottom: 1rem;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 0.75rem;
    border-bottom: 1px solid #dee2e6;
    text-align: left;
}

.table th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: #495057;
}

.table tbody tr:hover {
    background-color: #f8f9fa;
}

/* 顧客情報・注文情報 */
.customer-info,
.order-info {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.5rem;
    margin-bottom: 2rem;
}

.customer-info p,
.order-info p {
    margin-bottom: 0.5rem;
}

.customer-info p:last-child,
.order-info p:last-child {
    margin-bottom: 0;
}

/* 次のステップ */
.next-steps {
    background-color: #e7f3ff;
    padding: 1.5rem;
    border-radius: 0.5rem;
    margin: 2rem 0;
}

.next-steps h3 {
    margin-top: 0;
    color: #0d6efd;
}

.next-steps ul {
    margin-bottom: 0;
    padding-left: 1.5rem;
}

.next-steps li {
    margin-bottom: 0.5rem;
}

/* テキスト関連 */
.text-muted {
    color: #6c757d;
}

.text-danger {
    color: #dc3545;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .form-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .form-actions .btn {
        margin-bottom: 0.5rem;
    }
    
    .table {
        font-size: 0.875rem;
    }
    
    .table th,
    .table td {
        padding: 0.5rem;
    }
} 

/* ログイン画面用スタイル */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    padding: 2.5rem;
    width: 100%;
    max-width: 400px;
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-title {
    font-size: 1.75rem;
    font-weight: bold;
    color: #343a40;
    margin-bottom: 0.5rem;
}

.login-subtitle {
    color: #6c757d;
    font-size: 0.9rem;
}

.login-form {
    margin-bottom: 1.5rem;
}

.login-btn {
    width: 100%;
    padding: 0.75rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.login-btn:active {
    transform: translateY(0);
}

.login-actions {
    text-align: center;
    margin-top: 1rem;
} 

/* 商品一覧画面用スタイル */
.no-image-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
}

.no-image-placeholder.hidden {
    display: none;
}

.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem;
    border-radius: 4px;
    color: white;
    z-index: 1000;
    display: none;
}

.toast-success {
    background-color: #28a745;
}

.toast-error {
    background-color: #dc3545;
} 