
/* shader-env-light.css - Light-themed shader environment CSS */

/* ───────── Global Reset & Base Styles ───────── */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ───────── Container for Each Shader Editor ───────── */
.shader-container {
  display: flex;
  flex-direction: column;
  background: #ececec; /* light gray matching wos-weekend's light tone */
  border-radius: 8px;
  padding: 10px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  margin-top: 30px;
  margin-bottom: 30px;
}
.shader-title {
  color: #333; /* darker text */
  font-size: 14px;
  font-weight: 500;
  padding: 4px 8px;
  margin-bottom: 8px;
}
.shader-content {
  display: flex;
  gap: 10px;
}

/* ───────── Editor Panel ───────── */
.editor-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.controls {
  display: flex;
  gap: 8px;
  padding: 8px;
  background: #ddd; /* lighter controls background */
  border-radius: 4px;
  margin-bottom: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.controls button {
  padding: 6px 12px;
  background: #f0f0f0; /* light button */
  color: #333;
  border: 1px solid #ccc;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
  transition: background 0.2s, border-color 0.2s;
  display: flex;
  align-items: center;
  gap: 4px;
}
.controls button.flash {
  background: #e0e0e0 !important;
}
.controls button:hover {
  background: #e8e8e8;
  border-color: #bbb;
}
.controls button:active {
  background: #d8d8d8;
}
.controls button.active {
  background: #1b1f8a; /* wos-weekend link color */
  color: #fff;
  border-color: #1b1f8a;
}
.time-display {
  color: #666;
  font-size: 12px;
  font-family: monospace;
  margin-left: auto;
}

/* ───────── Editor Wrapper & CodeMirror ───────── */
.editor-wrapper {
  aspect-ratio: 4 / 3; /* 1.333 ratio */
  border: 1px solid #ccc;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
}
.CodeMirror {
  height: 100% !important;
  font-size: 12px;
  background: #fafafa; /* light editor background */
  color: #333; /* default text color */
}

/* CodeMirror Syntax Highlighting Overrides */
.cm-s-default .cm-comment {
  color: #555; /* darker gray for comments */
  font-style: italic;
}
.cm-s-default .cm-keyword {
  color: #1b1f8a; /* wos-weekend blue for keywords */
  font-weight: bold;
}
.cm-s-default .cm-atom,
.cm-s-default .cm-number {
  color: #005b96; /* deep blue for numbers */
}
.cm-s-default .cm-def {
  color: #333; /* definitions/identifiers */
}
.cm-s-default .cm-variable {
  color: #333;
}
.cm-s-default .cm-variable-2 {
  color: #1b1f8a; /* secondary variables in same blue */
}
.cm-s-default .cm-variable-3,
.cm-s-default .cm-builtin {
  color: #563d7c; /* violet shade */
}
.cm-s-default .cm-string {
  color: #a932f1; /* violet for strings */
}
.cm-s-default .cm-meta {
  color: #777; /* meta tags */
}
.cm-s-default .cm-operator {
  color: #333;
}
.cm-s-default .cm-comment {
  background: transparent;
}
.cm-s-default .cm-tag {
  color: #333;
}
.cm-s-default .cm-attribute {
  color: #005b96;
}
.cm-s-default .CodeMirror-cursor {
  border-left: 1px solid #000;
}
.cm-s-default .CodeMirror-gutters {
  background: #f0f0f0;
  border-right: 1px solid #ccc;
}
.cm-s-default .CodeMirror-linenumber {
  color: #666;
}

/* Mode Indicator */
.mode-indicator {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(255, 255, 255, 0.8);
  color: #666;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-family: monospace;
  z-index: 10;
}

/* ───────── Canvas Panel ───────── */
.canvas-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.controls .res-display {
  color: #333;
  font-family: monospace;
}
.canvas-wrapper {
  aspect-ratio: 4 / 3;
  width: 100%;
  background: #e0e0e0; /* light gray */
  position: relative;
}
.canvas-wrapper canvas {
  width: 100%;
  height: 100%;
  display: block;
}
.error-message {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(220, 20, 60, 0.9);
  color: white;
  padding: 8px;
  font-family: monospace;
  font-size: 12px;
  max-height: 100px;
  overflow-y: auto;
  display: none;
}

/* ───────── Responsive Layout ───────── */
@media (max-width: 768px) {
  .shader-content {
    flex-direction: column;
  }
}

/* Make Prism styling match CodeMirror */

code[class*="language-"] {
  font-family: monospace;
  font-size: 13px;
}

/* Prism code block */
pre[class*="language-"] {
  margin: 10px 0;
  margin-left: 20px;
  margin-right: 20px;
  padding: 10px;
  background: #eee;
  border-radius: 5px;
}

.line-highlight::before,
.line-highlight::after
{
  display: none !important;
}

