/* MealLog Ver.0.05 additions */

.share-top-button {
  border:1px solid var(--line);
  border-radius:999px;
  background:#fff;
  color:#655d91;
  padding:10px 14px;
  font-size:11px;
  font-weight:800;
  box-shadow:var(--shadow-soft);
}

.share-top-button:hover {
  background:#f7f4ff;
  border-color:#ddd7f3;
}

.share-select-field select {
  width:100%;
  min-height:48px;
  border:1px solid var(--line);
  border-radius:14px;
  padding:0 42px 0 15px;
  background:#fffdfc;
  color:var(--ink);
  font:inherit;
  outline:none;
}

.share-select-field select:focus {
  border-color:#a9a0df;
  box-shadow:0 0 0 4px rgba(101,93,145,.09);
}

.share-select-field small {
  display:block;
  margin-top:7px;
  color:var(--muted);
  font-size:10px;
  line-height:1.55;
}

.meal-tag.shared {
  color:#5c548e;
  background:#efedff;
}

.meal-tag.shared-by {
  color:#63706e;
  background:#edf3f2;
}

.shared-readonly {
  color:#9a8f89;
  font-size:10px;
  font-weight:700;
}

.shared-detail-note {
  margin-top:20px;
  padding:12px 14px;
  border-radius:14px;
  background:#f4f2ff;
  color:#655d91;
  font-size:11px;
  line-height:1.6;
}

.share-card {
  width:min(720px,calc(100% - 28px));
}

.share-lead {
  margin:7px 0 0;
  color:var(--muted);
  font-size:12px;
  line-height:1.7;
}

.share-groups-list {
  display:grid;
  gap:10px;
  margin-top:6px;
}

.share-empty {
  padding:24px;
  border:1px dashed #ddd1cc;
  border-radius:20px;
  background:#fffaf8;
  text-align:center;
}

.share-empty strong {
  display:block;
  font-size:15px;
}

.share-empty p {
  margin:7px 0 0;
  color:var(--muted);
  font-size:11px;
  line-height:1.7;
}

.share-group-card {
  padding:17px;
  border:1px solid var(--line);
  border-radius:20px;
  background:#fff;
}

.share-group-main {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
}

.share-group-main h3 {
  margin:4px 0 2px;
  font-size:18px;
}

.share-group-main p {
  margin:0;
  color:var(--muted);
  font-size:10px;
}

.share-role {
  display:inline-flex;
  padding:4px 7px;
  border-radius:999px;
  background:#f1effc;
  color:#655d91;
  font-size:8px;
  font-weight:800;
}

.share-group-icon {
  width:40px;
  height:40px;
  border-radius:14px;
  display:grid;
  place-items:center;
  background:#f3f0ff;
  color:#655d91;
  font-size:22px;
}

.invite-code-box {
  margin-top:14px;
  display:grid;
  grid-template-columns:auto 1fr auto;
  align-items:center;
  gap:10px;
  padding:11px 12px;
  border-radius:14px;
  background:#f8f5ff;
}

.invite-code-box span {
  color:#8a8196;
  font-size:9px;
}

.invite-code-box strong {
  min-width:0;
  letter-spacing:.12em;
  font-size:13px;
  overflow-wrap:anywhere;
}

.invite-code-box button {
  border:0;
  border-radius:10px;
  padding:7px 9px;
  background:#fff;
  color:#655d91;
  font-size:9px;
  font-weight:800;
}

.share-danger-button,
.share-leave-button {
  margin-top:10px;
  border:0;
  background:transparent;
  padding:6px 2px;
  font-size:10px;
}

.share-danger-button {
  color:#c43150;
}

.share-leave-button {
  color:#7d706a;
}

.share-actions-grid {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:12px;
  margin-top:18px;
}

.share-action-card {
  display:grid;
  gap:10px;
  padding:17px;
  border:1px solid var(--line);
  border-radius:20px;
  background:#fffaf8;
}

.share-action-kicker {
  color:var(--brand-deep);
  font-size:9px;
  font-weight:800;
  letter-spacing:.12em;
}

.share-action-card strong {
  font-size:14px;
}

.share-action-card input {
  min-height:45px;
}

.share-join-button {
  display:block;
  width:100%;
  min-height:44px;
}

.share-message {
  min-height:20px;
  margin:12px 2px 0;
  color:#736762;
  font-size:11px;
  line-height:1.6;
}

@media (max-width:640px) {
  .share-top-button {
    display:none;
  }

  .bottom-nav {
    grid-template-columns:repeat(4,1fr);
  }

  .bottom-nav .nav-add {
    margin:-16px 4px 0;
  }

  .share-card {
    width:100%;
    max-height:92vh;
    min-height:78vh;
    margin:8vh 0 0;
    border-radius:28px 28px 0 0;
    padding:20px;
  }

  .share-actions-grid {
    grid-template-columns:1fr;
  }

  .invite-code-box {
    grid-template-columns:1fr auto;
  }

  .invite-code-box > span {
    grid-column:1/-1;
  }

  .share-group-card {
    padding:15px;
  }
}
