/* --- GOOGLE FONTS IMPORT --- */
@import url('https://fonts.googleapis.com/css2?family=EB+Garamond:ital,wght@0,400..800;1,400..800&display=swap');

/* --- VARIABLES --- */
:root {
    --deep-green: #1b2e1e;
    --sage-green: #4a5d4e;
    --parchment: #e8e4d9; 
    --text-dark: #2c2c2c;
    --accent: #8c7851;
}

/* --- BASE STYLES --- */
body {
    background-color: var(--parchment);
    color: var(--text-dark);
    font-family: 'EB Garamond', serif;
    margin: 0;
    line-height: 1.8;
}

/* --- HEADER & NAVIGATION --- */
header {
    padding: 5rem 2rem 3rem;
    text-align: center;
}

.site-title, h1 {
    font-weight: 500;
    font-size: 4.5rem;
    margin: 0;
    letter-spacing: -2px;
    color: var(--deep-green);
    line-height: 1;
    text-decoration: none;
    display: block;
}

.subheading {
    font-style: italic;
    font-size: 1.4rem;
    color: var(--sage-green);
    margin-bottom: 2.5rem;
    display: block;
}

nav {
    border-top: 1px solid rgba(74, 93, 78, 0.3);
    border-bottom: 1px solid rgba(74, 93, 78, 0.3);
    padding: 1.2rem 0;
    display: flex;
    justify-content: center;
    gap: 4rem;
}

nav a {
    text-decoration: none;
    color: var(--deep-green);
    text-transform: lowercase;
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: 1px;
    transition: opacity 0.3s;
}

nav a:hover { opacity: 0.6; }

/* --- LAYOUT --- */
main {
    max-width: 850px; /* Slightly wider for better text flow */
    margin: 0 auto;
    padding: 4rem 2rem;
}

/* --- CAROUSEL / HERO --- */
.carousel {
    position: relative;
    max-width: 900px;
    margin: 0 auto 3rem;
    overflow: hidden;
    border: 1px solid rgba(74, 93, 78, 0.2);
    box-shadow: 0 8px 32px rgba(27, 46, 30, 0.1);
}

.carousel img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 380px;
    object-fit: cover;
    filter: contrast(1.02) saturate(0.95);
}

.carousel-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem 2rem;
    background: linear-gradient(transparent, rgba(27, 46, 30, 0.85));
    color: var(--parchment);
    font-style: italic;
    font-size: 1.35rem;
    letter-spacing: 0.5px;
}

/* --- INDEX INTRO & DECORATIVE ELEMENTS --- */
.index-tagline {
    text-align: center;
    max-width: 560px;
    margin: 0 auto 3rem;
    padding: 1.5rem 2rem;
    font-size: 1.2rem;
    font-style: italic;
    color: var(--sage-green);
    line-height: 1.7;
    border-left: 2px solid var(--accent);
    border-right: 2px solid var(--accent);
    background: rgba(140, 120, 81, 0.04);
}

.ornament {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin: 2.5rem 0;
}

.ornament::before,
.ornament::after {
    content: '';
    flex: 1;
    max-width: 120px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.6;
}

.ornament span {
    font-size: 0.95rem;
    letter-spacing: 4px;
    color: var(--accent);
    text-transform: uppercase;
}

.timeline-section-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--accent);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.timeline-section-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(140, 120, 81, 0.4), transparent);
}

/* --- PAGE TITLE AREA --- */
.page-title-area {
    text-align: center;
    margin-bottom: 3rem;
}

/* --- SERIES CARDS BOX (Series index page) --- */
.series-cards-box {
    border: 2px solid var(--sage-green);
    background: linear-gradient(180deg, rgba(27, 46, 30, 0.03) 0%, rgba(74, 93, 78, 0.06) 100%);
    padding: 2.5rem;
    margin-bottom: 4rem;
    box-shadow: inset 0 1px 0 rgba(232, 228, 217, 0.8), 0 4px 20px rgba(27, 46, 30, 0.08);
}

.series-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5rem;
}

.series-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem 1.25rem;
    border: 1px solid rgba(74, 93, 78, 0.25);
    background: var(--parchment);
    text-decoration: none;
    color: var(--deep-green);
    transition: all 0.3s ease;
    min-height: 140px;
}

.series-card:hover {
    background: rgba(27, 46, 30, 0.06);
    border-color: var(--accent);
    box-shadow: 0 4px 16px rgba(27, 46, 30, 0.12);
    transform: translateY(-3px);
}

.series-card .roman-numeral {
    font-size: 2.25rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 0.5rem;
    display: block;
}

.series-card .series-card-title {
    font-size: 1.15rem;
    font-variant: small-caps;
    letter-spacing: 1px;
    margin-bottom: 0.35rem;
}

.series-card .series-desc {
    font-size: 0.9rem;
    font-style: italic;
    color: var(--sage-green);
}

/* --- SERIES BRANDING BOX (Series Page) --- */
.series-branding-box {
    border: 1px solid var(--deep-green);
    outline: 4px solid var(--parchment);
    box-shadow: 0 0 0 2px var(--accent);
    padding: 3rem 2rem;
    margin-bottom: 5rem;
    text-align: center;
    background-color: rgba(27, 46, 30, 0.02);
}

.series-title {
    font-size: 4rem;
    color: var(--deep-green);
    margin: 0;
    line-height: 1.1;
    text-transform: lowercase;
    font-variant: small-caps;
}

.series-subtitle {
    font-style: italic;
    font-size: 1.6rem;
    color: var(--sage-green);
    margin-top: 1rem;
    display: block;
}

/* --- SERIES TITLE BOX (individual series pages: distinct from latest volume) --- */
.series-title-box {
    border: 2px solid var(--accent);
    background: linear-gradient(180deg, rgba(140, 120, 81, 0.06) 0%, rgba(27, 46, 30, 0.04) 100%);
    padding: 2.5rem 2rem;
    margin-bottom: 4rem;
    text-align: center;
    box-shadow: 0 0 0 1px rgba(140, 120, 81, 0.2), inset 0 1px 0 rgba(232, 228, 217, 0.5);
}

.series-title-box .featured-label {
    margin-bottom: 0.75rem;
}

.series-title-box h2 {
    font-size: 3rem;
    color: var(--deep-green);
    margin: 0 0 0.5rem;
    font-weight: 500;
    letter-spacing: -0.5px;
}

.series-title-box p {
    margin: 0;
    font-style: italic;
    font-size: 1.2rem;
    color: var(--sage-green);
}

/* --- SERIES HEADER (fallback when not using title box) --- */
.series-header {
    margin-bottom: 3rem;
}

/* --- SERIES FEATURED IMAGE (below title on individual series pages) --- */
.series-featured-image {
    margin: 0 0 3rem;
    padding: 0;
}

.series-featured-image img {
    width: 100%;
    height: auto;
    max-height: 320px;
    object-fit: cover;
    display: block;
    border: 1px solid rgba(74, 93, 78, 0.25);
    box-shadow: 0 4px 20px rgba(27, 46, 30, 0.08);
}

/* --- FEATURED POST AREA --- */
.featured-post {
    margin-bottom: 6rem;
    padding-bottom: 5rem;
    border-bottom: 1px solid rgba(74, 93, 78, 0.2);
    text-align: center;
}

.featured-label {
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 3px;
    color: var(--accent);
    display: block;
    margin-bottom: 1.5rem;
}


.featured-post h2 {
    font-size: 3.2rem;
    margin: 1rem 0 1.5rem;
    line-height: 1.1;
}

.featured-post h2 a {
    text-decoration: none;
    color: var(--deep-green);
    transition: color 0.3s;
}

.featured-post h2 a:hover { color: var(--accent); }

.featured-excerpt {
    font-size: 1.6rem;
    font-style: italic;
    color: var(--text-dark);
    max-width: 750px;
    margin: 0 auto 2.5rem;
    line-height: 1.6;
}

/* --- BUTTONS --- */
.read-more {
    display: inline-block;
    padding: 0.8rem 2.5rem;
    border: 1px solid var(--accent);
    color: var(--accent);
    text-decoration: none;
    text-transform: lowercase;
    font-variant: small-caps;
    font-size: 1.2rem;
    letter-spacing: 1px;
    transition: all 0.4s ease;
}

.read-more:hover {
    background: var(--accent);
    color: var(--parchment);
    transform: translateY(-2px);
}

/* --- TIMELINE AREA --- */
.timeline {
    position: relative;
    padding-left: 3.5rem;
    margin-top: 5rem;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(to bottom, var(--accent), transparent);
}

.timeline-item {
    margin-bottom: 4rem;
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -3.8rem;
    top: 0.6rem;
    width: 10px;
    height: 10px;
    background: var(--parchment);
    border: 1px solid var(--accent);
    border-radius: 50%;
    z-index: 2;
}

.date {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.timeline-title {
    font-size: 1.9rem;
    color: var(--deep-green);
    text-decoration: none;
    line-height: 1.2;
    transition: all 0.3s ease;
    display: inline-block;
}

.timeline-title:hover {
    color: var(--sage-green);
    transform: translateX(8px);
}

/* --- POST CONTENT STYLES --- */
.post-header {
    text-align: center;
    margin-bottom: 4rem;
}

.post-series-label {
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 3px;
    color: var(--accent);
}

.post-title {
    font-size: 3.5rem;
    margin: 1rem 0;
}

.post-subtitle {
    font-style: italic;
    font-size: 1.4rem;
    color: var(--sage-green);
    max-width: 600px;
    margin: 0 auto;
}

.post-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    text-align: justify;
}

.post-content p:first-of-type::first-letter {
    font-size: 4rem;
    float: left;
    line-height: 1;
    margin-right: 12px;
    color: var(--deep-green);
    font-weight: 600;
}

.post-content h2 {
    font-size: 1.75rem;
    color: var(--deep-green);
    margin: 2.5rem 0 1rem;
}

.post-content h3 {
    font-size: 1.35rem;
    color: var(--sage-green);
    margin: 2rem 0 0.75rem;
}

.post-content ul {
    margin: 0 0 2rem;
    padding-left: 1.5rem;
}

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

.post-content a {
    color: var(--accent);
    text-decoration: none;
}

.post-content a:hover {
    text-decoration: underline;
}

.rules-block {
    background: rgba(27, 46, 30, 0.04);
    border-left: 3px solid var(--accent);
    padding: 2.5rem;
    margin: 4rem 0;
}

.rules-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.rules-list li {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px dotted rgba(140, 120, 81, 0.3);
    padding: 0.5rem 0;
}

.rule-label {
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.8rem;
    color: var(--accent);
}

blockquote {
    font-style: italic;
    font-size: 1.5rem;
    border-left: 2px solid var(--accent);
    margin: 3rem 0;
    padding-left: 2rem;
    color: var(--deep-green);
}

figure {
    margin: 4rem 0;
    text-align: center;
}

figure img {
    max-width: 100%;
    height: auto;
    border: 1px solid var(--accent);
    padding: 5px;
    background: white;
}

figcaption {
    font-size: 0.9rem;
    font-style: italic;
    margin-top: 1rem;
    color: var(--sage-green);
}

/* --- FOOTER --- */
footer {
    text-align: center;
    padding: 6rem 2rem;
    font-size: 0.9rem;
    color: var(--sage-green);
}

/* --- BREADCRUMBS --- */
.breadcrumb {
    text-decoration: none;
    color: var(--accent);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- POST NAVIGATION (prev/next between entries) --- */
.post-navigation {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(74, 93, 78, 0.2);
}

.post-navigation a {
    color: var(--accent);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.post-navigation a:hover {
    color: var(--deep-green);
}

.post-navigation .nav-next {
    margin-left: auto;
}

.post-navigation span {
    font-size: 0.85rem;
    color: var(--sage-green);
}

/* --- MOBILE ADJUSTMENTS --- */
@media (max-width: 768px) {
    .site-title, h1 { font-size: 2.8rem; }
    .series-title { font-size: 2.5rem; }
    .series-title-box h2 { font-size: 2.25rem; }
    .featured-post h2 { font-size: 2.2rem; }
    .featured-excerpt { font-size: 1.3rem; }
    nav { gap: 1.5rem; flex-wrap: wrap; }
    .series-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
    .series-cards-box { padding: 1.5rem; }
    .series-card { padding: 1.5rem 1rem; min-height: 120px; }
    .series-card .roman-numeral { font-size: 1.75rem; }
    .carousel-caption { font-size: 1.1rem; padding: 1rem; }
    .index-tagline { font-size: 1.05rem; padding: 1.25rem 1.5rem; }
}