:root {
  --bg-0: #FFFFFF;
  --bg-1: #F7F7F9;
  --bg-2: #EEEEF2;
  --bg-3: #E2E2E8;
  --bg-input: #FFFFFF;
  --border: #D0D0DA;
  --border-focus: #FF2D8A;
  --text-0: #0D1B3E;
  --text-1: #2A3558;
  --text-2: #8088A0;
  --accent: #FF2D8A;
  --accent-light: rgba(255,45,138,0.10);
  --accent2: #00FF88;
  --accent2-light: rgba(0,255,136,0.10);
  --purple: #6B21A8;
  --purple-light: rgba(107,33,168,0.10);
  --darkblue: #0D1B3E;
  --radius: 6px;
  --font: 'Instrument Sans', system-ui, sans-serif;
  --mono: 'IBM Plex Mono', monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }

body {
  font-family: var(--font);
  background: linear-gradient(168deg, #FFFFFF 0%, #F9F8FC 35%, #F4F2F8 70%, #F0EEF5 100%);
  color: var(--text-0);
  min-height: 100vh;
  line-height: 1.5;
  position: relative;
}

/* Paper texture overlay via SVG feTurbulence noise */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  filter: url(#paperNoise);
  opacity: 0.38;
  mix-blend-mode: multiply;
  background: rgba(235,230,225,0.5);
}

/* Ensure all content sits above the paper texture */
body > * {
  position: relative;
  z-index: 1;
}

/* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 7px; height: 7px; }
::-webkit-scrollbar-track { background: var(--bg-1); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-2); }

/* ── HEADER ── */
.forge-header {
  background: #075F3B;
  border-bottom: 2px solid var(--accent);
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 16px rgba(13,27,62,0.25);
}
.forge-header-left { display: flex; align-items: center; gap: 16px; }
.forge-logo {
  font-family: var(--mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: #FFFFFF;
  letter-spacing: -0.03em;
}
.forge-logo em { font-style: normal; color: #FF2D8A; }
.forge-subtitle {
  font-size: 0.7rem;
  color: #00FF88;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
  opacity: 0.85;
  margin-top: -2px;
}
.btn-reset {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font);
  font-size: 0.78rem;
  font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0.05) 100%);
  color: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.2);
  padding: 5px 14px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 200ms ease;
  position: relative; overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15);
}
.btn-reset::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.1) 0%, transparent 100%);
  pointer-events: none;
}
.btn-reset:hover { color: #FF2D8A; border-color: #FF2D8A; box-shadow: 0 0 10px rgba(255,45,138,0.2), inset 0 1px 0 rgba(255,255,255,0.15); }
.btn-reset:active { box-shadow: 0 0 16px rgba(255,45,138,0.4), 0 0 30px rgba(255,45,138,0.15); transform: scale(0.96); }

.forge-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lang-toggle,
.btn-reset,
.lang-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: linear-gradient(180deg, rgba(255,255,255,0.12) 0%, rgba(255,255,255,0.05) 100%);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius);
  padding: 5px 12px;
  cursor: pointer;
  transition: all 200ms ease;
  position: relative;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.12);
  min-width: 72px;
  flex-shrink: 0;
  white-space: nowrap;
}
.lang-toggle::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.08) 0%, transparent 100%);
  pointer-events: none;
}
.lang-toggle:hover { border-color: #00FF88; box-shadow: 0 0 10px rgba(0,255,136,0.2), inset 0 1px 0 rgba(255,255,255,0.12); }
.lang-toggle:active { box-shadow: 0 0 16px rgba(0,255,136,0.35); transform: scale(0.96); }
.lang-opt {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.06em;
  transition: all 150ms;
}
.lang-opt.lang-active {
  color: #00FF88;
}
.lang-sep {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.2);
}

/* ── MODEL TABS ── */
.model-tabs {
  display: flex;
  gap: 2px;
  padding: 12px 20px 0;
  background: var(--bg-1);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 50; /* lift above forge-main so the Claude submenu can overlay content */
}
.model-tab {
  font-family: var(--font);
  background: linear-gradient(180deg, rgba(240,240,245,0.9) 0%, rgba(226,226,232,0.8) 100%);
  border: 1px solid var(--border);
  border-bottom: none;
  box-sizing: border-box;
  padding: 7px 14px;
  border-radius: var(--radius) var(--radius) 0 0;
  cursor: pointer;
  transition: all 200ms ease;
  position: relative;
  overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  height: 44px;
  flex: 1;
  text-align: center;
}
.model-tabs > .model-tab,
.model-tab-group {
  flex: 1 1 0;
  width: 0;
}
.model-tabs > .model-tab { padding-left: 0; padding-right: 0; }
.model-tab::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.5) 0%, transparent 100%);
  pointer-events: none;
}
.model-tab:hover { background: linear-gradient(180deg, rgba(248,248,252,0.95) 0%, rgba(238,238,245,0.85) 100%); }
.model-tab:active { box-shadow: 0 0 12px rgba(107,33,168,0.2), inset 0 1px 2px rgba(0,0,0,0.06); transform: scale(0.97); }
.model-tab.tab-active {
  background: linear-gradient(180deg, #FFFFFF 0%, var(--bg-0) 100%);
  border-color: var(--border);
  border-bottom-color: var(--bg-0);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.9);
}
.model-tab.tab-active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent);
}
.model-logo {
  display: block;
  max-width: 72px;
  max-height: 27px;
  object-fit: contain;
  flex-shrink: 0;
}
.model-logo-belgpt {
  max-height: 30px;
  border-radius: 50%;
  clip-path: circle(49% at 50% 50%);
}
/* Claude family tabs: model name overlaid on the bottom half of the icon */
.model-logo-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.model-tab-name {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  height: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  font-family: 'Styrene A Web', 'Styrene A', 'Styrene B', 'Styrene', var(--font);
  font-size: 0.56rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text-0);
  text-shadow: 0 0 3px rgba(255,255,255,0.95), 0 0 6px rgba(255,255,255,0.85);
  pointer-events: none;
}
.model-tab-name-standalone {
  position: static;
  transform: none;
  height: auto;
}
/* Claude model group: one tab that opens a submenu of the three Claude models */
.model-tab-group {
  position: relative;
  box-sizing: border-box;
  min-width: 0;
  display: flex;
}
.model-tab-group > .model-tab {
  flex: 1 1 0;
  width: calc(100% + 2px);
  margin-left: -1px;
  margin-right: -1px;
}
.claude-submenu {
  position: fixed; /* JS positions it under the Claude tab; fixed escapes the tab bar's overflow clip */
  transform: translateX(-50%);
  z-index: 400;
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 150px;
  padding: 6px;
  background: var(--bg-0);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(13,27,62,0.22);
}
.claude-submenu[hidden] { display: none; }
.model-subtab {
  font-family: var(--font);
  background: var(--bg-1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  cursor: pointer;
  height: 44px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  transition: background 150ms ease, border-color 150ms ease, box-shadow 150ms ease;
}
.model-subtab:hover { background: var(--bg-2); }
.model-subtab.subtab-active {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}
.tab-dot { display: none; }
.model-tooltip {
  position: fixed;
  z-index: 1000;
  padding: 6px 10px;
  border-radius: var(--radius);
  background: rgba(17, 24, 39, 0.92);
  color: #fff;
  font-size: 0.74rem;
  font-weight: 600;
  line-height: 1;
  box-shadow: 0 6px 18px rgba(0,0,0,0.22);
  opacity: 0;
  transform: translate(-50%, -4px);
  pointer-events: none;
  transition: opacity 120ms ease, transform 120ms ease;
}
.model-tooltip.tooltip-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ── LAYOUT ── */
.forge-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  max-width: 1600px;
  margin: 0 auto;
  min-height: calc(100vh - 94px);
}
.panel-controls {
  padding: 20px;
  overflow-y: auto;
  max-height: calc(100vh - 94px);
  border-right: 1px solid var(--border);
}
.panel-output {
  padding: 20px;
  position: sticky;
  top: 94px;
  max-height: calc(100vh - 94px);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

/* ── LABELS ── */
.step-label {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--purple);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 4px;
  opacity: 0.85;
}
.section-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-0);
  margin-bottom: 12px;
}

/* ── TASK TYPE GRID ── */
.task-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 20px;
}
.task-btn {
  font-family: var(--font);
  font-size: 0.82rem;
  font-weight: 600;
  background: linear-gradient(180deg, rgba(255,255,255,0.95) 0%, rgba(240,240,245,0.85) 100%);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--text-1);
  border: 1px solid rgba(255,255,255,0.7);
  border-radius: var(--radius);
  padding: 10px 8px 12px;
  cursor: pointer;
  transition: all 200ms ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06), inset 0 1px 0 rgba(255,255,255,0.9);
  position: relative;
  overflow: hidden;
  height: 126px;
}
.task-btn::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 45%;
  background: linear-gradient(180deg, rgba(255,255,255,0.6) 0%, rgba(255,255,255,0) 100%);
  border-radius: var(--radius) var(--radius) 0 0;
  pointer-events: none;
  z-index: 1;
}
.task-btn:hover {
  color: var(--text-0);
  border-color: #FF2D8A;
  background: linear-gradient(180deg, rgba(255,230,240,0.95) 0%, rgba(245,235,242,0.85) 100%);
  box-shadow: 0 3px 10px rgba(255,45,138,0.14), inset 0 1px 0 rgba(255,255,255,0.9);
}
.task-btn:active {
  box-shadow: 0 0 16px rgba(255,45,138,0.4), 0 0 30px rgba(255,45,138,0.15), inset 0 1px 2px rgba(0,0,0,0.08);
  transform: scale(0.97);
}
.task-btn.task-active {
  background: linear-gradient(180deg, rgba(255,220,235,0.95) 0%, rgba(255,200,225,0.80) 100%);
  border-color: #FF2D8A;
  color: var(--text-0);
  box-shadow: 0 0 12px rgba(255,45,138,0.25), 0 2px 8px rgba(255,45,138,0.15), inset 0 1px 0 rgba(255,255,255,0.7);
}
.task-btn.task-active:active {
  box-shadow: 0 0 20px rgba(255,45,138,0.5), 0 0 40px rgba(255,45,138,0.2), inset 0 1px 2px rgba(0,0,0,0.08);
}
.task-btn-image {
  display: block;
  width: 87px;
  height: 87px;
  object-fit: contain;
  pointer-events: none;
  position: relative;
  z-index: 2;
}
.task-btn[data-type="create"] .task-btn-image {
  width: 78px;
  height: 78px;
}
.task-label {
  position: relative;
  z-index: 2;
  line-height: 1.1;
  pointer-events: none;
}

/* ── FORM ELEMENTS ── */
select, input[type="text"], input[type="number"], textarea {
  font-family: var(--font);
  font-size: 0.84rem;
  background: var(--bg-input);
  color: var(--text-0);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 12px;
  width: 100%;
  outline: none;
  transition: border-color 150ms;
}
select:focus, input:focus, textarea:focus {
  border-color: #FF2D8A;
  box-shadow: 0 0 0 2px rgba(255,45,138,0.10);
}
textarea {
  font-family: var(--mono);
  font-size: 0.8rem;
  resize: vertical;
  min-height: 80px;
  line-height: 1.6;
}
textarea.raw-prompt { min-height: 110px; }
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%238A857D' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  padding-right: 30px;
  cursor: pointer;
}
input[type="number"] { width: 100px; }
.field { margin-bottom: 14px; }
.field-label {
  display: block;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-2);
  margin-bottom: 5px;
}

/* ── ACCORDION ── */
.acc-wrap {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
  overflow: hidden;
  background: var(--bg-1);
}
.acc-wrap[data-hidden="true"] { display: none; }
.acc-header {
  font-family: var(--font);
  font-size: 0.84rem;
  font-weight: 600;
  background: var(--bg-1);
  color: var(--text-1);
  border: none;
  padding: 10px 14px;
  width: 100%;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 150ms;
}
.acc-header:hover { background: var(--bg-2); color: var(--text-0); }
.acc-header.acc-open { background: var(--bg-2); border-bottom: 1px solid var(--border); }
.acc-header.acc-impact,
.acc-header.acc-impact:hover { color: var(--purple); }
.acc-right { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.chevron { font-size: 0.7rem; color: var(--text-2); transition: transform 250ms; }
.chevron-up { transform: rotate(180deg); }
.acc-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 300ms ease, padding 300ms ease;
  padding: 0 14px;
}
.acc-body.acc-body-open { max-height: 1400px; padding: 12px 14px 14px; }
.help-dot {
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--purple); color: #FFFFFF;
  font-size: 0.6rem; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0; transition: transform 150ms;
  user-select: none;
}
.help-dot:hover { transform: scale(1.15); background: #FF2D8A; }
.help-dot:active { box-shadow: 0 0 12px rgba(255,45,138,0.5); transform: scale(1.05); }
.tip-bubble {
  max-height: 0; overflow: hidden;
  transition: max-height 280ms ease, padding 280ms ease;
  padding: 0 14px;
  background: linear-gradient(135deg, #0D1B3E 0%, #1A1040 100%); color: #E2E2E8;
  font-size: 0.76rem; line-height: 1.6;
  border-top: 2px solid #FF2D8A;
}
.tip-bubble.tip-visible { max-height: 300px; padding: 10px 14px; }

/* ── SEGMENTED ── */
.seg-group { display: flex; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.seg-btn {
  flex: 1; font-family: var(--font); font-size: 0.76rem; font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.9) 0%, rgba(238,238,242,0.8) 100%);
  color: var(--text-2); border: none;
  border-right: 1px solid var(--border); padding: 8px 6px;
  cursor: pointer; transition: all 200ms ease; text-align: center;
  position: relative; overflow: hidden;
}
.seg-btn::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.5) 0%, transparent 100%);
  pointer-events: none;
}
.seg-btn:last-child { border-right: none; }
.seg-btn:hover { background: linear-gradient(180deg, rgba(245,245,250,0.95) 0%, rgba(230,230,238,0.85) 100%); }
.seg-btn:active {
  box-shadow: 0 0 12px rgba(255,45,138,0.3), inset 0 1px 2px rgba(0,0,0,0.06);
  transform: scale(0.96);
}
.seg-btn.seg-active {
  background: linear-gradient(180deg, #FF5AA5 0%, #FF2D8A 100%);
  color: #fff; font-weight: 600;
  box-shadow: 0 0 10px rgba(255,45,138,0.3), inset 0 1px 0 rgba(255,255,255,0.3);
}
.seg-btn.seg-active:active {
  box-shadow: 0 0 20px rgba(255,45,138,0.5), 0 0 35px rgba(255,45,138,0.2), inset 0 1px 2px rgba(0,0,0,0.1);
}

/* ── TOGGLE ── */
.toggle-row { display: flex; align-items: center; justify-content: space-between; padding: 6px 0; }
.toggle-label { font-size: 0.82rem; color: var(--text-1); }
.toggle-track {
  width: 40px; height: 22px; border-radius: 11px;
  background: var(--bg-3); border: 1px solid var(--border);
  cursor: pointer; position: relative; transition: all 150ms; flex-shrink: 0;
}
.toggle-track.toggle-on { background: #FF2D8A; border-color: #FF2D8A; }
.toggle-thumb {
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--text-2); position: absolute; top: 2px; left: 2px;
  transition: all 150ms;
}
.toggle-track.toggle-on .toggle-thumb { transform: translateX(18px); background: #fff; }

/* ── CHECKBOX ── */
.cb-group { display: flex; flex-direction: column; gap: 6px; }
.cb-item { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 0.82rem; color: var(--text-1); }
.cb-item input[type="checkbox"] {
  -webkit-appearance: none; appearance: none;
  width: 16px; height: 16px; border: 1px solid var(--border);
  border-radius: 3px; background: var(--bg-input); cursor: pointer;
  flex-shrink: 0; transition: all 150ms; position: relative;
}
.cb-item input[type="checkbox"]:checked { background: var(--purple); border-color: var(--purple); }
.cb-item input[type="checkbox"]:checked::after {
  content: ''; position: absolute; left: 4.5px; top: 1px;
  width: 5px; height: 9px; border: solid #fff;
  border-width: 0 2px 2px 0; transform: rotate(45deg);
}

/* ── RADIO ── */
.radio-group { display: flex; flex-direction: column; gap: 6px; }
.radio-item { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; color: var(--text-1); cursor: pointer; }
.radio-item input[type="radio"] {
  -webkit-appearance: none; appearance: none;
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid var(--border); background: var(--bg-input);
  cursor: pointer; flex-shrink: 0; position: relative; transition: all 150ms;
}
.radio-item input[type="radio"]:checked { border-color: var(--purple); }
.radio-item input[type="radio"]:checked::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--purple);
}

/* ── SLIDER ── */
.slider-wrap { display: flex; align-items: center; gap: 10px; }
.slider-edge { font-size: 0.7rem; color: var(--text-2); width: 70px; flex-shrink: 0; }
.slider-edge-r { text-align: right; }
input[type="range"] {
  -webkit-appearance: none; appearance: none; flex: 1;
  height: 4px; background: var(--bg-3); border-radius: 2px;
  outline: none; cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px;
  border-radius: 50%; background: #FF2D8A;
  border: 2px solid #FFFFFF; cursor: pointer;
  box-shadow: 0 0 6px rgba(255,45,138,0.4);
}
input[type="range"]::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%;
  background: #FF2D8A; border: 2px solid #FFFFFF; cursor: pointer;
}
.slider-val {
  font-family: var(--mono); font-size: 0.72rem;
  color: var(--purple); text-align: center; margin-top: 4px; font-weight: 600;
}

/* ── OUTPUT PANEL ── */
.output-header {
  display: flex; flex-direction: column;
  margin-bottom: 10px; gap: 10px;
}
.output-stats-head {
  display: flex; flex-direction: column;
  position: relative;
}
.output-stats-labelrow {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.output-stats-title {
  font-size: 0.95rem; font-weight: 600; color: var(--text-0);
}
.output-stats-divider {
  width: 100%;
  height: 2px;
  background: #FF2D8A;
  border-radius: 999px;
}
.output-meta {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.score-wrap { display: flex; align-items: center; gap: 10px; cursor: pointer; border-radius: var(--radius); padding: 2px 4px; }
.score-wrap:hover { background: var(--bg-2); }
.score-ring { position: relative; width: 50px; height: 50px; flex-shrink: 0; }
.score-ring svg { transform: rotate(-90deg); width: 50px; height: 50px; }
.ring-bg { fill: none; stroke: var(--bg-3); stroke-width: 4; }
.ring-fg { fill: none; stroke-width: 4; stroke-linecap: round; transition: stroke-dashoffset 500ms ease, stroke 300ms; }
.score-num {
  position: absolute; inset: 0; display: flex;
  align-items: center; justify-content: center;
  font-family: var(--mono); font-size: 0.78rem; font-weight: 700;
}
.score-side { font-size: 0.7rem; color: var(--text-2); line-height: 1.3; }
.stat-pill {
  font-family: var(--mono); font-size: 0.72rem;
  color: var(--text-2); background: var(--bg-2);
  padding: 3px 8px; border-radius: 4px;
}
.stat-pill.warn { color: #f59e0b; }
.stat-pill.danger { color: #ef4444; }
.btn-copy {
  font-family: var(--font); font-size: 0.82rem; font-weight: 600;
  background: linear-gradient(180deg, #FF5AA5 0%, #FF2D8A 100%);
  color: #fff; border: none;
  padding: 8px 20px; border-radius: var(--radius);
  cursor: pointer; transition: all 200ms ease; white-space: nowrap;
  position: relative; overflow: hidden;
  box-shadow: 0 2px 8px rgba(255,45,138,0.2), inset 0 1px 0 rgba(255,255,255,0.3);
}
.btn-copy::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.25) 0%, transparent 100%);
  border-radius: var(--radius) var(--radius) 0 0;
  pointer-events: none;
}
.btn-copy:hover {
  background: linear-gradient(180deg, #FF6AB0 0%, #FF3D95 100%);
  box-shadow: 0 4px 14px rgba(255,45,138,0.3), inset 0 1px 0 rgba(255,255,255,0.3);
}
.btn-copy:active {
  box-shadow: 0 0 20px rgba(255,45,138,0.5), 0 0 40px rgba(255,45,138,0.2), inset 0 1px 2px rgba(0,0,0,0.1);
  transform: scale(0.96);
}
.btn-copy.btn-copied { opacity: 0.7; }
.modal-backdrop {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(31,31,43,0.32);
  display: none; align-items: center; justify-content: center;
  padding: 18px;
}
.modal-backdrop.visible { display: flex; }
.app-modal {
  width: min(420px, 100%);
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 18px;
  box-shadow: 0 18px 54px rgba(0,0,0,0.24);
}
.modal-title { font-weight: 700; color: var(--text-0); margin-bottom: 6px; }
.modal-body { color: var(--text-2); font-size: 0.86rem; line-height: 1.45; margin-bottom: 12px; }
#appModalBody { white-space: pre-line; }
.modal-actions { display: flex; gap: 8px; margin-top: 10px; }
.output-box {
  flex: 1; font-family: var(--mono); font-size: 0.78rem; line-height: 1.7;
  background: #FFFFFF; border: 1px solid var(--border);
  border-radius: var(--radius); padding: 16px; overflow-y: auto;
  white-space: pre-wrap; word-wrap: break-word; min-height: 300px;
  color: var(--text-1); border-top: 3px solid #00FF88;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.04), 0 1px 4px rgba(0,0,0,0.06);
}
.output-box .sec-head { color: var(--purple); font-weight: 700; }
.output-box .empty-st { color: var(--text-2); font-style: italic; }
.output-box .sys-divider { color: #FF2D8A; font-weight: 700; letter-spacing: 0.05em; }
.output-footer {
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.app-version,
.powered-by {
  font-size: 0.68rem;
  color: var(--text-2);
  opacity: 0.78;
}
.app-version {
  text-align: left;
  cursor: pointer;
  border-radius: 4px;
}
.app-version:hover { color: #FF2D8A; opacity: 1; }
.app-version:focus-visible {
  outline: 2px solid #FF2D8A;
  outline-offset: 3px;
}
.powered-by { text-align: right; }

.model-note {
  font-size: 0.72rem; color: var(--text-2); background: var(--bg-2);
  border-left: 2px solid var(--purple); padding: 6px 10px; margin-top: 8px;
  border-radius: 0 var(--radius) var(--radius) 0; line-height: 1.5;
}
.divider { border: none; border-top: 1px solid var(--border); margin: 16px 0; }
.conditional { display: none; }
.conditional.visible { display: block; }
.output-title-text {
  display: flex;
  flex-direction: column;
  gap: 1px;
}
.output-model-label { display: block; font-size: 0.72rem; color: var(--text-2); margin-left: 0; font-weight: 500; }
.output-title-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-bottom: 12px; flex-wrap: wrap;
}
.output-title-copy {
  display: flex; align-items: center; gap: 10px;
}

/* ── SAVED CONFIGS ── */
.saved-configs {
  margin-top: 20px;
  border-top: 1px solid var(--border);
  padding-top: 16px;
}
.saved-configs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.saved-configs-title {
  font-family: var(--mono);
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  opacity: 0.85;
}
.save-row {
  display: flex;
  gap: 6px;
  margin-bottom: 12px;
}
.save-row input[type="text"] {
  flex: 1;
  font-size: 0.82rem;
  padding: 7px 10px;
}
.btn-save {
  font-family: var(--font);
  font-size: 0.78rem;
  font-weight: 600;
  background: linear-gradient(180deg, #FF5AA5 0%, #FF2D8A 100%);
  color: #fff;
  border: none;
  padding: 7px 16px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 200ms ease;
  white-space: nowrap;
  flex-shrink: 0;
  position: relative; overflow: hidden;
  box-shadow: 0 2px 6px rgba(255,45,138,0.2), inset 0 1px 0 rgba(255,255,255,0.3);
}
.btn-save::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.25) 0%, transparent 100%);
  pointer-events: none;
}
.btn-save:hover {
  background: linear-gradient(180deg, #FF6AB0 0%, #FF3D95 100%);
  box-shadow: 0 4px 12px rgba(255,45,138,0.3), inset 0 1px 0 rgba(255,255,255,0.3);
}
.btn-save:active {
  box-shadow: 0 0 18px rgba(255,45,138,0.5), 0 0 35px rgba(255,45,138,0.2), inset 0 1px 2px rgba(0,0,0,0.1);
  transform: scale(0.96);
}
.btn-save:hover { background: linear-gradient(180deg, #FF6AB0 0%, #FF3D95 100%); }
.btn-save:disabled { opacity: 0.4; cursor: not-allowed; }
.config-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.config-card {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 10px;
  transition: all 150ms;
}
.config-card:hover { border-color: var(--text-2); }
.config-info {
  flex: 1;
  min-width: 0;
}
.config-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-0);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.config-meta {
  font-size: 0.68rem;
  color: var(--text-2);
  display: flex;
  gap: 8px;
  margin-top: 1px;
}
.config-meta .config-tag {
  background: var(--bg-3);
  padding: 1px 5px;
  border-radius: 3px;
  font-family: var(--mono);
  font-size: 0.64rem;
}
.config-preview {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--text-2);
  margin-top: 4px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: pre-wrap;
}
.config-actions {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}
.btn-config {
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.9) 0%, rgba(238,238,242,0.8) 100%);
  color: var(--text-1);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 200ms ease;
  position: relative; overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
}
.btn-config::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.4) 0%, transparent 100%);
  pointer-events: none;
}
.btn-config:hover { color: var(--text-0); border-color: var(--text-2); }
.btn-config:active { box-shadow: 0 0 10px rgba(107,33,168,0.25), inset 0 1px 2px rgba(0,0,0,0.06); transform: scale(0.95); }
.btn-config.btn-load:hover { color: #FF2D8A; border-color: #FF2D8A; box-shadow: 0 0 8px rgba(255,45,138,0.2), inset 0 1px 0 rgba(255,255,255,0.7); }
.btn-config.btn-del:hover { color: #ef4444; border-color: #ef4444; box-shadow: 0 0 8px rgba(239,68,68,0.2), inset 0 1px 0 rgba(255,255,255,0.7); }
.btn-config.btn-export:hover { color: #3b82f6; border-color: #3b82f6; box-shadow: 0 0 8px rgba(59,130,246,0.2), inset 0 1px 0 rgba(255,255,255,0.7); }
.btn-config.btn-history:hover { color: #10A37F; border-color: #10A37F; box-shadow: 0 0 8px rgba(16,163,127,0.2), inset 0 1px 0 rgba(255,255,255,0.7); }
.config-empty {
  font-size: 0.78rem;
  color: var(--text-2);
  font-style: italic;
  padding: 8px 0;
}
.import-export-row {
  display: flex;
  gap: 6px;
  margin-top: 10px;
}
.btn-ie {
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 500;
  background: linear-gradient(180deg, rgba(255,255,255,0.9) 0%, rgba(238,238,242,0.8) 100%);
  color: var(--text-2);
  border: 1px solid var(--border);
  padding: 5px 12px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 200ms ease;
  position: relative; overflow: hidden;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.7);
}
.btn-ie::before {
  content: '';
  position: absolute; top: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(180deg, rgba(255,255,255,0.4) 0%, transparent 100%);
  pointer-events: none;
}
.btn-ie:hover { color: #FF2D8A; border-color: #FF2D8A; box-shadow: 0 0 8px rgba(255,45,138,0.2), inset 0 1px 0 rgba(255,255,255,0.7); }
.btn-ie:active { box-shadow: 0 0 14px rgba(255,45,138,0.35), inset 0 1px 2px rgba(0,0,0,0.06); transform: scale(0.96); }
.btn-ie-file { display: none; }

@media (max-width: 900px) {
  .forge-main { grid-template-columns: 1fr; }
  .panel-controls { max-height: none; border-right: none; border-bottom: 1px solid var(--border); }
  .panel-output { position: static; max-height: none; }
  .model-tabs { overflow-x: auto; }
}

/* BEL PROMPT OPTIMIZER THEME */
:root {
  --bel-green: #005640;
  --bel-lime: #91D754;
  --bel-red: #E33E36;
  --bel-cyan: #00A7CC;
  --bel-yellow: #FBDE4A;
  --bg-0: #FFFFFF;
  --bg-1: #F7FAF7;
  --bg-2: #EEF4EF;
  --bg-3: #DDE8DF;
  --bg-input: #FFFFFF;
  --border: #B9CDBF;
  --border-focus: #FBDE4A;
  --text-0: #005640;
  --text-1: #005640;
  --text-2: #64786D;
  --accent: #91D754;
  --accent-light: rgba(145,215,84,0.18);
  --accent2: #005640;
  --accent2-light: rgba(0,86,64,0.12);
  --purple: #005640;
  --purple-light: rgba(0,86,64,0.10);
  --darkblue: #005640;
  --coral: #E33E36;
  --radius: 6px;
}

body {
  background:
    linear-gradient(rgba(255,255,255,0.88), rgba(247,250,247,0.92)),
    repeating-linear-gradient(0deg, rgba(0,86,64,0.025) 0, rgba(0,86,64,0.025) 1px, transparent 1px, transparent 4px);
  color: var(--text-0);
}

body::after {
  opacity: 0.16;
  mix-blend-mode: multiply;
  background: rgba(231,238,231,0.42);
}

::-webkit-scrollbar-track { background: #EEF4EF; }
::-webkit-scrollbar-thumb { background: #A7BCAA; }
::-webkit-scrollbar-thumb:hover { background: #718A79; }

.forge-header {
  min-height: 72px;
  background-color: #005640;
  background-image: url('/images/header-green-texture.png');
  background-repeat: repeat-x;
  background-position: center;
  background-size: auto 100%;
  border-bottom: 3px solid #91D754;
  padding: 9px 24px;
  box-shadow: 0 2px 0 rgba(145,215,84,0.42), 0 5px 14px rgba(0,35,25,0.28);
  position: relative;
  isolation: isolate;
  overflow: hidden;
}
.forge-header::before {
  display: none;
}
.forge-header::after {
  display: none;
}
.forge-header > * { position: relative; z-index: 1; }

.forge-header-left > div { width: 100%; }
.brand-lockup { display: flex; align-items: center; gap: 12px; }
.bel-brand-logo {
  width: 66px;
  height: 66px;
  object-fit: cover;
  border-radius: 50%;
  border: 0;
  box-shadow: none;
  flex-shrink: 0;
}
.forge-logo {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1.42rem;
  line-height: 1.05;
  color: #FFFFFF;
  letter-spacing: 0;
  font-weight: 700;
  text-shadow: none;
}
.forge-subtitle {
  color: #91D754;
  font-family: 'Gotham', 'Montserrat', 'Avenir Next', var(--font);
  font-size: 0.72rem;
  letter-spacing: 0;
  margin-top: 3px;
  text-transform: none;
  font-weight: 600;
  opacity: 1;
}

.lang-toggle,
.btn-reset {
  height: 36px;
  border: 1px solid #91D754;
  background: rgba(0,35,25,0.88);
  box-shadow: 0 0 8px rgba(145,215,84,0.28), inset 0 0 0 1px rgba(255,255,255,0.04);
  border-radius: 6px;
}
.lang-toggle:hover,
.btn-reset:hover {
  color: #00A7CC;
  border-color: #00A7CC;
  box-shadow: 0 0 13px rgba(0,167,204,0.38), inset 0 0 0 1px rgba(255,255,255,0.06);
}
.lang-toggle {
  gap: 0;
  min-width: 90px;
  padding: 0;
  overflow: hidden;
}
.lang-toggle::before { display: none; }
.lang-opt {
  width: 44px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  letter-spacing: 0;
}
.lang-opt.lang-active {
  color: #005640;
  background: #91D754;
  border-radius: 5px 0 0 5px;
  padding: 0;
  box-shadow: 0 0 12px rgba(145,215,84,0.48);
}
.lang-opt#langFR.lang-active { border-radius: 0 5px 5px 0; }
.lang-sep { display: none; }
.btn-reset {
  color: #00A7CC;
  width: 138px;
  min-width: 138px;
  gap: 8px;
  padding: 5px 14px;
  font-weight: 600;
}
.btn-reset::before {
  content: '\21B6';
  position: static;
  width: auto;
  height: auto;
  background: none;
  color: #00A7CC;
  font-size: 1.25rem;
  line-height: 1;
}

.model-tabs {
  gap: 3px;
  padding: 8px 18px 0;
  background:
    radial-gradient(circle at 2px 2px, rgba(0,86,64,0.07) 1px, transparent 1.2px),
    #F4F8F4;
  background-size: 10px 10px;
  border-bottom: 1px solid #AFC8B4;
}
.model-tab {
  height: 52px;
  background: #FFFFFF;
  border-color: #779986;
  border-radius: 6px 6px 0 0;
  box-shadow: inset 0 -3px 0 #91D754;
}
.model-tab-group > .model-tab {
  width: 100%;
  margin-left: 0;
  margin-right: 0;
}
.model-tab:hover {
  background: #F7FBEA;
  border-color: #FBDE4A;
  box-shadow: inset 0 -4px 0 #91D754;
}
.model-tab.tab-active {
  background: #EAF7D8;
  border: 2px solid #005640;
  border-bottom-color: #005640;
  box-shadow: none;
}
.model-tab.tab-active::after {
  height: 6px;
  background: #005640;
  box-shadow: none;
}
.model-logo { max-height: 30px; }
.claude-submenu {
  background: #FFFFFF;
  border-color: #83A98D;
  box-shadow: 4px 5px 0 rgba(0,167,204,0.14), 0 15px 30px rgba(0,86,64,0.18);
}
.model-subtab { background: #F7FAF7; border-color: #B9CDBF; }
.model-subtab:hover { background: #F1F8D7; }
.model-subtab.subtab-active { border-color: #91D754; box-shadow: 0 0 0 2px rgba(145,215,84,0.25); }
.model-tooltip { background: rgba(0,86,64,0.96); color: #FFFFFF; border: 1px solid #91D754; }

.forge-main { max-width: 1600px; }
.panel-controls,
.panel-output {
  background: rgba(255,255,255,0.66);
}
.panel-controls {
  border-right: 1px solid #B9CDBF;
  box-shadow: inset -4px 0 0 rgba(0,167,204,0.035);
}
.panel-output { background: rgba(248,251,248,0.76); }
.step-label {
  color: #005640;
  opacity: 1;
  font-weight: 700;
}
.section-title,
.output-stats-title { color: #005640; font-weight: 700; }
.section-title { letter-spacing: 0; }

.task-btn {
  height: 98px;
  background:
    radial-gradient(circle at 2px 2px, rgba(0,86,64,0.045) 0 0.75px, transparent 0.95px),
    #FFFFFF;
  background-size: 8px 8px;
  color: #005640;
  border: 1px solid #789780;
  border-radius: 6px;
  box-shadow: inset 0 -3px 0 #91D754, 1px 2px 0 rgba(0,86,64,0.09);
  gap: 1px;
  padding: 5px 8px 7px;
}
.task-btn::before {
  background: none;
}
.task-btn:hover {
  color: #005640;
  border-color: #00A7CC;
  background:
    radial-gradient(circle at 2px 2px, rgba(0,167,204,0.075) 0 0.75px, transparent 0.95px),
    #F8FBEF;
  background-size: 8px 8px;
  box-shadow:
    inset 0 -4px 0 #91D754,
    0 0 0 2px rgba(0,167,204,0.16),
    0 0 15px rgba(0,167,204,0.24);
  transform: translateY(-1px);
}
.task-btn.task-active {
  background:
    radial-gradient(circle at 2px 2px, rgba(0,86,64,0.10) 0 0.8px, transparent 1px),
    rgba(145,215,84,0.42);
  background-size: 8px 8px;
  border-color: #91D754;
  color: #005640;
  box-shadow:
    inset 0 -4px 0 #005640,
    0 0 0 2px rgba(145,215,84,0.24),
    0 0 17px rgba(145,215,84,0.48);
}
.task-btn:active {
  box-shadow:
    inset 0 -4px 0 #005640,
    0 0 0 2px rgba(0,167,204,0.22),
    0 0 21px rgba(0,167,204,0.38);
}
.task-btn.task-active:active {
  box-shadow:
    inset 0 -4px 0 #005640,
    0 0 0 2px rgba(145,215,84,0.30),
    0 0 21px rgba(145,215,84,0.58);
}
.task-btn-image {
  width: 80px;
  height: 68px;
  filter: none;
  object-fit: contain;
}
.task-label {
  font-weight: 700;
  line-height: 1;
  color: #005640;
}

select,
input[type="text"],
input[type="number"],
textarea {
  background: rgba(255,255,255,0.94);
  border-color: #AFC6B5;
  color: #123F30;
  box-shadow: inset 2px 2px 0 rgba(12,107,67,0.025);
}
select:focus,
input:focus,
textarea:focus {
  border-color: #FBDE4A;
  box-shadow: 0 0 0 3px rgba(251,222,74,0.22), 2px 2px 0 rgba(227,62,54,0.10);
}
.field-label { color: #526B5E; font-weight: 600; }

.acc-wrap {
  background: #FFFFFF;
  border-color: #B9CDBF;
  box-shadow: 2px 2px 0 rgba(12,107,67,0.05);
}
.acc-header { background: #F7FAF7; color: #214D3D; }
.acc-header:hover { background: #F0F6F1; color: #005640; }
.acc-header.acc-open { background: #F1F8D7; border-bottom-color: #B2C99F; }
.acc-header.acc-impact,
.acc-header.acc-impact:hover { color: #005640; }
#configPanel .acc-header > span:first-child {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}
#configPanel .acc-header > span:first-child::before {
  content: '';
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-radius: 50%;
  background: #60766A;
  border: 1px solid #365346;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.35);
  transition: background 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}
.acc-header.acc-impact > span:first-child {
  color: #111111;
  text-shadow: none;
}
#configPanel .acc-header.acc-impact > span:first-child::before {
  background: #91D754;
  border-color: #C9F59E;
  box-shadow:
    0 0 5px rgba(145,215,84,0.95),
    0 0 11px rgba(145,215,84,0.72),
    inset 0 0 2px rgba(255,255,255,0.85);
}
.help-dot { background: #005640; color: #FBDE4A; }
.help-dot:hover { background: #E33E36; color: #FFFFFF; }
.tip-bubble {
  background: #005640;
  color: #F1F7F2;
  border-top-color: #91D754;
}

.seg-group { border-color: #AFC6B5; }
.seg-btn {
  background: #F6F9F6;
  color: #60766A;
  border-right-color: #B9CDBF;
}
.seg-btn:hover { background: #EFF6D7; }
.seg-btn.seg-active {
  background: #005640;
  color: #FFFFFF;
  box-shadow: inset 0 -3px 0 #91D754;
}
.toggle-track.toggle-on { background: #005640; border-color: #005640; }
.cb-item input[type="checkbox"]:checked { background: #005640; border-color: #005640; }
.radio-item input[type="radio"]:checked { border-color: #FBDE4A; }
.radio-item input[type="radio"]:checked::after { background: #91D754; }
input[type="range"] { background: linear-gradient(90deg, #91D754, #FBDE4A); }
#tempSlider { background: linear-gradient(90deg, #00A7CC 0%, #91D754 100%); }
input[type="range"]::-webkit-slider-thumb {
  background: #005640;
  border-color: #00A7CC;
  box-shadow: 0 0 7px rgba(251,222,74,0.42);
}
input[type="range"]::-moz-range-thumb { background: #005640; border-color: #00A7CC; }
.slider-val { color: #005640; }

.output-stats-divider {
  background: #91D754;
  box-shadow: 0 1px 0 rgba(227,62,54,0.28);
}
.score-wrap:hover { background: #EFF6E7; }
.ring-bg { stroke: #DCE7DE; }
.stat-pill {
  background: #F0F6F1;
  border: 1px solid #BED1C2;
  color: #526B5E;
}
.btn-copy,
.btn-save {
  background: #005640;
  color: #FFFFFF;
  border: 1px solid #002D20;
  box-shadow: 3px 3px 0 #91D754;
}
.btn-copy:hover,
.btn-save:hover {
  background: #FBDE4A;
  color: #005640;
  box-shadow: 3px 3px 0 #00A7CC;
}
.output-box {
  background:
    linear-gradient(rgba(255,255,255,0.96), rgba(255,255,255,0.96)),
    repeating-linear-gradient(0deg, rgba(0,86,64,0.04) 0, rgba(0,86,64,0.04) 1px, transparent 1px, transparent 24px);
  border-color: #9FBEA6;
  border-top-color: #91D754;
  color: #183F32;
  box-shadow: 4px 4px 0 rgba(12,107,67,0.08), inset 0 1px 3px rgba(7,61,42,0.04);
}
.output-box .sec-head { color: #005640; }
.output-box .sys-divider { color: #E33E36; }
.app-version:hover { color: #FBDE4A; }
.app-version:focus-visible { outline-color: #FBDE4A; }
.model-note { border-left-color: #91D754; background: #F2F7E5; }

.config-card { background: #F3F7F3; border-color: #BCD0C0; }
.config-card:hover { border-color: #7FA68A; }
.config-meta .config-tag { background: #DDE9DF; }
.btn-config,
.btn-ie {
  background: #F8FAF8;
  color: #466253;
  border-color: #B7CDBB;
}
.btn-config:hover,
.btn-config.btn-load:hover,
.btn-config.btn-history:hover,
.btn-ie:hover {
  color: #005640;
  border-color: #FBDE4A;
  box-shadow: 2px 2px 0 rgba(251,222,74,0.24);
}

.modal-backdrop { background: rgba(0,86,64,0.42); }
.app-modal {
  border-color: #88A98F;
  box-shadow: 6px 6px 0 rgba(145,215,84,0.35), 10px 10px 0 rgba(227,62,54,0.15);
}

#acc-savedconfigs > .acc-header,
#acc-history > .acc-header {
  background: #91D754;
  color: #005640;
  border-bottom: 1px solid #005640;
  box-shadow: inset 0 -2px 0 rgba(0,86,64,0.10);
}
#acc-savedconfigs > .acc-header:hover,
#acc-history > .acc-header:hover,
#acc-savedconfigs > .acc-header.acc-open,
#acc-history > .acc-header.acc-open {
  background: #00A7CC;
  color: #005640;
}
#acc-savedconfigs .saved-configs-title,
#acc-history .saved-configs-title {
  color: #005640;
  opacity: 1;
}

@media (max-width: 900px) {
  .forge-header { position: relative; padding: 10px 12px; }
  .brand-lockup { gap: 9px; }
  .bel-brand-logo { width: 56px; height: 56px; }
  .forge-logo { font-size: 1.06rem; }
  .forge-subtitle { font-size: 0.58rem; }
  .forge-header-right { gap: 6px; }
  .lang-toggle, .btn-reset { height: 34px; padding-left: 9px; padding-right: 9px; }
  .btn-reset { width: 138px; min-width: 138px; }
  .model-tabs { padding-left: 8px; padding-right: 8px; }
  .model-tab { min-width: 92px; }
  .model-tab-group { min-width: 92px; }
  .panel-controls, .panel-output { padding: 14px; }
  .task-btn { height: 104px; }
  .task-btn-image { width: 82px; height: 72px; }
}

@media (max-width: 560px) {
  .forge-header { flex-direction: column; align-items: stretch; gap: 8px; }
  .forge-header-right {
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
  }
  .lang-toggle { min-width: 90px; }
  .btn-reset { width: 138px; min-width: 138px; }
  .task-grid { grid-template-columns: repeat(2, 1fr); }
  .output-meta { gap: 8px; }
  .output-footer { align-items: flex-start; flex-direction: column; }
  .powered-by { text-align: left; }
}
