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

:root {
  --bg: #000000;
  --text: #ffffff;
  --muted: #888888;
  --accent: #ffffff;
}

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: 'Courier New', monospace;
  font-size: 16px;
  line-height: 1.6;
  padding: 20px;
}

.terminal {
  max-width: 900px;
  margin: 0 auto;
  min-height: calc(100vh - 40px);
  display: flex;
  flex-direction: column;
  padding: 20px;
}

/* Header Section */
.header {
  padding-bottom: 20px;
  margin-bottom: 20px;
  text-align: center;
}

.logo {
  color: var(--accent);
  font-size: 0.7rem;
  line-height: 0.9rem;
  margin-bottom: 10px;
}

.slogan {
  color: var(--muted);
  font-size: 14px;
}

/* Content Section */
.content {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 0;
}

.prompt {
  font-size: 18px;
  color: var(--text);
  white-space: pre-line;
}

#type-target {
  min-height: 1.3em;
}

.cursor {
  display: inline-block;
  width: 10px;
  height: 1em;
  background: var(--accent);
  animation: blink 1s steps(2) infinite;
  vertical-align: text-bottom;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* Footer Section */
.footer {
  padding-top: 20px;
  margin-top: 20px;
}

.tools {
  display: flex;
  flex-direction: row;
  gap: 20px;
  justify-content: center;
  align-items: center;
  margin-bottom: 15px;
}

.tool {
  color: var(--accent);
  text-decoration: none;
  font-size: 16px;
  transition: color 0.2s;
}

.tool:hover {
  color: var(--text);
  filter: brightness(1.5);
}

.key {
  color: var(--muted);
  margin-right: 5px;
}

/* Status Bar */
.status-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
  margin-top: 30px;
  padding-top: 15px;
  border-top: 1px solid #222222;
}

.status-item {
  display: inline-block;
}

.status-item.clickable {
  cursor: pointer;
  transition: color 0.2s;
}

.status-item.clickable:hover {
  color: var(--text);
}

/* Tool Mode Styles */
.tool-header {
  padding: 20px 0;
  border-bottom: 1px solid #222222;
  margin-bottom: 30px;
}

.tool-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
}

.tool-home-btn {
  background: transparent;
  border: none;
  color: var(--text);
  padding: 8px 0;
  font-family: 'Courier New', monospace;
  font-size: 16px;
  cursor: pointer;
  transition: color 0.2s;
}

.tool-home-btn:hover {
  color: var(--muted);
}

.tool-separator {
  color: var(--muted);
  margin: 0 5px;
}

.tool-nav {
  display: flex;
  gap: 15px;
  align-items: center;
}

.tool-nav-item {
  color: var(--muted);
  text-decoration: none;
  font-size: 16px;
  transition: color 0.2s;
  padding: 8px 0;
}

.tool-nav-item:hover {
  color: var(--text);
}

.tool-nav-item.active {
  color: var(--text);
  border-bottom: 1px solid var(--text);
}

.tool-content {
  flex: 1;
  margin-bottom: 30px;
}

.tool-container {
  display: flex;
  gap: 20px;
  margin-bottom: 20px;
}

.tool-panel {
  flex: 1;
}

.tool-panel h3 {
  font-size: 16px;
  margin-bottom: 15px;
  color: var(--muted);
}

.tool-textarea {
  width: 100%;
  min-height: 200px;
  background: #111111;
  border: 1px solid #222222;
  color: var(--text);
  font-family: 'Courier New', monospace;
  font-size: 14px;
  padding: 15px;
  resize: vertical;
}

.tool-textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.tool-input-group,
.tool-output-group {
  margin-bottom: 20px;
}

.tool-input-group label,
.tool-output-group label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 14px;
}

.tool-input {
  width: 100%;
  background: #111111;
  border: 1px solid #222222;
  color: var(--text);
  font-family: 'Courier New', monospace;
  font-size: 14px;
  padding: 10px;
}

.tool-input:focus {
  outline: none;
  border-color: var(--accent);
}

.tool-buttons {
  display: flex;
  gap: 10px;
  margin-top: 15px;
}

.tool-btn {
  background: transparent;
  border: 1px solid var(--accent);
  color: var(--accent);
  padding: 8px 16px;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
}

.tool-btn:hover {
  background: var(--accent);
  color: var(--bg);
}

.tool-link {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #222222;
  text-align: center;
}

.tool-link a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}

.tool-link a:hover {
  color: var(--accent);
}

/* Encryption Tool Specific Styles */
#encryption-tool .encryption-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 20px 0;
  border-bottom: 1px solid #222222;
  margin-bottom: 30px;
  justify-content: center;
}

#encryption-tool .encryption-method-btn {
  background: transparent;
  border: 1px solid #333333;
  color: var(--muted);
  padding: 10px 20px;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  min-width: 80px;
}

#encryption-tool .encryption-method-btn:hover {
  border-color: var(--accent);
  color: var(--text);
}

#encryption-tool .encryption-method-btn.active {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
}

#encryption-tool .tool-container {
  display: flex;
  flex-direction: column;
}

#encryption-tool .tool-info {
  background: #1a1a1a;
  padding: 10px;
  margin-bottom: 15px;
  border-left: 3px solid #888;
}

#encryption-tool .tool-info p {
  color: #888;
  font-size: 12px;
  margin: 0;
}

/* Serialization Tool Specific Styles */
#serialization-tool .encryption-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 20px 0;
  border-bottom: 1px solid #222222;
  margin-bottom: 30px;
  justify-content: center;
}

#serialization-tool .encryption-method-btn {
  background: transparent;
  border: 1px solid #333333;
  color: var(--muted);
  padding: 10px 20px;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  min-width: 80px;
}

#serialization-tool .encryption-method-btn:hover {
  border-color: var(--accent);
  color: var(--text);
}

#serialization-tool .encryption-method-btn.active {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
}

#serialization-tool .tool-container {
  display: flex;
  flex-direction: column;
}

#serialization-tool .tool-info {
  background: #1a1a1a;
  padding: 10px;
  margin-bottom: 15px;
  border-left: 3px solid #888;
}

#serialization-tool .tool-info p {
  color: #888;
  font-size: 12px;
  margin: 0;
}

@media (max-width: 640px) {
  #encryption-tool .encryption-selector {
    flex-direction: column;
    gap: 8px;
  }
  
  #encryption-tool .encryption-method-btn {
    width: 100%;
    padding: 12px 16px;
    font-size: 13px;
  }

  #serialization-tool .encryption-selector {
    flex-direction: column;
    gap: 8px;
  }
  
  #serialization-tool .encryption-method-btn {
    width: 100%;
    padding: 12px 16px;
    font-size: 13px;
  }
}

@media (max-width: 1024px) {
  .tool-container {
    flex-direction: column;
  }
}

/* JSON Formatter Tool Specific Styles */
#json-formatter-tool .tool-container {
  display: flex;
  flex-direction: row;
  gap: 20px;
}

#json-formatter-tool .tool-panel {
  flex: 1;
  min-width: 0;
}

#json-formatter-tool .tool-panel h3 {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

#json-formatter-tool .tool-textarea {
  width: 100%;
  min-height: 300px;
  background: #0a0a0a;
  border: 1px solid #333333;
  color: var(--text);
  font-family: 'Courier New', monospace;
  font-size: 13px;
  padding: 15px;
  resize: vertical;
  line-height: 1.5;
}

#json-formatter-tool .tool-buttons {
  display: flex;
  gap: 10px;
  margin-top: 12px;
}

/* Timestamp Converter Tool Specific Styles */
#timestamp-converter-tool .tool-container {
  display: flex;
  flex-direction: row;
  gap: 30px;
}

#timestamp-converter-tool .tool-panel {
  flex: 1;
  min-width: 0;
}

#timestamp-converter-tool .tool-panel h3 {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 1px solid #222222;
  padding-bottom: 8px;
}

#timestamp-converter-tool .tool-input-group {
  margin-bottom: 20px;
}

#timestamp-converter-tool .tool-input-group label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}

#timestamp-converter-tool .tool-input {
  width: 100%;
  background: #0a0a0a;
  border: 1px solid #333333;
  color: var(--text);
  font-family: 'Courier New', monospace;
  font-size: 14px;
  padding: 10px 12px;
  margin-bottom: 10px;
}

#timestamp-converter-tool .tool-output-group {
  margin-bottom: 15px;
}

#timestamp-converter-tool .tool-output-group label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}

#timestamp-converter-tool .tool-buttons {
  display: flex;
  gap: 10px;
}

/* MongoDB ObjectId Tool Specific Styles */
#mongoid-converter-tool .tool-container {
  display: flex;
  flex-direction: row;
  gap: 30px;
}

#mongoid-converter-tool .tool-panel {
  flex: 1;
  min-width: 0;
}

#mongoid-converter-tool .tool-panel h3 {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-bottom: 1px solid #222222;
  padding-bottom: 8px;
}

#mongoid-converter-tool .tool-input-group {
  margin-bottom: 20px;
}

#mongoid-converter-tool .tool-input-group label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}

#mongoid-converter-tool .tool-input {
  width: 100%;
  background: #0a0a0a;
  border: 1px solid #333333;
  color: var(--text);
  font-family: 'Courier New', monospace;
  font-size: 14px;
  padding: 10px 12px;
  margin-bottom: 10px;
}

#mongoid-converter-tool .tool-output-group {
  margin-bottom: 15px;
}

#mongoid-converter-tool .tool-output-group label {
  display: block;
  color: var(--muted);
  font-size: 12px;
  margin-bottom: 8px;
}

#mongoid-converter-tool .tool-buttons {
  display: flex;
  gap: 10px;
}

@media (max-width: 640px) {
  body {
    padding: 10px;
  }
  
  .terminal {
    padding: 15px;
    min-height: calc(100vh - 20px);
  }
  
  .logo {
    font-size: 0.55rem;
    line-height: 0.75rem;
  }
  
  .slogan {
    font-size: 12px;
  }
  
  .prompt {
    font-size: 16px;
  }
  
  .tool {
    font-size: 14px;
  }
  
  .status-bar {
    font-size: 10px;
    gap: 8px;
    margin-top: 20px;
    padding-top: 10px;
  }
  
  .tool-header {
    padding: 15px 0;
  }
  
  .tool-toolbar {
    flex-wrap: wrap;
    font-size: 14px;
  }
  
  .tool-home-btn {
    font-size: 14px;
  }
  
  .tool-nav {
    gap: 10px;
  }
  
  .tool-nav-item {
    font-size: 14px;
  }
  
  .tool-textarea {
    min-height: 150px;
    font-size: 12px;
  }
  
  .tool-input {
    font-size: 12px;
  }
  
  .tool-btn {
    font-size: 12px;
    padding: 6px 12px;
  }
  
  /* Responsive styles for tool-specific layouts */
  #json-formatter-tool .tool-container,
  #timestamp-converter-tool .tool-container,
  #mongoid-converter-tool .tool-container {
    flex-direction: column;
  }
  
  #json-formatter-tool .tool-textarea {
    min-height: 150px;
    font-size: 12px;
  }
  
  #timestamp-converter-tool .tool-panel h3,
  #mongoid-converter-tool .tool-panel h3 {
    font-size: 12px;
  }
}
