/* Custom dropdown (native <select>s open in random places / bottom sheets).
   Shared by all SafeShare pages. */
.dd { position: relative; height: 2.2rem; }
.dd-btn {
  width: 100%; height: 100%; padding: 0 2rem 0 .5rem; background: #161b22;
  border: 1px solid #30363d; border-radius: 6px; color: #e6edf3; font-size: .9rem;
  cursor: pointer; text-align: left; white-space: nowrap; overflow: hidden;
  text-overflow: ellipsis; margin: 0;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="6" viewBox="0 0 10 6"><path d="M1 1l4 4 4-4" stroke="%238b949e" stroke-width="1.5" fill="none"/></svg>');
  background-repeat: no-repeat; background-position: right .6rem center;
}
.dd-menu {
  position: absolute; top: calc(100% + 4px); left: 0; min-width: 100%;
  background: #1c2129; border: 1px solid #3d444d; border-radius: 6px;
  margin: 0; padding: .25rem; list-style: none; z-index: 100;
  box-shadow: 0 8px 24px rgba(0,0,0,.5); display: none;
}
.dd.open .dd-menu { display: block; }
.dd-menu li {
  padding: .45rem .6rem; border-radius: 4px; cursor: pointer; font-size: .9rem;
  color: #e6edf3; white-space: nowrap;
}
.dd-menu li:hover, .dd-menu li.sel { background: #263041; }

/* Compact number field with the native spinner nudged right */
.numwrap { position: relative; height: 2.2rem; width: 100%; }
.numwrap input {
  width: 100%; height: 100%; padding: .5rem; box-sizing: border-box;
  background: #161b22; color: #e6edf3; border: 1px solid #30363d; border-radius: 6px;
  font-size: .9rem; text-align: right;
}
.numwrap input::-webkit-inner-spin-button,
.numwrap input::-webkit-outer-spin-button { margin-left: 10px; }

/* Inline share editor (manager / admin panel): labeled grid, controls aligned */
.editgrid {
  display: grid;
  grid-template-columns: minmax(11rem, 1.4fr) minmax(7rem, 1fr) auto;
  gap: .75rem; align-items: end; padding: .5rem .25rem .25rem;
}
.editgrid label {
  font-size: .8rem; color: #8b949e; display: block;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  margin-bottom: .25rem; height: 1.05rem;
}
.editgrid .numwrap, .editgrid .dd { height: 2.2rem; }
.editgrid .numwrap input, .editgrid .dd-btn { background: #0d1117; }
.editgrid .editbtns { display: flex; gap: .4rem; }
.editgrid .editbtns button { height: 2.2rem; padding: 0 1rem; margin: 0; }
.editgrid .edwarn { grid-column: 1 / -1; color: #f85149; font-size: .78rem; margin-top: .25rem; }
.editgrid .ederr { grid-column: 1 / -1; color: #f85149; font-size: .8rem; min-height: 1em; margin-top: .25rem; }
.editgrid .ttl-row { display: flex; gap: .4rem; margin-top: .5rem; }
.editgrid .ttl-row .numwrap { flex: 0 0 4.5rem; width: 4.5rem; }
.editgrid .ttl-row .dd { flex: 1 1 auto; min-width: 0; }
@media (max-width: 700px) { .editgrid { grid-template-columns: 1fr; } }
