/* The server's news pages (ข่าวสาร, src/map/news.js: /news the list, /news/<id> a post): the look of the character
   page (client/profile/profile.css) - Gieno-RO's artwork blurred behind, cream cards with the game's gold edge, the big
   gold "มาเล่นด้วยกัน". Mobile first (iPhone 13: 390 px), one column up to 760 px wide. Fonts of the game only. No script. */

:root {
	--ink: #3d2614; --ink-2: #6b4a2e; --muted: #8a6d55; --cream: #fffaf0; --cream-2: #fff3dc; --line: #ecd3a2;
	--gold: #e0a713; --gold-2: #f2b631; --gold-hi: #ffe48a; --gold-ink: #4a3000; --sky: #3b2346; --link: #b0430a;
	--ui: Tahoma, 'Midgard Thai', 'Kanit', system-ui, sans-serif;
	--head: 'Kanit', Tahoma, 'Midgard Thai', system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html, body { margin: 0; min-height: 100%; }
body.nw { background: var(--sky); color: var(--ink); font: 15px/1.6 var(--ui); overflow-x: hidden; }
.nw-bg { position: fixed; inset: -24px; z-index: -1; background: #3b2346 url('/img/gieno-bg.jpg') 50% 30% / cover no-repeat; filter: blur(5px) saturate(1.1) brightness(0.62); transform: scale(1.04); }
.nw-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(59, 35, 70, 0.15), rgba(40, 20, 50, 0.55) 70%, rgba(30, 14, 40, 0.75)); }

.nw-top { display: flex; justify-content: center; padding: max(14px, env(safe-area-inset-top)) 16px 4px; }
.nw-brand { display: block; line-height: 0; }
.nw-brand img { width: 176px; max-width: 48vw; height: auto; border-radius: 14px; box-shadow: 0 0 0 2px rgba(255, 236, 190, 0.55), 0 6px 16px rgba(0, 0, 0, 0.45); }

.nw-nav { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; padding: 8px 14px 2px; }
.nw-nav a { display: inline-flex; align-items: center; min-height: 38px; padding: 0 14px; border-radius: 19px; border: 1px solid rgba(255, 236, 190, 0.55); background: rgba(30, 16, 40, 0.45);
	color: #fff6e2; font: 500 14px/1 var(--head); text-decoration: none; backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); white-space: nowrap; }
.nw-nav a:hover, .nw-nav a:focus-visible { background: rgba(255, 228, 138, 0.22); outline: none; }
.nw-nav .nw-nav-play { background: linear-gradient(var(--gold-hi), var(--gold-2)); color: var(--gold-ink); border-color: #c98a0e; font-weight: 600; }

.nw-main { width: 100%; max-width: 760px; margin: 0 auto; padding: 10px 14px 18px; display: flex; flex-direction: column; gap: 16px; }
.nw-card { padding: 16px; border-radius: 20px; background: linear-gradient(170deg, var(--cream) 0%, #fff7e6 60%, var(--cream-2) 100%); border: 2px solid var(--line);
	box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.6) inset, 0 18px 40px rgba(20, 8, 30, 0.45); min-width: 0; }
.nw-h1 { margin: 0 0 10px; font: 700 24px/1.25 var(--head); color: var(--ink); }

/* the list */
.nw-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.nw-item a { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 12px; align-items: start; padding: 10px; border-radius: 14px; background: #fff; border: 1px solid var(--line);
	color: inherit; text-decoration: none; box-shadow: 0 2px 0 #f0dcb2; }
.nw-item a:hover, .nw-item a:focus-visible { border-color: var(--gold); outline: none; box-shadow: 0 2px 0 #e6c57f, 0 0 0 2px rgba(224, 167, 19, 0.25); }
.nw-item.nw-pin a { background: linear-gradient(120deg, #fff, #fff6dc); border-color: #e9c472; }
.nw-thumb { display: block; width: 96px; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--cream-2); }
.nw-thumb.nw-noimg { background: #fff3dc url('/img/gieno-logo.png') 50% 50% / 82% auto no-repeat; }
.nw-timg { display: block; width: 100%; height: 100%; object-fit: cover; }
.nw-it { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.nw-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.nw-ititle { font: 600 16px/1.35 var(--head); color: var(--ink); overflow-wrap: anywhere; }
.nw-snip { font-size: 13.5px; line-height: 1.5; color: var(--ink-2); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.nw-empty { margin: 8px 0; color: var(--muted); text-align: center; }

.nw-tag { display: inline-block; padding: 1px 9px; border-radius: 10px; font: 600 12px/1.6 var(--head); color: #fff; background: #7a6a5c; white-space: nowrap; }
.nw-c-update { background: #2e7dd7; }
.nw-c-event { background: #d4498f; }
.nw-c-notice { background: #c98a0e; }
.nw-c-maint { background: #c4452c; }
.nw-pinned { display: inline-block; padding: 1px 8px; border-radius: 10px; font: 600 12px/1.6 var(--head); color: #8a4b00; background: linear-gradient(90deg, #fff1c4, #ffe08a); border: 1px solid #e3b649; white-space: nowrap; }

/* a post */
.nw-back { display: inline-flex; align-items: center; min-height: 36px; margin-bottom: 6px; color: var(--link); font: 500 14px/1 var(--head); text-decoration: none; }
.nw-back:hover, .nw-back:focus-visible { text-decoration: underline; outline: none; }
.nw-ptitle { margin: 6px 0 10px; font: 700 25px/1.3 var(--head); color: var(--ink); overflow-wrap: anywhere; }
.nw-figure { margin: 0 0 12px; border-radius: 14px; overflow: hidden; background: #2b1d33; box-shadow: 0 0 0 2px #f6e2b4, 0 6px 16px rgba(60, 30, 10, 0.25); }
.nw-pimg { display: block; width: 100%; height: auto; max-height: 70vh; object-fit: contain; margin: 0 auto; }
.nw-body { font-size: 15.5px; line-height: 1.75; color: var(--ink); overflow-wrap: anywhere; }
.nw-body p { margin: 0 0 12px; }
.nw-body p:last-child { margin-bottom: 0; }
.nw-body a { color: var(--link); text-decoration: underline; text-underline-offset: 2px; word-break: break-all; }
.nw-share { margin: 14px 0 0; }
.nw-fb { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; border-radius: 20px; background: #1877f2; color: #fff; font: 600 14px/1 var(--head); text-decoration: none; }
.nw-fb:hover, .nw-fb:focus-visible { background: #0e5fd0; outline: none; }

/* not found */
.nw-empty-card { text-align: center; padding: 26px 16px; }
.nw-empty-card h1 { margin: 6px 0 4px; font: 700 22px/1.3 var(--head); }
.nw-empty-card p { margin: 0 0 6px; color: var(--ink-2); }
.nw-q { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto; border-radius: 50%; background: var(--cream-2); border: 2px solid var(--line); font: 700 34px/1 var(--head); color: var(--gold); }

/* มาเล่นด้วยกัน */
.nw-join { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; color: #fff6e2; }
.nw-cta { display: inline-flex; align-items: center; justify-content: center; min-width: 240px; min-height: 54px; padding: 0 26px; border-radius: 28px; text-decoration: none;
	background: linear-gradient(var(--gold-hi), var(--gold-2) 55%, var(--gold)); color: var(--gold-ink); font: 700 19px/1 var(--head); border: 2px solid #fff3c8;
	box-shadow: 0 0 0 2px #c98a0e, 0 8px 22px rgba(0, 0, 0, 0.45); }
.nw-cta:hover, .nw-cta:focus-visible { filter: brightness(1.05); outline: none; }
.nw-join p { margin: 0; font-size: 13.5px; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); }
.nw-foot { text-align: center; padding: 8px 16px max(18px, env(safe-area-inset-bottom)); color: rgba(255, 246, 226, 0.75); font-size: 12px; }

@media (min-width: 600px) {
	.nw-card { padding: 22px 24px; }
	.nw-item a { grid-template-columns: 132px minmax(0, 1fr); gap: 14px; padding: 12px; }
	.nw-thumb { width: 132px; }
	.nw-ptitle { font-size: 30px; }
	.nw-h1 { font-size: 26px; }
}
