/* SimpleAIHub shared Python/code toolbar — mobile-safe */
.sah-codebar {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 58px;
  padding: 10px 14px;
  box-sizing: border-box;
  background: #f1f3f5;
  border-bottom: 1px solid #dfe3e8;
  color: #344054;
}
.sah-codebar__language {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  flex: 0 1 auto;
  color: #344054;
  font-size: 15px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
}
.sah-codebar__icon { font-size: 15px; font-weight: 900; letter-spacing: -.05em; }
.sah-codebar__title { display: none; }
.sah-codebar__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  margin-left: auto;
  flex: 0 0 auto;
}
.sah-codebar__button {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #cbd3dc;
  border-radius: 8px;
  background: #fff;
  color: #344054;
  font: 700 15px/1 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 1px 1px rgba(16,24,40,.03);
  transition: background .15s,border-color .15s,transform .05s;
}
.sah-codebar__button:hover { background:#f8fafc; border-color:#98a2b3; }
.sah-codebar__button:active { transform:translateY(1px); }
.sah-codebar__button:focus-visible { outline:2px solid #7c3aed; outline-offset:2px; }
.sah-codebar__button.is-copied { background:#f0fdf4; border-color:#86efac; color:#166534; }
.sah-codebar__button.sah-codebar__colab { color:#344054; }

/* Keep the toolbar intact on phones; only the code itself scrolls horizontally. */
@media (max-width: 600px) {
  .sah-codebar { min-height:54px; padding:8px 9px; gap:8px; }
  .sah-codebar__language { font-size:15px; }
  .sah-codebar__actions { gap:6px; }
  .sah-codebar__button { min-height:34px; padding:0 9px; font-size:15px; }
}
@media (max-width: 360px) {
  .sah-codebar { padding-left:8px; padding-right:8px; }
  .sah-codebar__language { font-size:15px; gap:5px; }
  .sah-codebar__button { min-height:32px; padding:0 7px; font-size:15px; }
  .sah-codebar__actions { gap:5px; }
}

.sah-code-block {
  overflow: hidden;
  border: 1px solid #cbd3dc;
  border-radius: 11px;
  background: #f8fafc;
}
.sah-code-block pre {
  margin: 0;
  padding: 18px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  background: #f8fafc;
  color: #344054;
  border: 0;
  border-radius: 0;
  white-space: pre;
  tab-size: 4;
  font: 15px/1.65 ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;
}
@media (max-width:600px) {
  .sah-code-block pre { padding:14px; font-size:15px; line-height:1.6; }
}
