/* 販売管理システム カスタムスタイル */

/* ========================================
   レイアウト
   ======================================== */
html {
    position: relative;
    min-height: 100%;
}

body {
    margin-bottom: 60px;
}

.footer {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 60px;
}

/* ========================================
   テーブル
   ======================================== */
.table-hover tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.1);
}

.table th {
    background-color: #f8f9fa;
    white-space: nowrap;
}

.table-actions {
    white-space: nowrap;
    width: 1%;
}

/* ========================================
   フォーム
   ======================================== */
.form-label.required::after {
    content: " *";
    color: #dc3545;
}

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

/* ========================================
   ボタン
   ======================================== */
.btn-group-sm > .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* ========================================
   カード
   ======================================== */
.card-header {
    font-weight: 600;
}

/* ========================================
   クイックアクセスカード
   ======================================== */
.quick-access-card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.quick-access-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* ========================================
   ステータスバッジ
   ======================================== */
.badge-status-draft {
    background-color: #6c757d;
}

.badge-status-confirmed {
    background-color: #0d6efd;
}

.badge-status-shipped {
    background-color: #198754;
}

.badge-status-cancelled {
    background-color: #dc3545;
}

.badge-status-completed {
    background-color: #20c997;
}

/* ========================================
   htmx インジケーター
   ======================================== */
.htmx-indicator {
    display: none;
}

.htmx-request .htmx-indicator {
    display: inline-block;
}

.htmx-request.htmx-indicator {
    display: inline-block;
}

/* ========================================
   検索フォーム
   ======================================== */
.search-form {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 0.375rem;
    margin-bottom: 1rem;
}

/* ========================================
   明細テーブル（動的フォーム用）
   ======================================== */
.detail-table input[type="number"] {
    text-align: right;
}

.detail-table .remove-row {
    cursor: pointer;
}

/* ========================================
   金額表示
   ======================================== */
.amount,
.price {
    text-align: right;
    font-family: "Consolas", "Monaco", monospace;
}

/* ========================================
   ページタイトル
   ======================================== */
.page-title {
    border-bottom: 2px solid #0d6efd;
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

/* ========================================
   アクションボタン群
   ======================================== */
.action-buttons {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
    margin-bottom: 1rem;
}

/* ========================================
   印刷用スタイル
   ======================================== */
@media print {
    .navbar,
    .footer,
    .action-buttons,
    .btn {
        display: none !important;
    }

    .container {
        max-width: 100% !important;
    }
}
