/* Scoped to the public offers panel; no admin/registration styles are changed. */
.offers-panel { display:grid; gap:24px; }
.offers-intro { padding:18px 20px; border:1px solid rgba(104,228,255,.24); border-radius:16px; background:linear-gradient(120deg,rgba(12,67,110,.48),rgba(5,22,45,.8)); }
.offers-intro p { margin:0; color:#d6e7f5; font-size:15px; line-height:1.8; }
.offers-intro small { display:block; margin-top:8px; color:#abc5dc; font-size:13px; line-height:1.7; }
.offer-filterbar { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
.offer-filterbar label { display:flex; align-items:center; gap:10px; color:#f2ce89; font-size:14px; }
.offer-filterbar select { max-width:100%; min-height:44px; padding:9px 36px 9px 12px; border:1px solid #386080; border-radius:10px; background:#08213f; color:#f2f9ff; font:inherit; }
.offer-filterbar p { margin:0; color:#a2c4dd; font-size:13px; }
.offer-group[hidden], .offer-viewer[hidden], .offer-viewer [hidden], .offer-cover img[hidden] { display:none!important; }
.offer-group { min-width:0; scroll-margin-top:20px; }
.offer-group-header { display:flex; align-items:center; gap:12px; margin-bottom:16px; padding-bottom:13px; border-bottom:1px solid rgba(242,189,93,.3); }
.offer-group-logo { flex:none; width:92px; height:52px; object-fit:contain; padding:7px; border-radius:8px; background:white; }
.offer-group-header h2 { margin:0; color:#f4f9ff; font-size:18px; line-height:1.35; }
.offer-group-header p { margin:4px 0 0; color:#a6cce5; font-size:12px; }
.offer-contact-link { flex:none; margin-left:auto; padding:10px 12px; min-height:42px; border:1px solid rgba(104,228,255,.3); border-radius:10px; background:rgba(7,64,97,.4); color:var(--cyan); font-size:13px; cursor:pointer; }
.offer-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.offer-card { min-width:0; border:1px solid rgba(104,228,255,.22); border-radius:15px; overflow:hidden; background:linear-gradient(145deg,rgba(8,37,69,.9),rgba(3,16,34,.94)); }
.offer-open { display:block; width:100%; padding:0; border:0; text-align:left; background:transparent; color:white; cursor:pointer; }
.offer-cover { position:relative; display:flex; align-items:center; justify-content:center; height:255px; padding:12px; background:rgba(255,255,255,.045); }
.offer-cover img { display:block; max-width:100%; max-height:100%; width:auto; height:auto; object-fit:contain; box-shadow:0 5px 16px #0004; }
.offer-cover.has-error::after { content:'預覽暫未載入・點擊查看'; color:#b3d8ec; font-size:14px; }
.offer-badge { position:absolute; right:9px; bottom:9px; padding:5px 8px; border-radius:7px; border:1px solid #b2e6ff40; background:#061c35eb; color:#d5f3ff; font-size:11px; }
.offer-card-text { display:block; padding:15px 16px 12px; }
.offer-card-text strong { display:block; font-size:16px; line-height:1.5; overflow-wrap:anywhere; }
.offer-card-text small { display:block; margin-top:7px; color:var(--cyan); font-size:13px; }
.offer-original { display:block; width:fit-content; margin:0 16px 15px; color:#bacde0; font-size:12px; text-decoration:underline; text-underline-offset:4px; }
.offer-open:hover .offer-card-text strong { color:#f5d494; }
.offer-open:focus-visible, .offer-contact-link:focus-visible, .offer-filterbar select:focus-visible, .offer-viewer button:focus-visible, .offer-viewer a:focus-visible, .offer-viewer select:focus-visible { outline:2px solid var(--gold); outline-offset:-3px; }
.offer-viewer { position:fixed; inset:0; z-index:150; padding:18px; display:grid; place-items:center; background:rgba(0,4,13,.96); }
.offer-viewer-card { width:min(1150px,100%); height:100%; max-height:1200px; display:grid; grid-template-rows:auto minmax(0,1fr) auto; border:1px solid #42728a; border-radius:17px; background:#06172a; overflow:hidden; }
.offer-viewer-header { display:flex; align-items:center; gap:12px; padding:14px 18px; border-bottom:1px solid #29506b; }
.offer-viewer-header > div { flex:1; min-width:0; }
.offer-viewer-header h2 { font-size:17px; line-height:1.45; margin:3px 0 0; overflow-wrap:anywhere; }
.offer-viewer-company { color:#80daef; font-size:12px; }
.offer-viewer button, .offer-viewer select { font:inherit; color:#ecf7ff; background:#0c2c49; border:1px solid #426981; border-radius:9px; min-height:42px; padding:8px 12px; cursor:pointer; }
.offer-viewer button:disabled { opacity:.4; cursor:default; }
.offer-viewer-close { flex:none; font-size:25px!important; min-width:44px; }
.offer-viewer-stage { position:relative; min-height:0; overflow:auto; display:flex; align-items:center; justify-content:center; padding:12px; background:#020c18; overscroll-behavior:contain; -webkit-overflow-scrolling:touch; touch-action:pan-x pan-y pinch-zoom; }
.offer-viewer-image { display:block; width:auto; height:auto; max-width:100%; max-height:100%; object-fit:contain; cursor:zoom-in; }
.offer-viewer-stage.is-zoomed { display:block; }
.offer-viewer-stage.is-zoomed .offer-viewer-image { max-width:none; max-height:none; height:auto; cursor:zoom-out; margin:0 auto; }
.offer-viewer-status { color:#c4dbe9; padding:25px; line-height:1.7; text-align:center; }
.offer-viewer-footer { display:flex; flex-wrap:wrap; justify-content:center; align-items:center; gap:10px; padding:12px 14px max(12px,env(safe-area-inset-bottom)); border-top:1px solid #29506b; }
.offer-viewer-pager { display:flex; align-items:center; justify-content:center; gap:8px; }
.offer-viewer-footer a { color:#92e4f5; font-size:13px; padding:8px; text-underline-offset:4px; }
.offer-viewer-footer select { padding:8px; }
@media(max-width:620px) {
  .offers-intro { padding:14px; }
  .offer-group-logo { width:74px; height:44px; }
  .offer-group-header { flex-wrap:wrap; gap:9px; }
  .offer-group-header h2 { font-size:16px; }
  .offer-contact-link { padding:8px; font-size:12px; }
  .offer-grid { gap:12px; }
  .offer-cover { height:200px; padding:8px; }
  .offer-card-text { padding:12px; }
  .offer-card-text strong { font-size:14px; }
  .offer-original { margin-left:12px; margin-right:12px; }
  .offer-viewer { padding:6px; }
  .offer-viewer-header { padding:10px 12px; }
  .offer-viewer-header h2 { font-size:15px; }
  .offer-viewer-stage { padding:6px; }
}
@media(max-width:440px) {
  .offer-grid { grid-template-columns:minmax(0,1fr); }
  .offer-cover { height:300px; }
  .offer-group-header > div { max-width:calc(100% - 85px); }
  .offer-contact-link { margin-left:0; }
  .offer-viewer-pager { width:100%; }
}
