/* Portál Můj klub — mobilní layout (členové a zástupci). Barva klubu v --brand (atribut body). */
:root {
	--brand: #1357c3;
	--ink: #14213d;
	--muted: #5f6b7a;
	--line: #e3e8ef;
	--bg: #f4f6fa;
	--card: #ffffff;
	--danger: #c62828;
	--success: #2e7d32;
	--warning: #b26a00;
	--radius: 12px;
}

* { box-sizing: border-box; }

body {
	margin: 0;
	font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	color: var(--ink);
	background: var(--bg);
	line-height: 1.45;
}

a { color: var(--brand); }

.portal-header {
	background: var(--brand);
	color: #fff;
	padding: 12px 16px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 16px;
}

.portal-brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; }
.portal-brand small { display: block; font-size: 12px; opacity: .85; }
.portal-logo { width: 40px; height: 40px; object-fit: contain; background: #fff; border-radius: 8px; padding: 3px; }

.portal-nav { display: flex; gap: 4px; }
.portal-nav a { color: #fff; text-decoration: none; padding: 6px 10px; border-radius: 8px; font-size: 15px; }
.portal-nav a.active, .portal-nav a:hover { background: rgba(255, 255, 255, .18); }

.portal-main { max-width: 720px; margin: 0 auto; padding: 16px; }
.portal-main h1 { font-size: 22px; margin: 8px 0 16px; }
.portal-main h2 { font-size: 18px; margin: 0 0 12px; }

.portal-card {
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	padding: 16px;
	margin-bottom: 16px;
}

.portal-card-narrow { max-width: 420px; margin: 24px auto; }

.portal-muted { color: var(--muted); font-size: 14px; }

.portal-member { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.portal-member + .portal-member { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 12px; }
.portal-badge { display: inline-block; font-size: 12px; padding: 2px 8px; border-radius: 999px; background: var(--bg); color: var(--muted); }

.portal-alert { padding: 10px 14px; border-radius: 10px; margin-bottom: 12px; background: #e8f0fe; }
.portal-alert-success { background: #e7f5e9; color: var(--success); }
.portal-alert-warning, .portal-alert-info { background: #fff4e0; color: var(--warning); }
.portal-alert-danger, .portal-alert-error { background: #fdecea; color: var(--danger); }

.portal-field { margin-bottom: 14px; }
.portal-field label { display: block; font-weight: 600; margin-bottom: 4px; }
.portal-field input[type=text], .portal-field input[type=email], .portal-field input[type=password], .portal-field input[type=tel] {
	width: 100%;
	font-size: 16px; /* bez zoomu na iOS */
	padding: 10px 12px;
	border: 1px solid var(--line);
	border-radius: 10px;
	background: #fff;
}
.portal-field input:focus { outline: 2px solid var(--brand); outline-offset: 1px; }
.portal-field .error { color: var(--danger); font-size: 14px; margin-top: 4px; }
.portal-check { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }

.portal-btn {
	display: inline-block;
	width: 100%;
	font-size: 16px;
	font-weight: 600;
	padding: 12px 16px;
	border: 0;
	border-radius: 10px;
	background: var(--brand);
	color: #fff;
	cursor: pointer;
	text-align: center;
	text-decoration: none;
}
.portal-btn-secondary { background: #fff; color: var(--brand); border: 1px solid var(--brand); }
.portal-btn-small { width: auto; font-size: 14px; padding: 6px 12px; }

.portal-links { text-align: center; margin-top: 12px; font-size: 14px; }

dl.portal-dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
dl.portal-dl dt { color: var(--muted); }
dl.portal-dl dd { margin: 0; overflow-wrap: anywhere; }

.portal-footer { text-align: center; color: var(--muted); font-size: 13px; padding: 24px 16px; }

@media (max-width: 480px) {
	.portal-nav { width: 100%; flex-wrap: wrap; row-gap: 2px; }
	.portal-nav a { padding: 6px 7px; font-size: 14px; white-space: nowrap; }
	dl.portal-dl { grid-template-columns: 1fr; }
	dl.portal-dl dd { margin-bottom: 8px; }
}

/* Příspěvky */
.portal-fee + .portal-fee { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 16px; }
.portal-fee-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; margin-bottom: 8px; }
.portal-fee-amount { font-size: 18px; font-weight: 700; white-space: nowrap; }
.portal-fee-overdue .portal-fee-amount { color: var(--danger); }
.portal-fee-pay { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.portal-qr { border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.portal-summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; }

/* Statistiky hráče */
.portal-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; text-align: center; }
.portal-stats strong { display: block; font-size: 22px; }
.portal-stats span { color: var(--muted); font-size: 13px; }

/* Události */
.portal-section { font-size: 18px; margin: 24px 0 12px; }
.portal-event-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 8px; }
.portal-event-head h3 { margin: 4px 0; font-size: 17px; }
.portal-event-head h3 a { color: var(--ink); text-decoration: none; }
.portal-event-date { min-width: 52px; text-align: center; background: var(--brand); color: #fff; border-radius: 10px; padding: 6px 4px; line-height: 1.1; }
.portal-event-date strong { display: block; font-size: 20px; }
.portal-event-date span { font-size: 13px; }
.portal-response { border-top: 1px solid var(--line); padding-top: 10px; margin-top: 10px; }
.portal-response-head { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 8px; }
.portal-response-buttons { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-start; }
.portal-response-form details { flex: 1 1 200px; }
.portal-response-form details[open] { flex-basis: 100%; }
.portal-response-form summary { list-style: none; display: inline-block; }
.portal-response-form summary::-webkit-details-marker { display: none; }
.portal-response-form details .portal-field { margin-top: 10px; }
.portal-response-form select { width: 100%; font-size: 16px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.portal-btn-attend { background: var(--success); }
.portal-btn-decline { background: var(--danger); }
.portal-badge-attending { background: #e7f5e9; color: var(--success); }
.portal-badge-maybe { background: #fff4e0; color: var(--warning); }
.portal-badge-declined { background: #fdecea; color: var(--danger); }
.portal-badge-pending { background: #eef1f6; color: var(--muted); }
.portal-table { width: 100%; border-collapse: collapse; margin-bottom: 12px; }
.portal-table td { border-top: 1px solid var(--line); padding: 8px 4px; vertical-align: top; }
.portal-table select { font-size: 15px; padding: 6px; border: 1px solid var(--line); border-radius: 8px; }
.portal-field select, .portal-field textarea, .portal-field input[type=date], .portal-field input[type=time], .portal-field input[type=datetime-local] {
	width: 100%; font-size: 16px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff;
}
.portal-field select[multiple] { min-height: 90px; }

.portal-days { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.portal-days label { display: inline-flex; gap: 6px; align-items: center; font-weight: normal; }

[hidden] { display: none !important; }

/* Rezervace — přehled slotů dne */
.portal-slots { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 8px; }
.portal-slot { font-size: 12px; padding: 3px 6px; border-radius: 6px; }
.portal-slot-free { background: #e7f5e9; color: var(--success); }
.portal-slot-busy { background: #eef1f6; color: var(--muted); text-decoration: line-through; }
