/* ====================================================
   Layout shell
   ==================================================== */
.app {
	min-height: 100vh;
	padding-bottom: calc(var(--tab-bar-height) + var(--safe-bottom) + 12px);
}

/* ---- Big hero header (Home only) ---- */
.header-hero {
	padding: calc(18px + var(--safe-top)) 24px 64px;
	background: linear-gradient(180deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
	color: #fff;
	text-align: center;
	border-radius: 0 0 28px 28px;
}
.header-hero h1 {
	font-size: 34px;
	font-weight: 800;
	letter-spacing: 0.5px;
	margin-bottom: 6px;
}
.header-hero .subtitle {
	font-size: 16px;
	opacity: 0.92;
	margin-bottom: 18px;
}
.header-hero .meta {
	display: flex;
	flex-direction: column;
	gap: 6px;
	align-items: center;
	font-size: 15px;
	opacity: 0.95;
}
.header-hero .meta span { display: inline-flex; align-items: center; gap: 8px; }

/* ---- Small bar header (inner pages) ---- */
.header-bar {
	padding: calc(14px + var(--safe-top)) 20px 16px;
	background: linear-gradient(180deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
	color: #fff;
	text-align: center;
	position: sticky;
	top: 0;
	z-index: 20;
}
.header-bar h1 { font-size: 19px; font-weight: 700; margin: 0; }

/* ====================================================
   Cards
   ==================================================== */
.card {
	background: var(--color-card);
	border-radius: var(--radius-lg);
	box-shadow: var(--shadow-card);
	padding: 22px;
	margin: -42px 16px 0;
	position: relative;
	z-index: 2;
}
.card h2 { font-size: 20px; font-weight: 800; }
.card p.muted { color: var(--color-text-muted); font-size: 15px; margin: 0; }

.section-title {
	font-size: 19px;
	font-weight: 800;
	margin: 28px 20px 12px;
}

.qa-list { display: flex; flex-direction: column; gap: 12px; margin: 0 16px; }
.qa-card {
	display: flex;
	align-items: center;
	gap: 14px;
	background: var(--color-card);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	padding: 14px 16px;
}
.qa-icon {
	width: 46px; height: 46px;
	border-radius: 50%;
	background: var(--color-icon-bg);
	display: flex; align-items: center; justify-content: center;
	flex-shrink: 0;
	color: var(--color-primary);
}
.qa-icon svg { width: 22px; height: 22px; }
.qa-text { flex: 1; }
.qa-text strong { display: block; font-size: 16px; font-weight: 700; }
.qa-text span { font-size: 13.5px; color: var(--color-text-muted); }
.qa-chev { color: #c2c8d6; flex-shrink: 0; }

.stats-row {
	display: flex;
	justify-content: space-around;
	background: var(--color-card);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	margin: 22px 16px 0;
	padding: 20px 8px;
}
.stat { text-align: center; }
.stat strong { display: block; font-size: 26px; font-weight: 800; color: var(--color-primary); }
.stat span { font-size: 13px; color: var(--color-text-muted); }

.footer-org {
	text-align: center;
	color: var(--color-text-muted);
	font-size: 13px;
	margin: 22px 24px 10px;
	line-height: 1.5;
}

/* ====================================================
   Bottom tab bar
   ==================================================== */
.bottom-nav {
	position: fixed;
	left: 0; right: 0; bottom: 0;
	height: calc(var(--tab-bar-height) + var(--safe-bottom));
	background: #fff;
	box-shadow: var(--shadow-nav);
	display: flex;
	z-index: 50;
	padding-bottom: var(--safe-bottom);
	border-top: 1px solid var(--color-border);
}
.bottom-nav a {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 3px;
	font-size: 11.5px;
	color: #8a90a0;
}
.bottom-nav a svg { width: 23px; height: 23px; }
.bottom-nav a.active { color: var(--color-primary); }

/* ====================================================
   Day toggle tabs (Schedule)
   ==================================================== */
.day-tabs {
	display: flex;
	background: #fff;
	border-bottom: 1px solid var(--color-border);
	position: sticky;
	top: 0;
	z-index: 19;
}
.day-tabs button {
	flex: 1;
	background: none;
	border: none;
	padding: 14px 0 12px;
	text-align: center;
	color: var(--color-text-muted);
	font-weight: 600;
	font-size: 14px;
	cursor: pointer;
	border-bottom: 3px solid transparent;
}
.day-tabs button .d { display:block; font-size: 15px; }
.day-tabs button.active {
	color: var(--color-primary);
	border-bottom-color: var(--color-primary);
}

/* ====================================================
   Session accordion
   ==================================================== */
.session-list { padding: 14px 16px 4px; }
.session-item {
	background: var(--color-card);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	margin-bottom: 12px;
	overflow: hidden;
}
.session-head {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	padding: 14px 16px;
	cursor: pointer;
}
.session-time {
	flex-shrink: 0;
	width: 64px;
	font-weight: 700;
	font-size: 13.5px;
	color: var(--color-primary);
	padding-top: 2px;
}
.session-time small { display: block; color: var(--color-text-muted); font-weight: 500; }
.session-main { flex: 1; }
.session-main h3 { font-size: 15.5px; font-weight: 700; margin: 0 0 4px; }
.session-room { font-size: 13px; color: var(--color-text-muted); }
.session-people { font-size: 12.5px; color: var(--color-text-muted); margin-top: 4px; }

.fav-btn {
	flex-shrink: 0;
	background: none; border: none; cursor: pointer;
	color: #c2c8d6; padding: 2px;
}
.fav-btn svg { width: 21px; height: 21px; }
.fav-btn.active { color: var(--color-primary); }
.fav-btn.active svg { fill: var(--color-primary); }

.chev-toggle { flex-shrink: 0; color: #c2c8d6; transition: transform .2s; margin-top: 4px; }
.session-item.open .chev-toggle { transform: rotate(180deg); }

.session-body {
	display: none;
	padding: 0 16px 16px 92px;
	font-size: 14px;
	color: var(--color-text);
}
.session-item.open .session-body { display: block; }
.session-body h4 { font-size: 13.5px; font-weight: 700; color: var(--color-primary); margin: 12px 0 4px; }
.session-body h4:first-child { margin-top: 0; }
.session-body p { font-size: 13.5px; margin: 0 0 6px; color: #3c4356; }

.badge {
	display: inline-block;
	font-size: 11px;
	font-weight: 700;
	padding: 3px 9px;
	border-radius: 20px;
	background: var(--color-icon-bg);
	color: var(--color-primary);
	margin-bottom: 4px;
}
.badge.break { background: #eef0f4; color: #6b7280; }
.badge.award { background: #fdeccd; color: #9a6308; }

/* ====================================================
   Speakers
   ==================================================== */
.search-bar-wrap { padding: 14px 16px 4px; }
.search-bar {
	display: flex;
	align-items: center;
	gap: 8px;
	background: #fff;
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	padding: 12px 16px;
}
.search-bar svg { width: 18px; height: 18px; color: var(--color-text-muted); flex-shrink: 0; }
.search-bar input {
	border: none; outline: none; flex: 1; font-size: 15px; background: none; color: var(--color-text);
}
.search-bar input::placeholder { color: #9aa1b1; }

.speaker-list { padding: 6px 16px 4px; }
.speaker-item {
	display: flex;
	align-items: center;
	gap: 14px;
	background: var(--color-card);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	margin-bottom: 10px;
	padding: 12px 14px;
}
.speaker-avatar {
	width: 48px; height: 48px;
	border-radius: 50%;
	background: var(--color-icon-bg);
	color: var(--color-primary);
	display: flex; align-items: center; justify-content: center;
	font-weight: 700; font-size: 16px;
	flex-shrink: 0;
	overflow: hidden;
}
.speaker-avatar img { width: 100%; height: 100%; object-fit: cover; }
.speaker-info { flex: 1; }
.speaker-info strong { display: block; font-size: 15.5px; font-weight: 700; }
.speaker-info span { font-size: 13px; color: var(--color-text-muted); }
.speaker-role {
	font-size: 11px; font-weight: 700; color: var(--color-primary);
	background: var(--color-icon-bg); padding: 3px 8px; border-radius: 20px; flex-shrink: 0;
}
.no-results { text-align: center; color: var(--color-text-muted); padding: 40px 20px; font-size: 14px; }

/* ====================================================
   Venue / practical info
   ==================================================== */
.info-block { padding: 6px 16px 4px; }
.info-card {
	background: var(--color-card);
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	padding: 16px;
	margin-bottom: 12px;
}
.info-card h3 { font-size: 15px; font-weight: 800; margin-bottom: 8px; display:flex; align-items:center; gap:8px; }
.info-card h3 svg { width: 18px; height: 18px; color: var(--color-primary); }
.info-card p { font-size: 14px; color: #3c4356; margin: 0 0 4px; }
.info-card .wifi-pass { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--color-bg); padding: 6px 10px; border-radius: 8px; display:inline-block; margin-top:4px; }

.map-wrap { overflow: auto; border-radius: var(--radius-md); }
.map-wrap img { width: 100%; }

.partner-tier { margin-bottom: 14px; }
.partner-tier h4 { font-size: 12.5px; text-transform: uppercase; letter-spacing: 1px; color: var(--color-text-muted); margin-bottom: 8px; }
.partner-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.partner-grid .logo {
	background: #fff; border-radius: 12px; box-shadow: var(--shadow-card);
	padding: 12px 16px; font-size: 13px; font-weight: 600; color: var(--color-text-muted);
	flex: 1 1 auto; text-align: center;
}

/* ====================================================
   Empty states
   ==================================================== */
.empty-state {
	text-align: center;
	padding: 70px 30px;
	color: var(--color-text-muted);
}
.empty-state svg { width: 56px; height: 56px; color: #c2c8d6; margin-bottom: 16px; }
.empty-state h3 { font-size: 18px; font-weight: 700; color: var(--color-text); margin-bottom: 6px; }
.empty-state p { font-size: 14px; }

/* ====================================================
   Offline banner
   ==================================================== */
.offline-banner {
	display: none;
	background: #fff3cd;
	color: #8a6105;
	text-align: center;
	font-size: 13px;
	padding: 8px 12px;
	position: sticky; top: 0; z-index: 30;
}
body.is-offline .offline-banner { display: block; }

/* ====================================================
   Responsive: keep it phone-shaped even on desktop browsers
   ==================================================== */
@media (min-width: 560px) {
	body { background: #dde3ee; }
	.app {
		max-width: 480px;
		margin: 0 auto;
		background: var(--color-bg);
		min-height: 100vh;
		box-shadow: 0 0 40px rgba(0,0,0,0.08);
	}
	.bottom-nav { max-width: 480px; margin: 0 auto; left: 50%; transform: translateX(-50%); }
}

/* ====================================================
   Sponsors page
   ==================================================== */
.sponsors-wrap { padding: 8px 16px calc(var(--tab-bar-height) + var(--safe-bottom) + 20px); }

.sponsor-tier { margin-top: 22px; }
.sponsor-tier:first-child { margin-top: 14px; }

.tier-heading {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	margin-bottom: 14px;
}
.tier-heading::before,
.tier-heading::after {
	content: "";
	height: 2px;
	flex: 1;
	max-width: 70px;
	border-radius: 2px;
	background: currentColor;
	opacity: 0.35;
}
.tier-label {
	font-size: 15px;
	font-weight: 800;
	letter-spacing: 2px;
}
.tier-platinum { color: #5b6573; }
.tier-gold     { color: #b8860b; }
.tier-silver   { color: #8a93a3; }

.logo-grid {
	display: grid;
	gap: 12px;
	width: 100%;
	/* Responsive: as many logos per row as comfortably fit, no fixed count.
	   minmax(0, ...) is what stops wide logos from blowing out the row. */
	grid-template-columns: repeat(auto-fit, minmax(min(140px, 100%), 1fr));
}
/* Platinum & Gold logos are bigger / fewer, so give them more room per cell */
.logo-grid-platinum { grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr)); }
.logo-grid-gold     { grid-template-columns: repeat(auto-fit, minmax(min(160px, 100%), 1fr)); }
.logo-grid-silver   { grid-template-columns: repeat(auto-fit, minmax(min(135px, 100%), 1fr)); }

.logo-card {
	background: #fff;
	border-radius: var(--radius-md);
	box-shadow: var(--shadow-card);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px 18px;
	min-width: 0;          /* allow the card to shrink inside the grid track */
	overflow: hidden;      /* never let contents spill past the card */
	min-height: 84px;
}
.logo-grid-silver .logo-card { min-height: 76px; padding: 14px 16px; }
.logo-grid-platinum .logo-card { min-height: 104px; padding: 22px 24px; }
.logo-card img {
	display: block;
	max-width: 100%;
	max-height: 56px;
	width: auto;
	height: auto;
	object-fit: contain;
}
.logo-grid-platinum .logo-card img { max-height: 64px; }
.logo-grid-silver .logo-card img { max-height: 48px; }

.tier-platinum .logo-card { box-shadow: 0 2px 16px rgba(20,33,61,0.10); }

/* ====================================================
   Six-tab bottom nav: tighten so labels fit on small phones
   ==================================================== */
.bottom-nav a { font-size: 10.5px; gap: 2px; }
.bottom-nav a svg { width: 21px; height: 21px; }
.bottom-nav a span { white-space: nowrap; }
@media (max-width: 360px) {
	.bottom-nav a { font-size: 9.5px; }
	.bottom-nav a svg { width: 19px; height: 19px; }
}
