/*
Theme Name: JPK Timeline Theme
Theme URI: https://jpk.ch
Author: Jean-Pierre A. Kousz
Author URI: https://jpk.ch
Description: Persönliches Blog-Theme mit Timeline-Layout und Hero-Header
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: jpk-theme
*/

/* ========================================
   CSS Reset & Base
======================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    overflow-y: auto;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
    min-height: 100vh;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ========================================
   Hero Header
======================================== */
.hero-header {
    position: relative;
    height: 350px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
}

.hero-content {
    position: relative;
    z-index: 2;
    color: #fff;
}

.site-title {
    font-size: 4rem;
    font-weight: 300;
    letter-spacing: 2px;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.5);
    margin-bottom: 0.25rem;
}

.site-title a {
    color: #fff;
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.site-title a:hover {
    opacity: 0.9;
}

.site-title .colon {
    color: #00bcd4;
}

.site-subtitle {
    font-size: 1.1rem;
    font-weight: 300;
    text-shadow: 1px 1px 5px rgba(0, 0, 0, 0.5);
    opacity: 0.9;
}

/* ========================================
   Navigation Bar
======================================== */
.nav-bar {
    background: #5a5a5a;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.grid-icon {
    color: #888;
    font-size: 1.5rem;
    cursor: pointer;
}

.social-icons {
    display: flex;
    gap: 0.5rem;
}

.social-icons a {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1rem;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.social-icons a:hover {
    transform: scale(1.1);
    opacity: 0.9;
}

.social-icons .facebook { background: #3b5998; }
.social-icons .twitter { background: #00bcd4; }
.social-icons .instagram { background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888); }
.social-icons .linkedin { background: #0077b5; }

/* Profilbild zentriert */
.profile-image-wrapper {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

.profile-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 4px solid #6a6a6a;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    object-fit: cover;
    background: #fff;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

/* Navigation Search */
.nav-search {
    display: flex;
    align-items: center;
    background: #4a4a4a;
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.2s ease;
}

.nav-search:focus-within {
    background: #555;
    box-shadow: 0 0 0 2px rgba(0, 188, 212, 0.3);
}

.nav-search input[type="search"] {
    background: transparent;
    border: none;
    color: #ccc;
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    width: 150px;
    outline: none;
}

.nav-search input[type="search"]::placeholder {
    color: #888;
}

.nav-search input[type="search"]::-webkit-search-cancel-button {
    -webkit-appearance: none;
}

.nav-search button {
    background: transparent;
    border: none;
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-search button svg {
    width: 18px;
    height: 18px;
    color: #888;
    transition: color 0.2s ease;
}

.nav-search button:hover svg {
    color: #00bcd4;
}

.menu-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.menu-toggle span {
    display: block;
    width: 28px;
    height: 3px;
    background: #888;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.menu-toggle:hover span {
    background: #00bcd4;
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #4a4a4a;
    min-width: 220px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 100;
    border-radius: 0 0 4px 4px;
}

.mobile-menu.active {
    display: block;
}

.mobile-menu ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

.mobile-menu li {
    margin: 0;
    padding: 0;
}

.mobile-menu a {
    display: block;
    padding: 1rem 1.5rem;
    color: #fff;
    border-bottom: 1px solid #5a5a5a;
    transition: background 0.2s ease;
}

.mobile-menu li:last-child a {
    border-bottom: none;
}

.mobile-menu a:hover {
    background: #00bcd4;
}

/* Submenu */
.mobile-menu .sub-menu {
    background: #3a3a3a;
}

.mobile-menu .sub-menu a {
    padding-left: 2.5rem;
    font-size: 0.9rem;
}

/* Hamburger Animation wenn aktiv */
.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ========================================
   Timeline
========================================*/
.timeline-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 2rem;
    position: relative;
}

/* Vertikale Mittellinie */
.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #6a6a6a;
    margin-left: -1px;
    z-index: 1;
}

/* Timeline Items Container */
.timeline-grid {
    position: relative;
    overflow: hidden;
}

/* Timeline Item - Basis */
.timeline-item {
    position: relative;
    width: calc(50% - 40px);
    margin-bottom: 2rem;
}

/* Ungerade Items - Links (nur links clearen) */
.timeline-item:nth-child(odd) {
    float: left;
    clear: left;
    margin-right: 40px;
}

/* Gerade Items - Rechts (nur rechts clearen) */
.timeline-item:nth-child(even) {
    float: right;
    clear: right;
    margin-left: 40px;
}

/* Horizontale Verbindungslinie - Links */
.timeline-item:nth-child(odd)::before {
    content: '';
    position: absolute;
    top: 35px;
    right: -40px;
    width: 33px;
    height: 2px;
    background: #6a6a6a;
    z-index: 2;
}

/* Horizontale Verbindungslinie - Rechts */
.timeline-item:nth-child(even)::before {
    content: '';
    position: absolute;
    top: 35px;
    left: -40px;
    width: 33px;
    height: 2px;
    background: #6a6a6a;
    z-index: 2;
}

/* Timeline-Punkt - Links (auf der Linie) */
.timeline-item:nth-child(odd)::after {
    content: '';
    position: absolute;
    right: -47px;
    top: 28px;
    width: 14px;
    height: 14px;
    background: #00bcd4;
    border: 3px solid #4a4a4a;
    border-radius: 50%;
    z-index: 3;
}

/* Timeline-Punkt - Rechts (auf der Linie) */
.timeline-item:nth-child(even)::after {
    content: '';
    position: absolute;
    left: -47px;
    top: 28px;
    width: 14px;
    height: 14px;
    background: #00bcd4;
    border: 3px solid #4a4a4a;
    border-radius: 50%;
    z-index: 3;
}

/* Clearfix */
.timeline-grid::after {
    content: '';
    display: table;
    clear: both;
}

/* Meta-Info (Datum Badge) */
.timeline-meta {
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 3;
}

.timeline-date {
    background: #00bcd4;
    color: #fff;
    padding: 0.4rem 0.85rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    white-space: nowrap;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.timeline-date svg {
    width: 14px;
    height: 14px;
}

/* Datum Badge inline wenn kein Bild */
.timeline-meta-inline {
    position: relative;
    top: auto;
    left: auto;
    margin-bottom: 0.75rem;
}

/* Card */
.timeline-card {
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    width: 100%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.timeline-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

.timeline-card-image-wrapper {
    position: relative;
    overflow: hidden;
}

.timeline-card-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.timeline-card:hover .timeline-card-image {
    transform: scale(1.05);
}

.timeline-card-content {
    padding: 1.25rem;
    border-left: 4px solid #00bcd4;
}

.timeline-card-title {
    font-size: 1.4rem;
    font-weight: 400;
    color: #333;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.timeline-card-title a {
    color: #333;
    transition: color 0.2s ease;
}

.timeline-card-title a:hover {
    color: #00bcd4;
}

.timeline-card-subtitle {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
}

.timeline-card-excerpt {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
}

.timeline-card-edit {
    margin-top: 0.75rem;
    margin-bottom: 0;
    padding-top: 0.75rem;
    border-top: 1px solid #eee;
}

.timeline-card-edit a {
    color: #00bcd4;
    font-size: 0.85rem;
    text-decoration: none;
}

.timeline-card-edit a:hover {
    text-decoration: underline;
}

/* ========================================
   Pagination
======================================== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 2rem 0;
}

.pagination a,
.pagination span {
    padding: 0.75rem 1rem;
    background: #5a5a5a;
    color: #fff;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.pagination a:hover,
.pagination .current {
    background: #00bcd4;
}

/* ========================================
   Jahres-Navigation
======================================== */
.year-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem;
    position: relative;
    z-index: 5;
}

.current-year {
    position: relative;
}

.year-select-wrapper {
    position: relative;
    display: inline-block;
}

.year-select-wrapper select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #5a5a5a;
    color: #fff;
    border: none;
    padding: 0.6rem 2.5rem 0.6rem 2rem;
    border-radius: 30px;
    font-size: 1.4rem;
    font-weight: 600;
    letter-spacing: 2px;
    cursor: pointer;
    outline: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease;
}

.year-select-wrapper select:hover,
.year-select-wrapper select:focus {
    background: #6a6a6a;
}

.year-select-wrapper::after {
    content: '▼';
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 0.7rem;
    pointer-events: none;
}

.year-label {
    font-size: 1.4rem;
    font-weight: 600;
    color: #fff;
    letter-spacing: 2px;
    background: #5a5a5a;
    padding: 0.6rem 2rem;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* Timeline Ende Navigation */
.timeline-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
    position: relative;
    z-index: 5;
}

.timeline-footer-line {
    width: 2px;
    height: 40px;
    background: #6a6a6a;
    margin-bottom: 1rem;
}

.year-nav-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: #00bcd4;
    color: #fff;
    padding: 0.75rem 1.5rem;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0, 188, 212, 0.35);
    transition: all 0.3s ease;
}

.year-nav-button:hover {
    background: #00a5bb;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 188, 212, 0.45);
}

.year-nav-button svg {
    width: 18px;
    height: 18px;
}

.timeline-end-text {
    color: #666;
    font-size: 0.9rem;
    font-style: italic;
    text-align: center;
}

.no-posts {
    text-align: center;
    padding: 4rem 2rem;
    color: #999;
}

.no-posts h2 {
    color: #fff;
    margin-bottom: 1rem;
}

/* ========================================
   Footer
======================================== */
.site-footer {
    background: #3a3a3a;
    color: #999;
    text-align: center;
    padding: 2rem;
    font-size: 0.9rem;
}

.site-footer a {
    color: #00bcd4;
}

.site-footer a:hover {
    text-decoration: underline;
}

/* ========================================
   Single Post
======================================== */
.single-post-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.single-post {
    background: #fff;
    border-radius: 4px;
    overflow: visible;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.single-post-image {
    width: 100%;
    max-height: 500px;
    object-fit: cover;
}

.single-post-content {
    padding: 2rem;
}

.single-post-title {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #333;
}

.single-post-meta {
    color: #888;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.single-post-meta svg {
    width: 14px;
    height: 14px;
    display: inline-block;
    vertical-align: middle;
}

.single-post-body {
    color: #444;
    line-height: 1.8;
}

.single-post-body p {
    margin-bottom: 1.25rem;
}

.single-post-body h2,
.single-post-body h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #333;
}

.single-post-body img {
    margin: 1.5rem 0;
    border-radius: 4px;
}

.single-post-edit {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
}

.single-post-edit a {
    color: #00bcd4;
    text-decoration: none;
}

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

/* ========================================
   Page Template
======================================== */
.page-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.page-content {
    background: #fff;
    border-radius: 4px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.page-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: #333;
    border-bottom: 2px solid #00bcd4;
    padding-bottom: 0.5rem;
}

/* ========================================
   Post Navigation
======================================== */
.post-navigation {
    max-width: 1000px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.post-navigation .nav-links {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.post-navigation .nav-previous,
.post-navigation .nav-next {
    flex: 1;
    min-width: 200px;
}

.post-navigation .nav-previous a,
.post-navigation .nav-next a {
    display: block;
    background: #fff;
    padding: 1.25rem 1.5rem;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    color: #333;
    transition: all 0.2s ease;
    text-decoration: none;
}

.post-navigation .nav-previous a:hover,
.post-navigation .nav-next a:hover {
    background: #00bcd4;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 188, 212, 0.4);
}

.post-navigation .nav-next {
    text-align: right;
}

/* ========================================
   Comments
======================================== */
.comments-area {
    max-width: 1000px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.comments-area > h2,
.comments-area .comments-title,
.comment-reply-title {
    color: #fff;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

.comment-list {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
}

.comment {
    background: #fff;
    border-radius: 4px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.comment .comment-author {
    font-weight: 600;
    color: #333;
}

.comment .comment-meta {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 0.75rem;
}

.comment .comment-content {
    color: #444;
    line-height: 1.6;
}

.comment .reply a {
    color: #00bcd4;
    font-size: 0.85rem;
}

/* Comment Form */
.comment-respond {
    background: #fff;
    border-radius: 4px;
    padding: 2rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.comment-respond .comment-reply-title {
    color: #333;
    margin-bottom: 1rem;
}

.comment-form p {
    margin-bottom: 1.25rem;
}

.comment-form label {
    display: block;
    font-weight: 500;
    color: #333;
    margin-bottom: 0.5rem;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form input[type="url"]:focus,
.comment-form textarea:focus {
    outline: none;
    border-color: #00bcd4;
    box-shadow: 0 0 0 3px rgba(0, 188, 212, 0.15);
}

.comment-form textarea {
    min-height: 150px;
    resize: vertical;
}

.comment-form .form-submit {
    margin-bottom: 0;
}

.comment-form input[type="submit"] {
    background: #00bcd4;
    color: #fff;
    border: none;
    padding: 0.85rem 2rem;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.comment-form input[type="submit"]:hover {
    background: #00a5bb;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 188, 212, 0.4);
}

.comment-notes,
.logged-in-as {
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 1.5rem;
}

/* ========================================
   Search Results
======================================== */
.search-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.search-header {
    text-align: center;
    margin-bottom: 3rem;
}

.search-title {
    color: #fff;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
}

.search-title span {
    color: #00bcd4;
}

.search-form-large {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    background: #fff;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.search-form-large input[type="search"] {
    flex: 1;
    border: none;
    padding: 1rem 1.5rem;
    font-size: 1rem;
    outline: none;
}

.search-form-large button {
    background: #00bcd4;
    border: none;
    padding: 1rem 1.5rem;
    cursor: pointer;
    transition: background 0.2s ease;
}

.search-form-large button:hover {
    background: #00a5bb;
}

.search-form-large button svg {
    width: 20px;
    height: 20px;
    color: #fff;
}

.search-results {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.search-result {
    background: #fff;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    display: flex;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.search-result:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.search-result-image {
    flex-shrink: 0;
    width: 150px;
}

.search-result-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-result-content {
    padding: 1.25rem;
    flex: 1;
}

.search-result-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.search-result-title a {
    color: #333;
    transition: color 0.2s ease;
}

.search-result-title a:hover {
    color: #00bcd4;
}

.search-result-meta {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.search-result-meta svg {
    width: 14px;
    height: 14px;
}

.search-result-excerpt {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
}

.no-results {
    text-align: center;
    padding: 4rem 2rem;
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.no-results h2 {
    color: #333;
    margin-bottom: 0.5rem;
}

.no-results p {
    color: #666;
}

/* ========================================
   Responsive Design
======================================== */
@media (max-width: 992px) {
    .timeline-item {
        width: calc(50% - 35px);
    }

    .timeline-item:nth-child(odd) {
        margin-right: 35px;
    }

    .timeline-item:nth-child(even) {
        margin-left: 35px;
    }

    .timeline-item:nth-child(odd)::before {
        right: -35px;
        width: 28px;
    }

    .timeline-item:nth-child(even)::before {
        left: -35px;
        width: 28px;
    }

    .timeline-item:nth-child(odd)::after {
        right: -42px;
    }

    .timeline-item:nth-child(even)::after {
        left: -42px;
    }
}

@media (max-width: 768px) {
    .hero-header {
        height: 250px;
    }

    .site-title {
        font-size: 2.5rem;
    }

    .nav-bar {
        padding: 1rem;
    }

    .nav-search input[type="search"] {
        width: 100px;
    }

    .profile-image-wrapper {
        display: none;
    }

    .social-icons a {
        width: 28px;
        height: 28px;
        font-size: 0.9rem;
    }

    .timeline-container {
        padding: 2rem 1rem;
    }

    /* Mobile: Einspaltiges Layout */
    .timeline-line {
        left: 20px;
        margin-left: 0;
    }

    .timeline-item,
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        float: none;
        width: calc(100% - 50px);
        margin-left: 50px;
        margin-right: 0;
        margin-bottom: 2rem;
    }

    .timeline-item:nth-child(odd)::before,
    .timeline-item:nth-child(even)::before {
        left: -30px;
        right: auto;
        width: 23px;
    }

    .timeline-item:nth-child(odd)::after,
    .timeline-item:nth-child(even)::after {
        left: -37px;
        right: auto;
    }

    .timeline-card-image {
        height: 180px;
    }

    .timeline-card-title {
        font-size: 1.2rem;
    }

    .year-header {
        margin-bottom: 1.5rem;
    }

    .year-select-wrapper select {
        font-size: 1.2rem;
        padding: 0.5rem 2rem 0.5rem 1.5rem;
    }

    .timeline-footer {
        margin-left: 20px;
    }

    .timeline-footer-line {
        margin-left: 0;
    }
}

@media (max-width: 480px) {
    .site-title {
        font-size: 2rem;
    }

    .site-subtitle {
        font-size: 0.9rem;
    }

    .grid-icon {
        display: none;
    }

    .nav-search {
        display: none;
    }

    /* Search Results responsive */
    .search-result {
        flex-direction: column;
    }

    .search-result-image {
        width: 100%;
        height: 150px;
    }

    .timeline-line {
        left: 15px;
    }

    .timeline-item,
    .timeline-item:nth-child(odd),
    .timeline-item:nth-child(even) {
        width: calc(100% - 40px);
        margin-left: 40px;
    }

    .timeline-item:nth-child(odd)::before,
    .timeline-item:nth-child(even)::before {
        left: -25px;
        width: 18px;
    }

    .timeline-item:nth-child(odd)::after,
    .timeline-item:nth-child(even)::after {
        left: -30px;
        width: 10px;
        height: 10px;
        top: 32px;
    }

    .timeline-date {
        font-size: 0.75rem;
        padding: 0.3rem 0.6rem;
    }

    .timeline-meta {
        top: 10px;
        left: 10px;
    }

    .timeline-footer {
        margin-left: 15px;
    }

    /* Post Navigation responsive */
    .post-navigation .nav-links {
        flex-direction: column;
    }

    .post-navigation .nav-next {
        text-align: left;
    }

    /* Comments responsive */
    .comments-area {
        padding: 0 1rem;
    }

    .comment-respond {
        padding: 1.5rem;
    }
}
