
.announcement-card { --announcement-accent: #2358ad; --announcement-tint: #eff5ff; position: relative; overflow: hidden; border: 1px solid #cedcf1; border-radius: 22px; background: #fff; box-shadow: 0 12px 32px #1238680c; }
.announcement-card.tone-important { --announcement-accent: #8f5400; --announcement-tint: #fff8e8; border-color: #edd49e; }
.announcement-card.tone-success { --announcement-accent: #11684a; --announcement-tint: #ecfaf3; border-color: #bce4d1; }
.announcement-header { display: flex; align-items: center; gap: 18px; padding: 22px 28px; background: var(--announcement-tint); border-bottom: 1px solid #17253a0a; }
.announcement-art { display: grid; width: 64px; height: 64px; flex-shrink: 0; place-items: center; border: 1px solid #fff; border-radius: 18px; background: #ffffffc4; color: var(--announcement-accent); box-shadow: 0 4px 10px #17253a08; }
.announcement-art svg { width: 44px; height: 44px; }
.announcement-heading { min-width: 0; flex: 1; }
.announcement-eyebrow { color: var(--announcement-accent); font-size: 11px; font-weight: 800; letter-spacing: .7px; }
.announcement-heading h2 { margin: 5px 0 0; color: #17253a; font-size: clamp(22px, 2.2vw, 34px); line-height: 1.4; overflow-wrap: anywhere; }
.announcement-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; max-width: 320px; }
.announcement-actions button { padding: 10px 13px; border: 1px solid #17253a20; border-radius: 10px; background: #ffffffb0; color: var(--announcement-accent); font: inherit; font-size: 12px; font-weight: 700; cursor: pointer; }
.announcement-actions button:hover { background: #fff; border-color: var(--announcement-accent); }
.announcement-actions button:focus-visible { outline: 3px solid var(--announcement-accent); outline-offset: 3px; }
.announcement-pause[hidden] { display: none; }
.announcement-viewport { padding: 26px 30px; }
.announcement-track { width: 100%; }
.announcement-text { margin: 0; color: #243753; font-size: clamp(22px, 2vw, 32px); font-weight: 600; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.mode-ticker .announcement-viewport { overflow: hidden; padding: 24px 0; }
.mode-ticker .announcement-track { display: flex; width: max-content; animation: announcementTicker var(--announcement-speed) linear infinite; }
.mode-ticker .announcement-text { flex-shrink: 0; padding: 0 60px 0 30px; white-space: pre; overflow-wrap: normal; }
.mode-rise .announcement-viewport { height: 240px; overflow: hidden; padding: 0 30px; }
.mode-rise .announcement-track { animation: announcementRise var(--announcement-speed) linear infinite; }
.mode-rise .announcement-text { min-height: 240px; padding: 26px 0; }
.motion-paused .announcement-track { animation-play-state: paused; }
.announcement-dialog { width: min(900px, calc(100vw - 30px)); max-height: 85vh; border: 0; border-radius: 24px; padding: 0; color: #17253a; background: #fff; box-shadow: 0 24px 100px #03183255; }
.announcement-dialog::backdrop { background: #061b3bc4; backdrop-filter: blur(5px); }
.announcement-dialog-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 26px 30px; border-bottom: 1px solid #dfe7f1; background: #eff5ff; }
.announcement-dialog h2 { margin: 0; font-size: 28px; line-height: 1.5; overflow-wrap: anywhere; }
.announcement-dialog form { flex-shrink: 0; }
.announcement-dialog button { padding: 9px 13px; border: 1px solid #c8d8ef; border-radius: 10px; background: #fff; color: #174379; font: inherit; cursor: pointer; }
.announcement-dialog-text { padding: 28px 32px; margin: 0; color: #243753; font-size: 24px; line-height: 1.9; white-space: pre-wrap; overflow-wrap: anywhere; }
@keyframes announcementTicker { to { transform: translateX(-50%); } }
@keyframes announcementRise { to { transform: translateY(-50%); } }
@media (max-width: 760px) {
  .announcement-header { gap: 12px; padding: 18px; flex-wrap: wrap; }
  .announcement-art { width: 48px; height: 48px; border-radius: 14px; }
  .announcement-art svg { width: 34px; height: 34px; }
  .announcement-actions { width: 100%; max-width: none; justify-content: flex-start; }
  .announcement-viewport { padding: 20px; }
  .announcement-text { font-size: 20px; }
  .announcement-dialog-header { padding: 20px; }
  .announcement-dialog h2 { font-size: 22px; }
  .announcement-dialog-text { padding: 20px; font-size: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .announcement-track { animation: none !important; transform: none !important; }
  .announcement-card .announcement-viewport { height: auto; padding: 20px 26px; }
  .announcement-card .announcement-track { display: block; width: 100%; }
  .announcement-card .announcement-text { min-height: 0; padding: 0; white-space: pre-wrap; overflow-wrap: anywhere; }
  .announcement-text[aria-hidden="true"], .announcement-pause { display: none; }
}

.announcement-media { position: relative; width: 100%; height: clamp(220px, 35vh, 400px); background: #071628; overflow: hidden; }
.announcement-media iframe { width: 100%; height: 100%; border: 0; pointer-events: none; }
.slideshow-image { display: block; width: 100%; height: 100%; object-fit: contain; }
.slideshow-progress { position: absolute; inset: auto 0 0; height: 4px; background: #8bb7ff; transform-origin: left; }
.media-caption { margin: 0; padding: 14px 18px; color: #506581; font-size: 12px; line-height: 1.7; overflow-wrap: anywhere; white-space: pre-wrap; max-height: 140px; overflow: auto; }
.media-placeholder { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 14px; padding: 24px; color: #c9d7ed; text-align: center; font-size: 17px; background: linear-gradient(145deg, #122d50, #081527); }
.youtube-placeholder > span { display: grid; width: 64px; height: 44px; place-items: center; border-radius: 12px; background: #ec443e; color: #fff; font-size: 28px; }
.youtube-placeholder strong { color: #fff; font-size: 22px; }
.youtube-placeholder small { font-size: 12px; }
.announcement-preview-area .announcement-media { height: 230px; }
@keyframes slideshowTime { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.announcement-media video { display: block; width: 100%; height: 100%; object-fit: contain; background: #07182e; pointer-events: none; }
.website-media { aspect-ratio: auto; height: clamp(260px, 48vh, 620px); }
.website-media iframe { width: 100%; height: 100%; border: 0; pointer-events: none; }
.playlist-screen { min-width: 0; }
.playlist-screen > .announcement-card { border: 0; border-radius: 0; box-shadow: none; }
.playlist-screen > .announcement-card > .announcement-header { display: none; }
.playlist-display-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 12px 18px; color: #456185; background: #edf3fa; font-size: 12px; line-height: 1.6; }
.playlist-now { min-width: 0; overflow-wrap: anywhere; }
.playlist-position { flex: 0 0 auto; font-variant-numeric: tabular-nums; color: #174379; font-weight: 800; }
.playlist-preview-list { display: grid; gap: 12px; margin: 0; padding: 22px 22px 22px 42px; color: #254b7d; font-size: 14px; line-height: 1.6; }

/* RSS cards share the announcement area and keep one consistent layout. */
.rss-news-card{display:flex;flex-direction:column;min-height:0;height:100%;background:#fff;border:1px solid #dce5f1;border-radius:18px;overflow:hidden;color:#17253a;}
.rss-news-photo{position:relative;height:clamp(180px,25vh,320px);flex:0 0 auto;background:#eaf1fc;}
.rss-news-photo img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;background:#eaf1fc;}.rss-news-photo img[hidden]{display:none;}
.rss-photo-placeholder{display:grid;place-items:center;height:100%;padding:24px;text-align:center;font-size:20px;font-weight:800;color:#41679f;background:linear-gradient(135deg,#d9e9ff,#f3f7fd);}
.rss-news-copy{padding:20px 24px;flex:1;min-height:0;overflow:auto;}.rss-news-badge{font-size:11px;letter-spacing:.04em;font-weight:800;color:#216251;}.rss-news-copy h2{font-size:clamp(20px,1.7vw,30px);line-height:1.45;color:#0e3a7c;margin:12px 0;}.rss-news-meta{font-size:13px;line-height:1.6;color:#68778c;}.rss-news-link{display:inline-block;color:#0e3a7c;font-size:14px;margin-top:6px;}
.rss-news-footer{display:flex;justify-content:space-between;align-items:center;padding:12px 20px;background:#f3f7fc;border-top:1px solid #dce5f1;font-size:13px;}.rss-news-footer button{width:34px;height:30px;border:1px solid #cad7e9;border-radius:8px;background:#fff;color:#0e3a7c;font-size:22px;cursor:pointer;}
.rss-content-visible{animation:rss-card-fade .7s ease;}@keyframes rss-card-fade{from{opacity:0;transform:translateY(8px);}to{opacity:1;transform:none;}}
.rss-presets,.rss-filters{border:1px solid #dce5f1;border-radius:12px;padding:16px;margin:18px 0;}.rss-presets legend,.rss-filters legend{font-size:14px;color:#0e3a7c;font-weight:700;}.rss-presets>label{display:flex;align-items:center;gap:8px;margin:10px 0;}.rss-filters>label{margin:10px 0;}.rss-filters>p{font-size:12px;line-height:1.7;color:#68778c;}
.rss-admin-preview{display:flex;align-items:center;gap:14px;padding:14px;margin:10px 0;border:1px solid #dce5f1;border-radius:12px;}.rss-admin-preview img{width:110px;height:75px;object-fit:contain;flex-shrink:0;}.rss-admin-preview a{color:#0e3a7c;font-size:14px;line-height:1.6;}
@media(max-width:760px){.rss-news-photo{height:210px;}.rss-news-copy{padding:16px;}.rss-news-copy h2{font-size:22px;}.rss-news-card{height:auto;min-height:450px;}.rss-admin-preview img{width:75px;height:65px;}}

.knowledge-card{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:16px;min-height:420px;height:100%;box-sizing:border-box;padding:32px 26px;border:1px solid #cbdaf0;border-radius:18px;background:linear-gradient(145deg,#e9f2ff,#fff 65%,#e8f5ef);color:#0e3a7c;text-align:center;}
.knowledge-mark{display:grid;place-items:center;width:78px;height:78px;border-radius:22px;background:#0e3a7c;color:#fff;font-size:38px;font-weight:800;}.knowledge-badge{font-size:11px;font-weight:800;letter-spacing:.03em;color:#216251;}.knowledge-card h2{font-size:clamp(22px,1.9vw,32px);line-height:1.4;margin:0;}.knowledge-body{font-size:clamp(18px,1.5vw,25px);line-height:1.7;margin:0;max-width:700px;}.knowledge-answer{padding:12px 16px;border-radius:12px;background:#dcefe5;color:#216251;font-size:18px;line-height:1.6;margin:0;}.knowledge-answer[hidden]{display:none;}.knowledge-position{font-size:12px;color:#68778c;margin-top:auto;}.knowledge-preview{height:520px;margin:18px 0;}.knowledge-preview[hidden]{display:none;}
@media(max-width:760px){.knowledge-card{padding:24px 18px;}.knowledge-body{font-size:19px;}}

/* Overflowing RSS text scrolls upward automatically without a visible scrollbar. */
.rss-news-copy{scroll-behavior:auto;scrollbar-width:none;overflow-y:auto;overflow-x:hidden;}
.rss-news-copy::-webkit-scrollbar{display:none;}

.playlist-preview-buttons{display:flex;gap:6px;flex-wrap:wrap;padding:10px}.playlist-preview-buttons button{padding:7px 10px;border:1px solid #cbd5e1;border-radius:8px;background:white;cursor:pointer}.playlist-preview-buttons button[aria-pressed="true"]{background:#174b91;color:white}.announcement-media iframe{width:100%;height:100%;min-height:220px;border:0;}

#announcementPreview .playlist-preview-screen .announcement-card{border:0;border-radius:0;box-shadow:none;background:transparent;}#announcementPreview .playlist-preview-screen .announcement-header,#announcementPreview .playlist-preview-screen .media-caption{display:none;}#announcementPreview .playlist-preview-screen .announcement-media{aspect-ratio:16/9;height:auto;min-height:0;margin:0;border:0;border-radius:0;overflow:hidden;}#announcementPreview .playlist-preview-screen iframe{display:block;width:100%;height:100%;min-height:0;aspect-ratio:16/9;}#announcementPreview .playlist-preview-buttons{background:#f3f6fc;}

/* The current news QR stays visible while the article text scrolls. */
.rss-news-footer{gap:16px;flex-shrink:0}
.rss-news-navigation{display:flex;align-items:center;justify-content:space-between;gap:12px;flex:1;min-width:0}
.rss-news-qr{display:flex;flex-direction:column;align-items:center;gap:3px;flex:0 0 auto;width:112px;padding:6px;background:#fff;border:1px solid #dce5f1;border-radius:9px;color:#244e7e;text-decoration:none}
.rss-news-qr[hidden]{display:none!important}
.rss-news-qr img{display:block;width:112px;height:112px;object-fit:contain}
.rss-news-qr span{font-size:10px;line-height:1.4;text-align:center}
@media(max-width:760px){.rss-news-qr{width:88px;padding:4px}.rss-news-qr img{width:88px;height:88px}.rss-news-footer{padding:10px 12px;gap:10px}}

/* Overlay the QR on the news photo without reducing the article viewport. */
.rss-news-photo{position:relative}
.rss-news-qr{position:absolute;top:12px;right:12px;z-index:2;box-sizing:content-box;box-shadow:0 4px 18px rgba(15,41,70,.18)}
.rss-news-photo .rss-news-qr img{position:static!important;display:block!important;inset:auto!important;max-width:none!important;width:112px!important;height:112px!important;object-fit:contain!important;opacity:1!important}
.rss-news-footer{padding:12px 20px}
@media(max-width:760px){.rss-news-qr{top:8px;right:8px}.rss-news-photo .rss-news-qr img{width:88px!important;height:88px!important}.rss-news-footer{padding:10px 12px}}

/* QR beside the article source, below the headline. */
.rss-news-copy .rss-news-qr{position:static;float:right;margin:0 0 10px 14px;box-shadow:none}
.rss-news-copy .rss-news-qr img{position:static;display:block;width:112px;height:112px;object-fit:contain;background:#fff}
@media(max-width:760px){.rss-news-copy .rss-news-qr img{width:88px;height:88px}.rss-news-copy .rss-news-qr{margin-left:10px}}

/* Remove legacy RSS navigation, including cached renderers. */
.rss-news-footer,.rss-news-navigation{display:none!important;height:0!important;padding:0!important;border:0!important}
