/* BobaLive Web Console: flat customer and product workbench. */
#comments-view .tools-header{
  overflow:visible;
  padding:8px 0 10px !important;
}
#comments-view .keyword-tools{
  display:grid;
  grid-template-columns:minmax(320px,560px) auto minmax(0,1fr);
  align-items:center;
  gap:10px;
  min-width:0;
  width:100%;
}
#comments-view .keyword-primary-tools{
  display:flex;
  align-items:center;
  gap:8px;
  min-width:0;
}
#comments-view .keyword-primary-tools #keyword{
  flex:1 1 360px;
  width:auto;
  min-width:180px;
}
#comments-view .keyword-primary-tools #apply-keyword-btn{
  flex:0 0 auto;
  min-height:38px;
  border-color:rgba(211,162,76,.28);
  color:#f1d398;
}
#comments-view #bridge-indicator{
  margin-left:0;
  white-space:nowrap;
}
#comments-view .comment-utility-tools{
  display:flex;
  align-items:center;
  gap:6px;
  justify-self:end;
}
#comments-view .comment-clear-btn{
  color:#a79d90;
  border-color:transparent;
  background:transparent;
}
#comments-view .comment-clear-btn:hover{
  color:#efaaa1;
  background:rgba(173,72,60,.08);
}
#comments-view .comment-more-menu{
  position:relative;
}
#comments-view .comment-more-menu > summary{
  display:inline-flex;
  align-items:center;
  min-height:36px;
  padding:8px 12px;
  list-style:none;
  cursor:pointer;
}
#comments-view .comment-more-menu > summary::-webkit-details-marker{display:none;}
#comments-view .comment-more-popover{
  position:absolute;
  z-index:50;
  top:calc(100% + 8px);
  right:0;
  display:grid;
  gap:7px;
  width:220px;
  padding:10px;
  border:1px solid rgba(211,162,76,.18);
  border-radius:12px;
  background:#111419;
  box-shadow:0 18px 44px rgba(0,0,0,.34);
}
#comments-view .comment-more-popover > .ghost-btn{
  justify-content:flex-start;
  width:100%;
}
#comments-view .comment-more-popover .language-switcher{
  justify-content:space-between;
  width:100%;
  margin:0;
}
#comments-view .ingest-key-card{
  display:block !important;
  padding:0 !important;
  overflow:visible;
  border-color:rgba(211,162,76,.12) !important;
  background:#111419 !important;
  box-shadow:none !important;
}
#comments-view .ingest-key-summary{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  min-height:56px;
  padding:10px 14px;
  list-style:none;
  cursor:pointer;
}
#comments-view .ingest-key-summary::-webkit-details-marker{display:none;}
#comments-view .ingest-key-title-group{
  display:flex;
  align-items:baseline;
  gap:10px;
}
#comments-view .ingest-key-title-group h2{
  margin:0;
  color:#e9e3da;
  font-size:16px;
}
#comments-view .ingest-toggle-copy{
  color:#b9ae9e;
  font-size:12px;
}
#comments-view .ingest-toggle-copy::before{content:"展開設定";}
#comments-view .ingest-key-card[open] .ingest-toggle-copy::before{content:"收合設定";}
#comments-view .ingest-key-panel{
  display:grid;
  gap:10px;
  padding:12px 14px 14px;
  border-top:1px solid rgba(255,255,255,.055);
}
#comments-view .ingest-key-description{
  margin:0;
  color:#a79f93;
  font-size:12px;
  line-height:1.55;
}
#comments-view .order-btn{
  min-height:30px !important;
  padding:5px 12px !important;
  border-radius:8px !important;
  background:linear-gradient(180deg,#2c7f40,#1f6030) !important;
  color:#fff !important;
  border:1px solid rgba(105,207,126,.48) !important;
  box-shadow:0 1px 0 rgba(255,255,255,.12) inset,0 4px 12px rgba(10,72,29,.2) !important;
  font-size:12px !important;
  font-weight:800 !important;
}
#comments-view .order-btn:hover{
  background:linear-gradient(180deg,#338044,#256b35) !important;
  color:#fff !important;
  border-color:rgba(125,225,145,.62) !important;
}
#comments-view .comment-badge.status-completed{
  background:rgba(80,154,103,.14) !important;
  color:#bde8c8 !important;
  border:1px solid rgba(105,198,132,.2) !important;
}
#comments-view .comment-badge.status-failed{
  min-height:30px !important;
  padding:5px 12px !important;
  border-radius:8px !important;
  background:linear-gradient(180deg,#ef4d45,#d9332d) !important;
  color:#fff !important;
  border:1px solid rgba(255,121,112,.62) !important;
  box-shadow:0 1px 0 rgba(255,255,255,.12) inset,0 4px 12px rgba(147,31,27,.18) !important;
  font-size:12px !important;
  font-weight:800 !important;
}
#comments-view .comment-badge.status-printing{
  background:rgba(76,123,174,.14) !important;
  color:#a9cff5 !important;
  border:1px solid rgba(109,162,216,.2) !important;
}
#comments-view .comment-badge.status-queued{
  background:rgba(211,162,76,.11) !important;
  color:#e9cb91 !important;
  border:1px solid rgba(211,162,76,.2) !important;
}
#comments-view .comment-list{
  gap:0 !important;
}
#comments-view .comment-card{
  position:relative;
  display:grid !important;
  grid-template-columns:minmax(0,1fr) max-content;
  column-gap:12px !important;
  align-items:start;
  margin:0 !important;
  padding:9px 10px !important;
  border:0 !important;
  border-bottom:1px solid rgba(255,255,255,.06) !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
}
#comments-view .comment-main{
  grid-column:1;
  grid-row:1;
  display:grid;
  gap:3px;
  min-width:0;
}
#comments-view .comment-user{
  color:#e8d4ae !important;
}
#comments-view .comment-side{
  grid-column:2;
  grid-row:1;
  align-self:start;
  width:max-content;
  min-width:0;
}
#comments-view .comment-body{
  min-width:0;
  margin:0 !important;
}
#comments-view .comment-card:hover{
  background:rgba(255,255,255,.018) !important;
}
#comments-view .comment-card.keyword-hit{
  padding-left:13px !important;
  border-left:3px solid #d3a24c !important;
}
#comments-view .comment-card.print-failed{
  padding-left:13px !important;
  border-left:3px solid #d56f64 !important;
}

@media (max-width:980px){
  #comments-view .keyword-tools{
    grid-template-columns:minmax(0,1fr) auto;
    row-gap:8px;
  }
  #comments-view .keyword-primary-tools{
    grid-column:1 / -1;
    width:min(560px,100%);
  }
  #comments-view #bridge-indicator{
    grid-column:1;
    justify-self:start;
  }
  #comments-view .comment-utility-tools{
    grid-column:2;
    justify-self:end;
  }
}

@media (max-width:520px){
  #comments-view .comment-card{
    column-gap:10px !important;
    padding-top:10px !important;
    padding-bottom:10px !important;
  }
  #comments-view .order-btn,
  #comments-view .comment-badge.status-failed{
    min-height:34px !important;
    padding:6px 13px !important;
    font-size:13px !important;
  }
}

#customers-view,
#products-view{
  --wb-line:rgba(255,255,255,.065);
  --wb-line-strong:rgba(211,162,76,.22);
  --wb-muted:#aaa296;
  --wb-soft:#d0c8bc;
  --wb-selected:rgba(211,162,76,.075);
}

#customers-view .page-header,
#products-view .page-header{
  align-items:flex-end;
  margin-bottom:8px;
  padding-bottom:16px;
  border-bottom:1px solid var(--wb-line);
}
#customers-view .page-header h1,
#products-view .page-header h1{
  font-size:clamp(34px,3vw,48px);
  letter-spacing:-.035em;
}
#customers-view .customer-actions,
#products-view .customer-actions{
  align-items:center;
  gap:6px;
}
#customers-view .customer-actions .ghost-btn,
#products-view .customer-actions .ghost-btn{
  min-height:36px;
  padding:7px 10px;
  border:0;
  border-radius:4px;
  background:transparent;
  color:var(--wb-soft);
}
#customers-view .customer-actions .ghost-btn:hover,
#products-view .customer-actions .ghost-btn:hover{
  background:rgba(255,255,255,.035);
  color:#fff1d6;
}

#customers-view .customer-toolbar,
#products-view .customer-toolbar{
  display:flex;
  align-items:center;
  gap:10px;
  margin:0;
  padding:12px 0 14px !important;
  border:0 !important;
  border-bottom:1px solid var(--wb-line) !important;
  border-radius:0 !important;
  background:transparent !important;
}
#customers-view .customer-search-row,
#customers-view .customer-date-row,
#products-view .product-search-row,
#products-view .product-date-row{
  display:flex;
  align-items:center;
  gap:8px;
  width:auto;
}
#customers-view .customer-search-row:first-child,
#products-view .product-search-row:first-child{flex:1 1 auto;}
#customers-view #customer-search,
#products-view #product-search{
  flex:1 1 320px;
  min-width:240px;
}
#customers-view #customer-platform-filter,
#customers-view #customer-status-filter{
  flex:0 0 132px;
  width:132px;
}
#customers-view #customer-date-from,
#customers-view #customer-date-to,
#products-view #product-date-from,
#products-view #product-date-to{
  flex:0 0 140px;
  width:140px;
}
#customers-view #customer-clear-filters-btn{
  flex:0 0 auto;
  min-width:84px;
  white-space:nowrap;
}
#customers-view .customer-toolbar input,
#customers-view .customer-toolbar select,
#products-view .customer-toolbar input,
#products-view .customer-toolbar select{
  min-height:38px;
  border-color:rgba(255,255,255,.075);
  border-radius:5px;
  background:#101318;
}

#customers-view .customer-summary-strip{
  display:flex;
  align-items:baseline;
  gap:0;
  margin:0 0 18px;
  padding:12px 0 14px;
  border:0;
  border-bottom:1px solid var(--wb-line);
  background:transparent;
}
#customers-view .customer-summary-cell{
  display:flex;
  align-items:baseline;
  gap:8px;
  min-width:0;
  padding:0 22px 0 0;
}
#customers-view .customer-summary-cell + .customer-summary-cell{padding-left:22px;}
#customers-view .customer-summary-cell + .customer-summary-cell::before{
  top:2px;
  bottom:2px;
  background:var(--wb-line);
}
#customers-view .customer-summary-cell span{
  color:var(--wb-muted);
  font-size:12px;
  letter-spacing:0;
  text-transform:none;
}
#customers-view .customer-summary-cell strong{
  color:#e8c883;
  font-size:23px !important;
}

#customers-view .customer-layout{
  display:grid;
  grid-template-columns:minmax(0,1fr);
  gap:0;
  min-height:0;
}
#customers-view .customer-layout.drawer-open{
  grid-template-columns:minmax(560px,1.65fr) minmax(340px,.9fr);
  gap:28px;
}
#customers-view .customer-detail-card.drawer-closed{display:none;}
#customers-view .customer-list-card,
#customers-view .customer-detail-card,
#products-view .product-category-card,
#products-view .product-detail-card{
  min-height:0;
  border:0 !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
}
#customers-view .customer-detail-card,
#products-view .product-detail-card{
  position:sticky;
  top:22px;
  align-self:start;
  max-height:calc(100vh - 44px);
  overflow:auto !important;
  scrollbar-width:thin;
}
#customers-view .customer-detail-card{
  padding-left:28px !important;
  border-left:1px solid var(--wb-line) !important;
}

#customers-view .customer-list-head,
#products-view .customer-list-head{
  align-items:baseline;
  margin:0;
  padding:0 0 10px;
  border:0;
}
#customers-view .customer-list-head h3,
#products-view .customer-list-head h3{
  font-size:22px;
  font-weight:650;
}
#customers-view .customer-table-head,
#products-view .product-table-head{
  display:grid;
  gap:16px;
  align-items:center;
  padding:10px 14px;
  border-top:1px solid var(--wb-line);
  border-bottom:1px solid var(--wb-line-strong);
  color:#8f887c;
  font-size:11px;
  letter-spacing:.04em;
}
#customers-view .customer-table-head{
  grid-template-columns:minmax(0,2.2fr) 110px 150px 168px;
}
#products-view .product-table-head{
  grid-template-columns:minmax(0,1.55fr) minmax(150px,.9fr) 146px;
}
#customers-view .customer-record-list,
#products-view .product-category-list{
  padding:0;
  border-top:0;
}

#customers-view .customer-record-item{
  display:grid;
  grid-template-columns:minmax(0,2.2fr) 110px 150px 168px;
  gap:16px !important;
  align-items:center;
  min-height:72px;
  margin:0;
  padding:13px 14px !important;
  border:0 !important;
  border-bottom:1px solid rgba(255,255,255,.045) !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
}
#customers-view .customer-record-item:hover,
#products-view .product-category-item:hover{background:rgba(255,255,255,.025) !important;}
#customers-view .customer-record-item.active,
#products-view .product-category-item.active{
  margin:0;
  padding-left:11px !important;
  border:0 !important;
  border-left:3px solid #d3a24c !important;
  border-bottom:1px solid rgba(255,255,255,.055) !important;
  border-radius:0 !important;
  background:var(--wb-selected) !important;
  box-shadow:none !important;
}
#customers-view .customer-record-main{
  display:grid;
  gap:3px;
  min-width:0;
}
#customers-view .customer-record-name{
  color:#f0ede7;
  font-size:15px;
  font-weight:650;
}
#customers-view .customer-record-preview{
  display:block;
  grid-column:auto;
  max-width:100%;
  padding:0;
  overflow:hidden;
  color:#8f98a5;
  font-size:12px;
  text-overflow:ellipsis;
  white-space:nowrap;
}
#customers-view .customer-record-sub{
  color:#746f67;
  font-size:11px;
}
#customers-view .customer-record-meta{
  display:grid;
  gap:2px;
  color:var(--wb-soft);
}
#customers-view .customer-record-side{
  display:grid;
  justify-items:start;
  gap:5px;
}
#customers-view .customer-status-pill{
  padding:3px 7px;
  border-radius:999px;
  font-size:11px;
}
#customers-view .comment-source{
  padding:0 !important;
  border:0 !important;
  border-radius:0 !important;
  background:transparent !important;
  color:#aaa397 !important;
  font-size:11px;
  letter-spacing:.02em;
}
#customers-view .customer-record-time{
  color:#7f7a72;
  font-size:11px;
}
#customers-view .customer-detail-tabs{
  display:flex;
  gap:18px;
  padding:0;
  border-bottom:1px solid var(--wb-line);
}
#customers-view .customer-tab-btn{
  margin:0;
  padding:11px 0 10px;
  border:0;
  border-bottom:2px solid transparent;
  border-radius:0;
  background:transparent;
  color:#8f887c;
}
#customers-view .customer-tab-btn.active{
  border-bottom-color:#d3a24c;
  background:transparent;
  color:#f3d89f;
}
#customers-view .contact-chip{
  border-color:rgba(255,255,255,.08);
  background:transparent;
  color:#9d978d;
}
#customers-view .contact-chip.active{
  border-color:rgba(211,162,76,.34);
  background:rgba(211,162,76,.1);
  color:#edcb87;
}
#customers-view .customer-tab-panel .detail-block,
#customers-view .customer-tab-panel .mini-stat,
#customers-view .product-summary-item,
#customers-view .timeline-item{
  border-radius:0;
  background:transparent;
  box-shadow:none;
}

#products-view .product-layout{
  display:grid;
  grid-template-columns:minmax(560px,1.65fr) minmax(340px,.9fr);
  gap:28px;
  min-height:0;
}
#products-view .product-detail-card{
  padding-left:28px;
  border-left:1px solid var(--wb-line) !important;
}
#products-view .product-category-list{
  display:grid;
  grid-template-columns:1fr;
  gap:0;
}
#products-view .product-category-item{
  display:grid;
  grid-template-columns:minmax(0,1.55fr) minmax(150px,.9fr) 146px;
  gap:16px !important;
  align-items:center;
  min-height:58px;
  margin:0;
  padding:12px 14px !important;
  border:0 !important;
  border-bottom:1px solid rgba(255,255,255,.045) !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
}
#products-view .product-category-main{gap:3px;}
#products-view .product-category-main strong{
  min-height:0;
  color:#f0ede7;
  font-size:15px;
  font-weight:650;
  line-height:1.35;
  -webkit-line-clamp:unset;
}
#products-view .product-category-main span{
  color:#a79f93;
  font-size:12px;
}
#products-view .product-category-customers{
  display:block;
  min-width:0;
  overflow:hidden;
  color:#bbb3a6;
  font-size:12px;
  text-overflow:ellipsis;
  white-space:nowrap;
}
#products-view .product-category-customers span{
  display:inline;
  padding:0;
  border:0;
  border-radius:0;
  color:inherit;
  background:transparent;
  white-space:nowrap;
}
#products-view .product-category-customers span + span::before{
  content:"、";
  color:#625d55;
}
#products-view .product-category-time{
  color:#938c82;
  font-size:12px;
}
#products-view .product-detail-head{
  align-items:flex-start;
  padding-bottom:12px;
}
#products-view .product-detail-head h3{
  margin:4px 0 0;
  font-size:24px;
}
#products-view .product-detail-stats{
  display:flex;
  align-items:baseline;
  gap:24px;
  padding:12px 0 14px;
  border-top:0;
  border-bottom:1px solid var(--wb-line);
}
#products-view .product-detail-stats .mini-stat{
  display:flex;
  align-items:baseline;
  gap:7px;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
}
#products-view .product-detail-stats .mini-stat + .mini-stat::before{display:none;}
#products-view .product-detail-stats .mini-stat span{
  color:#8f887c;
  font-size:11px;
}
#products-view .product-detail-stats .mini-stat strong{
  color:#e8c883;
  font-size:17px;
  font-weight:650;
}
#products-view .product-buyer-list{border-top:0;}
#products-view .product-buyer-item{
  padding:13px 0 !important;
  border:0 !important;
  border-bottom:1px solid rgba(255,255,255,.045) !important;
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
}
#products-view .product-buyer-item.active{
  padding-left:11px !important;
  border-left:3px solid #d3a24c !important;
  background:var(--wb-selected) !important;
}
#products-view .product-buyer-order{
  border-radius:0 !important;
  background:transparent !important;
  box-shadow:none !important;
}

#products-view .workbench-date-field{
  display:grid;
  gap:5px;
  color:#9d958a;
  font-size:11px;
  letter-spacing:.02em;
}
#products-view .workbench-date-field input{margin:0;}
#products-view .product-anomaly-line{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  margin-top:2px;
}
#products-view .product-anomaly-line span,
#products-view .product-detail-alerts strong{
  font-size:11px;
  font-weight:650;
  letter-spacing:.01em;
}
#products-view .is-pending{color:#e6bd70 !important;}
#products-view .is-failed{color:#ed8e84 !important;}
#products-view .product-detail-alerts{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:8px 16px;
  padding:10px 0;
  border-bottom:1px solid var(--wb-line);
  color:#918a80;
  font-size:11px;
}
#products-view .product-detail-card{scroll-margin-top:12px;}

@media (max-width:1120px){
  #customers-view .customer-layout.drawer-open,
  #products-view .product-layout{
    grid-template-columns:minmax(460px,1.35fr) minmax(310px,.85fr);
    gap:20px;
  }
  #customers-view .customer-record-item,
  #customers-view .customer-table-head{
    grid-template-columns:minmax(0,1.8fr) 90px 130px 150px;
  }
}
@media (max-width:980px){
  #customers-view .customer-toolbar,
  #products-view .customer-toolbar{
    align-items:stretch;
    flex-direction:column;
  }
  #customers-view .customer-search-row,
  #customers-view .customer-date-row,
  #products-view .product-search-row,
  #products-view .product-date-row{
    width:100%;
    flex-wrap:wrap;
  }
  #customers-view .customer-layout.drawer-open,
  #products-view .product-layout{grid-template-columns:1fr;}
  #customers-view .customer-detail-card,
  #products-view .product-detail-card{
    position:static;
    max-height:none;
    padding:20px 0 0 !important;
    border-top:1px solid var(--wb-line) !important;
    border-left:0 !important;
  }
}
@media (max-width:900px){
  body:not(.mobile-mode) #app-shell,
  body:not(.mobile-mode) #app-shell.sidebar-collapsed{
    grid-template-columns:68px minmax(0,1fr) !important;
  }
  body:not(.mobile-mode) .sidebar{
    position:sticky;
    top:0;
    display:grid;
    width:68px !important;
    height:100vh;
    padding:10px 7px !important;
    overflow:hidden;
  }
  body:not(.mobile-mode) .sidebar-brand,
  body:not(.mobile-mode) .sidebar-footer,
  body:not(.mobile-mode) .sidebar .ui-label{
    display:none !important;
  }
  body:not(.mobile-mode) .sidebar-top{
    display:flex;
    justify-content:center;
    padding:4px 0 0;
  }
  body:not(.mobile-mode) .sidebar-nav{
    align-content:start;
    gap:5px;
  }
  body:not(.mobile-mode) .sidebar .nav-item{
    justify-content:center;
    min-width:0;
    width:100%;
    min-height:44px;
    padding:0 !important;
    gap:0;
  }
  body:not(.mobile-mode) .sidebar .ui-icon{
    width:16px;
    height:16px;
    margin:0;
  }
  body:not(.mobile-mode) .main-panel{
    min-width:0;
    width:auto;
  }
}
@media (max-width:760px){
  #comments-view .keyword-tools{
    grid-template-columns:minmax(0,1fr) auto;
  }
  #comments-view .keyword-primary-tools{
    grid-column:1 / -1;
  }
  #comments-view .comment-utility-tools{justify-content:flex-end;}
  #comments-view .ingest-key-title-group{
    align-items:flex-start;
    flex-direction:column;
    gap:2px;
  }
}
@media (max-width:720px){
  #customers-view .page-header,
  #products-view .page-header{
    align-items:flex-start;
    flex-direction:column;
    gap:12px;
  }
  body.mobile-mode #customers-view .customer-summary-strip,
  #customers-view .customer-summary-strip{
    display:grid !important;
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
    align-items:start;
    gap:10px 18px;
  }
  #customers-view .customer-summary-cell,
  #customers-view .customer-summary-cell + .customer-summary-cell{
    width:auto;
    padding:0;
  }
  #customers-view .customer-summary-cell + .customer-summary-cell::before{display:none;}
  #customers-view .customer-table-head,
  #products-view .product-table-head{display:none;}
  #customers-view .customer-record-item,
  #products-view .product-category-item{
    grid-template-columns:1fr;
    gap:7px !important;
    padding:13px 0 !important;
  }
  #customers-view .customer-record-item.active,
  #products-view .product-category-item.active{padding-left:11px !important;}
  #products-view .product-category-time{text-align:left;}
  #products-view .product-detail-stats{
    align-items:flex-start;
    flex-direction:column;
    gap:8px;
  }
}
