:root {
  color-scheme: light;
  --notice-purple: #311071;
  --notice-muted: #655775;
  --notice-orange: #e77d2a;
  --notice-cream: #fff9ef;
  --notice-lavender: #f0e9f9;
  font-family:
    "PingFang TC", "Noto Sans TC", "Noto Sans CJK TC", "Microsoft JhengHei",
    sans-serif;
  color: var(--notice-purple);
  background: var(--notice-cream);
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
}

* {
  box-sizing: border-box;
}
body {
  margin: 0;
  min-width: 0;
}
p,
h1 {
  margin: 0;
}

.notice-page {
  width: min(100%, 1200px);
  min-height: 100svh;
  margin-inline: auto;
  padding: max(32px, env(safe-area-inset-top))
    max(32px, env(safe-area-inset-right)) max(24px, env(safe-area-inset-bottom))
    max(32px, env(safe-area-inset-left));
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.notice-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 0 4px 20px;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.7;
  letter-spacing: 0.035em;
}
.notice-header p span {
  display: inline-block;
  margin-left: 0.7em;
}
.notice-header-label {
  flex: 0 0 auto;
  color: var(--notice-muted);
  font-weight: 500;
}

.notice-card {
  overflow: clip;
  border: 1px solid #e6dcd8;
  border-radius: 28px;
  background: #fffcf6;
  box-shadow: 0 16px 48px #593a1b0a;
}
.notice-stripe {
  height: 8px;
  background: repeating-linear-gradient(
    125deg,
    var(--notice-orange) 0 14px,
    #ffe3ac 14px 28px,
    #fff9ef 28px 34px
  );
}
.notice-content {
  display: grid;
  grid-template-columns: 1.08fr 1fr;
}
.notice-message {
  align-self: center;
  padding: 38px 44px 42px;
  min-width: 0;
}
.notice-logo {
  display: block;
  width: min(100%, 300px);
  height: auto;
  margin: 0 0 32px -6px;
}
.notice-status {
  width: fit-content;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 14px;
  border: 1px solid #e4d8f3;
  border-radius: 999px;
  background: var(--notice-lavender);
  font-size: 0.875rem;
  line-height: 1.5;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.notice-status > span {
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #b95100;
}
h1 {
  margin-block: 18px 20px;
  font-size: 2.65rem;
  line-height: 1.38;
  font-weight: 900;
  letter-spacing: -0.04em;
  text-wrap: balance;
}
h1 span {
  display: block;
}
.notice-description {
  max-width: 26em;
  color: var(--notice-muted);
  font-size: 1rem;
  line-height: 1.95;
}
.notice-timing {
  margin-top: 12px;
  font-size: 0.9375rem;
  line-height: 1.8;
  font-weight: 700;
}
.notice-refresh {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 48px;
  margin-top: 26px;
  padding: 12px 20px;
  border: 1px solid var(--notice-purple);
  border-radius: 12px;
  background: var(--notice-purple);
  color: white;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.5;
  text-decoration: none;
}
.notice-refresh svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.notice-refresh:hover {
  background: #4d268e;
}
.notice-refresh:active {
  background: #23104a;
}
.notice-refresh:focus-visible {
  outline: 3px solid #b95100;
  outline-offset: 5px;
}

.notice-scene {
  position: relative;
  min-width: 0;
  display: grid;
  align-items: end;
  background: #d9ecf7;
}
.notice-hero {
  display: block;
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  min-height: 590px;
  object-fit: cover;
  object-position: 57% bottom;
}
.notice-scene-caption {
  position: relative;
  grid-area: 1 / 1;
  justify-self: center;
  max-width: calc(100% - 40px);
  margin-bottom: 22px;
  padding: 9px 20px;
  border: 1px solid #fff8;
  border-radius: 999px;
  background: #fff9eff5;
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.6;
  text-align: center;
  letter-spacing: 0.04em;
}

.notice-event {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 28px;
  padding: 24px 36px;
  border-top: 1px solid #e6dcd8;
}
.notice-event-name {
  flex: 1 1 auto;
  font-size: 0.9375rem;
  line-height: 1.65;
  font-weight: 800;
}
.notice-event-name span {
  display: inline-block;
  margin-left: 0.65em;
  color: var(--notice-muted);
  font-weight: 500;
}
.notice-event-detail {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.9375rem;
  line-height: 1.65;
  font-weight: 700;
}
.notice-event-detail svg {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  color: #a74400;
}
.notice-footer {
  padding: 22px 8px 0;
  text-align: center;
  color: var(--notice-muted);
  font-size: 0.8125rem;
  line-height: 1.9;
  overflow-wrap: anywhere;
}
.notice-domain {
  margin-top: 3px;
  font-size: 0.75rem;
  letter-spacing: 0.025em;
}

@media (max-width: 959px) {
  .notice-page {
    max-width: 704px;
    padding-inline: max(24px, env(safe-area-inset-left))
      max(24px, env(safe-area-inset-right));
  }
  .notice-header {
    font-size: 0.8125rem;
  }
  .notice-header-label {
    display: none;
  }
  .notice-content {
    grid-template-columns: minmax(0, 1fr);
  }
  .notice-message {
    padding: 36px 40px;
  }
  .notice-logo {
    width: min(100%, 260px);
    margin-bottom: 28px;
  }
  h1 {
    font-size: 2.375rem;
  }
  .notice-hero {
    min-height: 0;
    height: auto;
    max-height: 390px;
    aspect-ratio: 853 / 650;
    object-position: center bottom;
  }
  .notice-event {
    padding: 24px 32px;
    gap: 14px 24px;
  }
  .notice-event-name {
    flex-basis: 100%;
  }
}

@media (max-width: 479px) {
  .notice-page {
    padding: max(20px, env(safe-area-inset-top))
      max(16px, env(safe-area-inset-right))
      max(20px, env(safe-area-inset-bottom))
      max(16px, env(safe-area-inset-left));
  }
  .notice-header {
    padding: 0 4px 14px;
    font-size: 0.75rem;
    letter-spacing: 0;
  }
  .notice-header p span {
    margin-left: 0.5em;
  }
  .notice-card {
    border-radius: 22px;
  }
  .notice-message {
    padding: 26px 24px 28px;
  }
  .notice-logo {
    width: min(100%, 230px);
    margin-bottom: 24px;
  }
  h1 {
    font-size: 1.875rem;
    margin-block: 16px;
  }
  .notice-status {
    font-size: 0.8125rem;
  }
  .notice-timing {
    font-size: 0.9375rem;
  }
  .notice-refresh {
    margin-top: 22px;
  }
  .notice-hero {
    aspect-ratio: 853 / 730;
  }
  .notice-scene-caption {
    margin-bottom: 16px;
    font-size: 0.8125rem;
  }
  .notice-event {
    padding: 20px 24px;
    gap: 12px;
  }
  .notice-event-detail {
    flex-basis: 100%;
  }
  .notice-footer {
    padding-inline: 0;
  }
}

/* Reflow enlarged text without fixing a card height or clipping the message. */
@media (max-width: 60rem) {
  .notice-content {
    grid-template-columns: minmax(0, 1fr);
  }
  .notice-message {
    width: 100%;
  }
  .notice-hero {
    min-height: 0;
    height: auto;
    max-height: 440px;
    object-position: center bottom;
  }
}

@media print {
  .notice-page {
    max-width: none;
    padding: 0;
  }
  .notice-card {
    box-shadow: none;
  }
  .notice-refresh {
    display: none;
  }
}
