/* v1.0.4: Graphite is limited to the existing dark theme; light tokens stay unchanged. */
:root[data-theme="dark"]{
  --bg:#202124;--panel:#303136;--panel-2:#38393e;--panel-3:#414247;
  --text:#f5f5f5;--muted:#c3c4c9;--line:#414247;--line-strong:#65666c;
  --accent:#2563eb;--brand:#a9c3ff;--link-color:#a9c3ff;--focus-color:#a9c3ff;
  --color-studio-mist:#202124;--color-gallery-white:#303136;--color-paper-frost:#38393e;
  --color-control-gray:#414247;--color-ink:#f5f5f5;--color-slate:#c3c4c9;
  color-scheme:dark;
}
:root[data-theme="dark"] :is(.sidebar,.topbar,.account-menu,.modal,.panel){border-color:var(--line)}
:root[data-theme="dark"] :is(input,textarea,select){color:var(--text);background-color:var(--panel-2);border-color:var(--line-strong)}
:root[data-theme="dark"] :is(button,a,input,textarea,select):focus-visible{outline:2px solid var(--focus-color);outline-offset:2px}
.restaurant-filters{display:grid;grid-template-columns:minmax(200px,2fr) repeat(2,minmax(150px,1fr));gap:16px;margin-bottom:20px}
.restaurant-filters label{display:grid;gap:8px;min-width:0}.restaurant-filters :is(input,select){width:100%;min-width:0}
.restaurant-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,300px),1fr));gap:16px}
.restaurant-card{min-width:0;display:flex;flex-direction:column;gap:10px}.restaurant-card p{margin:0;white-space:pre-wrap;overflow-wrap:anywhere}.restaurant-card a{color:var(--link-color)}
.restaurant-card-top{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}.restaurant-card h2{font-size:var(--text-card-title);margin:0;overflow-wrap:anywhere}.restaurant-card-top span{color:var(--muted);font-size:var(--text-label)}.restaurant-card .detail-actions{margin-top:auto;padding-top:12px}.restaurant-notes{border-top:1px solid var(--line);padding-top:12px}
.restaurant-editor .field-grid textarea{min-height:85px}
.sidebar-order-trigger{margin:8px 0 20px}.sidebar-order-groups{max-height:min(55vh,550px);overflow:auto;display:grid;gap:16px}.sidebar-order-group h3{font-size:var(--text-body);margin:0 0 8px}.sidebar-order-list{display:grid;gap:5px}.sidebar-order-row{display:flex;align-items:center;gap:8px;background:var(--panel-2);border:1px solid var(--line);border-radius:var(--radius-md);padding:7px 10px}.sidebar-order-row strong{flex:1;min-width:0;overflow-wrap:anywhere}.sidebar-order-row[draggable=true]{cursor:grab}.sidebar-order-row button{min-width:36px}
@media(max-width:780px){.restaurant-filters{grid-template-columns:1fr}.sidebar-order-row[draggable=true]{cursor:default}}
/* v1.0.4.1 — Restaurant facts, separate Maps line, and user-managed cuisines. */
.restaurant-head-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.restaurant-facts{list-style:disc;padding-left:19px;margin:0;display:grid;gap:8px;min-width:0}
.restaurant-facts li{line-height:1.65;overflow-wrap:anywhere;padding-left:2px}
.restaurant-facts li::marker{color:var(--muted)}
.restaurant-fact-label{font-weight:600}
.restaurant-cuisine-add{display:flex;align-items:end;gap:10px;margin:16px 0}
.restaurant-cuisine-add label{flex:1;min-width:0;display:grid;gap:8px}
.restaurant-cuisine-add input{width:100%;min-width:0}
.restaurant-cuisine-list{max-height:40vh;overflow:auto;border-top:1px solid var(--line)}
.restaurant-cuisine-row{display:flex;align-items:center;gap:12px;padding:12px 0;border-bottom:1px solid var(--line)}
.restaurant-cuisine-row>span{font-weight:600;flex:1;min-width:0;overflow-wrap:anywhere}
.restaurant-cuisine-row small{color:var(--muted)}
@media(max-width:780px){.restaurant-head-actions{width:100%}.restaurant-cuisine-add{align-items:stretch;flex-direction:column}.restaurant-cuisine-row{flex-wrap:wrap}}

/* Restaurant editor: five rows, responsive two-column layout. */
.restaurant-editor .restaurant-edit-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start}
.restaurant-editor .restaurant-edit-field{display:grid;gap:8px;min-width:0}
.restaurant-editor .restaurant-edit-field :is(input,textarea){width:100%;min-width:0;box-sizing:border-box}
.restaurant-editor .restaurant-edit-name,.restaurant-editor .restaurant-edit-notes{grid-column:1/-1}
.restaurant-editor .restaurant-edit-notes textarea{min-height:100px;resize:vertical}
@media(max-width:600px){.restaurant-editor .restaurant-edit-grid{grid-template-columns:minmax(0,1fr)}}

/* Native selects match the existing category control, including OS menu behavior. */
.restaurant-editor .restaurant-edit-field select{width:100%;min-width:0;box-sizing:border-box}
.restaurant-editor [data-restaurant-new][hidden]{display:none}
.restaurant-cuisine-manager .restaurant-cuisine-row{flex-wrap:nowrap;gap:12px;padding:12px 0}
.restaurant-cuisine-manager .restaurant-cuisine-row>.cuisine-drag{flex:0 0 20px;color:var(--muted);cursor:grab;font-weight:400}
.restaurant-cuisine-manager .cuisine-name{display:grid;gap:4px;flex:1;min-width:0;overflow-wrap:anywhere}
.restaurant-cuisine-manager .cuisine-name strong{font-size:var(--text-body)}
.restaurant-cuisine-manager .cuisine-name small{font-size:var(--text-label)}
.restaurant-cuisine-manager .cuisine-actions{display:flex;gap:8px;align-items:center;flex:none}
.restaurant-cuisine-manager .cuisine-actions button{min-width:36px;min-height:36px}
@media(max-width:600px){.restaurant-cuisine-manager .restaurant-cuisine-row{gap:8px}.restaurant-cuisine-manager .cuisine-actions{gap:4px}.restaurant-cuisine-manager .cuisine-actions button{min-width:44px;min-height:44px;padding:6px}.restaurant-cuisine-manager .modal-actions{flex-wrap:wrap}}
