:root {
  --ink: #151515;
  --muted: #6d6f78;
  --line: #eceef2;
  --soft: #ffffff;
  --paper: #ffffff;
  --green: #6b7280;
  --teal: #0f766e;
  --blue: #2563eb;
  --shadow: 0 22px 50px rgba(20, 26, 40, 0.11);
  --font-main: "Noto Sans KR", "NotoSansKR", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--font-main);
  overflow-x: hidden;
}

.page-ripple {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9999;
  width: 16px;
  height: 16px;
  pointer-events: none;
  border: 1px solid rgba(37, 99, 235, 0.36);
  background: radial-gradient(circle, rgba(37, 99, 235, 0.16) 0%, rgba(37, 99, 235, 0.08) 42%, rgba(37, 99, 235, 0) 72%);
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0);
  animation: page-ripple 620ms ease-out forwards;
}

@keyframes page-ripple {
  0% {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(0);
  }

  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(8);
  }
}

@media (prefers-reduced-motion: reduce) {
  .page-ripple {
    animation-duration: 300ms;
  }

  .ingredient-card > *,
  .community-post > *,
  .card-actions button {
    transition: none;
  }
}

button,
input,
select,
textarea {
  font: inherit;
  font-family: var(--font-main);
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

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

img {
  display: block;
  max-width: 100%;
}

.sr-only {
  position: absolute;
  overflow: hidden;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  height: 72px;
  padding: 0 clamp(20px, 5vw, 72px);
  border-bottom: 1px solid rgba(236, 238, 242, 0.86);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(18px);
}

.brand,
.header-actions,
.main-nav,
.section-title,
.sort-control,
.filter-heading,
.footer-links,
.community-toolbar,
.community-search,
.post-meta,
.post-stats {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  flex: 0 0 auto;
  font-size: 21px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 8px;
  border: 1px solid #111;
  background: #fff;
  color: #111;
}

.main-nav {
  gap: 26px;
  color: #3d3f45;
  font-size: 15px;
  font-weight: 600;
}

.main-nav a:hover {
  color: var(--green);
}

.main-nav a.active {
  color: var(--ink);
  font-weight: 800;
}

.header-actions {
  gap: 10px;
}

.header-actions .text-button {
  color: #3d3f45;
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
}

.header-actions .text-button:hover {
  color: var(--green);
}

.admin-only-link:not([hidden]) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 13px;
  border-radius: 8px;
  background: #111827;
  color: #fff;
  font-weight: 900;
}

.icon-button,
.text-button,
.primary-button,
.outline-button,
.filter-heading button {
  border: 0;
  cursor: pointer;
}

.icon-button {
  position: relative;
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 8px;
  background: var(--soft);
  color: #34363b;
}

.message-bell.has-unread {
  color: #2563eb;
  animation: message-alert 1s ease-in-out infinite;
}

.message-bell[data-unread-count]::after {
  content: attr(data-unread-count);
  position: absolute;
  right: 1px;
  top: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: #111;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

@keyframes message-alert {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.28);
  }

  50% {
    box-shadow: 0 0 0 8px rgba(37, 99, 235, 0);
  }
}

.icon-button svg,
.primary-button svg,
.sort-control svg {
  width: 18px;
  height: 18px;
}

.text-button {
  background: transparent;
  color: #222;
  font-weight: 700;
}

.text-button.active-auth {
  color: var(--ink);
}

.primary-button,
.outline-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 8px;
  font-weight: 800;
  white-space: nowrap;
}

.primary-button {
  background: var(--ink);
  color: #fff;
  box-shadow: 0 12px 24px rgba(21, 21, 21, 0.14);
}

.primary-button:hover {
  transform: translateY(-1px);
}

.primary-button.compact {
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid #111;
  background: #fff;
  color: #111;
  box-shadow: none;
}

.primary-button.compact.active-register {
  background: #111;
  color: #fff;
}

.outline-button {
  border: 1px solid var(--line);
  background: #fff;
  color: #1f2937;
}

.hero {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  justify-items: center;
  min-height: auto;
  padding: clamp(58px, 8vw, 96px) clamp(20px, 5vw, 72px) 52px;
  background: #fff;
}

.hero-copy {
  width: min(100%, 980px);
  text-align: center;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--green);
  font-size: 14px;
  font-weight: 800;
}

.hero h1,
.community-hero h1 {
  max-width: none;
  margin: 0 auto;
  font-size: clamp(30px, 4vw, 52px);
  line-height: 1.08;
  letter-spacing: 0;
}

.hero h1 {
  white-space: nowrap;
}

.hero-description {
  max-width: none;
  margin: 18px auto 0;
  color: #4b5563;
  font-size: 19px;
  line-height: 1.7;
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  width: min(100%, 900px);
  max-width: none;
  margin-top: 34px;
  margin-right: auto;
  margin-left: auto;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--shadow);
}

.search-field {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 0 12px;
  color: var(--muted);
}

.search-field input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  color: var(--ink);
  font-size: 17px;
}

.marketplace {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  padding: 26px clamp(20px, 5vw, 72px) 70px;
  background: #fff;
}

.filter-panel {
  position: sticky;
  top: 94px;
  align-self: start;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.filter-heading {
  justify-content: space-between;
  margin-bottom: 22px;
}

.filter-heading h2,
.section-title h2 {
  margin: 0;
  line-height: 1.25;
  letter-spacing: 0;
}

.filter-heading h2 {
  font-size: 22px;
}

.filter-heading button {
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.filter-group + .filter-group {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.filter-group h3 {
  margin: 0 0 13px;
  font-size: 15px;
}

.filter-group label {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 11px 0;
  color: #383b42;
  font-size: 14px;
  font-weight: 600;
}

.filter-group input {
  width: 18px;
  height: 18px;
  accent-color: var(--green);
}

.content-area {
  width: min(100%, 1180px);
  min-width: 0;
  margin: 0 auto;
}

.section-title {
  justify-content: flex-start;
  margin-bottom: 16px;
}

.section-title h2 {
  font-size: 28px;
}

.sort-control {
  gap: 8px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #4b5563;
}

.sort-control select {
  border: 0;
  outline: 0;
  background: transparent;
  color: #222;
  font-weight: 700;
}

.ingredient-grid {
  display: grid;
  gap: 10px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.ingredient-board-head {
  display: none;
}

.ingredient-card {
  display: grid;
  grid-template-columns: minmax(220px, 1fr) minmax(190px, 0.9fr) minmax(88px, auto) max-content max-content 44px;
  grid-template-areas:
    "name desc desc actions actions favorite"
    "type lead lead manufacturer origin favorite";
  column-gap: 6px;
  row-gap: 8px;
  align-items: center;
  width: 100%;
  min-width: 0;
  min-height: 116px;
  padding: 24px 26px;
  border: 1px solid #d6e4dd;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.ingredient-card > * {
  transform-origin: left center;
  transition: transform 180ms ease;
}

.ingredient-card:hover {
  border-color: #aebfb6;
  background: #fff;
  box-shadow: 0 8px 24px rgba(20, 26, 40, 0.06);
}

.ingredient-card:hover > :not(.card-actions):not(.favorite-button) {
  transform: scale(1.012);
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 28px;
  padding: 7px 10px;
  border-radius: 8px;
  background: #f3f4f6;
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.ingredient-name {
  grid-area: name;
  min-width: 0;
}

.card-body {
  display: grid;
  min-height: 252px;
  padding: 20px;
}

.card-body h3 {
  margin: 14px 0 4px;
  font-size: 19px;
}

.ingredient-name h3 {
  display: inline-block;
  overflow: hidden;
  margin: 0;
  max-width: 100%;
  background: none;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.ingredient-name h3 span {
  color: #6b7280;
  font-size: 14px;
  font-weight: 700;
}

.english-name {
  display: block;
  overflow: hidden;
  margin-bottom: 0;
  color: #6b7280;
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ingredient-desc {
  grid-area: desc;
  overflow: hidden;
  margin: 0;
  color: #4b5563;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ingredient-origin,
.ingredient-lead-time,
.ingredient-manufacturer,
.ingredient-type {
  color: #4b5563;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

.ingredient-type {
  grid-area: type;
}

.ingredient-manufacturer {
  grid-area: manufacturer;
}

.ingredient-origin {
  grid-area: origin;
}

.ingredient-lead-time {
  grid-area: lead;
}

.ingredient-lead-time,
.ingredient-manufacturer {
  overflow: hidden;
  color: #374151;
  text-overflow: ellipsis;
}

.ingredient-origin {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.origin-flag {
  width: 24px;
  height: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 2px;
  object-fit: cover;
}

.ingredient-type {
  color: #374151;
}

.card-body p {
  min-height: 44px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.meta-row,
.card-actions {
  display: flex;
  align-items: center;
}

.meta-row {
  overflow: hidden;
  flex-wrap: nowrap;
  gap: 8px;
  margin: 0;
}

.meta-row span {
  overflow: hidden;
  padding: 7px 9px;
  border-radius: 7px;
  background: #f3f6f9;
  color: #384252;
  font-size: 12px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.card-actions {
  grid-area: actions;
  justify-content: flex-start;
  gap: 6px;
  min-width: 0;
}

.card-actions button {
  min-height: 32px;
  padding: 0 9px;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  transition: transform 160ms ease, border-color 160ms ease;
}

.card-actions button:hover {
  transform: scale(1.04);
  border-color: #111 !important;
}

.favorite-button {
  grid-area: favorite;
  display: inline-grid;
  width: 34px;
  height: 36px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #c5c9d1;
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  transition: color 160ms ease, transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.favorite-button:hover {
  transform: scale(1.08);
  border-color: #f2c94c;
  color: #f2b705;
}

.favorite-button.active {
  border-color: #f2c94c;
  background: #fff9db;
  color: #f2b705;
}

.sample-button {
  background: #fff;
  border-color: var(--line) !important;
  color: #1f2937;
}

.quote-button {
  background: #fff;
  border-color: var(--line) !important;
  color: #1f2937;
}

.empty-state {
  grid-column: 1 / -1;
  padding: 48px;
  border: 1px dashed #cfd6df;
  border-radius: 10px;
  background: #fff;
  color: var(--muted);
  text-align: center;
  font-weight: 700;
}

.pagination-bar {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-top: 1px solid var(--line);
  background: #fff;
}

.page-size-toggle,
.page-number-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.page-size-toggle button,
.page-number-list button {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #374151;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
}

.page-size-toggle button {
  padding: 0 12px;
}

.page-number-list button {
  min-width: 36px;
  padding: 0 10px;
}

.page-size-toggle button.active,
.page-number-list button.active {
  border-color: #111827;
  background: #111827;
  color: #fff;
}

.ingredient-detail {
  display: grid;
  min-width: 0;
  padding: 18px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.ingredient-detail-card {
  gap: 20px;
}

.detail-head h2 span {
  color: #6b7280;
  font-size: 20px;
}

.supplier-detail-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.supplier-detail-grid div {
  display: grid;
  gap: 7px;
  min-width: 0;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.supplier-detail-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.supplier-detail-grid strong,
.supplier-detail-grid a {
  overflow: hidden;
  color: #111827;
  font-size: 14px;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.supplier-detail-grid a {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.private-manufacturer-note {
  color: #8a93a3;
  font-size: 12px;
  font-weight: 700;
}

.detail-actions {
  display: flex;
  gap: 8px;
}

.detail-actions button {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
}

.supplier-band,
.community-section {
  padding: 66px clamp(20px, 5vw, 72px);
}

.supplier-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.supplier-list article {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.supplier-list img {
  grid-row: span 2;
  width: 86px;
  height: 86px;
  border-radius: 8px;
  object-fit: cover;
}

.supplier-list strong {
  display: block;
  font-size: 18px;
}

.supplier-list span,
.supplier-list p {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.supplier-list p {
  grid-column: 2;
  margin: 0;
}

.community-page {
  background: #fff;
}

.community-hero {
  display: grid;
  align-items: end;
  justify-items: center;
  padding: clamp(24px, 4vw, 46px) clamp(20px, 5vw, 72px) 10px;
  background: #fff;
  text-align: center;
}

.community-hero h1 {
  max-width: none;
  margin: 0 auto;
}

.community-hero p:not(.eyebrow) {
  max-width: 920px;
  margin: 12px auto 0;
  color: #4b5563;
  font-size: 18px;
  line-height: 1.7;
}

.community-section {
  background: #fff;
}

.community-section .section-title {
  max-width: none;
  justify-content: center;
  text-align: center;
}

.community-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  max-width: 1080px;
  margin: 0 auto;
  width: 100%;
}

.community-main {
  min-width: 0;
}

.community-toolbar {
  justify-content: center;
  gap: 10px;
  margin-bottom: 18px;
}

.community-search {
  flex: 0 1 720px;
  gap: 10px;
  min-height: 54px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--muted);
  background: #fff;
}

.community-search svg {
  width: 17px;
  height: 17px;
}

.community-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  font-size: 16px;
}

.community-write-button {
  min-height: 54px;
  white-space: nowrap;
}

.partner-write-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.partner-form-heading {
  display: grid;
  gap: 6px;
  padding: 16px;
  border-radius: 8px;
  background: #f8fafc;
}

.partner-form-heading strong {
  color: #111827;
  font-size: 18px;
  font-weight: 900;
}

.partner-form-heading p {
  margin: 0;
  color: #6b7280;
  font-size: 14px;
  font-weight: 700;
}

.community-write-form {
  display: grid;
  gap: 18px;
  margin-bottom: 16px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

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

.community-write-form label {
  display: grid;
  gap: 8px;
}

.community-write-form label span {
  color: #384252;
  font-size: 13px;
  font-weight: 800;
}

.community-write-form input,
.community-write-form select,
.community-write-form textarea {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 15px;
  outline: 0;
  color: var(--ink);
}

.community-write-form textarea {
  min-height: 132px;
  padding: 14px 15px;
  resize: vertical;
}

.community-write-form input:focus,
.community-write-form select:focus,
.community-write-form textarea:focus {
  border-color: #111;
}

.community-list {
  display: grid;
  gap: 10px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.community-board-head,
.community-post {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) 118px 96px 116px;
  gap: 14px;
  align-items: center;
  width: 100%;
  min-width: 0;
}

.community-board-head {
  display: none;
}

.community-post {
  min-height: 116px;
  padding: 24px 26px;
  border: 1px solid #d6e4dd;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.community-post > * {
  transform-origin: left center;
  transition: transform 180ms ease;
}

.community-post:hover {
  border-color: #aebfb6;
  background: #fff;
  box-shadow: 0 8px 24px rgba(20, 26, 40, 0.06);
}

.community-post:hover > * {
  transform: scale(1.012);
}

.community-post:last-child {
  border-bottom: 1px solid #d6e4dd;
}

.post-category {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 26px;
  max-width: 100%;
  padding: 0 9px;
  border-radius: 7px;
  background: #f3f4f6;
  color: var(--green);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.community-post h3 {
  overflow: hidden;
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.post-author,
.post-date {
  overflow: hidden;
  color: #5f6673;
  font-size: 13px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.community-post p,
.post-meta {
  display: none;
}

.post-meta span:not(:last-child)::after {
  content: none;
}

.post-stats {
  gap: 10px;
  justify-content: flex-start;
  color: #4b5563;
  font-size: 12px;
  font-weight: 700;
}

.post-stats span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 44px;
  justify-content: flex-start;
}

.ingredient-board-head > *,
.ingredient-card > *,
.community-board-head > *,
.community-post > * {
  min-width: 0;
}

.post-stats svg {
  width: 16px;
  height: 16px;
  color: var(--muted);
}

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

.partner-post {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
  align-items: center;
  min-height: 160px;
  padding: 26px 36px;
  border: 1px solid #cfded5;
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.partner-post:hover {
  border-color: #aebfb6;
  background: #fff;
  box-shadow: 0 10px 24px rgba(20, 26, 40, 0.06);
}

.partner-post-main {
  display: grid;
  gap: 10px;
  min-width: 0;
}

.partner-post-title {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.partner-post-title h3 {
  overflow: hidden;
  margin: 0;
  color: #111827;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.partner-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 900;
  white-space: nowrap;
}

.partner-badge.mode {
  background: #f3f4f6;
  color: #4b5563;
}

.partner-badge.trade {
  background: #ffe6f2;
  color: #e3177f;
}

.partner-badge.trade.sale {
  background: #e6f4ff;
  color: #0875be;
}

.partner-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  color: #555b66;
  font-size: 15px;
  font-weight: 500;
}

.partner-meta span:not(:last-child)::after {
  content: "";
  display: inline-block;
  width: 1px;
  height: 14px;
  margin-left: 16px;
  background: #d1d5db;
  vertical-align: -2px;
}

.partner-detail-meta {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 10px 16px;
  padding: 18px;
  border-radius: 8px;
  background: #f8fafc;
}

.partner-detail-meta span {
  color: #6b7280;
  font-size: 13px;
  font-weight: 800;
}

.partner-detail-meta strong {
  color: #111827;
  font-size: 14px;
}

.community-detail {
  display: grid;
  gap: 16px;
  min-width: 0;
  padding: 18px;
  border-bottom: 1px solid var(--line);
  background: #fbfcfd;
}

.community-detail[hidden] {
  display: none;
}

.detail-post,
.comment-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.detail-post {
  display: grid;
  gap: 22px;
  padding: 26px;
}

.detail-head {
  display: grid;
  gap: 12px;
}

.detail-head h2 {
  margin: 0;
  font-size: 28px;
  line-height: 1.35;
  letter-spacing: 0;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: #6b7280;
  font-size: 13px;
  font-weight: 800;
}

.message-user-button {
  width: fit-content;
  max-width: 100%;
  overflow: hidden;
  border: 0;
  padding: 0;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-user-button:hover {
  color: #374151;
  text-decoration: underline;
}

.detail-author,
.comment-author {
  font-size: 13px;
}

.detail-post p {
  margin: 0;
  color: #374151;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.75;
}

.comment-panel {
  display: grid;
  gap: 18px;
  padding: 22px;
}

.comment-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.comment-title h3 {
  margin: 0;
  font-size: 20px;
}

.comment-title span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

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

.comment-item {
  display: grid;
  gap: 8px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.comment-item div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.comment-item strong {
  font-size: 14px;
}

.comment-item span,
.comment-empty {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.comment-item p,
.comment-empty {
  margin: 0;
}

.comment-item p {
  color: #374151;
  line-height: 1.65;
}

.comment-form {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr) auto;
  gap: 10px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.comment-form input,
.comment-form textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 13px;
  outline: 0;
  color: var(--ink);
  font: inherit;
}

.comment-form textarea {
  min-height: 44px;
  padding: 11px 13px;
  resize: vertical;
}

.register-page {
  background: #fff;
}

.signup-page {
  background: #fff;
}

.seo-content {
  display: grid;
  gap: 12px;
  padding: 0 clamp(20px, 5vw, 72px) 58px;
}

.seo-content h2 {
  margin: 0;
  color: #252a33;
  font-size: 22px;
}

.seo-content p {
  max-width: 920px;
  margin: 0;
  color: #6b7280;
  font-size: 15px;
  line-height: 1.75;
}

.intro-copy {
  padding: 0 clamp(20px, 5vw, 72px) 24px;
}

.intro-copy p {
  max-width: 980px;
  margin: 0 auto;
  color: #4b5563;
  font-size: 16px;
  line-height: 1.8;
  text-align: center;
}

.news-section {
  display: grid;
  gap: 24px;
  padding: 28px clamp(20px, 5vw, 72px) 72px;
}

.news-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.news-heading h2 {
  margin: 4px 0 0;
  font-size: clamp(26px, 3.2vw, 42px);
  letter-spacing: 0;
}

.news-actions,
.news-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.news-arrow {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: #111;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.news-arrow:hover {
  transform: scale(1.04);
  box-shadow: 0 16px 30px rgba(17, 24, 39, 0.13);
}

.news-arrow svg {
  width: 18px;
  height: 18px;
}

.news-carousel {
  overflow: hidden;
  margin-right: calc(clamp(20px, 5vw, 72px) * -1);
  padding: 0 clamp(20px, 5vw, 72px) 8px 0;
}

.news-grid {
  display: grid;
  grid-auto-columns: minmax(320px, 30vw);
  grid-auto-flow: column;
  grid-template-columns: none;
  gap: 22px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.news-grid::-webkit-scrollbar {
  display: none;
}

.news-card {
  overflow: hidden;
  border: 1px solid #f0f1f4;
  border-radius: 8px;
  background: #f7f8fa;
  min-height: 260px;
  scroll-snap-align: start;
  cursor: default;
}

.news-card-body {
  display: grid;
  gap: 12px;
  min-height: 100%;
  padding: 22px;
}

.news-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.news-tags span {
  padding: 5px 8px;
  border-radius: 5px;
  background: #eef3e8;
  color: #111;
  font-size: 11px;
  font-weight: 800;
}

.news-card time {
  color: #6b7280;
  font-size: 13px;
  font-weight: 700;
}

.news-card h3 {
  margin: 0;
  font-size: 19px;
  line-height: 1.45;
}

.news-card p {
  margin: 0;
  color: #4b5563;
  font-size: 14px;
  line-height: 1.65;
}

.news-card strong {
  margin-top: 10px;
  color: #6b7280;
  font-size: 13px;
}

.legal-page {
  background: #fff;
}

.legal-hero {
  padding: clamp(44px, 7vw, 84px) clamp(20px, 5vw, 72px) 26px;
  text-align: center;
}

.legal-hero h1 {
  margin: 0;
  font-size: clamp(34px, 4.8vw, 56px);
  line-height: 1.1;
  letter-spacing: 0;
}

.legal-hero p:not(.eyebrow) {
  margin: 16px 0 0;
  color: #6b7280;
  font-size: 15px;
  font-weight: 700;
}

.legal-document {
  display: grid;
  gap: 14px;
  width: min(100% - 40px, 920px);
  margin: 0 auto 72px;
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.legal-document article {
  display: grid;
  gap: 10px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.legal-document article:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.legal-document h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.45;
}

.legal-document p {
  margin: 0;
  color: #4b5563;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.8;
}

.terms-check a {
  color: #111;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.suggestion-document {
  max-width: 760px;
}

.suggestion-form {
  display: grid;
  gap: 18px;
}

.suggestion-form label {
  display: grid;
  gap: 8px;
}

.suggestion-form label span {
  color: #384252;
  font-size: 13px;
  font-weight: 800;
}

.suggestion-form input,
.suggestion-form textarea {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 15px;
  outline: 0;
  color: var(--ink);
}

.suggestion-form textarea {
  min-height: 180px;
  padding: 14px 15px;
  resize: vertical;
}

.suggestion-form input:focus,
.suggestion-form textarea:focus {
  border-color: #111;
}

.auth-only[hidden] {
  display: none !important;
}

.guest-only[hidden] {
  display: none !important;
}

.single-column {
  grid-template-columns: 1fr;
}

.auth-form-layout {
  display: flex;
  justify-content: center;
  max-width: 760px;
  margin: 0 auto;
  width: 100%;
  justify-items: center;
}

.signup-form-layout {
  max-width: 980px;
}

.login-form-layout {
  max-width: 720px;
}

.auth-form-layout .signup-form {
  justify-self: center;
  width: 760px;
  max-width: calc(100vw - 40px);
}

.signup-form-layout .signup-form {
  width: 820px;
  min-height: 560px;
}

.login-form-layout .signup-form {
  width: 560px;
  min-height: 420px;
}

.register-hero {
  padding: clamp(44px, 7vw, 84px) clamp(20px, 5vw, 72px) 30px;
  text-align: center;
}

.signup-hero {
  padding: clamp(44px, 7vw, 84px) clamp(20px, 5vw, 72px) 30px;
  text-align: center;
}

.register-hero h1 {
  margin: 0;
  font-size: clamp(34px, 4.8vw, 58px);
  line-height: 1.1;
  letter-spacing: 0;
}

.signup-hero h1 {
  margin: 0;
  font-size: clamp(34px, 4.8vw, 58px);
  line-height: 1.1;
  letter-spacing: 0;
}

.register-hero p:not(.eyebrow) {
  max-width: 720px;
  margin: 18px auto 0;
  color: #4b5563;
  font-size: 17px;
  line-height: 1.7;
}

.signup-hero p:not(.eyebrow) {
  max-width: 720px;
  margin: 18px auto 0;
  color: #4b5563;
  font-size: 17px;
  line-height: 1.7;
}

.register-layout {
  display: grid;
  grid-template-columns: minmax(0, 980px);
  gap: 24px;
  justify-content: center;
  align-items: start;
  padding: 34px clamp(20px, 5vw, 72px) 70px;
}

.signup-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  gap: 24px;
  align-items: start;
  padding: 34px clamp(20px, 5vw, 72px) 70px;
}

.mypage-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 420px);
  gap: 24px;
  align-items: start;
  padding: 34px clamp(20px, 5vw, 72px) 70px;
}

.mypage-layout.ingredients-focus {
  grid-template-columns: minmax(0, 1120px);
  justify-content: center;
}

.mypage-layout.ingredients-focus #mypageForm {
  display: none;
}

.signup-layout.auth-form-layout {
  display: flex;
  justify-content: center;
}

.mypage-layout[hidden] {
  display: none;
}

.auth-required {
  display: grid;
  justify-items: center;
  gap: 14px;
  max-width: 520px;
  margin: 34px auto 80px;
  padding: 38px 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  text-align: center;
}

.auth-required[hidden] {
  display: none;
}

.auth-required svg {
  width: 34px;
  height: 34px;
  color: var(--green);
}

.auth-required h2 {
  margin: 0;
  font-size: 26px;
}

.auth-required p {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.register-form,
.signup-form,
.signup-result {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.register-form,
.signup-form {
  display: grid;
  gap: 22px;
  padding: clamp(26px, 3.5vw, 38px);
}

.form-section {
  display: grid;
  gap: 16px;
}

.form-section + .form-section {
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.form-section h2 {
  margin: 0;
  font-size: 21px;
}

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

.form-grid.single-column {
  grid-template-columns: 1fr;
}

.register-form label,
.signup-form label {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.manufacturer-field {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 210px;
  gap: 12px;
  align-items: start;
  min-width: 0;
}

.manufacturer-field.compact {
  grid-template-columns: 1fr;
}

.visibility-choice {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 8px;
  row-gap: 0;
  align-content: start;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.visibility-choice legend {
  grid-column: 1 / -1;
  color: #384252;
  font-size: 13px;
  font-weight: 800;
}

.visibility-choice label {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 52px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  transform: translateY(8px);
}

.visibility-choice input {
  position: absolute;
  appearance: none;
  width: 1px;
  height: 1px;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

.visibility-choice label:has(input:checked) {
  border-color: #111827;
  box-shadow: inset 0 0 0 1px #111827;
}

.visibility-choice label span {
  color: #111827;
  font-size: 14px;
  font-weight: 900;
}

.visibility-choice p {
  grid-column: 1 / -1;
  margin: 8px 0 0;
  color: #8a93a3;
  font-size: 12px;
  font-weight: 700;
}

.register-form label span,
.signup-form label span {
  color: #384252;
  font-size: 13px;
  font-weight: 800;
}

.register-form input,
.register-form select,
.register-form textarea,
.signup-form input,
.signup-form select,
.signup-form textarea {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 15px;
  outline: 0;
  background: #fff;
  color: var(--ink);
  font-size: 15px;
}

.register-form input:focus,
.register-form select:focus,
.register-form textarea:focus,
.signup-form input:focus,
.signup-form select:focus {
  border-color: #111;
}

.register-form input[readonly],
.signup-form input[readonly] {
  background: #f8fafc;
  color: #4b5563;
  cursor: default;
}

.register-form textarea,
.signup-form textarea {
  min-height: 120px;
  padding: 13px;
  resize: vertical;
}

.full-field {
  margin-top: 2px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.signup-result {
  position: sticky;
  top: 94px;
  display: grid;
  gap: 14px;
  padding: 22px;
}

.my-ingredients-panel {
  cursor: pointer;
}

.mypage-layout.ingredients-focus .my-ingredients-panel {
  position: static;
  width: 100%;
  cursor: default;
}

.my-ingredients-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.my-ingredients-head .eyebrow {
  margin-bottom: 6px;
}

.signup-result h2 {
  margin: 0;
  font-size: 24px;
}

.signup-result p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
}

.terms-check {
  display: flex !important;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 10px !important;
}

.terms-check input {
  width: 18px;
  min-height: 18px;
  accent-color: var(--green);
}

.form-message {
  min-height: 22px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.form-message.success {
  color: var(--green);
}

.form-message.error {
  color: #b91c1c;
}

.member-card {
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.member-card strong {
  font-size: 19px;
}

.member-card span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

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

.my-ingredient-search {
  display: grid;
  gap: 8px;
}

.my-ingredient-search span,
.my-ingredient-detail label span {
  color: #384252;
  font-size: 13px;
  font-weight: 800;
}

.my-ingredient-search input,
.my-ingredient-detail input,
.my-ingredient-detail select,
.my-ingredient-detail textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  outline: 0;
  background: #fff;
  color: var(--ink);
}

.my-ingredient-detail textarea {
  min-height: 96px;
  padding: 12px;
  resize: vertical;
}

.my-ingredient-item {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.my-ingredient-item:hover,
.my-ingredient-item.active {
  border-color: #111;
  box-shadow: 0 10px 24px rgba(17, 24, 39, 0.08);
  transform: translateY(-1px);
}

.my-ingredient-item strong {
  font-size: 16px;
}

.my-ingredient-item span,
.my-ingredient-item p,
.empty-mini {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.my-ingredient-detail {
  display: grid;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.my-ingredient-detail[hidden] {
  display: none;
}

.my-ingredient-detail h3 {
  margin: 0;
  font-size: 18px;
}

.my-ingredient-detail label {
  display: grid;
  gap: 8px;
}

.split-actions {
  justify-content: space-between;
}

.danger-button {
  color: #b91c1c;
}

.messages-layout {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 20px;
  padding: 34px clamp(20px, 5vw, 72px) 70px;
}

.message-thread-list,
.message-room {
  min-height: 420px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.message-thread-list {
  display: grid;
  align-content: start;
  overflow: hidden;
}

.message-thread {
  display: grid;
  gap: 6px;
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 16px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  text-align: left;
}

.message-thread.active {
  background: #f8fafc;
}

.message-thread.unread strong::after {
  content: attr(data-thread-unread);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  margin-left: 8px;
  border-radius: 999px;
  background: #111;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.message-thread span {
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-thread-meta {
  overflow: hidden;
  color: #6b7280;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.message-room {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
}

.message-conversation {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 22px;
}

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

.message-conversation-head h2 {
  margin: 0;
  font-size: 22px;
}

.message-conversation-head p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.message-bubbles {
  display: grid;
  gap: 10px;
}

.message-bubble {
  display: grid;
  gap: 6px;
  max-width: min(560px, 84%);
  padding: 12px 14px;
  border-radius: 8px;
}

.message-bubble.received {
  justify-self: start;
  background: #f3f4f6;
}

.message-bubble.sent {
  justify-self: end;
  background: #111;
  color: #fff;
}

.message-bubble p {
  margin: 0;
  line-height: 1.55;
  white-space: pre-line;
}

.message-bubble span {
  color: #8b93a1;
  font-size: 12px;
}

.message-composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 16px;
  border-top: 1px solid var(--line);
}

.message-composer textarea {
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  resize: vertical;
}

.message-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(17, 24, 39, 0.28);
}

.message-modal {
  display: grid;
  gap: 18px;
  width: min(520px, 100%);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(17, 24, 39, 0.2);
}

.message-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.message-modal-head h2 {
  margin: 4px 0 0;
  font-size: 24px;
}

.message-modal form {
  display: grid;
  gap: 14px;
}

.message-modal textarea {
  min-height: 140px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 13px;
  color: var(--ink);
  font: inherit;
  resize: vertical;
}

.admin-layout {
  display: grid;
  gap: 22px;
  padding: 34px clamp(20px, 5vw, 72px) 70px;
}

.admin-layout[hidden] {
  display: none;
}

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

.admin-stat-card,
.admin-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.admin-stat-card {
  display: grid;
  gap: 8px;
  padding: 18px;
}

.admin-stat-card span,
.admin-note {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.admin-stat-card strong {
  font-size: 28px;
}

.admin-panel {
  display: grid;
  gap: 16px;
  padding: 20px;
}

.admin-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.admin-panel-head h2 {
  margin: 4px 0 0;
  font-size: 22px;
}

.admin-panel-head input {
  width: min(360px, 100%);
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
}

.admin-table-wrap {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.admin-table th,
.admin-table td {
  padding: 13px 10px;
  border-top: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.admin-table td span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.admin-small-button {
  min-height: 32px;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 0 10px;
  background: #fff;
  cursor: pointer;
  font-weight: 800;
}

.admin-visit-list,
.admin-list {
  display: grid;
  gap: 10px;
}

.admin-list-row {
  display: grid;
  gap: 5px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
}

.admin-list-row strong {
  font-size: 15px;
}

.admin-list-row span,
.admin-list-row p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 34px clamp(20px, 5vw, 72px);
  border-top: 1px solid var(--line);
  color: #9ca3af;
  background: #fafafa;
}

.site-footer strong {
  color: #6b7280;
  font-size: 18px;
}

.site-footer p {
  margin: 8px 0 0;
}

.footer-brand-block {
  display: grid;
  gap: 8px;
}

.company-info {
  display: grid;
  gap: 4px;
  margin-top: 6px;
  color: #9ca3af;
  font-size: 13px;
  line-height: 1.6;
}

.company-info p {
  margin: 0;
}

.footer-links {
  gap: 18px;
  font-weight: 700;
  color: #9ca3af;
}

@media (max-width: 1180px) {
  .ingredient-grid,
  .supplier-list,
  .admin-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .community-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .main-nav {
    display: none;
  }

  .hero,
  .marketplace,
  .community-hero,
  .community-layout,
  .register-layout,
  .signup-layout,
  .messages-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .filter-panel {
    position: static;
  }

  .signup-result {
    position: static;
  }

  .community-list {
    grid-template-columns: 1fr;
  }

  .news-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .news-actions {
    width: 100%;
    justify-content: space-between;
  }
}

@media (max-width: 720px) {
  .site-header {
    height: auto;
    flex-wrap: nowrap;
    gap: 10px;
    padding-top: 14px;
    padding-bottom: 14px;
  }

  .site-header .brand {
    display: none;
  }

  .main-nav {
    display: flex;
    flex: 1 1 auto;
    gap: 10px;
    min-width: 0;
    font-size: 12px;
    line-height: 1.2;
    white-space: nowrap;
  }

  .main-nav a[href="intro.html"] {
    display: none;
  }

  .header-actions {
    width: auto;
    margin-left: auto;
    flex: 0 0 auto;
    justify-content: flex-end;
    gap: 8px;
  }

  .header-actions .text-button {
    font-size: 12px;
    font-weight: 600;
  }

  .search-panel,
  .section-title,
  .site-footer {
    align-items: stretch;
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .hero h1,
  .community-hero h1 {
    font-size: 30px;
  }

  .hero-description {
    font-size: 16px;
  }

  .ingredient-grid,
  .supplier-list {
    grid-template-columns: 1fr;
  }

  .ingredient-board-head,
  .ingredient-card {
    grid-template-columns: minmax(0, 1.35fr) minmax(88px, 0.85fr) minmax(70px, 0.55fr);
    grid-template-areas: "name manufacturer origin";
    gap: 8px;
    padding-right: 12px;
    padding-left: 12px;
  }

  .ingredient-board-head span:nth-child(2),
  .ingredient-board-head span:nth-child(3),
  .ingredient-board-head span:nth-child(6),
  .ingredient-board-head span:nth-child(7),
  .ingredient-board-head span:nth-child(8),
  .ingredient-card .ingredient-type,
  .ingredient-card .ingredient-desc,
  .ingredient-card .ingredient-lead-time,
  .ingredient-card > .card-actions,
  .ingredient-card > .favorite-button {
    display: none;
  }

  .ingredient-board-head span:nth-child(4),
  .ingredient-board-head span:nth-child(5) {
    display: inline;
  }

  .ingredient-card {
    min-height: 66px;
  }

  .ingredient-name h3 {
    display: -webkit-box;
    font-size: 15px;
    white-space: normal;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .ingredient-name h3 span {
    display: none;
  }

  .ingredient-manufacturer,
  .ingredient-origin {
    overflow: hidden;
    font-size: 13px;
    text-overflow: ellipsis;
  }

  .ingredient-origin {
    justify-content: flex-start;
    gap: 5px;
  }

  .origin-flag {
    width: 20px;
    height: 14px;
    flex: 0 0 auto;
  }

  .detail-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .pagination-bar {
    align-items: stretch;
    flex-direction: column;
    padding: 14px 12px;
  }

  .page-size-toggle,
  .page-number-list {
    justify-content: center;
  }

  .news-carousel {
    margin-right: -20px;
    padding-right: 20px;
  }

  .news-grid {
    grid-auto-columns: minmax(280px, 84vw);
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .manufacturer-field {
    grid-template-columns: 1fr;
  }

  .form-actions {
    flex-direction: column-reverse;
  }

  .community-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .partner-write-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .community-search {
    flex-basis: auto;
  }

  .comment-form {
    grid-template-columns: 1fr;
  }

  .message-composer {
    grid-template-columns: 1fr;
  }

  .admin-stat-grid {
    grid-template-columns: 1fr;
  }

  .admin-panel-head {
    align-items: stretch;
    flex-direction: column;
  }

  .supplier-detail-grid {
    grid-template-columns: 1fr;
  }

  .post-stats {
    justify-content: flex-start;
  }

  .partner-post {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 20px;
  }

  .partner-post-title {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .partner-post-title h3 {
    flex-basis: 100%;
    white-space: normal;
  }

  .partner-meta {
    font-size: 13px;
  }

  .partner-meta span::after {
    display: none !important;
  }

  .partner-detail-meta {
    grid-template-columns: 1fr;
  }

  .supplier-list article {
    grid-template-columns: 72px minmax(0, 1fr);
  }

  .supplier-list img {
    width: 72px;
    height: 72px;
  }
}

.workspace-page {
  min-height: 100vh;
  background: #fff;
}

.workspace-header {
  display: flex;
  align-items: center;
  min-height: 78px;
  padding: 18px clamp(22px, 6vw, 80px);
  border-bottom: 2px solid #87a7d0;
  background: #fff;
}

.workspace-logo {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 28px;
  border: 2px solid #87a7d0;
  background: #fff;
  color: #20324a;
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 800;
}

.workspace-main {
  padding: clamp(28px, 4vw, 48px) clamp(22px, 8vw, 96px) 64px;
}

.workspace-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: clamp(22px, 3.5vw, 40px) clamp(48px, 12vw, 140px);
  width: min(100%, 980px);
}

.workspace-card {
  display: flex;
  align-items: flex-start;
  min-height: 142px;
  padding: 16px 18px;
  border: 3px solid #789bc6;
  background: #fff;
  color: #20324a;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.workspace-card:hover,
.workspace-card:focus-visible {
  border-color: #315f99;
  box-shadow: 0 12px 26px rgba(49, 95, 153, 0.14);
  outline: 0;
  transform: translateY(-2px);
}

.workspace-card span {
  display: inline-flex;
  align-items: center;
  width: min(100%, 240px);
  min-height: 28px;
  padding: 0 12px;
  border: 3px solid #789bc6;
  font-size: 15px;
  font-weight: 800;
}

@media (max-width: 720px) {
  .workspace-header {
    min-height: 70px;
    padding: 14px 18px;
  }

  .workspace-logo {
    width: 100%;
    padding: 0 16px;
  }

  .workspace-main {
    padding: 24px 18px 44px;
  }

  .workspace-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .workspace-card {
    min-height: 116px;
  }
}
