
:root {
    --cream: #faf8f5;
    --cream-dark: #e5e0d8;
    --header-bg: #5c7a65;
    --accent: #c9703b;
    --text: #3d3d3d;
    --text-light: #6b6b6b;
    --sidebar-width: 280px;
}

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

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--cream);
    color: var(--text);
    line-height: 1.7;
}

/* HEADER */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    height: 100px;
    overflow: hidden;
    background: linear-gradient(to right, var(--header-bg) 0%, var(--header-bg) 40%, transparent 70%);
}

.site-header.tall {
    height: 180px;
}

.header-photo {
    position: absolute;
    right: -30px;
    top: 50%;
    transform: translateY(-50%);
    height: 160%;
    width: auto;
    object-fit: cover;
}

.header-content {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    padding-left: 25px;
    z-index: 2;
}

.logo-text {
    font-family: 'Work Sans', sans-serif;
    font-style: italic;
    font-weight: 700;
    font-size: 32px;
    color: white;
    text-decoration: none;
}

.site-header.tall .logo-text {
    font-size: 42px;
}

.tagline {
    font-size: 10px;
    color: rgba(255,255,255,0.85);
    letter-spacing: 1.5px;
    margin-top: 4px;
    text-transform: uppercase;
}

.site-header.tall .tagline {
    font-size: 12px;
    margin-top: 8px;
}

/* NAV BAR */
.main-nav {
    background: var(--header-bg);
    border-top: 1px solid rgba(255,255,255,0.1);
    border-bottom: 3px solid var(--accent);
    position: sticky;
    top: 100px;
    z-index: 99;
}

.site-header.tall + .main-nav {
    top: 180px;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    gap: 25px;
}

.hamburger {
    display: flex;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
    padding: 8px;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 4px;
    margin-right: 10px;
    transition: background 0.2s;
}

.hamburger:hover {
    background: rgba(255,255,255,0.2);
}

.hamburger span {
    width: 18px;
    height: 2px;
    background: white;
    display: block;
}

.main-nav a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 12px 0;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.main-nav a:hover,
.main-nav a.active {
    color: white;
    border-bottom-color: white;
}

/* STATS BAR */
.stats-bar {
    background: var(--accent);
    color: white;
    padding: 25px 40px;
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
}

.stat-number {
    font-family: 'Work Sans', sans-serif;
    font-size: 2.2rem;
    font-weight: 700;
}

.stat-label {
    font-size: 0.85rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* PAGE LAYOUT */
.page-layout {
    display: flex;
    min-height: calc(100vh - 200px);
}

/* SIDEBAR */
.sidebar {
    width: var(--sidebar-width);
    background: white;
    border-right: 1px solid var(--cream-dark);
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    overflow-y: auto;
    z-index: 90;
    padding-top: 147px;
    box-shadow: 2px 0 15px rgba(0,0,0,0.08);
    transition: transform 0.3s;
}

.sidebar.closed {
    transform: translateX(-100%);
}

.sidebar-header {
    padding: 15px 20px;
    border-bottom: 1px solid var(--cream-dark);
    background: var(--cream);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-title {
    font-family: 'Work Sans', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--header-bg);
}

.sidebar-close {
    background: none;
    border: none;
    font-size: 1.3rem;
    cursor: pointer;
    color: var(--text-light);
    padding: 0 5px;
}

/* Sidebar region accordion */
.sidebar-region {
    border-bottom: 1px solid var(--cream-dark);
}

.sidebar-region-header {
    padding: 12px 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
}

.sidebar-region-header:hover {
    background: var(--cream);
}

.sidebar-region.expanded .sidebar-region-header {
    background: var(--header-bg);
    color: white;
}

.sidebar-region-name {
    font-size: 0.85rem;
    font-weight: 500;
}

.sidebar-region-arrow {
    font-size: 0.7rem;
    transition: transform 0.2s;
}

.sidebar-region.expanded .sidebar-region-arrow {
    transform: rotate(180deg);
}

.sidebar-entries {
    display: none;
    background: var(--cream);
    max-height: 300px;
    overflow-y: auto;
}

.sidebar-region.expanded .sidebar-entries {
    display: block;
}

.sidebar-entry {
    display: block;
    padding: 8px 20px 8px 25px;
    font-size: 0.8rem;
    color: var(--text);
    text-decoration: none;
    border-top: 1px solid var(--cream-dark);
    transition: all 0.2s;
}

.sidebar-entry:hover {
    background: white;
    color: var(--accent);
}

.sidebar-entry.active {
    background: var(--accent);
    color: white;
}

.sidebar-gallery-link {
    display: block;
    padding: 10px 20px 10px 25px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--header-bg);
    text-decoration: none;
    border-top: 1px solid var(--cream-dark);
    background: white;
}

.sidebar-gallery-link:hover {
    color: var(--accent);
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    padding: 40px;
    margin-left: var(--sidebar-width);
    max-width: calc(100% - var(--sidebar-width));
}

.main-content.full-width {
    margin-left: 0;
    max-width: 100%;
}

.content-container {
    max-width: 900px;
    margin: 0 auto;
}

/* REGION TILES */
.section-title {
    font-family: 'Work Sans', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--header-bg);
    margin-bottom: 10px;
}

.section-subtitle {
    color: var(--text-light);
    margin-bottom: 30px;
}

.region-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.region-tile {
    background: white;
    border: 1px solid var(--cream-dark);
    padding: 25px;
    transition: all 0.2s;
}

.region-tile:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.region-tile .year-tag {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    margin-bottom: 8px;
}

.region-tile h3 {
    font-family: 'Work Sans', sans-serif;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--header-bg);
    margin-bottom: 10px;
}

.region-tile .region-info {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 15px;
}

.tile-links {
    display: flex;
    gap: 10px;
    padding-top: 15px;
    border-top: 1px solid var(--cream-dark);
}

.tile-link {
    flex: 1;
    text-align: center;
    padding: 10px 12px;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.2s;
}

.tile-link.journal-link {
    background: var(--header-bg);
    color: white;
}

.tile-link.journal-link:hover {
    background: #4a6552;
}

.tile-link.photo-link {
    background: var(--accent);
    color: white;
}

.tile-link.photo-link:hover {
    background: #b5612f;
}

/* ENTRY LIST */
.entry-list {
    list-style: none;
}

.entry-list-item {
    border-bottom: 1px solid var(--cream-dark);
}

.entry-list-item a {
    display: block;
    padding: 18px 15px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
}

.entry-list-item a:hover {
    background: white;
    padding-left: 25px;
}

.entry-date {
    font-size: 0.85rem;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 3px;
}

.entry-route {
    font-family: 'Work Sans', sans-serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--header-bg);
    margin-bottom: 3px;
}

.entry-miles {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* ENTRY PAGE */
.breadcrumb {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-bottom: 20px;
}

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

.breadcrumb a:hover {
    text-decoration: underline;
}

.entry-header {
    margin-bottom: 35px;
    padding-bottom: 25px;
    border-bottom: 3px solid var(--header-bg);
}

.entry-header .region-tag {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 4px 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.entry-header .date {
    font-size: 0.9rem;
    color: var(--accent);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.entry-header .route {
    font-family: 'Work Sans', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--header-bg);
    margin-bottom: 10px;
    line-height: 1.2;
}

.entry-header .miles {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 15px;
}

.entry-header .miles strong {
    color: var(--accent);
}

.header-gallery-link {
    display: inline-block;
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    padding: 8px 16px;
    border: 1px solid var(--accent);
    border-radius: 4px;
    transition: all 0.2s;
}

.header-gallery-link:hover {
    background: var(--accent);
    color: white;
}

.entry-content {
    font-size: 1.05rem;
    line-height: 1.85;
}

.entry-content p {
    margin-bottom: 1.4em;
}

.entry-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 50px;
    padding-top: 25px;
    border-top: 1px solid var(--cream-dark);
}

.entry-nav a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 500;
    padding: 10px 0;
}

.entry-nav a:hover {
    text-decoration: underline;
}

/* GALLERY PAGE */
.gallery-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 3px solid var(--header-bg);
}

.gallery-header .region-tag {
    display: inline-block;
    background: var(--accent);
    color: white;
    padding: 4px 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.gallery-header h1 {
    font-family: 'Work Sans', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--header-bg);
    margin-bottom: 10px;
}

.gallery-header .gallery-info {
    font-size: 0.95rem;
    color: var(--text-light);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.gallery-item {
    background: white;
    border: 1px solid var(--cream-dark);
    overflow: hidden;
}

.gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.gallery-item .caption {
    padding: 12px 15px;
    font-size: 0.85rem;
    color: var(--text);
    background: var(--cream);
    min-height: 50px;
}

.gallery-item .caption.empty {
    font-style: italic;
    color: var(--text-light);
}

/* FOOTER */
.site-footer {
    background: var(--header-bg);
    color: white;
    padding: 30px 40px;
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 15px;
}

.footer-links a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
}

.footer-links a:hover {
    color: white;
}

.copyright {
    font-size: 0.85rem;
    opacity: 0.7;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        max-width: 100%;
        padding: 25px 20px;
    }
    
    .stats-bar {
        gap: 30px;
        padding: 20px;
    }
    
    .stat-number {
        font-size: 1.6rem;
    }
    
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

@media (max-width: 600px) {
    .site-header {
        height: 80px;
    }
    
    .site-header.tall {
        height: 120px;
    }
    
    .logo-text {
        font-size: 26px;
    }
    
    .site-header.tall .logo-text {
        font-size: 32px;
    }
    
    .main-nav {
        top: 80px;
    }
    
    .region-tiles {
        grid-template-columns: 1fr;
    }
    
    .tile-links {
        flex-direction: column;
    }
    
    .gallery-grid {
        grid-template-columns: 1fr;
    }
}
