:root {
    color-scheme: dark;
    --bg: #13100e;
    --bg-soft: #1d1815;
    --surface: #221c18;
    --surface-strong: #2c241f;
    --text: #f7efe7;
    --muted: #c5b3a5;
    --line: #44362e;
    --accent: #d98250;
    --accent-dark: #b96639;
    --accent-soft: rgba(217, 130, 80, 0.16);
    --blue: #7893a2;
    --blue-soft: rgba(120, 147, 162, 0.18);
    --danger: #ff8f7f;
    --danger-soft: rgba(255, 143, 127, 0.14);
    --shadow: 0 18px 42px rgba(0, 0, 0, 0.34);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 12% -10%, rgba(217, 130, 80, 0.18), transparent 34rem),
        linear-gradient(180deg, #171310 0%, var(--bg) 44%, #0f0d0b 100%);
    color: var(--text);
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.55;
}

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

img,
video {
    max-width: 100%;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 12px clamp(16px, 4vw, 42px);
    background: #000;
    border-bottom: 1px solid #000;
    backdrop-filter: blur(12px);
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    border-radius: 8px;
}

.brand img {
    display: block;
    width: 96px;
    height: auto;
    filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.28));
}

.brand span {
    color: #f7efe7;
    font-size: clamp(1rem, 2.6vw, 1.45rem);
    font-weight: 650;
    line-height: 1.2;
}

.top-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.top-nav a,
.filters a,
.button {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 9px 13px;
    background: var(--surface);
    color: var(--text);
    font-weight: 650;
}

.top-nav a:hover,
.filters a:hover,
.button:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.page {
    width: min(1100px, calc(100% - 32px));
    margin: 0 auto;
    padding: 34px 0 58px;
}

.intro,
.admin-title {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 24px;
}

h1,
h2 {
    margin: 0;
    line-height: 1.12;
}

h1 {
    color: #fff8f1;
    font-size: clamp(2rem, 6vw, 4.25rem);
}

h2 {
    color: #fff5ec;
    font-size: 1.35rem;
}

.intro p,
.admin-title p,
.meta,
time,
.date-line,
.row-card span,
.empty {
    color: var(--muted);
}

.button.primary,
.filters .active {
    border-color: var(--accent);
    background: var(--accent);
    color: #21120b;
}

.button.danger {
    border-color: rgba(255, 143, 127, 0.44);
    background: var(--danger-soft);
    color: var(--danger);
}

.filters {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 16px;
    scrollbar-color: var(--accent) transparent;
}

.filters a {
    white-space: nowrap;
}

.search-form {
    display: grid;
    grid-template-columns: 1fr auto auto;
    align-items: end;
    gap: 10px;
    margin-bottom: 16px;
}

.post-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 18px;
}

.post-card,
.row-card,
.form-shell {
    background: linear-gradient(180deg, var(--surface-strong), var(--surface));
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.post-card {
    overflow: hidden;
}

.post-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
    background: #0c0a09;
}

.post-card-body {
    padding: 18px;
}

.post-card-body p {
    margin-bottom: 0;
}

.score-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #f1c197;
    font-weight: 750;
}

.score-line span {
    border: 1px solid rgba(217, 130, 80, 0.42);
    border-radius: 999px;
    padding: 3px 9px;
    background: rgba(217, 130, 80, 0.12);
}

.post-detail {
    max-width: 860px;
    margin: 0 auto;
}

.post-heading {
    margin-bottom: 24px;
}

.post-heading h1 {
    margin: 8px 0 10px;
}

.date-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
    font-size: 0.95rem;
}

.tags,
.check-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tags span {
    border: 1px solid rgba(120, 147, 162, 0.46);
    border-radius: 999px;
    padding: 5px 10px;
    background: var(--blue-soft);
    color: #d7e5eb;
}

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
    margin-bottom: 28px;
}

.media-thumb {
    display: block;
}

.media-thumb:hover img {
    border-color: var(--accent);
    transform: translateY(-1px);
}

.media-grid img,
.media-grid video,
.media-strip img,
.media-strip video {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #0c0a09;
    object-fit: cover;
    transition: border-color 0.18s ease, transform 0.18s ease;
}

.media-grid video {
    aspect-ratio: 4 / 3;
}

.media-grid img {
    height: auto;
    max-height: 420px;
    object-fit: contain;
}

.content {
    color: #f2e8df;
    font-size: 1.08rem;
    margin-bottom: 26px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--line);
}

.content a,
.internal-post-link {
    color: var(--accent);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 4px;
}

.restaurant-panel,
.map-panel,
.map-page {
    margin-bottom: 26px;
}

.restaurant-panel {
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    padding: 20px 0;
}

.restaurant-panel h2,
.map-panel h2 {
    margin-bottom: 14px;
}

.fact-grid,
.rating-list {
    display: grid;
    gap: 10px;
    margin: 0;
}

.fact-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.rating-list {
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    margin-top: 14px;
}

.fact-grid div,
.rating-list div {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.16);
}

.fact-grid dt,
.rating-list dt {
    color: var(--muted);
    font-size: 0.85rem;
}

.fact-grid dd,
.rating-list dd {
    margin: 3px 0 0;
    color: var(--text);
    font-weight: 750;
}

.map-panel iframe,
.visit-map {
    width: 100%;
    min-height: 360px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #0c0a09;
}

.visit-map {
    height: min(72vh, 620px);
}

.map-list {
    margin-top: 18px;
}

.leaflet-popup-content a {
    display: grid;
    gap: 3px;
    color: #241710;
}

.leaflet-popup-content span {
    color: #654c3d;
}

.form-shell {
    padding: clamp(18px, 4vw, 30px);
}

.form-shell.narrow {
    max-width: 620px;
    margin-inline: auto;
}

form {
    display: grid;
    gap: 16px;
}

label,
fieldset {
    display: grid;
    gap: 7px;
    color: var(--muted);
    font-weight: 650;
}

input,
textarea,
select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px 13px;
    background: #171310;
    color: var(--text);
    font: inherit;
}

input:focus,
textarea:focus,
select:focus {
    outline: 2px solid rgba(217, 130, 80, 0.46);
    border-color: var(--accent);
}

textarea {
    resize: vertical;
}

fieldset {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 14px;
    background: rgba(0, 0, 0, 0.12);
}

legend {
    padding: 0 8px;
    color: var(--text);
}

.check-list label,
.switch {
    display: flex;
    align-items: center;
    gap: 9px;
    color: var(--text);
}

.check-list input,
.switch input {
    width: auto;
    accent-color: var(--accent);
}

.check-list small {
    color: var(--blue);
}

.field-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.notice {
    border-radius: 8px;
    padding: 11px 13px;
}

.notice.success {
    background: rgba(120, 147, 162, 0.18);
    color: #c9e4ee;
}

.notice.error {
    background: var(--danger-soft);
    color: var(--danger);
}

.table-list {
    display: grid;
    gap: 10px;
}

.row-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px;
}

.row-card div {
    display: grid;
    gap: 3px;
}

.inline-form {
    grid-template-columns: 1fr 160px auto;
    align-items: end;
}

.media-strip {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 8px;
}

.media-strip img,
.media-strip video {
    aspect-ratio: 1;
}

.site-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border-top: 1px solid var(--line);
    padding: 22px;
    text-align: center;
    color: var(--muted);
}

@media (max-width: 720px) {
    .site-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .top-nav {
        width: 100%;
        justify-content: flex-start;
    }

    .top-nav a {
        flex: 1 1 auto;
    }

    .intro,
    .admin-title,
    .row-card {
        align-items: stretch;
        flex-direction: column;
    }

    .field-grid,
    .inline-form,
    .search-form {
        grid-template-columns: 1fr;
    }

    .button {
        width: 100%;
    }
}

.media-manager {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.media-admin-item {
    display: grid;
    gap: 10px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.18);
}

.media-admin-item img,
.media-admin-item video {
    width: 100%;
    max-height: 300px;
    object-fit: contain;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #0c0a09;
}

.media-admin-controls {
    display: grid;
    gap: 10px;
}

.media-admin-controls input[type="number"],
.order-field input {
    max-width: 120px;
}

.media-admin-controls input[type="range"] {
    accent-color: var(--accent);
}

.category-row {
    display: grid;
    grid-template-columns: 130px 1fr auto;
}

.lightbox-open {
    overflow: hidden;
}

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 72px 18px 28px;
    background: rgba(8, 6, 5, 0.94);
}

.lightbox.open {
    display: flex;
}

.lightbox img {
    max-width: min(100%, 1180px);
    max-height: calc(100vh - 120px);
    object-fit: contain;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.lightbox button {
    position: fixed;
    width: 48px;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text);
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
}

.lightbox-close {
    top: 18px;
    right: 18px;
}

.lightbox-prev {
    left: 18px;
    top: 50%;
}

.lightbox-next {
    right: 18px;
    top: 50%;
}

@media (max-width: 720px) {
    .category-row {
        display: flex;
    }

    .lightbox {
        padding-inline: 10px;
    }

    .lightbox-prev,
    .lightbox-next {
        top: auto;
        bottom: 18px;
    }
}
.user-list {
    margin-top: 18px;
}

.user-card {
    padding: 18px;
}

.user-card form {
    gap: 12px;
}
.site-footer a {
    color: var(--text);
    text-decoration: underline;
    text-underline-offset: 4px;
}

.legal-page {
    max-width: 820px;
    margin-inline: auto;
}

.legal-page h2 {
    margin-top: 26px;
}

.legal-page p {
    color: var(--muted);
}
.backup-note {
    color: var(--muted);
}
.footer-separator {
    color: var(--line);
}
.media-rotate-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}
.media-figure {
    display: grid;
    gap: 8px;
    margin: 0;
}

.media-figure figcaption {
    color: var(--muted);
    font-size: 0.95rem;
    line-height: 1.35;
    padding: 0 2px;
}
.voice-memo {
    display: grid;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.14);
}

.voice-memo audio {
    width: 100%;
}
.hint-box {
    display: grid;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.14);
    color: var(--muted);
}

.hint-box p {
    margin: 0;
}

.link-token-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    max-height: 130px;
    overflow: auto;
}

.link-token-list code,
.hint-box code {
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 2px 6px;
    background: #171310;
    color: var(--text);
}
.views {
    color: var(--blue);
    font-size: 0.9rem;
    font-weight: 650;
}
.external-link {
    color: var(--accent);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 4px;
}
