/* base.css */
html,
body {
	height: 100%;
	margin: 0;
	font-family: sans-serif;
	background: var(--bg-header);
	color: var(--text);
}

a {
	color: var(--link);
	text-decoration: underline;
}

a:visited {
	color: var(--link-visited);
}

a:hover {
	text-decoration: underline wavy;
}

/* textarea{
	field-sizing: content;
} */
textarea::placeholder {
	color: var(--placeholder);
}
#app-container {
	position: relative;
	max-width: 600px;
	width: 100%;
	margin: 0 auto;
	display: flex;
	flex-direction: column;
	height: calc(var(--app-vh, 1vh) * 100);
	background-image: linear-gradient(to right, var(--gradient-start), var(--gradient-end));
}

/* Если браузер поддерживает динамические единицы — используем их */
@supports (height: 100dvh) {
	#app-container {
		height: 100dvh;
	}
}

/* (на всякий случай) Другой вариант динамики */
@supports (height: 100svh) {
	#app-container {
		height: 100svh;
	}
}

header {
	text-align: center;
	margin: 0;
	padding: 1rem 0;
	position: sticky;
	padding: 10px;
	background: var(--bg-header);
	display: block;
	height: 50px;
	top: 0;
	border-bottom: 1px solid var(--border);
	z-index: 3;
}
.header {
	display: flex;
	height: 50px;
	align-items: center;
	justify-content: space-between;
}

footer {
	position: sticky;
	padding: 10px;
	bottom: 0;
}

header h3,
header p {
	margin: 0;
	line-height: 1.2;
}

main {
	display: block;
	flex-direction: column;
	flex: 1 1 auto;
	overflow-y: auto;
}

/* Lightbox - общий для всех страниц */
.lightbox {
	position: fixed;
	z-index: 10;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: var(--overlay);
	display: flex;
	justify-content: center;
	align-items: center;
}

.lightbox-content {
	max-width: 90%;
	max-height: 90%;
	border-radius: 10px;
}

.lightbox .close {
	position: absolute;
	top: 20px;
	right: 30px;
	color: var(--text-inverted);
	cursor: pointer;
}

.author-wrapper {
	overflow: hidden;
	word-break: break-word;
	white-space: normal;
}

.author-name {
	font-weight: bold;
	align-self: flex-end;
	font-size: x-small;
	padding-right: 2rem;
}

.btn {
	display: flex;
	flex-shrink: 0;
	justify-content: center;
	width: 30px;
	height: 30px;
	align-items: center;
	justify-self: center;
	cursor: pointer;
	border-radius: 50%;
	transition: 0.2s ease;
}

.btn:hover {
	scale: 1.1;
	background: var(--hover-button);
	border-radius: 50%;
}
