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

body {
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #222;
    background: #f5f5f0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

body > main {
    flex: 1;
    min-width: 0;
}

a {
    color: #4a7c3f;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Header */
.site-header {
    background: #2d4a27;
    padding: 14px 24px;
}

.site-logo {
    color: #e8e0d0;
    font-size: 1.25rem;
    font-weight: bold;
    letter-spacing: 0.03em;
    text-decoration: none;
    display: flex;
    align-items: center;
}

.site-logo-img {
    height: 40px;
    width: auto;
    display: block;
}

.site-logo:hover {
    color: #fff;
    text-decoration: none;
}

/* Header auth buttons */
.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-header-auth {
    display: flex;
    gap: 8px;
}

.btn-auth {
    background: transparent;
    border: 1px solid #8aac82;
    color: #e8e0d0;
    padding: 6px 14px;
    font-size: 0.85rem;
    cursor: pointer;
    font-family: inherit;
}

.btn-auth:hover {
    background: rgba(255,255,255,0.1);
}

.btn-auth-primary {
    background: #4a7c3f;
    border-color: #4a7c3f;
    color: #fff;
}

.btn-auth-primary:hover {
    background: #3d6b34;
}

/* Modal */
.modal-open {
    overflow: hidden;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-overlay[hidden] {
    display: none;
}

.modal {
    background: #fff;
    width: 100%;
    max-width: 380px;
    padding: 28px 28px 24px;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 1.4rem;
    line-height: 1;
    color: #888;
    cursor: pointer;
    padding: 0;
}

.modal-close:hover {
    color: #333;
}

.modal-title {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: #222;
}

.modal-form .form-group {
    margin-bottom: 14px;
}

.modal-form label {
    display: block;
    font-size: 0.85rem;
    color: #555;
    margin-bottom: 4px;
}

.form-group-inline {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 14px;
}

.form-group-inline > label:first-child {
    font-size: 0.85rem;
    color: #555;
    white-space: nowrap;
    flex-shrink: 0;
}

.radio-group {
    display: flex;
    gap: 24px;
}

.radio-label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
    color: #333;
    cursor: pointer;
    white-space: nowrap;
}

.modal-form input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ccc;
    font-size: 0.95rem;
    font-family: inherit;
    outline: none;
}

.modal-form input[type="radio"] {
    width: auto;
    padding: 0;
    border: none;
    cursor: pointer;
    flex-shrink: 0;
}

.modal-form input:focus {
    border-color: #4a7c3f;
}

.form-msg {
    font-size: 0.85rem;
    padding: 8px 10px;
    margin-bottom: 12px;
}

.form-msg[hidden] {
    display: none;
}

.form-msg-error {
    background: #fdf0f0;
    border: 1px solid #e8b4b4;
    color: #8b2020;
}

.form-msg-success {
    background: #f0fdf0;
    border: 1px solid #a8d4a8;
    color: #1a5c1a;
}

.btn-submit {
    width: 100%;
    padding: 9px;
    background: #2d4a27;
    color: #fff;
    border: none;
    font-size: 0.95rem;
    font-family: inherit;
    cursor: pointer;
}

.btn-submit:hover {
    background: #3d6b34;
}

.modal-switch {
    text-align: center;
    font-size: 0.85rem;
    color: #666;
    margin-top: 14px;
    margin-bottom: 0;
}

/* Breadcrumb */
.breadcrumb {
    background: #e8e4dc;
    border-bottom: 1px solid #ccc;
    padding: 8px 24px;
    font-size: 0.875rem;
}

.breadcrumb ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: '\203A';
    margin-right: 4px;
    color: #888;
}

.breadcrumb-item.active {
    color: #555;
}

/* Layout */
.container {
    max-width: 860px;
    margin: 32px auto;
    padding: 0 20px;
}

/* Maintenance */
.maintenance h1 {
    font-size: 1.6rem;
    margin-bottom: 12px;
    color: #333;
}

.maintenance-msg {
    color: #666;
    font-style: italic;
    border-left: 4px solid #aaa;
    padding-left: 12px;
}

/* City list (country page) */
.city-list {
    list-style: none;
    columns: 3;
    column-gap: 24px;
    margin-top: 20px;
}

.city-list li {
    padding: 5px 0;
    border-bottom: 1px solid #eee;
    break-inside: avoid;
}

.city-list a {
    color: #4a7c3f;
}

@media (max-width: 600px) {
    .city-list { columns: 1; }
}

/* Seller list (city page) */
.seller-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.seller-card {
    background: #fff;
    border: 1px solid #ddd;
    padding: 16px;
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.seller-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    background: #ccc;
    flex-shrink: 0;
}

.seller-info h2 {
    font-size: 1.1rem;
    margin-bottom: 4px;
}

.seller-preview {
    color: #555;
    font-size: 0.9rem;
    margin-bottom: 4px;
}

.seller-date {
    font-size: 0.8rem;
    color: #999;
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
    vertical-align: middle;
    margin-left: 6px;
    position: relative;
    top: -1px;
    cursor: default;
    flex-shrink: 0;
}

.badge::after {
    content: attr(data-hint);
    display: none;
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: #fff;
    font-size: 0.72rem;
    font-weight: 500;
    white-space: nowrap;
    padding: 4px 8px;
    border-radius: 3px;
    pointer-events: none;
    z-index: 10;
    letter-spacing: 0;
    text-transform: none;
}

.badge:hover::after {
    display: block;
}

.badge-verified {
    background: #2d6e2d;
    color: #fff;
}

.badge-pending {
    background: #f5d060;
    color: #6b4a00;
}

/* Seller post */
.seller-post {
    background: #fff;
    border: 1px solid #ddd;
    padding: 24px;
    margin-bottom: 32px;
}

.post-header {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.post-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    background: #ccc;
    flex-shrink: 0;
}

.post-header h1 {
    font-size: 1.4rem;
    margin-bottom: 6px;
}

.post-meta {
    font-size: 0.85rem;
    color: #777;
}

.post-body p {
    margin-bottom: 10px;
    color: #333;
}

/* Contacts */
.seller-contacts {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #eee;
}

.contacts-heading {
    font-weight: bold;
    margin-bottom: 10px;
    color: #222;
}

.contacts-table {
    border-collapse: collapse;
    font-size: 0.9rem;
    width: 100%;
    table-layout: fixed;
}

.contacts-table tr + tr td {
    border-top: 1px solid #eee;
}

.ct-key {
    color: #888;
    padding: 5px 20px 5px 0;
    white-space: nowrap;
    vertical-align: top;
}

.ct-val {
    color: #222;
    padding: 5px 0;
    font-weight: bold;
    overflow-wrap: break-word;
    word-break: break-all;
}

.contacts-link {
    color: #4a7c3f;
}

/* Delivery info */
.seller-delivery {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #eee;
}

.delivery-payment {
    font-weight: bold;
    margin-bottom: 12px;
    color: #222;
}

.delivery-heading {
    font-weight: bold;
    margin-bottom: 8px;
    color: #222;
}

.delivery-steps {
    margin: 0;
    padding-left: 20px;
    color: #444;
    line-height: 1.7;
}

/* Menu image */
.menu-image {
    display: block;
    width: calc(100% + 48px);
    margin: 20px -24px 0;
    max-width: none;
}

/* Products */
.product-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.product-card {
    display: flex;
    gap: 14px;
    border: 1px solid #e0ddd6;
    background: #faf9f6;
    padding: 12px;
}

.product-image {
    width: 100px;
    height: 100px;
    object-fit: contain;
    background: #e8e4dc;
    flex-shrink: 0;
}

.product-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.product-title {
    font-size: 0.95rem;
    margin-bottom: 4px;
    color: #222;
}

.product-description {
    font-size: 0.85rem;
    color: #555;
    line-height: 1.5;
    flex: 1;
    margin-bottom: 8px;
}

.product-footer {
    border-top: 1px solid #e8e4dc;
    padding-top: 6px;
}

.pricing-table {
    border-collapse: collapse;
    margin-top: 10px;
    font-size: 0.85rem;
}

.pricing-table tr + tr td {
    border-top: 1px solid #eee;
}

.pt-amount {
    color: #666;
    padding: 3px 12px 3px 0;
    white-space: nowrap;
}

.pt-price {
    font-weight: bold;
    color: #2d4a27;
    padding: 3px 0;
}

/* Comments */
.comments {
    margin-top: 8px;
}

.comments-body {
    transition: opacity 0.15s ease;
}

.comments h2 {
    font-size: 1.15rem;
    margin-bottom: 16px;
    color: #333;
    border-bottom: 1px solid #ddd;
    padding-bottom: 8px;
}

.comment {
    display: flex;
    gap: 14px;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.comment:last-child {
    border-bottom: none;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    background: #ccc;
    flex-shrink: 0;
}

.comment-content {
    flex: 1;
}

.comment-meta {
    font-size: 0.85rem;
    margin-bottom: 4px;
}

.comment-date {
    color: #999;
    margin-left: 8px;
    font-size: 0.8rem;
}

.trip-report-images {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 12px;
}

.trip-report-images img {
    width: 100%;
    height: auto;
    display: block;
}

.comment-body {
    font-size: 0.95rem;
    color: #333;
    line-height: 1.6;
}


/* Pagination */
.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid #ddd;
}

.page-link {
    display: inline-block;
    padding: 6px 12px;
    border: 1px solid #ccc;
    background: #fff;
    color: #4a7c3f;
    font-size: 0.875rem;
    text-decoration: none;
}

.page-link:hover {
    background: #f0f0ea;
    text-decoration: none;
}

.page-current {
    background: #2d4a27;
    color: #fff;
    border-color: #2d4a27;
    font-weight: bold;
}

/* Lightbox */
#lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

#lightbox[hidden] {
    display: none;
}

#lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.82);
}

#lightbox-box {
    position: relative;
    z-index: 1;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

#lightbox-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    display: block;
    box-shadow: 0 8px 40px rgba(0,0,0,0.6);
}

#lightbox-close {
    position: absolute;
    top: -16px;
    right: -16px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #fff;
    border: none;
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
}

#lightbox-close:hover {
    background: #eee;
}

/* Contact form */
.contact-form {
    max-width: 560px;
    margin-top: 28px;
}

.contact-form .form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 18px;
}

.contact-form label {
    display: block;
    font-size: 0.85rem;
    color: #555;
    margin-bottom: 6px;
    font-weight: 600;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #ccc;
    font-size: 0.95rem;
    font-family: inherit;
    outline: none;
    background: #fff;
    color: #222;
    box-sizing: border-box;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #4a7c3f;
}

.contact-form textarea {
    resize: vertical;
    min-height: 140px;
}

.contact-submit {
    margin-top: 4px;
    width: auto;
    padding: 10px 32px;
    font-size: 1rem;
}

/* Static pages (privacy, terms) */
.static-page h1 {
    font-size: 1.6rem;
    margin-bottom: 6px;
    color: #222;
}

.static-date {
    font-size: 0.8rem;
    color: #999;
    margin-bottom: 28px;
}

.static-page h2 {
    font-size: 1.05rem;
    color: #2d4a27;
    margin: 24px 0 8px;
}

.static-page p {
    color: #444;
    line-height: 1.7;
    margin-bottom: 10px;
}

.static-page a {
    color: #4a7c3f;
}

/* Footer */
.site-footer {
    background: #2d4a27;
    color: #b0c4a8;
    text-align: center;
    padding: 16px 24px;
    font-size: 0.85rem;
    margin-top: 48px;
}

.footer-links {
    margin-top: 6px;
    margin-bottom: 10px;
    font-size: 0.8rem;
}

.footer-links a {
    color: #8aac82;
    text-decoration: none;
}

.footer-links a:hover {
    color: #fff;
}

.footer-sep {
    margin: 0 8px;
    color: #5a7a52;
}

/* City page two-column layout */
.city-layout {
    display: block;
    width: 100%;
}

.city-sellers {
    width: 100%;
}

.city-news {
    width: 100%;
    background: #fff;
    border: 1px solid #ddd;
    padding: 20px;
    margin-top: 32px;
}

.news-heading {
    font-size: 1.15rem;
    margin-bottom: 16px;
    color: #333;
    border-bottom: 1px solid #ddd;
    padding-bottom: 8px;
}

.news-item {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid #eee;
    text-decoration: none;
    color: inherit;
}

.news-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.news-item:hover .news-title {
    color: #4a7c3f;
}

.news-title {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.45;
    margin-bottom: 5px;
    color: #222;
}

.news-meta {
    display: block;
    font-size: 0.75rem;
    color: #999;
}

.news-source {
    font-weight: 600;
    color: #777;
}

.news-source::after {
    content: ' · ';
}

.news-loading,
.news-error {
    font-size: 0.875rem;
    color: #888;
    padding: 4px 0;
}

