:root {
  --control-height: 36px;
}


body {
  margin: 0;
  background: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-ui);
}

#app {
  display: flex;
  flex-direction: column;
  height: 100vh;
}

.top-bar {
  height: 48px;
  background: var(--bg-panel);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
}

.project-title {
  font-size: 18px;
  font-weight: bold;
  text-align: left;
}

.app-body {
  display: flex;
  flex: 1;
  overflow: hidden;
}

main {
  flex: 1 1 auto;
  background: var(--bg-main);
  padding: 24px;
  overflow-y: auto;
  min-height: 0;
  min-width: 0;
}

html, body {
  height: 100%;
}

#app,
.app,
.app-shell {
  height: 100vh;
  display: flex;
}

.app-content,
.content,
.main-wrapper {
  display: flex;
  flex: 1;
  min-height: 0;
}


.btn {
  appearance: none;
  height: var(--control-height);
  border: 1px solid var(--border);
  background: #2a2a2a;
  color: var(--text-primary);

  padding: 6px 12px;
  border-radius: 4px;

  font-size: 13px;
  font-weight: 500;
  line-height: 1;

  cursor: pointer;
  white-space: nowrap;

  transition:
    background 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.btn:hover {
  background: #333;
  border-color: #555;
}

.btn:active {
  background: #3a3a3a;
}

.btn:focus {
  outline: none;
  border-color: var(--accent-muted, #a36a2a);
}

.btn-accent {
  background: #2f2a22;
  border-color: #5a4630;
  color: #e2c9a2;
}

.btn-accent:hover {
  background: #3a3328;
  border-color: #7a5c3a;
}

.btn-icon {
  padding: 6px 8px;
  font-size: 12px;
}


.btn-danger {
  background: #3a1f1f;
  border-color: #6a2a2a;
  color: #f2bcbc;
}

.btn-danger:hover {
  background: #4a2424;
}

.btn-current {
  background-color: #2ecc71;
  color: #ffffff;
  cursor: default;
  opacity: 1;
}

.btn-current:hover {
  background-color: #2ecc71;
}

/* ============================
   Text Inputs & Textareas
   ============================ */

input[type="text"],
input[type="search"],
input[type="email"],
input[type="password"],
textarea {
  background-color: #1f1f1f;
  color: #f0f0f0;

  border: 1px solid #3a3a3a;
  border-radius: 6px;

  height: var(--control-height);
  padding: 8px 10px;
  font-size: 14px;
  line-height: var(--control-height);

  outline: none;
  box-sizing: border-box;

  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    background-color 0.15s ease;
}

input[type="text"]:focus,
input[type="search"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus {
  border-color: #6aa9ff;
  box-shadow: 0 0 0 2px rgba(106, 169, 255, 0.25);
  background-color: #222;
}

input::placeholder,
textarea::placeholder {
  color: #9a9a9a;
}

input:disabled,
textarea:disabled,
input[readonly],
textarea[readonly] {
  background-color: #2a2a2a;
  color: #b0b0b0;
  border-color: #444;
  cursor: not-allowed;
}

.input-compact {
  padding: 6px 8px;
  font-size: 13px;
}

textarea {
  height: auto;
  min-height: calc(var(--control-height) * 2);
  line-height: 1.4;
  padding: 8px 10px;
  resize: vertical;
}

/* ============================
   File Input Button Styling
   ============================ */

input[type="file"] {
  color: #f0f0f0;
  font-size: 14px;
}

input[type="file"]::file-selector-button {
  height: var(--control-height);
  padding: 0 14px;

  margin-right: 10px;

  background: #2f2a22;
  border-color: #5a4630;
  color: #e2c9a2;

  border: none;
  border-radius: 6px;

  font-size: 14px;
  font-weight: 500;

  cursor: pointer;

  transition:
    background-color 0.15s ease,
    box-shadow 0.15s ease;
}

input[type="file"]::file-selector-button:hover {
  background: #3a3328;
  border-color: #7a5c3a;
}

input[type="file"]::file-selector-button:active {
  background: #3a3328;
  border-color: #7a5c3a;
}

input[type="file"]:focus-visible::file-selector-button {
  box-shadow: 0 0 0 2px rgba(106, 169, 255, 0.35);
}

