/*
Theme Name: TM Recycling Light
Theme URI: https://tmrecycling.lv
Description: Lightweight theme for TM Recycling plugin
Version: 1.0.2
Author: TM Recycling
Text Domain: tmrecycling-light
Domain Path: /languages
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/

:root {
	--color-primary: #1e40af;
	--color-text: #1f2937;
	--color-text-light: #6b7280;
	--color-bg: #ffffff;
	--color-bg-light: #f9fafb;
	--color-border: #e5e7eb;
	--spacing-unit: 1rem;
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html {
	font-size: 16px;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

body {
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	color: var(--color-text);
	background-color: var(--color-bg);
	line-height: 1.6;
}

main {
	min-height: 60vh;
}

.site-content {
	width: 100%;
}

.site-content > * {
	width: 100%;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
	font-weight: 600;
	line-height: 1.2;
	margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.125rem; }
h6 { font-size: 1rem; }

/* Paragraphs and text */
p {
	margin-bottom: 1rem;
}

a {
	color: var(--color-primary);
	text-decoration: none;
	transition: color 0.2s ease;
}

a:hover {
	text-decoration: underline;
}

/* Buttons
   Scoped to the .button class and real submit buttons only.
   A bare `button` rule would hijack the color/background of every
   plugin button (e.g. the services menu), so we intentionally avoid it. */
.button,
button[type="submit"],
input[type="submit"] {
	display: inline-block;
	padding: 0.75rem 1.5rem;
	background-color: var(--color-primary);
	color: white;
	border: none;
	border-radius: 0.375rem;
	font-size: 1rem;
	cursor: pointer;
	transition: background-color 0.2s ease;
}

.button:hover,
button[type="submit"]:hover,
input[type="submit"]:hover {
	background-color: #1e3a8a;
	text-decoration: none;
}

/* Forms */
input, textarea, select {
	width: 100%;
	padding: 0.75rem;
	border: 1px solid var(--color-border);
	border-radius: 0.375rem;
	font-family: inherit;
	font-size: 1rem;
	margin-bottom: 1rem;
}

input:focus, textarea:focus, select:focus {
	outline: none;
	border-color: var(--color-primary);
	box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

/* Images */
img {
	max-width: 100%;
	height: auto;
	display: block;
}

/* Lists */
ul, ol {
	margin-left: 1.5rem;
	margin-bottom: 1rem;
}

li {
	margin-bottom: 0.5rem;
}

/* Utilities */
.container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 1rem;
}

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

/* Responsive */
@media (max-width: 768px) {
	html {
		font-size: 14px;
	}

	h1 { font-size: 1.75rem; }
	h2 { font-size: 1.5rem; }
	h3 { font-size: 1.25rem; }
}

/* Safeguard: ensure the plugin footer/header are always visible,
   in case another theme or plugin tries to hide them. */
.tm-site-footer,
.tm-site-header {
	display: block !important;
}

/* Single post layout */
.tm-post__inner {
	max-width: 820px;
	margin: 0 auto;
	padding: 48px 24px 64px;
}

.tm-post__header {
	margin-bottom: 28px;
}

.tm-post__title {
	margin: 0 0 12px;
	font-size: clamp(28px, 4vw, 44px);
	font-weight: 800;
	line-height: 1.15;
	color: #111;
}

.tm-post__date {
	margin: 0;
	color: #8a8784;
	font-size: 14px;
}

.tm-post__featured {
	margin: 0 0 32px;
}

.tm-post__featured img {
	width: 100%;
	height: auto;
	border-radius: 14px;
}

.tm-post__content {
	font-size: 17px;
	line-height: 1.75;
	color: #2b2926;
}

.tm-post__content > *:first-child {
	margin-top: 0;
}

.tm-post__content h2 {
	margin: 2rem 0 1rem;
	font-size: 1.6rem;
}

.tm-post__content h3 {
	margin: 1.6rem 0 0.8rem;
	font-size: 1.3rem;
}

.tm-post__content p {
	margin: 0 0 1.25rem;
}

.tm-post__content img {
	max-width: 100%;
	height: auto;
	border-radius: 10px;
	margin: 1.5rem 0;
}

.tm-post__content ul,
.tm-post__content ol {
	margin: 0 0 1.25rem 1.5rem;
}

.tm-post__content a {
	color: #d94b0a;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.tm-post__back {
	margin: 40px 0 0;
}

.tm-post__back a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: #d94b0a;
	font-weight: 700;
	text-decoration: none;
}

.tm-post__back a:hover {
	text-decoration: underline;
}

