garden-result-share { display:block; min-width:0; max-width:100%; }
/* Result actions share one height, including games with their own result panels.
   Keep this after theme styles so larger primary-button padding cannot win. */
.game-frame .result-actions > :is(button,a),
.game-frame :has(> garden-result-share) > button,
.game-frame .result:has(> garden-result-share) > .dialog-actions > button,
.game-frame .result-sharing .result-share-button {
  box-sizing:border-box;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  height:44px;
  min-height:44px;
  padding-block:0;
  font:600 14px/1.4 system-ui,sans-serif;
  align-self:flex-start;
}
.result-sharing { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:6px 10px; margin:8px 0; text-transform:none; letter-spacing:normal; }
.result-sharing .result-share-button { box-sizing:border-box; min-height:44px; padding:10px 16px; border:1px solid #7b8290; border-radius:9px; background:#eee6f5; color:#252a39; font:600 14px/1.4 system-ui,sans-serif; cursor:pointer; }
.result-actions .result-sharing { margin:0; }
.result-actions .result-share-button { width:calc((100% - 10px)/2); }
.result-actions .result-share-status { flex-basis:100%; }
.dialog-actions > garden-result-share { flex:0 0 100%; width:100%; }
.dialog-actions > garden-result-share .result-sharing { margin-bottom:0; }
@media(max-width:360px) {
  .game-frame .result-actions > :is(button,a) { flex-basis:100%; max-width:100%; }
  .result-actions .result-share-button { width:100%; }
}
.result-sharing .result-share-button:hover { background:#e3d6f0; }
.result-sharing :is(button,textarea):focus-visible { outline:3px solid #b99aea; outline-offset:3px; }
.result-sharing .result-share-status { flex-basis:100%; font:12px/1.5 system-ui,sans-serif; color:inherit; }
.result-sharing .result-share-copy { box-sizing:border-box; flex-basis:100%; width:100%; min-width:0; max-width:420px; min-height:120px; padding:10px; border:1px solid #7b8290; border-radius:8px; background:#fffdf8; color:#252a39; font:14px/1.5 ui-monospace,monospace; resize:vertical; }
/* Afterglow's column overlay keeps replay and sharing on one centred axis. */
.game-frame.app .overlay:has(> garden-result-share) > :is(button,garden-result-share) {
  align-self:center;
  width:min(100%,220px);
  min-width:0;
}
.game-frame.app .overlay > garden-result-share .result-share-button { width:100%; }


/* Bespoke result screens use the same width for replay/next and sharing.
   Shared .result-actions keeps its equal two-column layout, and Songbird keeps
   its side-by-side grid. Only completed-result containers are affected. */
.game-frame :is(.overlay-content,.win-banner,.cover-content,.result,.overlay):has(> garden-result-share) > button,
.game-frame .result:has(> garden-result-share) > .dialog-actions > button,
.game-frame .dialog-actions:has(> garden-result-share) > button {
  width:min(100%,220px);
  min-width:0;
  max-width:100%;
  flex:0 1 220px;
  align-self:center;
}
.game-frame :is(.overlay-content,.win-banner,.cover-content,.result,.overlay):has(> garden-result-share) > button {
  flex:0 0 auto;
  margin-inline:auto;
}
.game-frame :is(.overlay-content,.win-banner,.cover-content,.result,.overlay,.dialog-actions) > garden-result-share {
  width:100%;
  align-self:center;
}
.game-frame :is(.overlay-content,.win-banner,.cover-content,.result,.overlay,.dialog-actions) > garden-result-share .result-share-button {
  width:min(100%,220px);
}
.game-frame .dialog-actions:has(> garden-result-share) {
  justify-content:center;
}
.game-frame .result:has(> garden-result-share) > .dialog-actions {
  width:100%;
}
.game-frame .dialog-actions:has(> garden-result-share) > button {
  box-sizing:border-box;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  height:44px;
  min-height:44px;
  padding-block:0;
  font:600 14px/1.4 system-ui,sans-serif;
}

.bloom-share-prompt { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:12px; padding:16px 0; color:#454b59; }
/* Sharing stays beneath replay actions and never opens an automatic modal. */
.share-inline-actions {display:flex;flex-wrap:wrap;justify-content:center;gap:8px;width:100%;}
.share-inline-actions .result-share-button {flex:1 1 140px;max-width:220px;}
.game-frame .result-actions .share-inline-actions .result-share-button {
  flex:0 1 calc((100% - 10px)/2);
  max-width:calc((100% - 10px)/2);
}
.share-invitation {flex-basis:100%;margin:12px 0 4px;font:550 15px/1.5 system-ui;}
.share-inline-status {flex-basis:100%;margin:0;font:14px/1.5 system-ui;}
.share-inline-status:empty {display:none;}
.weekly-postcard {margin:20px 0;}

/* Daily result sharing is disabled; free-play result actions remain available. */
garden-result-share[hidden],
.daily-active garden-result-share {display:none;}

@media(max-width:700px) {
  .game-result:has(garden-result-share) .result-eyebrow {display:none;}
  .game-result:has(garden-result-share) h2 {margin:8px 0;}
}
@media(max-width:360px) {
  .game-result:has(garden-result-share) {padding:12px;}
  .game-result:has(garden-result-share) section > p {display:none;}
  .game-frame .result-actions:has(garden-result-share) {margin-top:12px;}
  .game-frame .result-actions .share-inline-actions > .result-share-button:first-child {width:100%;max-width:100%;flex-basis:100%;}
}
