* { box-sizing: border-box; }

:root {
  color-scheme: light;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

body {
  min-height: 100vh;
  margin: 0;
  background: var(--background, #fbf5ed);
  color: var(--text, #26201d);
}

.profile {
  width: min(100% - 2rem, 42rem);
  margin: 0 auto;
  padding: clamp(2.5rem, 8vw, 5rem) 0 2rem;
}

.profile-header { text-align: center; }
.avatar {
  width: 6rem;
  height: 6rem;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid white;
  box-shadow: 0 5px 24px #26201d1a;
}
.brand {
  margin: 1.25rem 0 .5rem;
  color: var(--accent, #a84632);
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .16em;
}
h1 { margin: 0; font-size: clamp(2rem, 7vw, 3.25rem); line-height: 1.08; letter-spacing: -.045em; }
.bio { max-width: 34rem; margin: 1rem auto 0; color: color-mix(in srgb, currentColor 74%, transparent); line-height: 1.65; }
.blocks { display: grid; gap: .875rem; margin-top: 2.25rem; }
.action {
  display: block;
  padding: 1rem 1.25rem;
  border: 1px solid color-mix(in srgb, var(--accent, #a84632) 28%, transparent);
  border-radius: 1rem;
  background: #fff;
  color: inherit;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease;
}
.action-icon { display: inline-grid; width: 1.25em; place-items: center; margin-right: .4rem; }
.action:hover { transform: translateY(-2px); box-shadow: 0 8px 24px #26201d12; }
.action:focus-visible, .socials a:focus-visible { outline: 3px solid var(--accent, #a84632); outline-offset: 3px; }
.socials { display: flex; justify-content: center; flex-wrap: wrap; gap: .625rem; }
.socials a { padding: .6rem .9rem; border-radius: 999px; background: #fff; color: inherit; font-weight: 650; text-decoration: none; }
.text-block { padding: 1.25rem; border-radius: 1rem; background: #fff9; }
.text-block h2 { margin: 0 0 .5rem; font-size: 1.2rem; }
.text-block p { margin: 0; line-height: 1.7; white-space: pre-line; }
.image-block { display: grid; min-height: 0; margin: 0; overflow: hidden; place-items: center; border-radius: 1rem; background: #eee; }
.image-block img { display: block; width: auto; max-width: 100%; max-height: min(62svh, 28rem); object-fit: contain; }
.location-block, .hours-block { padding: 1.25rem; border-radius: 1rem; background: #fff9; }
.location-block p { margin: 0; line-height: 1.6; }
.location-action { margin-top: .8rem; }
.hours-block h2 { margin: 0 0 .5rem; font-size: 1.1rem; }
.hours-block dl { margin: 0; }
.hours-block dl div { display: flex; justify-content: space-between; gap: .75rem; padding: .45rem 0; border-top: 1px solid #26201d18; }
.hours-block dt { font-weight: 700; }
.hours-block dd { margin: 0; text-align: right; }
.separator { width: 2.5rem; height: 3px; margin: .5rem auto; border: 0; border-radius: 2px; background: var(--accent, #a84632); }
.profile-footer { margin-top: 2.5rem; color: color-mix(in srgb, currentColor 55%, transparent); font-size: .8rem; text-align: center; }

.admin { width: min(100% - 2rem, 50rem); margin: 0 auto; padding: clamp(2rem, 7vw, 4rem) 0; }
.admin-brand { margin: 0 0 .75rem; color: #a84632; font-size: .75rem; font-weight: 800; letter-spacing: .14em; }
.admin-identity { color: color-mix(in srgb, currentColor 68%, transparent); }
.admin-list { display: grid; gap: .75rem; margin: 2rem 0 0; padding: 0; list-style: none; }
.admin-card { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.25rem; border: 1px solid #26201d1a; border-radius: .9rem; background: #fff; }
.admin-card h2, .admin-card h3 { margin: 0; font-size: 1.1rem; }
.admin-card p { margin: .45rem 0 0; color: color-mix(in srgb, currentColor 68%, transparent); }
.admin-card a, .admin-back { color: #753020; font-weight: 700; }
.admin-card a:focus-visible, .admin-back:focus-visible { outline: 3px solid #a84632; outline-offset: 3px; }
.admin-public-link { white-space: nowrap; }
.admin-private { color: color-mix(in srgb, currentColor 60%, transparent); font-size: .9rem; }
.admin-details { display: grid; gap: 1rem; margin: 2rem 0; }
.admin-details div { display: grid; gap: .3rem; }
.admin-details dt { color: color-mix(in srgb, currentColor 68%, transparent); font-size: .85rem; }
.admin-details dd { margin: 0; font-weight: 650; }
.admin-primary-link, .admin-secondary-button { display: inline-flex; min-height: 2.75rem; align-items: center; justify-content: center; padding: .65rem .9rem; border: 1px solid #75302040; border-radius: .45rem; background: #fff; color: #753020; font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; }
.admin-primary-link { border-color: #753020; background: #753020; color: white; }
.admin-primary-link:focus-visible, .admin-secondary-button:focus-visible, .admin-form input:focus-visible, .admin-form select:focus-visible { outline: 3px solid #a84632; outline-offset: 2px; }
.admin-card-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .75rem; }
.admin-card-actions form, .admin-member-list form { margin: 0; }
.admin-form { display: grid; max-width: 38rem; gap: .55rem; margin: 1.5rem 0; }
.admin-form label { font-weight: 700; }
.admin-form input, .admin-form select { width: 100%; min-height: 2.75rem; padding: .65rem .75rem; border: 1px solid #26201d40; border-radius: .45rem; background: white; color: #26201d; font: inherit; }
.admin-form .editor-save { justify-self: start; margin-top: .5rem; }
.admin-slug-field { display: flex; align-items: center; gap: .35rem; }
.admin-slug-field > span { color: #655d58; font-weight: 700; }
.admin-slug-field input { min-width: 0; }
.admin-help { margin: 0 0 .5rem; color: #655d58; font-size: .9rem; line-height: 1.5; }
.editor-warning { padding: .75rem; border-left: 3px solid #9a5a24; background: #9a5a2412; color: #5c3517; line-height: 1.5; }
.admin-member-list { display: grid; gap: .6rem; margin: 1rem 0; padding: 0; list-style: none; }
.admin-member-list li { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .75rem; border: 1px solid #26201d1a; border-radius: .55rem; }
.admin-member-list li > span { min-width: 0; overflow-wrap: anywhere; }
.admin-member-form { margin-top: 1rem; }
.admin-members { margin-top: 2rem; }

.editor-page { width: min(100% - 2rem, 88rem); }
.editor-workspace { display: grid; grid-template-columns: minmax(20rem, .9fr) minmax(24rem, 1.1fr); align-items: start; gap: 1.25rem; margin-top: 1.5rem; }
.editor-fields, .editor-preview { min-width: 0; padding: 1.4rem; border: 1px solid #26201d1a; border-radius: .9rem; background: #fff; }
.editor-fields h2, .editor-preview-heading h2 { margin: 0 0 1.25rem; font-size: 1.1rem; }
.editor-fields form { display: grid; gap: .55rem; }
.editor-fields label, .editor-theme legend { font-weight: 700; }
.editor-fields input:not([type="color"]), .editor-fields textarea, .editor-fields select { width: 100%; padding: .75rem; border: 1px solid #26201d40; border-radius: .45rem; background: white; color: #26201d; font: inherit; }
.editor-fields input:focus-visible, .editor-fields textarea:focus-visible, .editor-fields select:focus-visible, .editor-fields button:focus-visible, .editor-preview button:focus-visible { outline: 3px solid #a84632; outline-offset: 2px; }
.editor-fields textarea { resize: vertical; }
.editor-theme { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .75rem; margin: .8rem 0; padding: .8rem; border: 1px solid #26201d26; border-radius: .55rem; }
.editor-theme legend { padding: 0 .3rem; }
.editor-avatar { display: grid; gap: .5rem; margin: .8rem 0; padding: .8rem; border: 1px solid #26201d26; border-radius: .55rem; }
.editor-avatar legend { padding: 0 .3rem; font-weight: 700; }
.editor-avatar .avatar { width: 4rem; height: 4rem; }
.editor-color { display: grid; gap: .35rem; }
.editor-color input { width: 100%; height: 2.5rem; padding: .15rem; border: 1px solid #26201d26; border-radius: .4rem; background: white; }
.editor-actions { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; flex-wrap: wrap; gap: .75rem; margin: 0 -1.4rem .75rem; padding: .75rem 1.4rem; border-bottom: 1px solid #26201d1a; background: #fffffff2; }
.editor-save, .editor-preview-open, .editor-preview-close { min-height: 2.75rem; padding: .75rem 1rem; border: 0; border-radius: .45rem; background: #753020; color: white; font: inherit; font-weight: 700; cursor: pointer; }
.editor-save:disabled { background: #77716d; cursor: not-allowed; }
.editor-dirty, .editor-preview-heading span { color: color-mix(in srgb, currentColor 68%, transparent); font-size: .9rem; }
.editor-saved { padding: .7rem 1rem; border-left: 3px solid #48764f; background: #48764f12; }
.editor-error, .editor-field-error { color: #9a251d; font-size: .9rem; }
.block-editor { margin-top: 1.2rem; padding-top: 1.1rem; border-top: 1px solid #26201d26; }
.block-editor-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.block-editor-heading h2 { margin: 0; }
.block-editor-heading > span { color: #753020; font-variant-numeric: tabular-nums; font-weight: 750; }
.editor-kicker { margin: 0 0 .25rem; color: #753020; font-size: .68rem; font-weight: 800; letter-spacing: .12em; }
.block-add { display: grid; gap: .35rem; margin-bottom: 1rem; padding: .85rem; border-radius: .6rem; background: #f8f3eb; }
.block-add > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .5rem; }
.block-add button, .editor-block-actions button, .editor-social-row button, .editor-social-add button { min-height: 2.75rem; padding: .55rem .8rem; border: 1px solid #75302040; border-radius: .4rem; background: #fff; color: #753020; font: inherit; font-weight: 700; cursor: pointer; }
.block-add button:disabled, .editor-block-actions button:disabled, .editor-social-add button:disabled { color: #77716d; cursor: not-allowed; opacity: .65; }
.block-add p { margin: 0; color: #655d58; font-size: .8rem; }
.editor-block-list { display: grid; gap: .7rem; margin: 0; padding: 0; list-style: none; }
.editor-block { position: relative; min-width: 0; padding: .75rem .9rem; border: 1px solid #26201d26; border-radius: .65rem; background: #fffdfa; }
.editor-block[data-drop-position]::before { position: absolute; z-index: 2; right: .45rem; left: .45rem; height: 3px; border-radius: 2px; background: #a84632; content: ''; pointer-events: none; }
.editor-block[data-drop-position="before"]::before { top: -.4rem; }
.editor-block[data-drop-position="after"]::before { bottom: -.4rem; }
.editor-block-dragging { opacity: .45; outline: 2px dashed #753020; outline-offset: 2px; }
.editor-block details > summary { display: flex; min-height: 2.75rem; align-items: center; gap: .65rem; cursor: pointer; list-style: none; }
.editor-block details > summary::-webkit-details-marker { display: none; }
.editor-hours { display: grid; gap: .6rem; }
.editor-hours-day { display: grid; gap: .55rem; margin: 0; padding: .75rem; border: 1px solid #26201d26; border-radius: .55rem; }
.editor-hours-day legend { padding: 0 .25rem; font-weight: 700; }
.editor-fields .editor-hours-open { display: flex; align-items: center; gap: .45rem; }
.editor-fields .editor-hours-open input[type="checkbox"] { width: 1.15rem; height: 1.15rem; margin: 0; accent-color: #753020; }
.editor-hours-range { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem; }
.editor-hours-range label { display: grid; gap: .25rem; font-size: .82rem; }
.editor-hours button, .editor-block-field button { min-height: 2.75rem; padding: .55rem .8rem; border: 1px solid #75302040; border-radius: .4rem; background: white; color: #753020; font: inherit; font-weight: 700; cursor: pointer; }
.editor-hours-copy { display: grid; gap: .5rem; margin-top: .35rem; padding: .75rem; border-radius: .55rem; background: #f8f3eb; }
.editor-hours-copy > summary { min-height: 2.75rem; align-content: center; font-weight: 700; }
.editor-hours-copy > label { font-size: .82rem; }
.editor-hours-copy-destinations { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .35rem; margin: 0; padding: .55rem; border: 1px solid #26201d26; border-radius: .45rem; }
.editor-hours-copy-destinations legend { padding: 0 .25rem; font-size: .82rem; font-weight: 700; }
.editor-fields .editor-hours-copy-day { display: flex; align-items: center; gap: .35rem; font-size: .82rem; }
.editor-fields .editor-hours-copy-day input[type="checkbox"] { width: 1.1rem; height: 1.1rem; margin: 0; accent-color: #753020; }
.editor-hours button:disabled { cursor: not-allowed; opacity: .6; }
.editor-block details > summary::before { content: '›'; color: #753020; font-size: 1.35rem; line-height: 1; transition: transform .15s ease; }
.editor-block details[open] > summary::before { transform: rotate(90deg); }
.editor-block-summary-content { overflow: hidden; flex: 1; color: #655d58; text-overflow: ellipsis; white-space: nowrap; }
.editor-block-summary-enabled { color: #655d58; font-size: .78rem; white-space: nowrap; }
.editor-block-number { display: grid; width: 2rem; height: 2rem; flex: 0 0 2rem; place-items: center; border-radius: 50%; background: #f1e3d8; color: #753020; font-size: .72rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.editor-block-content { padding-top: .65rem; }
.editor-block-enabled { display: flex; align-items: center; gap: .4rem; font-size: .83rem; white-space: nowrap; }
.editor-fields .editor-block-enabled input[type="checkbox"] { width: 1.15rem; height: 1.15rem; margin: 0; accent-color: #753020; }
.editor-block-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
.editor-block-field { display: grid; min-width: 0; gap: .3rem; }
.editor-block-field label { font-size: .82rem; }
.editor-block-field textarea { min-height: 5rem; }
.editor-social-list { display: grid; gap: .6rem; }
.editor-social-row { display: grid; grid-template-columns: minmax(7rem, .4fr) minmax(0, 1fr) auto; align-items: center; gap: .5rem; }
.editor-social-row .editor-field-error { grid-column: 2 / -1; margin: 0; }
.editor-social-row button { min-height: 2.75rem; }
.editor-social-add { display: grid; gap: .3rem; max-width: 28rem; margin-top: .5rem; }
.editor-social-add > div { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .5rem; }
.editor-block-actions { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: .75rem; }
.editor-block-actions button { min-height: 2.5rem; padding: .45rem .7rem; font-size: .85rem; }
.editor-block-actions button:last-child { margin-left: auto; }
.editor-block-drag { display: inline-grid; width: 2.25rem; min-height: 2.25rem; flex: 0 0 auto; place-items: center; padding: .2rem; border: 1px solid #75302040; border-radius: .4rem; background: white; color: #753020; cursor: grab !important; font-size: 1.1rem !important; }
.editor-block-drag:active { cursor: grabbing !important; }
.editor-block-unsupported { margin: .6rem 0; color: #655d58; font-size: .88rem; }
.editor-block-status:empty { display: none; }
.editor-preview { position: sticky; top: 2rem; display: flex; height: calc(100vh - 6rem); height: calc(100dvh - 6rem); max-height: calc(100vh - 6rem); flex-direction: column; }
.editor-preview-heading { display: flex; flex: 0 0 auto; align-items: center; flex-wrap: wrap; gap: .75rem; }
.editor-preview-heading h2 { margin-right: auto; }
.editor-preview-close, .editor-preview-open { display: none; }
.preview-surface { min-height: 0; flex: 1; overflow-y: auto; overscroll-behavior: contain; border: 1px solid #26201d18; border-radius: .65rem; background: var(--background, #fbf5ed); color: var(--text, #26201d); }
.preview-surface .profile { width: min(100% - 1.5rem, 42rem); }

@media (max-width: 48rem) {
  .editor-workspace { display: block; }
  .editor-theme { grid-template-columns: 1fr; }
  .editor-block-fields { grid-template-columns: 1fr; }
  .block-add > div { grid-template-columns: 1fr; }
  .editor-preview { position: static; display: none; height: auto; max-height: none; }
  .editor-preview-open { display: inline-flex; }
  .editor-block-drag { display: none; }
  .editor-social-row { grid-template-columns: minmax(0, 1fr) auto; }
  .editor-social-row label { grid-column: 1 / -1; }
  .editor-hours-copy-destinations { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .editor-page.preview-open .editor-preview { position: fixed; z-index: 10; inset: 0; display: flex; width: 100%; height: 100vh; height: 100dvh; max-height: 100dvh; overflow-y: auto; padding: 1rem; border: 0; border-radius: 0; background: #fbf5ed; }
  .editor-page.preview-open .editor-preview-heading { position: sticky; top: -1rem; z-index: 1; padding: .75rem 0; background: #fff; }
  .editor-page.preview-open .preview-surface { min-height: 0; }
  .editor-preview-close { display: inline-flex; }
}

@media (max-width: 36rem) {
  .hours-block dl div { display: grid; gap: .15rem; }
  .hours-block dd { text-align: left; white-space: nowrap; font-variant-numeric: tabular-nums; }
  .admin-card { align-items: flex-start; flex-direction: column; }
  .admin-card-actions { width: 100%; justify-content: space-between; }
  .admin-member-list li { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}
