:root {
  color-scheme: light;
  --bg: #f4f7f5;
  --surface: #ffffff;
  --ink: #17211c;
  --muted: #65756d;
  --line: #dce6df;
  --green: #0a9b57;
  --green-dark: #087444;
  --red: #b42318;
  --amber: #9a6700;
  --blue: #2563eb;
  --shadow: 0 18px 50px rgba(23, 33, 28, 0.11);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(10, 155, 87, 0.14), transparent 34%),
    linear-gradient(315deg, rgba(37, 99, 235, 0.1), transparent 30%),
    var(--bg);
  color: var(--ink);
  font-size: 15px;
  font-family: Arial, Helvetica, sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

.shell {
  width: min(1080px, calc(100% - 28px));
  margin: 0 auto;
  padding: 22px 0 40px;
}

.topbar,
.tabs,
.field-row,
.actions,
.result-item,
.recipient-item {
  display: flex;
  align-items: center;
}

.topbar {
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--green-dark);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 0;
  font-size: clamp(1.55rem, 4vw, 2.8rem);
  line-height: 1.05;
}

h2 {
  max-width: 620px;
  margin-bottom: 12px;
  font-size: clamp(1.45rem, 3vw, 2.55rem);
  line-height: 1.08;
}

h3 {
  margin-bottom: 4px;
  font-size: 1.05rem;
}

.status-pill {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.74);
  padding: 10px 14px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.status-pill.ready {
  color: var(--green-dark);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  gap: 24px;
  align-items: end;
  min-height: 320px;
  margin-bottom: 18px;
  padding: 30px;
  overflow: hidden;
  border-radius: 8px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.64)),
    url("https://images.unsplash.com/photo-1556742049-0cfed4f6a45d?auto=format&fit=crop&w=1600&q=80");
  background-position: center;
  background-size: cover;
  box-shadow: var(--shadow);
}

.hero-copy p:not(.eyebrow) {
  max-width: 590px;
  margin-bottom: 0;
  color: #33443b;
  font-size: 0.96rem;
  line-height: 1.55;
}

.phone-preview {
  width: 220px;
  min-height: 292px;
  justify-self: end;
  border: 8px solid #18241e;
  border-radius: 28px;
  background: #f8fbf9;
  padding: 14px;
  box-shadow: 0 22px 45px rgba(0, 0, 0, 0.22);
}

.phone-bar {
  width: 62px;
  height: 5px;
  margin: 0 auto 20px;
  border-radius: 999px;
  background: #27362f;
}

.screen-card {
  border-radius: 8px;
  background: #0a9b57;
  padding: 18px;
  color: white;
}

.screen-card span,
.screen-card small {
  display: block;
  opacity: 0.82;
}

.screen-card strong {
  display: block;
  margin: 8px 0;
  font-size: 2.15rem;
  line-height: 1;
}

.screen-line {
  width: 68%;
  height: 10px;
  margin-top: 14px;
  border-radius: 999px;
  background: #dce6df;
}

.screen-line.wide {
  width: 100%;
}

.screen-button {
  margin-top: 30px;
  border-radius: 8px;
  background: #17211c;
  padding: 12px;
  color: white;
  text-align: center;
  font-weight: 800;
}

.tabs {
  gap: 8px;
  margin-bottom: 14px;
}

.tab,
.primary,
.secondary {
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  padding: 0 16px;
  cursor: pointer;
  font-weight: 800;
}

.tab {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.74);
  color: var(--muted);
}

.tab.is-active,
.primary {
  background: var(--green);
  color: white;
}

.secondary {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
}

.panel {
  display: none;
}

.panel.is-active {
  display: block;
}

.grid.two {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
  gap: 16px;
}

.card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  padding: 18px;
  box-shadow: 0 10px 30px rgba(23, 33, 28, 0.06);
}

.section-heading {
  margin-bottom: 14px;
}

.section-heading p {
  margin-bottom: 0;
  color: var(--muted);
}

.form-stack {
  display: grid;
  gap: 14px;
}

.field-row {
  gap: 16px;
}

label {
  display: grid;
  width: 100%;
  gap: 7px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
}

label small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.35;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  color: var(--ink);
  padding: 11px 12px;
  outline: none;
}

textarea {
  resize: vertical;
  line-height: 1.5;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(10, 155, 87, 0.16);
}

.recipient-list,
.results-list {
  display: grid;
  gap: 10px;
}

.recipient-item,
.result-item {
  justify-content: space-between;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: white;
  padding: 12px;
}

.recipient-item.invalid,
.result-item.failed {
  border-color: rgba(180, 35, 24, 0.3);
}

.badge {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 5px 9px;
  background: rgba(10, 155, 87, 0.1);
  color: var(--green-dark);
  font-size: 0.75rem;
  font-weight: 800;
}

.badge.failed {
  background: rgba(180, 35, 24, 0.1);
  color: var(--red);
}

.badge.pending {
  background: rgba(154, 103, 0, 0.12);
  color: var(--amber);
}

.muted {
  color: var(--muted);
}

.actions {
  gap: 10px;
  flex-wrap: wrap;
}

.site-footer {
  margin-top: 24px;
  padding: 18px 0 4px;
  text-align: center;
}

.site-footer a {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
  text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus {
  color: var(--green-dark);
  text-decoration: underline;
}

@media (max-width: 820px) {
  .shell {
    width: min(100% - 18px, 680px);
    padding-top: 12px;
  }

  .topbar,
  .field-row,
  .grid.two {
    display: grid;
    grid-template-columns: 1fr;
  }

  .topbar {
    gap: 12px;
    margin-bottom: 12px;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    padding: 18px;
    gap: 18px;
  }

  .phone-preview {
    width: min(210px, 100%);
    min-height: 250px;
    justify-self: start;
  }

  .tabs {
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .tab {
    flex: 1 0 auto;
  }

  .card {
    padding: 14px;
  }

  textarea {
    min-height: 140px;
  }
}

@media (max-width: 520px) {
  body {
    font-size: 14px;
  }

  .shell {
    width: calc(100% - 14px);
  }

  .status-pill {
    justify-self: start;
    padding: 8px 10px;
  }

  .hero {
    padding: 14px;
  }

  .phone-preview {
    display: none;
  }

  .tabs {
    position: sticky;
    top: 0;
    z-index: 3;
    background: rgba(244, 247, 245, 0.94);
    padding: 6px 0;
  }

  .tab,
  .primary,
  .secondary {
    min-height: 40px;
    padding: 0 12px;
  }

  .actions .primary,
  .actions .secondary {
    width: 100%;
  }

  .recipient-item,
  .result-item {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .site-footer {
    margin-top: 18px;
    padding-bottom: 0;
  }
}
