/* assets/css/style.css */
:root {
  --ripmg-primary: #4a5568;
  --ripmg-accent: #2b6cb0;
  --ripmg-bg: #ffffff;
  --ripmg-border: #e2e8f0;
  --ripmg-radius: 12px;
  --ripmg-shadow: 0 10px 25px rgba(0,0,0,0.05);
}

.ripmg-container {
  max-width: 900px;
  margin: 2rem auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, sans-serif;
  color: #2d3748;
}

.ripmg-form {
  background: var(--ripmg-bg);
  padding: 2rem;
  border-radius: var(--ripmg-radius);
  box-shadow: var(--ripmg-shadow);
  border: 1px solid var(--ripmg-border);
}

.ripmg-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.25rem;
}

.ripmg-col {
  flex: 1 1 45%;
}

.ripmg-col-full {
  flex: 1 1 100%;
}

.ripmg-form label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--ripmg-primary);
  font-size: 0.9rem;
  letter-spacing: 0.02em;
}

.ripmg-form select,
.ripmg-form input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--ripmg-border);
  border-radius: 8px;
  font-size: 1rem;
  background: #fafafa;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.ripmg-form select:focus,
.ripmg-form input:focus {
  outline: none;
  border-color: var(--ripmg-accent);
  box-shadow: 0 0 0 3px rgba(43,108,176,0.15);
}

.ripmg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.8rem;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--ripmg-accent);
  color: #fff;
  box-shadow: 0 4px 12px rgba(43,108,176,0.3);
}

.ripmg-btn:hover {
  background: #1a4c8a;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(43,108,176,0.4);
}

.ripmg-btn-outline {
  background: transparent;
  color: var(--ripmg-accent);
  border: 1px solid var(--ripmg-accent);
  box-shadow: none;
}

.ripmg-btn-outline:hover {
  background: var(--ripmg-accent);
  color: #fff;
}

#ripmg-generate-btn {
  width: 100%;
  margin-top: 0.5rem;
}

.ripmg-results {
  margin-top: 2rem;
}

.ripmg-results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.ripmg-results-header h3 {
  margin: 0;
  font-size: 1.4rem;
  color: var(--ripmg-primary);
}

.ripmg-message-item {
  background: var(--ripmg-bg);
  border: 1px solid var(--ripmg-border);
  border-radius: var(--ripmg-radius);
  padding: 1.25rem;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.02);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: box-shadow 0.2s;
}

.ripmg-message-item:hover {
  box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

.ripmg-message-text {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #2d3748;
  word-break: break-word;
}

.ripmg-message-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.ripmg-copy-btn {
  background: #edf2f7;
  border: none;
  border-radius: 6px;
  padding: 0.4rem 1rem;
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s;
  color: #4a5568;
}

.ripmg-copy-btn:hover {
  background: #e2e8f0;
}

.ripmg-copy-btn.copied {
  background: #c6f6d5;
  color: #276749;
}

.ripmg-char-count {
  font-size: 0.8rem;
  color: #a0aec0;
}

.ripmg-loader {
  text-align: center;
  padding: 2rem;
  font-size: 1.1rem;
  color: var(--ripmg-accent);
}

@media (max-width: 600px) {
  .ripmg-row {
    flex-direction: column;
  }
  .ripmg-col {
    flex: 1 1 100%;
  }
  .ripmg-results-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}