:root {
  color-scheme: light;
  --paper: #f7f4ed;
  --paper-deep: #ede8dc;
  --ink: #28352e;
  --muted: #788077;
  --green: #345947;
  --green-dark: #203d30;
  --sage: #dce6d9;
  --terracotta: #b56b4d;
  --line: #e5e0d5;
  --white: #fffefa;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  background: var(--paper);
  color: var(--ink);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--paper); }
a { color: inherit; text-decoration: none; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }

.site-header {
  height: 76px;
  padding: 0 clamp(20px, 6vw, 88px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(49, 70, 57, .08);
}
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--green-dark); font-weight: 700; letter-spacing: .04em; }
.brand-mark { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 50% 50% 48% 52%; background: var(--green); color: #f5f1e7; font-size: 16px; font-weight: 500; transform: rotate(-8deg); }
.admin-link { color: var(--green); font-size: 13px; font-weight: 600; }
.admin-link span { margin-left: 4px; color: var(--terracotta); }

main { max-width: 1140px; margin: 0 auto; padding: 0 28px; }
.hero { padding: clamp(64px, 9vw, 120px) 0 76px; text-align: center; }
.eyebrow { margin: 0 0 16px; color: var(--terracotta); font-size: 11px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; }
.hero h1, .admin-intro h1 { margin: 0; color: var(--green-dark); font-size: clamp(33px, 5vw, 52px); font-weight: 600; letter-spacing: .08em; line-height: 1.28; }
.hero-copy { max-width: 530px; margin: 19px auto 30px; color: var(--muted); font-size: 14px; line-height: 1.9; }
.search-form { display: flex; align-items: center; max-width: 590px; height: 58px; margin: 0 auto; padding: 6px 7px 6px 20px; border: 1px solid #e3ded2; border-radius: 8px; background: var(--white); box-shadow: 0 8px 26px rgba(56, 65, 48, .045); text-align: left; }
.search-icon { margin-right: 12px; color: #9a9e91; font-size: 26px; line-height: 1; }
.search-form input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 14px; }
.search-form input::placeholder { color: #a9aaa0; }
.search-form button, .primary-button { min-height: 44px; padding: 0 22px; border: 0; border-radius: 6px; background: var(--green); color: white; font-size: 13px; font-weight: 600; transition: background .2s ease, transform .2s ease; }
.search-form button:hover, .primary-button:hover { background: var(--green-dark); transform: translateY(-1px); }
.search-hint { min-height: 18px; margin: 12px 0 0; color: #9b9e92; font-size: 11px; }

.guides-section { padding: 0 0 98px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 27px; }
.section-heading .eyebrow { margin-bottom: 8px; font-size: 9px; letter-spacing: .22em; }
.section-heading h2 { margin: 0; color: var(--green-dark); font-size: 23px; font-weight: 600; letter-spacing: .08em; }
.result-count { color: var(--muted); font-size: 12px; }
.guide-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 21px; }
.guide-card { min-height: 224px; display: flex; flex-direction: column; padding: 22px; border: 1px solid var(--line); border-radius: 8px; background: var(--white); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.guide-card:hover { transform: translateY(-3px); border-color: #c9d3c7; box-shadow: 0 14px 32px rgba(44, 59, 48, .08); }
.guide-card-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.destination { color: var(--terracotta); font-size: 11px; font-weight: 600; letter-spacing: .08em; }
.guide-date { color: #a2a49a; font-size: 10px; }
.guide-card h3 { margin: 19px 0 8px; color: var(--green-dark); font-size: 18px; font-weight: 600; line-height: 1.55; }
.guide-summary { display: -webkit-box; overflow: hidden; margin: 0 0 18px; color: #777f76; font-size: 12px; line-height: 1.8; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.guide-card-bottom { display: flex; flex: 1; align-items: end; justify-content: space-between; gap: 10px; }
.tag-list { display: flex; flex-wrap: wrap; gap: 6px; }
.guide-tag { padding: 4px 8px; border-radius: 4px; background: #f1f3ec; color: #667765; font-size: 10px; }
.open-guide { display: inline-flex; align-items: center; gap: 7px; color: var(--green); font-size: 11px; font-weight: 600; white-space: nowrap; }
.open-guide span { color: var(--terracotta); font-size: 15px; }
.empty-state { padding: 62px 20px; border: 1px dashed #d8d4c9; border-radius: 8px; text-align: center; }
.empty-illustration { display: inline-grid; place-items: center; width: 54px; height: 54px; margin-bottom: 10px; border-radius: 50%; background: #e9eee4; color: var(--green); font-size: 29px; }
.empty-state h3 { margin: 0 0 8px; color: var(--green-dark); font-size: 16px; font-weight: 600; }
.empty-state p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.8; }
.site-footer { display: flex; align-items: center; justify-content: space-between; padding: 23px clamp(20px, 6vw, 88px); border-top: 1px solid rgba(49, 70, 57, .08); color: #93968b; font-size: 10px; letter-spacing: .06em; }
.site-footer span:last-child { letter-spacing: .18em; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.admin-main { max-width: 830px; padding-top: 72px; padding-bottom: 80px; }
.admin-intro { margin: 0 0 30px; }
.admin-intro h1 { font-size: clamp(30px, 4vw, 40px); letter-spacing: .05em; }
.admin-intro > p:last-child { max-width: 620px; margin: 14px 0 0; color: var(--muted); font-size: 13px; line-height: 1.9; }
.upload-card { padding: clamp(20px, 4vw, 36px); border: 1px solid var(--line); border-radius: 9px; background: var(--white); box-shadow: 0 12px 36px rgba(56, 65, 48, .04); }
.card-heading { display: flex; gap: 15px; margin-bottom: 24px; }
.step-number { display: grid; flex: 0 0 36px; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--sage); color: var(--green); font-size: 10px; font-weight: 700; }
.card-heading h2 { margin: 0 0 5px; color: var(--green-dark); font-size: 17px; font-weight: 600; }
.card-heading p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.7; }
.file-picker { display: flex; align-items: center; gap: 14px; min-height: 82px; padding: 14px 17px; border: 1px dashed #cfd8cb; border-radius: 7px; background: #fafbf7; cursor: pointer; }
.file-picker:hover { border-color: var(--green); background: #f5f8f1; }
.file-picker input { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.file-icon { display: grid; flex: 0 0 38px; place-items: center; width: 38px; height: 38px; border-radius: 6px; background: #e6ede2; color: var(--green); font-size: 23px; }
.file-picker-copy { display: flex; flex: 1; min-width: 0; flex-direction: column; gap: 4px; }
.file-picker-copy strong { overflow: hidden; color: var(--ink); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.file-picker-copy small, .file-picker-action { color: var(--muted); font-size: 10px; }
.file-picker-action { padding: 9px 12px; border: 1px solid #e0e4db; border-radius: 5px; background: white; color: var(--green); font-weight: 600; white-space: nowrap; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 16px; margin-top: 24px; }
.field { display: flex; min-width: 0; flex-direction: column; gap: 8px; color: #4f5e52; font-size: 11px; font-weight: 600; }
.field > span { display: flex; align-items: baseline; gap: 7px; }
.field b { color: var(--terracotta); font-size: 9px; font-weight: 500; }
.field small { color: #9b9e92; font-size: 9px; font-weight: 400; }
.field input, .field textarea { width: 100%; min-height: 42px; padding: 10px 12px; border: 1px solid #e5e3da; border-radius: 5px; outline: 0; background: #fff; color: var(--ink); font-size: 12px; font-weight: 400; }
.field input:focus, .field textarea:focus { border-color: #9aaf9a; box-shadow: 0 0 0 3px rgba(92, 126, 94, .11); }
.field input::placeholder, .field textarea::placeholder { color: #b0b1a9; }
.field textarea { min-height: 78px; resize: vertical; line-height: 1.7; }
.field-wide { grid-column: 1 / -1; }
.slug-field { display: flex; min-width: 0; align-items: center; border: 1px solid #e5e3da; border-radius: 5px; background: white; }
.slug-field:focus-within { border-color: #9aaf9a; box-shadow: 0 0 0 3px rgba(92, 126, 94, .11); }
.slug-field span { padding: 0 0 0 12px; color: #92968c; font-size: 11px; white-space: nowrap; }
.slug-field input { min-width: 0; border: 0; box-shadow: none !important; }
.field-help { color: #969b90; font-size: 10px; font-weight: 400; }
.guide-preview { margin-top: 25px; padding-top: 24px; border-top: 1px solid #efede7; }
.preview-label { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; }
.preview-label .step-number { background: #f2e7db; color: var(--terracotta); }
.preview-label h2 { margin: 0 0 4px; color: var(--green-dark); font-size: 13px; font-weight: 600; }
.preview-label p { margin: 0; color: var(--muted); font-size: 10px; }
.preview-card { max-width: 430px; min-height: 150px; padding: 18px; border: 1px solid var(--line); border-radius: 7px; background: #fffefa; }
.preview-destination { color: var(--terracotta); font-size: 10px; font-weight: 600; letter-spacing: .08em; }
.preview-card h3 { margin: 12px 0 6px; color: var(--green-dark); font-size: 15px; font-weight: 600; }
.preview-card > p { margin: 0 0 14px; color: var(--muted); font-size: 10px; line-height: 1.7; }
.preview-bottom { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.preview-url { overflow: hidden; color: #92968c; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.upload-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 27px; padding-top: 22px; border-top: 1px solid #efede7; }
.privacy-note { margin: 0; color: #888f84; font-size: 10px; line-height: 1.6; }
.primary-button { min-height: 46px; padding: 0 19px; white-space: nowrap; }
.primary-button span { margin-left: 14px; color: #d5dfd2; font-size: 17px; vertical-align: -1px; }
.primary-button:disabled { cursor: wait; opacity: .7; transform: none; }
.form-status { min-height: 20px; margin: 12px 0 0; color: var(--muted); font-size: 11px; line-height: 1.7; }
.form-status[data-kind="error"] { color: #a34b35; }
.form-status[data-kind="success"] { color: var(--green); }
.form-status a { color: var(--green); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.admin-tip { display: flex; gap: 12px; margin: 19px 2px; color: #858c80; font-size: 11px; line-height: 1.8; }
.admin-tip span { color: var(--terracotta); font-size: 16px; }
.admin-tip p { margin: 0; }

@media (max-width: 760px) {
  .site-header { height: 65px; padding: 0 20px; }
  main { padding-right: 20px; padding-left: 20px; }
  .hero { padding: 69px 0 57px; }
  .hero-copy { max-width: 430px; font-size: 12px; }
  .guide-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .guide-card { min-height: 215px; padding: 18px; }
  .admin-main { padding-top: 54px; }
}
@media (max-width: 520px) {
  .brand { gap: 8px; font-size: 13px; }
  .brand-mark { width: 28px; height: 28px; }
  .admin-link { font-size: 11px; }
  .hero { padding-top: 60px; }
  .hero h1 { font-size: 33px; }
  .hero-copy { margin-top: 14px; }
  .search-form { height: 52px; padding-left: 14px; }
  .search-form input { font-size: 12px; }
  .search-form button { min-height: 40px; padding: 0 15px; font-size: 11px; }
  .guides-section { padding-bottom: 66px; }
  .guide-grid { grid-template-columns: 1fr; gap: 12px; }
  .guide-card { min-height: 192px; padding: 19px; }
  .site-footer { gap: 12px; font-size: 9px; }
  .admin-main { padding-top: 45px; }
  .admin-intro > p:last-child { font-size: 12px; }
  .upload-card { padding: 19px; }
  .file-picker { gap: 10px; padding: 12px; }
  .file-picker-action { padding: 8px 9px; font-size: 9px; }
  .form-grid { grid-template-columns: 1fr; gap: 16px; }
  .field-wide { grid-column: auto; }
  .upload-footer { align-items: stretch; flex-direction: column; }
  .primary-button { width: 100%; }
}
