:root {
  color-scheme: dark;
  font-family: Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #101416;
  color: #f3f7f4;
}

.page {
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.5rem 0 2rem;
  display: grid;
  gap: 1.5rem;
}

.stream-panel,
.chat-panel {
  background: #182025;
  border: 1px solid #2f3a42;
  border-radius: 14px;
  padding: 1rem;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

.subtitle,
.chat-header p,
.status {
  color: #aebcc2;
}

.streams,
.news-list {
  display: grid;
  gap: 1rem;
}

.tank-stream,
.content-section {
  margin-top: 1.5rem;
}

.tank-header {
  margin-bottom: 0.65rem;
}

.tank-header h2,
.content-section h2 {
  margin-bottom: 0.35rem;
}

.stream-frame {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  background: #0a0d0f;
}

.stream {
  position: relative;
  z-index: 1;
  width: 100%;
  display: block;
  background: #0a0d0f;
}

.stream-placeholder {
  position: absolute;
  inset: 0;
  z-index: 0;
  min-height: 180px;
  display: grid;
  place-content: center;
  gap: 0.35rem;
  padding: 1rem;
  text-align: center;
  color: #dce6e2;
  background: #0a0d0f;
  opacity: 0;
  pointer-events: none;
}

.stream-placeholder span {
  color: #aebcc2;
}

.stream[src=""],
.stream:not([src]),
.stream.is-offline {
  min-height: 180px;
  opacity: 0;
  z-index: 0;
}

.stream[src=""] + .stream-placeholder,
.stream:not([src]) + .stream-placeholder,
.stream.is-offline + .stream-placeholder {
  z-index: 1;
  opacity: 1;
}

.content-section {
  border-top: 1px solid #2f3a42;
  padding-top: 1.5rem;
}

.content-section p:last-child,
.content-section ul:last-child,
.news-entry p:last-child {
  margin-bottom: 0;
}

.content-section ul,
.news-entry ul {
  padding-left: 1.25rem;
}

.news-entry {
  padding: 1rem;
  border: 1px solid #2f3a42;
  border-radius: 8px;
  background: #11191d;
}

.news-entry time {
  display: block;
  margin-bottom: 0.35rem;
  color: #c9d60d;
  font-size: 0.9rem;
  font-weight: 700;
}

.news-entry h3 {
  margin-bottom: 0.5rem;
}

.news-image {
  display: block;
  width: min(100%, 560px);
  height: auto;
  margin: 0.75rem 0 0;
  border-radius: 8px;
}

.chat-form {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.chat-form label {
  display: grid;
  gap: 0.35rem;
}

.chat-form input,
.chat-form button {
  border-radius: 8px;
  border: 1px solid #40505a;
  padding: 0.75rem;
  font: inherit;
}

.chat-form input {
  background: #0f1519;
  color: #f3f7f4;
}

.chat-form button {
  background: #c9d60d;
  color: #2a2c2b;
  font-weight: 700;
  cursor: pointer;
}

.messages {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.messages li {
  font-size: 15px;
  padding: 0.75rem;
  border-radius: 8px;
  background: #11191d;
  border: 1px solid #253038;
  overflow-wrap: anywhere;
}

.small {
  font-size: 3em;
}

@media (min-width: 900px) {
  .page {
    grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
    align-items: start;
  }

  .chat-panel {
    position: sticky;
    top: 1rem;
  }
}
