/* =========================================================
WAHSUITS ADMIN — same look as the website (colours, type, cards)
========================================================= */

@font-face { font-family: Inter; font-style: normal; font-weight: 400; font-display: swap; src: url("../assets/fonts/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuLyfMZ1rib2Bg-4.woff2") format("woff2"); }
@font-face { font-family: Inter; font-style: normal; font-weight: 500; font-display: swap; src: url("../assets/fonts/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuI6fMZ1rib2Bg-4.woff2") format("woff2"); }
@font-face { font-family: Inter; font-style: normal; font-weight: 600; font-display: swap; src: url("../assets/fonts/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuGKYMZ1rib2Bg-4.woff2") format("woff2"); }
@font-face { font-family: Inter; font-style: normal; font-weight: 700; font-display: swap; src: url("../assets/fonts/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuFuYMZ1rib2Bg-4.woff2") format("woff2"); }
@font-face { font-family: Inter; font-style: normal; font-weight: 800; font-display: swap; src: url("../assets/fonts/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuDyYMZ1rib2Bg-4.woff2") format("woff2"); }
@font-face { font-family: Inter; font-style: normal; font-weight: 900; font-display: swap; src: url("../assets/fonts/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuBWYMZ1rib2Bg-4.woff2") format("woff2"); }
@font-face { font-family: Inter; font-style: italic; font-weight: 900; font-display: swap; src: url("../assets/fonts/UcCM3FwrK3iLTcvneQg7Ca725JhhKnNqk4j1ebLhAm8SrXTccNxhiJ-Ek-7MeA.woff2") format("woff2"); }

:root {
	--navy: #13233a;
	--navy-deep: #0d1f30;
	--ink: #18155b;
	--teal: #4aadb3;
	--teal-ink: #2b7f86;
	--aqua: #7de1d4;
	--yellow: #ffe16a;
	--orange: #f89d32;
	--orange-ink: #e07b12;
	--paper: #f0f9ff;
	--card: #ffffff;
	--line: rgba(19, 35, 58, 0.1);
	--line-strong: rgba(19, 35, 58, 0.18);
	--muted: #5b6b80;
	--danger: #e5484d;
	--ok: #22b573;
	--glow-ok: #5cf2a6;
	--radius-lg: 32px;
	--radius-md: 22px;
	--radius-sm: 14px;
	--gradient: linear-gradient(90deg, var(--aqua), var(--yellow) 55%, var(--orange));
	--header-gradient: linear-gradient(321deg, rgb(13, 54, 114) 0%, rgb(199, 223, 210) 73%, rgb(74, 173, 179) 100%);
	--shadow-sheet: 0 30px 80px rgba(2, 8, 20, 0.35);
	--shadow-card: 0 10px 28px rgba(13, 31, 48, 0.08);
	--spring: cubic-bezier(0.34, 1.56, 0.64, 1);
	--ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
	margin: 0;
	min-height: 100vh;
	font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
	font-size: 15px;
	font-weight: 500;
	line-height: 1.45;
	color: var(--navy);
	-webkit-font-smoothing: antialiased;
	background:
		radial-gradient(1100px 700px at 8% -5%, rgba(74, 173, 179, 0.34), transparent 60%),
		radial-gradient(900px 650px at 100% 25%, rgba(248, 157, 50, 0.10), transparent 60%),
		radial-gradient(1300px 900px at 50% 115%, rgba(74, 211, 211, 0.22), transparent 60%),
		linear-gradient(180deg, #0b1f3a 0%, #10294a 55%, #0c2135 100%);
	background-attachment: fixed;
}

::selection { background: var(--aqua); color: var(--navy); }

:focus-visible {
	outline: 3px solid var(--aqua);
	outline-offset: 3px;
}

h1, h2, h3 { margin: 0; color: var(--ink); letter-spacing: -0.02em; }

p { margin: 0; }

img { max-width: 100%; }

/* Decorative stars, same artwork as the website */
.stars {
	position: fixed;
	top: 0;
	z-index: 0;
	width: min(16vw, 240px);
	height: 640px;
	pointer-events: none;
	background: no-repeat top / contain;
	opacity: 0.9;
}
.stars-left { left: 0; background-image: url("../assets/img/Artboard-3.png"); }
.stars-right { right: 0; background-image: url("../assets/img/Artboard-1-2.png"); }
body:not(.is-connect) .stars { opacity: 0.35; }

/* ---------- Type ---------- */

.kicker {
	display: inline-block;
	padding: 6px 13px;
	border-radius: 999px;
	font-size: 11px;
	font-weight: 900;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--teal-ink);
	background: rgba(74, 173, 179, 0.12);
	border: 1px solid rgba(74, 173, 179, 0.25);
}

.display {
	font-size: clamp(34px, 5vw, 54px);
	font-weight: 900;
	line-height: 1.02;
	letter-spacing: -0.035em;
	color: var(--ink);
}

.lede {
	font-size: 17px;
	font-style: italic;
	font-weight: 900;
	color: var(--orange);
}

.hint { font-size: 13px; color: var(--muted); font-weight: 500; }
.hint.center { text-align: center; }
.hint.warn { color: var(--orange-ink); }
.lead-hint { margin-bottom: 14px; }
.form-error { min-height: 1.2em; font-size: 14px; font-weight: 700; color: var(--danger); }
.form-error:empty { min-height: 0; }

.notice {
	padding: 12px 14px;
	border-radius: var(--radius-sm);
	font-size: 14px;
	font-weight: 600;
}
.notice.is-warn { color: #8a4a00; background: #fff3e0; border: 1px solid #ffd59e; }

.icon { display: inline-flex; width: 18px; height: 18px; flex: 0 0 auto; }
.icon svg { width: 100%; height: 100%; }

/* ---------- Buttons ---------- */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 44px;
	padding: 10px 22px;
	font: inherit;
	font-size: 15px;
	font-weight: 900;
	letter-spacing: 0.02em;
	white-space: nowrap;
	color: var(--navy);
	text-decoration: none;
	border: 0;
	border-radius: 999px;
	cursor: pointer;
	transition: transform 0.25s var(--spring), box-shadow 0.25s ease, background-position 0.5s ease, background-color 0.2s;
}

.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn:not(:disabled):active { transform: scale(0.97); }

.btn-primary {
	background: var(--gradient);
	background-size: 200% 100%;
	box-shadow: 0 10px 26px rgba(248, 157, 50, 0.28), 0 4px 12px rgba(0, 0, 0, 0.12);
}
.btn-primary:not(:disabled):hover {
	transform: translateY(-2px) scale(1.02);
	background-position: 100% 50%;
	box-shadow: 0 16px 34px rgba(248, 157, 50, 0.34), 0 0 26px rgba(125, 225, 212, 0.3);
}
.btn-primary:disabled { box-shadow: none; }

.btn-soft { background: #e3f1f7; color: var(--navy); }
.btn-soft:not(:disabled):hover { background: #d3e9f2; }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:not(:disabled):hover { background: #cf3237; }

.btn-danger-quiet { background: transparent; color: var(--danger); border: 1.5px solid rgba(229, 72, 77, 0.35); }
.btn-danger-quiet:hover { background: rgba(229, 72, 77, 0.08); }

.btn-ghost-dark { background: rgba(255, 255, 255, 0.1); color: #fff; }
.btn-ghost-dark:hover { background: rgba(255, 255, 255, 0.18); }

.btn-sm { min-height: 36px; padding: 6px 15px; font-size: 13px; }
.btn-wide { width: 100%; }

.btn-link {
	padding: 0;
	font: inherit;
	font-size: 13px;
	font-weight: 800;
	color: var(--teal-ink);
	background: none;
	border: 0;
	text-decoration: underline;
	text-underline-offset: 3px;
	cursor: pointer;
}

.btn-round {
	display: inline-grid;
	place-items: center;
	width: 42px;
	height: 42px;
	padding: 0;
	color: inherit;
	background: rgba(255, 255, 255, 0.16);
	border: 0;
	border-radius: 50%;
	cursor: pointer;
	transition: background 0.2s, transform 0.25s var(--spring);
}
.btn-round:hover:not(:disabled) { background: rgba(255, 255, 255, 0.28); }
.btn-round:disabled { opacity: 0.3; cursor: not-allowed; }
.btn-round-sm { width: 34px; height: 34px; color: var(--navy); background: #e8f3f8; }
.btn-round-sm .icon { width: 16px; height: 16px; }
.btn-round-sm:hover:not(:disabled) { background: #d6eaf2; }
.btn-round-sm.is-danger:hover:not(:disabled) { color: #fff; background: var(--danger); }

.link-quiet {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 14px;
	font-weight: 800;
	color: var(--teal-ink);
	text-decoration: none;
}
.link-quiet:hover { text-decoration: underline; text-underline-offset: 3px; }
.link-quiet .icon { width: 15px; height: 15px; }

/* ---------- Form fields ---------- */

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-size: 13px; font-weight: 800; color: var(--navy); }
.field small { font-size: 12.5px; }

input, textarea, select {
	width: 100%;
	min-height: 46px;
	padding: 11px 14px;
	font: inherit;
	font-weight: 600;
	color: var(--navy);
	background: #fff;
	border: 1.5px solid var(--line-strong);
	border-radius: var(--radius-sm);
	transition: border-color 0.15s, box-shadow 0.15s;
}
input::placeholder, textarea::placeholder { color: #9aa8b8; font-weight: 500; }
input:hover, textarea:hover, select:hover { border-color: rgba(74, 173, 179, 0.6); }
input:focus, textarea:focus, select:focus {
	outline: none;
	border-color: var(--teal);
	box-shadow: 0 0 0 4px rgba(125, 225, 212, 0.35);
}
textarea { resize: vertical; line-height: 1.45; }

.check { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; cursor: pointer; }
.check input { width: 20px; min-height: 0; height: 20px; accent-color: var(--teal); }

.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; gap: 12px; }
.row > * { flex: 1; }
.row > .is-narrow { flex: 0 0 96px; }

/* Switch */
.switch { position: relative; display: inline-flex; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; min-height: 0; }
.switch-ui {
	position: relative;
	width: 52px;
	height: 30px;
	border-radius: 999px;
	background: #cfdbe6;
	transition: background 0.2s;
}
.switch-ui::after {
	content: "";
	position: absolute;
	top: 3px;
	left: 3px;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: #fff;
	box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
	transition: transform 0.3s var(--spring);
}
.switch input:checked + .switch-ui { background: var(--teal); }
.switch input:checked + .switch-ui::after { transform: translateX(22px); }
.switch input:focus-visible + .switch-ui { box-shadow: 0 0 0 4px rgba(125, 225, 212, 0.45); }

/* Chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
	padding: 8px 14px;
	font: inherit;
	font-size: 13px;
	font-weight: 800;
	color: var(--navy);
	background: #fff;
	border: 1.5px solid var(--line-strong);
	border-radius: 999px;
	cursor: pointer;
	transition: border-color 0.15s, background 0.15s, transform 0.2s var(--spring);
}
.chip:hover { border-color: var(--teal); background: #effafa; transform: translateY(-1px); }

/* =========================================================
CONNECT SCREEN
========================================================= */

.connect {
	position: relative;
	z-index: 1;
	display: grid;
	place-items: center;
	min-height: 100vh;
	padding: 32px 16px;
}

.connect-card {
	width: min(100%, 940px);
	padding: clamp(28px, 5vw, 56px);
	text-align: center;
	background:
		radial-gradient(600px 300px at 0% 0%, rgba(125, 225, 212, 0.25), transparent 60%),
		radial-gradient(500px 300px at 100% 100%, rgba(248, 157, 50, 0.12), transparent 60%),
		var(--paper);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sheet);
}

.connect-logo {
	width: 120px;
	height: 120px;
	margin: 0 auto 14px;
	display: block;
	filter: drop-shadow(0 12px 24px rgba(13, 31, 48, 0.2));
}

.connect-card .display { margin: 16px 0 10px; }

.connect-options {
	display: grid;
	grid-template-columns: 1.15fr 1fr;
	gap: 18px;
	margin-top: 34px;
	text-align: left;
}

.option {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 26px;
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
}
.option h2 { font-size: 21px; font-weight: 900; }
.option-local { background: rgba(255, 255, 255, 0.6); }
.option-local .btn + .btn { margin-top: -4px; }

.advanced summary {
	font-size: 13px;
	font-weight: 800;
	color: var(--teal-ink);
	cursor: pointer;
}
.advanced .row { margin-top: 12px; }

/* =========================================================
TOP BAR — the website's header pill
========================================================= */

.topbar {
	position: sticky;
	top: 12px;
	z-index: 40;
	display: flex;
	align-items: center;
	gap: 14px;
	width: min(calc(100% - 24px), 1460px);
	margin: 12px auto 0;
	padding: 10px 12px 10px 14px;
	color: #fff;
	background-image: var(--header-gradient);
	border-radius: 999px;
	box-shadow: 0 16px 40px rgba(2, 8, 20, 0.35);
}

.brand { display: flex; flex: 0 0 auto; }
.brand img { width: 56px; height: 56px; transition: transform 0.4s var(--spring); }
.brand:hover img { transform: rotate(-8deg) scale(1.06); }

.tabs {
	display: flex;
	flex: 1;
	gap: 2px;
	min-width: 0;
	overflow-x: auto;
	scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs button {
	flex: 0 0 auto;
	padding: 10px 15px;
	font: inherit;
	font-size: 15px;
	font-weight: 900;
	color: #fff;
	text-shadow: 0 1px 6px rgba(13, 31, 48, 0.35);
	background: none;
	border: 0;
	border-radius: 999px;
	cursor: pointer;
	transition: color 0.2s, background 0.2s, transform 0.2s var(--spring);
}
.tabs button:hover { color: var(--yellow); transform: translateY(-1px); }
.tabs button.is-active {
	color: var(--yellow);
	background: rgba(13, 31, 48, 0.45);
	text-shadow: none;
}

.topbar-actions { display: flex; flex: 0 0 auto; align-items: center; gap: 10px; }
.topbar .btn-round { color: #fff; background: rgba(13, 31, 48, 0.35); }
.topbar .btn-round:hover { background: rgba(13, 31, 48, 0.55); }

.chip-status {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 42px;
	padding: 0 16px;
	font: inherit;
	font-size: 13px;
	font-weight: 700;
	color: #fff;
	background: rgba(13, 31, 48, 0.42);
	border: 1px solid rgba(255, 255, 255, 0.16);
	border-radius: 999px;
	cursor: pointer;
	white-space: nowrap;
}
.chip-status:hover { background: rgba(13, 31, 48, 0.6); }
.chip-status b { font-weight: 900; }
.chip-status .dot, .big-toggle .dot {
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: #ff6b6b;
	box-shadow: 0 0 10px #ff6b6b;
}
.chip-status.is-open .dot { background: var(--glow-ok); box-shadow: 0 0 10px var(--glow-ok); animation: pulse 1.6s ease-in-out infinite; }
.chip-time { display: inline-flex; align-items: center; gap: 4px; padding-left: 8px; color: var(--yellow); border-left: 1px solid rgba(255, 255, 255, 0.2); }
.chip-time .icon { width: 14px; height: 14px; }

@keyframes pulse { 50% { opacity: 0.35; } }

.menu-wrap { position: relative; }
.menu {
	position: absolute;
	top: calc(100% + 10px);
	right: 0;
	z-index: 50;
	display: flex;
	flex-direction: column;
	width: 270px;
	padding: 8px;
	color: var(--navy);
	background: #fff;
	border-radius: var(--radius-md);
	box-shadow: 0 20px 50px rgba(2, 8, 20, 0.3);
	animation: pop 0.25s var(--spring);
}
.menu button {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 11px 12px;
	font: inherit;
	font-weight: 800;
	text-align: left;
	color: inherit;
	background: none;
	border: 0;
	border-radius: 12px;
	cursor: pointer;
}
.menu button:hover { background: #edf6fa; }
.menu button .icon { color: var(--teal-ink); }
.menu-where {
	margin: 4px 4px 6px;
	padding: 10px 12px;
	font-size: 12.5px;
	color: var(--muted);
	background: #f3f8fb;
	border-radius: 12px;
	overflow-wrap: anywhere;
}
.menu-where b { color: var(--navy); }

@keyframes pop {
	from { opacity: 0; transform: translateY(-6px) scale(0.97); }
	to { opacity: 1; transform: none; }
}

/* =========================================================
THE SHEET — the big light card, like the website's pages
========================================================= */

.sheet {
	position: relative;
	z-index: 1;
	width: min(calc(100% - 24px), 1460px);
	margin: 16px auto 100px;
	padding: clamp(18px, 2.4vw, 30px);
	background:
		radial-gradient(700px 360px at 0% 0%, rgba(125, 225, 212, 0.22), transparent 60%),
		var(--paper);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-sheet);
	transition: margin-right 0.4s var(--ease-out);
}

/* ---------- Page editor ---------- */

.editor-head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 14px;
}

.editor-title-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; margin-top: 8px; }
.editor-title {
	font-size: clamp(30px, 4vw, 46px);
	font-weight: 900;
	line-height: 1;
	letter-spacing: -0.035em;
}

.editor-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.editor-status { font-size: 13px; font-weight: 700; color: var(--muted); }

.seg { display: inline-flex; padding: 4px; background: #e3f1f7; border-radius: 999px; }
.seg button {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	min-height: 32px;
	padding: 4px 13px;
	font: inherit;
	font-size: 13px;
	font-weight: 800;
	color: var(--muted);
	background: none;
	border: 0;
	border-radius: 999px;
	cursor: pointer;
}
.seg button .icon { width: 15px; height: 15px; }
.seg button.is-active { color: var(--navy); background: #fff; box-shadow: 0 2px 8px rgba(13, 31, 48, 0.12); }

.how {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin: 0 0 16px;
	padding: 0;
	list-style: none;
}
.how li {
	padding: 7px 14px;
	font-size: 13px;
	color: var(--muted);
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 999px;
}
.how b { color: var(--navy); font-weight: 900; }

.frame-wrap {
	overflow: hidden;
	background: var(--navy-deep);
	border-radius: var(--radius-md);
	box-shadow: 0 0 0 1px var(--line), 0 18px 40px rgba(13, 31, 48, 0.18);
	transition: max-width 0.4s var(--ease-out);
}
.page-frame {
	display: block;
	width: 100%;
	height: calc(100vh - 230px);
	min-height: 520px;
	border: 0;
	background: var(--navy-deep);
}
.frame-wrap.is-phone {
	max-width: 400px;
	margin: 0 auto;
	border: 10px solid var(--navy);
	border-radius: 42px;
}
.frame-wrap.is-phone .page-frame { height: min(820px, calc(100vh - 230px)); }

/* ---------- Unsaved bar ---------- */

.unsaved-bar {
	position: fixed;
	left: 50%;
	bottom: 20px;
	z-index: 45;
	display: flex;
	align-items: center;
	gap: 10px;
	max-width: calc(100% - 24px);
	padding: 8px 8px 8px 20px;
	color: #fff;
	background: var(--navy);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 999px;
	box-shadow: 0 18px 44px rgba(2, 8, 20, 0.45);
	transform: translateX(-50%);
	animation: rise 0.4s var(--spring);
}
.unsaved-bar > span {
	overflow: hidden;
	font-size: 14px;
	font-weight: 700;
	white-space: nowrap;
	text-overflow: ellipsis;
}
.unsaved-bar > span::before {
	content: "";
	display: inline-block;
	width: 8px;
	height: 8px;
	margin-right: 10px;
	border-radius: 50%;
	background: var(--orange);
	box-shadow: 0 0 10px var(--orange);
	vertical-align: 1px;
}
body.has-drawer .unsaved-bar { left: calc((100% - min(460px, 100%)) / 2); }

@keyframes rise {
	from { opacity: 0; transform: translate(-50%, 20px); }
	to { opacity: 1; transform: translate(-50%, 0); }
}

/* =========================================================
SIDE PANEL
========================================================= */

.drawer {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	z-index: 60;
	display: flex;
	flex-direction: column;
	width: min(460px, 100%);
	background: var(--paper);
	box-shadow: -24px 0 60px rgba(2, 8, 20, 0.35);
	transform: translateX(105%);
	transition: transform 0.45s var(--ease-out);
}
.drawer.is-open { transform: none; }

@media (min-width: 1100px) {
	body.has-drawer .sheet,
	body.has-drawer .topbar { width: auto; margin-left: 12px; margin-right: 472px; }
}

.drawer-head {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 18px 18px 18px 22px;
	color: #fff;
	background-image: var(--header-gradient);
}
.drawer-head > div { flex: 1; min-width: 0; }
.drawer-head .kicker { color: #fff; background: rgba(13, 31, 48, 0.3); border-color: rgba(255, 255, 255, 0.2); }
.drawer-head h2 {
	margin-top: 6px;
	overflow: hidden;
	font-size: 26px;
	font-weight: 900;
	color: #fff;
	white-space: nowrap;
	text-overflow: ellipsis;
	text-shadow: 0 1px 8px rgba(13, 31, 48, 0.3);
}
.drawer-head .btn-round { color: #fff; background: rgba(13, 31, 48, 0.35); }

.drawer-body {
	flex: 1;
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 20px 20px 120px;
	overflow-y: auto;
	overscroll-behavior: contain;
}

.panel-block {
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 18px;
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
}
.panel-block h3 { display: flex; align-items: center; gap: 8px; font-size: 17px; font-weight: 900; }
.panel-block h3 .icon { color: var(--teal-ink); }
.panel-block.more summary { font-size: 15px; font-weight: 900; color: var(--ink); cursor: pointer; }
.panel-block.more[open] summary { margin-bottom: 4px; }
.block-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.mini-label { font-size: 13px; font-weight: 800; }
.row-actions { display: flex; gap: 8px; }

/* Open / closed */
.big-toggle { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.big-toggle button {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 58px;
	font: inherit;
	font-size: 17px;
	font-weight: 900;
	color: var(--muted);
	background: #f3f8fb;
	border: 2px solid transparent;
	border-radius: 18px;
	cursor: pointer;
	transition: all 0.2s;
}
.big-toggle button .dot { background: #b8c4d0; box-shadow: none; }
.big-toggle button:hover { border-color: var(--line-strong); }
.big-toggle .is-open.is-on { color: #0d6b45; background: #e3fbef; border-color: var(--glow-ok); }
.big-toggle .is-open.is-on .dot { background: var(--ok); box-shadow: 0 0 10px var(--glow-ok); }
.big-toggle .is-closed.is-on { color: #a12a2e; background: #ffeceb; border-color: #ffb3b3; }
.big-toggle .is-closed.is-on .dot { background: #ff6b6b; box-shadow: 0 0 10px #ff6b6b; }

.timer.is-set { border-color: rgba(74, 173, 179, 0.4); box-shadow: 0 10px 28px rgba(74, 173, 179, 0.15); }
.timer-left {
	padding: 14px 16px;
	font-size: 15px;
	color: #fff;
	background: var(--navy);
	border-radius: 16px;
}
.timer-left b { font-size: 20px; font-weight: 900; color: var(--yellow); }
.timer-left span { font-size: 13px; color: rgba(255, 255, 255, 0.7); }

/* Photo picker field */
.photo-field {
	position: relative;
	display: grid;
	place-items: center;
	width: 100%;
	aspect-ratio: 1;
	padding: 0;
	overflow: hidden;
	font: inherit;
	color: var(--muted);
	background: #eaf4f9;
	border: 2px dashed var(--line-strong);
	border-radius: 18px;
	cursor: pointer;
}
.photo-field img { width: 100%; height: 100%; object-fit: cover; }
.photo-field:has(img) { border-style: solid; border-color: transparent; }
.photo-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; }
.photo-empty .icon { width: 28px; height: 28px; }
.photo-change {
	position: absolute;
	right: 8px;
	bottom: 8px;
	padding: 5px 11px;
	font-size: 12px;
	font-weight: 900;
	color: var(--navy);
	background: rgba(255, 255, 255, 0.92);
	border-radius: 999px;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
	opacity: 0;
	transform: translateY(4px);
	transition: all 0.2s;
}
.photo-field:hover .photo-change, .photo-field:focus-visible .photo-change { opacity: 1; transform: none; }

/* Gallery polaroids (same look as the homepage) */
.polaroids { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.polaroid {
	display: flex;
	flex-direction: column;
	gap: 8px;
	padding: 10px 10px 12px;
	background: #fffdf8;
	border-radius: 6px;
	box-shadow: 0 10px 24px rgba(13, 31, 48, 0.16);
	transform: rotate(-1.2deg);
	transition: transform 0.35s var(--spring), box-shadow 0.3s;
}
.polaroid:nth-child(even) { transform: rotate(1.2deg); }
.polaroid:hover, .polaroid.is-focus { transform: rotate(0) translateY(-3px); box-shadow: 0 16px 34px rgba(13, 31, 48, 0.22); }
.polaroid.is-focus { outline: 3px solid var(--orange); outline-offset: 3px; }
.polaroid .field > span { display: none; }
.polaroid .photo-field { border-radius: 3px; }
.polaroid-caption {
	min-height: 38px;
	padding: 6px 8px;
	font-weight: 800;
	text-align: center;
	background: transparent;
	border-color: transparent;
}
.polaroid-actions { display: flex; align-items: center; gap: 6px; }
.spacer { flex: 1; }
.empty-note { padding: 30px; text-align: center; color: var(--muted); }

/* WAH cards (same rarity colours as the WAHfamily page) */
.country { gap: 12px; }
.country-head { display: flex; align-items: center; gap: 8px; }
.flag-input { flex: 0 0 58px; width: 58px; padding: 8px 4px; font-size: 22px; text-align: center; }
.country-name { flex: 1; font-size: 17px; font-weight: 900; }

.mini-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 10px; }
.mini-card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding: 6px 6px 8px;
	font: inherit;
	text-align: center;
	color: #fff;
	border: 2px solid rgba(255, 255, 255, 0.22);
	border-radius: 14px;
	cursor: pointer;
	transition: transform 0.3s var(--spring), box-shadow 0.2s;
}
.mini-card:hover { transform: translateY(-4px) rotate(-1deg); }
.mini-card img, .mini-card .mini-empty {
	display: grid;
	place-items: center;
	width: 100%;
	aspect-ratio: 1;
	object-fit: cover;
	border-radius: 9px;
	background: rgba(255, 255, 255, 0.12);
}
.mini-name { font-size: 11.5px; font-weight: 900; line-height: 1.15; overflow-wrap: anywhere; }
.mini-rarity {
	align-self: center;
	padding: 4px 10px;
	font-size: 10px;
	font-weight: 900;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	background: rgba(0, 0, 0, 0.35);
	border-radius: 999px;
}
.mini-add {
	align-items: center;
	justify-content: center;
	color: var(--teal-ink);
	background: #effafa;
	border: 2px dashed rgba(74, 173, 179, 0.5);
}
.mini-add .icon { width: 26px; height: 26px; }

.rarity-common { background: linear-gradient(180deg, rgba(31, 111, 165, 0.75), #172d4a); }
.rarity-rare { background: linear-gradient(180deg, rgba(125, 225, 212, 0.8), #172d4a); border-color: rgba(125, 225, 212, 0.9); }
.rarity-epic { background: linear-gradient(180deg, rgba(121, 175, 209, 0.85), rgba(31, 111, 165, 0.8), #172d4a); border-color: rgba(121, 175, 209, 0.9); }
.rarity-legendary { background: linear-gradient(180deg, rgba(255, 225, 106, 0.85), rgba(125, 225, 212, 0.35), #172d4a); border-color: rgba(255, 225, 106, 0.95); }
.rarity-mythic { background: linear-gradient(180deg, rgba(248, 157, 50, 0.9), rgba(255, 225, 106, 0.35), #172d4a); border-color: rgba(248, 157, 50, 0.95); }

.suit-top { display: grid; grid-template-columns: 150px 1fr; gap: 14px; align-items: start; }
.mini-card.is-big { cursor: default; padding: 8px 8px 10px; border-radius: 18px; box-shadow: 0 12px 28px rgba(13, 31, 48, 0.25); }
.mini-card.is-big:hover { transform: none; }
.mini-card.is-big .mini-name { font-size: 14px; }
.suit-photos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.rarity-pick { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.rarity-pick button {
	min-height: 42px;
	padding: 0 4px;
	font: inherit;
	font-size: 11.5px;
	font-weight: 900;
	text-transform: capitalize;
	color: #fff;
	border: 2px solid transparent;
	border-radius: 12px;
	cursor: pointer;
	opacity: 0.55;
	transition: opacity 0.2s, transform 0.25s var(--spring);
}
.rarity-pick button:hover { opacity: 0.85; }
.rarity-pick button.is-on { opacity: 1; transform: translateY(-2px); box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--navy); }

/* =========================================================
DIALOGS, TOASTS
========================================================= */

.modal-backdrop {
	position: fixed;
	inset: 0;
	z-index: 100;
	display: grid;
	place-items: center;
	padding: 16px;
	background: rgba(6, 16, 30, 0.6);
	backdrop-filter: blur(6px);
	animation: fade 0.2s ease;
}
.modal-backdrop.is-leaving { opacity: 0; transition: opacity 0.15s; }
@keyframes fade { from { opacity: 0; } }

.modal {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 18px;
	width: min(100%, 480px);
	max-height: calc(100vh - 32px);
	padding: 28px;
	overflow-y: auto;
	background: var(--paper);
	border-radius: 28px;
	box-shadow: var(--shadow-sheet);
	animation: pop 0.3s var(--spring);
}
.modal.is-wide { width: min(100%, 720px); }
.modal-title { padding-right: 40px; font-size: 26px; font-weight: 900; }
.modal-body { display: flex; flex-direction: column; gap: 14px; font-size: 15px; }
.modal-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; }
.modal-x {
	position: absolute;
	top: 18px;
	right: 18px;
	display: grid;
	place-items: center;
	width: 38px;
	height: 38px;
	color: var(--navy);
	background: #e3f1f7;
	border: 0;
	border-radius: 50%;
	cursor: pointer;
}
.modal-x:hover { background: #d3e9f2; }

.divider { display: flex; align-items: center; gap: 12px; margin: 6px 0; font-size: 13px; font-weight: 700; color: var(--muted); }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line-strong); }

.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.photo-pick {
	padding: 0;
	aspect-ratio: 1;
	overflow: hidden;
	background: #e3f1f7;
	border: 3px solid transparent;
	border-radius: 14px;
	cursor: pointer;
	transition: border-color 0.15s, transform 0.25s var(--spring);
}
.photo-pick:hover { border-color: var(--orange); transform: scale(1.04); }
.photo-pick img { width: 100%; height: 100%; object-fit: cover; }

.image-preview { display: grid; place-items: center; padding: 12px; background: #e3f1f7; border-radius: 18px; }
.image-preview img { max-height: 280px; border-radius: 10px; }

.steps { display: flex; flex-direction: column; gap: 10px; margin: 0; padding-left: 22px; }
.steps li::marker { font-weight: 900; color: var(--orange); }

.help-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.help-item { display: flex; gap: 14px; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: 18px; }
.help-item h3 { margin-bottom: 4px; font-size: 16px; font-weight: 900; }
.help-item p { font-size: 14px; color: var(--muted); }
.help-n {
	display: grid;
	place-items: center;
	flex: 0 0 34px;
	height: 34px;
	font-weight: 900;
	color: var(--navy);
	background: var(--gradient);
	border-radius: 50%;
}

.history-list { display: flex; flex-direction: column; gap: 8px; }
.history-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 14px;
	padding: 12px 14px;
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 16px;
}
.history-what { font-weight: 800; }

.toast {
	position: fixed;
	left: 50%;
	bottom: 86px;
	z-index: 200;
	max-width: calc(100% - 32px);
	padding: 13px 22px;
	font-weight: 800;
	color: #fff;
	background: var(--navy);
	border-radius: 999px;
	box-shadow: 0 16px 40px rgba(2, 8, 20, 0.4);
	transform: translateX(-50%);
	animation: rise 0.35s var(--spring);
	transition: opacity 0.3s, transform 0.3s;
}
.toast.is-ok { color: var(--navy); background: var(--gradient); }
.toast.is-error { background: var(--danger); }
.toast.is-leaving { opacity: 0; transform: translate(-50%, 10px); }

/* =========================================================
SMALL SCREENS
========================================================= */

@media (max-width: 900px) {
	.connect-options { grid-template-columns: 1fr; }
	.topbar {
		flex-wrap: wrap;
		gap: 8px;
		border-radius: 28px;
		padding: 10px;
	}
	.brand img { width: 46px; height: 46px; }
	.tabs { order: 3; flex: 1 0 100%; }
	.topbar-actions { margin-left: auto; }
	.help-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
	body { font-size: 14px; }
	.topbar, .sheet { width: calc(100% - 16px); }
	.sheet { margin-top: 10px; padding: 14px; border-radius: 24px; }
	.chip-status > span:nth-child(2) { font-size: 0; }
	.chip-status > span:nth-child(2) b { font-size: 13px; text-transform: capitalize; }
	.editor-tools .seg { display: none; }
	.chip-status { padding: 0 12px; }
	.how { display: none; }
	.page-frame { height: calc(100vh - 250px); min-height: 440px; }
	.frame-wrap.is-phone { border-width: 0; border-radius: var(--radius-md); max-width: none; }
	.suit-top { grid-template-columns: 1fr; }
	.suit-top .suit-preview { max-width: 160px; margin: 0 auto; }
	.modal { padding: 22px; border-radius: 24px; }
	.unsaved-bar { bottom: 12px; padding-left: 14px; }
	.history-row { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Rarity buttons: solid colours so the label stays readable */
.rarity-pick .rarity-common { background: #1f6fa5; }
.rarity-pick .rarity-rare { background: #2b9c93; }
.rarity-pick .rarity-epic { background: #4f7fb0; }
.rarity-pick .rarity-legendary { background: #f5c93a; color: var(--navy); }
.rarity-pick .rarity-mythic { background: #f08a1c; color: var(--navy); }

/* Login */
.login-card { width: min(100%, 460px); }
.login-form { margin-top: 28px; text-align: left; }
.login-form h2 { font-size: 21px; font-weight: 900; }
.code-input { font-size: 24px; letter-spacing: 0.3em; text-align: center; font-variant-numeric: tabular-nums; }
.qr { display: grid; place-items: center; padding: 12px; background: #fff; border-radius: var(--radius-md); }
.qr img { width: 200px; height: 200px; image-rendering: pixelated; }
.secret { margin-top: 8px; font-family: ui-monospace, Consolas, monospace; font-size: 15px; word-break: break-all; user-select: all; }
.pending-chip { white-space: nowrap; }
