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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background-color: #0f172a;
  color: #f8fafc;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

.app-container {
  width: 100%;
  max-width: 1600px;
  margin: 0 auto;
  padding: clamp(1rem, 2vw, 2rem);
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 1.5rem;
}

.header {
  text-align: center;
}

.header h1 {
  font-size: clamp(1.4rem, 2.5vw, 2.2rem);
  color: #38bdf8;
  margin-bottom: 0.25rem;
}

.header p {
  color: #94a3b8;
  font-size: 0.9rem;
}

.workspace {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  flex: 1;
}

@media (min-width: 900px) {
  .workspace {
    grid-template-columns: 1fr 1fr;
  }
}

.panel {
  background-color: #1e293b;
  border-radius: 10px;
  border: 1px solid #334155;
  display: flex;
  flex-direction: column;
  padding: 1rem;
  gap: 0.75rem;
  min-width: 0;
}

.panel-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.panel-header h2 {
  font-size: 1.05rem;
  color: #e2e8f0;
}

.actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.btn {
  border: none;
  padding: 0.45rem 0.8rem;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}

.btn:hover {
  opacity: 0.9;
}

.btn-primary { background-color: #0284c7; color: #fff; }
.btn-secondary { background-color: #475569; color: #fff; }
.btn-success { background-color: #10b981; color: #fff; }
.btn-danger { background-color: #ef4444; color: #fff; }

.dropzone {
  border: 2px dashed #475569;
  border-radius: 6px;
  padding: 0.8rem;
  text-align: center;
  font-size: 0.85rem;
  color: #94a3b8;
  transition: border-color 0.2s, background-color 0.2s;
}

.dropzone.dragover {
  border-color: #38bdf8;
  background-color: rgba(56, 189, 248, 0.05);
}

.link-label {
  color: #38bdf8;
  text-decoration: underline;
  cursor: pointer;
}

textarea {
  width: 100%;
  flex: 1;
  min-height: 380px;
  background-color: #0b1120;
  color: #e2e8f0;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 0.8rem;
  font-family: inherit;
  font-size: 0.95rem;
  line-height: 1.5;
  resize: vertical;
  outline: none;
}

#rawEncrypted {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.85rem;
  color: #a5b4fc;
  word-break: break-all;
  overflow-wrap: break-word;
}

textarea:focus {
  border-color: #38bdf8;
}
