/*
 * This is a manifest file that'll be compiled into application.css.
 *
 * With Propshaft, assets are served efficiently without preprocessing steps. You can still include
 * application-wide styles in this file, but keep in mind that CSS precedence will follow the standard
 * cascading order, meaning styles declared later in the document or manifest will override earlier ones,
 * depending on specificity.
 *
 * Consider organizing styles into separate files for maintainability.
 */

/* =================================================================
   響應式表格樣式
   ================================================================= */

/* 商戶名稱欄位 - 桌面版：完整顯示 */
.merchant-name-cell {
  max-width: 300px;
  word-break: break-word;
  overflow-wrap: break-word;
}

/* 平板版：略微限制寬度 */
@media (max-width: 992px) {
  .merchant-name-cell {
    max-width: 200px;
  }
}

/* 手機版：顯示省略 + hover 展開 */
@media (max-width: 768px) {
  .merchant-name-cell {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .merchant-name-cell:hover,
  .merchant-name-cell:focus {
    white-space: normal;
    overflow: visible;
    position: relative;
    z-index: 10;
    background: var(--bs-body-bg, white);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    padding: 4px 8px;
    border-radius: 4px;
  }
}

/* =================================================================
   禁用按鈕樣式
   ================================================================= */

.btn.disabled[data-bs-toggle="tooltip"] {
  pointer-events: auto; /* 允許 tooltip 顯示 */
}

/* =================================================================
   維護模式標示增強
   ================================================================= */

.badge[data-bs-toggle="tooltip"] {
  cursor: help;
}
