
/* ---- Error / info toast notifications ---- */

.toast-container {
	position: fixed;
	top: 16px;
	right: 16px;
	z-index: 10000;
	display: flex;
	flex-direction: column;
	gap: 8px;
	pointer-events: none;
	max-width: min(420px, calc(100vw - 32px));
}

.toast {
	pointer-events: auto;
	display: flex;
	align-items: flex-start;
	gap: 10px;
	padding: 12px 14px;
	border-radius: 12px;
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	box-shadow:
		0 0 0 1px rgba(255, 255, 255, 0.06) inset,
		0 8px 32px rgba(0, 0, 0, 0.45);
	font-size: 0.88rem;
	line-height: 1.4;
	animation: toastIn 0.35s ease;
	transform-origin: top right;
}

.toast.is-exiting {
	animation: toastOut 0.25s ease forwards;
}

/* Severity variants */
.toast--error {
	border: 1px solid rgba(239, 68, 68, 0.45);
	background: rgba(127, 29, 29, 0.72);
	color: rgba(254, 202, 202, 0.95);
}

.toast--warn {
	border: 1px solid rgba(251, 191, 36, 0.45);
	background: rgba(120, 53, 15, 0.72);
	color: rgba(254, 243, 199, 0.95);
}

.toast--info {
	border: 1px solid var(--panel-border);
	background: var(--panel-bg);
	color: rgba(234, 240, 255, 0.92);
}

.toast-icon {
	flex: 0 0 auto;
	font-size: 1.1rem;
	line-height: 1;
	margin-top: 1px;
}

.toast-body {
	flex: 1 1 auto;
	min-width: 0;
}

.toast-title {
	font-weight: 700;
	font-size: 0.85rem;
	letter-spacing: 0.2px;
	margin-bottom: 2px;
}

.toast-msg {
	word-break: break-word;
}

.toast-dismiss {
	flex: 0 0 auto;
	padding: 2px 6px;
	border: none;
	background: rgba(255, 255, 255, 0.08);
	color: inherit;
	border-radius: 6px;
	cursor: pointer;
	font-size: 0.78rem;
	line-height: 1;
	opacity: 0.7;
	transition: opacity 0.15s, background 0.15s;
}

.toast-dismiss:hover {
	opacity: 1;
	background: rgba(255, 255, 255, 0.16);
}

.toast-dismiss:focus-visible {
	outline: 2px solid rgba(255, 255, 255, 0.4);
	outline-offset: 2px;
}

/* Progress bar for auto-dismiss countdown */
.toast-progress {
	position: absolute;
	bottom: 0;
	left: 0;
	height: 3px;
	border-radius: 0 0 12px 12px;
	background: rgba(255, 255, 255, 0.18);
	animation: toastProgress var(--toast-duration, 6s) linear forwards;
}

@keyframes toastIn {
	from { opacity: 0; transform: translateX(20px) scale(0.95); }
	to   { opacity: 1; transform: translateX(0) scale(1); }
}

@keyframes toastOut {
	from { opacity: 1; transform: translateX(0) scale(1); }
	to   { opacity: 0; transform: translateX(20px) scale(0.92); }
}

@keyframes toastProgress {
	from { width: 100%; }
	to   { width: 0%; }
}

/* On mobile, toasts go full-width at the top */
@media (max-width: 768px) {
	.toast-container {
		left: 8px;
		right: 8px;
		max-width: none;
	}
}

/* ==================================================
   Base / Body / Punk palette
   ================================================== */

html,
body {
	height: 100%;
}

body {
	margin: 0;
	font-family: 'Barlow Condensed', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
		Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
	font-weight: 400;
	--accent1: rgba(255, 215, 0, 0.14);
	--accent2: rgba(255, 165, 0, 0.12);
	--bg1: #0a0a0a;
	--bg2: #050505;
	--text: #eaf0ff;
	--panel-bg: rgba(0, 0, 0, 0.62);
	--panel-border: rgba(255, 215, 0, 0.22);
	--panel-inset: rgba(255, 215, 0, 0.12);
	--panel-shadow: rgba(255, 215, 0, 0.16);
	--chip-bg: rgba(255, 255, 255, 0.05);
	--chip-border: rgba(255, 255, 255, 0.10);
	--leaflet-attrib-bg: rgba(0, 0, 0, 0.35);
	--leaflet-attrib-border: rgba(255, 215, 0, 0.16);
	--leaflet-attrib-shadow: rgba(255, 215, 0, 0.10);

	background:
		radial-gradient(900px 500px at 20% 10%, var(--accent1) 0%, rgba(0, 0, 0, 0) 60%),
		radial-gradient(900px 500px at 85% 25%, var(--accent2) 0%, rgba(0, 0, 0, 0) 62%),
		linear-gradient(180deg, var(--bg1) 0%, var(--bg2) 100%);
	background-attachment: fixed;
	color: var(--text);
}

/* ==================================================
   Weather Themes (set by JS via data-theme)
   ================================================== */

body[data-theme="clear-day"] {
	--accent1: rgba(255, 214, 10, 0.38);
	--accent2: rgba(56, 189, 248, 0.22);
	--panel-bg: rgba(19, 14, 0, 0.58);
	--panel-border: rgba(255, 214, 10, 0.42);
	--panel-inset: rgba(255, 214, 10, 0.22);
	--panel-shadow: rgba(255, 214, 10, 0.26);
	--chip-bg: rgba(255, 214, 10, 0.06);
	--chip-border: rgba(255, 214, 10, 0.22);
	--leaflet-attrib-border: rgba(255, 221, 87, 0.18);
}

body[data-theme="clear-day"][data-phase="night"] {
	--accent1: rgba(147, 197, 253, 0.16);
	--accent2: rgba(168, 85, 247, 0.10);
}

body[data-theme="clear-night"] {
	--accent1: rgba(96, 165, 250, 0.26);
	--accent2: rgba(168, 85, 247, 0.24);
	--panel-bg: rgba(6, 10, 24, 0.66);
	--panel-border: rgba(168, 85, 247, 0.34);
	--panel-inset: rgba(96, 165, 250, 0.18);
	--panel-shadow: rgba(168, 85, 247, 0.22);
	--chip-bg: rgba(168, 85, 247, 0.06);
	--chip-border: rgba(168, 85, 247, 0.22);
	--leaflet-attrib-border: rgba(147, 197, 253, 0.16);
}

body[data-theme="clouds"] {
	--accent1: rgba(148, 163, 184, 0.26);
	--accent2: rgba(56, 189, 248, 0.20);
	--panel-bg: rgba(10, 14, 22, 0.64);
	--panel-border: rgba(148, 163, 184, 0.32);
	--panel-inset: rgba(56, 189, 248, 0.16);
	--panel-shadow: rgba(56, 189, 248, 0.16);
	--chip-bg: rgba(148, 163, 184, 0.06);
	--chip-border: rgba(148, 163, 184, 0.18);
	--leaflet-attrib-border: rgba(148, 163, 184, 0.16);
}

body[data-theme="rain"] {
	--accent1: rgba(56, 189, 248, 0.24);
	--accent2: rgba(37, 99, 235, 0.28);
	--panel-bg: rgba(2, 8, 22, 0.70);
	--panel-border: rgba(56, 189, 248, 0.34);
	--panel-inset: rgba(37, 99, 235, 0.18);
	--panel-shadow: rgba(37, 99, 235, 0.22);
	--chip-bg: rgba(37, 99, 235, 0.08);
	--chip-border: rgba(56, 189, 248, 0.22);
	--leaflet-attrib-border: rgba(56, 189, 248, 0.16);
}

body[data-theme="thunder"] {
	--accent1: rgba(168, 85, 247, 0.28);
	--accent2: rgba(99, 102, 241, 0.30);
	--panel-bg: rgba(8, 4, 18, 0.72);
	--panel-border: rgba(168, 85, 247, 0.40);
	--panel-inset: rgba(99, 102, 241, 0.20);
	--panel-shadow: rgba(168, 85, 247, 0.24);
	--chip-bg: rgba(168, 85, 247, 0.08);
	--chip-border: rgba(168, 85, 247, 0.24);
	--leaflet-attrib-border: rgba(168, 85, 247, 0.16);
}

body[data-theme="snow"] {
	--accent1: rgba(226, 232, 240, 0.24);
	--accent2: rgba(125, 211, 252, 0.26);
	--panel-bg: rgba(8, 12, 18, 0.62);
	--panel-border: rgba(226, 232, 240, 0.32);
	--panel-inset: rgba(125, 211, 252, 0.16);
	--panel-shadow: rgba(125, 211, 252, 0.20);
	--chip-bg: rgba(226, 232, 240, 0.06);
	--chip-border: rgba(226, 232, 240, 0.18);
	--leaflet-attrib-border: rgba(226, 232, 240, 0.16);
}

body[data-theme="mist"] {
	--accent1: rgba(20, 184, 166, 0.22);
	--accent2: rgba(148, 163, 184, 0.18);
	--panel-bg: rgba(4, 12, 14, 0.70);
	--panel-border: rgba(20, 184, 166, 0.32);
	--panel-inset: rgba(148, 163, 184, 0.16);
	--panel-shadow: rgba(20, 184, 166, 0.20);
	--chip-bg: rgba(20, 184, 166, 0.06);
	--chip-border: rgba(20, 184, 166, 0.18);
	--leaflet-attrib-border: rgba(20, 184, 166, 0.16);
}

/* Scanline overlay — punk aesthetic */
body::before {
	content: '';
	position: fixed;
	inset: 0;
	pointer-events: none;
	background: repeating-linear-gradient(
		180deg,
		rgba(255, 215, 0, 0.07) 0px,
		rgba(255, 215, 0, 0.07) 1px,
		rgba(0, 0, 0, 0) 4px,
		rgba(0, 0, 0, 0) 10px
	);
	opacity: 0.06;
	z-index: 0;
}

/* ==================================================
   Screen-reader-only utility (for SVG filter, etc.)
   ================================================== */

.sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* ==================================================
   Grain overlay
   ================================================== */

.grain-overlay {
	position: fixed;
	inset: 0;
	z-index: 9998;
	filter: url(#grain);
	opacity: 0.04;
	pointer-events: none;
}

/* ==================================================
   App shell
   ================================================== */

.app-shell {
	padding-top: 52px;
	min-height: 100vh;
	min-height: 100dvh;
	position: relative;
	z-index: 1;
}

main {
	padding: 0;
}

/* ==================================================
   Nav strip — 52px fixed top bar
   ================================================== */

.nav-strip {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 900;
	height: 52px;
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 0 14px;
	background: rgba(10, 10, 10, 0.85);
	backdrop-filter: blur(14px);
	-webkit-backdrop-filter: blur(14px);
	border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.nav-left {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-shrink: 0;
}

.nav-center {
	flex: 1;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 0;
}

.nav-right {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-shrink: 0;
}

/* Brand: logo + wordmark */
.nav-brand {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	text-decoration: none;
	color: var(--text);
}

.nav-mark-wrap {
	position: relative;
	width: 32px;
	height: 32px;
	flex: 0 0 auto;
}

.nav-mark {
	position: relative;
	z-index: 1;
	width: 100%;
	height: 100%;
	display: block;
	padding: 2px;
	border: none;
	background: none;
	filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.9))
		drop-shadow(0 0 4px var(--panel-shadow))
		drop-shadow(0 0 10px var(--panel-shadow));
}

.nav-wordmark {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 1.25rem;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--text);
	white-space: nowrap;
}

/* Nav icon button (hamburger, etc.) */
.nav-icon-btn {
	padding: 7px 10px;
	border-radius: 999px;
	border: 1px solid var(--panel-border);
	background: rgba(255, 255, 255, 0.04);
	color: rgba(234, 240, 255, 0.85);
	cursor: pointer;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: border-color 0.15s, background 0.15s;
}

.nav-icon-btn:hover {
	border-color: color-mix(in srgb, var(--panel-border) 70%, white);
	background: rgba(255, 255, 255, 0.08);
}

.nav-icon-btn.is-hidden {
	display: none !important;
}

/* Mode switch (Live / Past / Chat) */
.mode-switch {
	display: inline-flex;
	align-items: center;
	gap: 0;
	border: 1px solid var(--panel-border);
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.03);
	box-shadow: 0 0 0 1px var(--panel-inset) inset;
	overflow: hidden;
}

.mode-link {
	padding: 7px 14px;
	text-decoration: none;
	color: rgba(234, 240, 255, 0.85);
	font-weight: 650;
	font-size: 0.85rem;
	letter-spacing: 0.3px;
	border-right: 1px solid rgba(255, 255, 255, 0.08);
	white-space: nowrap;
	transition: background 0.15s;
}

.mode-link:last-child {
	border-right: none;
}

.mode-link:hover {
	background: rgba(255, 255, 255, 0.04);
}

.mode-link.is-active,
.mode-link[aria-current="page"] {
	background: var(--accent1);
	color: #eaf0ff;
}

/* Inline units selector */
.units-inline {
	position: relative;
	display: inline-flex;
	align-items: center;
	cursor: pointer;
}

.units-inline select {
	appearance: none;
	-webkit-appearance: none;
	padding: 7px 26px 7px 10px;
	border-radius: 999px;
	border: 1px solid var(--panel-border);
	background: rgba(255, 255, 255, 0.04);
	color: rgba(234, 240, 255, 0.85);
	font-weight: 650;
	font-size: 0.85rem;
	cursor: pointer;
	outline: none;
	font-family: inherit;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none'%3E%3Cpath d='M1 1l4 4 4-4' stroke='rgba(234,240,255,0.6)' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 9px center;
}

.units-inline select option {
	background: #1a1a1a;
	color: #eaf0ff;
	padding: 6px 10px;
}

.units-inline select:hover {
	border-color: color-mix(in srgb, var(--panel-border) 70%, white);
}

.units-inline select:focus-visible {
	box-shadow:
		0 0 0 2px rgba(255, 215, 0, 0.25),
		0 0 20px rgba(255, 215, 0, 0.18);
}

/* User label */
.user-label {
	font-size: 0.82rem;
	color: rgba(234, 240, 255, 0.7);
	white-space: nowrap;
}

.user-label[hidden] {
	display: none !important;
}

/* Icon button (generic — used in nav-right, etc.) */
.icon-btn {
	padding: 7px 10px;
	border-radius: 999px;
	border: 1px solid var(--panel-border);
	background: rgba(255, 255, 255, 0.04);
	color: rgba(234, 240, 255, 0.85);
	cursor: pointer;
	transition: border-color 0.15s, background 0.15s;
}

.icon-btn:hover {
	border-color: color-mix(in srgb, var(--panel-border) 70%, white);
}

/* Legacy brand switch / app mark (keep for header logo) */
.brand-switch {
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

.app-mark-wrap {
	position: relative;
	width: 40px;
	height: 40px;
	flex: 0 0 auto;
	border-radius: 12px;
}

.app-mark-wrap::before {
	content: '';
	position: absolute;
	inset: -3px;
	border-radius: 14px;
	padding: 2px;
	background: conic-gradient(
		transparent 0%,
		var(--panel-shadow) 20%,
		transparent 40%,
		transparent 60%,
		var(--panel-shadow) 80%,
		transparent 100%
	);
	-webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	mask-composite: exclude;
	animation: glowSpin 3s linear infinite;
	z-index: 2;
	transition: filter 0.2s ease;
}

.app-mark-wrap:hover::before {
	filter: brightness(1.5);
}

.app-mark {
	position: relative;
	z-index: 1;
	width: 100%;
	height: 100%;
	display: block;
	padding: 2px;
	border: none;
	background: none;
	filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.9))
		drop-shadow(0 0 4px var(--panel-shadow))
		drop-shadow(0 0 10px var(--panel-shadow));
}

/* ==================================================
   Login screen
   ================================================== */

.login-screen {
	min-height: calc(100vh - 52px);
	min-height: calc(100dvh - 52px);
	display: grid;
	place-items: center;
	padding: 24px 16px;
	position: relative;
	z-index: 1;
}

.login-screen[hidden] {
	display: none !important;
}

.login-card {
	width: min(560px, 100%);
	border: 1px solid var(--panel-border);
	border-radius: 16px;
	background: var(--panel-bg);
	box-shadow:
		0 0 0 1px var(--panel-inset) inset,
		0 0 34px var(--panel-shadow);
	padding: 18px 18px 16px;
}

.login-card h2 {
	margin: 0 0 10px;
	font-family: 'Bebas Neue', sans-serif;
	font-size: 1.4rem;
	letter-spacing: 1px;
}

.google-btn {
	margin-top: 12px;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 10px 14px;
	border-radius: 12px;
	border: 1px solid rgba(255, 255, 255, 0.18);
	background: #ffffff;
	color: #111827;
	font-weight: 600;
	cursor: pointer;
	font-family: inherit;
}

.google-btn:hover {
	filter: brightness(0.97);
}

.g-icon {
	width: 18px;
	height: 18px;
	border-radius: 4px;
	background:
		conic-gradient(from 45deg,
			#4285F4 0 90deg,
			#34A853 90deg 180deg,
			#FBBC05 180deg 270deg,
			#EA4335 270deg 360deg);
}

/* ==================================================
   SEEK MODE — search / landing state
   ================================================== */

.seek-mode {
	max-width: 640px;
	margin: 0 auto;
	padding: 40px 20px 100px;
	display: flex;
	flex-direction: column;
	align-items: center;
	opacity: 1;
	transform: translateY(0);
	transition: opacity 0.35s ease, transform 0.35s ease;
}

.seek-mode[hidden] {
	display: none !important;
}

.seek-mode.is-exiting {
	opacity: 0;
	transform: translateY(-12px);
	pointer-events: none;
}

.seek-hero {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 6px;
	margin-bottom: 24px;
}

/* Mascot logo with glow ring */
.seek-mascot-wrap {
	position: relative;
	width: 120px;
	height: 120px;
	margin: 0 auto;
	border-radius: 30px;
}

/* Outer glow ring */
.seek-mascot-wrap::after {
	content: '';
	position: absolute;
	inset: -18px;
	border-radius: 50%;
	background: conic-gradient(
		transparent 0%,
		var(--panel-shadow) 12%,
		transparent 28%,
		transparent 100%
	);
	animation: glowSpin 2.4s linear infinite;
	filter: blur(10px);
	opacity: 0.7;
}

/* Crisp ring stroke */
.seek-mascot-wrap::before {
	content: '';
	position: absolute;
	inset: -12px;
	border-radius: 50%;
	padding: 3px;
	background: conic-gradient(
		transparent 0%,
		var(--panel-shadow) 15%,
		transparent 30%,
		transparent 100%
	);
	-webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	mask-composite: exclude;
	animation: glowSpin 2.4s linear infinite;
	z-index: 2;
}

.seek-mascot-img {
	position: relative;
	z-index: 1;
	width: 100%;
	height: 100%;
	display: block;
	padding: 8px;
	border: none;
	background: none;
	filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.9))
		drop-shadow(0 0 8px var(--panel-shadow))
		drop-shadow(0 0 20px var(--panel-shadow));
}

/* Search input */
.seek-search-area {
	position: relative;
	width: 100%;
	max-width: 480px;
}

.seek-search-wrap {
	position: relative;
	width: 100%;
}

.seek-search-icon {
	position: absolute;
	left: 14px;
	top: 50%;
	transform: translateY(-50%);
	width: 18px;
	height: 18px;
	color: rgba(234, 240, 255, 0.4);
	pointer-events: none;
}

.seek-input {
	width: 100%;
	padding: 14px 16px 14px 42px;
	border-radius: 14px;
	border: 2px solid rgba(255, 255, 255, 0.08);
	background: rgba(255, 255, 255, 0.04);
	color: var(--text);
	font-size: 1.05rem;
	font-family: inherit;
	outline: none;
	transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.seek-input::placeholder {
	color: rgba(234, 240, 255, 0.3);
}

.seek-input:focus {
	border-color: rgba(255, 215, 0, 0.55);
	box-shadow: 0 0 20px rgba(255, 215, 0, 0.12);
}

/* Search results dropdown */
.seek-results {
	position: absolute;
	top: calc(100% + 4px);
	left: 0;
	right: 0;
	z-index: 100;
	background: rgba(16, 16, 16, 0.95);
	border: 1px solid var(--panel-border);
	border-radius: 12px;
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
	overflow: hidden;
}

.seek-results[hidden] {
	display: none !important;
}

/* Recent lookups section */
.seek-recents-section {
	width: 100%;
	margin-top: 32px;
}

.seek-recents-label {
	font-size: 0.72rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1.2px;
	color: rgba(234, 240, 255, 0.35);
	margin-bottom: 10px;
}

.seek-recents {
	display: flex;
	gap: 10px;
	overflow-x: auto;
	padding-bottom: 6px;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
}

.seek-recents::-webkit-scrollbar {
	height: 4px;
}

.seek-recents::-webkit-scrollbar-track {
	background: transparent;
}

.seek-recents::-webkit-scrollbar-thumb {
	background: rgba(255, 255, 255, 0.1);
	border-radius: 2px;
}

/* Ticket stub card */
.seek-recent-card {
	flex: 0 0 auto;
	min-width: 140px;
	max-width: 180px;
	padding: 10px 12px;
	border: 1px solid var(--chip-border);
	border-radius: 10px;
	background: var(--chip-bg);
	cursor: pointer;
	scroll-snap-align: start;
	transition: border-color 0.15s, background 0.15s;
}

.seek-recent-card:hover {
	border-color: var(--panel-border);
	background: rgba(255, 255, 255, 0.06);
}

.seek-recent-icon {
	width: 28px;
	height: 28px;
	flex: 0 0 auto;
}

.seek-recent-name {
	font-size: 0.82rem;
	font-weight: 600;
	color: rgba(234, 240, 255, 0.92);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.seek-recent-info {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-top: 4px;
}

.seek-recent-temp {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.9rem;
	font-weight: 600;
	color: rgba(234, 240, 255, 0.85);
}

.seek-recent-condition {
	font-size: 0.75rem;
	color: rgba(234, 240, 255, 0.5);
	text-transform: capitalize;
}

.seek-recent-time {
	font-size: 0.7rem;
	color: rgba(234, 240, 255, 0.35);
	margin-top: 4px;
}

/* Search result items */
.seek-result-item {
	padding: 10px 14px;
	cursor: pointer;
	font-size: 0.88rem;
	color: rgba(234, 240, 255, 0.85);
	border-bottom: 1px solid rgba(255, 255, 255, 0.06);
	transition: background 0.12s;
}

.seek-result-item:last-child {
	border-bottom: none;
}

.seek-result-item:hover {
	background: rgba(255, 255, 255, 0.06);
}

.seek-result-empty {
	padding: 14px;
	font-size: 0.85rem;
	color: rgba(234, 240, 255, 0.4);
	text-align: center;
}

.seek-result-divider {
	padding: 6px 14px 4px;
	font-size: 0.68rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1.2px;
	color: rgba(234, 240, 255, 0.3);
	border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.seek-result-searching {
	padding: 10px 14px;
	font-size: 0.82rem;
	color: rgba(234, 240, 255, 0.35);
	text-align: center;
	font-style: italic;
}

/* Nav center place/time labels */
.nav-place {
	font-weight: 600;
	font-size: 0.88rem;
	color: rgba(234, 240, 255, 0.92);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.nav-asof {
	font-size: 0.82rem;
	color: rgba(234, 240, 255, 0.5);
	margin-left: 6px;
	white-space: nowrap;
}

/* Compact map section */
.seek-map-section {
	width: 100%;
	margin-top: 24px;
}

.seek-map-label {
	font-size: 0.72rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1.2px;
	color: rgba(234, 240, 255, 0.35);
	margin-bottom: 10px;
}

.seek-map {
	height: 30vh;
	min-height: 180px;
	max-height: 320px;
	border-radius: 14px;
	border: 1px solid var(--panel-border);
	background: #0b1326;
	box-shadow:
		0 0 0 1px var(--panel-inset) inset,
		0 0 20px var(--accent1);
	overflow: hidden;
}

/* ==================================================
   Torn divider (scissors cut line)
   ================================================== */

.torn-divider {
	position: relative;
	border-top: 2px dashed rgba(255, 255, 255, 0.12);
	margin: 32px 0;
	pointer-events: none;
}

.torn-scissors {
	position: absolute;
	top: -11px;
	left: 50%;
	transform: translateX(-50%);
	font-size: 1rem;
	line-height: 1;
	color: rgba(234, 240, 255, 0.3);
	background: var(--bg1, #0a0a0a);
	padding: 0 8px;
}

/* ==================================================
   REPORT MODE — weather report view
   ================================================== */

.report-mode {
	width: 100%;
	max-width: 860px;
	margin: 0 auto;
	padding: 0 20px 120px;
	opacity: 1;
	transform: translateY(0);
	transition: opacity 0.35s ease, transform 0.35s ease;
}

.report-mode[hidden] {
	display: none !important;
}

.report-mode.is-entering {
	opacity: 0;
	transform: translateY(16px);
}

/* Hero temperature */
.report-hero {
	text-align: center;
	padding: 32px 0 12px;
}

.hero-temp-value {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 12rem;
	line-height: 0.85;
	letter-spacing: -2px;
	color: var(--text);
	margin: 0;
}

.hero-temp-unit {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 3rem;
	color: rgba(234, 240, 255, 0.4);
	vertical-align: super;
	margin-left: 4px;
}

.report-hero-condition {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin-top: 8px;
}

.report-hero-condition img {
	width: 40px;
	height: 40px;
	image-rendering: -webkit-optimize-contrast;
}

.report-hero-condition span {
	font-size: 1.2rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.75);
	text-transform: capitalize;
}

.report-hero-feels {
	margin-top: 4px;
	font-size: 0.92rem;
	color: rgba(234, 240, 255, 0.45);
}

/* Overview */
.report-overview {
	text-align: center;
	max-width: 600px;
	margin: 16px auto 0;
	padding: 0 12px;
	font-style: italic;
	font-size: 0.95rem;
	line-height: 1.55;
	color: rgba(234, 240, 255, 0.5);
}

/* Report sections */
.report-section {
	margin-top: 32px;
	padding: 0;
}

.report-section-title {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 1.6rem;
	text-transform: uppercase;
	letter-spacing: 2px;
	color: rgba(234, 240, 255, 0.6);
	margin: 0 0 12px;
}

/* Report metrics — reuse tiered layout */
.report-metrics {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

/* Report error banner */
.report-error {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 12px;
	margin-bottom: 8px;
	border-radius: 8px;
	border: 1px solid rgba(239, 68, 68, 0.45);
	background: rgba(127, 29, 29, 0.72);
	color: rgba(254, 202, 202, 0.95);
	font-size: 0.85rem;
	line-height: 1.4;
}

.report-error[hidden] {
	display: none;
}

.report-error-icon {
	flex: 0 0 auto;
	font-size: 1rem;
}

.report-error-msg {
	flex: 1 1 auto;
	min-width: 0;
	word-break: break-word;
}

.report-error-retry {
	flex: 0 0 auto;
	padding: 3px 10px;
	border-radius: 6px;
	border: 1px solid rgba(239, 68, 68, 0.5);
	background: rgba(239, 68, 68, 0.2);
	color: rgba(254, 202, 202, 0.95);
	font-size: 0.78rem;
	font-weight: 600;
	cursor: pointer;
	font-family: inherit;
	transition: background 0.15s;
}

.report-error-retry:hover {
	background: rgba(239, 68, 68, 0.35);
}

.report-error-dismiss {
	flex: 0 0 auto;
	background: none;
	border: none;
	color: rgba(254, 202, 202, 0.7);
	font-size: 1rem;
	cursor: pointer;
	padding: 0 2px;
	line-height: 1;
}

.report-error-dismiss:hover {
	color: rgba(254, 202, 202, 1);
}

/* Report debug section */
.report-debug-section {
	margin-top: 24px;
}

/* Report footer spacer */
.report-footer-spacer {
	height: 80px;
}

/* ==================================================
   Alerts banner — concert flyer aesthetic
   ================================================== */

.alerts-banner {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-top: 24px;
}

.alerts-banner[hidden] {
	display: none !important;
}

.alert-card {
	--rot: 0deg;
	border: 2px solid rgba(251, 146, 60, 0.55);
	border-radius: 10px;
	background: rgba(127, 29, 29, 0.55);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	box-shadow:
		0 0 0 1px rgba(251, 146, 60, 0.12) inset,
		0 0 18px rgba(251, 146, 60, 0.14);
	padding: 12px 14px;
	outline: 2px dashed rgba(251, 146, 60, 0.25);
	outline-offset: 3px;
	transform: rotate(var(--rot));
	animation: alertSlideIn 0.35s ease;
}

@keyframes alertSlideIn {
	from { opacity: 0; transform: rotate(var(--rot, 0deg)) translateY(8px); }
	to   { opacity: 1; transform: rotate(var(--rot, 0deg)) translateY(0); }
}

.alert-head {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 8px;
	cursor: pointer;
}

.alert-title {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 1.1rem;
	letter-spacing: 0.5px;
	color: rgba(253, 186, 116, 1);
	font-weight: 700;
}

.alert-chevron {
	flex: 0 0 auto;
	margin-left: auto;
	width: 18px;
	height: 18px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: transform 0.25s ease;
}

.alert-chevron::before {
	content: '';
	display: block;
	width: 8px;
	height: 8px;
	border-right: 2px solid rgba(253, 186, 116, 0.8);
	border-bottom: 2px solid rgba(253, 186, 116, 0.8);
	transform: rotate(45deg);
	transition: transform 0.25s ease;
}

.alert-card.is-collapsed .alert-chevron::before {
	transform: rotate(-45deg);
}

.alert-card.is-collapsed .alert-body {
	display: none;
}

.alert-body {
	margin-top: 6px;
	font-size: 0.85rem;
	color: rgba(234, 240, 255, 0.82);
	white-space: pre-line;
	line-height: 1.45;
	animation: alertBodyIn 0.25s ease;
}

@keyframes alertBodyIn {
	from { opacity: 0; max-height: 0; }
	to   { opacity: 1; max-height: 500px; }
}

.alert-dismiss {
	flex: 0 0 auto;
	padding: 2px 6px;
	border: none;
	background: rgba(255, 255, 255, 0.08);
	color: rgba(253, 186, 116, 0.9);
	border-radius: 6px;
	cursor: pointer;
	font-size: 0.8rem;
	line-height: 1;
}

.alert-dismiss:hover {
	background: rgba(255, 255, 255, 0.16);
}

/* ==================================================
   Metric cards & tiered layout
   ================================================== */

.metric-card {
	border: 1px solid var(--chip-border);
	background: var(--chip-bg);
	border-radius: 12px;
	padding: 0.55rem 0.6rem;
	min-height: 86px;
}

.metric-card-wide {
	min-width: 160px;
	grid-column: span 1;
}

.metric-k {
	font-size: 0.72rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: rgba(234, 240, 255, 0.55);
}

.metric-v {
	margin-top: 0.25rem;
	font-family: 'JetBrains Mono', monospace;
	font-size: 1.2rem;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	color: rgba(234, 240, 255, 0.95);
}

/* Tiered metric layout */
.tiered-metrics {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.metric-tier--primary {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 8px;
}

.metric-tier--primary .metric-card {
	min-height: auto;
}

.metric-tier1 {
	border-color: var(--panel-border);
	background: rgba(255, 255, 255, 0.04);
}

.metric-tier1 .metric-v {
	font-size: 1.4rem;
	font-weight: 800;
}

.metric-tier--secondary {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 8px;
}

.metric-tier--secondary .metric-card {
	min-height: 72px;
}

.metric-tier--tertiary {
	border: 1px solid var(--chip-border);
	border-radius: 10px;
	background: rgba(0, 0, 0, 0.12);
}

.tier3-toggle {
	font-size: 0.78rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: rgba(234, 240, 255, 0.45);
	cursor: pointer;
	padding: 8px 12px;
	list-style: none;
	user-select: none;
}

.tier3-toggle::-webkit-details-marker {
	display: none;
}

.tier3-toggle::before {
	content: '\25B8';
	display: inline-block;
	margin-right: 6px;
	transition: transform 0.2s ease;
}

details[open] > .tier3-toggle::before {
	transform: rotate(90deg);
}

.tier3-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 6px;
	padding: 0 8px 8px;
}

.metric-tier3 {
	min-height: 56px;
	padding: 0.4rem 0.5rem;
	border: 1px solid rgba(255, 255, 255, 0.04);
	background: rgba(255, 255, 255, 0.02);
}

.metric-tier3 .metric-v {
	font-size: 0.95rem;
	font-weight: 600;
}

.metric-icon {
	display: inline-flex;
	align-items: center;
	vertical-align: middle;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
}

.metric-icon svg {
	width: 14px;
	height: 14px;
	stroke: currentColor;
	fill: none;
	stroke-width: 2;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* Color-coded cache cards */
.metric-card.cache-hit {
	border-color: rgba(52, 211, 153, 0.35);
	background: rgba(52, 211, 153, 0.06);
}

.metric-card.cache-miss {
	border-color: rgba(251, 146, 60, 0.35);
	background: rgba(251, 146, 60, 0.06);
}

@media (max-width: 768px) {
	.metric-tier--primary {
		grid-template-columns: 1fr 1fr;
	}
	.metric-tier--secondary,
	.tier3-grid {
		grid-template-columns: 1fr 1fr;
	}
}

@media (max-width: 420px) {
	.metric-tier--primary,
	.metric-tier--secondary,
	.tier3-grid {
		grid-template-columns: 1fr;
	}
}

/* Feels-like delta badges */
.feels-delta {
	display: inline-block;
	font-size: 0.72rem;
	font-weight: 700;
	padding: 1px 5px;
	border-radius: 4px;
	margin-left: 4px;
	vertical-align: middle;
}

.feels-warmer {
	color: rgba(239, 68, 68, 0.95);
	background: rgba(239, 68, 68, 0.15);
}

.feels-cooler {
	color: rgba(96, 165, 250, 0.95);
	background: rgba(96, 165, 250, 0.15);
}

/* ==================================================
   Debug / cache toggle & panel
   ================================================== */

.debug-toggle {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	border-radius: 999px;
	border: 1px solid rgba(255, 255, 255, 0.08);
	background: rgba(255, 255, 255, 0.03);
	color: rgba(234, 240, 255, 0.35);
	cursor: pointer;
	transition: color 0.15s, border-color 0.15s;
}

.debug-toggle:hover {
	color: rgba(234, 240, 255, 0.7);
	border-color: rgba(255, 255, 255, 0.15);
}

.debug-toggle-icon {
	display: inline-flex;
	align-items: center;
}

.debug-toggle-icon svg {
	width: 14px;
	height: 14px;
}

.debug-panel {
	margin-top: 8px;
	padding: 10px;
	border: 1px solid rgba(255, 255, 255, 0.06);
	border-radius: 8px;
	background: rgba(0, 0, 0, 0.2);
}

.debug-panel[hidden] {
	display: none !important;
}

.debug-panel-title {
	font-size: 0.7rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.8px;
	color: rgba(234, 240, 255, 0.35);
	margin-bottom: 8px;
}

.debug-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
	gap: 6px;
}

.debug-grid .metric-card {
	min-height: 56px;
	padding: 6px 8px;
	border-color: rgba(255, 255, 255, 0.04);
	background: rgba(255, 255, 255, 0.02);
}

.debug-grid .metric-v {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.9rem;
	font-weight: 600;
}

/* ==================================================
   Wind compass
   ================================================== */

.compass-wrap {
	display: inline-flex;
	align-items: center;
	vertical-align: middle;
}

.compass-svg {
	flex: 0 0 auto;
}

.compass-label {
	display: block;
	margin-top: 4px;
	font-size: 0.82rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.85);
}

/* ==================================================
   Hourly panel & sparkline
   ================================================== */

.hourly-panel {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.hourly {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: minmax(92px, 1fr);
	gap: 0.5rem;
	overflow-x: auto;
	padding-bottom: 0.25rem;
	scroll-snap-type: x mandatory;
}

.hour-card {
	border: 1px solid var(--chip-border);
	background: var(--chip-bg);
	border-radius: 12px;
	padding: 0.5rem;
	min-height: 92px;
	scroll-snap-align: start;
}

.hour-time {
	font-size: 0.85rem;
	color: rgba(234, 240, 255, 0.8);
}

.hour-temp {
	font-family: 'JetBrains Mono', monospace;
	font-size: 1.1rem;
	margin-top: 0.25rem;
}

.hour-pop {
	font-size: 0.85rem;
	color: rgba(234, 240, 255, 0.8);
	margin-top: 0.25rem;
}

/* Sparkline */
.sparkline-container {
	flex-shrink: 0;
	min-width: 0;
}

.sparkline-wrap {
	width: 100%;
	position: relative;
}

.sparkline-svg {
	width: 100%;
	height: 80px;
	display: block;
}

.hourly-show-toggle {
	flex: 0 0 auto;
	align-self: center;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 80px;
	min-height: 70px;
	padding: 8px 14px;
	border-radius: 12px;
	border: 1px dashed var(--chip-border);
	background: rgba(255, 255, 255, 0.02);
	color: rgba(234, 240, 255, 0.55);
	font-size: 0.78rem;
	font-weight: 600;
	font-family: inherit;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
	scroll-snap-align: start;
}

.hourly-show-toggle:hover {
	background: rgba(255, 255, 255, 0.06);
	color: rgba(234, 240, 255, 0.8);
}

.sparkline-labels {
	position: relative;
	height: 16px;
	font-size: 0.72rem;
	color: rgba(234, 240, 255, 0.65);
	margin-top: 2px;
}

.spark-time-label {
	position: absolute;
	transform: translateX(-50%);
	white-space: nowrap;
}

.spark-temp-label {
	position: absolute;
	transform: translateX(-50%);
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.72rem;
	font-weight: 600;
	pointer-events: none;
	z-index: 2;
	background: rgba(0, 0, 0, 0.55);
	padding: 1px 5px;
	border-radius: 4px;
	line-height: 1.4;
}

.spark-temp-max {
	color: rgba(252, 100, 100, 1);
	top: -2px;
	border: 1px solid rgba(239, 68, 68, 0.3);
}

.spark-temp-min {
	color: rgba(120, 180, 255, 1);
	bottom: 20px;
	border: 1px solid rgba(96, 165, 250, 0.3);
}

/* Sparkline hover tooltip */
.spark-hit {
	cursor: crosshair;
}

.spark-tooltip {
	position: absolute;
	top: -6px;
	transform: translateX(-50%);
	padding: 3px 8px;
	border-radius: 6px;
	border: 1px solid var(--panel-border);
	background: var(--panel-bg);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.72rem;
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	color: rgba(250, 204, 21, 0.95);
	white-space: nowrap;
	pointer-events: none;
	z-index: 10;
}

.spark-tooltip[hidden] {
	display: none;
}

.spark-window {
	fill: rgba(250, 204, 21, 0.12);
	stroke: rgba(250, 204, 21, 0.35);
	stroke-width: 1;
	pointer-events: none;
	transition: x 0.08s linear, width 0.08s linear;
}

/* ==================================================
   Sunrise / sunset arc
   ================================================== */

.sun-arc-wrap {
	display: flex;
	justify-content: center;
	margin-top: 2px;
}

.sun-arc-svg {
	display: block;
}

.metric-card-wide .metric-v {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 2px;
}

.metric-card-wide .metric-v .compass-wrap {
	margin-bottom: 2px;
}

/* ==================================================
   Daily list / drilldown
   ================================================== */

.daily-list {
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.daily-row {
	display: grid;
	grid-template-columns: 52px 32px 48px 1fr 48px 42px;
	align-items: center;
	gap: 8px;
	padding: 8px 10px;
	border-radius: 8px;
	cursor: pointer;
	transition: background 0.15s ease;
}

.daily-row:hover {
	background: rgba(255, 255, 255, 0.05);
}

.daily-row-day {
	font-size: 0.88rem;
	font-weight: 600;
	color: rgba(234, 240, 255, 0.9);
	white-space: nowrap;
}

.daily-row-icon {
	width: 28px;
	height: 28px;
	image-rendering: -webkit-optimize-contrast;
}

.daily-row-lo {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.88rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.5);
	text-align: right;
	font-variant-numeric: tabular-nums;
}

.daily-row-bar {
	position: relative;
	width: 100%;
	height: 5px;
	border-radius: 3px;
	background: rgba(255, 255, 255, 0.08);
	overflow: hidden;
}

.daily-row-hi {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.88rem;
	font-weight: 700;
	color: rgba(234, 240, 255, 0.95);
	font-variant-numeric: tabular-nums;
}

.daily-row-pop {
	font-size: 0.75rem;
	font-weight: 500;
	color: rgba(96, 165, 250, 0.75);
	display: inline-flex;
	align-items: center;
	gap: 2px;
	min-width: 0;
}

.daily-row-pop svg {
	width: 12px;
	height: 12px;
	stroke: rgba(96, 165, 250, 0.75);
	fill: none;
	flex-shrink: 0;
}

.temp-bar-wrap {
	position: relative;
	width: 100%;
	height: 5px;
	border-radius: 3px;
	background: rgba(255, 255, 255, 0.08);
	margin: 4px 0 2px;
	overflow: hidden;
}

.temp-bar {
	position: absolute;
	top: 0;
	height: 100%;
	border-radius: 3px;
	background: linear-gradient(90deg,
		rgba(96, 165, 250, 0.85),
		rgba(250, 204, 21, 0.85),
		rgba(239, 68, 68, 0.85));
	transition: left 0.3s ease, width 0.3s ease;
}

.wx-icon {
	width: 34px;
	height: 34px;
	image-rendering: -webkit-optimize-contrast;
}

.daily {
	display: flex;
	flex-direction: column;
	gap: 0.35rem;
}

.day-row {
	display: grid;
	grid-template-columns: 70px 36px 1fr auto;
	align-items: center;
	gap: 0.5rem;
	padding: 0.4rem 0.35rem;
	border-radius: 10px;
	border: 1px solid rgba(255, 255, 255, 0.08);
	background: rgba(255, 255, 255, 0.02);
}

.day-name {
	font-size: 0.9rem;
	color: rgba(234, 240, 255, 0.9);
}

.day-desc {
	font-size: 0.9rem;
	color: rgba(234, 240, 255, 0.9);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.day-temps {
	font-variant-numeric: tabular-nums;
	color: rgba(234, 240, 255, 0.9);
}

/* Daily drill-down detail view */
.daily-panel {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	overflow: hidden;
}

/* Expanded row highlight */
.daily-row.is-expanded {
	background: rgba(255, 215, 0, 0.08);
	border-color: var(--panel-border);
}

/* Inline detail accordion (inserted after selected daily-row) */
.daily-detail {
	overflow: hidden;
	transition: max-height 0.3s ease, opacity 0.25s ease;
	padding: 0 10px;
	border-left: 2px solid var(--panel-border);
	margin-left: 14px;
	margin-bottom: 4px;
}

.daily-detail .tiered-metrics {
	padding: 12px 0 8px;
}

.daily-detail .metric-tier--primary {
	grid-template-columns: repeat(4, 1fr);
}

.daily-detail-summary {
	font-size: 0.85rem;
	font-style: italic;
	color: rgba(234, 240, 255, 0.55);
	padding: 10px 0 0;
	line-height: 1.4;
}

@media (max-width: 768px) {
	.daily-detail .metric-tier--primary {
		grid-template-columns: repeat(2, 1fr);
	}

	.daily-detail {
		margin-left: 8px;
	}
}

@media (max-width: 480px) {
	.daily-detail .metric-tier--primary {
		grid-template-columns: 1fr 1fr;
	}
}


/* Legacy app-header (hidden) */
.app-header { display: none; }

.hero-condition {
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

.hero-condition-text {
	font-size: 1.1rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.7);
	text-transform: capitalize;
}

.hero-wx-icon {
	width: 36px;
	height: 36px;
	vertical-align: middle;
	image-rendering: -webkit-optimize-contrast;
}

/* Misc: muted, kv tables, code blocks */
.muted {
	color: rgba(234, 240, 255, 0.75);
	font-size: 0.95rem;
}

.kv {
	width: 100%;
	border-collapse: collapse;
}

.kv td {
	padding: 6px 4px;
	vertical-align: top;
	border-bottom: 1px solid rgba(255, 255, 255, 0.10);
}

.kv td:first-child {
	width: 45%;
	color: rgba(234, 240, 255, 0.9);
	font-weight: 600;
}

details > summary {
	cursor: pointer;
}

.forecast h3 {
	margin: 0.75rem 0 0.5rem;
	font-size: 0.95rem;
}

.code {
	white-space: pre-wrap;
	word-break: break-word;
	font-size: 12px;
	margin: 10px 0 0;
}

.card {
	border: 1px solid var(--panel-border);
	border-radius: 10px;
	padding: 10px;
	margin-top: 10px;
	background: rgba(0, 0, 0, 0.22);
	box-shadow: 0 0 18px var(--panel-shadow);
}

/* ==================================================
   Map styles (compact seek-map + legacy #map)
   ================================================== */

#map {
	height: 30vh;
	min-height: 180px;
	border: 1px solid var(--panel-border);
	border-radius: 14px;
	background: #0b1326;
	box-shadow:
		0 0 0 1px var(--panel-inset) inset,
		0 0 20px var(--accent1);
}

/* Leaflet tweaks for dark UI */
.leaflet-control-zoom {
	position: absolute !important;
	right: 12px !important;
	bottom: 12px !important;
	left: auto !important;
	top: auto !important;
	margin: 0 !important;
}

.leaflet-top.leaflet-left .leaflet-control-zoom {
	position: absolute !important;
}

.leaflet-control-attribution {
	background: var(--leaflet-attrib-bg) !important;
	color: rgba(234, 240, 255, 0.7) !important;
	border: 1px solid var(--leaflet-attrib-border) !important;
	border-radius: 10px;
	box-shadow: 0 0 14px var(--leaflet-attrib-shadow);
}

.leaflet-control-attribution a {
	color: rgba(147, 197, 253, 0.95) !important;
}

/* Marker bounce */
@keyframes markerBounce {
	0%   { transform: translateY(-40px); opacity: 0; }
	40%  { transform: translateY(0); opacity: 1; }
	55%  { transform: translateY(-12px); }
	70%  { transform: translateY(0); }
	82%  { transform: translateY(-4px); }
	100% { transform: translateY(0); }
}

.marker-bounce {
	animation: markerBounce 0.6s ease-out;
}

/* Coord tooltip on map hover */
.coord-tooltip {
	position: absolute;
	bottom: 8px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 500;
	padding: 4px 10px;
	border-radius: 999px;
	border: 1px solid var(--panel-border);
	background: var(--panel-bg);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.78rem;
	font-variant-numeric: tabular-nums;
	color: rgba(234, 240, 255, 0.7);
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.15s ease;
	white-space: nowrap;
}

.coord-tooltip.is-visible {
	opacity: 1;
}

/* ==================================================
   Loading overlay
   ================================================== */

.loading-overlay {
	position: fixed;
	inset: 0;
	z-index: 9999;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(10, 10, 10, 0.75);
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
	transition: opacity 0.3s ease;
}

.loading-overlay.is-hidden {
	opacity: 0;
	pointer-events: none;
}

/* Subtle variant for subsequent fetches */
.loading-overlay.is-subtle {
	background: rgba(10, 10, 10, 0.25);
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
}

.loading-overlay.is-subtle .loading-card {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 16px;
	border-radius: 12px;
	box-shadow:
		0 0 0 1px var(--panel-inset) inset,
		0 0 20px var(--panel-shadow);
}

.loading-overlay.is-subtle .loading-logo-wrap {
	width: 30px;
	height: 30px;
	margin: 0;
	border-radius: 10px;
}

.loading-overlay.is-subtle .loading-logo-wrap::after {
	inset: -4px;
	border-radius: 14px;
	filter: blur(3px);
	animation-duration: 1.2s;
}

.loading-overlay.is-subtle .loading-logo-wrap::before {
	inset: -2px;
	border-radius: 12px;
	padding: 1.5px;
	animation-duration: 1.2s;
}

.loading-overlay.is-subtle .loading-msg {
	font-size: 0.8rem;
}

.loading-overlay.is-subtle .loading-icon {
	padding: 2px;
	animation: none;
	filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.8))
		drop-shadow(0 0 3px var(--panel-shadow));
}

.loading-card {
	text-align: center;
	padding: 28px 36px;
	border: 1px solid var(--panel-border);
	border-radius: 16px;
	background: var(--panel-bg);
	box-shadow:
		0 0 0 1px var(--panel-inset) inset,
		0 0 40px var(--panel-shadow);
}

.loading-logo-wrap {
	position: relative;
	width: 72px;
	height: 72px;
	margin: 0 auto 12px;
	border-radius: 20px;
}

/* Outer glow */
.loading-logo-wrap::after {
	content: '';
	position: absolute;
	inset: -14px;
	border-radius: 50%;
	background: conic-gradient(
		transparent 0%,
		var(--panel-shadow) 12%,
		transparent 28%,
		transparent 100%
	);
	animation: glowSpin 1.8s linear infinite;
	filter: blur(8px);
	opacity: 0.9;
}

/* Crisp ring stroke */
.loading-logo-wrap::before {
	content: '';
	position: absolute;
	inset: -10px;
	border-radius: 50%;
	padding: 2.5px;
	background: conic-gradient(
		transparent 0%,
		var(--panel-shadow) 15%,
		transparent 30%,
		transparent 100%
	);
	-webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
	mask-composite: exclude;
	animation: glowSpin 1.8s linear infinite;
	z-index: 2;
}

.loading-icon {
	position: relative;
	z-index: 1;
	width: 100%;
	height: 100%;
	display: block;
	padding: 6px;
	border: none;
	background: none;
	filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.9))
		drop-shadow(0 0 5px var(--panel-shadow))
		drop-shadow(0 0 14px var(--panel-shadow));
	animation: none;
}

@keyframes glowSpin {
	from { transform: rotate(0deg); }
	to   { transform: rotate(360deg); }
}

.loading-msg {
	font-size: 0.95rem;
	color: rgba(234, 240, 255, 0.88);
	letter-spacing: 0.2px;
}

/* ==================================================
   Skeleton loading cards
   ================================================== */

.skeleton-card {
	border: 1px solid var(--chip-border);
	background: var(--chip-bg);
	border-radius: 12px;
	padding: 0.55rem 0.6rem;
	min-height: 86px;
	display: flex;
	flex-direction: column;
	gap: 10px;
	justify-content: center;
}

.skeleton-bar {
	border-radius: 4px;
	background: linear-gradient(90deg,
		rgba(255, 255, 255, 0.04) 25%,
		rgba(255, 255, 255, 0.10) 50%,
		rgba(255, 255, 255, 0.04) 75%);
	background-size: 200% 100%;
	animation: shimmer 1.5s ease-in-out infinite;
}

.skeleton-bar-sm {
	width: 45%;
	height: 10px;
}

.skeleton-bar-lg {
	width: 75%;
	height: 16px;
}

@keyframes shimmer {
	0%   { background-position: 200% 0; }
	100% { background-position: -200% 0; }
}

/* ==================================================
   History page — card grid + detail panel
   ================================================== */

.history-page {
	max-width: 100%;
	margin: 0 auto;
	padding-left: 0;
	padding-right: 0;
	padding-bottom: 0;
}

.history-page .corner-ui {
	position: relative;
	top: auto;
	left: auto;
	right: auto;
	padding: 10px 16px;
	margin-bottom: 0;
}

/* Centered content container (matches .report-mode max-width) */
.history-content {
	width: 100%;
	max-width: 860px;
	margin: 0 auto;
	padding: 40px 20px 120px;
}

/* ---- Card grid ---- */

.history-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: 12px;
}

.history-grid[hidden] {
	display: none !important;
}

.history-card {
	border: 1px solid var(--chip-border);
	background: var(--chip-bg);
	backdrop-filter: blur(8px);
	-webkit-backdrop-filter: blur(8px);
	border-radius: 12px;
	padding: 14px 14px 12px;
	cursor: pointer;
	transition: border-color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.history-card:hover {
	background: rgba(255, 255, 255, 0.06);
	transform: translateY(-2px);
}

.history-card:focus-visible {
	outline: 2px solid var(--accent1);
	outline-offset: 2px;
}

.history-card.is-selected {
	border-color: var(--accent1);
	background: rgba(255, 255, 255, 0.06);
	box-shadow: 0 0 12px rgba(var(--accent1-rgb, 99, 102, 241), 0.15);
}

.history-card-header {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-bottom: 6px;
}

.history-card-icon {
	width: 40px;
	height: 40px;
	image-rendering: -webkit-optimize-contrast;
	flex-shrink: 0;
}

.history-card-temp {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 2.2rem;
	line-height: 1;
	letter-spacing: -0.5px;
	color: var(--text);
}

.history-card-condition {
	font-size: 0.88rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.75);
	text-transform: capitalize;
	margin-bottom: 4px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.history-card-location {
	font-size: 0.78rem;
	color: rgba(234, 240, 255, 0.55);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.history-card-time {
	font-size: 0.72rem;
	color: rgba(234, 240, 255, 0.4);
	margin-top: 2px;
}

/* ---- Empty state ---- */

.history-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 10px;
	padding: 40px 20px;
	text-align: center;
	border: 1px solid var(--chip-border);
	border-radius: 12px;
	background: rgba(0, 0, 0, 0.12);
}

.history-empty[hidden] {
	display: none !important;
}

.empty-icon {
	width: 56px;
	height: 56px;
	padding: 4px;
	background: none;
	border: none;
	filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.8))
		drop-shadow(0 0 4px var(--panel-shadow))
		drop-shadow(0 0 10px var(--panel-shadow));
	opacity: 0.8;
}

.empty-title {
	font-family: 'Bebas Neue', sans-serif;
	font-weight: 700;
	font-size: 1.2rem;
	letter-spacing: 0.5px;
}

.history-empty a {
	color: rgba(255, 215, 0, 0.9);
}

/* ---- Pagination ---- */

.history-pagination {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 16px;
	margin-top: 20px;
	padding: 8px 0;
}

.history-pagination[hidden] {
	display: none !important;
}

.history-page-btn {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	padding: 8px 16px;
	border: 1px solid var(--chip-border);
	border-radius: 8px;
	background: var(--chip-bg);
	color: rgba(234, 240, 255, 0.85);
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.8rem;
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	cursor: pointer;
	transition: background 0.2s ease, border-color 0.2s ease;
}

.history-page-btn:hover:not(:disabled) {
	background: rgba(255, 255, 255, 0.06);
	border-color: var(--panel-border);
}

.history-page-btn:disabled {
	opacity: 0.3;
	cursor: not-allowed;
}

.history-page-info {
	font-family: 'JetBrains Mono', monospace;
	font-size: 0.78rem;
	color: rgba(234, 240, 255, 0.5);
	letter-spacing: 0.5px;
}

/* ---- Detail panel ---- */

.history-detail {
	margin-top: 24px;
	border: 1px solid var(--chip-border);
	background: rgba(0, 0, 0, 0.12);
	border-radius: 14px;
	padding: 24px 20px;
	animation: historyDetailIn 0.3s ease;
}

.history-detail[hidden] {
	display: none !important;
}

@keyframes historyDetailIn {
	from { opacity: 0; transform: translateY(8px); }
	to   { opacity: 1; transform: translateY(0); }
}

/* Detail hero — matches Live page report-hero */
.history-detail-hero {
	text-align: center;
	padding: 0 0 8px;
}

.history-detail-temp {
	display: flex;
	align-items: baseline;
	justify-content: center;
}

.history-detail-temp-value {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 8rem;
	line-height: 0.85;
	letter-spacing: -2px;
	color: var(--text);
}

.history-detail-temp-unit {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 2rem;
	color: rgba(234, 240, 255, 0.4);
	margin-left: 4px;
}

.history-detail-condition {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	margin-top: 8px;
}

.history-detail-wx-icon {
	width: 40px;
	height: 40px;
	image-rendering: -webkit-optimize-contrast;
}

.history-detail-condition-text {
	font-size: 1.2rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.75);
	text-transform: capitalize;
}

.history-detail-feels {
	margin-top: 4px;
	font-size: 0.92rem;
	color: rgba(234, 240, 255, 0.45);
}

.history-detail-location {
	margin-top: 8px;
	font-size: 0.85rem;
	color: rgba(234, 240, 255, 0.55);
}

.history-detail-time {
	font-size: 0.78rem;
	color: rgba(234, 240, 255, 0.35);
	margin-top: 2px;
}

/* Detail map */
.history-detail-map {
	margin-top: 0;
}

.history-mini-map {
	height: 180px;
	border-radius: 10px;
	border: 1px solid var(--chip-border);
}

/* ---- Responsive ---- */

@media (max-width: 768px) {
	.history-content {
		padding: 16px 14px 100px;
	}

	.history-grid {
		grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
		gap: 10px;
	}

	.history-card-temp {
		font-size: 1.8rem;
	}

	.history-card-icon {
		width: 34px;
		height: 34px;
	}

	.history-detail-temp-value {
		font-size: 6rem;
	}

	.history-detail-temp-unit {
		font-size: 1.5rem;
	}

	.history-detail {
		padding: 16px 14px;
	}
}

@media (max-width: 480px) {
	.history-grid {
		grid-template-columns: 1fr 1fr;
		gap: 8px;
	}

	.history-card {
		padding: 10px 10px 8px;
	}

	.history-card-temp {
		font-size: 1.5rem;
	}

	.history-card-icon {
		width: 28px;
		height: 28px;
	}

	.history-detail-temp-value {
		font-size: 5rem;
	}
}

/* ==================================================
   Weather FX animations
   ================================================== */

#weatherFx {
	position: fixed;
	inset: 0;
	pointer-events: none;
	z-index: 0;
	overflow: hidden;
}

.wx-rain,
.wx-snow,
.wx-lightning,
.wx-mist,
.wx-clouds,
.wx-stars {
	position: absolute;
	inset: 0;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.8s ease;
}

/* --- Rain --- */
body[data-theme="rain"] .wx-rain,
body[data-theme="thunder"] .wx-rain {
	opacity: 1;
}

.wx-rain .drop {
	position: absolute;
	width: 1.5px;
	height: 18px;
	background: linear-gradient(180deg, transparent, rgba(120, 200, 255, 0.45));
	border-radius: 0 0 2px 2px;
	animation: rainFall var(--dur, 0.7s) linear infinite;
	animation-delay: var(--delay, 0s);
	left: var(--x, 50%);
	top: -20px;
}

@keyframes rainFall {
	0%   { transform: translateY(0); opacity: 0.7; }
	100% { transform: translateY(100vh); opacity: 0; }
}

/* --- Snow --- */
body[data-theme="snow"] .wx-snow {
	opacity: 1;
}

.wx-snow .flake {
	position: absolute;
	width: var(--size, 4px);
	height: var(--size, 4px);
	background: rgba(255, 255, 255, 0.7);
	border-radius: 50%;
	animation: snowFall var(--dur, 4s) linear infinite;
	animation-delay: var(--delay, 0s);
	left: var(--x, 50%);
	top: -10px;
	filter: blur(var(--blur, 0px));
}

@keyframes snowFall {
	0%   { transform: translateY(0) translateX(0); opacity: 0.9; }
	50%  { transform: translateY(50vh) translateX(var(--drift, 20px)); opacity: 0.8; }
	100% { transform: translateY(100vh) translateX(0); opacity: 0; }
}

/* --- Lightning (thunder) --- */
body[data-theme="thunder"] .wx-lightning {
	opacity: 1;
}

.wx-lightning .flash {
	position: absolute;
	inset: 0;
	background: rgba(255, 255, 255, 0.06);
	animation: lightningFlash var(--period, 6s) ease-in-out infinite;
	animation-delay: var(--delay, 0s);
}

@keyframes lightningFlash {
	0%, 100% { opacity: 0; }
	1%       { opacity: 1; }
	2%       { opacity: 0; }
	3%       { opacity: 0.7; }
	4%       { opacity: 0; }
}

/* --- Mist / Fog --- */
body[data-theme="mist"] .wx-mist {
	opacity: 1;
}

.wx-mist .fog-band {
	position: absolute;
	width: 200%;
	height: var(--h, 30%);
	top: var(--y, 60%);
	left: -50%;
	background: linear-gradient(90deg,
		transparent 0%,
		rgba(180, 210, 210, 0.06) 20%,
		rgba(180, 210, 210, 0.10) 50%,
		rgba(180, 210, 210, 0.06) 80%,
		transparent 100%);
	animation: mistDrift var(--dur, 20s) ease-in-out infinite alternate;
	animation-delay: var(--delay, 0s);
	filter: blur(var(--blur, 8px));
}

@keyframes mistDrift {
	0%   { transform: translateX(-5%); }
	100% { transform: translateX(5%); }
}

/* --- Stars (clear night) --- */
body[data-theme="clear-night"] .wx-stars {
	opacity: 1;
}

.wx-stars .star {
	position: absolute;
	width: var(--size, 2px);
	height: var(--size, 2px);
	background: rgba(255, 255, 255, 0.8);
	border-radius: 50%;
	left: var(--x, 50%);
	top: var(--y, 50%);
	animation: starTwinkle var(--dur, 3s) ease-in-out infinite;
	animation-delay: var(--delay, 0s);
}

@keyframes starTwinkle {
	0%, 100% { opacity: 0.3; transform: scale(1); }
	50%      { opacity: 1; transform: scale(1.3); }
}

/* --- Clouds (overcast) --- */
body[data-theme="clouds"] .wx-clouds {
	opacity: 1;
}

.wx-clouds .cloud {
	position: absolute;
	top: var(--y, 20%);
	left: -20%;
	width: var(--w, 180px);
	height: var(--h, 50px);
	border-radius: 50%;
	background: radial-gradient(ellipse at center,
		rgba(200, 210, 230, var(--opacity, 0.06)) 0%,
		rgba(200, 210, 230, 0) 70%);
	filter: blur(8px);
	animation: cloudDrift var(--dur, 30s) linear infinite;
	animation-delay: var(--delay, 0s);
}

@keyframes cloudDrift {
	0%   { transform: translateX(0); }
	100% { transform: translateX(calc(100vw + 40%)); }
}

/* --- Clear day: subtle sun glow --- */
body[data-theme="clear-day"] #weatherFx::after {
	content: '';
	position: absolute;
	top: -10%;
	right: -5%;
	width: 40vw;
	height: 40vw;
	border-radius: 50%;
	background: radial-gradient(circle, rgba(255, 214, 10, 0.12) 0%, transparent 70%);
	animation: sunPulse 6s ease-in-out infinite;
}

@keyframes sunPulse {
	0%, 100% { transform: scale(1); opacity: 0.7; }
	50%      { transform: scale(1.08); opacity: 1; }
}

/* ==================================================
   Footer
   ================================================== */

.app-footer {
	position: fixed;
	bottom: 0;
	left: 0;
	right: 0;
	z-index: 500;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 10px 16px;
	background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.55) 100%);
	pointer-events: none;
}

.footer-group {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	pointer-events: auto;
}

.footer-sep {
	color: rgba(234, 240, 255, 0.3);
	font-size: 1rem;
	line-height: 1;
	user-select: none;
}

.app-footer a {
	pointer-events: auto;
}

.footer-text {
	font-size: 0.92rem;
	font-weight: 600;
	letter-spacing: 0.3px;
	color: rgba(234, 240, 255, 0.55);
}

.footer-logo {
	height: 24px;
	width: auto;
	vertical-align: middle;
	opacity: 0.55;
	transition: opacity 0.2s ease;
}

.footer-logo:hover {
	opacity: 0.9;
}

/* ==================================================
   Chat page styles
   ================================================== */

.chat-page {
	display: flex;
	flex-direction: column;
	height: 100vh;
	height: 100dvh;
	box-sizing: border-box;
}

.chat-page .corner-ui {
	position: relative;
	top: auto;
	left: auto;
	right: auto;
	padding: 10px 16px;
	flex-shrink: 0;
}

.chat-shell {
	display: flex;
	flex: 1;
	min-height: 0;
	overflow: hidden;
}

/* ---- Sidebar ---- */

.chat-sidebar {
	width: 260px;
	flex-shrink: 0;
	display: flex;
	flex-direction: column;
	background: var(--panel-bg, rgba(15, 18, 30, 0.88));
	border-right: 1px solid var(--panel-border, rgba(234, 240, 255, 0.08));
	backdrop-filter: blur(16px);
	-webkit-backdrop-filter: blur(16px);
}

.chat-sidebar-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 14px 10px;
	border-bottom: 1px solid var(--panel-border, rgba(234, 240, 255, 0.08));
}

.chat-sidebar-title {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 0.95rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 1px;
	color: rgba(234, 240, 255, 0.55);
}

.chat-session-list {
	flex: 1;
	overflow-y: auto;
	padding: 6px 0;
}

.chat-session-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	padding: 10px 14px;
	cursor: pointer;
	transition: background 0.15s ease;
	border-left: 3px solid transparent;
}

.chat-session-item:hover {
	background: rgba(234, 240, 255, 0.04);
}

.chat-session-item.is-active {
	background: rgba(234, 240, 255, 0.07);
	border-left-color: var(--accent1, #60a5fa);
}

.chat-session-info {
	flex: 1;
	min-width: 0;
}

.chat-session-item-title {
	font-size: 0.88rem;
	font-weight: 500;
	color: rgba(234, 240, 255, 0.88);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.chat-session-time {
	font-size: 0.75rem;
	color: rgba(234, 240, 255, 0.4);
	margin-top: 2px;
}

.chat-session-delete {
	flex-shrink: 0;
	background: none;
	border: none;
	color: rgba(234, 240, 255, 0.3);
	font-size: 0.85rem;
	cursor: pointer;
	padding: 4px 8px;
	border-radius: 4px;
	opacity: 1;
	transition: color 0.15s ease, background 0.15s ease;
}

.chat-session-delete:hover {
	color: rgba(239, 68, 68, 0.9);
	background: rgba(239, 68, 68, 0.12);
}

/* ---- Mobile swipe-to-delete ---- */

.chat-session-swipe {
	position: relative;
	overflow: hidden;
}

.chat-session-swipe .chat-session-item {
	position: relative;
	z-index: 1;
	transition: transform 0.2s ease;
	background: var(--panel-bg, rgba(15, 18, 30, 0.88));
}

.chat-session-swipe.is-swiping .chat-session-item {
	transition: none;
}

.chat-session-swipe-action {
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	width: 80px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(239, 68, 68, 0.85);
	color: #fff;
	font-size: 0.8rem;
	font-weight: 600;
	letter-spacing: 0.3px;
}

/* ---- Main chat area ---- */

.chat-main {
	flex: 1;
	display: flex;
	flex-direction: column;
	min-width: 0;
	position: relative;
}

.chat-thread {
	flex: 1;
	overflow-y: auto;
	padding: 20px 24px 12px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

/* ---- Empty / welcome state ---- */

.chat-main.is-empty {
	justify-content: center;
	padding-bottom: 12vh;
}

.chat-main.is-empty .chat-thread {
	display: none;
}

.chat-main.is-empty .chat-input-area {
	background: none;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
	max-width: 560px;
	width: 100%;
	align-self: center;
}

.chat-input-wrap {
	animation: chatInputGlow 3s ease-in-out infinite;
}

@keyframes chatInputGlow {
	0%, 100% {
		box-shadow: 0 0 8px rgba(255, 215, 0, 0.15), 0 0 0 1px rgba(255, 215, 0, 0.08);
	}
	50% {
		box-shadow: 0 0 20px rgba(255, 215, 0, 0.3), 0 0 0 1px rgba(255, 215, 0, 0.2);
	}
}

.chat-empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 10px;
	padding: 0 24px 8px;
}

.chat-empty .empty-icon {
	width: 72px;
	height: 72px;
	opacity: 0.25;
	filter: drop-shadow(0 0 16px rgba(255, 215, 0, 0.3));
}

.chat-empty .empty-title {
	font-family: 'Bebas Neue', sans-serif;
	font-size: 1.35rem;
	font-weight: 600;
	letter-spacing: 1px;
	color: rgba(234, 240, 255, 0.7);
}

.chat-empty .muted {
	font-size: 0.88rem;
	color: rgba(234, 240, 255, 0.35);
}

/* ---- Chat bubbles ---- */

.chat-bubble {
	max-width: 75%;
	padding: 12px 16px;
	border-radius: 16px;
	animation: chatBubbleIn 0.25s ease;
	line-height: 1.5;
	font-size: 0.92rem;
	word-wrap: break-word;
	overflow-wrap: break-word;
}

.chat-bubble--user {
	align-self: flex-end;
	background: var(--accent1, #60a5fa);
	color: #fff;
	border-bottom-right-radius: 4px;
}

.chat-bubble--assistant {
	align-self: flex-start;
	background: var(--chip-bg, rgba(234, 240, 255, 0.08));
	color: rgba(234, 240, 255, 0.92);
	border-bottom-left-radius: 4px;
}

.chat-bubble-content {
	white-space: pre-wrap;
}

.chat-bubble-footer {
	display: flex;
	align-items: center;
	gap: 6px;
	margin-top: 4px;
}

.chat-bubble--user .chat-bubble-footer {
	justify-content: flex-end;
}

.chat-bubble-time {
	font-size: 0.7rem;
	color: rgba(234, 240, 255, 0.35);
}

.chat-bubble--user .chat-bubble-time {
	color: rgba(255, 255, 255, 0.55);
}

.chat-source-badge {
	font-size: 0.65rem;
	font-weight: 600;
	letter-spacing: 0.3px;
	padding: 1px 6px;
	border-radius: 6px;
	text-transform: uppercase;
}

.chat-source-badge--openweather {
	background: rgba(234, 240, 255, 0.06);
	color: rgba(234, 240, 255, 0.35);
}

.chat-source-badge--claude {
	background: rgba(217, 119, 57, 0.15);
	color: rgba(217, 150, 90, 0.8);
}

@keyframes chatBubbleIn {
	from {
		opacity: 0;
		transform: translateY(8px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* ---- Typing indicator ---- */

.chat-bubble--typing {
	padding: 14px 20px;
}

.typing-dots {
	display: flex;
	gap: 5px;
	align-items: center;
}

.typing-dots span {
	width: 7px;
	height: 7px;
	background: rgba(234, 240, 255, 0.4);
	border-radius: 50%;
	animation: typingBounce 1.2s infinite ease-in-out;
}

.typing-dots span:nth-child(2) {
	animation-delay: 0.15s;
}

.typing-dots span:nth-child(3) {
	animation-delay: 0.3s;
}

@keyframes typingBounce {
	0%, 60%, 100% {
		transform: translateY(0);
		opacity: 0.4;
	}
	30% {
		transform: translateY(-6px);
		opacity: 1;
	}
}

/* ---- Footer: hide on chat page ---- */

body:has(.chat-page) .app-footer {
	display: none !important;
}

/* ---- Input area ---- */

.chat-input-area {
	flex-shrink: 0;
	padding: 12px 24px 16px;
	background: linear-gradient(180deg, transparent 0%, var(--panel-bg, rgba(15, 18, 30, 0.88)) 30%);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
}

.chat-input-wrap {
	display: flex;
	align-items: center;
	gap: 8px;
	background: rgba(234, 240, 255, 0.06);
	border: 1px solid var(--panel-border, rgba(234, 240, 255, 0.08));
	border-radius: 24px;
	padding: 4px 4px 4px 16px;
	transition: border-color 0.2s ease;
}

.chat-input-wrap:focus-within {
	border-color: var(--accent1, #60a5fa);
}

.chat-input {
	flex: 1;
	background: none;
	border: none;
	outline: none;
	color: rgba(234, 240, 255, 0.92);
	font-size: 0.92rem;
	padding: 8px 0;
	font-family: inherit;
}

.chat-input::placeholder {
	color: rgba(234, 240, 255, 0.3);
}

.chat-send-btn {
	flex-shrink: 0;
	width: 36px;
	height: 36px;
	border: none;
	border-radius: 50%;
	background: var(--accent1, #60a5fa);
	color: #fff;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.15s ease, transform 0.15s ease;
}

.chat-send-btn:hover {
	background: var(--accent2, #3b82f6);
	transform: scale(1.05);
}

.chat-send-btn:active {
	transform: scale(0.95);
}

.chat-send-btn.is-sending {
	opacity: 0.5;
	pointer-events: none;
}

.chat-attribution {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding-top: 8px;
	font-size: 0.78rem;
	font-weight: 600;
	letter-spacing: 0.3px;
	color: rgba(234, 240, 255, 0.35);
}

.chat-attribution a {
	display: inline-flex;
	align-items: center;
}

.chat-attribution .footer-logo {
	height: 18px;
	opacity: 0.4;
}

.chat-attribution .footer-logo:hover {
	opacity: 0.8;
}

.chat-attribution .footer-sep {
	font-size: 0.85rem;
}

/* ---- Mobile sidebar toggle ---- */

.chat-sidebar-toggle {
	display: none;
}

/* ---- Mobile responsive (chat) ---- */

@media (max-width: 768px) {
	.chat-sidebar-toggle {
		display: inline-flex;
	}

	.chat-sidebar {
		position: fixed;
		top: 0;
		left: 0;
		bottom: 0;
		width: 280px;
		z-index: 1100;
		transform: translateX(-100%);
		transition: transform 0.25s ease;
		box-shadow: none;
	}

	.chat-sidebar.is-open {
		transform: translateX(0);
		box-shadow: 4px 0 24px rgba(0, 0, 0, 0.5);
	}

	.chat-bubble {
		max-width: 88%;
	}

	.chat-thread {
		padding: 16px 14px 10px;
	}

	.chat-input-area {
		padding: 10px 14px 14px;
	}

	.chat-session-delete {
		display: none;
	}
}

/* ==================================================
   Responsive — SEEK + REPORT + nav
   ================================================== */

@media (max-width: 768px) {
	.hero-temp-value {
		font-size: 8rem;
	}

	.hero-temp-unit {
		font-size: 2rem;
	}

	.report-section-title {
		font-size: 1.3rem;
	}

	.seek-hero {
		padding-top: 24px;
	}

	.seek-input {
		font-size: 0.95rem;
	}

	.seek-map {
		height: 25dvh;
		min-height: 150px;
	}

	.nav-center {
		max-width: 40vw;
	}

	.report-overview {
		font-size: 0.88rem;
	}

	.report-section {
		padding: 16px;
	}

	.alerts-banner .alert-card {
		padding: 10px 12px;
	}
}

@media (max-width: 480px) {
	.nav-wordmark {
		display: none;
	}

	.nav-strip {
		padding: 0 10px;
	}

	.mode-link {
		padding: 7px 10px;
		font-size: 0.8rem;
	}

	.hero-temp-value {
		font-size: 6rem;
	}

	.hero-temp-unit {
		font-size: 1.5rem;
	}

	.seek-mode {
		padding: 24px 14px 80px;
	}

	.seek-mascot-wrap {
		width: 90px;
		height: 90px;
	}

	.seek-recent-card {
		min-width: 120px;
		max-width: 150px;
		padding: 8px 10px;
	}

	.report-mode {
		padding: 16px 14px 80px;
	}

	.report-hero {
		padding: 24px 0 16px;
	}

	.report-hero-condition span {
		font-size: 1rem;
	}

	.nav-center {
		max-width: 35vw;
	}

	.nav-place {
		font-size: 0.78rem;
	}

	.nav-asof {
		font-size: 0.6rem;
	}

	.hourly-card {
		min-width: 56px;
		padding: 8px 4px;
	}
}
