
/* 
  Theme: Le Grimoire
  Author: Generated by Google GenAI
*/

@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@300;400;600&family=Patrick+Hand&display=swap');

:root {
  --font-hand: 'Patrick Hand', cursive;
  --font-sans: 'Fredoka', sans-serif;
  --color-paper: #fdfbf7;
  --color-ink: #2d3436;
  --color-blue: #4a90e2;
  --color-pink: #fd79a8;
  --color-yellow: #ffeaa7;
  --color-green: #badc58;
}

/* Reset & Basics */
body {
  background-color: var(--color-paper);
  background-image: radial-gradient(#d1d8e0 1px, transparent 1px);
  background-size: 20px 20px;
  color: var(--color-ink);
  font-family: var(--font-sans);
  line-height: 1.6;
  margin: 0;
  padding: 0;
}

a { text-decoration: none; color: inherit; transition: color 0.2s; }
a:hover { color: var(--color-blue); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-hand);
  margin-top: 0;
  line-height: 1.2;
}

/* Header */
.gh-head {
  padding: 2rem 1rem;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(4px);
  border-bottom: 4px dashed var(--color-ink);
  position: sticky;
  top: 0;
  z-index: 100;
}

.gh-head-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-logo {
  font-family: var(--font-hand);
  font-size: 2rem;
  font-weight: bold;
  position: relative;
  display: inline-block;
}

.site-logo::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -5px;
  width: 100%;
  height: 6px;
  background: url("data:image/svg+xml;charset=utf8,%3Csvg viewBox='0 0 100 20' preserveAspectRatio='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 10 Q 25 20 50 10 T 100 10' stroke='%23fd79a8' stroke-width='3' fill='none' /%3E%3C/svg%3E") repeat-x;
  background-size: 100% 100%;
}

.gh-head-menu .nav {
  list-style: none;
  display: flex;
  gap: 1.5rem;
  font-family: var(--font-hand);
  font-size: 1.25rem;
  margin: 0;
  padding: 0;
}

/* Main Layout */
.site-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* Post Card */
.post-card {
  background: white;
  border-radius: 2px 255px 3px 25px / 255px 5px 225px 5px;
  border: 2px solid var(--color-ink);
  box-shadow: 2px 3px 0px rgba(0,0,0,0.1);
  transition: all 0.2s ease-in-out;
  overflow: hidden;
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
}

.post-card:hover {
  box-shadow: 4px 5px 0px rgba(74, 144, 226, 0.4);
  transform: translateY(-2px) rotate(-0.5deg);
}

.post-card-image-link {
  height: 200px;
  overflow: hidden;
  border-bottom: 2px dashed var(--color-ink);
}

.post-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-card-content {
  padding: 1.5rem;
}

.post-card-title {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

.post-card-excerpt {
  font-size: 1rem;
  color: #666;
}

/* Post Grid */
.post-feed {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

/* Single Post / Page */
.article {
  background: white;
  border-radius: 2px 255px 3px 25px / 255px 5px 225px 5px;
  border: 2px solid var(--color-ink);
  padding: 0 0 2rem 0;
  position: relative;
  overflow: hidden;
  margin-bottom: 3rem;
}

.article-header {
  text-align: center;
  margin: 2rem 2rem 2rem 2rem;
  border-bottom: 2px dashed #eee;
  padding-bottom: 2rem;
}

.article-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.article-image {
  width: 100%;
  height: auto;
  border-bottom: 2px dashed var(--color-ink);
  margin-bottom: 2rem;
}

/* Ghost Content & Koenig Editor Support (Critical for Validation) */

/* Modern Grid Layout for Content */
.gh-content {
  display: grid;
  grid-template-columns: [full-start] minmax(4vw, auto) [wide-start] minmax(auto, 240px) [main-start] min(720px, calc(100% - 8vw)) [main-end] minmax(auto, 240px) [wide-end] minmax(4vw, auto) [full-end];
  font-size: 1.125rem;
}

.gh-content > * {
  grid-column: main-start / main-end;
}

/* Required Koenig Classes */
.kg-width-wide {
  grid-column: wide-start / wide-end;
}

.kg-width-full {
  grid-column: full-start / full-end;
}

.kg-width-full img {
  width: 100%;
}

.gh-content p { margin-bottom: 1.5rem; }

.gh-content blockquote {
  border-left: 4px solid var(--color-pink);
  padding-left: 1rem;
  font-style: italic;
  font-family: var(--font-hand);
  font-size: 1.25rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

.gh-content img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

/* Gallery Support */
.kg-gallery-container {
  display: flex;
  flex-direction: column;
  max-width: 1000px;
  width: 100%;
}
.kg-gallery-row {
  display: flex;
  flex-direction: row;
  justify-content: center;
}
.kg-gallery-image img {
  display: block;
  margin: 0;
  width: 100%;
  height: 100%;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  margin: 4rem 0;
  font-family: var(--font-hand);
  font-size: 1.25rem;
  font-weight: bold;
}

.newer-posts, .older-posts {
  background: white;
  border: 2px solid var(--color-ink);
  padding: 0.5rem 1.5rem;
  border-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  box-shadow: 2px 2px 0px rgba(0,0,0,0.1);
  transition: all 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.newer-posts:hover, .older-posts:hover {
  background: var(--color-yellow);
  transform: rotate(-1deg) scale(1.05);
  box-shadow: 4px 4px 0px rgba(0,0,0,0.1);
  color: var(--color-ink);
  text-decoration: none;
}

.page-number {
  color: #666;
  font-family: var(--font-sans);
  font-size: 0.9rem;
}

/* Footer */
.site-footer {
  text-align: center;
  padding: 2rem;
  background: var(--color-ink);
  color: white;
  font-family: var(--font-hand);
  margin-top: 3rem;
}
