@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap");

:root {
  --bg: #f7f5f0;
  --surface: #ffffff;
  --ink: #004b34;
  --muted: #6b7570;
  --border: #99b7ad;
  --accent: #1f5c3f;
  --accent-soft: #e8f0e9;
  --danger: #b3452e;
  --radius: 16px;
  --shadow: 0 10px 30px -12px rgba(31, 46, 38, 0.18);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  display: flex;
  justify-content: center;
  padding: 64px 24px;
}

.app {
  width: 100%;
  max-width: 720px;
}

.hero {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.brand-logo {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.brand-name {
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--muted);
  text-transform: uppercase;
}

h1 {
  font-size: 28px;
  font-weight: 600;
  margin: 0 0 8px 0;
  letter-spacing: -0.01em;
}

.subtitle {
  color: var(--muted);
  font-size: 15px;
  margin: 0 0 32px 0;
  line-height: 1.6;
}

.card {
  background: var(--surface);
  padding: 40px;
}

.hidden {
  display: none !important;
}

.btn {
  appearance: none;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 13px 22px;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, opacity 0.15s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  background: #184a32;
}

.btn-secondary {
  background: var(--accent-soft);
  color: var(--accent);
}

.btn-secondary:hover {
  background: #dceade;
}

.btn-ghost {
  background: transparent;
  color: var(--muted);
}

.btn-ghost:hover {
  color: var(--ink);
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.profile-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.profile-info .name {
  font-weight: 600;
  font-size: 17px;
}

.profile-info .meta {
  color: var(--muted);
  font-size: 14px;
  margin-top: 2px;
}

.company-tag {
  display: inline-block;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 4px 12px;
}

.section-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 12px;
}

.preview-frame-wrap {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: #fcfbf9;
}

iframe#signature-frame {
  width: 100%;
  border: none;
  display: block;
  background: #fcfbf9;
}

.actions {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
}

.lang-toggle {
  display: flex;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.lang-btn {
  appearance: none;
  border: none;
  background: var(--surface);
  color: var(--muted);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 8px 14px;
  cursor: pointer;
}

.lang-btn + .lang-btn {
  border-left: 1.5px solid var(--border);
}

.lang-btn.active {
  background: var(--accent);
  color: #ffffff;
}

.status {
  font-size: 13.5px;
  color: var(--accent);
  font-weight: 500;
}

.status.error {
  color: var(--danger);
}

.landing {
  text-align: center;
  padding: 56px 40px;
}

.spinner {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2.5px solid var(--accent-soft);
  border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.footer-note {
  margin-top: 24px;
  font-size: 12.5px;
  color: var(--muted);
  text-align: center;
}

.help-card {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.help-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--accent);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--accent);
  margin-bottom: 16px;
}

.help-list {
  margin: 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.help-list li {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink);
}

.help-list li strong {
  color: var(--accent);
}
