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

html, body {
    height: 100%;
}

body {
    font-family: Georgia, "Times New Roman", serif;
    background: #e8e4db;
    color: #2c2c2c;
}

.site-main {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 2rem;
    text-align: center;
}

.site-inner {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.site-title {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: normal;
    letter-spacing: 0.04em;
    color: #1a1a1a;
}

.site-contact a {
    color: #5a6e5a;
    text-decoration: none;
    font-size: 1rem;
    letter-spacing: 0.02em;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.site-contact a:hover {
    border-color: #5a6e5a;
}

/* Hamburger nav */
.hamburger-nav {
    position: fixed;
    top: 1rem;
    left: 1.5rem;
    z-index: 200;
}

.hamburger-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.4rem;
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
}

.hamburger-btn span {
    display: block;
    width: 22px;
    height: 2px;
    background: #5a6e5a;
    transition: transform 0.2s, opacity 0.2s;
}

.hamburger-nav.is-open .hamburger-btn span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger-nav.is-open .hamburger-btn span:nth-child(2) {
    opacity: 0;
}

.hamburger-nav.is-open .hamburger-btn span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.nav-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    list-style: none;
    background: #f5f2eb;
    border: 1px solid #d0ccc0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    min-width: 160px;
    padding: 0.4rem 0;
}

.nav-menu[hidden] {
    display: none;
}

.nav-menu a,
.nav-menu button {
    display: block;
    width: 100%;
    padding: 0.6rem 1.25rem;
    color: #2c2c2c;
    text-decoration: none;
    font: inherit;
    font-size: 0.9rem;
    background: none;
    border: none;
    text-align: left;
    cursor: pointer;
    white-space: nowrap;
}

.nav-menu a:hover,
.nav-menu button:hover {
    background: #e8e4db;
    color: #5a6e5a;
}

/* Forum layout */
.forum {
    max-width: 68rem;
    margin: 0 auto;
    padding: 3rem 1.5rem 4rem;
}

.forum h1, .forum h2 {
    font-weight: normal;
    letter-spacing: 0.03em;
    color: #1a1a1a;
    margin-bottom: 1rem;
}

.forum h1 {
    font-size: 1.75rem;
}

.forum h2 {
    font-size: 1.25rem;
}

.forum-crumbs {
    font-size: 0.85rem;
    color: #7a7a7a;
    margin-bottom: 1.5rem;
}

.forum-crumbs a {
    color: #5a6e5a;
    text-decoration: none;
}

.forum-crumbs a:hover {
    text-decoration: underline;
}

.forum-list {
    list-style: none;
    border-top: 1px solid #e3e0d8;
}

.forum-list li {
    border-bottom: 1px solid #e3e0d8;
    border-left: 3px solid transparent;
    padding: 0 0 0 0.75rem;
    transition: border-left-color 0.15s;
}

.forum-list li:hover {
    border-left-color: #5a6e5a;
}

.forum-list-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem 0;
}

.forum-list-main {
    flex: 1;
}

.forum-list-count {
    flex-shrink: 0;
    min-width: 3.5rem;
    text-align: right;
    font-size: 1.2rem;
    color: #5a6e5a;
    line-height: 1.2;
}

.forum-list-count span {
    display: block;
    font-size: 0.72rem;
    color: #9a9a9a;
    letter-spacing: 0.03em;
}

.forum-list a {
    color: #1a1a1a;
    text-decoration: none;
}

.forum-list a:hover {
    color: #5a6e5a;
}

.forum-meta {
    font-size: 0.85rem;
    color: #7a7a7a;
    margin-top: 0.25rem;
}

.forum-post {
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    padding: 1.25rem 1.5rem;
    margin-bottom: 1rem;
}

.forum-post-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: #7a7a7a;
    margin-bottom: 0.5rem;
}

.forum-post-header .author {
    color: #1a1a1a;
    font-weight: 600;
    text-decoration: none;
}

.forum-post-body {
    white-space: pre-wrap;
    line-height: 1.55;
}

.forum-post-image {
    margin-top: 0.75rem;
    max-width: 100%;
    height: auto;
    border: 1px solid #e3e0d8;
}

.forum-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.forum-avatar--lg {
    width: 96px;
    height: 96px;
}

.forum-form {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.forum-form label {
    font-size: 0.9rem;
    color: #4a4a4a;
}

.forum-form input[type="text"],
.forum-form input[type="email"],
.forum-form input[type="password"],
.forum-form textarea {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #d0ccc0;
    background: #fff;
    font: inherit;
}

.forum-form textarea {
    resize: vertical;
    min-height: 6rem;
}

.forum-form button {
    padding: 0.5rem 1rem;
    border: 1px solid #5a6e5a;
    background: #5a6e5a;
    color: #fff;
    font: inherit;
    cursor: pointer;
    align-self: flex-start;
}

.forum-form button:hover {
    background: #4a5c4a;
}

.forum-form .errorlist {
    list-style: none;
    color: #a04040;
    font-size: 0.85rem;
}

.forum-badge {
    font-size: 0.75rem;
    color: #5a6e5a;
    border: 1px solid #5a6e5a;
    padding: 0.05rem 0.4rem;
    margin-right: 0.4rem;
    border-radius: 2px;
}

.forum-actions {
    margin-top: 1.5rem;
    font-size: 0.9rem;
}

.forum-actions a {
    color: #5a6e5a;
    text-decoration: none;
}

.forum-actions a:hover {
    text-decoration: underline;
}

/* Lightbox */
.forum-post-image {
    cursor: zoom-in;
}

.lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    z-index: 1000;
    overflow-y: auto;
    padding: 2rem 1rem;
    cursor: zoom-out;
}

.lightbox-overlay.is-open {
    display: flex;
    align-items: flex-start;
    justify-content: center;
}

.lightbox-img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 3px;
    box-shadow: 0 4px 32px rgba(0,0,0,0.5);
    cursor: default;
    align-self: center;
}

/* Responsive */
@media (max-width: 720px) {
    .forum {
        padding: 1.5rem 1rem 3rem;
    }

    .forum-post {
        padding: 1rem 1rem;
    }
}