[hidden] { display: none !important; }
.editor-tabs { display:flex; gap:8px; border-bottom:1px solid #dbe3e0; margin-bottom:20px; }
.editor-tabs button { padding:12px 22px; border-bottom:3px solid transparent; color:#64746d; font-weight:600; }
.editor-tabs button[aria-selected=true] { border-color:#059669; color:#047857; }
/* Keep event suggestions below the seating workspace, at the supplied banner size. */
.affiliate-panel { margin:24px 0; padding:12px 16px; border-top:1px solid #e0e7e3; }
.affiliate-panel > h2 { margin:0 0 8px; color:#64746d; font-size:11px; font-weight:400; }
.affiliate-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:24px; }
.affiliate-card { display:flex; align-items:center; justify-content:space-between; gap:12px; min-width:0; }
.affiliate-heading { min-width:0; }
.affiliate-heading h3 { margin:0; color:#33443b; font-size:13px; line-height:1.6; font-weight:500; }
.affiliate-heading span { color:#64746d; font-size:12px; }
.affiliate-code { display:flex; flex:0 0 120px; align-items:center; position:relative; }
.affiliate-code a { display:block; }
.affiliate-code a:focus-visible { outline:2px solid #059669; outline-offset:4px; }
.affiliate-code img[width="120"] { display:block; width:120px; height:60px; }
.affiliate-code img[width="1"] { position:absolute; width:1px; height:1px; }
.editor-panel { background:white; border:1px solid #e0e7e3; border-radius:16px; padding:24px; margin-bottom:20px; }
.editor-panel h2 { font-size:18px; font-weight:700; }
.editor-panel p { color:#64746d; font-size:13px; margin:8px 0; }
.editor-heading, .editor-actions { display:flex; align-items:center; flex-wrap:wrap; gap:10px; margin-bottom:14px; }
.editor-heading { justify-content:space-between; }
.editor-panel button, .editor-panel select, .editor-panel input:not([type=checkbox]):not([type=radio]), .editor-panel textarea { border:1px solid #cbd5d1; border-radius:8px; padding:8px 10px; font-size:14px; background:white; }
.editor-panel button { cursor:pointer; }
.editor-panel button:hover { background:#ecfdf5; }
.editor-panel button.primary { background:#047857; color:white; border-color:#047857; font-weight:600; }
.editor-panel button:disabled { opacity:.4; cursor:default; }
.editor-panel :focus-visible, .editor-tabs :focus-visible { outline:2px solid #059669; outline-offset:2px; }
.editor-panel textarea { display:block; width:100%; margin:8px 0 12px; }
.editor-panel summary { cursor:pointer; font-size:14px; padding:6px 0; }
.editor-box { background:#f8faf9; border:1px solid #e1e8e4; border-radius:10px; padding:14px; margin:14px 0; }
.editor-feedback:not(:empty) { margin-bottom:14px; }
.editor-feedback > div:not(.hidden) { margin:8px 0; }
.turnstile-panel { margin-top:.75rem; padding:.75rem; border:1px solid #dbe4ea; border-radius:.75rem; background:#f8fafc; }
.turnstile-panel p { margin:.5rem 0 0; color:#64748b; font-size:.75rem; line-height:1.55; }
.member-scroll { max-height:65vh; overflow:auto; }
.member-table { border-collapse:separate; border-spacing:0; width:100%; font-size:14px; }
.member-table th { position:sticky; top:0; z-index:1; background:#f1f5f3; text-align:left; color:#52665b; }
.member-table th, .member-table td { padding:10px 8px; border-bottom:1px solid #e5ebe7; }
.member-table input[type=text] { width:100%; min-width:100px; }
.member-table select { max-width:120px; }
.gender-buttons { display:flex; white-space:nowrap; gap:3px; }
.gender-buttons button[aria-pressed=true] { color:#065f46; background:#d1fae5; border-color:#059669; }
.member-table .gender-buttons button { padding:7px; }
.member-table tr:has(input[type=checkbox]:checked) { background:#f0fdf4; }
.field-editor { display:grid; grid-template-columns:130px 1fr auto; gap:10px; align-items:start; margin:12px 0; }
.field-editor textarea { margin:0; }
.bulk-bar .editor-actions { margin:8px 0 0; }
.legacy-tags, .paste-errors { color:#a34e10; font-size:12px; }
.paste-preview { max-height:200px; overflow:auto; white-space:pre-wrap; padding:10px; }
@media(max-width:640px) {
  main { padding:12px !important; }
  .affiliate-panel { padding:12px 0; }
  .affiliate-grid { grid-template-columns:1fr; gap:16px; }
  .editor-panel { padding:14px; }
  [data-controller=app] > header button, .editor-panel button, .seat-tools button { min-height:44px; }
  .assignment-panel .editor-actions label { display:flex; min-height:44px; align-items:center; }
  .editor-panel input:not([type=checkbox]):not([type=radio]), .editor-panel select, .editor-panel textarea, .island input { font-size:16px !important; }
  .member-table thead { display:none; }
  .member-table tr { display:flex; flex-wrap:wrap; padding:10px 0; border-bottom:1px solid #e5ebe7; gap:6px; }
  .member-table td { border:0; padding:3px; }
  .member-table td:nth-child(2) { flex:1; min-width:65%; }
  .member-table td[data-label]:before { content:attr(data-label); display:block; color:#64746d; font-size:11px; margin-bottom:3px; }
  .field-editor { grid-template-columns:1fr; }
  .editor-tabs { position:sticky; top:0; background:#f9fafb; z-index:45; }
}
@media print { #seats-panel[hidden] { display:block !important; } }

.editor-panel button.danger { color:#b91c1c; border-color:#fecaca; }
.editor-panel button.danger:hover { background:#fef2f2; }

.seat-shell { position:relative; min-width:80px; }
.seat-shell .seat { width:100%; height:100%; min-height:100px; cursor:pointer; }
.seat-shell .seat[draggable=true] { cursor:grab; }
.seat-move { position:absolute; z-index:2; top:3px; right:3px; display:flex; width:30px; height:30px; align-items:center; justify-content:center; border:1px solid #a7d9c5; border-radius:999px; color:#047857; background:#fff; box-shadow:0 1px 2px #0f172a14; }
.seat-move:hover { background:#ecfdf5; border-color:#10b981; }
.seat-move svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.touch-movable { touch-action:none; -webkit-touch-callout:none; }
.touch-drag-ghost { position:fixed; z-index:100; top:0; left:0; max-width:180px; padding:8px 12px; border:2px solid #10b981; border-radius:10px; color:#064e3b; background:#ecfdf5eb; box-shadow:0 8px 24px #0f172a33; font-size:14px; font-weight:700; pointer-events:none; }
.touch-drop-target { outline:3px solid #10b981 !important; outline-offset:2px; background-color:#d1fae5 !important; }
.touch-dragging { user-select:none; }
.seat-tools { display:flex; align-items:center; flex-wrap:wrap; gap:12px; font-size:13px; color:#52665b; }
.seat-tools button, .move-dialog button { border:1px solid #cbd5d1; padding:8px 12px; border-radius:8px; background:white; }
.seat-tools button:disabled { opacity:.4; }
.seat-shell :focus-visible, .seat-tools :focus-visible { outline:3px solid #059669; outline-offset:2px; }
.board-help { font-size:13px; color:#52665b; margin:12px 0 20px; }
.previous-panel { margin-top:20px; }
.island { max-width:100%; overflow-x:auto; }
.move-dialog { margin:auto; padding:24px; width:min(480px, calc(100% - 24px)); border:1px solid #cbd5d1; border-radius:16px; }
.move-dialog::backdrop { background:#14271f66; }
.move-dialog h2 { font-size:18px; font-weight:700; }
.move-dialog p { margin:12px 0; font-size:13px; color:#52665b; }
.move-dialog select { width:100%; padding:10px; border:1px solid #cbd5d1; border-radius:8px; margin:8px 0 20px; }
.move-dialog button.primary { color:white; background:#047857; }
@media print { .seat-shell .seat { padding-bottom:6px; min-height:72px; } .island { overflow:visible; } }
.seat-shell .seat [data-role=name] { max-width:100%; white-space:normal; overflow-wrap:anywhere; overflow:visible; }
.previous-link { color:#047857; text-decoration:underline; font-size:13px; }
#previous-layout { scroll-margin-top:90px; }
@media(max-width:640px) {
  [data-controller=app] > header { position:static; }
  [data-app-target=board] { padding:8px !important; gap:16px !important; }
  .island { width:100% !important; padding:10px !important; }
  .island .grid { grid-template-columns:repeat(var(--island-cols), minmax(58px, 1fr)) !important; }
  .seat-shell { min-width:58px; }
  .seat-shell .seat { min-height:104px; }
  .seat-move { width:32px; height:32px; }
  .island:after { content:'4列以上は左右にスクロールできます'; display:block; font-size:11px; color:#64746d; margin-top:8px; position:sticky; left:0; }
  .move-dialog select { font-size:16px; }
}
@media print { .island input::placeholder { color:transparent; } }
.previous-link { display:block; margin:8px 0; }
.board-front { color:#64746d; font-size:11px; text-align:center; margin:6px 0; }
@media print { .seat-shell .seat { min-height:72px; padding-bottom:6px; } }

.condition-list { display:grid; gap:10px; margin:12px 0; padding:0; list-style:none; }
.condition-row { border:1px solid #dbe5df; border-radius:10px; padding:12px; background:#f8faf9; min-width:0; }
.condition-heading { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
.condition-rank { font-size:12px; color:#52665b; min-width:16px; }
.condition-order { display:flex; gap:4px; margin-left:auto; }
.condition-order button { min-width:36px; min-height:36px; }
.condition-fields { display:flex; gap:8px; margin-top:10px; flex-wrap:wrap; }
.condition-fields select { flex:1; min-width:0; max-width:100%; }
.condition-empty { color:#64746d; font-size:14px; padding:12px 0; }
.view-switch { display:flex; gap:4px; }
.view-switch button[aria-pressed=true] { border-color:#059669; color:#047857; background:#ecfdf5; }
.board-overview { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; padding:12px; border:1px solid #dbe5df; border-radius:12px; background:white; }
.overview-island { display:block; min-width:0; padding:10px; border:1px solid #dbe5df; border-radius:8px; text-align:center; }
.overview-island:hover, .overview-island:focus-visible { outline:2px solid #059669; }
.overview-island strong { font-size:13px; }
.overview-island .board-front { display:block; }
.overview-grid { display:grid; gap:3px; }
.overview-seat { display:flex; flex-direction:column; min-width:0; border:1px solid #a7d9c5; border-radius:3px; background:#ecfdf5; padding:3px 1px; font-size:10px; }
.overview-seat span { display:-webkit-box; -webkit-box-orient:vertical; -webkit-line-clamp:4; overflow:hidden; white-space:normal; overflow-wrap:anywhere; font-size:9px; line-height:1.2; }
.overview-seat small { font-size:8px; color:#52665b; }
.is-disabled { background:#f1f5f9; color:#64748b; border-style:dashed; }
.same-seats { margin:12px 0; }
.same-seats .editor-actions { max-height:240px; overflow:auto; padding:6px; }
.print-board { display:none; }
@media(max-width:640px) {
  .condition-heading { gap:4px; }
  .condition-heading > select { max-width:calc(100% - 24px); }
  .condition-fields { flex-direction:column; }
  .condition-fields select, .condition-row textarea { font-size:16px; }
  .board-overview { gap:6px; padding:6px; }
  .overview-island { padding:5px; }
}
@media print {
  @page { size:A4 landscape; margin:12mm; }
  body { background:white !important; }
  main { padding:0 !important; margin:0 !important; max-width:none !important; }
  [data-app-target=board] { display:none !important; }
  .print-board { display:block; color:#1f2937; }
  .print-page { break-after:page; }
  .print-page:last-child { break-after:auto; }
  .print-header { display:flex; align-items:center; justify-content:space-between; padding:0 0 4mm; margin-bottom:5mm; border-bottom:1px solid #dbe3e0; }
  .print-brand { display:flex; align-items:center; gap:2.5mm; }
  .print-brand-mark { display:grid; grid-template-columns:repeat(2,1fr); gap:1mm; width:9mm; height:9mm; padding:2mm; border-radius:2.5mm; background:#059669; }
  .print-brand-mark i { border:1px solid white; border-radius:.5mm; }
  .print-page h1 { font-size:14pt; line-height:1.15; font-weight:700; letter-spacing:-.02em; }
  .print-brand p { margin-top:.5mm; color:#64748b; font-size:7.5pt; line-height:1; }
  .print-page-number { min-width:15mm; padding:1.5mm 2.5mm; border:1px solid #dbe3e0; border-radius:999px; color:#52665b; background:#f8faf9; font-size:8pt; text-align:center; }
  .print-island { margin-bottom:5mm; padding:4mm; border:1px solid #e0e7e3; border-radius:3mm; background:#f8faf9; break-inside:avoid; }
  .print-island h2 { display:flex; align-items:center; justify-content:space-between; gap:4mm; margin-bottom:3mm; color:#334155; font-size:11pt; font-weight:700; }
  .print-island h2 > span { padding-left:2.5mm; border-left:3px solid #10b981; }
  .print-island h2 small { color:#64746d; font-size:8pt; font-weight:400; text-align:right; }
  .print-island h2 small span { color:#047857; font-weight:600; }
  .print-grid { display:grid; gap:2mm; }
  .print-seat { position:relative; min-width:0; min-height:18mm; padding:5.5mm 2.5mm 2.5mm; border:1.5px solid #10b981; border-radius:2mm; background:#ecfdf5; text-align:center; break-inside:avoid; }
  .print-seat > small { position:absolute; top:2mm; left:2.5mm; display:block; color:#52665b; font-size:7.5pt; font-weight:500; line-height:1; }
  .print-seat > div { color:#0f172a; font-size:9.5pt; font-weight:600; line-height:1.25; overflow-wrap:anywhere; white-space:normal; }
  .print-seat.is-empty { border-color:#cbd5d1; border-style:dashed; background:white; }
  .print-seat.is-empty > div { color:#94a3b8; font-size:8pt; font-weight:500; }
  .print-seat.is-disabled { border-color:#94a3b8; border-style:dashed; background:#f1f5f9; color:#64748b; }
  .print-seat.is-disabled > div { color:#64748b; font-size:8pt; font-weight:500; }
  .print-tags { display:inline-block; max-width:100%; margin-top:1.5mm; padding:.5mm 1.5mm; border:1px solid #a7d9c5; border-radius:999px; color:#047857; background:white; font-size:7pt; line-height:1.2; overflow-wrap:anywhere; }
}
.sekigime-home-link {
  display: inline-block;
  margin-bottom: 0.1rem;
  color: #047857;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.25;
  text-decoration: none;
}

.sekigime-home-link:hover {
  text-decoration: underline;
}

.sekigime-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1rem;
}

.sekigime-footer a {
  color: #475569;
}
