:root {
  color-scheme:light;
  --ink:#20362e;
  --muted:#59675e;
  --pine:#184b37;
  --action:#176042;
  --line:#dce3d9;
  --paper:#fff;
  --wash:#f5f6f0;
  --soft:#eaf1e3;
  --error:#862d27;
}

* {
  box-sizing:border-box;
}

body {
  margin:0;
  background:var(--wash);
  color:var(--ink);
  font-family:"Pretendard","Apple SD Gothic Neo","Malgun Gothic",system-ui,sans-serif;
  font-size:16px;
  line-height:1.55;
  word-break:keep-all;
  overflow-wrap:anywhere;
}

a {
  color:var(--action);
  text-underline-offset:4px;
  text-decoration-thickness:1px;
}

button,input,select,textarea {
  font:inherit;
}

button,.button,.pager a {
  display:inline-flex;
  justify-content:center;
  align-items:center;
  min-height:42px;
  border-radius:8px;
  border:1px solid #becbbd;
  background:var(--paper);
  padding:8px 16px;
  color:var(--pine);
  font-weight:650;
  line-height:1.35;
  text-decoration:none;
  cursor:pointer;
}

button:hover,.button:hover,.pager a:hover {
  background:var(--soft);
}

a:focus-visible,button:focus-visible,summary:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible {
  outline:3px solid #488e67;
  outline-offset:3px;
}

.primary {
  background:var(--action);
  border-color:var(--action);
  color:#fff;
}

.primary:hover {
  background:var(--pine);
}

button.small {
  min-height:34px;
  font-size:13px;
  padding:5px 10px;
  border-color:#759483;
  color:#fff;
  background:transparent;
}

.wide {
  width:100%;
}

.skip {
  position:fixed;
  left:8px;
  top:-90px;
  background:white;
  color:var(--pine);
  padding:12px;
  z-index:2;
}

.skip:focus {
  top:8px;
}

.mast {
  background:var(--pine);
  color:#fff;
}

.mast-inner,.school-inner,.navigation>div {
  max-width:1020px;
  margin:auto;
  padding:0 30px;
  display:flex;
  align-items:center;
}

.mast-inner {
  min-height:66px;
  justify-content:space-between;
  gap:12px;
}

.brand {
  display:flex;
  align-items:center;
  gap:10px;
  color:white;
  font-size:20px;
  font-weight:750;
  text-decoration:none;
  letter-spacing:-.055em;
}

.brandmark {
  position:relative;
  width:26px;
  height:25px;
  display:block;
}

.brandmark i {
  position:absolute;
  display:block;
  background:#c2da82;
  border-radius:6px 1px 6px 1px;
  width:11px;
  height:11px;
}

.brandmark i:nth-child(1) {
  left:2px;
  top:3px;
}

.brandmark i:nth-child(2) {
  left:14px;
  top:0;
}

.brandmark i:nth-child(3) {
  left:8px;
  top:15px;
}

.identity,.school-inner {
  display:flex;
  align-items:center;
  gap:12px;
}

.identity {
  font-size:14px;
}

.schoolbar {
  background:white;
}

.school-inner {
  padding-top:13px;
  padding-bottom:12px;
}

.school-name {
  font-weight:720;
  font-size:17px;
  text-decoration:none;
}

.school-name span {
  color:var(--muted);
  margin-left:4px;
}

.school-inner b,.badge {
  display:inline-block;
  font-size:12px;
  border-radius:5px;
  background:var(--soft);
  color:#325d40;
  padding:2px 7px;
  font-weight:650;
}

.school-inner small {
  font-size:12px;
}

.navigation {
  background:var(--paper);
  border-top:1px solid #edf1e9;
  border-bottom:1px solid var(--line);
}

.navigation>div {
  gap:24px;
  overflow-x:auto;
}

.navigation a {
  display:block;
  color:var(--ink);
  font-weight:600;
  font-size:14px;
  padding:11px 0;
  white-space:nowrap;
  text-decoration:none;
}

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

main {
  max-width:1020px;
  margin:0 auto;
  padding:38px 30px 56px;
  min-height:calc(100vh - 220px);
}

footer {
  border-top:1px solid var(--line);
  max-width:960px;
  margin:0 auto;
  padding:20px 0 32px;
  color:var(--muted);
  font-size:13px;
  font-weight:700;
}

footer span {
  padding-left:8px;
  font-weight:400;
}

h1,h2,h3,p,ul,dl {
  margin:0;
}

h1 {
  font-size:clamp(1.75rem,4.8vw,2.65rem);
  line-height:1.2;
  letter-spacing:-.06em;
  margin-bottom:18px;
  font-weight:760;
}

h2 {
  font-size:1.25rem;
  letter-spacing:-.045em;
  line-height:1.4;
}

h3 {
  font-size:1rem;
  margin:16px 0 6px;
}

p {
  margin:8px 0 14px;
}

p:last-child {
  margin-bottom:0;
}

ul {
  padding-left:1.35rem;
}

.muted,small,.helptext {
  color:var(--muted);
}

.eyebrow {
  color:var(--action);
  font-size:14px;
  font-weight:700;
  margin:0 0 8px;
}

section+section,.split+section,.panel+.split,details.panel+section,form+.cards {
  margin-top:16px;
}

.heading,.filters,.mealrow,.rowlink {
  display:flex;
  align-items:center;
  gap:12px;
}

.heading {
  justify-content:space-between;
  margin-bottom:14px;
  flex-wrap:wrap;
}

.heading :is(h1,h2,p) {
  margin-bottom:0;
}

.pager {
  display:flex;
  gap:6px;
}

.pager a {
  font-size:22px;
  width:42px;
  padding:0;
}

.filters {
  flex-wrap:wrap;
  margin:16px 0 22px;
}

.filters label {
  display:flex;
  gap:8px;
  align-items:center;
  font-size:14px;
}

.filters input {
  max-width:100%;
}

.cards {
  display:grid;
  gap:9px;
}

.panel,.auth-panel {
  border:1px solid var(--line);
  border-radius:14px;
  background:var(--paper);
  padding:22px;
}

.panel h2 {
  margin-bottom:12px;
}

.panel .heading h2 {
  margin:0;
}

.split {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:15px;
  align-items:start;
  margin:16px 0;
}

.split>section+section {
  margin:0;
}

.grow {
  flex:1;
  min-width:0;
}

.rowlink {
  color:var(--ink);
  text-decoration:none;
  justify-content:space-between;
}

.rowlink:hover {
  border-color:#8fa991;
}

.rowlink p,.mealrow p {
  color:var(--muted);
  margin:4px 0 0;
  font-size:14px;
}

.mealrow {
  padding:14px 17px;
}

.dateblock {
  min-width:48px;
  text-align:center;
  background:var(--soft);
  border-radius:10px;
  padding:5px 6px;
}

.dateblock strong,.dateblock small {
  display:block;
  line-height:1.2;
}

.dateblock strong {
  font-size:22px;
  font-variant-numeric:tabular-nums;
}

.dateblock small {
  font-size:11px;
}

.empty {
  padding:24px;
  color:var(--muted);
  border:1px dashed #bfcbbb;
  border-radius:12px;
  background:#f9faf5;
}

.narrow {
  max-width:570px;
}

.auth-panel {
  max-width:460px;
  margin:4vh auto;
  padding:32px;
}

.auth-intro {
  border-bottom:1px solid var(--line);
  margin-bottom:20px;
  padding-bottom:8px;
}

.auth-intro p {
  color:var(--muted);
}

.auth-links {
  display:flex;
  justify-content:space-between;
  gap:12px;
  font-size:14px;
  margin-top:20px;
}

.notice {
  background:#eaf2df;
  color:#223b2a;
  border-radius:9px;
  padding:12px 16px;
  margin:10px 0;
}

.notice.error,.errorlist {
  color:var(--error);
  background:#fff0eb;
}

.highlight {
  background:#edf3e6;
  border-color:#cddcc3;
}

.back {
  display:inline-block;
  margin-top:18px;
}

.dishes {
  list-style:none;
  padding:0;
}

.dishes li {
  padding:9px 0;
  border-bottom:1px solid var(--line);
}

.dishes li:last-child {
  border:0;
}

.dishes small {
  display:block;
}

.facts>div {
  display:flex;
  justify-content:space-between;
  gap:10px;
  padding:6px 0;
  border-bottom:1px solid var(--line);
}

.facts dd {
  font-weight:650;
  margin:0;
  font-variant-numeric:tabular-nums;
}

.facts>div:last-child {
  border:0;
}

.formstack {
  display:grid;
  gap:14px;
}

.formstack div>label,.formstack>label,fieldset legend {
  display:block;
  font-weight:650;
}

.formstack :is(input:not([type="radio"]):not([type="checkbox"]),select,textarea) {
  width:100%;
  margin-top:4px;
}

input:not([type="radio"]):not([type="checkbox"]),select,textarea {
  border:1px solid #b4c2b4;
  border-radius:7px;
  padding:8px 10px;
  background:white;
  color:var(--ink);
  max-width:100%;
  min-height:42px;
}

textarea {
  resize:vertical;
}

input:disabled {
  color:var(--muted);
  background:#f0f2ed;
}

fieldset {
  border:0;
  min-width:0;
  padding:0;
  margin:0;
}

input[type="radio"],input[type="checkbox"] {
  width:17px;
  height:17px;
  accent-color:var(--action);
  vertical-align:middle;
}

.formstack fieldset>div>div label {
  display:inline-block;
  padding:4px;
  font-weight:500;
}

.formstack #id_rating {
  display:flex;
  gap:6px;
  flex-wrap:wrap;
}

.formstack .helptext {
  font-size:13px;
  margin-top:5px;
}

.helptext ul {
  margin-top:5px;
}

.errorlist {
  padding:8px 12px 8px 28px;
  border-radius:6px;
  list-style:disc;
}

details {
  margin:12px 0;
}

summary {
  font-weight:650;
  color:var(--action);
  cursor:pointer;
  min-height:30px;
}

details[open]>summary {
  margin-bottom:12px;
}

code {
  word-break:break-all;
}

.printrow {
  background:#fff;
  border-top:1px solid var(--line);
  padding:12px 14px;
  break-inside:avoid;
}

.printrow h2 {
  font-size:17px;
}

.printrow p {
  margin:4px 0;
}

.printrow p:last-child {
  color:var(--muted);
  font-size:13px;
}

@media(max-width:690px) {
  .mast-inner,.school-inner,.navigation>div {
    padding-left:16px;
    padding-right:16px;
  }

  .mast-inner {
    min-height:56px;
  }

  .brand {
    font-size:17px;
  }

  .identity>span {
    display:none;
  }

  .navigation>div {
    gap:18px;
  }

  main {
    padding:24px 16px 36px;
  }

  .panel,.auth-panel {
    padding:16px;
  }

  .split {
    grid-template-columns:1fr;
    gap:12px;
  }

  .heading {
    gap:8px;
  }

  .panel.mealrow {
    padding:12px;
  }

  .auth-panel {
    margin:12px auto;
  }

  .filters {
    gap:6px;
  }

  .school-inner {
    gap:7px;
  }

  footer {
    margin:0 16px;
  }

  .printrow {
    padding:10px 6px;
  }

  .cards {
    gap:8px;
  }

}

@media print {
  @page {
    margin:11mm;
  }

  body,main {
    background:white;
    font-size:11pt;
  }

  main {
    min-height:auto;
    padding:0;
    max-width:none;
  }

  header,.schoolbar,.navigation,.skip,.printbtn,footer {
    display:none;
  }

  .printrow {
    padding:6px 0;
  }

  .printrow h2 {
    font-size:12pt;
  }

  .printrow p:last-child {
    font-size:10pt;
  }

}

.alternative {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:8px;
  border-bottom:1px solid var(--line);
}

.alternative button {
  min-width:60px;
}


.actions, .section-jump {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.actions .primary {
  background: var(--action);
  color: #fff;
}
.section-jump {
  margin-bottom: 18px;
}
.section-jump a {
  padding: 4px 10px;
  border-radius: 5px;
  color: var(--pine);
  background: var(--soft);
  text-decoration: none;
}
.formstack #id_weekdays, .formstack #id_meals {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
@media (max-width: 430px) {
  .actions {
    width: 100%;
  }
  .actions .button {
    flex: 1;
  }
}

.publication-card {
  padding: 0;
  overflow: hidden;
}
.publication-card > figure {
  margin: 0 15px 12px;
}
.publication-card .rowlink {
  padding: 13px 16px;
}
@media (min-width: 720px) {
  .publication-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
  .publication-grid .empty {
    grid-column: 1 / -1;
  }
}
.photo-manage {
  display: block;
  font-size: .875rem;
  min-height: 32px;
}
.publication-card .meal-photo {
  padding: 0 16px;
}
.meal-photo figcaption {
  font-size: .85rem;
  color: var(--muted);
}
