:root {
  --bg-color: #0d1117;
  --surface-color: #161b22;
  --text-main: #c9d1d9;
  --text-muted: #8b949e;
  --accent-blue: #58a6ff;
  --accent-green: #3fb950;
  --accent-yellow: #d29922;
  --accent-red: #f85149;
  --border-color: #30363d;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier, monospace;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: var(--font-sans);
  background-color: var(--bg-color);
  color: var(--text-main);
  line-height: 1.6;
}

.container { max-width: 1000px; margin: 0 auto; padding: 0 20px; }

a { color: var(--accent-blue); text-decoration: none; transition: opacity 0.2s; }
a:hover { opacity: 0.8; }

/* Header */
.site-header {
  border-bottom: 1px solid var(--border-color);
  padding: 20px 0;
  background-color: var(--surface-color);
}
.nav-wrap {
  display: flex; justify-content: space-between; align-items: center;
}
.logo {
  font-family: var(--font-mono); font-weight: bold; font-size: 1.5rem; color: var(--accent-green);
}
.site-header nav a { margin-left: 20px; color: var(--text-main); }

/* Sections */
section { padding: 60px 0; }
section h1 { font-size: 2.5rem; margin-bottom: 10px; }
section h2 { font-size: 2rem; margin-bottom: 20px; color: var(--accent-blue); }
section h3 { font-size: 1.3rem; margin-bottom: 10px; margin-top: 20px; }
section p { margin-bottom: 20px; color: var(--text-muted); font-size: 1.1rem; }
code { font-family: var(--font-mono); background: var(--surface-color); padding: 2px 6px; border-radius: 4px; color: var(--accent-yellow); }

.subtitle { font-size: 1.25rem; max-width: 700px; }

/* Tool Container */
.tool-container {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 30px;
  margin: 40px 0;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.input-group {
  display: flex;
  align-items: center;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 5px 15px;
}
.prompt-symbol {
  color: var(--accent-green);
  font-family: var(--font-mono);
  font-weight: bold;
  margin-right: 15px;
}
input[type="text"] {
  flex: 1;
  background: transparent;
  border: none;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 1.2rem;
  padding: 15px 0;
  outline: none;
}
button {
  background: var(--accent-blue);
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  font-weight: bold;
  cursor: pointer;
  transition: background 0.2s;
}
button:hover { background: #3182ce; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Results */
.hidden { display: none !important; }
.result-area { margin-top: 30px; border-top: 1px solid var(--border-color); padding-top: 30px; }
.syntax-highlight {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  margin-bottom: 30px;
  letter-spacing: 0.5px;
  word-break: break-all;
}
.part-cmd { color: var(--accent-blue); font-weight: bold; }
.part-flag { color: var(--accent-green); }
.part-arg { color: var(--accent-yellow); }

.explanation-list { display: flex; flex-direction: column; gap: 15px; }
.exp-item {
  display: flex;
  align-items: flex-start;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 15px;
}
.exp-term {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  min-width: 120px;
  font-weight: bold;
}
.exp-desc { color: var(--text-muted); }

/* Grid component */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}
.card {
  background: var(--surface-color);
  border: 1px solid var(--border-color);
  padding: 25px;
  border-radius: 8px;
}
.card p { margin-bottom: 0; font-size: 1rem; }

.note-text { font-size: 0.9rem; margin-top: 30px; text-align: center; }

.ad-container { margin: 30px 0; text-align: center; min-height: 120px; background: rgba(0,0,0,0.2); border: 1px dashed var(--border-color); display: flex; align-items: center; justify-content: center; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border-color);
  padding: 40px 0;
  text-align: center;
  color: var(--text-muted);
}
.site-footer nav { margin-top: 15px; }
.site-footer nav a { margin: 0 10px; color: var(--text-muted); }

@media (max-width: 768px) {
  .input-group { flex-direction: column; align-items: stretch; }
  .prompt-symbol { display: none; }
  input[type="text"] { padding: 10px; margin-bottom: 10px; text-align: center; }
  section h1 { font-size: 2rem; }
  .exp-item { flex-direction: column; }
  .exp-term { margin-bottom: 10px; }
}



/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
