*{box-sizing:border-box}

body{
  margin:0;
  background:#f5f7fb;
  color:#172033;
  font-family:-apple-system,BlinkMacSystemFont,"Noto Sans TC","Microsoft JhengHei",sans-serif;
}

.page{
  width:min(960px,100%);
  margin:0 auto;
  padding:18px 12px 32px;
}

.narrow{width:min(680px,100%)}

.search-card,.map-card{
  background:#fff;
  border-radius:18px;
  box-shadow:0 10px 30px rgba(20,38,80,.08);
  padding:18px;
  margin-bottom:14px;
}

.brand{
  font-size:13px;
  letter-spacing:.08em;
  color:#0d52b8;
  font-weight:800;
}

h1{
  font-size:22px;
  margin:6px 0 16px;
  line-height:1.35;
}

.search-row{
  display:flex;
  gap:8px;
}

input[type=search],input[type=file]{
  width:100%;
  font-size:16px;
  border:1px solid #d7deea;
  border-radius:14px;
  padding:14px;
  background:#fff;
}

button{
  border:0;
  border-radius:14px;
  background:#0d52b8;
  color:#fff;
  font-size:16px;
  font-weight:800;
  padding:0 18px;
  min-height:50px;
}

.hint{
  line-height:1.7;
  color:#5c667a;
}

.result{
  margin-top:14px;
  border-radius:14px;
  padding:12px;
  line-height:1.6;
}

.muted{
  background:#f2f5fa;
  color:#697386;
}

.success{
  background:#eef9f0;
  color:#175c2a;
}

.error{
  background:#fff1f0;
  color:#9f1d16;
}

.result-item{
  width:100%;
  display:block;
  text-align:left;
  background:#fff;
  color:#172033;
  border:1px solid #dce3ef;
  padding:12px;
  margin:8px 0;
  border-radius:14px;
  min-height:auto;
}

.result-item strong{
  display:block;
  font-size:17px;
}

.result-item span{
  display:block;
  color:#536078;
  font-size:14px;
}

.map-scroll{
  overflow:auto;
  border-radius:14px;
  background:#fff;
  width:100%;
}

/* 關鍵：容器跟圖片同尺寸 */
.map-wrap{
  position:relative;
  width:100%;
}

/* 關鍵：圖片不要 max-width，不要限制 450px */
.map-wrap img{
  display:block;
  width:100%;
  height:auto;
}

/* 紅圈用百分比，會跟圖片一起縮放 */
.seat-marker{
  position:absolute;
  transform:translate(-50%,-50%);
  width:8.9%;
  aspect-ratio:1;
  border-radius:50%;
  pointer-events:none;
  opacity:0;
}

.seat-marker.active{
  opacity:1;
  border:6px solid #e60012;
  background:rgba(230,0,18,.13);
  box-shadow:
    0 0 0 8px rgba(230,0,18,.18),
    0 0 24px rgba(230,0,18,.58);
  animation:pulse 1.05s infinite;
}

.seat-marker[data-table-no="主桌"]{
  width:13.2%;
}

.seat-marker[data-table-no="貴賓1"],
.seat-marker[data-table-no="貴賓2"]{
  width:10.5%;
}

@keyframes pulse{
  0%,100%{filter:brightness(1)}
  50%{filter:brightness(1.25)}
}

@media(max-width:640px){
  .page{
    padding:12px 8px;
  }

  .search-card,.map-card{
    border-radius:16px;
    padding:14px;
  }

  .search-row{
    position:sticky;
    top:8px;
    z-index:5;
    background:#fff;
    padding-bottom:8px;
  }

  h1{
    font-size:20px;
  }

  button{
    padding:0 14px;
  }
}

.event-banner {
  width: 100%;
  background: #f8f6f2;
}

.banner-img {
  width: 100%;
  display: block;
}