/* silkscreen-latin-400-normal */
@font-face {
    font-family: 'Silkscreen';
    font-style: normal;
    font-display: swap;
    font-weight: 400;
    src: url(https://cdn.jsdelivr.net/fontsource/fonts/silkscreen@latest/latin-400-normal.woff2) format('woff2'), url(https://cdn.jsdelivr.net/fontsource/fonts/silkscreen@latest/latin-400-normal.woff) format('woff');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
	--color-text: #424242;
    --color-blue: #004aad;
    --color-gray: rgb(207 206 206);
    --color-gray-light: rgb(246, 246, 246);
    --color-gray-dark: rgb(100 103 121);
    --color-link: rgb(30, 96, 217);
    --color-link-hover: rgb(221 39 88);
    --color-link-visited: rgb(172, 84, 172);
    --color-surface: white;
    --color-bg: #f9f9fb;
    --color-section-header: cornsilk;
    --color-input-bg: #eeecec;
    --color-action-button: linear-gradient(to top, rgb(242, 98, 26) 21.85%, rgb(240, 106, 40) 39.08%, rgba(239, 137, 16, 1));
    --color-action-button-hover: linear-gradient(to top, rgb(242, 98, 26) 5.04%, rgb(226, 102, 41) 29.41%, rgba(217, 131, 29, 1));
}

@media (prefers-color-scheme: dark) {
    :root {
    	--color-text: #d3d0d0;
        --color-blue: #004aad;
        --color-gray: rgb(207 206 206);
        --color-gray-light: rgb(246, 246, 246);
        --color-gray-dark: rgb(160, 160, 160);
        --color-link: rgb(42 134 255);
        --color-link-hover: rgb(211, 21, 21);
        --color-link-visited: rgb(135, 48, 135);
        --color-surface: rgb(16, 15, 15);
        --color-bg: rgb(16, 15, 15);
        --color-section-header: rgb(20, 20, 20);
        --color-input-bg: #202021;
        --color-action-button: #545d69;
        --color-action-button-hover: #373b41;
    }
}

* {
    box-sizing: border-box;
}

html {
    color-scheme: light dark;
}

body {
    padding: 1rem;
    max-width: 970px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    height: 100svh;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 0.86rem;
    background-color: var(--color-bg);
}

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

a:hover {
    color: var(--color-link-hover);
}

/* TABLES */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
    background-color: var(--color-surface);
    font-size: 0.86rem;
}

th,
td {
    padding: 0.5rem;
    text-align: left;
    border: 1px solid var(--color-gray);
}

th {
    background-color: var(--color-blue);
    color: white;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 1px;
}

tr:nth-child(even) {
    background-color: var(--color-gray-light);
}

@media(prefers-color-scheme: dark) {
    tr:nth-child(even) {
        background-color: rgb(21, 21, 21);
    }
}


/* CUSTOM ELEMENTS */

/* MASTHEAD */

.masthead {
    /* background-color: lavender; */
    padding-top: 0rem;
    padding-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.masthead__logo {
    display: block;
    height: 52px;
    width: 52px;
    border-radius: 4px;
}

.masthead__tagline {
    font-family: 'Silkscreen';
    color: gray;
    margin: 0;
    padding: 0;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* NAVBAR (WITHIN MASTHEAD) */

.navbar {
    font-size: 0.86rem;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    font-weight: bold;
    background-color: var(--color-blue);
    margin-top: 0.5rem;
    border-top: 2px solid var(--color-gray);
    border-left: 2px solid rgb(192, 191, 191);
    border-bottom: 2px solid black;
    border-right: 2px solid black;
}

.navbar ul {
    margin: 0;
    padding: 0;
    list-style-type: none;
    display: flex;
    align-items: center;
}

.navbar ul li {}

.navbar ul li a {
    display: inline-block;
    color: white;
    text-decoration: none;
    padding-inline: 0.5rem;
    padding-block: 6px;
    border-right: 1px dotted var(--color-gray);
    min-width: 8ch;
}

.navbar ul li a:hover {
    color: white;
    background-color: black;
    border-right: 1px dotted var(--color-gray);
}

.navbar ul li a.active {
    color: rgb(41, 41, 40);
    background-color: var(--color-gray);
    text-decoration: none;
}

/* ELEMENT: Sections */

.section {
    background-color: var(--color-surface);
    border: 1px solid gray;
    position: relative;
}

@media (prefers-color-scheme: dark) {
	.section { border: 1px solid rgb(39, 39, 39); }
}

.section__title {
    margin: 0;
    font-size: 0.9rem;
    font-family: Arial, Helvetica, sans-serif;
    color: light dark;
    padding: 0.5rem;
    border-bottom: 1px solid gray;
    background-color: var(--color-section-header);
}

.section__main {
    padding: 0.75rem;
}

/* 
.section ul {
    margin: 0;
    padding: 0.5rem;
    list-style-type: none;
}

.section ul li {
    margin-block: 0.5rem;
}

.section li a {
    text-decoration: none;
}
 */


.section.central {
    width: 100%;
    overflow: auto;
}

.section.sidebar {
    min-width: 16ch;
    height: fit-content;
    display: none;
}

.searchbar {
	margin-bottom: 1rem;
	display: block;	
}

.searchbar input[type="text"] {
	width: 100%;
	max-width: 100%;
	margin-inline: auto;
	display: block;
	margin-bottom: 1rem;
}

/* RECENT BLOGS */

.recent-blog {
    border-bottom: 1px solid var(--color-gray);
    padding: 1rem 0.5rem;
}

@media (prefers-color-scheme: dark) {
    .recent-blog {
    	border-bottom: 1px solid rgb(45, 45, 45);
	}
}

.recent-blog:last-of-type {
    border-bottom: none;
}

.recent-blog__title {
    font-weight: bold;
    margin-top: 0;
}

.recent-blog__title a {
	text-decoration: none;
}

.recent-blog__favicon {
    border-radius: 6px;
    height: 24px;
    width: 24px;
    float: right;
}

.recent-blog__description {
    max-width: 80ch;
    color: var(--color-gray-dark);
    line-height: 1.4;
}

.recent-blog__categories {
	margin-top: 1rem;
}

.recent-blog__category {
	padding: 0.35rem 0.65rem;
	border; gray;
	display: inline;
	margin-right: 0.25rem;
	border-radius: 8px;
	background-color: var(--color-input-bg);
	color: gray;
}

/* Pagination */

.pagination {
	display: flex;
	gap: 1rem;
    margin: 2rem auto;
    width: fit-content; 
    justify-content: center;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    flex-wrap: wrap;
}

.pagination a {
	text-decoration: none;  
}

/* Blogpost in home feed */
.blogpost {
    /* background-color: lavender; */
    border-bottom: 1px solid var(--color-gray);
    padding: 0.75rem 0;
}

@media (prefers-color-scheme: dark) {
    .blogpost {
        border-bottom: 1px solid rgb(39, 39, 39);
    }
}

.blogpost__favicon {
    height: 16px;
    width: 16px;
}

.blogpost__title,
.blogpost__author {
    margin-block: 0;
}

.blogpost__title {
    font-size: 0.98rem;
    overflow: hidden;
}

.blogpost__title a:visited {
    color: var(--color-link-visited);
}

.blogpost__author {
    color: var(--color-gray-dark);
}

.blogpost__body {
	margin-top: 1rem; 
	line-height: 1.5;
	color: var(--color-text);
}

.blogpost__body h1 {
	font-size: 1.25rem;
}

.blogpost__body h2 {
	margin-top: 1.5rem;
	font-size: 1rem;
}

.blogpost__body a {
	text-decoration: none;
}

.blogpost__body img {
	max-width: 100%;
	height: auto;
}

.blogpost__body blockquote {
	border-left: 2px solid var(--color-gray-dark);
    margin-left: 0;
    padding-left: 1rem;
}

.blogpost__body pre, .blogpost__body table, .blogpost__body code {
	overflow: auto;
	font-size: 0.8rem;
}

.blogpost__body pre, .blogpost__body code {
    background-color: #242129;
    padding: 0.25rem;
    border-radius: 4px;
    color: rgb(227, 227, 227);
}

.blogpost__body code {
	white-space: nowrap;
}

.blogpost__body hr {
	max-width: 10ch;
	color: var(--color-gray-dark);
}

.blogpost__body ol, .blogpost__body ul {
	margin-left: 1rem;
	padding-top: 0;
}

.blogpost__body ul {
	list-style-type: disc;
}

summary {
	color: var(--color-gray-dark);
	font-size: 92%;
}

summary:hover {
	cursor: pointer;
}

/* BLOG SHOW */

.blog__recent-posts {
    display: flex;
    flex-direction: column-reverse;
    font-size: 0.98rem;
    padding: 0.5rem 0;
    line-height: 1.5;
}

.blog__recent-posts a:visited {
    color: var(--color-link-visited);
}

/* FORM STYLING */

/* form {
   padding: 0;
}*/
 
.form__field {
    display: flex;
    flex-direction: column;
    margin-top: 1.5rem;
}

.form__field:first-of-type {
    margin-top: 0rem;
}

.form__field label {
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

input[type="text"], input[type="email"], textarea {
    border: 2px solid transparent;
    outline: none;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 1rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    max-width: 60ch;
    padding-left: 0.75rem;
    background-color: var(--color-input-bg);
}

input[type="text"]:focus-within, input[type="email"]:focus-within, textarea:focus-within {
    outline-color: var(--color-blue);
    border-color: var(--color-blue);
}

input[type="submit"], button {
    display: block;
    border: 2px solid #d47e0e;
    background-color: #eb8d12;
    color: white;
    font-weight: bold;
    padding: 0.5rem;
    border-radius: 4px;
    margin-top: 1rem;
    text-transform: uppercase;
    width: 100%;
}

input[type="submit"]:hover, button:hover {
    border: 2px solid #d47e0e;
    background-color: #d17f14;
    cursor: pointer;
}

@media(prefers-color-scheme: dark) {
    input[type="submit"], button {
        border: 2px solid var(--color-blue);
        background-color: var(--color-blue);
    }

    input[type="submit"]:hover, button:hover {
        border: 2px solid #053d89;
        background-color: #053b84;
    }
}

textarea:not([rows]) {
  min-height: 5em;
}

.button-delete {
    border: 2px solid #a10925;
    background-color: firebrick;
}

.label-delete {
    font-size: 0.8rem;
    color: firebrick;
    background: none;
    border: none;
    text-transform: none;
    font-weight: normal;
    margin-top: 0.5rem;
    padding: 0;
}

.label-delete:hover {
    font-size: 0.8rem;
    color: firebrick;
    background: none;
    border: none;
    text-transform: none;
}

.button-action {
    display: none;
}

/* MOBILE MENU */

.mobile-menu {
    background-color: var(--color-blue);
    display: flex;
    justify-content: space-between;
    position: sticky;
    bottom: 0;
    width: 100%;
    padding: 0.75rem;
    margin-top: 1rem;
}

.mobile-menu a {
    text-transform: uppercase;
    color: var(--color-gray-light);
    text-decoration: none;
    font-weight: bold;
}

footer {
    display: none;
}


.footer__link {
    text-decoration: none;
    color: gray;
}

/* About Page with Cover Image */

.page__header {
/* 	border: 1px solid red; */
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: clamp(1rem, 0.8977rem + 0.4545vw, 1.25rem);
	margin-bottom: clamp(2.0736rem, 1.6734rem + 1.7785vw, 3.0518rem);
}

.page__title {
	text-align: center;
	font-size: clamp(2.4883rem, 1.9457rem + 2.4116vw, 3.8147rem);
	font-weight: bold;
	margin: 0;
	color: white;
	text-shadow: 1px 2px 2px #191624; 
}

.page__tagline {
	text-align: center;
/* 	font-size: clamp(1.728rem, 1.4362rem + 1.2971vw, 2.4414rem); */
	font-size: clamp(0.8rem, 1.5vw + 0.87rem, 2.4rem);
	margin: 0;
	font-family: 'Silkscreen', cursive;
	color: #ececec;
	text-shadow: 1px 2px 2px #191624; 
}

.page__image {
	position: absolute; 
	width: 100%; 
/* 	object-fit: cover;  */
	max-height: clamp(200px, 20vw, 240px);
	min-height: 160px;
}


.page__main {
	font-size: clamp(1rem, 0.8977rem + 0.4545vw, 1.25rem); 
	padding: clamp(1rem, 0.8977rem + 0.4545vw, 1.25rem); 
	line-height: 1.5; 
	position: relative;
	color: var(--color-text);
}


@media screen and (min-width: 790px) {

    .button-action {
        display: flex;
        gap: 0.25rem;
        align-items: center;
        padding: 0.5rem 0;
        background: var(--color-action-button);
        border-radius: 2px;
        justify-content: center;
        color: white;
        text-decoration: none;
        border-top: 2px solid var(--color-gray);
        border-left: 2px solid rgb(192, 191, 191);
        border-bottom: 2px solid black;
        border-right: 2px solid black;
    }

    .button-action:hover {
        background: var(--color-action-button-hover);
        color: white;
    }

    .masthead {
        padding-top: 1rem;
    }

    .masthead__logo {
        height: 64px;
        width: 64px;
    }

    .mobile-menu {
        display: none;
    }

    #page-container {
        display: flex;
        gap: 1rem;
    }

    .section {
        max-height: inherit;
    }

    .section.sidebar {
        display: block;
        min-width: 20ch;
        max-width: fit-content;
        width: 100%;
    }

    .section.central {
        min-width: 80ch;
    }
    
    .section__main {
		padding: 1rem; /* TESTING NOV 3 */
	}

    .blog__recent-posts {
        flex-direction: row;
        justify-content: space-between;
/*         margin-bottom: 1rem; */
    }

    input[type="submit"], button {
        width: fit-content;
        min-width: 14ch;
    }

    footer {
        display: flex;
    }
    
    .searchbar {
		min-width: 30ch;
	}

	.searchbar input[type="text"] {
		max-width: 60ch;
	}
}