/* Layout */
.es-container {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 1.5rem;
  align-items: start;
}
@media (max-width: 860px) {
  .es-container { grid-template-columns: 1fr; }
}

/* Form column */
.es-label {
  font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.07em;
  opacity: 0.5; font-weight: 700; margin-bottom: 0.75rem;
}
.es-tmpl-card { padding: 1rem; margin-bottom: 1rem; }
.es-tmpl-btns { display: flex; gap: 0.5rem; }
.es-tmpl-btn {
  flex: 1; background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  color: inherit; border-radius: 8px; padding: 0.5rem;
  font-size: 0.85rem; font-weight: 600; cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}
.es-tmpl-btn:hover { background: rgba(255,255,255,0.1); }
.es-tmpl-btn.active { background: var(--accent); border-color: var(--accent); color: #fff; }

.es-form-card { padding: 1rem 1.1rem; margin-bottom: 1rem; }
.es-fields { display: flex; flex-direction: column; gap: 0.6rem; }
.es-field { display: flex; flex-direction: column; gap: 0.25rem; }
.es-field label { font-size: 0.78rem; opacity: 0.65; font-weight: 600; }
.es-field input[type="text"],
.es-field input[type="email"],
.es-field input[type="tel"] {
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px; padding: 0.5rem 0.75rem;
  color: inherit; font-family: inherit; font-size: 0.9rem; outline: none;
  transition: border-color 0.15s;
}
.es-field input:focus { border-color: var(--accent); }
.es-disclaimer-input {
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px; padding: 0.5rem 0.75rem;
  color: inherit; font-family: inherit; font-size: 0.85rem; outline: none;
  resize: vertical; transition: border-color 0.15s;
}
.es-disclaimer-input:focus { border-color: var(--accent); }
.es-optional { opacity: 0.4; font-weight: 400; }
.es-color-row { display: flex; align-items: center; gap: 0.6rem; }
.sg-small-hex {
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
  border-radius: 7px; padding: 0.35rem 0.6rem;
  color: inherit; font-family: monospace; font-size: 0.85rem; font-weight: 700;
  width: 90px; text-transform: uppercase; outline: none;
}
.es-file-input {
  background: rgba(255,255,255,0.03); border: 1px dashed rgba(255,255,255,0.15);
  border-radius: 8px; padding: 0.5rem 0.75rem;
  color: inherit; font-size: 0.85rem; cursor: pointer; width: 100%;
}

/* Preview column */
.es-preview-label {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 0.6rem; font-size: 0.82rem; font-weight: 700; opacity: 0.7;
}
.es-preview-toggles { display: flex; gap: 0.4rem; }
.es-bg-toggle {
  font-size: 0.75rem; padding: 0.25rem 0.6rem;
  opacity: 0.6; transition: opacity 0.15s;
}
.es-bg-toggle.active { opacity: 1; background: var(--accent); color: #fff; border-color: var(--accent); }

.es-preview-card { padding: 0; overflow: hidden; margin-bottom: 1rem; }
.es-email-chrome { display: flex; flex-direction: column; }
.es-chrome-bar {
  display: flex; gap: 6px; align-items: center;
  padding: 0.6rem 0.9rem; background: rgba(255,255,255,0.05);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.es-chrome-dot { width: 11px; height: 11px; border-radius: 50%; display: block; }
.es-email-body {
  padding: 1.5rem 1.75rem; background: #ffffff; color: #1a1a1a;
  min-height: 180px; transition: background 0.2s, color 0.2s;
}
.es-email-body.dark { background: #1e1e1e; color: #e0e0e0; }
.es-email-body-text {
  font-family: Arial, sans-serif; font-size: 14px; line-height: 1.6;
  color: inherit; margin: 0 0 1.25rem 0;
}
.es-sig-preview { border-top: 1px solid #e0e0e0; padding-top: 1rem; margin-top: 0.5rem; }
.es-email-body.dark .es-sig-preview { border-top-color: #333; }

/* Copy row */
.es-copy-row { display: flex; gap: 0.75rem; margin-bottom: 1rem; flex-wrap: wrap; }
.es-copy-html { flex: 1; }
.es-copy-text { flex: 1; }

/* Instructions */
.es-instructions { padding: 1.1rem; }
.es-inst-tabs { display: flex; gap: 0.5rem; margin-bottom: 0.9rem; }
.es-inst-tab {
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
  color: inherit; border-radius: 7px; padding: 0.3rem 0.75rem;
  font-size: 0.8rem; font-weight: 600; cursor: pointer;
}
.es-inst-tab.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.es-inst-panel { display: none; }
.es-inst-panel.active { display: block; }
.es-inst-steps {
  margin: 0; padding-left: 1.3rem;
  display: flex; flex-direction: column; gap: 0.5rem;
}
.es-inst-steps li { font-size: 0.85rem; line-height: 1.45; }
.es-inst-steps kbd {
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2);
  border-radius: 4px; padding: 0.1rem 0.4rem; font-size: 0.78rem;
}

/* cc-color-picker shared styles */
.cc-color-picker {
  width: 36px; height: 36px; border: none; background: none;
  cursor: pointer; border-radius: 6px; padding: 0; flex-shrink: 0;
}
.cc-color-picker::-webkit-color-swatch-wrapper { padding: 0; }
.cc-color-picker::-webkit-color-swatch { border-radius: 6px; border: 2px solid rgba(255,255,255,0.15); }
