@font-face {
    font-family: 'Ralsihten';
    src: url('Ralsihten.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'GoMonoRegular';
    src: url('GoMonoRegular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'GoMonoBold';
    src: url('GoMonoBold.ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}

@font-face {
    font-family: 'GoMonoItalic';
    src: url('GoMonoItalic.ttf') format('truetype');
    font-weight: normal;
    font-style: italic;
}

@font-face {
    font-family: 'GoMonoBoldItalic';
    src: url('GoMonoBoldItalic.ttf') format('truetype');
    font-weight: bold;
    font-style: italic;
}

:root {
  --main-color: #8c6946;
}

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

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    line-height: 1.6;
    color: #e8dcc6;
    background: radial-gradient(ellipse at top, #2c1810 0%, #1a1a1a 40%, #0f0f0f 100%);
    background-attachment: fixed;
    min-height: 100vh;
}

header {
    background: #3d2f1f;
    padding: 1rem;
    border-bottom: 3px solid var(--main-color);
    box-shadow: 0 4px 12px rgba(0,0,0,0.6);
    position: relative;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

header h1 {
    color: #f4e4bc;
    font-size: 2.5rem;
    text-shadow: 2px 2px 6px rgba(0,0,0,0.9);
    font-weight: bold;
    position: relative;
	display: flex;
    font-family: 'Ralsihten', serif;
}


nav a {
	font-family: 'GoMonoRegular';
	font-weight: normal;
	font-style: normal;

    color: #d2b48c;
    text-decoration: none;
    font-weight: bold;
    padding: 0.6rem 1.2rem;
    border: 2px solid var(--main-color);
    background: rgba(61, 47, 31, 0.7);
    transition: all 0.3s ease;
    backdrop-filter: blur(2px);
}

nav a:hover {
    background: rgba(205, 133, 63, 0.3);
    color: #f4e4bc;
    box-shadow: 0 3px 8px rgba(205, 133, 63, 0.4);
    transform: translateY(-1px);
}

main {
    max-width: 60rem;
    margin: 2rem auto;
    padding: 0 2rem;
}

#post-list, #single-post {
    background: linear-gradient(135deg, rgba(61, 47, 31, 0.95) 0%, rgba(44, 24, 16, 0.95) 100%);
    border: 2px solid var(--main-color);
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.7), inset 0 1px 0 rgba(244, 228, 188, 0.1);
    position: relative;
    backdrop-filter: blur(5px);
}

#post-list::before, #single-post::before {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    z-index: -1;
    opacity: 0.8;
}

.post-preview {
	text-decoration: none;
	display: block;
    border-bottom: 2px solid rgba(205, 133, 63, 0.4);
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 0.5rem 0;
	font-family: 'GoMonoRegular';
	font-weight: normal;
	font-style: normal;
}

.post-preview:hover {
    background: rgba(205, 133, 63, 0.15);
    box-shadow: inset 0 0 15px rgba(244, 228, 188, 0.2);
    transform: translateX(5px);
}

.post-title {
    color: #f4e4bc;
    margin-bottom: 0.5rem;
    font-size: 1.6rem;
    font-weight: bold;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.9);
}

.post-excerpt {
    color: #e8dcc6;
    line-height: 1.6;
}

#post-content {
	font-family: 'GoMonoRegular';
	font-weight: normal;
	font-style: normal;
}

#post-content h1, #post-content h2, #post-content h3 {
    color: #f4e4bc;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.9);
}

#post-content h1 {
    border-bottom: 3px solid var(--main-color);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
}

#post-content h2 {
    font-size: 1.6rem;
    color: #e8dcc6;
}

#post-content h3 {
    font-size: 1.4rem;
    color: #d2b48c;
}

#post-content p {
    margin-bottom: 1.2rem;
    color: #e8dcc6;
}

#post-content pre {
    background: rgba(26, 26, 26, 0.9);
    border: 2px solid var(--main-color);
    padding: 1.5rem;
    overflow-x: auto;
    margin: 1.5rem 0;
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.6);
}

#post-content code {
    background: rgba(205, 133, 63, 0.2);
    color: #f4e4bc;
    padding: 0.3rem 0.6rem;
    font-family: 'Courier New', monospace;
    border: 1px solid rgba(205, 133, 63, 0.4);
}

#post-content blockquote {
    border-left: 4px solid var(--main-color);
    margin: 1rem 0;
    padding: 0.5rem;
    color: #d2b48c;
	opacity: 70%;
    background: rgba(205, 133, 63, 0.1);
    position: relative;
}

#post-content blockquote p {
	margin: 0;
}

#post-content strong {
    color: #f4e4bc;
	font-weight: bold;
    text-shadow: 0.2rem 0.2rem 0.2rem rgba(0,0,0,0.8);
	text-decoration: underline;
}

#post-content em {
    color: #d2b48c;
}

#post-content table {
    border-collapse: collapse;
    width: 100%;
    margin: 1.5rem 0;
    background: rgba(61, 47, 31, 0.8);
    border: 2px solid var(--main-color);
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

#post-content th, #post-content td {
    border: 1px solid rgba(205, 133, 63, 0.3);
    padding: 0.8rem;
    text-align: left;
}

#post-content th {
    background: linear-gradient(135deg, var(--main-color) 0%, #a0825a 100%);
    color: #f4e4bc;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8);
}

#post-content td {
    color: #e8dcc6;
}

#post-content ul, #post-content ol {
    margin: 1rem 0 1rem 2rem;
    color: #e8dcc6;
}

#post-content li {
    margin-bottom: 0.5rem;
}


#loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: #e8dcc6;
    font-family: 'GoMonoRegular';
}

.hidden {
    display: none !important;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(205, 133, 63, 0.3);
    border-left: 4px solid var(--main-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#loading-spinner p {
    font-size: 1.1rem;
    color: #d2b48c;
}




/* 
 * Colours taken from Everforest theme "Foreground Colors (palette2)"
 *  - https://github.com/sainnhe/everforest/blob/master/palette.md
 */
.ada, .emily, .ab, .nic, .riley, .matt {
	position: relative;
  	display: inline-block; 
}
.ada::after, .emily::after, .ab::after, .nic::after, .riley::after, .matt::after {
	content: "";
	position: absolute;
	inset: 0 0 0 0;
	line-height: 0.5rem;
	transform: skewX(-10deg);
}

.ada::after {
	background: #d699b620;
}

.emily::after {
	background: #dbbc7f20;
}

.ab::after {
	background: #7fbbb320;
}

.nic::after {
	background: #83c09220;
}

.riley::after {
	background: #e6987520;
}

.matt::after {
	background: #e67e8020;
}
