/*
Theme Name: enrich base CandP
Theme URI: https://www.enrichdesign.co.uk/
Description: A simple, responsive WordPress theme.
Version: 2.0.0
Requires at least: 6.3
Tested up to: 6.8
Requires PHP: 7.4
Author: Richard Nicholls - www.enrichdesign.co.uk
Author URI: https://www.enrichdesign.co.uk/
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: enrichbase
Tags: custom-menu, custom-logo, featured-images, threaded-comments, translation-ready, left-sidebar, two-columns
*/

/* ==========================================================================
   Base
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

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

html, body, form,
h1, h2, h3, h4, h5, h6,
p, img, a { margin: 0; padding: 0; border: 0; }

body {
	font-family: 'Playfair Display', Georgia, serif;
	font-weight: 400;
	font-size: 1.05em;
	color: #444;
	line-height: 1.5;
	background-color: #f8f8f8;
	background-image: url('images/paper-bkgrd.jpg');
	overflow-wrap: break-word;
}

p { margin-bottom: 0.6em; }

img, video, iframe, embed, object { max-width: 100%; }
img { height: auto; }

ul { margin: 0 0 10px; }
li { list-style-type: none; text-decoration: none; break-inside: avoid; }

h1 { font-size: 2em; line-height: 1.2; color: #00308f; padding: 10px 0; }
h2 { font-size: 1.1em; line-height: 1.2; color: #ac0233; padding: 10px 0; }
h3 { font-size: 1em; color: #00308f; padding: 0 0 0 25px; }
h4, h5 { font-size: 0.8em; padding: 10px 0; }

a { color: #00308f; }
a:hover { text-decoration: underline; color: #ac0233; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
	outline: 2px solid #ac0233;
	outline-offset: 2px;
}

em { font-style: italic; }
blockquote { margin: 1em 1.5em; font-style: italic; }

/* ==========================================================================
   Layout
   ========================================================================== */

#top { margin: 0 auto; }

.contentwidth {
	width: 100%;
	max-width: 1000px;
	margin: 0 auto;
	padding: 0 15px;
}

#header { margin: 20px 0 10px; }
#header .contentwidth {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 10px 20px;
}

#logo { flex: 0 1 460px; }
#logo img { display: block; max-width: 100%; height: auto; }

.content-grid { display: block; }
.has-sidebar .content-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 230px;
	gap: 0 30px;
}

/* Pages put the sidebar on the left. */
.sidebar-left.has-sidebar .content-grid { grid-template-columns: 230px minmax(0, 1fr); }
.sidebar-left.has-sidebar .site-main { grid-column: 2; grid-row: 1; }
.sidebar-left.has-sidebar .widget-area { grid-column: 1; grid-row: 1; }

.site-main { min-width: 0; }

/* ==========================================================================
   Navigation
   ========================================================================== */

.main-navigation ul { list-style: none; margin: 0; padding: 0; }

.main-navigation .menu,
.main-navigation .nav-menu {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
}

.main-navigation li { position: relative; list-style: none; }

.main-navigation a {
	display: block;
	line-height: 2em;
	padding: 12px 8px 0;
	border-bottom: 1.5px solid #00308f;
	text-decoration: none;
}

.main-navigation a:hover,
.main-navigation a:focus { color: #ac0233; border-bottom-color: #ac0233; text-decoration: none; }

.main-navigation .current-menu-item > a,
.main-navigation .current-menu-ancestor > a,
.main-navigation .current_page_item > a { color: #ac0233; }

.main-navigation ul ul {
	position: absolute;
	top: 100%;
	left: -9999px;
	z-index: 99;
	min-width: 12em;
	background: #f8f8f8;
	border: 1.5px solid #00308f;
	border-top: 0;
}
.main-navigation ul ul a { padding: 6px 10px; border-bottom: 0; line-height: 1.4; }
.main-navigation ul ul ul { top: 0; }

.main-navigation li:hover > ul,
.main-navigation li:focus-within > ul { left: 0; }
.main-navigation ul ul li:hover > ul,
.main-navigation ul ul li:focus-within > ul { left: 100%; }

.menu-toggle {
	display: none;
	margin: 0;
	padding: 6px 16px;
	font: inherit;
	color: #00308f;
	background: #f8f8f8;
	border: 1.5px solid #00308f;
	cursor: pointer;
	float: right;
}

/* ==========================================================================
   Content
   ========================================================================== */

.entry { padding: 3px 0 10px; }

.entry-title { font-size: 2em; line-height: 1.2; color: #00308f; padding: 10px 0; }
.entry-title a { color: inherit; }
.entry-title a:hover { color: #ac0233; }

.entry-content::after { content: ""; display: table; clear: both; }

.entry img:not(.emoji):not(.wp-smiley) {
	border: 10px solid #f5f1e7;
	box-sizing: content-box;
	max-width: calc(100% - 20px);
}
.entry img.imgplain, .imgplain { border: none !important; max-width: 100%; }

.shadow {
	box-shadow: 0 0 5px 1px #ddd;
	-webkit-box-shadow: 0 0 5px 1px #ddd;
}

.page-header { margin-bottom: 10px; }

/* Category lists */
.archive-entry { margin-bottom: 20px; }
.archive-thumb { float: left; margin: 0 20px 10px 0; }
.archive-thumb img { display: block; width: 229px; max-width: 100%; height: auto; }
.archive-text { overflow: hidden; }
.archive-text h2 { padding-top: 0; }
.catlist, .front { font-size: 1.5em; line-height: 1.2; }
.catlist a, .catlist a:hover { color: inherit; text-decoration: none; }
.catsection { border-bottom: 1px solid #00308f; padding-bottom: 10px; }

.posts-navigation, .comments-navigation { margin: 1em 0; overflow: hidden; }
.posts-navigation .nav-previous, .comments-navigation .nav-previous { float: left; }
.posts-navigation .nav-next, .comments-navigation .nav-next { float: right; }

p.quote {
	color: #ac0233;
	font-size: 1.7em !important;
	line-height: 1.2;
	padding: 16px 0 10px;
}

.blue { color: #00308f !important; }

.subhead {
	text-align: center;
	margin-bottom: 20px;
	font-size: 1.2em;
	font-weight: 700;
}

.caption, .wp-caption-text, .gallery-caption {
	font-size: 120%;
	font-style: italic;
	line-height: 1.2;
	padding: 15px 5px;
}
.wp-caption { max-width: 100%; }

.twocolumntext {
	column-count: 2;
	column-gap: 20px;
	column-rule: none;
	margin-bottom: 10px;
}

tr { border-bottom: 15px solid #f8f8f8; }

/* Widgets */
.widget { margin-bottom: 1.5em; }
.widget p { font-size: 90%; padding-top: 18px; }
.widget a { color: #ac0233; }
.widget a:hover { text-decoration: underline; color: #00308f; }

.textwidget li {
	font-size: 1.4em;
	font-weight: 700;
	letter-spacing: 0.025em;
	padding-bottom: 5px;
}
.textwidget li a, .menu li a { text-decoration: none; }

/* Category Posts Widget plugin */
.cat-post-widget h3 {
	text-transform: uppercase;
	padding: 30px 0 10px 10px;
	color: #000;
}
.cat-post-widget h3 a, .cat-post-widget h3 a:hover { color: #000; text-decoration: none; }
.cat-post-item a, .cat-post-item a:hover {
	text-transform: uppercase;
	text-decoration: none;
	font-size: 90%;
	line-height: 1;
}
.cat-post-item p { padding: 10px 0; font-family: sans-serif; line-height: 1.2; }

/* ==========================================================================
   Forms
   ========================================================================== */

input, textarea, select, button { font: inherit; }

.standardForm input, .standardForm .textarea,
.entry-content input, .entry-content textarea,
.message-area, .formtextarea {
	background: #fff;
	border: 1px solid #aaa;
	font-family: Verdana, Geneva, sans-serif;
	font-size: 1.1em;
	padding: 3px;
}

.standardForm .textarea, .standardForm .textbox { width: 240px; max-width: 100%; padding: 3px; color: #444; }
.standardForm .textarea { height: 90px; }
.standardForm .textbox { margin: 0 0 5px; height: 20px; }
.standardForm .submit { padding: 4px; height: 30px; color: #555; }

#message { color: #990000; }

.wpcf7-form p { font-family: Verdana, Geneva, sans-serif; font-size: 0.8em; }
.wpcf7-form input[type="text"], .wpcf7-form input[type="email"], .wpcf7-form textarea { max-width: 100%; }

.wpcf7-submit {
	padding: 4px 12px !important;
	background: #eee !important;
	border-radius: 5px;
}

.search-form { display: flex; align-items: center; gap: 6px; max-width: 260px; }
.search-form .search-field {
	flex: 1 1 auto;
	min-width: 0;
	border: 0;
	border-bottom: 1px solid #444;
	border-radius: 0;
	background: #fff;
	padding: 5px 0;
	-webkit-appearance: none;
	appearance: none;
}
.search-form .search-submit {
	flex: 0 0 24px;
	width: 24px;
	height: 24px;
	padding: 0;
	border: 0;
	background: url(images/icon_search.gif) center / 24px 24px no-repeat;
	cursor: pointer;
}

/* ==========================================================================
   Footer
   ========================================================================== */

#footer-top .contentwidth {
	padding-top: 5px;
	border-top: 1.5px solid #ac0233;
	border-bottom: 1.5px solid #ac0233;
}

.footer-widgets {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 0 20px;
}

#copyright-info {
	font-size: 0.8em;
	color: #666;
	padding-top: 10px;
	text-align: center;
}

#quiet {
	font-family: Verdana, Geneva, sans-serif;
	font-size: 0.6em;
	color: #767676;
	text-align: center;
	padding-bottom: 10px;
}
#quiet a { color: #767676; text-decoration: none; }

/* ==========================================================================
   Legacy content classes (kept so existing page / post content still works)
   ========================================================================== */

.left, .alignleft { float: left; }
.right, .alignright { float: right; }
.alignleft { margin: 0 1.5em 1em 0; }
.alignright { margin: 0 0 1em 1.5em; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; clear: both; }

.column { margin: 0 20px 0 0; float: left; }
.columnVerySmall { width: 115px; }
.columnSmall { width: 230px; }
.columnHalfLarge { width: 340px; }
.columnOneThird { width: 300px; }
.columnOneHalf { width: 460px; }
.columnTwoThirds { width: 640px; }
.columnLarge { width: 700px; }
.last { margin: 0; float: right; }

.strong { font-weight: 700; }

.clearfix::after { content: ""; display: block; clear: both; visibility: hidden; line-height: 0; height: 0; }
.clear { clear: both; padding-bottom: 10px; }
.hidden { display: none; }

/* ==========================================================================
   WordPress core accessibility / utility classes
   ========================================================================== */

.screen-reader-text {
	border: 0;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute;
	width: 1px;
	word-wrap: normal !important;
}

.screen-reader-text:focus,
.skip-link:focus {
	clip: auto !important;
	clip-path: none;
	display: block;
	height: auto;
	width: auto;
	left: 5px;
	top: 5px;
	z-index: 100000;
	padding: 12px 20px;
	background: #f8f8f8;
	color: #000;
	font-size: 1em;
	text-decoration: none;
}

.sticky, .bypostauthor { display: block; }

.gallery { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 1em; }
.gallery-item { margin: 0; }

.commentlist { margin-left: 0; padding-left: 0; }
.commentlist .children { margin-left: 1.5em; }
.comment-body { margin-bottom: 1em; }
.comment-form input[type="text"], .comment-form input[type="email"], .comment-form input[type="url"], .comment-form textarea {
	max-width: 100%;
	border: 1px solid #aaa;
	background: #fff;
	padding: 4px;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 800px) {
	.has-sidebar .content-grid,
	.sidebar-left.has-sidebar .content-grid { grid-template-columns: minmax(0, 1fr); }
	.sidebar-left.has-sidebar .site-main,
	.sidebar-left.has-sidebar .widget-area { grid-column: auto; grid-row: auto; }
	#secondary { margin-top: 2em; }

	.footer-widgets { grid-template-columns: minmax(0, 1fr); }
	.footer-widget-area { margin-bottom: 1em; }

	#header .contentwidth { flex-direction: column; align-items: stretch; }
	#logo { flex-basis: auto; }
	.main-navigation .menu, .main-navigation .nav-menu { display: block; }

	/* Fixed-width legacy columns stack on small screens. */
	.column, .columnVerySmall, .columnSmall, .columnHalfLarge, .columnOneThird,
	.columnOneHalf, .columnTwoThirds, .columnLarge {
		float: none;
		width: 100%;
		margin-right: 0;
	}
	.last { float: none; }

	.twocolumntext { column-count: 1; }

	.archive-thumb { float: none; margin-right: 0; }

	.main-navigation.js-nav .menu-toggle { display: block; }
	.main-navigation.js-nav:not(.toggled) ul { display: none; }
	.main-navigation a { padding: 8px; }
	.main-navigation ul ul {
		position: static;
		min-width: 0;
		border: 0;
		background: none;
		padding-left: 1em;
	}
}

@media (max-width: 600px) {
	.alignleft, .alignright { float: none; display: block; margin: 0 auto 1em; }
	.entry-content table { display: block; overflow-x: auto; }
}

/* ==========================================================================
   Print
   ========================================================================== */

@media print {
	body { background: none; color: #000; font-size: 10pt; }
	.main-navigation, #secondary, #footer-top, .search-form, .skip-link { display: none !important; }
	.has-sidebar .content-grid { display: block; }
	a { text-decoration: underline; }
	.entry-content a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 90%; }
}
