@font-face {
  font-family: "Newsreader";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/static/fonts/newsreader-subset.woff2") format("woff2");
}

html {
  font-family: "Newsreader", Georgia, Cambria, serif;
  font-size: 18px;
  line-height: 1.58;
}

html[data-theme="dark"] {
  color-scheme: dark;
}

body {
  margin: 2rem auto;
  max-width: 820px;
  padding: 0 1rem;
  color: #111;
  background: #fff;
}

html[data-theme="dark"] body {
  background: #111;
  color: #ece7df;
}

body:has(.webssh-shell) {
  max-width: 1180px;
}

[hidden] {
  display: none !important;
}

h1,
h2,
h3 {
  font-family: "Newsreader", Georgia, Cambria, serif;
  font-weight: 800;
}

h1 {
  font-size: 2.8rem;
  line-height: 1;
  margin: 1.25rem 0 0.85rem;
}

h2 {
  font-size: 1.55rem;
  line-height: 1.15;
}

h3 {
  font-size: 1.2rem;
  line-height: 1.2;
}

a {
  color: #181818;
  text-decoration-color: rgba(17, 17, 17, 0.35);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.16em;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

a:hover,
a:focus {
  color: #000;
  text-decoration-color: currentColor;
}

html[data-theme="dark"] a {
  color: #ece7df;
  text-decoration-color: rgba(236, 231, 223, 0.42);
}

html[data-theme="dark"] a:hover,
html[data-theme="dark"] a:focus {
  color: #fff;
  text-decoration-color: currentColor;
}

header {
  border-color: #ddd;
  border-style: solid;
  border-width: 0;
}

header {
  border-bottom-width: 1px;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  padding-right: 4.6rem;
  position: relative;
}

header p {
  font-family: "Newsreader", Georgia, Cambria, serif;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1;
  margin: 0 0 0.45rem;
}

nav a {
  margin-right: 1rem;
}

.theme-toggle {
  align-items: center;
  background: transparent;
  border: 1px solid #aaa;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  font-size: 0.85rem;
  justify-content: center;
  line-height: 1;
  min-height: 1.85rem;
  padding: 0 0.7rem;
  position: absolute;
  right: 0;
  top: 0.05rem;
}

footer {
  border-top: 1px solid #ddd;
  color: #555;
  font-size: 0.95rem;
  margin-top: 3rem;
  padding: 1rem 0 0;
}

footer p {
  margin: 0 0 0.35rem;
}

footer a {
  margin-right: 0.85rem;
}

html[data-theme="dark"] header,
html[data-theme="dark"] footer,
html[data-theme="dark"] .webssh-home,
html[data-theme="dark"] .webssh-auth,
html[data-theme="dark"] .webssh-account,
html[data-theme="dark"] .webssh-connect,
html[data-theme="dark"] .note,
html[data-theme="dark"] td,
html[data-theme="dark"] th {
  border-color: #3a3a3a;
}

html[data-theme="dark"] footer,
html[data-theme="dark"] .profile-photo figcaption,
html[data-theme="dark"] .site-image figcaption,
html[data-theme="dark"] .post-date,
html[data-theme="dark"] .note {
  color: #b8b2aa;
}

html[data-theme="dark"] .theme-toggle,
html[data-theme="dark"] button,
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea {
  background: #1a1a1a;
  border-color: #555;
  color: #ece7df;
}

html[data-theme="dark"] button:hover,
html[data-theme="dark"] button:focus {
  background: #252525;
  border-color: #777;
}

html[data-theme="dark"] .webssh-connect select {
  background-image:
    linear-gradient(45deg, transparent 50%, #d8d2c8 50%),
    linear-gradient(135deg, #d8d2c8 50%, transparent 50%);
}

html[data-theme="dark"] .webssh-profile-button,
html[data-theme="dark"] .webssh-profile-menu {
  background: #1a1a1a;
  border-color: #555;
  color: #ece7df;
}

html[data-theme="dark"] .webssh-sidebar-toggle {
  background: rgba(236, 231, 223, 0.08);
  color: #cfc8bd;
}

html[data-theme="dark"] .webssh-sidebar-toggle:hover,
html[data-theme="dark"] .webssh-sidebar-toggle:focus {
  background: rgba(236, 231, 223, 0.12);
  color: #fff;
}

html[data-theme="dark"] .webssh-profile-menu button:hover,
html[data-theme="dark"] .webssh-profile-menu button:focus {
  background: #252525;
}

html[data-theme="dark"] .webssh-fingerprint {
  background: #181818;
  border-color: #444;
}

html[data-theme="dark"] .webssh-auth-switch {
  background: #111;
  border-color: #555;
}

html[data-theme="dark"] .webssh-auth-switch button.is-active {
  background: #ece7df;
  color: #111;
}

html[data-theme="dark"] .post-list-item {
  border-top-color: #333;
}

html[data-theme="dark"] .webssh-preview-files {
  background: #181818;
  border-left-color: #3a3a3a;
  color: #ece7df;
}

html[data-theme="dark"] .webssh-preview-keybar {
  background: #1a1a1a;
  border-bottom-color: #3a3a3a;
}

html[data-theme="dark"] .webssh-preview-keybar span,
html[data-theme="dark"] .webssh-preview-filebar span,
html[data-theme="dark"] .webssh-preview-filebar b {
  background: #111;
  border-color: #444;
  color: #ece7df;
}

html[data-theme="dark"] .webssh-preview-files div:not(.webssh-preview-filebar):not(.webssh-preview-actions) {
  border-bottom-color: #333;
}

html[data-theme="dark"] .webssh-preview-actions span {
  border-color: #555;
  color: #ece7df;
}

html[data-theme="dark"] .webssh-keybar,
html[data-theme="dark"] .editor-toolbar {
  background: #1a1a1a;
  border-color: #3a3a3a;
}

html[data-theme="dark"] .webssh-keybar button,
html[data-theme="dark"] .editor-toolbar button,
html[data-theme="dark"] .webssh-tabbar button,
html[data-theme="dark"] .webssh-session-carousel button,
html[data-theme="dark"] .webssh-upload {
  background: #242424;
  border-color: #555;
  color: #ece7df;
}

html[data-theme="dark"] .webssh-tabbar button.is-active,
html[data-theme="dark"] .webssh-session-carousel button.is-active {
  background: #ece7df;
  border-color: #ece7df;
  color: #111;
}

html[data-theme="dark"] .file-link {
  color: #ece7df;
}

html[data-theme="dark"] .webssh-loading {
  color: #c8c2ba;
}

html[data-theme="dark"] .webssh-filegrid.is-loading::after {
  background: rgba(17, 17, 17, 0.74);
}

.home-profile {
  display: block;
}

.profile-photo {
  float: left;
  margin: 0.25rem 1.25rem 0.75rem 0;
  max-width: 165px;
  width: 34%;
}

.profile-photo img {
  display: block;
  height: auto;
  max-width: 100%;
  width: 100%;
}

.profile-photo figcaption {
  color: #555;
  font-size: 0.85rem;
  margin-top: 0.35rem;
}

.home-profile::after {
  clear: both;
  content: "";
  display: table;
}

.resume-page {
  max-width: 900px;
}

.resume-page h1 {
  margin-bottom: 1.25rem;
}

.resume-page h2 {
  border-top: 1px solid #ddd;
  clear: both;
  font-size: 1.35rem;
  margin: 2rem 0 0.75rem;
  padding-top: 0.9rem;
}

.resume-page h3 {
  border-left: 3px solid #111;
  font-size: 1.08rem;
  margin: 1.25rem 0 0.4rem;
  padding-left: 0.65rem;
}

.resume-page p {
  margin: 0.35rem 0 0.85rem;
}

.resume-page ul {
  margin: 0.4rem 0 1.1rem;
  padding-left: 1.1rem;
}

.resume-page li {
  margin-bottom: 0.38rem;
}

.resume-page li::marker {
  color: #555;
}

html[data-theme="dark"] .resume-page h2 {
  border-top-color: #3a3a3a;
}

html[data-theme="dark"] .resume-page h3 {
  border-left-color: #ece7df;
}

html[data-theme="dark"] .resume-page li::marker {
  color: #b8b2aa;
}

.webssh-home {
  align-items: stretch;
  border-bottom: 1px solid #ddd;
  border-top: 1px solid #ddd;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: minmax(220px, 0.72fr) minmax(360px, 1.28fr);
  margin: 2.25rem 0;
  padding: 1.5rem 0;
}

.webssh-home h2 {
  margin-top: 0;
}

.webssh-home p {
  margin-bottom: 0.5rem;
}

.webssh-preview {
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  color: #f2f2f2;
  margin: 0;
  min-height: 100%;
  overflow: hidden;
}

.webssh-preview-toolbar {
  align-items: center;
  background: #1b1b1b;
  border-bottom: 1px solid #333;
  color: #cfcfcf;
  display: flex;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.72rem;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.65rem;
}

.webssh-preview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(160px, 0.9fr);
}

.webssh-preview-terminal {
  min-width: 0;
}

.webssh-preview-keybar {
  background: #f5f5f5;
  border-bottom: 1px solid #d7d7d7;
  color: #111;
  display: flex;
  gap: 0.25rem;
  overflow: hidden;
  padding: 0.35rem;
}

.webssh-preview-keybar span {
  background: #fff;
  border: 1px solid #999;
  border-radius: 7px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.68rem;
  line-height: 1;
  padding: 0.25rem 0.4rem;
  white-space: nowrap;
}

.webssh-preview pre {
  background: transparent;
  border: 0;
  border-radius: 0;
  margin: 0;
  overflow: auto;
  padding: 1rem;
}

.webssh-preview code {
  color: inherit;
  font-size: 0.78rem;
  line-height: 1.5;
}

.terminal-muted {
  color: #aaa;
}

.webssh-preview-files {
  background: #f4f4f4;
  border-left: 1px solid #333;
  color: #151515;
  display: grid;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.76rem;
  gap: 0.35rem;
  padding: 0.75rem;
}

.webssh-preview-filebar {
  align-items: center;
  display: grid;
  gap: 0.3rem;
  grid-template-columns: minmax(0, 1fr) auto auto;
}

.webssh-preview-filebar span,
.webssh-preview-filebar b {
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 6px;
  color: #111;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-weight: 400;
  overflow: hidden;
  padding: 0.25rem 0.4rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.webssh-preview-filebar b {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.68rem;
}

.webssh-preview-files div:not(.webssh-preview-filebar):not(.webssh-preview-actions) {
  align-items: center;
  border-bottom: 1px solid #ddd;
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  padding-bottom: 0.25rem;
}

.webssh-preview-files span {
  color: #666;
  white-space: nowrap;
}

.webssh-preview-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.15rem;
}

.webssh-preview-actions span {
  border: 1px solid #aaa;
  border-radius: 999px;
  color: #111;
  padding: 0.18rem 0.45rem;
}

.terminal-dots::after {
  animation: terminal-dots 3s steps(1, end) infinite;
  content: "";
}

@keyframes terminal-dots {
  0% {
    content: "";
  }
  25% {
    content: ".";
  }
  50% {
    content: "..";
  }
  75% {
    content: "...";
  }
  100% {
    content: "";
  }
}

input[type="text"],
input[type="password"],
select,
textarea {
  box-sizing: border-box;
  font: inherit;
  max-width: 100%;
  width: 100%;
}

button {
  background: #f7f7f7;
  border: 1px solid #aaa;
  border-radius: 8px;
  cursor: pointer;
  font: inherit;
  min-height: 2rem;
  padding: 0.25rem 0.65rem;
}

button:hover,
button:focus {
  background: #efefef;
  border-color: #777;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

table {
  border-collapse: collapse;
  width: 100%;
}

td,
th {
  border: 1px solid #ddd;
  padding: 0.35rem;
  text-align: left;
  vertical-align: top;
}

td p {
  margin: 0 0 0.5rem;
}

.inline {
  display: inline;
  margin-left: 0.5rem;
}

.site-image {
  margin: 1.5rem auto;
  text-align: center;
}

.site-image img {
  display: block;
  height: auto;
  margin: 0 auto;
  max-width: 100%;
}

.site-image figcaption {
  color: #555;
  font-size: 0.9rem;
  margin-top: 0.35rem;
}

.post-list {
  list-style: none;
  margin: 1rem 0;
  padding-left: 0;
}

.post-list-item {
  border-top: 2px solid #e5e5e5;
  display: flex;
  gap: 1.25rem;
  padding: 1.25rem 0;
}

.post-cover {
  flex: 0 0 220px;
}

.post-cover img {
  display: block;
  height: auto;
  max-width: 220px;
  width: 100%;
}

.post-list-body {
  flex: 1;
  min-width: 0;
}

.post-list-body h2,
.post-list-body h3 {
  line-height: 1.25;
  margin: 0 0 0.35rem;
}

.post-list-body h2 {
  font-size: 1.45rem;
}

.post-list-body h3 {
  font-size: 1.15rem;
}

.post-date {
  color: #555;
  font-size: 0.9rem;
  margin: 0 0 0.5rem;
}

.post-summary {
  margin: 0.4rem 0 0.6rem;
}

.admin-thumb {
  display: block;
  height: auto;
  margin: 0.5rem 0;
  max-width: 220px;
}

.note {
  border: 1px solid #ddd;
  margin: 1rem 0;
  padding: 0.75rem;
}

.marker-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0.35rem 0;
}

.webssh-auth,
.webssh-account {
  border: 1px solid #ddd;
  border-radius: 8px;
  margin: 1rem 0;
  padding: 1rem;
}

.webssh-auth-switch {
  background: #f3f3f3;
  border: 1px solid #ddd;
  border-radius: 8px;
  display: grid;
  gap: 0.25rem;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 1rem;
  padding: 0.25rem;
}

.webssh-auth-switch button {
  background: transparent;
  border: 0;
  border-radius: 6px;
  min-height: 2.1rem;
}

.webssh-auth-switch button.is-active {
  background: #fff;
  border: 1px solid #ddd;
  color: #111;
}

.webssh-auth input[type="text"],
.webssh-auth input[type="password"],
.webssh-connect input[type="text"],
.webssh-connect input[type="password"],
.webssh-connect input[type="number"],
.webssh-connect textarea,
.webssh-connect select,
.webssh-filebar input[type="text"],
.webssh-editor input[type="text"],
.webssh-editor textarea {
  background: #fbfbfb;
  border: 1px solid #b8b8b8;
  border-radius: 8px;
  box-sizing: border-box;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.04);
  min-height: 2.25rem;
  padding: 0.35rem 0.6rem;
}

.webssh-auth input[type="text"]:focus,
.webssh-auth input[type="password"]:focus,
.webssh-connect input[type="text"]:focus,
.webssh-connect input[type="password"]:focus,
.webssh-connect input[type="number"]:focus,
.webssh-connect textarea:focus,
.webssh-connect select:focus,
.webssh-filebar input[type="text"]:focus,
.webssh-editor input[type="text"]:focus,
.webssh-editor textarea:focus {
  border-color: #666;
  box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.1);
  outline: 0;
}

html[data-theme="dark"] .webssh-auth input[type="text"],
html[data-theme="dark"] .webssh-auth input[type="password"],
html[data-theme="dark"] .webssh-connect input[type="text"],
html[data-theme="dark"] .webssh-connect input[type="password"],
html[data-theme="dark"] .webssh-connect input[type="number"],
html[data-theme="dark"] .webssh-connect textarea,
html[data-theme="dark"] .webssh-connect select,
html[data-theme="dark"] .webssh-filebar input[type="text"],
html[data-theme="dark"] .webssh-editor input[type="text"],
html[data-theme="dark"] .webssh-editor textarea {
  background: #1a1a1a;
  border-color: #555;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.25);
  color: #ece7df;
}

html[data-theme="dark"] .webssh-auth input[type="text"]:focus,
html[data-theme="dark"] .webssh-auth input[type="password"]:focus,
html[data-theme="dark"] .webssh-connect input[type="text"]:focus,
html[data-theme="dark"] .webssh-connect input[type="password"]:focus,
html[data-theme="dark"] .webssh-connect input[type="number"]:focus,
html[data-theme="dark"] .webssh-connect textarea:focus,
html[data-theme="dark"] .webssh-connect select:focus,
html[data-theme="dark"] .webssh-filebar input[type="text"]:focus,
html[data-theme="dark"] .webssh-editor input[type="text"]:focus,
html[data-theme="dark"] .webssh-editor textarea:focus {
  border-color: #888;
  box-shadow: 0 0 0 3px rgba(236, 231, 223, 0.12);
}

.webssh-guest-button {
  background: #111;
  border-color: #111;
  color: #fff;
  width: 100%;
}

.webssh-auth button[type="submit"] {
  width: 100%;
}

.webssh-guest-button:hover,
.webssh-guest-button:focus {
  background: #000;
  border-color: #000;
}

.webssh-shell {
  align-items: stretch;
  display: grid;
  gap: 0.75rem;
  grid-template-columns: var(--webssh-sidebar-width, 280px) 1.35rem minmax(0, 1fr);
  margin: 1rem 0;
  transition: grid-template-columns 0.18s ease, gap 0.18s ease;
}

.webssh-shell.is-sidebar-collapsed {
  grid-template-columns: var(--webssh-sidebar-width, 280px) 1.35rem minmax(0, 1fr);
}

.webssh-shell.is-sidebar-collapsed .webssh-connect {
  border-width: 0;
  opacity: 0;
  overflow: hidden;
  padding-left: 0;
  padding-right: 0;
  pointer-events: none;
  visibility: hidden;
}

.webssh-sidebar-toggle {
  align-items: center;
  align-self: stretch;
  background: rgba(17, 17, 17, 0.045);
  border: 0;
  border-radius: 999px;
  box-sizing: border-box;
  color: #686868;
  cursor: pointer;
  display: flex;
  font-size: 1.35rem;
  justify-content: center;
  min-height: 12rem;
  padding: 0;
  transition: background 0.15s ease, color 0.15s ease, transform 0.18s ease;
  width: 1.35rem;
}

.webssh-sidebar-toggle:hover,
.webssh-sidebar-toggle:focus {
  background: rgba(17, 17, 17, 0.06);
  color: #111;
  outline: 0;
}

.webssh-shell.is-sidebar-collapsed .webssh-sidebar-toggle {
  transform: translateX(-0.1rem);
}

.webssh-connect {
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 1rem;
  transition: opacity 0.16s ease, padding 0.18s ease, border-width 0.18s ease;
}

.webssh-connect p {
  margin: 0 0 0.75rem;
}

.webssh-connect input[type="text"],
.webssh-connect input[type="password"],
.webssh-connect input[type="number"],
.webssh-connect textarea,
.webssh-connect select {
  height: 2.35rem;
  line-height: 1.35;
  width: 100%;
}

.webssh-connect textarea {
  height: auto;
  min-height: 7rem;
  resize: vertical;
}

.webssh-connect input[type="number"] {
  appearance: textfield;
  -moz-appearance: textfield;
}

.webssh-connect input[type="number"]::-webkit-inner-spin-button,
.webssh-connect input[type="number"]::-webkit-outer-spin-button {
  appearance: none;
  margin: 0;
}

.webssh-connect select {
  appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #555 50%),
    linear-gradient(135deg, #555 50%, transparent 50%);
  background-position:
    calc(100% - 1rem) 50%,
    calc(100% - 0.68rem) 50%;
  background-repeat: no-repeat;
  background-size: 0.35rem 0.35rem, 0.35rem 0.35rem;
  padding-right: 2rem;
}

.webssh-profile-picker {
  display: block;
  max-width: 100%;
  position: relative;
  width: 100%;
}

.webssh-profile-button {
  background: #f7f7f7;
  border: 1px solid #bbb;
  border-radius: 8px;
  box-sizing: border-box;
  min-height: 2.15rem;
  overflow: hidden;
  padding: 0.28rem 2rem 0.28rem 0.55rem;
  position: relative;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}

.webssh-profile-button::after {
  border-bottom: 1px solid currentColor;
  border-right: 1px solid currentColor;
  content: "";
  height: 0.42rem;
  position: absolute;
  right: 0.85rem;
  top: 45%;
  transform: rotate(45deg) translateY(-50%);
  width: 0.42rem;
}

.webssh-profile-menu {
  background: #fff;
  border: 1px solid #bbb;
  border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
  box-sizing: border-box;
  display: grid;
  gap: 0.2rem;
  left: 0;
  margin-top: 0.25rem;
  max-height: 14rem;
  overflow: auto;
  padding: 0.3rem;
  position: absolute;
  right: 0;
  z-index: 20;
}

.webssh-profile-menu[hidden] {
  display: none;
}

.webssh-profile-menu button {
  background: transparent;
  border: 0;
  border-radius: 6px;
  min-height: 2rem;
  overflow: hidden;
  padding: 0.35rem 0.5rem;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: 100%;
}

.webssh-profile-menu button:hover,
.webssh-profile-menu button:focus {
  background: #efefef;
}

.webssh-connect button {
  min-height: 2.15rem;
}

.webssh-fingerprint {
  background: #f8f8f8;
  border: 1px solid #ccc;
  border-radius: 8px;
  margin: 0 0 0.75rem;
  padding: 0.7rem;
}

.webssh-fingerprint p {
  margin: 0 0 0.45rem;
}

.webssh-resizer {
  align-self: stretch;
  background: linear-gradient(90deg, transparent, #d0d0d0, transparent);
  border: 0;
  border-radius: 999px;
  cursor: col-resize;
  min-height: 12rem;
  opacity: 1;
  padding: 0;
  transition: opacity 0.14s ease, background 0.15s ease;
  width: 8px;
}

.webssh-resizer:hover,
.webssh-resizer:focus {
  background: #111;
  outline: 0;
}

.webssh-connect input[type="checkbox"] {
  width: auto;
}

.webssh-connect p:has(button) {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.webssh-terminal-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.webssh-tabbar {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 0.35rem;
  overflow-x: auto;
  padding-bottom: 0.1rem;
}

.webssh-tabbar button,
.webssh-session-carousel button {
  background: #f7f7f7;
  border: 1px solid #bbb;
  border-radius: 999px;
  cursor: pointer;
  min-height: 2rem;
  overflow: hidden;
  padding: 0.25rem 0.75rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.webssh-tabbar button.is-active,
.webssh-session-carousel button.is-active {
  background: #111;
  border-color: #111;
  color: #fff;
}

.webssh-keybar {
  background: #f5f5f5;
  border: 1px solid #d7d7d7;
  border-bottom: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  padding: 0.35rem;
}

.webssh-keybar button {
  background: #fff;
  border: 1px solid #999;
  border-radius: 7px;
  cursor: pointer;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.8rem;
  min-height: 1.9rem;
  min-width: 2.25rem;
  padding: 0.2rem 0.45rem;
}

.webssh-keybar button.is-active {
  background: #111;
  border-color: #111;
  color: #fff;
}

.webssh-keybar .webssh-copy-button {
  font-family: inherit;
  margin-left: auto;
  min-width: 4rem;
}

.webssh-keybar .webssh-copy-selected-button {
  font-family: inherit;
  min-width: 7rem;
}

.webssh-terminal {
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  box-sizing: border-box;
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  position: relative;
}

.webssh-terminal .xterm {
  height: 100%;
  width: 100%;
}

.webssh-terminal-screen {
  height: 100%;
  inset: 0;
  position: absolute;
  width: 100%;
}

.webssh-terminal-screen[hidden] {
  display: none;
}

.webssh-files {
  margin-top: 1.5rem;
}

.webssh-file-session {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.25rem 0 0.65rem;
}

.webssh-file-session > span {
  color: #555;
  font-size: 0.9rem;
}

.webssh-session-carousel {
  display: flex;
  gap: 0.25rem;
  max-width: 100%;
  overflow-x: auto;
  padding-bottom: 0.1rem;
}

.webssh-loading {
  color: #444;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  margin: 0.25rem 0;
}

.webssh-loading::before {
  animation: webssh-spin 0.8s linear infinite;
  border: 2px solid #bbb;
  border-top-color: #111;
  border-radius: 50%;
  content: "";
  display: inline-block;
  height: 0.85rem;
  margin-right: 0.45rem;
  vertical-align: -0.12rem;
  width: 0.85rem;
}

.webssh-filegrid {
  position: relative;
}

.webssh-filegrid.is-loading::after {
  align-items: center;
  background: rgba(255, 255, 255, 0.72);
  bottom: 0;
  content: "Loading...";
  display: flex;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  justify-content: center;
  left: 0;
  position: absolute;
  right: 0;
  top: 0;
}

@keyframes webssh-spin {
  to {
    transform: rotate(360deg);
  }
}

.webssh-filebar {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.5rem 0 0.75rem;
}

.webssh-filebar input[type="text"] {
  flex: 1 1 260px;
}

.webssh-filebar button,
.webssh-upload {
  align-items: center;
  background: #f7f7f7;
  border: 1px solid #999;
  border-radius: 7px;
  box-sizing: border-box;
  color: #111;
  cursor: pointer;
  display: inline-flex;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.85rem;
  justify-content: center;
  min-height: 2.15rem;
  padding: 0.25rem 0.65rem;
}

.webssh-filebar button:hover,
.webssh-filebar button:focus,
.webssh-upload:hover,
.webssh-upload:focus-within {
  background: #fff;
  border-color: #555;
}

.webssh-upload:has(input:disabled) {
  cursor: not-allowed;
  opacity: 0.55;
}

.webssh-upload input {
  display: none;
}

.webssh-filegrid {
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
}

.webssh-editor textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85rem;
}

.file-link {
  background: transparent;
  border: 0;
  color: #181818;
  cursor: pointer;
  padding: 0;
  text-align: left;
}

.file-dir {
  font-weight: 700;
}

.editor-toolbar {
  background: #f3f3f3;
  border-color: #999;
  opacity: 1;
}

.editor-toolbar button {
  background: #fff;
  border: 1px solid #aaa;
  color: #111;
  font-size: 0;
  min-width: 2.1rem;
  margin: 0 2px 2px 0;
  padding: 0 0.45rem;
  vertical-align: top;
}

.editor-toolbar button::after {
  content: none !important;
}

.editor-toolbar button::before {
  color: #111;
  display: inline-block;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.78rem;
  font-style: normal;
  font-weight: 700;
  line-height: 1;
}

.editor-toolbar button.bold::before {
  content: "B";
}

.editor-toolbar button.italic::before {
  content: "I";
  font-style: italic;
}

.editor-toolbar button.heading::before {
  content: "H";
}

.editor-toolbar button.unordered-list::before {
  content: "UL";
}

.editor-toolbar button.ordered-list::before {
  content: "OL";
}

.editor-toolbar button.quote::before {
  content: "Q";
}

.editor-toolbar button.code::before {
  content: "{}";
}

.editor-toolbar button.link::before {
  content: "Link";
}

.editor-toolbar button.preview::before {
  content: "View";
}

.editor-toolbar button.side-by-side::before {
  content: "Split";
}

.editor-toolbar button.fullscreen::before {
  content: "Full";
}

.editor-toolbar button:hover,
.editor-toolbar button.active {
  background: #e8e8e8;
  border-color: #555;
  color: #000;
}

.editor-toolbar i.separator {
  border-left-color: #999;
  border-right-color: #fff;
}

.editor-toolbar.fullscreen {
  background: #f3f3f3;
}

.EasyMDEContainer .CodeMirror {
  border-color: #999;
}

pre,
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

code {
  background: #f1f1f1;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 0.88em;
  padding: 0.08rem 0.28rem;
}

pre {
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  color: #f2f2f2;
  font-size: 0.9rem;
  line-height: 1.55;
  margin: 1.25rem 0;
  overflow-x: auto;
  padding: 1rem;
  tab-size: 2;
  user-select: text;
  white-space: pre;
}

.code-window {
  margin: 1.25rem 0;
  position: relative;
}

.code-window pre {
  margin: 0;
  padding-right: 4.25rem;
}

.code-copy {
  background: #262626;
  border: 1px solid #555;
  border-radius: 5px;
  color: #f5f5f5;
  cursor: pointer;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.72rem;
  line-height: 1;
  padding: 0.32rem 0.45rem;
  position: absolute;
  right: 0.55rem;
  top: 0.55rem;
}

.code-copy:hover,
.code-copy:focus {
  background: #3a3a3a;
  border-color: #777;
}

pre code {
  background: transparent;
  border: 0;
  border-radius: 0;
  color: inherit;
  display: block;
  font-size: inherit;
  padding: 0;
}

.code-lines {
  counter-reset: code-line;
}

.code-line {
  counter-increment: code-line;
  display: block;
  min-height: 1.55em;
  padding-left: 3.2rem;
  position: relative;
}

.code-line::before {
  color: #858585;
  content: counter(code-line);
  font-variant-numeric: tabular-nums;
  left: 0;
  position: absolute;
  text-align: right;
  user-select: none;
  width: 2.1rem;
}

@media (max-width: 760px) {
  html {
    font-size: 16px;
  }

  body {
    margin: 1rem auto;
    padding: 0 0.75rem;
  }

  body:has(.webssh-shell) {
    max-width: 100%;
  }

  h1 {
    font-size: 2.15rem;
  }

  .profile-photo {
    float: none;
    margin: 0 0 1rem;
    max-width: 180px;
    width: 55%;
  }

  .post-list-item {
    display: block;
  }

  .post-cover {
    display: block;
    margin-bottom: 0.5rem;
  }

  .post-cover img {
    max-width: 100%;
  }

  .webssh-home,
  .webssh-filegrid {
    grid-template-columns: 1fr;
  }

  .webssh-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .webssh-preview-grid {
    grid-template-columns: 1fr;
  }

  .webssh-preview-files {
    border-left: 0;
    border-top: 1px solid #333;
  }

  .webssh-shell.is-sidebar-collapsed {
    grid-template-columns: minmax(0, 1fr);
  }

  .webssh-shell {
    gap: 0.75rem;
  }

  .webssh-connect {
    padding: 0.8rem;
  }

  .webssh-resizer,
  .webssh-sidebar-toggle {
    display: none;
  }

  .webssh-connect p:has(button) {
    display: grid;
    grid-template-columns: 1fr;
  }

  .webssh-connect p:has(button) button {
    width: 100%;
  }

  .webssh-tabbar,
  .webssh-session-carousel {
    scrollbar-width: thin;
  }

  .webssh-tabbar button,
  .webssh-session-carousel button {
    flex: 0 0 auto;
    max-width: 11rem;
  }

  .webssh-keybar {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: thin;
  }

  .webssh-keybar button {
    flex: 0 0 auto;
  }

  .webssh-keybar .webssh-copy-button {
    margin-left: 0;
  }

  .webssh-terminal {
    height: min(68vh, 460px);
    min-height: 330px;
  }

  .webssh-file-session {
    align-items: stretch;
    display: grid;
  }

  .webssh-filebar {
    align-items: stretch;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .webssh-filebar input[type="text"] {
    grid-column: 1 / -1;
    min-width: 0;
    width: 100%;
  }

  .webssh-filebar button,
  .webssh-upload {
    box-sizing: border-box;
    justify-content: center;
    text-align: center;
    width: 100%;
  }

  .webssh-filegrid {
    gap: 0.75rem;
  }

  .webssh-filegrid > table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    white-space: nowrap;
  }

  .webssh-editor textarea {
    min-height: 18rem;
    width: 100%;
  }
}

@media (max-width: 420px) {
  .webssh-filebar {
    grid-template-columns: 1fr;
  }
}
