:root {
  --bg-top: #f3f7f5;
  --bg-bottom: #ecf0f2;
  --panel: #ffffff;
  --ink: #2f2f2f;
  --muted: #69737a;
  --stroke: #d7dde2;
  --brand: #1f2629;
  --brand-soft: #3f4b51;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Avenir Next", "Gill Sans", "Trebuchet MS", sans-serif;
  color: var(--ink);
  background: radial-gradient(circle at 15% 20%, #ffffff 0, var(--bg-top) 46%),
    linear-gradient(165deg, var(--bg-top), var(--bg-bottom));
  min-height: 100vh;
}

.app-shell {
  max-width: 1080px;
  margin: 0 auto;
  padding: 32px 16px;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.panel {
  background: var(--panel);
  border: 1px solid var(--stroke);
  border-radius: 14px;
  padding: 20px;
  box-shadow: 0 12px 30px rgba(31, 38, 41, 0.08);
}

h1,
h2 {
  margin: 0;
  font-weight: 600;
  letter-spacing: 0.01em;
}

h1 {
  font-size: 1.4rem;
}

h2 {
  font-size: 1.2rem;
}

.title-row {
  display: flex;
  align-items: center;
  gap: 14px;
}

.title-mark {
  width: 54px;
  height: 54px;
  object-fit: contain;
  border-radius: 10px;
}

.subtitle {
  margin: 8px 0 16px;
  color: var(--muted);
  font-size: 0.95rem;
}

form {
  display: grid;
  gap: 8px;
}

label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--brand-soft);
  margin-top: 4px;
}

input {
  width: 100%;
  border: 1px solid var(--stroke);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  color: var(--ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

select {
  border: 1px solid var(--stroke);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  color: var(--ink);
  background: #fff;
}

input:focus {
  border-color: #a4b1b8;
  box-shadow: none;
  outline: 0;
}

select:focus {
  border-color: #a4b1b8;
  box-shadow: none;
  outline: 0;
}

input:focus-visible,
select:focus-visible,
button:focus-visible {
  outline: 3px solid #0b6b6f;
  outline-offset: 2px;
}

.phone-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.phone-label-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: end;
}

button {
  margin-top: 12px;
  background: var(--brand);
  color: #fff;
  border: 0;
  border-radius: 10px;
  padding: 11px 14px;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.14s ease, background-color 0.2s ease;
}

button:hover {
  background: #111618;
}

button:active {
  transform: translateY(1px);
}

.status {
  min-height: 1.2em;
  margin: 8px 0 0;
  font-size: 0.88rem;
  color: var(--muted);
}

.gmail-steps {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--stroke);
}

.gmail-steps h2 {
  font-size: 1rem;
  margin-bottom: 8px;
}

.gmail-steps ol {
  margin: 0;
  padding-left: 18px;
  color: var(--brand-soft);
  font-size: 0.92rem;
  line-height: 1.45;
}

.preview-surface {
  margin-top: 8px;
  border: 1px solid var(--stroke);
  border-radius: 12px;
  background: #ffffff;
  padding: 18px;
  overflow-x: auto;
}

#signature-preview {
  min-width: 300px;
}

@media (max-width: 700px) {
  .app-shell {
    padding: 20px 12px;
  }

  .panel {
    padding: 16px;
  }
}
