* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f5f7f4;
  color: #172018;
}

.account-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 20px;
}

.account-panel {
  width: min(760px, 100%);
  background: #fff;
  border: 1px solid #dfe7da;
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 18px 50px rgba(23, 32, 24, 0.08);
}

.back-link {
  display: inline-flex;
  color: #1f7a4f;
  font-weight: 700;
  text-decoration: none;
  margin-bottom: 14px;
}

h1 {
  font-size: 28px;
  margin: 0 0 8px;
}

.muted,
.message {
  color: #5f6d62;
  line-height: 1.5;
}

.notice {
  border: 1px solid #dfe7da;
  background: #f8fbf6;
  border-radius: 8px;
  padding: 12px;
  margin: 16px 0;
  color: #4f5f52;
}

button,
input,
select {
  width: 100%;
  min-height: 44px;
  border-radius: 7px;
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
  font-weight: 700;
  margin-top: 10px;
}

.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 18px 0 10px;
}

.tab {
  background: #eef4ec;
  color: #172018;
}

.tab.active {
  background: #172018;
  color: #fff;
}

.primary {
  background: #1f7a4f;
  color: #fff;
}

.secondary {
  background: #eef4ec;
  color: #172018;
}

.link-button {
  background: transparent;
  color: #1f7a4f;
  min-height: 36px;
}

label {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  font-weight: 700;
}

input,
select {
  border: 1px solid #cfd9ca;
  padding: 0 12px;
  background: #fff;
}

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 18px 0 6px;
  color: #778377;
}

.divider::before,
.divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: #dfe7da;
}

.profile-panel {
  display: grid;
  gap: 12px;
  border: 1px solid #dfe7da;
  border-radius: 8px;
  padding: 14px;
  margin-top: 16px;
  background: #f8fbf6;
}

.profile-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.nav-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 7px;
  text-decoration: none;
  font-weight: 700;
}

.manage-panel {
  display: grid;
  gap: 18px;
  margin-top: 18px;
  border-top: 1px solid #dfe7da;
  padding-top: 18px;
}

.manage-page {
  width: min(980px, 100%);
}

.manage-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 220px;
}

.profile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.profile-grid label {
  margin-top: 0;
}

.wide {
  grid-column: 1 / -1;
}

.form-actions {
  display: grid;
  gap: 8px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.section-head h2 {
  margin: 0;
  font-size: 20px;
}

.compact {
  width: auto;
  min-height: 36px;
  padding: 0 12px;
  margin-top: 0;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.info-grid > div {
  display: grid;
  gap: 4px;
  border: 1px solid #dfe7da;
  border-radius: 8px;
  padding: 12px;
  background: #f8fbf6;
}

.info-grid span {
  color: #5f6d62;
  font-size: 13px;
}

.orders-list {
  display: grid;
  gap: 10px;
}

.order-card {
  border: 1px solid #dfe7da;
  border-radius: 8px;
  padding: 12px;
  background: #fff;
}

.order-top,
.order-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.order-card p {
  margin: 8px 0;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 0 10px;
  background: #eef4ec;
  color: #1f7a4f;
  font-weight: 700;
  font-size: 13px;
}

.order-items {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0;
}

.order-items span {
  border-radius: 999px;
  padding: 5px 8px;
  background: #f5f7f4;
  color: #4f5f52;
  font-size: 13px;
}

.small {
  font-size: 14px;
}

@media (max-width: 620px) {
  .profile-actions,
  .info-grid,
  .profile-grid {
    grid-template-columns: 1fr;
  }

  .manage-title,
  .top-actions {
    display: grid;
    width: 100%;
  }

  .wide {
    grid-column: auto;
  }
}
