/*
 * Google 商家資訊卡 — 奶油暖調 × 週時段圖表
 * google-biz-card v1.0.0 | mummy.com.tw
 * ─────────────────────────────────────────
 */

@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+TC:wght@400;500;700&family=Playfair+Display:ital,wght@0,700;1,400&family=DM+Mono:wght@400;500&display=swap');

/* ══ 外層容器 ════════════════════════════════════════ */
.gbc-wrap {
  margin: 28px 0;
  font-family: -apple-system, 'Noto Sans TC', 'PingFang TC', 'Microsoft JhengHei', sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ══ 卡片本體 ═════════════════════════════════════════ */
.gbc-card {
  background: #fffdf8;
  border: 1.5px solid #e2cdb0;
  border-radius: 20px;
  overflow: hidden;
  max-width: 560px;
}

.gbc-card.gbc-is-closed {
  filter: saturate(0.55);
  opacity: 0.85;
}

/* ══ 標頭 ════════════════════════════════════════════ */
.gbc-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 22px 24px 18px;
  border-bottom: 1px solid #eddfc8;
  position: relative;
}

/* 左側印刷條紋 */
.gbc-head::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: repeating-linear-gradient(
    180deg,
    #c4a882 0px,
    #c4a882 18px,
    #eddfc8 18px,
    #eddfc8 26px
  );
}

.gbc-avatar {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: #f0e6d4;
  border: 1.5px solid #d4b990;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
  margin-left: 8px;
  overflow: hidden;
}

/* 有首圖時：圖片填滿，無邊框裝飾色 */
.gbc-avatar-photo {
  background: #e8dcc8;
  padding: 0;
}

.gbc-avatar-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 0;
}

.gbc-head-info {
  flex: 1;
  min-width: 0;
}

.gbc-eyebrow {
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #b89870;
  font-family: 'DM Mono', 'Courier New', monospace;
  margin-bottom: 4px;
}

.gbc-name {
  font-family: 'Playfair Display', Georgia, '宋體', serif;
  font-size: 22px;
  font-weight: 700;
  color: #2c1a0e;
  line-height: 1.25;
}

.gbc-address-short {
  font-size: 12px;
  color: #9a7a5a;
  margin-top: 4px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 狀態徽章 */
.gbc-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 20px;
  padding: 5px 13px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: .02em;
}

.gbc-status-open {
  background: #e8f4ee;
  border: 1px solid #b8d9c4;
  color: #2a6a45;
}

.gbc-status-temp {
  background: #fff8e8;
  border: 1px solid #e8d4a0;
  color: #8a6010;
}

.gbc-status-closed {
  background: #f5ede0;
  border: 1px solid #d4b990;
  color: #8a5c2a;
}

.gbc-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  display: inline-block;
  flex-shrink: 0;
}

@keyframes gbc-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: .25; }
}

.gbc-dot-blink {
  animation: gbc-blink 1.8s ease-in-out infinite;
}

/* ══ 停業提示 ═════════════════════════════════════════ */
.gbc-closed-notice {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 24px;
  background: #fdf5eb;
  border-bottom: 1px solid #eddfc8;
}

.gbc-closed-icon {
  font-size: 28px;
  opacity: .7;
  flex-shrink: 0;
}

.gbc-closed-title {
  font-size: 14px;
  font-weight: 700;
  color: #5a3e1b;
}

.gbc-closed-sub {
  font-size: 11px;
  color: #b89870;
  margin-top: 4px;
  font-family: 'DM Mono', monospace;
}

.gbc-info-faded {
  opacity: .5;
  pointer-events: none;
}

/* ══ 數據列 ══════════════════════════════════════════ */
.gbc-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  border-bottom: 1px solid #eddfc8;
}

.gbc-metric {
  padding: 16px 8px;
  text-align: center;
  border-right: 1px solid #eddfc8;
}

.gbc-metric:last-child {
  border-right: none;
}

.gbc-metric-num {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 30px;
  font-weight: 700;
  color: #2c1a0e;
  line-height: 1;
}

.gbc-stars {
  display: flex;
  gap: 2px;
  justify-content: center;
  margin: 5px 0 3px;
}

.gbc-metric-label {
  font-size: 10px;
  color: #b89870;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-family: 'DM Mono', monospace;
}

.gbc-metric-sub {
  font-size: 11px;
  color: #9a7a5a;
  margin-top: 3px;
}

.gbc-today-time {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 15px;
  font-style: italic;
  color: #5a3e1b;
  margin-top: 6px;
  line-height: 1.3;
}

/* ══ 週時段長條圖 ════════════════════════════════════ */
.gbc-hours {
  padding: 18px 22px 20px;
  border-bottom: 1px solid #eddfc8;
  background: #fdf9f3;
}

.gbc-hours-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.gbc-hours-title {
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: #b89870;
  font-family: 'DM Mono', monospace;
}

.gbc-hours-note {
  font-size: 11px;
  color: #c4a882;
  font-family: 'DM Mono', monospace;
}

.gbc-timeline {
  display: flex;
  gap: 6px;
}

.gbc-day-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.gbc-day-label {
  font-size: 10px;
  color: #b89870;
  font-family: 'DM Mono', monospace;
  white-space: nowrap;
}

.gbc-today .gbc-day-label {
  color: #5a3e1b;
  font-weight: 600;
}

.gbc-bar-track {
  width: 100%;
  height: 64px;
  background: #f0e6d4;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
}

.gbc-bar-closed {
  background: #eddfc8;
}

.gbc-bar-fill {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: #c4a882;
  border-radius: 6px;
  transition: height .6s cubic-bezier(.4, 0, .2, 1);
  min-height: 4px;
}

.gbc-today .gbc-bar-fill {
  background: #5a3e1b;
}

.gbc-closed-mark {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  color: #c4a882;
  font-family: 'DM Mono', monospace;
  letter-spacing: .04em;
}

.gbc-day-time {
  font-size: 9px;
  color: #9a7a5a;
  text-align: center;
  line-height: 1.4;
  font-family: 'DM Mono', monospace;
  white-space: nowrap;
}

.gbc-today .gbc-day-time {
  color: #5a3e1b;
  font-weight: 600;
}

/* ══ 資訊格 ══════════════════════════════════════════ */
.gbc-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.gbc-cell {
  padding: 14px 20px;
  border-right: 1px solid #eddfc8;
  border-bottom: 1px solid #eddfc8;
}

.gbc-cell:nth-child(even) {
  border-right: none;
}

.gbc-cell.gbc-full {
  grid-column: 1 / -1;
  border-right: none;
}

/* 最後一行不需要底線（讓按鈕區的 border-top 補上分隔）*/
.gbc-info .gbc-cell:last-child,
.gbc-info .gbc-cell:nth-last-child(2):not(:nth-child(odd)):not(.gbc-full) {
  border-bottom: none;
}

.gbc-cell-lbl {
  font-size: 10px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #b89870;
  font-family: 'DM Mono', monospace;
  margin-bottom: 4px;
}

.gbc-cell-val {
  font-size: 13px;
  color: #3a2510;
  line-height: 1.55;
}

.gbc-cell-link {
  font-size: 13px;
  color: #8a5c2a;
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-color: #d4b990;
}

.gbc-cell-link:hover {
  color: #5a3e1b;
  text-decoration-color: #5a3e1b;
}

/* ══ 按鈕列 ══════════════════════════════════════════ */
.gbc-actions {
  display: flex;
  gap: 10px;
  padding: 16px 20px 18px;
  background: #fdf9f3;
  border-top: 1px solid #eddfc8;
  flex-wrap: wrap;
}

.gbc-btn {
  flex: 1;
  min-width: 80px;
  padding: 11px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: background .15s, color .15s;
  letter-spacing: .02em;
}

.gbc-btn-pri {
  background: #2c1a0e;
  color: #f5e8d0;
  border: 1.5px solid #2c1a0e;
}

.gbc-btn-pri:hover,
.gbc-btn-pri:focus {
  background: #3d2510;
  border-color: #3d2510;
  color: #f5e8d0;
  text-decoration: none;
}

.gbc-btn-sec {
  background: transparent;
  color: #5a3e1b;
  border: 1.5px solid #c4a882;
}

.gbc-btn-sec:hover,
.gbc-btn-sec:focus {
  background: #f5ede0;
  color: #3a2510;
  text-decoration: none;
}

/* ══ 頁尾 ════════════════════════════════════════════ */
.gbc-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 22px;
  background: #faf5ec;
  border-top: 1px solid #eddfc8;
}

.gbc-foot-txt {
  font-size: 10px;
  color: #c4a882;
  font-family: 'DM Mono', monospace;
  display: flex;
  align-items: center;
  gap: 5px;
}

.gbc-foot-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #c4a882;
  display: inline-block;
  flex-shrink: 0;
}

/* ══ 錯誤提示 ════════════════════════════════════════ */
.gbc-error {
  display: inline-block;
  padding: 12px 18px;
  background: #fdf5eb;
  border: 1px solid #e8d4a0;
  border-radius: 12px;
  color: #8a6010;
  font-size: 13px;
  line-height: 1.5;
}

/* ══ 手機版響應式 ════════════════════════════════════ */
@media (max-width: 520px) {
  .gbc-head {
    padding: 18px 18px 16px;
    gap: 10px;
  }

  .gbc-avatar {
    width: 44px;
    height: 44px;
    font-size: 20px;
  }

  .gbc-name {
    font-size: 18px;
  }

  .gbc-status {
    font-size: 10px;
    padding: 4px 9px;
  }

  .gbc-metric-num {
    font-size: 24px;
  }

  .gbc-hours {
    padding: 14px 16px 16px;
  }

  .gbc-timeline {
    gap: 4px;
  }

  .gbc-bar-track {
    height: 52px;
  }

  .gbc-day-time {
    font-size: 8px;
  }

  /* 資訊格手機改單欄 */
  .gbc-info {
    grid-template-columns: 1fr;
  }

  .gbc-cell,
  .gbc-cell:nth-child(even) {
    border-right: none;
  }

  .gbc-info .gbc-cell:last-child {
    border-bottom: none;
  }

  .gbc-info .gbc-cell:nth-last-child(2):not(.gbc-full) {
    border-bottom: 1px solid #eddfc8;
  }

  .gbc-actions {
    padding: 14px 16px 16px;
    gap: 8px;
  }

  .gbc-foot {
    flex-direction: column;
    gap: 4px;
    text-align: center;
    padding: 10px 16px;
  }
}

/* ══ 購票按鈕（聯盟行銷）════════════════════════════════ */
.gbc-btn-ticket {
  background: #e05c00;
  color: #fff !important;
  border: 1.5px solid #e05c00;
  font-weight: 700;
  letter-spacing: .03em;
  flex: 1.3;              /* 比其他按鈕稍寬，更顯眼 */
  position: relative;
}

/* 右上角小光點裝飾，加強視覺引導 */
.gbc-btn-ticket::after {
  content: '';
  position: absolute;
  top: 6px; right: 8px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: rgba(255,255,255,0.7);
}

.gbc-btn-ticket:hover,
.gbc-btn-ticket:focus {
  background: #c44f00;
  border-color: #c44f00;
  color: #fff !important;
  text-decoration: none;
}
